org.apache.jackrabbit.rmi.client
Class ClientNodeType

java.lang.Object
  extended by org.apache.jackrabbit.rmi.client.ClientObject
      extended by org.apache.jackrabbit.rmi.client.ClientNodeType
All Implemented Interfaces:
NodeType, NodeTypeDefinition

public class ClientNodeType
extends ClientObject
implements NodeType

Local adapter for the JCR-RMI RemoteNodeType interface. This class makes a remote node type locally available using the JCR NodeType interface.

See Also:
NodeType, RemoteNodeType

Field Summary
 
Fields inherited from interface javax.jcr.nodetype.NodeType
MIX_CREATED, MIX_LANGUAGE, MIX_LAST_MODIFIED, MIX_LIFECYCLE, MIX_LOCKABLE, MIX_MIMETYPE, MIX_REFERENCEABLE, MIX_SHAREABLE, MIX_SIMPLE_VERSIONABLE, MIX_TITLE, MIX_VERSIONABLE, NT_ACTIVITY, NT_ADDRESS, NT_BASE, NT_CHILD_NODE_DEFINITION, NT_CONFIGURATION, NT_FILE, NT_FOLDER, NT_FROZEN_NODE, NT_HIERARCHY_NODE, NT_LINKED_FILE, NT_NODE_TYPE, NT_PROPERTY_DEFINITION, NT_QUERY, NT_RESOURCE, NT_UNSTRUCTURED, NT_VERSION, NT_VERSION_HISTORY, NT_VERSIONED_CHILD
 
Constructor Summary
ClientNodeType(RemoteNodeType remote, LocalAdapterFactory factory)
          Creates a local adapter for the given remote node type.
 
Method Summary
 boolean canAddChildNode(String name)
          
 boolean canAddChildNode(String name, String type)
          
 boolean canRemoveItem(String name)
          
 boolean canRemoveNode(String nodeName)
           
 boolean canRemoveProperty(String propertyName)
           
 boolean canSetProperty(String name, Value value)
          
 boolean canSetProperty(String name, Value[] values)
          
 NodeDefinition[] getChildNodeDefinitions()
          
 NodeDefinition[] getDeclaredChildNodeDefinitions()
          
 PropertyDefinition[] getDeclaredPropertyDefinitions()
          
 NodeTypeIterator getDeclaredSubtypes()
           
 String[] getDeclaredSupertypeNames()
           
 NodeType[] getDeclaredSupertypes()
          
 String getName()
          
 String getPrimaryItemName()
          
protected  PropertyDefinition[] getPropertyDefArray(RemotePropertyDefinition[] remotes)
          Utility method for creating an array of local property definition adapters for an array of remote property definitions.
 PropertyDefinition[] getPropertyDefinitions()
          
 NodeTypeIterator getSubtypes()
           
 NodeType[] getSupertypes()
          
 boolean hasOrderableChildNodes()
          
 boolean isAbstract()
           
 boolean isMixin()
          
 boolean isNodeType(String type)
          
 boolean isQueryable()
           
 
Methods inherited from class org.apache.jackrabbit.rmi.client.ClientObject
getFactory, getItem, getNode, getNodeTypeArray
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ClientNodeType

public ClientNodeType(RemoteNodeType remote,
                      LocalAdapterFactory factory)
Creates a local adapter for the given remote node type.

Parameters:
remote - remote node type
factory - local adapter factory
Method Detail

getPropertyDefArray

protected PropertyDefinition[] getPropertyDefArray(RemotePropertyDefinition[] remotes)
Utility method for creating an array of local property definition adapters for an array of remote property definitions. The property definition adapters are created using the local adapter factory.

A null input is treated as an empty array.

Parameters:
remotes - remote property definitions
Returns:
local property definition array

getName

public String getName()

Specified by:
getName in interface NodeTypeDefinition

isMixin

public boolean isMixin()

Specified by:
isMixin in interface NodeTypeDefinition

hasOrderableChildNodes

public boolean hasOrderableChildNodes()

Specified by:
hasOrderableChildNodes in interface NodeTypeDefinition

getSupertypes

public NodeType[] getSupertypes()

Specified by:
getSupertypes in interface NodeType

getDeclaredSupertypes

public NodeType[] getDeclaredSupertypes()

Specified by:
getDeclaredSupertypes in interface NodeType

isNodeType

public boolean isNodeType(String type)

Specified by:
isNodeType in interface NodeType

getPropertyDefinitions

public PropertyDefinition[] getPropertyDefinitions()

Specified by:
getPropertyDefinitions in interface NodeType

getDeclaredPropertyDefinitions

public PropertyDefinition[] getDeclaredPropertyDefinitions()

Specified by:
getDeclaredPropertyDefinitions in interface NodeTypeDefinition

getChildNodeDefinitions

public NodeDefinition[] getChildNodeDefinitions()

Specified by:
getChildNodeDefinitions in interface NodeType

getDeclaredChildNodeDefinitions

public NodeDefinition[] getDeclaredChildNodeDefinitions()

Specified by:
getDeclaredChildNodeDefinitions in interface NodeTypeDefinition

canSetProperty

public boolean canSetProperty(String name,
                              Value value)

Specified by:
canSetProperty in interface NodeType

canSetProperty

public boolean canSetProperty(String name,
                              Value[] values)

Specified by:
canSetProperty in interface NodeType

canAddChildNode

public boolean canAddChildNode(String name)

Specified by:
canAddChildNode in interface NodeType

canAddChildNode

public boolean canAddChildNode(String name,
                               String type)

Specified by:
canAddChildNode in interface NodeType

canRemoveItem

public boolean canRemoveItem(String name)

Specified by:
canRemoveItem in interface NodeType

getPrimaryItemName

public String getPrimaryItemName()

Specified by:
getPrimaryItemName in interface NodeTypeDefinition

canRemoveNode

public boolean canRemoveNode(String nodeName)
Specified by:
canRemoveNode in interface NodeType

canRemoveProperty

public boolean canRemoveProperty(String propertyName)
Specified by:
canRemoveProperty in interface NodeType

getDeclaredSubtypes

public NodeTypeIterator getDeclaredSubtypes()
Specified by:
getDeclaredSubtypes in interface NodeType

getSubtypes

public NodeTypeIterator getSubtypes()
Specified by:
getSubtypes in interface NodeType

getDeclaredSupertypeNames

public String[] getDeclaredSupertypeNames()
Specified by:
getDeclaredSupertypeNames in interface NodeTypeDefinition

isAbstract

public boolean isAbstract()
Specified by:
isAbstract in interface NodeTypeDefinition

isQueryable

public boolean isQueryable()
Specified by:
isQueryable in interface NodeTypeDefinition


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