org.apache.jackrabbit.rmi.server
Class ServerNodeType

java.lang.Object
  extended by java.rmi.server.RemoteObject
      extended by java.rmi.server.RemoteServer
          extended by java.rmi.server.UnicastRemoteObject
              extended by org.apache.jackrabbit.rmi.server.ServerObject
                  extended by org.apache.jackrabbit.rmi.server.ServerNodeType
All Implemented Interfaces:
Serializable, Remote, RemoteNodeType

public class ServerNodeType
extends ServerObject
implements RemoteNodeType

Remote adapter for the JCR NodeType interface. This class makes a local node type available as an RMI service using the RemoteNodeType interface.

See Also:
NodeType, RemoteNodeType, Serialized Form

Field Summary
 
Fields inherited from class java.rmi.server.RemoteObject
ref
 
Constructor Summary
ServerNodeType(NodeType type, RemoteAdapterFactory factory)
          Creates a remote adapter for the given local node type.
 
Method Summary
 boolean canAddChildNode(String name)
          Remote version of the NodeType.canAddChildNode(String) method.
 boolean canAddChildNode(String name, String type)
          Remote version of the NodeType.canAddChildNode(String,String) method.
 boolean canRemoveItem(String name)
          Remote version of the NodeType.canRemoveItem(String) method.
 boolean canSetProperty(String name, Value value)
          Remote version of the NodeType.canSetProperty(String,Value) method.
 boolean canSetProperty(String name, Value[] values)
          Remote version of the NodeType.canSetProperty(String,Value[]) method.
 RemoteNodeDefinition[] getChildNodeDefs()
          Remote version of the NodeType.getChildNodeDefs() method.
 RemoteNodeDefinition[] getDeclaredChildNodeDefs()
          Remote version of the NodeType.getDeclaredChildNodeDefs() method.
 RemotePropertyDefinition[] getDeclaredPropertyDefs()
          Remote version of the NodeType.getDeclaredPropertyDefs() method.
 RemoteNodeType[] getDeclaredSupertypes()
          Remote version of the NodeType.getDeclaredSupertypes() method.
 String getName()
          Remote version of the NodeType.getName() method.
 String getPrimaryItemName()
          Remote version of the NodeType.getPrimaryItemName() method.
 RemotePropertyDefinition[] getPropertyDefs()
          Remote version of the NodeType.getPropertyDefs() method.
 RemoteNodeType[] getSupertypes()
          Remote version of the NodeType.getSupertypes() method.
 boolean hasOrderableChildNodes()
          Remote version of the NodeType.hasOrderableChildNodes() method.
 boolean isAbstract()
          Remote version of the NodeType.isAbstract() method.
 boolean isMixin()
          Remote version of the NodeType.isMixin() method.
 boolean isNodeType(String type)
          Remote version of the NodeType.isNodeType(String) method.
 
Methods inherited from class org.apache.jackrabbit.rmi.server.ServerObject
getFactory, getRemoteItem, getRemoteNode, getRemoteNodeTypeArray, getRepositoryException, getSerialValue, getSerialValues
 
Methods inherited from class java.rmi.server.UnicastRemoteObject
clone, exportObject, exportObject, exportObject, unexportObject
 
Methods inherited from class java.rmi.server.RemoteServer
getClientHost, getLog, setLog
 
Methods inherited from class java.rmi.server.RemoteObject
equals, getRef, hashCode, toString, toStub
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ServerNodeType

public ServerNodeType(NodeType type,
                      RemoteAdapterFactory factory)
               throws RemoteException
Creates a remote adapter for the given local node type.

Parameters:
type - local node type
factory - remote adapter factory
Throws:
RemoteException - on RMI errors
Method Detail

getName

public String getName()
               throws RemoteException
Remote version of the NodeType.getName() method.

Specified by:
getName in interface RemoteNodeType
Returns:
node type name
Throws:
RemoteException - on RMI errors

isMixin

public boolean isMixin()
                throws RemoteException
Remote version of the NodeType.isMixin() method.

Specified by:
isMixin in interface RemoteNodeType
Returns:
true if this is a mixin type, false otherwise
Throws:
RemoteException - on RMI errors

isAbstract

public boolean isAbstract()
                   throws RemoteException
Remote version of the NodeType.isAbstract() method.

Specified by:
isAbstract in interface RemoteNodeType
Returns:
true if this is an abstract type, false otherwise
Throws:
RemoteException - on RMI errors

hasOrderableChildNodes

public boolean hasOrderableChildNodes()
                               throws RemoteException
Remote version of the NodeType.hasOrderableChildNodes() method.

