org.griphyn.common.catalog.transformation
Class Database

java.lang.Object
  extended by org.griphyn.vdl.dbschema.DatabaseSchema
      extended by org.griphyn.common.catalog.transformation.Database
All Implemented Interfaces:
TransformationCatalog, Catalog

public class Database
extends DatabaseSchema
implements TransformationCatalog


Field Summary
private static Database mDatabaseTC
           
protected static LogManager mLogger
          The LogManager object which is used to log all the messages.
 
Fields inherited from class org.griphyn.vdl.dbschema.DatabaseSchema
m_dbdriver, m_dbschemaprops
 
Fields inherited from interface org.griphyn.common.catalog.Catalog
DB_ALL_PREFIX
 
Constructor Summary
private Database()
           
 
Method Summary
private  long addLogicalTr(String namespace, String name, String version)
          Adds a logical entry to the logicaltx table
private  long addPhysicalTr(String physicalname, String resourceid, TCType type, long archid)
          Adds a physical entry to the physicaltxtable
private  boolean addProfile(Profile p, long id, boolean pfn)
          Add a lfn or pfn profile to the TC
private  long addSysInfo(SysInfo system)
          Adds a system information entry into the TC.
 boolean addTCEntry(List tcentry)
          Add multiple TCEntries to the Catalog.
 boolean addTCEntry(String namespace, String name, String version, String physicalname, TCType type, String resourceid, List lfnprofiles, List pfnprofiles, SysInfo system)
          Add an single entry into the transformation catalog.
 boolean addTCEntry(String namespace, String name, String version, String physicalname, TCType type, String resourceid, List lfnprofiles, List pfnprofiles, SysInfo system, boolean write)
          Add an single entry into the transformation catalog.
 boolean addTCEntry(TransformationCatalogEntry entry)
          Add a single TCEntry to the Catalog.
 boolean addTCEntry(TransformationCatalogEntry entry, boolean write)
          Add a single TCEntry to the Catalog.
 boolean addTCLfnProfile(String namespace, String name, String version, List profiles)
          Add additional profile to a logical transformation .
 boolean addTCPfnProfile(String pfn, TCType type, String resourceid, List profiles)
          Add additional profile to a physical transformation.
private  long checkLfnPfnMap(long lfnid, long pfnid)
          Checks if a lfn,pfn exist in the map.
private  long checkProfile(String namespace, String name, String value, long id, boolean pfn)
          Checks if a given profile exists
 void close()
          Disassociate from the database driver before finishing.
private static void columnLength(String[] s, int[] count)
          Computes the maximum column lenght for pretty printing.
 boolean connect(Properties props)
           
private  boolean deleteProfile(Profile p, long id, boolean pfn)
          Delete a given lfn or pfn profile
 boolean deleteTC()
          Deletes the entire transformation catalog.
 boolean deleteTCbyLogicalName(String namespace, String name, String version, String resourceid, TCType type)
          Delete all entries in the transformation catalog for a give logical tranformation and/or on a resource and/or of a particular type
 boolean deleteTCbyPhysicalName(String physicalname, String namespace, String name, String version, String resourceid, TCType type)
          Delete all entries in the transformation catalog for pair of logical and physical transformation.
 boolean deleteTCbyResourceId(String resourceid)
          Delete all entries on a particular resource from the transformation catalog.
 boolean deleteTCbySysInfo(SysInfo sysinfo)
          Deletes entries from the catalog which have a particular system information.
 boolean deleteTCbyType(TCType type, String resourceid)
          Delete a paricular type of transformation, and/or on a particular resource
 boolean deleteTCLfnProfile(String namespace, String name, String version, List profiles)
          Delete a list of profiles or all the profiles associated with a logical transformation.
 boolean deleteTCPfnProfile(String physicalname, TCType type, String resourceid, List profiles)
          Delete a list of profiles or all the profiles associated with a pfn on a resource and of a type.
static TransformationCatalog getInstance()
           
private  long getLogicalId(String namespace, String name, String version)
          Returns the id associated with the logical transformation.
private  long getPhysicalId(String pfn, TCType type, String resourceid)
          Returns the id of the physical transformation
private  long[] getPhysicalIds(String pfn, TCType type, String resourceid)
          Returns a list of pfnid for a given pfn on any resource, and of any type.
