VectorTypeTerm.java

  1. /* Copyright 2024-2025 The Johns Hopkins University Applied Physics Laboratory
  2.  * Licensed to CS GROUP (CS) under one or more
  3.  * contributor license agreements.  See the NOTICE file distributed with
  4.  * this work for additional information regarding copyright ownership.
  5.  * CS licenses this file to You under the Apache License, Version 2.0
  6.  * (the "License"); you may not use this file except in compliance with
  7.  * the License.  You may obtain a copy of the License at
  8.  *
  9.  *   http://www.apache.org/licenses/LICENSE-2.0
  10.  *
  11.  * Unless required by applicable law or agreed to in writing, software
  12.  * distributed under the License is distributed on an "AS IS" BASIS,
  13.  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  14.  * See the License for the specific language governing permissions and
  15.  * limitations under the License.
  16.  */
  17. package org.orekit.files.iirv.terms;

  18. import org.orekit.files.iirv.terms.base.LongValuedIIRVTerm;

  19. /**
  20.  * 1-character type of vector specified in the message.
  21.  * <p>
  22.  * Valid values:
  23.  * <ul>
  24.  * <li> 1 = Free flight (routine on-orbit)
  25.  * <li> 2 = Forced (special orbit update)
  26.  * <li> 3 = Spare
  27.  * <li> 4 = Maneuver ignition
  28.  * <li> 5 = Maneuver cutoff
  29.  * <li> 6 = Reentry
  30.  * <li> 7 = Powered flight
  31.  * <li> 8 = Stationary
  32.  * <li> 9 = Spare
  33.  * </ul>
  34.  *
  35.  * @author Nick LaFarge
  36.  * @since 13.0
  37.  */
  38. public class VectorTypeTerm extends LongValuedIIRVTerm {

  39.     /** Free flight (routine on-orbit) VectorType. */
  40.     public static final VectorTypeTerm FREE_FLIGHT = new VectorTypeTerm("1");

  41.     /** Forced VectorType. */
  42.     public static final VectorTypeTerm FORCED = new VectorTypeTerm("2");

  43.     /** Spare VectorType: 3. */
  44.     public static final VectorTypeTerm SPARE3 = new VectorTypeTerm("3");

  45.     /** Maneuver ignition VectorType. */
  46.     public static final VectorTypeTerm MANEUVER_IGNITION = new VectorTypeTerm("4");

  47.     /** Maneuver cutoff VectorType. */
  48.     public static final VectorTypeTerm MANEUVER_CUTOFF = new VectorTypeTerm("5");

  49.     /** Reentry VectorType. */
  50.     public static final VectorTypeTerm REENTRY = new VectorTypeTerm("6");

  51.     /** Powered flight VectorType. */
  52.     public static final VectorTypeTerm POWERED_FLIGHT = new VectorTypeTerm("7");

  53.     /** Stationary VectorType. */
  54.     public static final VectorTypeTerm STATIONARY = new VectorTypeTerm("8");

  55.     /** Spare VectorType: 9. */
  56.     public static final VectorTypeTerm SPARE9 = new VectorTypeTerm("9");

  57.     /** The length of the IIRV term within the message. */
  58.     public static final int VECTOR_TYPE_TERM_LENGTH = 1;

  59.     /** Regular expression that ensures the validity of string values for this term. */
  60.     public static final String VECTOR_TYPE_TERM_PATTERN = "[1-9]";

  61.     /**
  62.      * Constructor.
  63.      * <p>
  64.      * See {@link LongValuedIIRVTerm#LongValuedIIRVTerm(String, String, int, boolean)}
  65.      *
  66.      * @param value value of the vector type term
  67.      */
  68.     public VectorTypeTerm(final String value) {
  69.         super(VECTOR_TYPE_TERM_PATTERN, value, VECTOR_TYPE_TERM_LENGTH, false);
  70.     }

  71.     /**
  72.      * Constructor.
  73.      * <p>
  74.      * See {@link LongValuedIIRVTerm#LongValuedIIRVTerm(String, long, int, boolean)}
  75.      *
  76.      * @param value value of the vector type term
  77.      */
  78.     public VectorTypeTerm(final long value) {
  79.         super(VECTOR_TYPE_TERM_PATTERN, value, VECTOR_TYPE_TERM_LENGTH, false);
  80.     }
  81. }