org.modeshape.graph.request
Class CollectGarbageRequest

java.lang.Object
  extended by org.modeshape.graph.request.Request
      extended by org.modeshape.graph.request.CollectGarbageRequest
All Implemented Interfaces:
Serializable

public final class CollectGarbageRequest
extends Request

Request that garbage collection be performed. Processors may disregard this request.

See Also:
Serialized Form

Constructor Summary
CollectGarbageRequest()
          Create a request to destroy an existing workspace.
 
Method Summary
 boolean equals(Object obj)
          
 RequestType getType()
          Returns the type of the request
 int hashCode()
          
 boolean isAdditionalPassRequired()
          Determine whether additional garbage collection passes are still required after this pass.
 boolean isReadOnly()
          Return whether this request only reads information.
 void setAdditionalPassRequired(boolean additionalPassRequired)
          After collecting garbage during one pass (per this request), set whether additional passes are still required.
 String toString()
          
 
Methods inherited from class org.modeshape.graph.request.Request
cancel, checkNotFrozen, freeze, getError, hasError, isCancelled, isFrozen, printable, printable, setError, setLatchForFreezing
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

CollectGarbageRequest

public CollectGarbageRequest()
Create a request to destroy an existing workspace.

Method Detail

isReadOnly

public boolean isReadOnly()
Return whether this request only reads information.

Specified by:
isReadOnly in class Request
Returns:
true if this request reads information, or false if it requests that the repository content be changed in some way
See Also:
Request.isReadOnly()

hashCode

public int hashCode()

Overrides:
hashCode in class Object
See Also:
Object.hashCode()

equals

public boolean equals(Object obj)

Overrides:
equals in class Object
See Also:
Object.equals(java.lang.Object)

setAdditionalPassRequired

public void setAdditionalPassRequired(boolean additionalPassRequired)
After collecting garbage during one pass (per this request), set whether additional passes are still required.

Parameters:
additionalPassRequired - true if this pass did not collect all known gargabe and additional passes are required, or false otherwise
Throws:
IllegalStateException - if the request is frozen

isAdditionalPassRequired

public boolean isAdditionalPassRequired()
Determine whether additional garbage collection passes are still required after this pass. In other words, if 'true', then this pass did not completely collect all known garbage.

Returns:
true if this pass did not collect all known gargabe and additional passes are required, or false otherwise

toString

public String toString()

Overrides:
toString in class Object
See Also:
Object.toString()

getType

public RequestType getType()
Description copied from class: Request
Returns the type of the request

Specified by:
getType in class Request
Returns:
the type of the request


Copyright © 2008-2011 JBoss, a division of Red Hat. All Rights Reserved.