wt.fc
Class WTObject

java.lang.Object
  extended bywt.fc.WTObject
All Implemented Interfaces:
DisplayIdentification, Externalizable, NetFactor, ObjectMappable, Persistable, Serializable
Direct Known Subclasses:
AbstractObjectGraph, AbstractObjectGraphEdge, AbstractObjectGraphNode, AbstractTransferPolicy, AbstractTransferSpec, AbstractValue, AdHocAclSpec, Agenda, AnnotationBaseline, CabinetManaged, CalendarComponent, ConfirmableShippingItem, ContainerConstraint, ContentItem, Criterion, CriterionObject, DatedEffectivity, DefaultWTContainerTemplate, Discussion, ElectronicSignature, ElementImportInfo, EnvironmentConflict, EPMCheckpoint, EPMFeatureValue, EPMParameterMap, EPMParameterValue, EPMWorkspace, ESITransactionMessage, EventLog, ExchangeContainer, ExportAdHocCriteria, FolderResident, ForumCookie, FvPolicyItem, FvServicePersistentFlags, ImportAdHocCriteria, ImportSession, IndexPolicyList, Item, IteratedFolderResident, LifeCycleHistory, LifeCycleSignature, Managed, Master, Minutes, NotebookComponent, NotificationList, ObjectSubscription, ObjectToObjectLink, ObjectToVersionLink, OrgContainer, PagingSession, PDMLinkProduct, PersistentTrackingNumGen, Phase, PolicyAcl, Project2, Receipt, RecentUpdate, ReleaseActivityMessage, RemoteSiteTeamTemplate, ReplicationBaseline, ReVaultSessionId, RevisionControlled, RoleActorRoleMap, RolePoolMap, RolePrincipalMap, RoleRoleMap, RvStreamIdCounter, SavedQuery, ScheduleHistory, ScheduleMethodArg, SemanticKey, Simple, SingleDefinitionConstraint, SiteSecurity, StoredItem, StreamData, ToDoItem, TransferUnitMaster, TransportBox, TypeConstraint, UnitEffectivity, VersionToVersionLink, WfAssignment, WfBallot, WfConnector, WfConnectorTemplate, WfExpression, WfProcessRequester, WorkItem, WTIncorporationDate, WTLibrary, WTProductConfiguration, WTProductConfigurationMaster, WTProductInstance2, WTProductInstanceMaster, WTRoleHolder, WTRoleHolder2

public abstract class WTObject
extends Object
implements Persistable, DisplayIdentification, Externalizable

WTObject is the abstract base class for all domain-specific item and link classes.

Supported API: true

Extendable: true

See Also:
Serialized Form

Field Summary
private static String CLASSNAME
           
private  Reference counterRef
           
static String CREATE_TIMESTAMP
           
static long EXTERNALIZATION_VERSION_UID
           
static String MODIFY_TIMESTAMP
           
protected static long OLD_FORMAT_VERSION_UID
           
private static String RESOURCE
           
(package private) static long serialVersionUID
           
private  PersistInfo thePersistInfo
           
 
Fields inherited from interface wt.fc.Persistable
IDENTITY, PERSIST_INFO, TYPE
 
Fields inherited from interface wt.identity.DisplayIdentification
DISPLAY_IDENTIFIER, DISPLAY_IDENTITY, DISPLAY_TYPE
 
Constructor Summary
WTObject()
           
 
Method Summary
 void checkAttributes()
          Validate the values of this Persistable object's attributes.
 WTObject duplicate()
          Create a deep copy of this WTObject.
 boolean equals(Object obj)
          Indicates whether the given object is equal to this object from a persistence perspective, by comparing the two objects ObjectIdentifiers.
protected  void finalize()
           
 ClassInfo getClassInfo()
          Returns the ClassInfo object for this class.
 Timestamp getCreateTimestamp()
          Deprecated.  
 LocalizableMessage getDisplayIdentifier()
          Use IdentityFactory to return the displayable identifier of the object.
 DisplayIdentity getDisplayIdentity()
          Use IdentityFactory to return the displayable identity of the object.
 LocalizableMessage getDisplayType()
          Use IdentityFactory to return the displayable type of the object.
 String getIdentity()
          Deprecated. Replaced by getDisplayIdentifier() to return a localizable message which supplies the identifier for the object. To return a localizable value which includes the object type, use getDisplayIdentity(). For general messages, getDisplayIdentity() by itself is prefereble to using a combination of getDisplayType() and getDisplayIdentifier().
 Timestamp getModifyTimestamp()
          Deprecated.  
 PersistInfo getPersistInfo()
          Gets the object for the association that plays role: PERSIST_INFO.
 String getType()
          Deprecated. Replaced by getDisplayType() to return a localizable message which supplies the type of the object.
 int hashCode()
          Returns a hash code for this object based upon its ObjectIdentifier.
