Java Doc for JDOAdapter.java in  » Database-ORM » JPOX » org » jpox » jdo » 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.jdo 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   org.jpox.jdo.JDOAdapter

JDOAdapter
public class JDOAdapter implements ApiAdapter(Code)
Adapter for the JDO API, to allow the JPOX core runtime to expose multiple APIs to clients.
version:
   $Revision: 1.32 $


Field Summary
final protected static  LocaliserLOCALISER
    


Method Summary
public  booleanallowDeleteOfNonPersistentObject()
     Whether the API allows deletion of a non-persistent object.
public  booleanallowPersistOfDeletedObject()
     Whether the API allows (re-)persistence of a deleted object.
public  booleanallowReadFieldOfDeletedObject()
     Whether the API allows reading a field of a deleted object.
public  booleanclearLoadedFlagsOnDeleteObject()
     Whether the API requires clearing of the fields of an object when it is deleted.
public  booleangetDefaultCascadeDeleteForField()
     Returns the default cascade-delete setting.
public  booleangetDefaultCascadePersistForField()
     Returns the default cascade-persist.
public  booleangetDefaultCascadeRefreshForField()
     Returns the default cascade-refresh setting.
public  booleangetDefaultCascadeUpdateForField()
     Returns the default cascade-update setting.
public  MapgetDefaultFactoryProperties()
     Method to return the default factory properties for this API.
public  ObjectgetIdForObject(Object obj)
     Method to return the object identity for the passed persistable object.
public  ClassgetKeyTypeForSingleFieldIdentityType(Class idType)
     Accessor for the type of the single field application-identity key given the single field identity type.
public  LifeCycleStategetLifeCycleState(int stateType)
     Returns the LifeCycleState for the state constant.
public  ObjectgetNewApplicationIdentityObjectId(Object pc, AbstractClassMetaData cmd)
     Method to create a new object identity for the passed object with the supplied MetaData.
public  ObjectgetNewApplicationIdentityObjectId(Class cls, Object key)
     Method to return a new object identity for the specified class, and key (possibly toString() output).
public  ObjectgetNewSingleFieldIdentity(Class idType, Class pcType, Object value)
     Utility to create a new SingleFieldIdentity using reflection when you know the type of the PersistenceCapable, and also which SingleFieldIdentity, and the value of the key.
Parameters:
  idType - Type of SingleFieldIdentity
Parameters:
  pcType - Type of the PersistenceCapable
