gov.nasa.pds.citool
Class CIToolIngester

java.lang.Object
  extended by gov.nasa.pds.citool.CIToolIngester

public class CIToolIngester
extends Object


Field Summary
static List<CatalogObject> catObjs
           
static Map<String,String> refInfo
           
static boolean targetAvailable
           
 
Constructor Summary
CIToolIngester(IngestReport report)
           
 
Method Summary
 boolean compare(URL source, URL target)
          Perform a comparison between 2 files.
 void getFilesFromStorageService(List<String> requiredFiles)
           
 org.apache.oodt.cas.filemgr.structs.Product getProductFromStorageService(String fileName)
           
 Map<String,String> getTargetInfos(String targetName)
           
 void ingest(Target target, boolean recurse)
          Ingest catalog file(s).
 gov.nasa.pds.tools.label.Label parse(URL url)
          Method to parse the PDS catalog file
 void parseLabel(URL source)
          Parse a label
 void parseLabels(List<URL> sources)
          Ingest catalog files from the given directories.
 void process()
           
 void setRegistryUrl(String registryUrl)
           
 void setSecurity(gov.nasa.pds.registry.client.SecurityContext securityContext, String username, String password)
          Sets the security.
 void setStorageUrl(String storageUrl)
           
 void setTransportUrl(String transportUrl)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

catObjs

public static List<CatalogObject> catObjs

refInfo

public static Map<String,String> refInfo

targetAvailable

public static boolean targetAvailable
Constructor Detail

CIToolIngester

public CIToolIngester(IngestReport report)
Method Detail

setRegistryUrl

public void setRegistryUrl(String registryUrl)

setStorageUrl

public void setStorageUrl(String storageUrl)

setTransportUrl

public void setTransportUrl(String transportUrl)

setSecurity

public void setSecurity(gov.nasa.pds.registry.client.SecurityContext securityContext,
                        String username,
                        String password)
Sets the security.

Parameters:
securityContext - An object containing the keystore information.
username - Username of an authorized user.
password - Password associated with the given username.
Throws:
RegistryClientException - If an error occurred while initializing the security.

ingest

public void ingest(Target target,
                   boolean recurse)
            throws Exception
Ingest catalog file(s).

Parameters:
target - URL of the target (directory or file)
Throws:
Exception

parseLabel

public void parseLabel(URL source)
Parse a label

Parameters:
source - URL of the catalog file.

process

public void process()

getFilesFromStorageService

public void getFilesFromStorageService(List<String> requiredFiles)

getProductFromStorageService

public org.apache.oodt.cas.filemgr.structs.Product getProductFromStorageService(String fileName)

getTargetInfos

public Map<String,String> getTargetInfos(String targetName)

parseLabels

public void parseLabels(List<URL> sources)
Ingest catalog files from the given directories.

Parameters:
sources - URL of the directory of catalog files

parse

public gov.nasa.pds.tools.label.Label parse(URL url)
Method to parse the PDS catalog file

Parameters:
url - URL of the pds catalog file
Returns:
a Label object

compare

public boolean compare(URL source,
                       URL target)
Perform a comparison between 2 files.

Parameters:
source - URL of the source file.
target - URL of the target file.
Throws:
gov.nasa.pds.tools.LabelParserException
IOException


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