Specified by:
hasOrderableChildNodes in interface RemoteNodeType
Returns:
true if nodes of this type has orderable child nodes, false otherwise
Throws:
RemoteException - on RMI errors

getSupertypes

public RemoteNodeType[] getSupertypes()
                               throws RemoteException
Remote version of the NodeType.getSupertypes() method.

Specified by:
getSupertypes in interface RemoteNodeType
Returns:
supertypes
Throws:
RemoteException - on RMI errors

getDeclaredSupertypes

public RemoteNodeType[] getDeclaredSupertypes()
                                       throws RemoteException
Remote version of the NodeType.getDeclaredSupertypes() method.

Specified by:
getDeclaredSupertypes in interface RemoteNodeType
Returns:
declared supertypes
Throws:
RemoteException - on RMI errors

isNodeType

public boolean isNodeType(String type)
                   throws RemoteException
Remote version of the NodeType.isNodeType(String) method.

Specified by:
isNodeType in interface RemoteNodeType
Parameters:
type - node type name
Returns:
true if this node type is or extends the given node type, false otherwise
Throws:
RemoteException - on RMI errors

getPropertyDefs

public RemotePropertyDefinition[] getPropertyDefs()
                                           throws RemoteException
Remote version of the NodeType.getPropertyDefs() method.

Specified by:
getPropertyDefs in interface RemoteNodeType
Returns:
property definitions
Throws:
RemoteException - on RMI errors

getDeclaredPropertyDefs

public RemotePropertyDefinition[] getDeclaredPropertyDefs()
                                                   throws RemoteException
Remote version of the NodeType.getDeclaredPropertyDefs() method.

Specified by:
getDeclaredPropertyDefs in interface RemoteNodeType
Returns:
declared property definitions
Throws:
RemoteException - on RMI errors

getChildNodeDefs

public RemoteNodeDefinition[] getChildNodeDefs()
                                        throws RemoteException
Remote version of the NodeType.getChildNodeDefs() method.

Specified by:
getChildNodeDefs in interface RemoteNodeType
Returns:
child node definitions
Throws:
RemoteException - on RMI errors

getDeclaredChildNodeDefs

public RemoteNodeDefinition[] getDeclaredChildNodeDefs()
                                                throws RemoteException
Remote version of the NodeType.getDeclaredChildNodeDefs() method.

Specified by:
getDeclaredChildNodeDefs in interface RemoteNodeType
Returns:
declared child node definitions
Throws:
RemoteException - on RMI errors

canSetProperty

public boolean canSetProperty(String name,
                              Value value)
                       throws RemoteException
Remote version of the NodeType.canSetProperty(String,Value) method.

Specified by:
canSetProperty in interface RemoteNodeType
Parameters:
name - property name
value - property value
Returns:
true if the property can be set, false otherwise
Throws:
RemoteException - on RMI errors

canSetProperty

public boolean canSetProperty(String name,
                              Value[] values)
                       throws RemoteException
Remote version of the NodeType.canSetProperty(String,Value[]) method.

Specified by:
canSetProperty in interface RemoteNodeType
Parameters:
name - property name
values - property values
Returns:
true if the property can be set, false otherwise
Throws:
RemoteException - on RMI errors

canAddChildNode

public boolean canAddChildNode(String name)
                        throws RemoteException
Remote version of the NodeType.canAddChildNode(String) method.

Specified by:
canAddChildNode in interface RemoteNodeType
Parameters:
name - child node name
Returns:
true if the child node can be added, false otherwise
Throws:
RemoteException - on RMI errors

canAddChildNode

public boolean canAddChildNode(String name,
                               String type)
                        throws RemoteException
Remote version of the NodeType.canAddChildNode(String,String) method.

Specified by:
canAddChildNode in interface RemoteNodeType
Parameters:
name - child node name
type - child node type
Returns:
true if the child node can be added, false otherwise
Throws:
RemoteException - on RMI errors

canRemoveItem

public boolean canRemoveItem(String name)
                      throws RemoteException
Remote version of the NodeType.canRemoveItem(String) method.

Specified by:
canRemoveItem in interface RemoteNodeType
Parameters:
name - item name
Returns:
true if the item can be removed, false otherwise
Throws:
RemoteException - on RMI errors

getPrimaryItemName

public String getPrimaryItemName()
                          throws RemoteException
Remote version of the NodeType.getPrimaryItemName() method.

Specified by:
getPrimaryItemName in interface RemoteNodeType
Returns:
primary item name
Throws:
RemoteException - on RMI errors


Copyright © 2004-2010 The Apache Software Foundation. All Rights Reserved.