Parameters:
  value - The value for the identity (the Long, or Int, or ...
public  ObjectgetObjectId(StateManager sm)
     Accessor for the object id from the StateManager for this object.
public  StringgetObjectState(Object obj)
     Accessor for the object state.
public  ObjectgetPersistenceManager(Object obj)
     Accessor for the persistence manager for this object.
public  StringgetSingleFieldIdentityClassNameForByte()
     Accessor for the class name to use for identities when there is a single Byte/byte field.
public  StringgetSingleFieldIdentityClassNameForChar()
     Accessor for the class name to use for identities when there is a single Character/char field.
public  StringgetSingleFieldIdentityClassNameForInt()
     Accessor for the class name to use for identities when there is a single Integer/int field.
public  StringgetSingleFieldIdentityClassNameForLong()
     Accessor for the class name to use for identities when there is a single Long/long field.
public  StringgetSingleFieldIdentityClassNameForObject()
     Accessor for the class name to use for identities when there is a single Object field.
public  StringgetSingleFieldIdentityClassNameForShort()
     Accessor for the class name to use for identities when there is a single Short/short field.
public  StringgetSingleFieldIdentityClassNameForString()
     Accessor for the class name to use for identities when there is a single String field.
public  ClassgetTargetClassForSingleFieldIdentity(Object id)
     Accessor for the target class for the specified single field application-identity.
public  StringgetTargetClassNameForSingleFieldIdentity(Object id)
     Accessor for the target class name for the specified single field identity.
public  ObjectgetTargetKeyForSingleFieldIdentity(Object id)
     Accessor for the key object for the specified single field application-identity.
public  ObjectgetVersion(StateManager sm)
     Accessor for the version from the StateManager for this object.
public  ObjectgetVersionForObject(Object obj)
     Method to return the object version for the passed persistable object.
public  booleanisDeleted(Object obj)
     Accessor for whether the passed object is deleted.
public  booleanisDetachable(Object obj)
     Method to return if the passed object is detachable using this API.
public  booleanisDetached(Object obj)
     Accessor for whether the passed object is detached.
public  booleanisDirty(Object obj)
     Accessor for whether the passed object is dirty.
public  booleanisLoaded(StateManager sm, int fieldNumber)
    
public  booleanisNew(Object obj)
     Accessor for whether the passed object is new.
public  booleanisPersistable(Object obj)
     Method to return if the passed object is persistable using this API.
public  booleanisPersistable(Class cls)
     Utility method to check if the specified class is of a type that can be persisted for this API.
public  booleanisPersistent(Object obj)
     Accessor for whether the passed object is persistent.
public  booleanisSingleFieldIdentity(Object id)
     Accessor for whether the passed identity is a valid single-field application-identity for this API.
public  booleanisSingleFieldIdentityClass(String className)
     Checks whether the passed class name is valid for a single field application-identity for this API.
public  booleanisTransactional(Object obj)
     Accessor for whether the passed object is transactional.
public  booleanisValidPrimaryKeyClass(Class pkClass, AbstractClassMetaData cmd, ClassLoaderResolver clr, int noOfPkFields)
     Utility to check if a primary-key class is valid.
public  voidmakeFieldDirty(Object obj, String fieldName)
     Method to make the field dirty in the object.
public  StateManagernewStateManager(ObjectManager om, AbstractClassMetaData acmd)
     Method to create a new StateManager for the ObjectManager and class.

Field Detail
LOCALISER
final protected static Localiser LOCALISER(Code)





Method Detail
allowDeleteOfNonPersistentObject
public boolean allowDeleteOfNonPersistentObject()(Code)
Whether the API allows deletion of a non-persistent object. Whether you can call delete on an object not yet persisted



allowPersistOfDeletedObject
public boolean allowPersistOfDeletedObject()(Code)
Whether the API allows (re-)persistence of a deleted object. Whether you can call persist on a deleted object



allowReadFieldOfDeletedObject
public boolean allowReadFieldOfDeletedObject()(Code)
Whether the API allows reading a field of a deleted object. Whether you can read after deleting



clearLoadedFlagsOnDeleteObject
public boolean clearLoadedFlagsOnDeleteObject()(Code)
Whether the API requires clearing of the fields of an object when it is deleted. Whether to clear loaded fields at delete



getDefaultCascadeDeleteForField
public boolean getDefaultCascadeDeleteForField()(Code)
Returns the default cascade-delete setting. JDO defaults to not deleting by reachability (unless using delete dependent) The default cascade-delete (false)



getDefaultCascadePersistForField
public boolean getDefaultCascadePersistForField()(Code)
Returns the default cascade-persist. JDO defaults to persisting by reachability. The default value for cascade-persist (true)



getDefaultCascadeRefreshForField
public boolean getDefaultCascadeRefreshForField()(Code)
Returns the default cascade-refresh setting. The default cascade-refresh (false)



getDefaultCascadeUpdateForField
public boolean getDefaultCascadeUpdateForField()(Code)
Returns the default cascade-update setting. JDO defaults to updating by reachability. The default cascade-update (true)



getDefaultFactoryProperties
public Map getDefaultFactoryProperties()(Code)
Method to return the default factory properties for this API. The default props



getIdForObject
public Object getIdForObject(Object obj)(Code)
Method to return the object identity for the passed persistable object. Returns null if it is not persistable, or has no identity.
Parameters:
  obj - The object The identity



getKeyTypeForSingleFieldIdentityType
public Class getKeyTypeForSingleFieldIdentityType(Class idType)(Code)
Accessor for the type of the single field application-identity key given the single field identity type.
Parameters:
  idType - Single field identity type key type



getLifeCycleState
public LifeCycleState getLifeCycleState(int stateType)(Code)
Returns the LifeCycleState for the state constant.
Parameters:
  stateType - the type as integer the type as LifeCycleState object



getNewApplicationIdentityObjectId
public Object getNewApplicationIdentityObjectId(Object pc, AbstractClassMetaData cmd)(Code)
Method to create a new object identity for the passed object with the supplied MetaData. Only applies to application-identity cases.
Parameters:
  pc - The persistable object
Parameters:
  cmd - Its metadata The new identity object



getNewApplicationIdentityObjectId
public Object getNewApplicationIdentityObjectId(Class cls, Object key)(Code)
Method to return a new object identity for the specified class, and key (possibly toString() output).
Parameters:
  cls - Persistable class
Parameters:
  key - form of the object id The object identity



getNewSingleFieldIdentity
public Object getNewSingleFieldIdentity(Class idType, Class pcType, Object value)(Code)
Utility to create a new SingleFieldIdentity using reflection when you know the type of the PersistenceCapable, and also which SingleFieldIdentity, and the value of the key.
Parameters:
  idType - Type of SingleFieldIdentity
Parameters:
  pcType - Type of the PersistenceCapable
Parameters:
  value - The value for the identity (the Long, or Int, or ... etc). Single field identity
throws:
  JPOXException - if invalid input is received



getObjectId
public Object getObjectId(StateManager sm)(Code)
Accessor for the object id from the StateManager for this object.
Parameters:
  sm - StateManager object id



getObjectState
public String getObjectState(Object obj)(Code)
Accessor for the object state.
Parameters:
  obj - Object The state ("persistent-clean", "detached-dirty" etc)



getPersistenceManager
public Object getPersistenceManager(Object obj)(Code)
Accessor for the persistence manager for this object. The returned object will be a JDO PersistenceManager or null if not managed.
Parameters:
  obj - The object The persistence manager



getSingleFieldIdentityClassNameForByte
public String getSingleFieldIdentityClassNameForByte()(Code)
Accessor for the class name to use for identities when there is a single Byte/byte field. Class name of identity class



getSingleFieldIdentityClassNameForChar
public String getSingleFieldIdentityClassNameForChar()(Code)
Accessor for the class name to use for identities when there is a single Character/char field. Class name of identity class



getSingleFieldIdentityClassNameForInt
public String getSingleFieldIdentityClassNameForInt()(Code)
Accessor for the class name to use for identities when there is a single Integer/int field. Class name of identity class



getSingleFieldIdentityClassNameForLong
public String getSingleFieldIdentityClassNameForLong()(Code)
Accessor for the class name to use for identities when there is a single Long/long field. Class name of identity class



getSingleFieldIdentityClassNameForObject
public String getSingleFieldIdentityClassNameForObject()(Code)
Accessor for the class name to use for identities when there is a single Object field. Class name of identity class



getSingleFieldIdentityClassNameForShort
public String getSingleFieldIdentityClassNameForShort()(Code)
Accessor for the class name to use for identities when there is a single Short/short field. Class name of identity class



getSingleFieldIdentityClassNameForString
public String getSingleFieldIdentityClassNameForString()(Code)
Accessor for the class name to use for identities when there is a single String field. Class name of identity class



getTargetClassForSingleFieldIdentity
public Class getTargetClassForSingleFieldIdentity(Object id)(Code)
Accessor for the target class for the specified single field application-identity.
Parameters:
  id - The identity The target class



getTargetClassNameForSingleFieldIdentity
public String getTargetClassNameForSingleFieldIdentity(Object id)(Code)
Accessor for the target class name for the specified single field identity.
Parameters:
  id - The identity The target class name



getTargetKeyForSingleFieldIdentity
public Object getTargetKeyForSingleFieldIdentity(Object id)(Code)
Accessor for the key object for the specified single field application-identity.
Parameters:
  id - The identity The key object



getVersion
public Object getVersion(StateManager sm)(Code)
Accessor for the version from the StateManager for this object.
Parameters:
  sm - StateManager



getVersionForObject
public Object getVersionForObject(Object obj)(Code)
Method to return the object version for the passed persistable object. Returns null if it is not persistable, or not versioned.
Parameters:
  obj - The object The version



isDeleted
public boolean isDeleted(Object obj)(Code)
Accessor for whether the passed object is deleted.
Parameters:
  obj - The object Whether it is deleted



isDetachable
public boolean isDetachable(Object obj)(Code)
Method to return if the passed object is detachable using this API. Returns whether the object is an instance of javax.jdo.spi.Detachable.
Parameters:
  obj - The object Whether it is detachable



isDetached
public boolean isDetached(Object obj)(Code)
Accessor for whether the passed object is detached.
Parameters:
  obj - The object Whether it is detached



isDirty
public boolean isDirty(Object obj)(Code)
Accessor for whether the passed object is dirty.
Parameters:
  obj - The object Whether it is dirty



isLoaded
public boolean isLoaded(StateManager sm, int fieldNumber)(Code)
Accessor for whether a field is loaded for the object managed by the StateManager
Parameters:
  sm - StateManager
Parameters:
  fieldNumber - Number of the field Whether it is loaded



isNew
public boolean isNew(Object obj)(Code)
Accessor for whether the passed object is new.
Parameters:
  obj - The object Whether it is new



isPersistable
public boolean isPersistable(Object obj)(Code)
Method to return if the passed object is persistable using this API. Returns whether the object is an instance of javax.jdo.spi.PersistenceCapable.
Parameters:
  obj - The object Whether it is persistable



isPersistable
public boolean isPersistable(Class cls)(Code)
Utility method to check if the specified class is of a type that can be persisted for this API. Checks that it implements javax.jdo.spi.PersistenceCapable.
Parameters:
  cls - The class to check Whether the class is persistable



isPersistent
public boolean isPersistent(Object obj)(Code)
Accessor for whether the passed object is persistent.
Parameters:
  obj - The object Whether it is persistent



isSingleFieldIdentity
public boolean isSingleFieldIdentity(Object id)(Code)
Accessor for whether the passed identity is a valid single-field application-identity for this API. Whether it is valid



isSingleFieldIdentityClass
public boolean isSingleFieldIdentityClass(String className)(Code)
Checks whether the passed class name is valid for a single field application-identity for this API.
Parameters:
  className - the full class name Whether it is a single field class



isTransactional
public boolean isTransactional(Object obj)(Code)
Accessor for whether the passed object is transactional.
Parameters:
  obj - The object Whether it is transactional



isValidPrimaryKeyClass
public boolean isValidPrimaryKeyClass(Class pkClass, AbstractClassMetaData cmd, ClassLoaderResolver clr, int noOfPkFields)(Code)
Utility to check if a primary-key class is valid. Will throw a InvalidPrimaryKeyException if it is invalid, otherwise returning true.
Parameters:
  pkClass - The Primary Key class
Parameters:
  cmd - AbstractClassMetaData for the PersistenceCapable class
Parameters:
  clr - the ClassLoaderResolver
Parameters:
  noOfPkFields - Number of primary key fields Whether it is valid



makeFieldDirty
public void makeFieldDirty(Object obj, String fieldName)(Code)
Method to make the field dirty in the object.
Parameters:
  obj - Object
Parameters:
  fieldName - Name of the field to make dirty



newStateManager
public StateManager newStateManager(ObjectManager om, AbstractClassMetaData acmd)(Code)
Method to create a new StateManager for the ObjectManager and class.
Parameters:
  om - ObjectManager
Parameters:
  acmd - MetaData for the class/interface



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.