wugle.expression
Class ExpressionOperation
java.lang.Object
|
+--wugle.expression.ExpressionOperation
- Direct Known Subclasses:
- LogicOperation
- public abstract class ExpressionOperation
- extends java.lang.Object
Delegation object for various operations.
Expressions implementing the various operation interfaces can use this
class for delegating the operation. This is an abstract class because
not all of the operations are generic enough the be implemented here.
Subpackages should provide a subclass that implements the abstract operation methods
and any operations specific to the package.
Any operation methods not declared
here are too implementation specific for a delegated operation.
- Version:
- 0.1.3
- Author:
- Jacob Perkins
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ExpressionOperation
public ExpressionOperation()
setChild
public void setChild(Operator parent,
Expression oldChild,
Expression newChild)
canAssociateLeft
public boolean canAssociateLeft(Associative operator)
- See Also:
associateLeft(Associative)
,
canAssociateRight(Associative)
,
Associative.canAssociateLeft()
associateLeft
public Associative associateLeft(Associative operator)
throws java.lang.Exception
java.lang.Exception
- See Also:
canAssociateLeft(Associative)
,
associateRight(Associative)
,
Associative.associateLeft()
canAssociateRight
public boolean canAssociateRight(Associative operator)
- See Also:
associateRight(Associative)
,
canAssociateLeft(Associative)
,
Associative.canAssociateRight()
associateRight
public Associative associateRight(Associative operator)
throws java.lang.Exception
java.lang.Exception
- See Also:
canAssociateRight(Associative)
,
associateLeft(Associative)
,
Associative.associateRight()
commute
public void commute(Commutative operator)
canDeMorgans
public boolean canDeMorgans(DeMorgans operator)
canDistributeExpand
public boolean canDistributeExpand(Distributive operator)
distributeExpand
public Distributive distributeExpand(Distributive operator)
throws java.lang.Exception
java.lang.Exception
canDistributeReduce
public boolean canDistributeReduce(Distributive operator)
distributeReduce
public Distributive distributeReduce(Distributive operator)
throws java.lang.Exception
java.lang.Exception
dominate
public Dominator dominate(Dominatable operator)
throws java.lang.Exception
java.lang.Exception
doubleComplement
public DoubleComplement doubleComplement(DoubleComplement expression)
doubleNegate
public DoubleNegatable doubleNegate(DoubleNegatable expression)
canIdempotent
public boolean canIdempotent(Idempotent operator)
idempotent
public Expression idempotent(Idempotent operator)
throws java.lang.Exception
java.lang.Exception
idempotent
public void idempotent(Idempotent operator,
Expression child)
canIdentity
public boolean canIdentity(Identity operator)
identity
public Expression identity(Identity operator)
throws java.lang.Exception
java.lang.Exception
identity
public void identity(Identity operator,
Expression child)