|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.mmbase.bridge.util.AbstractNode
org.mmbase.bridge.util.AbstractNodeManager
org.mmbase.bridge.mock.MockNodeManager
public class MockNodeManager
Straight-forward implementation of NodeManager based on a Map with DataType's.
| Nested Class Summary | |
|---|---|
protected class |
MockNodeManager.SystemField
|
| Field Summary | |
|---|---|
protected String |
context
|
protected List<Function<?>> |
functions
|
protected Map<String,Field> |
map
|
protected String |
name
|
protected int |
oType
|
protected String |
parent
|
protected MockCloud |
vcloud
|
| Fields inherited from class org.mmbase.bridge.util.AbstractNodeManager |
|---|
cloud, values |
| Fields inherited from interface org.mmbase.bridge.NodeManager |
|---|
GUI_PLURAL, GUI_SINGULAR, ORDER_CREATE, ORDER_EDIT, ORDER_LIST, ORDER_NONE, ORDER_SEARCH |
| Fields inherited from interface org.mmbase.bridge.Node |
|---|
CLOUD_COMMITNODE_KEY |
| Constructor Summary | |
|---|---|
MockNodeManager(MockCloud cloud,
NodeManagerDescription desc)
|
|
| Method Summary | |
|---|---|
Node |
createNode()
Creates a new node. |
String |
getContext()
Get the security context of the current Node |
protected Map<String,Field> |
getFieldTypes()
|
Collection<Function<?>> |
getFunctions()
This default implementation is based on Node.getNodeManager().Node.getFunctions(). |
String |
getName()
Returns the name of this node manager. |
NodeManager |
getParent()
Retrieve the parent of this NodeManager (the Nodemanager that this nodemanager extends from) |
Map<String,String> |
getProperties()
Retrieve a copy of the node manager's properties |
boolean |
mayCreateNode()
Check if the current user may create a new node of this type. |
void |
setContext(String c)
Sets the security context of this Node (AKA the 'owner' field) |
protected void |
setDefaultsWithCloud(Node node)
|
String |
toString()
Converts the node to a string |
| Methods inherited from class org.mmbase.bridge.util.AbstractNodeManager |
|---|
createFieldList, createNodeList, createQuery, createRelationList, edit, getAllowedRelations, getAllowedRelations, getAllowedRelations, getCloud, getDescendants, getDescription, getDescription, getField, getFields, getFields, getGUIName, getGUIName, getGUIName, getInfo, getInfo, getList, getList, getList, getList, getNodeManager, getProperty, getSize, getValueWithoutProcess, hasField, isNodeManager, setNodeManager, setSize, setValueWithoutChecks, toNodeManager |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface java.lang.Comparable |
|---|
compareTo |
| Field Detail |
|---|
protected final Map<String,Field> map
protected final String name
protected final String parent
protected final MockCloud vcloud
protected final int oType
protected final List<Function<?>> functions
protected String context
| Constructor Detail |
|---|
public MockNodeManager(MockCloud cloud,
NodeManagerDescription desc)
| Method Detail |
|---|
public String getName()
NodeManager
getName in interface NodeManagergetName in class AbstractNodeManagerprotected void setDefaultsWithCloud(Node node)
public Node createNode()
NodeManager
createNode in interface NodeManagercreateNode in class AbstractNodeManagerNodepublic Map<String,String> getProperties()
NodeManager
getProperties in interface NodeManagergetProperties in class AbstractNodeManagerprotected Map<String,Field> getFieldTypes()
getFieldTypes in class AbstractNodeManager
public NodeManager getParent()
throws NotFoundException
NodeManager
getParent in interface NodeManagergetParent in class AbstractNodeManagerNotFoundException - if no parent exists (i.e. this nodeManager is "object")public Collection<Function<?>> getFunctions()
AbstractNodeNode.getNodeManager().Node.getFunctions().
getFunctions in interface NodegetFunctions in class AbstractNodeManagerFunction objects.public String getContext()
Node
getContext in interface NodegetContext in class AbstractNodepublic void setContext(String c)
Node
setContext in interface NodesetContext in class AbstractNodec - The security context to which this node should belong,public boolean mayCreateNode()
NodeManager
mayCreateNode in interface NodeManagermayCreateNode in class AbstractNodeManagerpublic String toString()
Node
toString in interface NodetoString in class AbstractNodeManager
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||