private  long getSysInfoId(SysInfo system)
          Gets the id for the system information entry.
 List getTC()
          List all the contents of the TC in a column format.
 List getTCEntries(String namespace, String name, String version, List resourceids, TCType type)
          Returns TC entries for a particular logical transformation and/or on a number of resources and/or of a particular type.
 List getTCEntries(String namespace, String name, String version, String resourceid, TCType type)
          Returns TC entries for a particular logical transformation and/or on a particular resource and/or of a particular type.
 List getTCLfnProfiles(String namespace, String name, String version)
          Get the list of Profiles associated with a particular logical transformation.
 List getTCLogicalNames(String resourceid, TCType type)
          Get the list of LogicalNames available on a particular resource.
 String getTCMode()
          Returns the TC implementation being used
 List getTCPfnProfiles(String pfn, String resourceid, TCType type)
          Get the list of Profiles associated with a particular physical transformation.
 List getTCPhysicalNames(String namespace, String name, String version, String resourceid, TCType type)
          Get the list of PhysicalNames for a particular transformation on a site/sites for a particular type/types;
 List getTCResourceIds(String namespace, String name, String version, TCType type)
          Get the list of Resource ID's where a particular transformation may reside.
 boolean isClosed()
           
 
Methods inherited from class org.griphyn.vdl.dbschema.DatabaseSchema
cachingMakesSense, finalize, loadSchema, loadSchema, longOrNull, makeNotNull, stringOrNull
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

mLogger

protected static LogManager mLogger
The LogManager object which is used to log all the messages. It's values are set in the CPlanner class.


mDatabaseTC

private static Database mDatabaseTC
Constructor Detail

Database

private Database()
          throws ClassNotFoundException,
                 NoSuchMethodException,
                 InstantiationException,
                 IllegalAccessException,
                 InvocationTargetException,
                 SQLException,
                 IOException
Throws:
ClassNotFoundException
NoSuchMethodException
InstantiationException
IllegalAccessException
InvocationTargetException
SQLException
IOException
Method Detail

getTCEntries

public List getTCEntries(String namespace,
                         String name,
                         String version,
                         String resourceid,
                         TCType type)
                  throws Exception
Returns TC entries for a particular logical transformation and/or on a particular resource and/or of a particular type.

Specified by:
getTCEntries in interface TransformationCatalog
Parameters:
namespace - String The namespace of the logical transformation.
name - String the name of the logical transformation.
version - String The version of the logical transformation.
resourceid - String The resourceid where the transformation is located. If NULL it returns all resources.
type - TCType The type of the transformation to search for. If NULL it returns all types.
Returns:
List Returns a list of TCEntry objects containing the corresponding entries from the TC. Returns null if no entry found. The profiles returned are lfn profiles, followed by pfn profiles. The code does not check for similar keys between lfn and pfn profiles and all profiles are kept
Throws:
Exception
See Also:
TCType, TransformationCatalogEntry

getTCEntries

public List getTCEntries(String namespace,
                         String name,
                         String version,
                         List resourceids,
                         TCType type)
                  throws Exception
Returns TC entries for a particular logical transformation and/or on a number of resources and/or of a particular type.

Specified by:
getTCEntries in interface TransformationCatalog
Parameters:
namespace - String The namespace of the logical transformation.
name - String the name of the logical transformation.
version - String The version of the logical transformation.
resourceids - List The List resourceid where the transformation is located. If NULL it returns all resources.
type - TCType The type of the transformation to search for. If NULL it returns all types.
Returns:
List Returns a list of TCEntry objects containing the corresponding entries from the TC. Returns null if no entry found.
Throws:
Exception
See Also:
TCType, TransformationCatalogEntry

getTC

public List getTC()
           throws Exception
List all the contents of the TC in a column format.

Specified by:
getTC in interface TransformationCatalog
Returns:
List Returns a List of String Arrays. Each string array contains the resource, lfn, pfn, type, sysinfo and profiles. The last entry in the list is an array of integers which contain the column lengths for pretty print.
Throws:
Exception

getTCResourceIds

public List getTCResourceIds(String namespace,
                             String name,
                             String version,
                             TCType type)
                      throws Exception
Get the list of Resource ID's where a particular transformation may reside.

