Class FDSNStationXML


  • public class FDSNStationXML
    extends java.lang.Object
    • Constructor Detail

      • FDSNStationXML

        public FDSNStationXML​(javax.xml.stream.XMLEventReader reader)
                       throws javax.xml.stream.XMLStreamException,
                              StationXMLException
        Throws:
        javax.xml.stream.XMLStreamException
        StationXMLException
    • Method Detail

      • getSource

        public java.lang.String getSource()
      • setSource

        public void setSource​(java.lang.String source)
      • getSender

        public java.lang.String getSender()
      • setSender

        public void setSender​(java.lang.String sender)
      • getModule

        public java.lang.String getModule()
      • setModule

        public void setModule​(java.lang.String module)
      • getCreated

        public java.lang.String getCreated()
      • setCreated

        public void setCreated​(java.lang.String created)
      • findChannelBySID

        public static Channel findChannelBySID​(java.util.Map<Network,​java.util.List<Station>> networks,
                                               FDSNSourceId sid,
                                               java.time.Instant time)
        Finds the channel with the given FDSN SourceId that was active at the given time. Usually the networks Map comes from extractAllNetworks().
        Parameters:
        networks - map of network to list of stations to search.
        sid - FDSN SourceId to match
        time - time to overlap
        Returns:
        Channel if found or null if not
      • closeReader

        public void closeReader()
      • getXmlSchemaLocation

        public java.lang.String getXmlSchemaLocation()
      • setXmlSchemaLocation

        public void setXmlSchemaLocation​(java.lang.String xmlns)
      • getReader

        public javax.xml.stream.XMLEventReader getReader()
      • getModuleUri

        public java.lang.String getModuleUri()
      • getSchemaVersion

        public java.lang.String getSchemaVersion()
      • getLogger

        public static org.slf4j.Logger getLogger()
      • checkSchemaVersion

        public boolean checkSchemaVersion()
      • setResponse

        public void setResponse​(org.apache.hc.core5.http.ClassicHttpResponse response)
      • findInternalSchema

        public static java.net.URL findInternalSchema()
      • printSchema

        public static void printSchema​(java.io.OutputStream out)
                                throws java.io.IOException
        Throws:
        java.io.IOException
      • loadStationXML

        public static FDSNStationXML loadStationXML​(java.io.Reader streamReader)
                                             throws javax.xml.stream.XMLStreamException,
                                                    java.io.IOException,
                                                    SeisFileException
        Throws:
        javax.xml.stream.XMLStreamException
        java.io.IOException
        SeisFileException
      • loadStationXML

        public static FDSNStationXML loadStationXML​(java.io.InputStream stream)
                                             throws javax.xml.stream.XMLStreamException,
                                                    java.io.IOException,
                                                    SeisFileException
        Throws:
        javax.xml.stream.XMLStreamException
        java.io.IOException
        SeisFileException
      • loadStationXML

        public static FDSNStationXML loadStationXML​(java.lang.String filename)
                                             throws javax.xml.stream.XMLStreamException,
                                                    java.io.IOException,
                                                    SeisFileException
        Throws:
        javax.xml.stream.XMLStreamException
        java.io.IOException
        SeisFileException
      • loadStationXML

        public static FDSNStationXML loadStationXML​(java.io.File filename)
                                             throws javax.xml.stream.XMLStreamException,
                                                    java.io.IOException,
                                                    SeisFileException
        Throws:
        javax.xml.stream.XMLStreamException
        java.io.IOException
        SeisFileException