org.jboss.dna.graph.request
Class GetWorkspacesRequest

java.lang.Object
  extended by org.jboss.dna.graph.request.Request
      extended by org.jboss.dna.graph.request.CacheableRequest
          extended by org.jboss.dna.graph.request.GetWorkspacesRequest
All Implemented Interfaces:
Serializable, Cacheable

public class GetWorkspacesRequest
extends CacheableRequest

A request to obtain the information about the workspaces that are available.

See Also:
Serialized Form

Constructor Summary
GetWorkspacesRequest()
          Create a request to obtain the information about the available workspaces.
 
Method Summary
 void cancel()
          Cancel this request.
 boolean equals(Object obj)
          
 Set<String> getAvailableWorkspaceNames()
          Get the names of workspaces that are available (at least to the current user)
 int hashCode()
          
 boolean isReadOnly()
          Return whether this request only reads information.
 void setAvailableWorkspaceNames(Set<String> availableWorkspaceNames)
          Set the names of the workspaces that are available (at least to the current user)
 String toString()
          
 
Methods inherited from class org.jboss.dna.graph.request.CacheableRequest
getCachePolicy, getTimeLoaded, setCachePolicy, setTimeLoaded
 
Methods inherited from class org.jboss.dna.graph.request.Request
freeze, getError, hasError, isCancelled, isFrozen, setError, setLatchForFreezing
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

GetWorkspacesRequest

public GetWorkspacesRequest()
Create a request to obtain the information about the available workspaces.

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()

getAvailableWorkspaceNames

public Set<String> getAvailableWorkspaceNames()
Get the names of workspaces that are available (at least to the current user)

Returns:
the set of workspace names, or null if the request has not been completed

setAvailableWorkspaceNames

public void setAvailableWorkspaceNames(Set<String> availableWorkspaceNames)
Set the names of the workspaces that are available (at least to the current user)

Parameters:
availableWorkspaceNames - Sets availableWorkspaceNames to the specified value.
Throws:
IllegalStateException - if the request is frozen

cancel

public void cancel()
Cancel this request. After this method is called, the cancellation flag is set, and any current or future processing of the request may be affected by the cancellation. (Note however, that processors may choose to not respect this request.)

This method is safe to be called by different threads.

Overrides:
cancel in class Request
See Also:
Request.cancel()

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)

toString

public String toString()

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


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