Java Doc for AbstractStateManager.java in  » Database-ORM » JPOX » org » jpox » state » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Database ORM » JPOX » org.jpox.state 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   org.jpox.state.AbstractStateManager

All known Subclasses:   org.jpox.state.JDOStateManagerImpl,
AbstractStateManager
abstract public class AbstractStateManager implements StateManager(Code)
Abstract representation of a StateManager. Provides some of the basic StateManager methods that do very little.
version:
   $Revision: 1.36 $


Field Summary
final protected static  LocaliserLOCALISER
     Localiser for messages.
protected  AbstractClassMetaDatacmd
     the metadata for the class.
protected  FieldManagercurrFM
     Current FieldManager.
protected  ObjectcurrFMmonitor
    
protected  booleandirty
     Indicator for whether the persistable instance is dirty. Note that "dirty" in this case is not equated to being in the P_DIRTY state. The P_DIRTY state means that at least one field in the object has been written by the user during the current transaction, whereas for this parameter, a field is "dirty" if it's been written by the user but not yet updated in the data store.
protected  boolean[]dirtyFields
     indicators for which fields are currently dirty in the persistable instance.
protected  boolean[]loadedFields
     indicators for which fields are currently loaded in the persistable instance.
protected  FetchPlan.FetchPlanForClassmyFP
     Fetch plan for the class of the managed object.
protected  ObjectmyID
    
protected  ObjectmyInternalID
     The object identity in the JVM.
protected  LifeCycleStatemyLC
    
protected  ObjectManagermyOM
    
protected  PersistenceCapablemyPC
    
protected  ObjectmyVersion
    