Specified by:
getTCResourceIds in interface TransformationCatalog
Parameters:
namespace - String The namespace of the transformation to search for.
name - String The name of the transformation to search for.
version - String The version of the transformation to search for.
type - TCType The type of the transformation to search for.
(Enumerated type includes SOURCE, STATIC-BINARY, DYNAMIC-BINARY, PACMAN, INSTALLED, SCRIPT)
If NULL it returns all types.
Returns:
List Returns a list of Resource Id's as strings. Returns NULL if no results found.
Throws:
Exception - NotImplementedException if not implemented
See Also:
TCType

getTCPhysicalNames

public List getTCPhysicalNames(String namespace,
                               String name,
                               String version,
                               String resourceid,
                               TCType type)
                        throws Exception
Get the list of PhysicalNames for a particular transformation on a site/sites for a particular type/types;

Specified by:
getTCPhysicalNames in interface TransformationCatalog
Parameters:
namespace - String The namespace of the transformation to search for.
name - String The name of the transformation to search for.
version - String The version of the transformation to search for.
resourceid - String The id of the resource on which you want to search.
If NULL then returns entries on all resources
type - TCType The type of the transformation to search for.
(Enumerated type includes source, binary, dynamic-binary, pacman, installed)
If NULL then returns entries of all types.
Returns:
List Returns a list of String Arrays. Each array contains the resourceid, the physical transformation, the type of the tr and the systeminfo. The last entry in the List is a int array containing t he column lengths for pretty print. Returns NULL if no results found.
Throws:
Exception - NotImplementedException if not implemented.
See Also:
TCType, SysInfo

getTCLogicalNames

public List getTCLogicalNames(String resourceid,
                              TCType type)
                       throws Exception
Get the list of LogicalNames available on a particular resource.

Specified by:
getTCLogicalNames in interface TransformationCatalog
Parameters:
resourceid - String The id of the resource on which you want to search
type - TCType The type of the transformation to search for.
(Enumerated type includes source, binary, dynamic-binary, pacman, installed)
If NULL then return logical name for all types.
Returns:
List Returns a list of String Arrays. Each array contains the resourceid, logical transformation in the format namespace::name:version and type. The last entry in the list is an array of integers specifying the column length for pretty print. Returns NULL if no results found.
Throws:
Exception - NotImpementedException if not implemented

getTCLfnProfiles

public List getTCLfnProfiles(String namespace,
                             String name,
                             String version)
                      throws Exception
Get the list of Profiles associated with a particular logical transformation.

Specified by:
getTCLfnProfiles in interface TransformationCatalog
Parameters:
namespace - String The namespace of the transformation to search for.
name - String The name of the transformation to search for.
version - String The version of the transformation to search for.
Returns:
List Returns a list of Profile Objects containing profiles assocaited with the transformation. Returns NULL if no profiles found.
Throws:
Exception - NotImplementedException if not implemented.
See Also:
Profile

getTCPfnProfiles

public List getTCPfnProfiles(String pfn,
                             String resourceid,
                             TCType type)
                      throws Exception
Get the list of Profiles associated with a particular physical transformation.

Specified by:
getTCPfnProfiles in interface TransformationCatalog
Parameters:
pfn - The physical file name to search the transformation by.
resourceid - String The id of the resource on which you want to search.
type - TCType The type of the transformation to search for.
(Enumerated type includes source, binary, dynamic-binary, pacman, installed)
Returns:
List Returns a list of Profile Objects containing profiles assocaited with the transformation. Returns NULL if no profiless found.
Throws:
Exception - NotImplementedException if not implemented.
See Also:
Profile

addTCEntry

public boolean addTCEntry(List tcentry)
                   throws Exception
Add multiple TCEntries to the Catalog.

Specified by:
addTCEntry in interface TransformationCatalog
Parameters:
tcentry - List Takes a list of TCEntry objects as input
Returns:
boolean Return true if succesful, false if error. Exception is thrown when error occurs.
Throws:
Exception
See Also:
TransformationCatalogEntry

addTCEntry

public boolean addTCEntry(TransformationCatalogEntry entry)
                   throws Exception
Add a single TCEntry to the Catalog. Exception is thrown when error occurs.

Specified by:
addTCEntry in interface TransformationCatalog
Parameters:
entry - a single TransformationCatalogEntry object as input.
Returns:
boolean Return true if succesful, false if error.
Throws:
Exception
See Also:
TransformationCatalogEntry

addTCEntry