protected  void initialize()
          Initializes objects created by new-factory methods.
 void readExternal(ObjectInput input)
          Reads the non-transient fields of this class from an external source.
 void readExternal(PersistentRetrieveIfc input)
          Used by Persistent Data Service to populate the persistent attributes of this class from a persistent store.
private  boolean readOldVersion(ObjectInput input, long readSerialVersionUID, boolean passThrough, boolean superDone)
          Reads the non-transient fields of this class from an external source, which is not the current version.
protected  boolean readVersion(WTObject thisObject, ObjectInput input, long readSerialVersionUID, boolean passThrough, boolean superDone)
          Reads the non-transient fields of this class from an external source.
 void setPersistInfo(PersistInfo a_PersistInfo)
          Sets the object for the association that plays role: PERSIST_INFO.
 String toString()
          If the object has been persisted, return it's ObjectIdentifier.
 void writeExternal(ObjectOutput output)
          Writes the non-transient fields of this class to an external source.
 void writeExternal(PersistentStoreIfc output)
          Used by Persistent Data Service to obtain the values of the persistent attributes of this class, so they can be written to a persistent store.
 
Methods inherited from class java.lang.Object
clone, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface wt.fc.NetFactor
getConceptualClassname
 

Field Detail

RESOURCE

private static final String RESOURCE
See Also:
Constant Field Values

CLASSNAME

private static final String CLASSNAME

thePersistInfo

private PersistInfo thePersistInfo

serialVersionUID

static final long serialVersionUID
See Also:
Constant Field Values

EXTERNALIZATION_VERSION_UID

public static final long EXTERNALIZATION_VERSION_UID
See Also:
Constant Field Values

OLD_FORMAT_VERSION_UID

protected static final long OLD_FORMAT_VERSION_UID
See Also:
Constant Field Values

counterRef

private Reference counterRef

CREATE_TIMESTAMP

public static final String CREATE_TIMESTAMP
See Also:
Constant Field Values

MODIFY_TIMESTAMP

public static final String MODIFY_TIMESTAMP
See Also:
Constant Field Values
Constructor Detail

WTObject

public WTObject()
Method Detail

writeExternal

public void writeExternal(ObjectOutput output)
                   throws IOException
Writes the non-transient fields of this class to an external source.

Supported API: false

Specified by:
writeExternal in interface Externalizable
Parameters:
output -
Throws:
IOException

readExternal

public void readExternal(ObjectInput input)
                  throws IOException,
                         ClassNotFoundException
Reads the non-transient fields of this class from an external source.

Supported API: false

Specified by:
readExternal in interface Externalizable
Parameters:
input -
Throws:
IOException
ClassNotFoundException

readVersion

protected boolean readVersion(WTObject thisObject,
                              ObjectInput input,
                              long readSerialVersionUID,
                              boolean passThrough,
                              boolean superDone)
                       throws IOException,
                              ClassNotFoundException
Reads the non-transient fields of this class from an external source.

Supported API: false

Parameters:
thisObject -
input -
readSerialVersionUID -
passThrough -
superDone -
Returns:
boolean
Throws:
IOException
ClassNotFoundException

readOldVersion

private boolean readOldVersion(ObjectInput input,
                               long readSerialVersionUID,
                               boolean passThrough,
                               boolean superDone)
                        throws IOException,
                               ClassNotFoundException
Reads the non-transient fields of this class from an external source, which is not the current version.

Parameters:
input -
readSerialVersionUID -
passThrough -
superDone -
Returns:
boolean
Throws:
IOException
ClassNotFoundException

writeExternal

public void writeExternal(PersistentStoreIfc output)
                   throws SQLException,
                          DatastoreException
Used by Persistent Data Service to obtain the values of the persistent attributes of this class, so they can be written to a persistent store.

(Not intended for general use.)

Supported API: false

Specified by:
writeExternal in interface ObjectMappable
Parameters:
output -
Throws:
SQLException
DatastoreException

readExternal

public void readExternal(PersistentRetrieveIfc input)
                  throws SQLException,
                         DatastoreException
