Class ClassControl
java.lang.Object
com.sun.jdo.api.persistence.enhancer.util.Assertion
com.sun.jdo.api.persistence.enhancer.util.Support
com.sun.jdo.api.persistence.enhancer.impl.ClassControl
ClassControl acts as the primary handle for a class within the
filter tool. ClassControl instances are typically accessed through
various methods on Environment.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final int -
Constructor Summary
ConstructorsConstructorDescriptionClassControl(ClassFileSource theSource, ClassFile theFile, Environment env) ConstructorClassControl(ClassFileSource theSource, Environment env) Constructor -
Method Summary
Modifier and TypeMethodDescriptioncom.sun.jdo.api.persistence.enhancer.impl.ClassActionaction()Get the ClassAction for this classvoidannotate()perform necessary annotation actions on the classbooleanReturn true if the class is one which should be a candidate for annotation.voidaugment()Reparent class if neededGet the ClassFile data structure for the classReturn the class name in VM formbooleanReturn true if filtering of the class is required.voidRecord a modification of the classstatic StringReturn the vm package name for the vm class nameintReturn the persistence type for this classpkg()Return the vm package name for this classvoidMark the class as requiring update.voidscan1()Note the class characteristicssource()Return the source of the classReturn the name of the class sourcebooleanupdated()Return true if the classfile has been updatedstatic StringuserClassFromVMClass(String vmName) Return the class name in user ('.' delimited) formReturn the class name in user ('.' delimited) formstatic StringvmClassFromUserClass(String userName) Return the class name in VM ('/' delimited) formvoidWrite the file.Methods inherited from class com.sun.jdo.api.persistence.enhancer.util.Support
getI18N, getI18N, getI18N, getI18N, getI18N, getI18N
-
Field Details
-
TransientOnly
public static final int TransientOnly- See Also:
-
PersistUnknown
public static final int PersistUnknown- See Also:
-
PersistAware
public static final int PersistAware- See Also:
-
PersistCapable
public static final int PersistCapable- See Also:
-
UpdateNotNeeded
public static final int UpdateNotNeeded- See Also:
-
UpdateUnknown
public static final int UpdateUnknown- See Also:
-
UpdateNew
public static final int UpdateNew- See Also:
-
UpdateNewer
public static final int UpdateNewer- See Also:
-
-
Constructor Details
-
ClassControl
Constructor -
ClassControl
Constructor
-
-
Method Details
-
updated
public boolean updated()Return true if the classfile has been updated -
noteUpdate
public void noteUpdate()Record a modification of the class -
classFile
Get the ClassFile data structure for the class -
persistType
public int persistType()Return the persistence type for this class -
filterRequired
public boolean filterRequired()Return true if filtering of the class is required. This checks only whether the filtered version of the class is up to date w.r.t. its input class. -
requireUpdate
public void requireUpdate()Mark the class as requiring update. -
annotateable
public boolean annotateable()Return true if the class is one which should be a candidate for annotation. -
action
public com.sun.jdo.api.persistence.enhancer.impl.ClassAction action()Get the ClassAction for this class -
scan1
public void scan1()Note the class characteristics -
augment
public void augment()Reparent class if needed -
annotate
public void annotate()perform necessary annotation actions on the class -
className
Return the class name in VM form -
userClassName
Return the class name in user ('.' delimited) form -
userClassFromVMClass
Return the class name in user ('.' delimited) form -
vmClassFromUserClass
Return the class name in VM ('/' delimited) form -
pkg
Return the vm package name for this class -
packageOf
Return the vm package name for the vm class name -
sourceName
Return the name of the class source -
source
Return the source of the class -
write
Write the file. If destination directory is non-null, write the file relative to that directory, else write it relative to its original location.- Throws:
IOExceptionFileNotFoundException
-