public boolean addTCEntry(TransformationCatalogEntry entry,
                          boolean write)
                   throws Exception
Add a single TCEntry to the Catalog. Exception is thrown when error occurs. This method is a hack and wont commit the additions to the backend catalog

Specified by:
addTCEntry in interface TransformationCatalog
Parameters:
entry - a single TransformationCatalogEntry object as input.
write - boolean to commit additions to backend catalog.
Returns:
boolean Return true if succesful, false if error.
Throws:
Exception
See Also:
TransformationCatalogEntry

addTCEntry

public boolean addTCEntry(String namespace,
                          String name,
                          String version,
                          String physicalname,
                          TCType type,
                          String resourceid,
                          List lfnprofiles,
                          List pfnprofiles,
                          SysInfo system)
                   throws Exception
Add an single entry into the transformation catalog.

Specified by:
addTCEntry in interface TransformationCatalog
Parameters:
namespace - String The namespace of the transformation to be added (Can be null)
name - String The name of the transformation to be added.
version - String The version of the transformation to be added. (Can be null)
physicalname - String The physical name/location of the transformation to be added.
type - TCType The type of the physical transformation.
resourceid - String The resource location id where the transformation is located.
lfnprofiles - List The List of Profile objects associated with a Logical Transformation. (can be null)
pfnprofiles - List The List of Profile objects associated with a Physical Transformation. (can be null)
system - SysInfo The System information associated with a physical transformation.
Returns:
boolean Returns true if succesfully added, returns false if error and throws exception.
Throws:
Exception
See Also:
TransformationCatalogEntry, SysInfo, Profile

addTCEntry

public boolean addTCEntry(String namespace,
                          String name,
                          String version,
                          String physicalname,
                          TCType type,
                          String resourceid,
                          List lfnprofiles,
                          List pfnprofiles,
                          SysInfo system,
                          boolean write)
                   throws Exception
Add an single entry into the transformation catalog.

Parameters:
namespace - String The namespace of the transformation to be added (Can be null)
name - String The name of the transformation to be added.
version - String The version of the transformation to be added. (Can be null)
physicalname - String The physical name/location of the transformation to be added.
type - TCType The type of the physical transformation.
resourceid - String The resource location id where the transformation is located.
lfnprofiles - List The List of Profile objects associated with a Logical Transformation. (can be null)
pfnprofiles - List The List of Profile objects associated with a Physical Transformation. (can be null)
system - SysInfo The System information associated with a physical transformation.
write - boolean to commit changes to the backend catalog
Returns:
boolean Returns true if succesfully added, returns false if error and throws exception.
Throws:
Exception
See Also:
TransformationCatalogEntry, SysInfo, Profile

addTCLfnProfile

public boolean addTCLfnProfile(String namespace,
                               String name,
                               String version,
                               List profiles)
                        throws Exception
Add additional profile to a logical transformation .

Specified by:
addTCLfnProfile in interface TransformationCatalog
Parameters:
namespace - String The nsamespace of the transformation to be added. (can be null)
name - String The name of the transformation to be added.
version - String The version of the transformation to be added. (can be null)
profiles - List The List of Profile objects that are to be added to the transformation.
Returns:
boolean Returns true if success, false if error.
Throws:
Exception
See Also:
Profile

addTCPfnProfile

public boolean addTCPfnProfile(String pfn,
                               TCType type,
                               String resourceid,
                               List profiles)
                        throws Exception
Add additional profile to a physical transformation.

Specified by:
addTCPfnProfile in interface TransformationCatalog
Parameters:
pfn - String The physical name of the transformation
type - TCType The type of transformation that the profile is associated with.
resourceid - String The resource on which the physical transformation exists
profiles - List The List of Profile objects that are to be added to the transformation.
Returns:
boolean Returns true for success, false for error.
Throws:
Exception
See Also:
Profile

deleteTCbyLogicalName

public boolean deleteTCbyLogicalName(String namespace,
                                     String name,
                                     String version,
                                     String resourceid,
                                     TCType type)
                              throws Exception
Delete all entries in the transformation catalog for a give logical tranformation and/or on a resource and/or of a particular type