protected  intpcObjectType
     The type of the managed object (0 = PC, 1 = embedded PC, 2 = embedded element, 3 = embedded key, 4 = embedded value.
protected  booleanrestoreValues
     Whether to restore values at StateManager.
protected  ObjecttransactionalVersion
     version field for optimistic transactions, after a insert/update but not yet committed.

Constructor Summary
public  AbstractStateManager(ObjectManager om, AbstractClassMetaData cmd)
     Constructor.

Method Summary
protected  voidclearDirtyFlags()
     Method to clear all dirty flags on the object.
protected  voidclearDirtyFlags(int[] fields)
     Method to clear all dirty flags on the object.
protected static  voidclearFlags(boolean[] flags)
     Utility to clear the supplied flags.
protected static  voidclearFlags(boolean[] flags, int[] fields)
     Utility to clear the supplied flags.
abstract protected  booleandisconnectClone(PersistenceCapable pc)
     Method to disconnect any cloned persistence capable objects from their StateManager.
protected static  booleanequals(Object o1, Object o2)
     Compares two objects for equality, where one or both of the object references may be null.
protected  int[]getAllFieldNumbers()
     returns field numbers of all fields.
public  booleangetBooleanField(PersistenceCapable pc, int field, boolean currentValue)
     This method is called by the associated persistable if the value for the specified field is not cached (StateManager.isLoaded() fails).
public  bytegetByteField(PersistenceCapable pc, int field, byte currentValue)
     This method is called by the associated PersistenceCapable if the value for the specified field is not cached (StateManager.isLoaded() fails).
protected  CallbackHandlergetCallbackHandler()
     returns the handler for callback events.
public  chargetCharField(PersistenceCapable pc, int field, char currentValue)
     This method is called by the associated persistable if the value for the specified field is not cached (StateManager.isLoaded() fails).
public  AbstractClassMetaDatagetClassMetaData()
     Accessor for the ClassMetaData for this object.
public  String[]getDirtyFieldNames()
     Accessor for the names of the fields that are dirty.
public  int[]getDirtyFieldNumbers()
     Accessor for the field numbers of all dirty fields.
public  doublegetDoubleField(PersistenceCapable pc, int field, double currentValue)
     This method is called by the associated persistable if the value for the specified field is not cached (StateManager.isLoaded() fails).
public static  int[]getFlagsSetTo(boolean[] flags, boolean state)
     Returns an array of integers containing the indices of all elements in flags that are in the state passed as argument.
protected static  int[]getFlagsSetTo(boolean[] flags, int[] indices, boolean state)
     Returns an array of integers containing the indices of all elements in flags whose index occurs in indices and whose value is state.
public  floatgetFloatField(PersistenceCapable pc, int field, float currentValue)
     This method is called by the associated persistable if the value for the specified field is not cached (StateManager.isLoaded() fails).
public  intgetHighestFieldNumber()
    
public  intgetIntField(PersistenceCapable pc, int field, int currentValue)
     This method is called by the associated persistable if the value for the specified field is not cached (StateManager.isLoaded() fails).
public  ObjectgetInternalObjectId()
     Accessor for the internal object id of the object we are managing.
public  LifeCycleStategetLifecycleState()
    
public  String[]getLoadedFieldNames()
     Accessor for the names of the fields that are loaded.
public  int[]getLoadedFieldNumbers()
     Accessor for the field numbers of all loaded fields in this managed instance.
public  longgetLongField(PersistenceCapable pc, int field, long currentValue)
     This method is called by the associated persistable if the value for the specified field is not cached (StateManager.isLoaded() fails).
public  MetaDataManagergetMetaDataManager()
     Accessor for the MetaDataManager to use for this object. Simply a wrapper accessor method.
protected  int[]getNonPrimaryKeyFieldNumbers()
     returns field numbers of all non-primary-key fields.
protected  boolean[]getNonPrimaryKeyFields()
     returns indicators for which fields are non-primary key fields.
public  ObjectgetObject()
     Accessor for the Persistent Capable object.
public  ObjectgetObjectField(PersistenceCapable pc, int field, Object currentValue)
     This method is called by the associated persistable if the value for the specified field is not cached (StateManager.isLoaded() fails).
public  ObjectManagergetObjectManager()
     Accessor for the ObjectManager for this object.
public  intgetPcObjectType()
     Accessor for the PC object type (whether it is PC, embedded PC, etc).
protected  int[]getSecondClassMutableFieldNumbers()
     returns field numbers of all second class mutable fields.
protected  boolean[]getSecondClassMutableFields()
     returns indicators for which fields are second-class mutable.
public  shortgetShortField(PersistenceCapable pc, int field, short currentValue)
     This method is called by the associated persistable if the value for the specified field is not cached (StateManager.isLoaded() fails).
public  StoreManagergetStoreManager()
     Accessor for the StoreManager used for this object.
public  StringgetStringField(PersistenceCapable pc, int field, String currentValue)
     This method is called by the associated persistable if the value for the specified field is not cached (StateManager.isLoaded() fails).
public  ObjectgetTransactionalVersion(Object pc)
     Return the object representing the transactional version of the calling instance.
public  ObjectgetVersion(PersistenceCapable pc)
     Return the object representing the version of the calling instance.
protected  voidinitialiseFieldInformation()
     Convenience method to initialise the field information.
protected  booleanisDefaultFetchGroupLoaded()
     Accessor for whether the DFG fields are loaded.
public  booleanisDeleted(PersistenceCapable pc)
     Tests whether this object has been deleted.
public  booleanisDirty(PersistenceCapable pc)
     Tests whether this object is dirty.
public  booleanisEmbedded()
     Convenience accessor for whether this StateManager manages an embedded/serialised object.
protected  booleanisFetchPlanLoaded()
     Accessor for whether the current fetch plan fields are loaded.
public  booleanisNew(PersistenceCapable pc)
     Tests whether this object has been newly made persistent.
public  booleanisPersistent(PersistenceCapable pc)
     Tests whether this object is persistent.
public  booleanisRestoreValues()
    
public  booleanisTransactional(PersistenceCapable pc)
     Tests whether this object is transactional. Instances that respect transaction boundaries return true.
protected static  ObjectpeekField(Object obj, String fieldName)
     Utility to take a peek at a field in the persistable object.
public  voidprovidedBooleanField(PersistenceCapable pc, int field, boolean currentValue)
     This method is called from the associated persistable when its PersistenceCapable.jdoProvideFields() method is invoked.
public  voidprovidedByteField(PersistenceCapable pc, int field, byte currentValue)
     This method is called from the associated persistable when its PersistenceCapable.jdoProvideFields() method is invoked.
public  voidprovidedCharField(PersistenceCapable pc, int field, char currentValue)
     This method is called from the associated PersistenceCapable when its PersistenceCapable.jdoProvideFields() method is invoked.
public  voidprovidedDoubleField(PersistenceCapable pc, int field, double currentValue)
     This method is called from the associated PersistenceCapable when its PersistenceCapable.jdoProvideFields() method is invoked.
public  voidprovidedFloatField(PersistenceCapable pc, int field, float currentValue)
     This method is called from the associated PersistenceCapable when its PersistenceCapable.jdoProvideFields() method is invoked.
public  voidprovidedIntField(PersistenceCapable pc, int field, int currentValue)
     This method is called from the associated PersistenceCapable when its PersistenceCapable.jdoProvideFields() method is invoked.
public  voidprovidedLongField(PersistenceCapable pc, int field, long currentValue)
     This method is called from the associated PersistenceCapable when its PersistenceCapable.jdoProvideFields() method is invoked.
public  voidprovidedObjectField(PersistenceCapable pc, int fieldNumber, Object currentValue)
     This method is called from the associated persistable when its PersistenceCapable.jdoProvideFields() method is invoked.
public  voidprovidedShortField(PersistenceCapable pc, int field, short currentValue)
     This method is called from the associated PersistenceCapable when its PersistenceCapable.jdoProvideFields() method is invoked.
public  voidprovidedStringField(PersistenceCapable pc, int field, String currentValue)
     This method is called from the associated persistable when its PersistenceCapable.jdoProvideFields() method is invoked.
public  booleanreplacingBooleanField(PersistenceCapable pc, int field)
     This method is invoked by the PersistenceCapable object's jdoReplaceField() method to refresh the value of a boolean field.
public  bytereplacingByteField(PersistenceCapable obj, int field)
     This method is invoked by the PersistenceCapable object's jdoReplaceField() method to refresh the value of a byte field.
public  charreplacingCharField(PersistenceCapable obj, int field)
     This method is invoked by the PersistenceCapable object's jdoReplaceField() method to refresh the value of a char field.
public  doublereplacingDoubleField(PersistenceCapable obj, int field)
     This method is invoked by the PersistenceCapable object's jdoReplaceField() method to refresh the value of a double field.
public  floatreplacingFloatField(PersistenceCapable obj, int field)
     This method is invoked by the PersistenceCapable object's jdoReplaceField() method to refresh the value of a float field.
public  intreplacingIntField(PersistenceCapable obj, int field)
     This method is invoked by the persistable object's jdoReplaceField() method to refresh the value of a int field.
public  longreplacingLongField(PersistenceCapable obj, int field)
     This method is invoked by the persistable object's jdoReplaceField() method to refresh the value of a long field.
public  ObjectreplacingObjectField(PersistenceCapable obj, int field)
     This method is invoked by the persistable object's jdoReplaceField() method to refresh the value of an Object field.
public  shortreplacingShortField(PersistenceCapable obj, int field)
     This method is invoked by the persistable object's jdoReplaceField() method to refresh the value of a short field.
public  StringreplacingStringField(PersistenceCapable obj, int field)
     This method is invoked by the persistable object's jdoReplaceField() method to refresh the value of a String field.
public  voidsetPcObjectType(int embeddedType)
     Method to set this StateManager as managing an embedded/serialised object.
protected  voidsetRestoreValues(boolean restore_values)
    
public  voidsetTransactionalVersion(Object version)
    
public  voidsetVersion(Object version)
    
public  StringtoString()
     Stringifier method.

Field Detail
LOCALISER
final protected static Localiser LOCALISER(Code)
Localiser for messages.



cmd
protected AbstractClassMetaData cmd(Code)
the metadata for the class.



currFM
protected FieldManager currFM(Code)
Current FieldManager.



currFMmonitor
protected Object currFMmonitor(Code)
monitor to synchronize execution when replacing/providing fields *



dirty
protected boolean dirty(Code)
Indicator for whether the persistable instance is dirty. Note that "dirty" in this case is not equated to being in the P_DIRTY state. The P_DIRTY state means that at least one field in the object has been written by the user during the current transaction, whereas for this parameter, a field is "dirty" if it's been written by the user but not yet updated in the data store. The difference is, it's possible for an object's state to be P_DIRTY, yet have no "dirty" fields because flush() has been called at least once during the transaction.



dirtyFields
protected boolean[] dirtyFields(Code)
indicators for which fields are currently dirty in the persistable instance.



loadedFields
protected boolean[] loadedFields(Code)
indicators for which fields are currently loaded in the persistable instance.



myFP
protected FetchPlan.FetchPlanForClass myFP(Code)
Fetch plan for the class of the managed object.



myID
protected Object myID(Code)
The object identity in the datastore



myInternalID
protected Object myInternalID(Code)
The object identity in the JVM. Will be "myID" (if set) or otherwise a temporary id based on this StateManager.



myLC
protected LifeCycleState myLC(Code)
The actual LifeCycleState for the persistable instance



myOM
protected ObjectManager myOM(Code)
the Object Manager for this StateManager



myPC
protected PersistenceCapable myPC(Code)
The PersistenceCapable instance managed by this StateManager



myVersion
protected Object myVersion(Code)
version field for optimistic transactions



pcObjectType
protected int pcObjectType(Code)
The type of the managed object (0 = PC, 1 = embedded PC, 2 = embedded element, 3 = embedded key, 4 = embedded value.



restoreValues
protected boolean restoreValues(Code)
Whether to restore values at StateManager. If true, overwrites the restore values at tx level.



transactionalVersion
protected Object transactionalVersion(Code)
version field for optimistic transactions, after a insert/update but not yet committed.




Constructor Detail
AbstractStateManager
public AbstractStateManager(ObjectManager om, AbstractClassMetaData cmd)(Code)
Constructor.
Parameters:
  om - ObjectManager
Parameters:
  cmd - the metadata for the class.




Method Detail
clearDirtyFlags
protected void clearDirtyFlags()(Code)
Method to clear all dirty flags on the object.



clearDirtyFlags
protected void clearDirtyFlags(int[] fields)(Code)
Method to clear all dirty flags on the object.
Parameters:
  fields - the fields to clear



clearFlags
protected static void clearFlags(boolean[] flags)(Code)
Utility to clear the supplied flags.
Parameters:
  flags -



clearFlags
protected static void clearFlags(boolean[] flags, int[] fields)(Code)
Utility to clear the supplied flags.
Parameters:
  flags -
Parameters:
  fields - fields numbers where the flags will be cleared



disconnectClone
abstract protected boolean disconnectClone(PersistenceCapable pc)(Code)
Method to disconnect any cloned persistence capable objects from their StateManager.
Parameters:
  pc - The persistable object Whether the object was disconnected.



equals
protected static boolean equals(Object o1, Object o2)(Code)
Compares two objects for equality, where one or both of the object references may be null. true if the objects are both null orcompare equal according to their equals() method,false otherwise.



getAllFieldNumbers
protected int[] getAllFieldNumbers()(Code)
returns field numbers of all fields. field numbers of all fields.



getBooleanField
public boolean getBooleanField(PersistenceCapable pc, int field, boolean currentValue)(Code)
This method is called by the associated persistable if the value for the specified field is not cached (StateManager.isLoaded() fails). In this implementation of the StateManager, isLoaded() has a side effect of loading unloaded information and will always return true. As such, this method should never be called.
Parameters:
  pc - the calling persistable instance
Parameters:
  field - the field number
Parameters:
  currentValue - the current value of the field the new value for the field



getByteField
public byte getByteField(PersistenceCapable pc, int field, byte currentValue)(Code)
This method is called by the associated PersistenceCapable if the value for the specified field is not cached (StateManager.isLoaded() fails). In this implementation of the StateManager, isLoaded() has a side effect of loading unloaded information and will always return true. As such, this method should never be called.
Parameters:
  pc - the calling PersistenceCapable instance
Parameters:
  field - the field number
Parameters:
  currentValue - the current value of the field the new value for the field



getCallbackHandler
protected CallbackHandler getCallbackHandler()(Code)
returns the handler for callback events. the handler for callback events.



getCharField
public char getCharField(PersistenceCapable pc, int field, char currentValue)(Code)
This method is called by the associated persistable if the value for the specified field is not cached (StateManager.isLoaded() fails). In this implementation of the StateManager, isLoaded() has a side effect of loading unloaded information and will always return true. As such, this method should never be called.
Parameters:
  pc - the calling persistable instance
Parameters:
  field - the field number
Parameters:
  currentValue - the current value of the field the new value for the field



getClassMetaData
public AbstractClassMetaData getClassMetaData()(Code)
Accessor for the ClassMetaData for this object. The ClassMetaData.



getDirtyFieldNames
public String[] getDirtyFieldNames()(Code)
Accessor for the names of the fields that are dirty. Names of the dirty fields



getDirtyFieldNumbers
public int[] getDirtyFieldNumbers()(Code)
Accessor for the field numbers of all dirty fields. Absolute field numbers of the dirty fields in this instance.



getDoubleField
public double getDoubleField(PersistenceCapable pc, int field, double currentValue)(Code)
This method is called by the associated persistable if the value for the specified field is not cached (StateManager.isLoaded() fails). In this implementation of the StateManager, isLoaded() has a side effect of loading unloaded information and will always return true. As such, this method should never be called.
Parameters:
  pc - the calling persistable instance
Parameters:
  field - the field number
Parameters:
  currentValue - the current value of the field the new value for the field



getFlagsSetTo
public static int[] getFlagsSetTo(boolean[] flags, boolean state)(Code)
Returns an array of integers containing the indices of all elements in flags that are in the state passed as argument.
Parameters:
  flags - Array of flags (true or false)
Parameters:
  state - The state to search (true or false) The settings of the flags



getFlagsSetTo
protected static int[] getFlagsSetTo(boolean[] flags, int[] indices, boolean state)(Code)
Returns an array of integers containing the indices of all elements in flags whose index occurs in indices and whose value is state.



getFloatField
public float getFloatField(PersistenceCapable pc, int field, float currentValue)(Code)
This method is called by the associated persistable if the value for the specified field is not cached (StateManager.isLoaded() fails). In this implementation of the StateManager, isLoaded() has a side effect of loading unloaded information and will always return true. As such, this method should never be called.
Parameters:
  pc - the calling persistable instance
Parameters:
  field - the field number
Parameters:
  currentValue - the current value of the field the new value for the field



getHighestFieldNumber
public int getHighestFieldNumber()(Code)
Accessor for the highest field number in this class The highest field number



getIntField
public int getIntField(PersistenceCapable pc, int field, int currentValue)(Code)
This method is called by the associated persistable if the value for the specified field is not cached (StateManager.isLoaded() fails). In this implementation of the StateManager, isLoaded() has a side effect of loading unloaded information and will always return true. As such, this method should never be called.
Parameters:
  pc - the calling persistable instance
Parameters:
  field - the field number
Parameters:
  currentValue - the current value of the field the new value for the field



getInternalObjectId
public Object getInternalObjectId()(Code)
Accessor for the internal object id of the object we are managing. This will return the "id" if it has been set, otherwise a temporary id based on this StateManager. The internal object id



getLifecycleState
public LifeCycleState getLifecycleState()(Code)
Accessor for the LifeCycleState the LifeCycleState



getLoadedFieldNames
public String[] getLoadedFieldNames()(Code)
Accessor for the names of the fields that are loaded. Names of the loaded fields



getLoadedFieldNumbers
public int[] getLoadedFieldNumbers()(Code)
Accessor for the field numbers of all loaded fields in this managed instance. Field numbers of all (currently) loaded fields



getLongField
public long getLongField(PersistenceCapable pc, int field, long currentValue)(Code)
This method is called by the associated persistable if the value for the specified field is not cached (StateManager.isLoaded() fails). In this implementation of the StateManager, isLoaded() has a side effect of loading unloaded information and will always return true. As such, this method should never be called.
Parameters:
  pc - the calling persistable instance
Parameters:
  field - the field number
Parameters:
  currentValue - the current value of the field the new value for the field



getMetaDataManager
public MetaDataManager getMetaDataManager()(Code)
Accessor for the MetaDataManager to use for this object. Simply a wrapper accessor method. The MetaDataManager.



getNonPrimaryKeyFieldNumbers
protected int[] getNonPrimaryKeyFieldNumbers()(Code)
returns field numbers of all non-primary-key fields. field numbers of all non-primary-key fields.



getNonPrimaryKeyFields
protected boolean[] getNonPrimaryKeyFields()(Code)
returns indicators for which fields are non-primary key fields. indicators for which fields are non-primary key fields.



getObject
public Object getObject()(Code)
Accessor for the Persistent Capable object. The PersistentCapable object



getObjectField
public Object getObjectField(PersistenceCapable pc, int field, Object currentValue)(Code)
This method is called by the associated persistable if the value for the specified field is not cached (StateManager.isLoaded() fails). In this implementation of the StateManager, isLoaded() has a side effect of loading unloaded information and will always return true. As such, this method should never be called.
Parameters:
  pc - the calling persistable instance
Parameters:
  field - the field number
Parameters:
  currentValue - the current value of the field the new value for the field



getObjectManager
public ObjectManager getObjectManager()(Code)
Accessor for the ObjectManager for this object. The Object Manager.



getPcObjectType
public int getPcObjectType()(Code)
Accessor for the PC object type (whether it is PC, embedded PC, etc). PC Object Type



getSecondClassMutableFieldNumbers
protected int[] getSecondClassMutableFieldNumbers()(Code)
returns field numbers of all second class mutable fields. field numbers of all second class mutable fields.



getSecondClassMutableFields
protected boolean[] getSecondClassMutableFields()(Code)
returns indicators for which fields are second-class mutable. indicators for which fields are second-class mutable.



getShortField
public short getShortField(PersistenceCapable pc, int field, short currentValue)(Code)
This method is called by the associated persistable if the value for the specified field is not cached (StateManager.isLoaded() fails). In this implementation of the StateManager, isLoaded() has a side effect of loading unloaded information and will always return true. As such, this method should never be called.
Parameters:
  pc - the calling persistable instance
Parameters:
  field - the field number
Parameters:
  currentValue - the current value of the field the new value for the field



getStoreManager
public StoreManager getStoreManager()(Code)
Accessor for the StoreManager used for this object. The StoreManager.



getStringField
public String getStringField(PersistenceCapable pc, int field, String currentValue)(Code)
This method is called by the associated persistable if the value for the specified field is not cached (StateManager.isLoaded() fails). In this implementation of the StateManager, isLoaded() has a side effect of loading unloaded information and will always return true. As such, this method should never be called.
Parameters:
  pc - the calling persistable instance
Parameters:
  field - the field number
Parameters:
  currentValue - the current value of the field the new value for the field



getTransactionalVersion
public Object getTransactionalVersion(Object pc)(Code)
Return the object representing the transactional version of the calling instance.
Parameters:
  pc - the calling persistable instance the object representing the version of the calling instance
since:
   1.1.1



getVersion
public Object getVersion(PersistenceCapable pc)(Code)
Return the object representing the version of the calling instance.
Parameters:
  pc - the calling persistable instance the object representing the version of the calling instance
since:
   JDO 2.0



initialiseFieldInformation
protected void initialiseFieldInformation()(Code)
Convenience method to initialise the field information.



isDefaultFetchGroupLoaded
protected boolean isDefaultFetchGroupLoaded()(Code)
Accessor for whether the DFG fields are loaded. Whether the DFG fields are all loaded.



isDeleted
public boolean isDeleted(PersistenceCapable pc)(Code)
Tests whether this object has been deleted. Instances that have been deleted in the current transaction return true.

Transient instances return false.
Parameters:
  pc - the calling persistable instance true if this instance was deleted in the current transaction.




isDirty
public boolean isDirty(PersistenceCapable pc)(Code)
Tests whether this object is dirty. Instances that have been modified, deleted, or newly made persistent in the current transaction return true.

Transient nontransactional instances return false (JDO spec), but the JPOX implementation does not currently support the transient transactional state.
See Also:   PersistenceCapable.jdoMakeDirty(String fieldName)
Parameters:
  pc - the calling persistable instance true if this instance has been modified in current transaction.




isEmbedded
public boolean isEmbedded()(Code)
Convenience accessor for whether this StateManager manages an embedded/serialised object. Whether the managed object is embedded/serialised.



isFetchPlanLoaded
protected boolean isFetchPlanLoaded()(Code)
Accessor for whether the current fetch plan fields are loaded. Whether the fetch plan fields are all loaded.



isNew
public boolean isNew(PersistenceCapable pc)(Code)
Tests whether this object has been newly made persistent. Instances that have been made persistent in the current transaction return true.

Transient instances return false.
Parameters:
  pc - the calling persistable instance true if this instance was made persistentin the current transaction.




isPersistent
public boolean isPersistent(PersistenceCapable pc)(Code)
Tests whether this object is persistent. Instances whose state is stored in the data store return true. Transient instances return false.
Parameters:
  pc - the calling persistable instance true if this instance is persistent.



isRestoreValues
public boolean isRestoreValues()(Code)
Accessor for the Restore Values flag Whether to restore values



isTransactional
public boolean isTransactional(PersistenceCapable pc)(Code)
Tests whether this object is transactional. Instances that respect transaction boundaries return true. These instances include transient instances made transactional as a result of being the target of a makeTransactional method call; newly made persistent or deleted persistent instances; persistent instances read in data store transactions; and persistent instances modified in optimistic transactions.

Transient nontransactional instances return false.
Parameters:
  pc - the calling persistable instance true if this instance is transactional.




peekField
protected static Object peekField(Object obj, String fieldName)(Code)
Utility to take a peek at a field in the persistable object.
Parameters:
  obj - The persistable object
Parameters:
  fieldName - The field to peek at The value of the field.



providedBooleanField
public void providedBooleanField(PersistenceCapable pc, int field, boolean currentValue)(Code)
This method is called from the associated persistable when its PersistenceCapable.jdoProvideFields() method is invoked. Its purpose is to provide the value of the specified field to the StateManager.
Parameters:
  pc - the calling persistable instance
Parameters:
  field - the field number
Parameters:
  currentValue - the current value of the field



providedByteField
public void providedByteField(PersistenceCapable pc, int field, byte currentValue)(Code)
This method is called from the associated persistable when its PersistenceCapable.jdoProvideFields() method is invoked. Its purpose is to provide the value of the specified field to the StateManager.
Parameters:
  pc - the calling persistable instance
Parameters:
  field - the field number
Parameters:
  currentValue - the current value of the field



providedCharField
public void providedCharField(PersistenceCapable pc, int field, char currentValue)(Code)
This method is called from the associated PersistenceCapable when its PersistenceCapable.jdoProvideFields() method is invoked. Its purpose is to provide the value of the specified field to the StateManager.
Parameters:
  pc - the calling persistable instance
Parameters:
  field - the field number
Parameters:
  currentValue - the current value of the field



providedDoubleField
public void providedDoubleField(PersistenceCapable pc, int field, double currentValue)(Code)
This method is called from the associated PersistenceCapable when its PersistenceCapable.jdoProvideFields() method is invoked. Its purpose is to provide the value of the specified field to the StateManager.
Parameters:
  pc - the calling persistable instance
Parameters:
  field - the field number
Parameters:
  currentValue - the current value of the field



providedFloatField
public void providedFloatField(PersistenceCapable pc, int field, float currentValue)(Code)
This method is called from the associated PersistenceCapable when its PersistenceCapable.jdoProvideFields() method is invoked. Its purpose is to provide the value of the specified field to the StateManager.
Parameters:
  pc - the calling persistable instance
Parameters:
  field - the field number
Parameters:
  currentValue - the current value of the field



providedIntField
public void providedIntField(PersistenceCapable pc, int field, int currentValue)(Code)
This method is called from the associated PersistenceCapable when its PersistenceCapable.jdoProvideFields() method is invoked. Its purpose is to provide the value of the specified field to the StateManager.
Parameters:
  pc - the calling persistable instance
Parameters:
  field - the field number
Parameters:
  currentValue - the current value of the field



providedLongField
public void providedLongField(PersistenceCapable pc, int field, long currentValue)(Code)
This method is called from the associated PersistenceCapable when its PersistenceCapable.jdoProvideFields() method is invoked. Its purpose is to provide the value of the specified field to the StateManager.
Parameters:
  pc - the calling persistable instance
Parameters:
  field - the field number
Parameters:
  currentValue - the current value of the field



providedObjectField
public void providedObjectField(PersistenceCapable pc, int fieldNumber, Object currentValue)(Code)
This method is called from the associated persistable when its PersistenceCapable.jdoProvideFields() method is invoked. Its purpose is to provide the value of the specified field to the StateManager.
Parameters:
  pc - the calling PersistenceCapable instance
Parameters:
  fieldNumber - the field number
Parameters:
  currentValue - the current value of the field



providedShortField
public void providedShortField(PersistenceCapable pc, int field, short currentValue)(Code)
This method is called from the associated PersistenceCapable when its PersistenceCapable.jdoProvideFields() method is invoked. Its purpose is to provide the value of the specified field to the StateManager.
Parameters:
  pc - the calling persistable instance
Parameters:
  field - the field number
Parameters:
  currentValue - the current value of the field



providedStringField
public void providedStringField(PersistenceCapable pc, int field, String currentValue)(Code)
This method is called from the associated persistable when its PersistenceCapable.jdoProvideFields() method is invoked. Its purpose is to provide the value of the specified field to the StateManager.
Parameters:
  pc - the calling persistable instance
Parameters:
  field - the field number
Parameters:
  currentValue - the current value of the field



replacingBooleanField
public boolean replacingBooleanField(PersistenceCapable pc, int field)(Code)
This method is invoked by the PersistenceCapable object's jdoReplaceField() method to refresh the value of a boolean field.
Parameters:
  pc - the calling persistable instance
Parameters:
  field - the field number the new value for the field



replacingByteField
public byte replacingByteField(PersistenceCapable obj, int field)(Code)
This method is invoked by the PersistenceCapable object's jdoReplaceField() method to refresh the value of a byte field.
Parameters:
  obj - the calling persistable instance
Parameters:
  field - the field number the new value for the field



replacingCharField
public char replacingCharField(PersistenceCapable obj, int field)(Code)
This method is invoked by the PersistenceCapable object's jdoReplaceField() method to refresh the value of a char field.
Parameters:
  obj - the calling persistable instance
Parameters:
  field - the field number the new value for the field



replacingDoubleField
public double replacingDoubleField(PersistenceCapable obj, int field)(Code)
This method is invoked by the PersistenceCapable object's jdoReplaceField() method to refresh the value of a double field.
Parameters:
  obj - the calling PersistenceCapable instance
Parameters:
  field - the field number the new value for the field



replacingFloatField
public float replacingFloatField(PersistenceCapable obj, int field)(Code)
This method is invoked by the PersistenceCapable object's jdoReplaceField() method to refresh the value of a float field.
Parameters:
  obj - the calling PersistenceCapable instance
Parameters:
  field - the field number the new value for the field



replacingIntField
public int replacingIntField(PersistenceCapable obj, int field)(Code)
This method is invoked by the persistable object's jdoReplaceField() method to refresh the value of a int field.
Parameters:
  obj - the calling persistable instance
Parameters:
  field - the field number the new value for the field



replacingLongField
public long replacingLongField(PersistenceCapable obj, int field)(Code)
This method is invoked by the persistable object's jdoReplaceField() method to refresh the value of a long field.
Parameters:
  obj - the calling persistable instance
Parameters:
  field - the field number the new value for the field



replacingObjectField
public Object replacingObjectField(PersistenceCapable obj, int field)(Code)
This method is invoked by the persistable object's jdoReplaceField() method to refresh the value of an Object field.
Parameters:
  obj - the calling persistable instance
Parameters:
  field - the field number the new value for the field



replacingShortField
public short replacingShortField(PersistenceCapable obj, int field)(Code)
This method is invoked by the persistable object's jdoReplaceField() method to refresh the value of a short field.
Parameters:
  obj - the calling persistable instance
Parameters:
  field - the field number the new value for the field



replacingStringField
public String replacingStringField(PersistenceCapable obj, int field)(Code)
This method is invoked by the persistable object's jdoReplaceField() method to refresh the value of a String field.
Parameters:
  obj - the calling persistable instance
Parameters:
  field - the field number the new value for the field



setPcObjectType
public void setPcObjectType(int embeddedType)(Code)
Method to set this StateManager as managing an embedded/serialised object.
Parameters:
  embeddedType - The type of object being managed



setRestoreValues
protected void setRestoreValues(boolean restore_values)(Code)
Mutator for the Restore Values flag
Parameters:
  restore_values - Whether to restore values



setTransactionalVersion
public void setTransactionalVersion(Object version)(Code)
Sets the value for the version column in a transaction not yet committed
Parameters:
  version - The version



setVersion
public void setVersion(Object version)(Code)
Sets the value for the version column in the datastore
Parameters:
  version - The version



toString
public String toString()(Code)
Stringifier method. String form of the StateManager



Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.