/** * Loads a set of region metadata from an arbitrary {@code InputStream} * containing an XML file. * * @param stream the stream to load from * @return the loaded region metadata * @throws IOException on error reading from the stream */ public static RegionMetadata load (final InputStream stream) throws IOException { return RegionMetadataParser.parse(stream); }
/** * Loads a set of region metadata by parsing the given file. * * @param file the region metadata to load from * @throws IOException any error while reading from file. */ public static RegionMetadata load (final File file) throws IOException { return RegionMetadataParser.parse(new BufferedInputStream(new FileInputStream(file))); }
/** * Loads a set of region metadata by downloading an XML file from the * given URI and parsing it. * * @param uri the uri of the XML file to parse * @param config configuration for the HTTP client to use to fetch the file * @throws IOException any error while reading data. */ public static RegionMetadata load (final URI uri, final ClientConfiguration config) throws IOException { return RegionMetadataParser.parse( RuntimeHttpUtils.fetchFile(uri, config)); }
/** * Loads a set of region metadata from an arbitrary {@code InputStream} * containing an XML file. * * @param stream the stream to load from * @return the loaded region metadata * @throws IOException on error reading from the stream */ public static RegionMetadata load (final InputStream stream) throws IOException { return RegionMetadataParser.parse(stream); }
/** * Loads a set of region metadata by parsing the given file. * * @param file the region metadata to load from * @throws IOException any error while reading from file. */ public static RegionMetadata load (final File file) throws IOException { return RegionMetadataParser.parse(new BufferedInputStream(new FileInputStream(file))); }
/** * Loads a set of region metadata by downloading an XML file from the * given URI and parsing it. * * @param uri the uri of the XML file to parse * @param config configuration for the HTTP client to use to fetch the file * @throws IOException any error while reading data. */ public static RegionMetadata load (final URI uri, final ClientConfiguration config) throws IOException { return RegionMetadataParser.parse( RuntimeHttpUtils.fetchFile(uri, config)); }
/** * Loads a set of region metadata from an arbitrary {@code InputStream} * containing an XML file. * * @param stream the stream to load from * @return the loaded region metadata * @throws IOException on error reading from the stream */ public static RegionMetadata load (final InputStream stream) throws IOException { return RegionMetadataParser.parse(stream); }
/** * Loads a set of region metadata by parsing the given file. * * @param file the region metadata to load from * @throws IOException any error while reading from file. */ public static RegionMetadata load (final File file) throws IOException { return RegionMetadataParser.parse(new BufferedInputStream(new FileInputStream(file))); }
/** * Loads a set of region metadata by downloading an XML file from the * given URI and parsing it. * * @param uri the uri of the XML file to parse * @param config configuration for the HTTP client to use to fetch the file * @throws IOException any error while reading data. */ public static RegionMetadata load (final URI uri, final ClientConfiguration config) throws IOException { return RegionMetadataParser.parse( RuntimeHttpUtils.fetchFile(uri, config)); }