Oracle Fusion Middleware Java API Reference for Oracle Extension SDK Reference
11g Release 1 (11.1.1.6.0)

E13403-07

oracle.javatools.db.property
Class PropertyInfo

java.lang.Object
  extended by oracle.javatools.db.property.PropertyInfo
All Implemented Interfaces:
java.lang.Comparable

public abstract class PropertyInfo
extends java.lang.Object
implements java.lang.Comparable

Wrapper for the PropertyDescriptor beans class that includes some db api specific accessors for the annotation information.

Since:
11.0

Field Summary
static java.lang.String ID
           
static java.lang.String NAME
           
 
Constructor Summary
PropertyInfo()
           
 
Method Summary
 int compareTo(java.lang.Object o)
          The implementation of this method allows a collection of PropertyInfo objects to be sorted lexicographically by the property name.
 boolean equals(java.lang.Object o)
           
protected abstract  boolean equalsImpl(PropertyInfo info)
           
abstract  java.lang.Class getPropertyClass()
          Returns the class expected for values of this property.
abstract  java.lang.String getPropertyName()
          Returns the name of the property.
abstract  java.lang.String getPropertyPath()
          Gets the path for the property.
abstract  java.lang.Object getPropertyValue(java.lang.Object bean)
          Invokes the getter method using owningObject as the object on which the getter is called.
 java.lang.Class getReferencedClass()
          If this property is a reference property (i.e.
protected abstract  boolean isAfter()
          Returns true if the get OR set method for this property has the After annotation.
abstract  boolean isGetTransient()
          Returns true if the get method for this property has the Transient annotation.
 boolean isInternalReference()
          If this class is a reference property (i.e.
abstract  boolean isSetTransient()
          Returns true if the set method for this property has the Transient annotation.
 boolean isStaticReference()
          Only valid for properties with a return type of DBObjectID.
 boolean isTransient()
          Returns true if the get OR set method for this property has the Transient annotation.
abstract  void setPropertyValue(java.lang.Object bean, java.lang.Object value)
          Invokes the setter method using owningObject as the object on which the setter is called, and value as the value passed to the setter.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ID

public static final java.lang.String ID
See Also:
Constant Field Values

NAME

public static final java.lang.String NAME
See Also:
Constant Field Values
Constructor Detail

PropertyInfo

public PropertyInfo()
Method Detail

getPropertyName

public abstract java.lang.String getPropertyName()
Returns the name of the property.


getPropertyPath

public abstract java.lang.String getPropertyPath()
Gets the path for the property. For bean methods this will just be the property name, but other properties may be nested (e.g. under in the "properties" map.


getPropertyClass

public abstract java.lang.Class getPropertyClass()
Returns the class expected for values of this property.


getPropertyValue

public abstract java.lang.Object getPropertyValue(java.lang.Object bean)
Invokes the getter method using owningObject as the object on which the getter is called. This method will return null if any exception occurs while invoking the getter method.


setPropertyValue

public abstract void setPropertyValue(java.lang.Object bean,
                                      java.lang.Object value)
                               throws java.lang.Exception
Invokes the setter method using owningObject as the object on which the setter is called, and value as the value passed to the setter. If any Exception is encountered invoking the setter it is passed on to the caller.

Throws:
java.lang.Exception

getReferencedClass

public java.lang.Class getReferencedClass()
If this property is a reference property (i.e. property class is DBObjectID) this returns the expected class of object that the property references. By default this is DBObject.class. For non-reference properties this method will return null.

Returns:
the expected class of object referenced, or null if this property isn't a reference property.

isInternalReference

public boolean isInternalReference()
If this class is a reference property (i.e. property class is DBObjectID) then this returns true if the referenced object is owned by the same SchemaObject as the object this property is on.

Returns:
true if this property is a reference property and the object it references is under the same owning SchemaObject as the object this property is on.

isGetTransient

public abstract boolean isGetTransient()
Returns true if the get method for this property has the Transient annotation.

Returns:
true if the get method for this property is "transient"
See Also:
Transient

isSetTransient

public abstract boolean isSetTransient()
Returns true if the set method for this property has the Transient annotation.

Returns:
true if the set method for this property is "transient"
See Also:
Transient

isTransient

public boolean isTransient()
Returns true if the get OR set method for this property has the Transient annotation.

See Also:
Transient

isAfter

protected abstract boolean isAfter()
Returns true if the get OR set method for this property has the After annotation.

Returns:
true if this property is "after" the others on the bean
See Also:
After

compareTo

public int compareTo(java.lang.Object o)
The implementation of this method allows a collection of PropertyInfo objects to be sorted lexicographically by the property name.

Specified by:
compareTo in interface java.lang.Comparable

equals

public boolean equals(java.lang.Object o)
Overrides:
equals in class java.lang.Object

equalsImpl

protected abstract boolean equalsImpl(PropertyInfo info)

isStaticReference

public boolean isStaticReference()
Only valid for properties with a return type of DBObjectID. If true it means that the property is static and shouldn't be replaced by any call to replaceReferenceIDs.

Returns:
false by default, or true to omit the property value from and replaceReferenceIDs logic on DBObject.

Oracle Fusion Middleware Java API Reference for Oracle Extension SDK Reference
11g Release 1 (11.1.1.6.0)

E13403-07

Copyright © 1997, 2011, Oracle. All rights reserved.