Package thredds.catalog.parser.jdom

Examples of thredds.catalog.parser.jdom.InvCatalogFactory10


  static Document convertCatalogToDocument( InvCatalog catalog )
  {
    InvCatalogFactory fac = InvCatalogFactory.getDefaultFactory( false );
    InvCatalogConvertIF converter = fac.getCatalogConverter( XMLEntityResolver.CATALOG_NAMESPACE_10 );
    InvCatalogFactory10 fac10 = (InvCatalogFactory10) converter;

    return fac10.writeCatalog( (InvCatalogImpl) catalog );
  }
View Full Code Here


        this.catFactory.writeXML( (InvCatalogImpl) catalog, outFileName );
      }
      else
      {
        // Override default output catalog version. (kludge for IDV backward compatibility)
        InvCatalogFactory10 fac10 = (InvCatalogFactory10) this.catFactory.getCatalogConverter( XMLEntityResolver.CATALOG_NAMESPACE_10 );
        fac10.setVersion( this.catalog.getVersion() );
        BufferedOutputStream osCat = new BufferedOutputStream( new FileOutputStream( outFileName ) );
        fac10.writeXML( (InvCatalogImpl) catalog, osCat );
        osCat.close();
      }

      log.debug( "writeCatalog(): catalog written to " + outFileName + "." );
    }
View Full Code Here

    private volatile int hashCode = 0; // Bloch, item 8

    public void toXML(java.io.OutputStream out) throws IOException {
      // hack, hack
      InvCatalogFactory10 converter = new InvCatalogFactory10();
      Element elem = converter.writeGeospatialCoverage(this);
      //XMLOutputter outputter = new XMLOutputter("  ", true);
      XMLOutputter fmt = new XMLOutputter(Format.getPrettyFormat());
      fmt.output(elem, out);
    }
View Full Code Here

TOP

Related Classes of thredds.catalog.parser.jdom.InvCatalogFactory10

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.