Specified by:
deleteTCbyLogicalName in interface TransformationCatalog
Parameters:
namespace - String The namespace of the transformation to be added. (can be null)
name - String The name of the transformation to be added.
version - String The version of the transformation to be added. ( can be null)
resourceid - String The resource id for which the transformation is to be deleted. If NULL then transformation on all resource are deleted
type - TCType The type of the transformation. If NULL then all types are deleted for the transformation.
Returns:
boolean Returns true if success , false if there is any error.
Throws:
Exception
See Also:
TCType

deleteTCbyPhysicalName

public boolean deleteTCbyPhysicalName(String physicalname,
                                      String namespace,
                                      String name,
                                      String version,
                                      String resourceid,
                                      TCType type)
                               throws Exception
Delete all entries in the transformation catalog for pair of logical and physical transformation.

Specified by:
deleteTCbyPhysicalName in interface TransformationCatalog
Parameters:
physicalname - String The physical name of the transformation
namespace - String The namespace assocaited in the logical name of the transformation.
name - String The name of the logical transformation.
version - String The version number of the logical transformation.
resourceid - String The resource on which the transformation is to be deleted. If NULL then it searches all the resource id.
type - TCType The type of transformation. If NULL then it search and deletes entries for all types.
Returns:
boolean Returns true if sucess, false if any error occurs.
Throws:
Exception
See Also:
TCType

deleteTCbySysInfo

public boolean deleteTCbySysInfo(SysInfo sysinfo)
                          throws Exception
Deletes entries from the catalog which have a particular system information.

Specified by:
deleteTCbySysInfo in interface TransformationCatalog
Parameters:
sysinfo - SysInfo The System Information by which you want to delete
Returns:
boolean Returns true for success, false if any error occurs.
Throws:
Exception
See Also:
SysInfo

deleteTCbyType

public boolean deleteTCbyType(TCType type,
                              String resourceid)
                       throws Exception
Delete a paricular type of transformation, and/or on a particular resource

Specified by:
deleteTCbyType in interface TransformationCatalog
Parameters:
type - TCType The type of the transformation
resourceid - String The resource on which the transformation exists. If NULL then that type of transformation is deleted from all the resources.
Returns:
boolean Returns true if success, false if any error occurs.
Throws:
Exception
See Also:
TCType

deleteTCbyResourceId

public boolean deleteTCbyResourceId(String resourceid)
                             throws Exception
Delete all entries on a particular resource from the transformation catalog.

Specified by:
deleteTCbyResourceId in interface TransformationCatalog
Parameters:
resourceid - String The resource which you want to remove.
Returns:
boolean Returns true if successm false if any error occurs.
Throws:
Exception

deleteTC

public boolean deleteTC()
                 throws Exception
Deletes the entire transformation catalog. CLEAN............. USE WITH CAUTION.

Specified by:
deleteTC in interface TransformationCatalog
Returns:
boolean Returns true if delete succeeds, false if any error occurs.
Throws:
Exception

deleteTCPfnProfile

public boolean deleteTCPfnProfile(String physicalname,
                                  TCType type,
                                  String resourceid,
                                  List profiles)
                           throws Exception
Delete a list of profiles or all the profiles associated with a pfn on a resource and of a type.

Specified by:
deleteTCPfnProfile in interface TransformationCatalog
Parameters:
physicalname - String The physical name of the transformation.
type - TCType The type of the transformation.
resourceid - String The resource of the transformation.
profiles - List The list of profiles to be deleted. If NULL then all profiles for that pfn+resource+type are deleted.
Returns:
boolean Returns true if success, false if any error occurs.
Throws:
Exception
See Also:
Profile

deleteTCLfnProfile

public boolean deleteTCLfnProfile(String namespace,
                                  String name,
                                  String version,
                                  List profiles)
                           throws Exception
Delete a list of profiles or all the profiles associated with a logical transformation.

Specified by:
deleteTCLfnProfile in interface TransformationCatalog
Parameters:
namespace - String The namespace of the logical transformation.
name - String The name of the logical transformation.
version - String The version of the logical transformation.
profiles - List The List of profiles to be deleted. If NULL then all profiles for the logical transformation are deleted.
Returns:
boolean Returns true if success, false if any error occurs.
Throws:
Exception
See Also:
Profile

getInstance

public static TransformationCatalog getInstance()

getTCMode

public String getTCMode()
Returns the TC implementation being used

Specified by:
getTCMode in interface TransformationCatalog
Returns:
String

close

public void close()
Description copied from class: DatabaseSchema
Disassociate from the database driver before finishing. Mind that performing this action may throw NullPointerException in later stages!

