gov.nasa.pds.search.core.extractor
Class RegistryExtractor

java.lang.Object
  extended by gov.nasa.pds.search.core.extractor.RegistryExtractor

public class RegistryExtractor
extends Object

Utilizes XML configuration files to extract data from the Registry Service and create XML files for each Product containing the raw data found in the Registry.

Author:
jpadams

Constructor Summary
RegistryExtractor(String outDir, boolean clean)
          Object initializer method with an output directory and clean boolean parameter specified.
 
Method Summary
 void close()
          Complete the output for the log and flush/close the PrintWriter.
 File getConfDir()
           
 Set<String> getProductClassList()
          Return the set of product classes to be parsed, as denoted in the product-classes.txt configuration file.
 int getQueryMax()
           
 String getRegistryUrl()
           
 void run()
          Driver method for extraction of data for all classes to be included in catalog.
 void setConfDir(File confDir)
           
 void setQueryMax(int queryMax)
           
 void setRegistryUrl(String registryUrl)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RegistryExtractor

public RegistryExtractor(String outDir,
                         boolean clean)
                  throws ProductClassException
Object initializer method with an output directory and clean boolean parameter specified.

Parameters:
outDir -
clean -
Throws:
ProductClassException - thrown when directories cannot be created
Method Detail

close

public final void close()
Complete the output for the log and flush/close the PrintWriter.


run

public final void run()
               throws ProductClassException,
                      IOException
Driver method for extraction of data for all classes to be included in catalog.

Throws:
ProductClassException - thrown if error found during registry queries
IOException - thrown if files cannot be created

getProductClassList

public Set<String> getProductClassList()
                                throws ProductClassException
Return the set of product classes to be parsed, as denoted in the product-classes.txt configuration file.

Returns:
list of product class properties
Throws:
ProductClassException - thrown when error loading properties file

getConfDir

public final File getConfDir()
Returns:
the confDir

setConfDir

public final void setConfDir(File confDir)
Parameters:
confDir - the confDir to set

getRegistryUrl

public final String getRegistryUrl()
Returns:
the registryUrl

setRegistryUrl

public final void setRegistryUrl(String registryUrl)
Parameters:
registryUrl - the registryUrl to set

getQueryMax

public final int getQueryMax()
Returns:
the queryMax

setQueryMax

public final void setQueryMax(int queryMax)
Parameters:
queryMax - the queryMax to set


Copyright © 2010-2012 Planetary Data System. All Rights Reserved.