org.datanucleus.metadata
Class FetchPlanMetaData

java.lang.Object
  extended by org.datanucleus.metadata.MetaData
      extended by org.datanucleus.metadata.FetchPlanMetaData
All Implemented Interfaces:
java.io.Serializable

public class FetchPlanMetaData
extends MetaData

FetchPlan defined in MetaData.

See Also:
Serialized Form

Field Summary
protected  java.util.List<FetchGroupMetaData> fetchGroups
          Series of Fetch Groups used in this FetchPlan.
protected  int fetchSize
          Fetch Size for use when querying using this FetchPlan.
protected  int maxFetchDepth
          Max fetch depth for this FetchPlan.
 
Fields inherited from class org.datanucleus.metadata.MetaData
extensions, LOCALISER, METADATA_CREATED_STATE, METADATA_INITIALISED_STATE, METADATA_POPULATED_STATE, METADATA_USED_STATE, metaDataState, parent, VENDOR_NAME, VENDOR_NAME_OLD
 
Constructor Summary
FetchPlanMetaData(java.lang.String name)
          Constructor for a fetch plan with a name.
 
Method Summary
 void addFetchGroup(FetchGroupMetaData fgmd)
          Add a new FetchGroupMetaData
 FetchGroupMetaData[] getFetchGroupMetaData()
          Accessor for fetchGroupMetaData
 int getFetchSize()
           
 int getMaxFetchDepth()
           
 java.lang.String getName()
          Accessor for name
 int getNumberOfFetchGroups()
           
 FetchGroupMetaData newFetchGroupMetaData(java.lang.String name)
          Method to create a new FetchGroup metadata, add it and return it.
 FetchPlanMetaData setFetchSize(int fetchSize)
           
 FetchPlanMetaData setFetchSize(java.lang.String fetchSize)
           
 FetchPlanMetaData setMaxFetchDepth(int maxFetchDepth)
           
 FetchPlanMetaData setMaxFetchDepth(java.lang.String maxFetchDepth)
           
 java.lang.String toString(java.lang.String prefix, java.lang.String indent)
          Returns a string representation of the object.
 
Methods inherited from class org.datanucleus.metadata.MetaData
addExtension, addExtension, assertIfInitialised, getExtensions, getNoOfExtensions, getParent, getValueForExtension, getValuesForExtension, hasExtension, initialise, isInitialised, isPopulated, isUsed, newExtensionMetaData, removeExtension, setParent, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

maxFetchDepth

protected int maxFetchDepth
Max fetch depth for this FetchPlan.


fetchSize

protected int fetchSize
Fetch Size for use when querying using this FetchPlan.


fetchGroups

protected java.util.List<FetchGroupMetaData> fetchGroups
Series of Fetch Groups used in this FetchPlan. Only used during construction.

Constructor Detail

FetchPlanMetaData

public FetchPlanMetaData(java.lang.String name)
Constructor for a fetch plan with a name. Set fields using setters, before populate().

Parameters:
name - Name of fetch plan
Method Detail

getName

public final java.lang.String getName()
Accessor for name

Returns:
Returns the name.

getMaxFetchDepth

public final int getMaxFetchDepth()

setMaxFetchDepth

public FetchPlanMetaData setMaxFetchDepth(int maxFetchDepth)

setMaxFetchDepth

public FetchPlanMetaData setMaxFetchDepth(java.lang.String maxFetchDepth)

getFetchSize

public final int getFetchSize()

getNumberOfFetchGroups

public int getNumberOfFetchGroups()

setFetchSize

public FetchPlanMetaData setFetchSize(int fetchSize)

setFetchSize

public FetchPlanMetaData setFetchSize(java.lang.String fetchSize)

getFetchGroupMetaData

public final FetchGroupMetaData[] getFetchGroupMetaData()
Accessor for fetchGroupMetaData

Returns:
Returns the fetchGroupMetaData.

addFetchGroup

public void addFetchGroup(FetchGroupMetaData fgmd)
Add a new FetchGroupMetaData

Parameters:
fgmd - the fetch group

newFetchGroupMetaData

public FetchGroupMetaData newFetchGroupMetaData(java.lang.String name)
Method to create a new FetchGroup metadata, add it and return it.

Parameters:
name - Name of the fetch group
Returns:
The new fetch group metadata

toString

public java.lang.String toString(java.lang.String prefix,
                                 java.lang.String indent)
Returns a string representation of the object. This can be used as part of a facility to output a MetaData file.

Overrides:
toString in class MetaData
Parameters:
prefix - prefix string
indent - indent string
Returns:
a string representation of the object.


Copyright © 2010. All Rights Reserved.