Objectivity for Java Reference

com.objy.db.app
Class DefaultClusterStrategy

java.lang.Object
  |
  +--com.objy.db.app.DefaultClusterStrategy
All Implemented Interfaces:
ClusterStrategy

public class DefaultClusterStrategy
extends Object
implements ClusterStrategy

Represents the default clustering strategy for assigning basic objects to containers and for assigning containers to databases.

Whenever a session is created, it is initialized to use an instance of DefaultClusterStrategy as its clustering strategy.

You typically do not work directly with instances of this class.

For additional information about clustering and the default clustering strategy, see Clustering Objects.


Constructor Summary
DefaultClusterStrategy()
          Reserved for internal use.
 
Method Summary
 void requestCluster(Object requestObject, ClusterReason reason, Object object)
          Makes the specified object persistent and clusters it with the requesting object.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultClusterStrategy

public DefaultClusterStrategy()
Reserved for internal use.
Method Detail

requestCluster

public void requestCluster(Object requestObject,
                           ClusterReason reason,
                           Object object)
Makes the specified object persistent and clusters it with the requesting object.

This method makes object persistent by passing it as the parameter to the cluster method of requestObject.

Specified by:
requestCluster in interface ClusterStrategy
Parameters:
requestObject - The object requesting that object be made persistent. This object must be a database, a container, or a persistent basic object; it must belong to the session that is in a transaction when requestCluster is called.

reason - The reason for making object persistent.

object - The object being made persistent.

Throws:
ObjyRuntimeException - If object is already persistent.

Objectivity for Java Reference

Copyright © 2000 Objectivity, Inc. All rights reserved.