OcmMetadata.java
/* Copyright 2002-2026 CS GROUP
* Licensed to CS GROUP (CS) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* CS licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.orekit.files.ccsds.ndm.odm.ocm;
import java.util.ArrayList;
import java.util.List;
import java.util.Optional;
import org.orekit.annotation.Nullable;
import org.orekit.data.DataContext;
import org.orekit.files.ccsds.definitions.CcsdsFrameMapper;
import org.orekit.files.ccsds.definitions.TimeSystem;
import org.orekit.files.ccsds.ndm.odm.OdmMetadata;
import org.orekit.files.ccsds.section.MetadataKey;
import org.orekit.frames.Frame;
import org.orekit.time.AbsoluteDate;
/** Meta-data for {@link OcmMetadata Orbit Comprehensive Message}.
* @since 11.0
*/
public class OcmMetadata extends OdmMetadata {
/** Default value for SCLK_OFFSET_AT_EPOCH.
* @since 12.0
*/
public static final double DEFAULT_SCLK_OFFSET_AT_EPOCH = 0.0;
/** Default value for SCLK_SEC_PER_SI_SEC.
* @since 12.0
*/
public static final double DEFAULT_SCLK_SEC_PER_SI_SEC = 1.0;
/** International designator for the object as assigned by the UN Committee
* on Space Research (COSPAR) and the US National Space Science Data Center (NSSDC). */
@Nullable
private String internationalDesignator;
/** Specification of satellite catalog source. */
@Nullable
private String catalogName;
/** Unique satellite identification designator for the object. */
@Nullable
private String objectDesignator;
/** Alternate names for this space object. */
private List<String> alternateNames;
/** Programmatic Point Of Contact at originator. */
@Nullable
private String originatorPOC;
/** Position of Programmatic Point Of Contact at originator. */
@Nullable
private String originatorPosition;
/** Phone number of Programmatic Point Of Contact at originator. */
@Nullable
private String originatorPhone;
/** Email address of Programmatic Point Of Contact at originator.
* @since 11.2
*/
@Nullable
private String originatorEmail;
/** Address of Programmatic Point Of Contact at originator. */
@Nullable
private String originatorAddress;
/** Creating agency or operator. */
@Nullable
private String techOrg;
/** Technical Point Of Contact at originator. */
@Nullable
private String techPOC;
/** Position of Technical Point Of Contact at originator. */
@Nullable
private String techPosition;
/** Phone number of Technical Point Of Contact at originator. */
@Nullable
private String techPhone;
/** Email address of Technical Point Of Contact at originator.
* @since 11.2
*/
@Nullable
private String techEmail;
/** Address of Technical Point Of Contact at originator. */
@Nullable
private String techAddress;
/** Unique ID identifying previous message from a given originator. */
@Nullable
private String previousMessageID;
/** Unique ID identifying next message from a given originator. */
@Nullable
private String nextMessageID;
/** Unique identifier of Attitude Data Message linked to this Orbit Data Message. */
@Nullable
private String admMessageLink;
/** Unique identifier of Conjunction Data Message linked to this Orbit Data Message. */
@Nullable
private String cdmMessageLink;
/** Unique identifier of Pointing Request Message linked to this Orbit Data Message. */
@Nullable
private String prmMessageLink;
/** Unique identifier of Reentry Data Messages linked to this Orbit Data Message. */
@Nullable
private String rdmMessageLink;
/** Unique identifier of Tracking Data Messages linked to this Orbit Data Message. */
@Nullable
private String tdmMessageLink;
/** Operator of the space object. */
@Nullable
private String operator;
/** Owner of the space object. */
@Nullable
private String owner;
/** Name of the country where the space object owner is based. */
@Nullable
private String country;
/** Name of the constellation this space object belongs to. */
@Nullable
private String constellation;
/** Type of object. */
@Nullable
private ObjectType objectType;
/** Epoch to which <em>all</em> relative times are referenced in data blocks;
* unless overridden by block-specific {@code EPOCH_TZERO} values. */
private AbsoluteDate epochT0;
/** Operational status. */
@Nullable
private OpsStatus opsStatus;
/** Orbit category. */
@Nullable
private OrbitCategory orbitCategory;
/** List of elements of information data blocks included in this message. */
private List<OcmElements> ocmDataElements;
/** Spacecraft clock count at {@link #getEpochT0()}.
* Never null because of default value.
*/
private double sclkOffsetAtEpoch;
/** Number of spacecraft clock seconds occurring during one SI second.
* Never null because of default value.
*/
private double sclkSecPerSISec;
/** Creation date of previous message from a given originator. */
@Nullable
private AbsoluteDate previousMessageEpoch;
/** Creation date of next message from a given originator. */
@Nullable
private AbsoluteDate nextMessageEpoch;
/** Time of the earliest data contained in the OCM. */
@Nullable
private AbsoluteDate startTime;
/** Time of the latest data contained in the OCM. */
@Nullable
private AbsoluteDate stopTime;
/** Span of time that the OCM covers. */
@Nullable
private Double timeSpan;
/** Difference (TAI - UTC) in seconds at epoch {@link #epochT0}. */
@Nullable
private Double taimutcT0;
/** Epoch of next leap second.
* @since 11.2
*/
@Nullable
private AbsoluteDate nextLeapEpoch;
/** Difference (TAI - UTC) in seconds incorporated at {@link #nextLeapEpoch}.
* @since 11.2
*/
@Nullable
private Double nextLeapTaimutc;
/** Difference (UT1 - UTC) in seconds at epoch {@link #epochT0}. */
@Nullable
private Double ut1mutcT0;
/** Source and version of Earth Orientation Parameters. */
@Nullable
private String eopSource;
/** Interpolation method for Earth Orientation Parameters. */
@Nullable
private String interpMethodEOP;
/** Source and version of celestial body (e.g. Sun/Earth/Planetary). */
@Nullable
private String celestialSource;
/** Data context.
* @since 12.0
*/
private final DataContext dataContext;
/**
* Create a new meta-data.
*
* @param dataContext data context
* @param frameMapper for creating an Orekit {@link Frame}.
* @since 13.1.5
*/
public OcmMetadata(final DataContext dataContext,
final CcsdsFrameMapper frameMapper) {
// set up the few fields that have default values as per CCSDS standard
super(TimeSystem.UTC, frameMapper);
this.sclkOffsetAtEpoch = DEFAULT_SCLK_OFFSET_AT_EPOCH; // Default value if absent
this.sclkSecPerSISec = DEFAULT_SCLK_SEC_PER_SI_SEC; // Default value if absent
this.dataContext = dataContext;
this.ocmDataElements = new ArrayList<>();
this.alternateNames = new ArrayList<>();
}
/** {@inheritDoc} */
@Override
public void validate(final double version) {
// we don't call super.checkMandatoryEntries() because
// all of the parameters considered mandatory at ODM level
// for OPM, OMM and OEM are in fact optional in OCM
// only TIME_SYSTEM and EPOCH_TZERO are mandatory
checkNotNull(getTimeSystem(), MetadataKey.TIME_SYSTEM.name());
checkNotNull(epochT0, OcmMetadataKey.EPOCH_TZERO.name());
if (nextLeapEpoch != null) {
checkNotNaN(nextLeapTaimutc != null ? nextLeapTaimutc : Double.NaN, OcmMetadataKey.NEXT_LEAP_TAIMUTC.name());
}
}
/** Get the international designator for the object.
* @return international designator for the object
*/
public Optional<String> getInternationalDesignator() {
return Optional.ofNullable(internationalDesignator);
}
/** Set the international designator for the object.
* @param internationalDesignator international designator for the object
*/
public void setInternationalDesignator(final String internationalDesignator) {
refuseFurtherComments();
this.internationalDesignator = internationalDesignator;
}
/** Get the specification of satellite catalog source.
* @return specification of satellite catalog source
*/
public Optional<String> getCatalogName() {
return Optional.ofNullable(catalogName);
}
/** Set the specification of satellite catalog source.
* @param catalogName specification of satellite catalog source
*/
public void setCatalogName(final String catalogName) {
refuseFurtherComments();
this.catalogName = catalogName;
}
/** Get the unique satellite identification designator for the object.
* @return unique satellite identification designator for the object.
*/
public Optional<String> getObjectDesignator() {
return Optional.ofNullable(objectDesignator);
}
/** Set the unique satellite identification designator for the object.
* @param objectDesignator unique satellite identification designator for the object
*/
public void setObjectDesignator(final String objectDesignator) {
refuseFurtherComments();
this.objectDesignator = objectDesignator;
}
/** Get the alternate names for this space object.
* @return alternate names
*/
public List<String> getAlternateNames() {
return alternateNames;
}
/** Set the alternate names for this space object.
* @param alternateNames alternate names
*/
public void setAlternateNames(final List<String> alternateNames) {
refuseFurtherComments();
this.alternateNames = alternateNames;
}
/** Get the programmatic Point Of Contact at originator.
* @return programmatic Point Of Contact at originator
*/
public Optional<String> getOriginatorPOC() {
return Optional.ofNullable(originatorPOC);
}
/** Set the programmatic Point Of Contact at originator.
* @param originatorPOC programmatic Point Of Contact at originator
*/
public void setOriginatorPOC(final String originatorPOC) {
refuseFurtherComments();
this.originatorPOC = originatorPOC;
}
/** Get the position of Programmatic Point Of Contact at originator.
* @return position of Programmatic Point Of Contact at originator
*/
public Optional<String> getOriginatorPosition() {
return Optional.ofNullable(originatorPosition);
}
/** Set the position of Programmatic Point Of Contact at originator.
* @param originatorPosition position of Programmatic Point Of Contact at originator
*/
public void setOriginatorPosition(final String originatorPosition) {
refuseFurtherComments();
this.originatorPosition = originatorPosition;
}
/** Get the phone number of Programmatic Point Of Contact at originator.
* @return phone number of Programmatic Point Of Contact at originator
*/
public Optional<String> getOriginatorPhone() {
return Optional.ofNullable(originatorPhone);
}
/** Set the phone number of Programmatic Point Of Contact at originator.
* @param originatorPhone phone number of Programmatic Point Of Contact at originator
*/
public void setOriginatorPhone(final String originatorPhone) {
refuseFurtherComments();
this.originatorPhone = originatorPhone;
}
/** Get the email address of Programmatic Point Of Contact at originator.
* @return email address of Programmatic Point Of Contact at originator
* @since 11.2
*/
public Optional<String> getOriginatorEmail() {
return Optional.ofNullable(originatorEmail);
}
/** Set the email address of Programmatic Point Of Contact at originator.
* @param originatorEmail email address of Programmatic Point Of Contact at originator
* @since 11.2
*/
public void setOriginatorEmail(final String originatorEmail) {
refuseFurtherComments();
this.originatorEmail = originatorEmail;
}
/** Get the address of Programmatic Point Of Contact at originator.
* @return address of Programmatic Point Of Contact at originator
*/
public Optional<String> getOriginatorAddress() {
return Optional.ofNullable(originatorAddress);
}
/** Set the address of Programmatic Point Of Contact at originator.
* @param originatorAddress address of Programmatic Point Of Contact at originator
*/
public void setOriginatorAddress(final String originatorAddress) {
refuseFurtherComments();
this.originatorAddress = originatorAddress;
}
/** Get the creating agency or operator.
* @return creating agency or operator
*/
public Optional<String> getTechOrg() {
return Optional.ofNullable(techOrg);
}
/** Set the creating agency or operator.
* @param techOrg creating agency or operator
*/
public void setTechOrg(final String techOrg) {
refuseFurtherComments();
this.techOrg = techOrg;
}
/** Get the Technical Point Of Contact at originator.
* @return Technical Point Of Contact at originator
*/
public Optional<String> getTechPOC() {
return Optional.ofNullable(techPOC);
}
/** Set the Technical Point Of Contact at originator.
* @param techPOC Technical Point Of Contact at originator
*/
public void setTechPOC(final String techPOC) {
refuseFurtherComments();
this.techPOC = techPOC;
}
/** Get the position of Technical Point Of Contact at originator.
* @return position of Technical Point Of Contact at originator
*/
public Optional<String> getTechPosition() {
return Optional.ofNullable(techPosition);
}
/** Set the position of Technical Point Of Contact at originator.
* @param techPosition position of Technical Point Of Contact at originator
*/
public void setTechPosition(final String techPosition) {
refuseFurtherComments();
this.techPosition = techPosition;
}
/** Get the phone number of Technical Point Of Contact at originator.
* @return phone number of Technical Point Of Contact at originator
*/
public Optional<String> getTechPhone() {
return Optional.ofNullable(techPhone);
}
/** Set the phone number of Technical Point Of Contact at originator.
* @param techPhone phone number of Technical Point Of Contact at originator
*/
public void setTechPhone(final String techPhone) {
refuseFurtherComments();
this.techPhone = techPhone;
}
/** Get the email address of Technical Point Of Contact at originator.
* @return email address of Technical Point Of Contact at originator
* @since 11.2
*/
public Optional<String> getTechEmail() {
return Optional.ofNullable(techEmail);
}
/** Set the email address of Technical Point Of Contact at originator.
* @param techEmail email address of Technical Point Of Contact at originator
* @since 11.2
*/
public void setTechEmail(final String techEmail) {
refuseFurtherComments();
this.techEmail = techEmail;
}
/** Get the address of Technical Point Of Contact at originator.
* @return address of Technical Point Of Contact at originator
*/
public Optional<String> getTechAddress() {
return Optional.ofNullable(techAddress);
}
/** Set the address of Technical Point Of Contact at originator.
* @param techAddress address of Technical Point Of Contact at originator
*/
public void setTechAddress(final String techAddress) {
refuseFurtherComments();
this.techAddress = techAddress;
}
/** Get the unique ID identifying previous message from a given originator.
* @return unique ID identifying previous message from a given originator
*/
public Optional<String> getPreviousMessageID() {
return Optional.ofNullable(previousMessageID);
}
/** Set the unique ID identifying previous message from a given originator.
* @param previousMessageID unique ID identifying previous message from a given originator
*/
public void setPreviousMessageID(final String previousMessageID) {
refuseFurtherComments();
this.previousMessageID = previousMessageID;
}
/** Get the unique ID identifying next message from a given originator.
* @return unique ID identifying next message from a given originator
*/
public Optional<String> getNextMessageID() {
return Optional.ofNullable(nextMessageID);
}
/** Set the unique ID identifying next message from a given originator.
* @param nextMessageID unique ID identifying next message from a given originator
*/
public void setNextMessageID(final String nextMessageID) {
refuseFurtherComments();
this.nextMessageID = nextMessageID;
}
/** Get the Unique identifier of Attitude Data Message linked to this Orbit Data Message.
* @return Unique identifier of Attitude Data Message linked to this Orbit Data Message
*/
public Optional<String> getAdmMessageLink() {
return Optional.ofNullable(admMessageLink);
}
/** Set the Unique identifier of Attitude Data Message linked to this Orbit Data Message.
* @param admMessageLink Unique identifier of Attitude Data Message linked to this Orbit Data Message
*/
public void setAdmMessageLink(final String admMessageLink) {
refuseFurtherComments();
this.admMessageLink = admMessageLink;
}
/** Get the Unique identifier of Conjunction Data Message linked to this Orbit Data Message.
* @return Unique identifier of Conjunction Data Message linked to this Orbit Data Message
*/
public Optional<String> getCdmMessageLink() {
return Optional.ofNullable(cdmMessageLink);
}
/** Set the Unique identifier of Conjunction Data Message linked to this Orbit Data Message.
* @param cdmMessageLink Unique identifier of Conjunction Data Message linked to this Orbit Data Message
*/
public void setCdmMessageLink(final String cdmMessageLink) {
refuseFurtherComments();
this.cdmMessageLink = cdmMessageLink;
}
/** Get the Unique identifier of Pointing Request Message linked to this Orbit Data Message.
* @return Unique identifier of Pointing Request Message linked to this Orbit Data Message
*/
public Optional<String> getPrmMessageLink() {
return Optional.ofNullable(prmMessageLink);
}
/** Set the Unique identifier of Pointing Request Message linked to this Orbit Data Message.
* @param prmMessageLink Unique identifier of Pointing Request Message linked to this Orbit Data Message
*/
public void setPrmMessageLink(final String prmMessageLink) {
refuseFurtherComments();
this.prmMessageLink = prmMessageLink;
}
/** Get the Unique identifier of Reentry Data Message linked to this Orbit Data Message.
* @return Unique identifier of Reentry Data Message linked to this Orbit Data Message
*/
public Optional<String> getRdmMessageLink() {
return Optional.ofNullable(rdmMessageLink);
}
/** Set the Unique identifier of Reentry Data Message linked to this Orbit Data Message.
* @param rdmMessageLink Unique identifier of Reentry Data Message linked to this Orbit Data Message
*/
public void setRdmMessageLink(final String rdmMessageLink) {
refuseFurtherComments();
this.rdmMessageLink = rdmMessageLink;
}
/** Get the Unique identifier of Tracking Data Message linked to this Orbit Data Message.
* @return Unique identifier of Tracking Data Message linked to this Orbit Data Message
*/
public Optional<String> getTdmMessageLink() {
return Optional.ofNullable(tdmMessageLink);
}
/** Set the Unique identifier of Tracking Data Message linked to this Orbit Data Message.
* @param tdmMessageLink Unique identifier of Tracking Data Message linked to this Orbit Data Message
*/
public void setTdmMessageLink(final String tdmMessageLink) {
refuseFurtherComments();
this.tdmMessageLink = tdmMessageLink;
}
/** Get the operator of the space object.
* @return operator of the space object
*/
public Optional<String> getOperator() {
return Optional.ofNullable(operator);
}
/** Set the operator of the space object.
* @param operator operator of the space object
*/
public void setOperator(final String operator) {
refuseFurtherComments();
this.operator = operator;
}
/** Get the owner of the space object.
* @return owner of the space object
*/
public Optional<String> getOwner() {
return Optional.ofNullable(owner);
}
/** Set the owner of the space object.
* @param owner owner of the space object
*/
public void setOwner(final String owner) {
refuseFurtherComments();
this.owner = owner;
}
/** Get the name of the country where the space object owner is based.
* @return name of the country where the space object owner is based
*/
public Optional<String> getCountry() {
return Optional.ofNullable(country);
}
/** Set the name of the country where the space object owner is based.
* @param country name of the country where the space object owner is based
*/
public void setCountry(final String country) {
refuseFurtherComments();
this.country = country;
}
/** Get the name of the constellation this space object belongs to.
* @return name of the constellation this space object belongs to
*/
public Optional<String> getConstellation() {
return Optional.ofNullable(constellation);
}
/** Set the name of the constellation this space object belongs to.
* @param constellation name of the constellation this space object belongs to
*/
public void setConstellation(final String constellation) {
refuseFurtherComments();
this.constellation = constellation;
}
/** Get the type of object.
* @return type of object
*/
public Optional<ObjectType> getObjectType() {
return Optional.ofNullable(objectType);
}
/** Set the type of object.
* @param objectType type of object
*/
public void setObjectType(final ObjectType objectType) {
refuseFurtherComments();
this.objectType = objectType;
}
/** Get the epoch to which <em>all</em> relative times are referenced in data blocks.
* @return epoch to which <em>all</em> relative times are referenced in data blocks
*/
public AbsoluteDate getEpochT0() {
return epochT0;
}
/** Set the epoch to which <em>all</em> relative times are referenced in data blocks.
* @param epochT0 epoch to which <em>all</em> relative times are referenced in data blocks
*/
public void setEpochT0(final AbsoluteDate epochT0) {
refuseFurtherComments();
this.epochT0 = epochT0;
}
/** Get the operational status.
* @return operational status
*/
public Optional<OpsStatus> getOpsStatus() {
return Optional.ofNullable(opsStatus);
}
/** Set the operational status.
* @param opsStatus operational status
*/
public void setOpsStatus(final OpsStatus opsStatus) {
refuseFurtherComments();
this.opsStatus = opsStatus;
}
/** Get the orbit category.
* @return orbit category
*/
public Optional<OrbitCategory> getOrbitCategory() {
return Optional.ofNullable(orbitCategory);
}
/** Set the orbit category.
* @param orbitCategory orbit category
*/
public void setOrbitCategory(final OrbitCategory orbitCategory) {
refuseFurtherComments();
this.orbitCategory = orbitCategory;
}
/** Get the list of elements of information data blocks included in this message.
* @return list of elements of information data blocks included in this message
*/
public List<OcmElements> getOcmDataElements() {
return ocmDataElements;
}
/** Set the list of elements of information data blocks included in this message.
* @param ocmDataElements list of elements of information data blocks included in this message
*/
public void setOcmDataElements(final List<OcmElements> ocmDataElements) {
refuseFurtherComments();
this.ocmDataElements = ocmDataElements;
}
/** Get the spacecraft clock count at {@link #getEpochT0()}.
* @return spacecraft clock count at {@link #getEpochT0()}
*/
public double getSclkOffsetAtEpoch() {
return sclkOffsetAtEpoch;
}
/** Set the spacecraft clock count at {@link #getEpochT0()}.
* @param sclkOffsetAtEpoch spacecraft clock count at {@link #getEpochT0()}
*/
public void setSclkOffsetAtEpoch(final double sclkOffsetAtEpoch) {
refuseFurtherComments();
this.sclkOffsetAtEpoch = sclkOffsetAtEpoch;
}
/** Get the number of spacecraft clock seconds occurring during one SI second.
* @return number of spacecraft clock seconds occurring during one SI second
*/
public double getSclkSecPerSISec() {
return sclkSecPerSISec;
}
/** Set the number of spacecraft clock seconds occurring during one SI second.
* @param secClockPerSISec number of spacecraft clock seconds occurring during one SI second
*/
public void setSclkSecPerSISec(final double secClockPerSISec) {
refuseFurtherComments();
this.sclkSecPerSISec = secClockPerSISec;
}
/** Get the creation date of previous message from a given originator.
* @return creation date of previous message from a given originator
*/
public Optional<AbsoluteDate> getPreviousMessageEpoch() {
return Optional.ofNullable(previousMessageEpoch);
}
/** Set the creation date of previous message from a given originator.
* @param previousMessageEpoch creation date of previous message from a given originator
*/
public void setPreviousMessageEpoch(final AbsoluteDate previousMessageEpoch) {
refuseFurtherComments();
this.previousMessageEpoch = previousMessageEpoch;
}
/** Get the creation date of next message from a given originator.
* @return creation date of next message from a given originator
*/
public Optional<AbsoluteDate> getNextMessageEpoch() {
return Optional.ofNullable(nextMessageEpoch);
}
/** Set the creation date of next message from a given originator.
* @param nextMessageEpoch creation date of next message from a given originator
*/
public void setNextMessageEpoch(final AbsoluteDate nextMessageEpoch) {
refuseFurtherComments();
this.nextMessageEpoch = nextMessageEpoch;
}
/** Get the time of the earliest data contained in the OCM.
* @return time of the earliest data contained in the OCM
*/
public Optional<AbsoluteDate> getStartTime() {
return Optional.ofNullable(startTime);
}
/** Set the time of the earliest data contained in the OCM.
* @param startTime time of the earliest data contained in the OCM
*/
public void setStartTime(final AbsoluteDate startTime) {
refuseFurtherComments();
this.startTime = startTime;
}
/** Get the time of the latest data contained in the OCM.
* @return time of the latest data contained in the OCM
*/
public Optional<AbsoluteDate> getStopTime() {
return Optional.ofNullable(stopTime);
}
/** Set the time of the latest data contained in the OCM.
* @param stopTime time of the latest data contained in the OCM
*/
public void setStopTime(final AbsoluteDate stopTime) {
refuseFurtherComments();
this.stopTime = stopTime;
}
/** Get the span of time in seconds that the OCM covers.
* @return span of time in seconds that the OCM covers
*/
public Optional<Double> getTimeSpan() {
return Optional.ofNullable(timeSpan);
}
/** Set the span of time in seconds that the OCM covers.
* @param timeSpan span of time in seconds that the OCM covers
*/
public void setTimeSpan(final double timeSpan) {
refuseFurtherComments();
this.timeSpan = timeSpan;
}
/** Get the difference (TAI - UTC) in seconds at epoch {@link #getEpochT0()}.
* @return difference (TAI - UTC) in seconds at epoch {@link #getEpochT0()}
*/
public Optional<Double> getTaimutcT0() {
return Optional.ofNullable(taimutcT0);
}
/** Set the difference (TAI - UTC) in seconds at epoch {@link #getEpochT0()}.
* @param taimutcT0 difference (TAI - UTC) in seconds at epoch {@link #getEpochT0()}
*/
public void setTaimutcT0(final double taimutcT0) {
refuseFurtherComments();
this.taimutcT0 = taimutcT0;
}
/** Get the epoch of next leap second.
* @return epoch of next leap second
* @since 11.2
*/
public Optional<AbsoluteDate> getNextLeapEpoch() {
return Optional.ofNullable(nextLeapEpoch);
}
/** Set the epoch of next leap second.
* @param nextLeapEpoch epoch of next leap second
* @since 11.2
*/
public void setNextLeapEpoch(final AbsoluteDate nextLeapEpoch) {
refuseFurtherComments();
this.nextLeapEpoch = nextLeapEpoch;
}
/** Get the difference (TAI - UTC) in seconds incorporated at epoch {@link #getNextLeapEpoch()}.
* @return difference (TAI - UTC) in seconds incorporated at epoch {@link #getNextLeapEpoch()}
* @since 11.2
*/
public Optional<Double> getNextLeapTaimutc() {
return Optional.ofNullable(nextLeapTaimutc);
}
/** Set the difference (TAI - UTC) in seconds incorporated at epoch {@link #getNextLeapEpoch()}.
* @param nextLeapTaimutc difference (TAI - UTC) in seconds incorporated at epoch {@link #getNextLeapEpoch()}
* @since 11.2
*/
public void setNextLeapTaimutc(final double nextLeapTaimutc) {
refuseFurtherComments();
this.nextLeapTaimutc = nextLeapTaimutc;
}
/** Get the difference (UT1 - UTC) in seconds at epoch {@link #getEpochT0()}.
* @return difference (UT1 - UTC) in seconds at epoch {@link #getEpochT0()}
*/
public Optional<Double> getUt1mutcT0() {
return Optional.ofNullable(ut1mutcT0);
}
/** Set the difference (UT1 - UTC) in seconds at epoch {@link #getEpochT0()}.
* @param ut1mutcT0 difference (UT1 - UTC) in seconds at epoch {@link #getEpochT0()}
*/
public void setUt1mutcT0(final double ut1mutcT0) {
refuseFurtherComments();
this.ut1mutcT0 = ut1mutcT0;
}
/** Get the source and version of Earth Orientation Parameters.
* @return source and version of Earth Orientation Parameters
*/
public Optional<String> getEopSource() {
return Optional.ofNullable(eopSource);
}
/** Set the source and version of Earth Orientation Parameters.
* @param eopSource source and version of Earth Orientation Parameters
*/
public void setEopSource(final String eopSource) {
refuseFurtherComments();
this.eopSource = eopSource;
}
/** Get the interpolation method for Earth Orientation Parameters.
* @return interpolation method for Earth Orientation Parameters
*/
public Optional<String> getInterpMethodEOP() {
return Optional.ofNullable(interpMethodEOP);
}
/** Set the interpolation method for Earth Orientation Parameters.
* @param interpMethodEOP interpolation method for Earth Orientation Parameters
*/
public void setInterpMethodEOP(final String interpMethodEOP) {
refuseFurtherComments();
this.interpMethodEOP = interpMethodEOP;
}
/** Get the source and version of celestial body (e.g. Sun/Earth/Planetary).
* @return source and version of celestial body (e.g. Sun/Earth/Planetary)
*/
public Optional<String> getCelestialSource() {
return Optional.ofNullable(celestialSource);
}
/** Set the source and version of celestial body (e.g. Sun/Earth/Planetary).
* @param celestialSource source and version of celestial body (e.g. Sun/Earth/Planetary)
*/
public void setCelestialSource(final String celestialSource) {
refuseFurtherComments();
this.celestialSource = celestialSource;
}
/** Copy the instance, making sure mandatory fields have been initialized.
* <p>
* Message ID, previous/next references, start and stop times are not copied.
* </p>
* @param version format version
* @return a new copy
* @since 12.0
*/
public OcmMetadata copy(final double version) {
validate(version);
// allocate new instance
final OcmMetadata copy = new OcmMetadata(dataContext, getFrameMapper());
// copy comments
for (String comment : getComments()) {
copy.addComment(comment);
}
// copy metadata
getInternationalDesignator().ifPresent(copy::setInternationalDesignator);
getCatalogName().ifPresent(copy::setCatalogName);
getObjectDesignator().ifPresent(copy::setObjectDesignator);
copy.setAlternateNames(getAlternateNames());
getOriginatorPOC().ifPresent(copy::setOriginatorPOC);
getOriginatorPosition().ifPresent(copy::setOriginatorPosition);
getOriginatorPhone().ifPresent(copy::setOriginatorPhone);
getOriginatorEmail().ifPresent(copy::setOriginatorEmail);
getOriginatorAddress().ifPresent(copy::setOriginatorAddress);
getTechOrg().ifPresent(copy::setTechOrg);
getTechPOC().ifPresent(copy::setTechPOC);
getTechPosition().ifPresent(copy::setTechPosition);
getTechPhone().ifPresent(copy::setTechPhone);
getTechEmail().ifPresent(copy::setTechEmail);
getTechAddress().ifPresent(copy::setTechAddress);
getAdmMessageLink().ifPresent(copy::setAdmMessageLink);
getCdmMessageLink().ifPresent(copy::setCdmMessageLink);
getPrmMessageLink().ifPresent(copy::setPrmMessageLink);
getRdmMessageLink().ifPresent(copy::setRdmMessageLink);
getTdmMessageLink().ifPresent(copy::setTdmMessageLink);
getOperator().ifPresent(copy::setOperator);
getOwner().ifPresent(copy::setOwner);
getCountry().ifPresent(copy::setCountry);
getConstellation().ifPresent(copy::setConstellation);
getObjectType().ifPresent(copy::setObjectType);
copy.setEpochT0(getEpochT0());
getOpsStatus().ifPresent(copy::setOpsStatus);
getOrbitCategory().ifPresent(copy::setOrbitCategory);
copy.setOcmDataElements(getOcmDataElements());
copy.setSclkOffsetAtEpoch(getSclkOffsetAtEpoch());
copy.setSclkSecPerSISec(getSclkSecPerSISec());
getTaimutcT0().ifPresent(copy::setTaimutcT0);
getNextLeapEpoch().ifPresent(copy::setNextLeapEpoch);
getNextLeapTaimutc().ifPresent(copy::setNextLeapTaimutc);
getUt1mutcT0().ifPresent(copy::setUt1mutcT0);
getEopSource().ifPresent(copy::setEopSource);
getInterpMethodEOP().ifPresent(copy::setInterpMethodEOP);
getCelestialSource().ifPresent(copy::setCelestialSource);
return copy;
}
}