public abstract class MMObjectNodeFunction<R> extends NodeFunction<R>
MMObjectNode instance.
This provides getCoreNode(org.mmbase.module.core.MMObjectBuilder, org.mmbase.bridge.Node), which can be used to produce an instance of that.MMObjectBuilder.executeFunction(org.mmbase.module.core.MMObjectNode, java.lang.String, java.util.List<?>),
Node.getFunctionValue(java.lang.String, java.util.List<?>),
BeanFunction,
Serialized FormautoReturnType, name, returnType| Constructor and Description |
|---|
MMObjectNodeFunction(String name,
Parameter... def) |
MMObjectNodeFunction(String name,
Parameter<?>[] def,
ReturnType<R> returnType) |
| Modifier and Type | Method and Description |
|---|---|
protected MMObjectNode |
getCoreNode(MMObjectBuilder builder,
Node node)
Utility method to convert a
Node to a MMObjectNode. |
protected R |
getFunctionValue(MMObjectNode coreNode,
Parameters parameters)
Implements the function on a certain node.
|
protected static Node |
getNode(MMObjectNode coreNode,
Parameters parameters) |
Function<R> |
newInstance(MMObjectNode node)
Returns a new instance of NodeInstanceFunction, which represents an actual Function.
|
static <Q> Function<Q> |
newInstance(NodeFunction<Q> function,
MMObjectNode node) |
getFunctionNameAndFillArgs, getFunctionValue, getFunctionValue, getFunctionValue, getFunctionValueForNode, getNode, getNodeParameterDef, getReturnType, newInstance, wrapcompareTo, createParameters, equals, getDescription, getFunctionValueWithList, getName, getParameterDefinition, hashCode, setDescription, setParameterDefinition, setReturnType, toStringpublic MMObjectNodeFunction(String name, Parameter<?>[] def, ReturnType<R> returnType)
public static <Q> Function<Q> newInstance(NodeFunction<Q> function, MMObjectNode node)
public final Function<R> newInstance(MMObjectNode node)
protected static Node getNode(MMObjectNode coreNode, Parameters parameters)
protected final R getFunctionValue(MMObjectNode coreNode, Parameters parameters)
NodeFunction.getFunctionValue(org.mmbase.bridge.Node, Parameters). Overriding the
bridge version has two advantages. It's easier, and mmbase security will be honoured. That
last thing is of course not necesary if you are not going to use other nodes.
XXX: made final because it does not work well if you don't implement a bridge versionprotected final MMObjectNode getCoreNode(MMObjectBuilder builder, Node node)
Node to a MMObjectNode.MMBase 1.9-SNAPSHOT - ${javadoctimestamp}