scphEditor
Class DefaultOperator

java.lang.Object
  extended by scphEditor.DefaultOperator
All Implemented Interfaces:
IOperator

public class DefaultOperator
extends java.lang.Object
implements IOperator

DefaultOperator provides a default implementation of the IOperator interface. You provide the operator properties (arity etc.) to the constructor, and these properties will be used by the query services.


Field Summary
 
Fields inherited from interface scphEditor.IOperator
ASSOC, LEFT, nARY, NONASSOC, RIGHT
 
Constructor Summary
DefaultOperator(java.lang.String id, int arityOf, int precOf, int assocOf, boolean commOf, IEmbedding format, java.lang.String[] proverName)
          Constructs an DefaultOperator object with the given properties.
 
Method Summary
 int arity()
          Returns the arity of this operator.
 int associative()
          Returns the associativity of this operator.
 boolean commutative()
          Returns the commutativity of this operator.
 IEmbedding format()
           
 java.lang.String id()
           
 int precedence()
          Returns the precedence of this operator.
 java.lang.String[] proverName()
           
 java.lang.String proverName0()
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

DefaultOperator

public DefaultOperator(java.lang.String id,
                       int arityOf,
                       int precOf,
                       int assocOf,
                       boolean commOf,
                       IEmbedding format,
                       java.lang.String[] proverName)
Constructs an DefaultOperator object with the given properties.

Parameters:
id - the new unique internal ID of the operator
arityOf - arity of the operator
precOf - precedence of the operator
assocOf - associativity of the operator
commOf - commutativity of the operator
format - the screen formatting spec for this operator
proverName - the name(s) of this operator in the prover
Method Detail

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

precedence

public int precedence()
Returns the precedence of this operator.

Specified by:
precedence in interface IOperator

associative

public int associative()
Returns the associativity of this operator.

Specified by:
associative in interface IOperator

commutative

public boolean commutative()
Returns the commutativity of this operator.

Specified by:
commutative in interface IOperator

arity

public int arity()
Returns the arity of this operator.

Specified by:
arity in interface IOperator

format

public IEmbedding format()
Specified by:
format in interface IOperator
Returns:
Returns the format.

id

public java.lang.String id()
Specified by:
id in interface IOperator
Returns:
Returns the internal unique id.

proverName

public java.lang.String[] proverName()
Specified by:
proverName in interface IOperator
Returns:
Returns the names on the prover.

proverName0

public java.lang.String proverName0()
Specified by:
proverName0 in interface IOperator
Returns:
Returns the first name on the prover.