![]() |
0.10.8-alpha
|
Representation of a unary constant. More...
Public Member Functions | |
| Constant (Object value) | |
| Creates a new constant. More... | |
| void | evaluate (Object[] inputs, Object[] outputs, Context context, EventTracker tracker) |
| void | evaluate (Object[] inputs, Object[] outputs) |
| boolean | evaluatePartial (Object[] inputs, Object[] outputs, Context context) |
| int | getInputArity () |
| int | getOutputArity () |
| void | reset () |
| Constant | duplicate (boolean with_state) |
| Duplicates an object. More... | |
| void | getInputTypesFor (Set< Class<?>> classes, int index) |
| Class<?> | getOutputTypeFor (int index) |
| String | toString () |
| Object | getValue () |
| Gets the actual object that this constant processor returns. More... | |
| Object | printState () |
| Constant | readState (Object o) |
Public Member Functions inherited from ca.uqac.lif.cep.functions.Function | |
| void | evaluate (Object[] inputs, Object[] outputs, Context context) |
| Evaluates the outputs of the function, given some inputs. More... | |
| abstract void | evaluate (Object[] inputs, Object[] outputs, Context context, EventTracker tracker) |
| Evaluates the outputs of the function, given some inputs. More... | |
| void | evaluate (Object[] inputs, Object[] outputs) |
| Evaluates the outputs of the function, given some inputs. More... | |
| boolean | evaluatePartial (Object[] inputs, Object[] outputs, Context context) |
| Evaluates the outputs of the function, given some inputs. More... | |
| boolean | evaluateLazy (Object[] inputs, Object[] outputs) |
| Attempts a lazy evaluation of the function, given some inputs. More... | |
| abstract int | getInputArity () |
| Gets the function's input arity, i.e. More... | |
| abstract int | getOutputArity () |
| Gets the function's output arity, i.e. More... | |
| void | reset () |
| Resets the function to its initial state. More... | |
| abstract void | getInputTypesFor (Set< Class<?>> classes, int index) |
| Populates the set of classes accepted by the function for its i-th input. More... | |
| abstract Class<?> | getOutputTypeFor (int index) |
| Returns the type of the events produced by the function for its i-th output. More... | |
| Future< Object[]> | evaluateFast (Object[] inputs, Object[] outputs, Context context, ExecutorService service) |
| Utility method that delegates the call to evaluate() More... | |
| final Function | duplicate () |
| Duplicates an object and sets it to its initial state. More... | |
| abstract Function | duplicate (boolean with_state) |
| Duplicates an object. More... | |
| Object | print (ObjectPrinter<?> printer) |
| final Function | read (ObjectReader<?> reader, Object o) throws FunctionException |
| Reads the content of a function from a serialized object. More... | |
Static Public Attributes | |
| static final transient Constant | ZERO = new Constant(0) |
| A constant representing the number zero. More... | |
| static final transient Constant | ONE = new Constant(1) |
| A constant representing the number one. More... | |
Static Public Attributes inherited from ca.uqac.lif.cep.functions.Function | |
| static final int | s_maxInputArity = 10 |
| The maximum input arity that a function can have. More... | |
Additional Inherited Members | |
Protected Member Functions inherited from ca.uqac.lif.cep.functions.Function | |
| Object | printState () |
| Produces an object that represents the state of the current function. More... | |
| Function | readState (Object o) |
| Reads the state of a function and uses it to create a new instance. More... | |
| ca.uqac.lif.cep.functions.Constant.Constant | ( | Object | value | ) |
Creates a new constant.
| value | The value associated to this constant |
Definition at line 53 of file Constant.java.
| Constant ca.uqac.lif.cep.functions.Constant.duplicate | ( | boolean | with_state | ) |
Duplicates an object.
Optionally, set the object into the same state as the source object.
| with_state | Set to true to replicate the object's state, false to create a new copy in the initial state. |
Implements ca.uqac.lif.cep.Duplicable.
Definition at line 101 of file Constant.java.
| void ca.uqac.lif.cep.functions.Constant.evaluate | ( | Object [] | inputs, |
| Object [] | outputs, | ||
| Context | context, | ||
| EventTracker | tracker | ||
| ) |
Definition at line 60 of file Constant.java.
| void ca.uqac.lif.cep.functions.Constant.evaluate | ( | Object [] | inputs, |
| Object [] | outputs | ||
| ) |
Definition at line 70 of file Constant.java.
| boolean ca.uqac.lif.cep.functions.Constant.evaluatePartial | ( | Object [] | inputs, |
| Object [] | outputs, | ||
| Context | context | ||
| ) |
Definition at line 76 of file Constant.java.
| int ca.uqac.lif.cep.functions.Constant.getInputArity | ( | ) |
Definition at line 83 of file Constant.java.
| void ca.uqac.lif.cep.functions.Constant.getInputTypesFor | ( | Set< Class<?>> | classes, |
| int | index | ||
| ) |
Definition at line 107 of file Constant.java.
| int ca.uqac.lif.cep.functions.Constant.getOutputArity | ( | ) |
Definition at line 89 of file Constant.java.
| Class<?> ca.uqac.lif.cep.functions.Constant.getOutputTypeFor | ( | int | index | ) |
Definition at line 114 of file Constant.java.
| Object ca.uqac.lif.cep.functions.Constant.getValue | ( | ) |
Gets the actual object that this constant processor returns.
Definition at line 134 of file Constant.java.
| Object ca.uqac.lif.cep.functions.Constant.printState | ( | ) |
Definition at line 143 of file Constant.java.
| Constant ca.uqac.lif.cep.functions.Constant.readState | ( | Object | o | ) |
Definition at line 152 of file Constant.java.
| void ca.uqac.lif.cep.functions.Constant.reset | ( | ) |
Definition at line 95 of file Constant.java.
| String ca.uqac.lif.cep.functions.Constant.toString | ( | ) |
Definition at line 120 of file Constant.java.
A constant representing the number one.
Definition at line 40 of file Constant.java.
A constant representing the number zero.
Definition at line 35 of file Constant.java.