Overrides:
close in class DatabaseSchema

connect

public boolean connect(Properties props)

isClosed

public boolean isClosed()

getLogicalId

private long getLogicalId(String namespace,
                          String name,
                          String version)
                   throws Exception
Returns the id associated with the logical transformation.

Parameters:
namespace - String
name - String
version - String
Returns:
long Returns -1 if entry does not exist
Throws:
Exception

checkLfnPfnMap

private long checkLfnPfnMap(long lfnid,
                            long pfnid)
                     throws Exception
Checks if a lfn,pfn exist in the map.

Parameters:
lfnid - long
pfnid - long
Returns:
long Returns 1 if exists, -1 if not exists
Throws:
Exception

checkProfile

private long checkProfile(String namespace,
                          String name,
                          String value,
                          long id,
                          boolean pfn)
                   throws Exception
Checks if a given profile exists

Parameters:
namespace - String
name - String
value - String
id - long
pfn - boolean
Returns:
long Returns 1 if exists , -1 if does not exist.
Throws:
Exception

getSysInfoId

private long getSysInfoId(SysInfo system)
                   throws Exception
Gets the id for the system information entry.

Parameters:
system - SysInfo
Returns:
long Returns -1 if it does not exist
Throws:
Exception
See Also:
SysInfo

addSysInfo

private long addSysInfo(SysInfo system)
                 throws Exception
Adds a system information entry into the TC.

Parameters:
system - SysInfo
Returns:
boolean Returns true if success, false if error occurs.
Throws:
Exception

addLogicalTr

private long addLogicalTr(String namespace,
                          String name,
                          String version)
                   throws Exception
Adds a logical entry to the logicaltx table

Parameters:
namespace - String The namespace of the transformation
name - String The name of the transformation
version - String The version of the transformation
Returns:
long The position in table at which the entry is added. If there is an error -1 is returned.
Throws:
Exception

addPhysicalTr

private long addPhysicalTr(String physicalname,
                           String resourceid,
                           TCType type,
                           long archid)
                    throws Exception
Adds a physical entry to the physicaltxtable

Parameters:
physicalname - String The physical name of the transformation
resourceid - String The resource on which the transformation exists
type - TCType The type of the transformation
archid - long The architecture id from the sysinfo table for the tr.
Returns:
long The position in the physicaltx table at which the entry is stored. If there is an error -1 is returned.
Throws:
Exception

addProfile

private boolean addProfile(Profile p,
                           long id,
                           boolean pfn)
                    throws Exception
Add a lfn or pfn profile to the TC

Parameters:
p - Profile The profile to be added
id - long The lfn or pfn id to which the profile is associated.
pfn - boolean if true entry is added to the pfn, false to the lfn.
Returns:
boolean Returns true if success, false if error occurs.
Throws:
Exception

deleteProfile

private boolean deleteProfile(Profile p,
                              long id,
                              boolean pfn)
                       throws Exception
Delete a given lfn or pfn profile

Parameters:
p - Profile The profile to be deleted
id - long The lfn or pfnid with which the profile is associated
pfn - boolean If true the pfn profile is deleted, if false lfn profile is deleted
Returns:
boolean Returns true if success, false if any error occurs.
Throws:
Exception

getPhysicalId

private long getPhysicalId(String pfn,
                           TCType type,
                           String resourceid)
                    throws Exception
Returns the id of the physical transformation

Parameters:
pfn - String the physical transformation
type - TCType The type of the transformation
resourceid - String The resource on which the transformation exists.
Returns:
long Returns -1 if entry does not exist.
Throws:
Exception

getPhysicalIds

private long[] getPhysicalIds(String pfn,
                              TCType type,
                              String resourceid)
                       throws Exception
Returns a list of pfnid for a given pfn on any resource, and of any type.

Parameters:
pfn - String The physical transformation to search for.
type - TCType The type to search for. If NULL then all types are searched.
resourceid - String The resource to search for. If NULL then all resources are searched.
Returns:
long[] Returns -1 is no entry exist.
Throws:
Exception

columnLength

private static void columnLength(String[] s,
                                 int[] count)
Computes the maximum column lenght for pretty printing.

Parameters:
s - String[]
count - int[]


Copyright © 2007 The University of Southern California. All Rights Reserved.