org.datanucleus.store.rdbms.schema
Class RDBMSTableIndexInfo

java.lang.Object
  extended by org.datanucleus.store.rdbms.schema.RDBMSTableIndexInfo
All Implemented Interfaces:
org.datanucleus.store.schema.ListStoreSchemaData, org.datanucleus.store.schema.StoreSchemaData

public class RDBMSTableIndexInfo
extends java.lang.Object
implements org.datanucleus.store.schema.ListStoreSchemaData

Representation of index information for a table in the datastore. Supports the properties :-


Constructor Summary
RDBMSTableIndexInfo()
           
RDBMSTableIndexInfo(java.lang.String catalog, java.lang.String schema, java.lang.String table)
          Constructor taking just the catalog, schema and table name directly.
 
Method Summary
 void addChild(org.datanucleus.store.schema.StoreSchemaData child)
          Method to add another index col to the table schema.
 void addProperty(java.lang.String name, java.lang.Object value)
          Method to add a property for the table.
 void clearChildren()
          Method to remove all children.
 boolean equals(java.lang.Object obj)
          Indicates whether some object is "equal to" this one.
 org.datanucleus.store.schema.StoreSchemaData getChild(int position)
          Accessor for the index column at the position.
 java.util.List getChildren()
          Accessor for the indices.
 int getNumberOfChildren()
          Accessor for the number of indices cols in the schema for this table.
 org.datanucleus.store.schema.StoreSchemaData getParent()
           
 java.lang.Object getProperty(java.lang.String name)
          Accessor for a property of the table.
 int hashCode()
          Returns a hash code value for this object.
 void setParent(org.datanucleus.store.schema.StoreSchemaData parent)
           
 java.lang.String toString()
          Returns the string representation of this object.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

RDBMSTableIndexInfo

public RDBMSTableIndexInfo()

RDBMSTableIndexInfo

public RDBMSTableIndexInfo(java.lang.String catalog,
                           java.lang.String schema,
                           java.lang.String table)
Constructor taking just the catalog, schema and table name directly.

Parameters:
catalog - Catalog containing the table
schema - Schema containing the table
table - The table name
Method Detail

addChild

public void addChild(org.datanucleus.store.schema.StoreSchemaData child)
Method to add another index col to the table schema.

Specified by:
addChild in interface org.datanucleus.store.schema.ListStoreSchemaData
Parameters:
child - Column

clearChildren

public void clearChildren()
Method to remove all children.

Specified by:
clearChildren in interface org.datanucleus.store.schema.ListStoreSchemaData

getChild

public org.datanucleus.store.schema.StoreSchemaData getChild(int position)
Accessor for the index column at the position.

Specified by:
getChild in interface org.datanucleus.store.schema.ListStoreSchemaData
Parameters:
position - Index
Returns:
PK column at the position

getChildren

public java.util.List getChildren()
Accessor for the indices.

Specified by:
getChildren in interface org.datanucleus.store.schema.ListStoreSchemaData
Returns:
PK information

getNumberOfChildren

public int getNumberOfChildren()
Accessor for the number of indices cols in the schema for this table.

Specified by:
getNumberOfChildren in interface org.datanucleus.store.schema.ListStoreSchemaData
Returns:
Number of indices cols

addProperty

public void addProperty(java.lang.String name,
                        java.lang.Object value)
Method to add a property for the table.

Specified by:
addProperty in interface org.datanucleus.store.schema.StoreSchemaData
Parameters:
name - Name of property
value - Its value

getProperty

public java.lang.Object getProperty(java.lang.String name)
Accessor for a property of the table.

Specified by:
getProperty in interface org.datanucleus.store.schema.StoreSchemaData
Parameters:
name - Name of the property
Returns:
Its value, or null if not defined

getParent

public org.datanucleus.store.schema.StoreSchemaData getParent()
Specified by:
getParent in interface org.datanucleus.store.schema.ListStoreSchemaData

setParent

public void setParent(org.datanucleus.store.schema.StoreSchemaData parent)
Specified by:
setParent in interface org.datanucleus.store.schema.ListStoreSchemaData

equals

public final boolean equals(java.lang.Object obj)
Indicates whether some object is "equal to" this one. Two RDBMSTableIndexInfo are considered equal if their catalog, schema, table are all equal.

Overrides:
equals in class java.lang.Object
Parameters:
obj - the reference object with which to compare
Returns:
true if this object is equal to the obj argument; false otherwise.

hashCode

public final int hashCode()
Returns a hash code value for this object.

Overrides:
hashCode in class java.lang.Object
Returns:
hash code

toString

public java.lang.String toString()
Returns the string representation of this object.

Overrides:
toString in class java.lang.Object
Returns:
string representation of this object.


Copyright © 2009. All Rights Reserved.