wt.introspection
Class WTIntrospectorTest

java.lang.Object
  extended bywt.introspection.WTIntrospectorTest
All Implemented Interfaces:
Runnable

public class WTIntrospectorTest
extends Object
implements Runnable

WTIntrospectorTest is a test utility for the Introspection package.


  


Supported API: false

Extendable: false

See Also:
WTIntrospector, ClassInfo, LinkInfo, AttributeDescriptor

Field Summary
private  int classCounter
           
private  String classname
           
(package private) static Class DATASTORE_ELEMENT
           
private  String directory
           
(package private) static Class ENUMERATED_TYPE
           
private  String instance
           
private static MappedRegistry modelRegistry
           
private static boolean MULTI_THREADED
           
private  OutputFile out
           
(package private) static Class PERSISTENT_CLASS
           
private  boolean printReport
           
(package private) static Class WINDCHILL_CLASS
           
 
Constructor Summary
private WTIntrospectorTest(String printReport, String instance, String directory)
           
 
Method Summary
 void executeApp(String classNames)
           
protected  void exerciseAttributeInfo(AttributeDescriptor[] attrs)
          Exercise the methods of the AttributeDescriptors.
protected  void exerciseClassInfo(ClassInfo classInfo)
          Exercise the methods of the ClassInfo class.
protected  void exerciseColumnInfo(ColumnDescriptor attr)
          Exercise the methods of the ColumnDescriptor.
protected  void exerciseColumnInfos(ColumnDescriptor[] attrs)
          Exercise the methods of the ColumnDescriptors.
protected  void exerciseCriteria(CriteriaDescriptor criteria)
          Exercise the methods of the CriteriaDescriptor.
protected  void exerciseCriterion(CriteriaDescriptor[] criterion)
          Exercise the methods of the CriteriaDescriptors.
protected  void exerciseDatabaseInfo(DatabaseInfo dbInfo)
          Exercise the methods of the ClassInfo class.
protected  void exerciseLinkInfo(LinkInfo linkInfo)
          Exercise the methods of the LinkInfo class.
protected  void exercisePropertyInfo(PropertyDescriptor property)
          Exercise the methods of the PropertyDescriptor.
protected  void exercisePropertyInfos(PropertyDescriptor[] properties)
          Exercise the methods of the PropertyDescriptors.
protected  void exerciseRoleInfo(RoleDescriptor role)
          Exercise the methods of the RoleDescriptor.
protected  void exerciseRoleInfos(RoleDescriptor[] roles)
          Exercise an array of RoleDescriptors.
private  boolean hasInfo(String classname)
           
static void main(String[] args)
           
protected  void print(Enumeration collection)
          Print the values of a Enumerations.
protected  void print(Object[] array)
          Print the values of a Array.
protected  void processPackage(String pckg)
           
protected  void processRegistry()
           
private  void report(String line)
           
 void report(String classNames, boolean ignoreProblems)
          Exercise the methods of the classes in the Introspector package.
 void run()
          run method comment.
 void setInstance(String instance)
           
 void setPrintReport(boolean on)
           
static String sqlType(int typeValue)
           
static String tail(String aString, char aSeparator, int level)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

out

private OutputFile out

instance

private String instance

classname

private String classname

directory

private String directory

printReport

private boolean printReport

classCounter

private int classCounter

MULTI_THREADED

private static final boolean MULTI_THREADED

modelRegistry

private static MappedRegistry modelRegistry

PERSISTENT_CLASS

static final Class PERSISTENT_CLASS

WINDCHILL_CLASS

static final Class WINDCHILL_CLASS

ENUMERATED_TYPE

static final Class ENUMERATED_TYPE

DATASTORE_ELEMENT

static final Class DATASTORE_ELEMENT
Constructor Detail

WTIntrospectorTest

private WTIntrospectorTest(String printReport,
                           String instance,
                           String directory)
Method Detail

executeApp

public void executeApp(String classNames)
                throws Exception
Throws:
Exception

exerciseAttributeInfo

protected void exerciseAttributeInfo(AttributeDescriptor[] attrs)
Exercise the methods of the AttributeDescriptors.

Parameters:
attrs - is array of descriptors to exercise

exerciseClassInfo

protected void exerciseClassInfo(ClassInfo classInfo)
Exercise the methods of the ClassInfo class.

Parameters:
classInfo - is the ClassInfo instance to exercise

exerciseColumnInfo

protected void exerciseColumnInfo(ColumnDescriptor attr)
Exercise the methods of the ColumnDescriptor.

Parameters:
attr - is a descriptor to exercise

exerciseColumnInfos

protected void exerciseColumnInfos(ColumnDescriptor[] attrs)
Exercise the methods of the ColumnDescriptors.

Parameters:
attrs - is array of descriptors to exercise

exerciseCriteria

protected void exerciseCriteria(CriteriaDescriptor criteria)
Exercise the methods of the CriteriaDescriptor.

Parameters:
criteria - is the descriptor to exercise

exerciseCriterion

protected void exerciseCriterion(CriteriaDescriptor[] criterion)
Exercise the methods of the CriteriaDescriptors.

Parameters:
criterion - is array of descriptors to exercise

exerciseDatabaseInfo

protected void exerciseDatabaseInfo(DatabaseInfo dbInfo)
Exercise the methods of the ClassInfo class.


exerciseLinkInfo

protected void exerciseLinkInfo(LinkInfo linkInfo)
Exercise the methods of the LinkInfo class.

Parameters:
linkInfo - is the LinkInfo instance to exercise

exercisePropertyInfo

protected void exercisePropertyInfo(PropertyDescriptor property)
Exercise the methods of the PropertyDescriptor.

Parameters:
property - is a descriptor to exercise

exercisePropertyInfos

protected void exercisePropertyInfos(PropertyDescriptor[] properties)
Exercise the methods of the PropertyDescriptors.

Parameters:
properties - is array of descriptors to exercise

exerciseRoleInfo

protected void exerciseRoleInfo(RoleDescriptor role)
                         throws WTIntrospectionException
Exercise the methods of the RoleDescriptor.

Parameters:
role - is role descriptor to exercise
Throws:
WTIntrospectionException

exerciseRoleInfos

protected void exerciseRoleInfos(RoleDescriptor[] roles)
                          throws WTIntrospectionException
Exercise an array of RoleDescriptors.

Parameters:
roles - is array of descriptors to exercise
Throws:
WTIntrospectionException

main

public static void main(String[] args)

print

protected void print(Object[] array)
Print the values of a Array.


print

protected void print(Enumeration collection)
Print the values of a Enumerations.

Parameters:
collection - is the collection to print

processPackage

protected void processPackage(String pckg)

processRegistry

protected void processRegistry()

report

private void report(String line)

report

public void report(String classNames,
                   boolean ignoreProblems)
Exercise the methods of the classes in the Introspector package.

Parameters:
classNames - is a comma delimited list of fully qualified classnames to report on

run

public void run()
run method comment.

Specified by:
run in interface Runnable

setInstance

public void setInstance(String instance)

setPrintReport

public void setPrintReport(boolean on)

sqlType

public static String sqlType(int typeValue)

tail

public static String tail(String aString,
                          char aSeparator,
                          int level)

hasInfo

private boolean hasInfo(String classname)