Used by Persistent Data Service to populate the persistent attributes of this class from a persistent store.

(Not intended for general use.)

Supported API: false

Specified by:
readExternal in interface ObjectMappable
Parameters:
input -
Throws:
SQLException
DatastoreException

toString

public String toString()
If the object has been persisted, return it's ObjectIdentifier. If it has not yet been persisted, simply return it's conceptual (modeled) name.

Returns:
String

getClassInfo

public ClassInfo getClassInfo()
                       throws WTIntrospectionException
Returns the ClassInfo object for this class.

Supported API: false

Specified by:
getClassInfo in interface NetFactor
Returns:
ClassInfo
Throws:
WTIntrospectionException

getIdentity

public String getIdentity()
Deprecated. Replaced by getDisplayIdentifier() to return a localizable message which supplies the identifier for the object. To return a localizable value which includes the object type, use getDisplayIdentity(). For general messages, getDisplayIdentity() by itself is prefereble to using a combination of getDisplayType() and getDisplayIdentifier().

Returns a string that can be displayed to the user to identify the object. WTObject implements a default method that returns a string representation of this object's identifier.

Supported API: false

Specified by:
getIdentity in interface Persistable
Returns:
String

getType

public String getType()
Deprecated. Replaced by getDisplayType() to return a localizable message which supplies the type of the object.

Returns a string that can be displayed to the user to identify the object's type. WTObject implements a default method that returns the name of this object's class.

Supported API: false

Specified by:
getType in interface Persistable
Returns:
String

checkAttributes

public void checkAttributes()
                     throws InvalidAttributeException
Validate the values of this Persistable object's attributes.

Supported API: false

Specified by:
checkAttributes in interface Persistable
Throws:
InvalidAttributeException

duplicate

public WTObject duplicate()
                   throws WTException
Create a deep copy of this WTObject. The resulting object is not persistent (i.e., it does not have an assigned object identifier).

Supported API: false

Returns:
WTObject
Throws:
WTException

initialize

protected void initialize()
                   throws WTException
Initializes objects created by new-factory methods.

Supported API: false

Throws:
WTException

getDisplayType

public LocalizableMessage getDisplayType()
Use IdentityFactory to return the displayable type of the object. This value is suitable for any message.

Supported API: true

Specified by:
getDisplayType in interface DisplayIdentification
Returns:
LocalizableMessage

getDisplayIdentifier

public LocalizableMessage getDisplayIdentifier()
Use IdentityFactory to return the displayable identifier of the object.

Supported API: true

Specified by:
getDisplayIdentifier in interface DisplayIdentification
Returns:
LocalizableMessage

getDisplayIdentity

public DisplayIdentity getDisplayIdentity()
Use IdentityFactory to return the displayable identity of the object.

Supported API: true

Specified by:
getDisplayIdentity in interface DisplayIdentification
Returns:
DisplayIdentity

getPersistInfo

public PersistInfo getPersistInfo()
Gets the object for the association that plays role: PERSIST_INFO.

Supported API: false

Specified by:
getPersistInfo in interface Persistable
Returns:
PersistInfo

setPersistInfo

public void setPersistInfo(PersistInfo a_PersistInfo)
Sets the object for the association that plays role: PERSIST_INFO.

Supported API: false

Specified by:
setPersistInfo in interface Persistable
Parameters:
a_PersistInfo -

equals

public boolean equals(Object obj)
Indicates whether the given object is equal to this object from a persistence perspective, by comparing the two objects ObjectIdentifiers. Changed or stale copies are still considered equal by this method. Delegates to PersistenceHelper.equals(Persistable,Object).

Warning: Certain core Windchill operations may depend upon equals being ObjectIdentifier-based. Changes to the default implementation should be done with care, if at all.

Supported API: false

Parameters:
obj -
Returns:
boolean

hashCode

public int hashCode()
Returns a hash code for this object based upon its ObjectIdentifier. Delegates to PersistenceHelper.hashCode(Persistable).

Warning: Certain core Windchill operations may depend upon hashCode being ObjectIdentifier-based. Changes to the default implementation should be done with care, if at all.

Supported API: false

Returns:
int

getCreateTimestamp

public final Timestamp getCreateTimestamp()
Deprecated.  


getModifyTimestamp

public final Timestamp getModifyTimestamp()
Deprecated.  


finalize

protected void finalize()
                 throws Throwable
Throws:
Throwable