Class RinexUtils


  • public class RinexUtils
    extends Object
    Utilities for RINEX various messages files.
    Since:
    12.0
    Author:
    Luc Maisonobe
    • Field Detail

      • LABEL_INDEX

        public static final int LABEL_INDEX
        Index of label in header lines.
        See Also:
        Constant Field Values
    • Method Detail

      • getLabel

        public static String getLabel​(String line)
        Get the trimmed label from a header line.
        Parameters:
        line - header line to parse
        Returns:
        trimmed label
      • matchesLabel

        public static boolean matchesLabel​(String line,
                                           String label)
        Check if a header line matches an expected label.
        Parameters:
        line - header line to check
        label - expected label
        Returns:
        true if line matches expected label
      • parseVersionFileTypeSatelliteSystem

        public static void parseVersionFileTypeSatelliteSystem​(String line,
                                                               String name,
                                                               RinexBaseHeader header,
                                                               double... supportedVersions)
        Parse version, file type and satellite system.
        Parameters:
        line - line to parse
        name - file name (for error message generation)
        header - header to fill with parsed data
        supportedVersions - supported versions
      • parseProgramRunByDate

        public static void parseProgramRunByDate​(String line,
                                                 int lineNumber,
                                                 String name,
                                                 TimeScales timeScales,
                                                 RinexBaseHeader header)
        Parse program, run/by and date.
        Parameters:
        line - line to parse
        lineNumber - line number
        name - file name (for error message generation)
        timeScales - the set of time scales used for parsing dates.
        header - header to fill with parsed data
      • parseComment

        public static void parseComment​(int lineNumber,
                                        String line,
                                        RinexFile<?> rinexFile)
        Parse a comment.
        Parameters:
        lineNumber - line number
        line - line to parse
        rinexFile - rinex file
      • parseDouble

        public static double parseDouble​(String line,
                                         int startIndex,
                                         int size)
        Parse a double value.
        Parameters:
        line - line to parse
        startIndex - start index
        size - size of the value
        Returns:
        the parsed value
      • parseInt

        public static int parseInt​(String line,
                                   int startIndex,
                                   int size)
        Parse an integer value.
        Parameters:
        line - line to parse
        startIndex - start index
        size - size of the value
        Returns:
        the parsed value
      • parseString

        public static String parseString​(String line,
                                         int startIndex,
                                         int size)
        Parse a string value.
        Parameters:
        line - line to parse
        startIndex - start index
        size - size of the value
        Returns:
        the parsed value
      • convert2DigitsYear

        public static int convert2DigitsYear​(int yy)
        Convert a 2 digits year to a complete year.
        Parameters:
        yy - year between 0 and 99
        Returns:
        complete year
        Since:
        12.0