mirror of
https://github.com/DanilaFe/abacus
synced 2024-11-13 14:19:53 -08:00
Add the operator that had been in use by Plugin and PluginManager.
This commit is contained in:
parent
586cd90e32
commit
663562bab1
27
src/org/nwapw/abacus/function/Operator.java
Normal file
27
src/org/nwapw/abacus/function/Operator.java
Normal file
|
@ -0,0 +1,27 @@
|
|||
package org.nwapw.abacus.function;
|
||||
|
||||
public abstract class Operator {
|
||||
|
||||
private OperatorAssociativity associativity;
|
||||
private int precedence;
|
||||
private Function function;
|
||||
|
||||
public Operator(OperatorAssociativity associativity, int precedence, Function function){
|
||||
this.associativity = associativity;
|
||||
this.precedence = precedence;
|
||||
this.function = function;
|
||||
}
|
||||
|
||||
public OperatorAssociativity getAssociativity() {
|
||||
return associativity;
|
||||
}
|
||||
|
||||
public int getPrecedence() {
|
||||
return precedence;
|
||||
}
|
||||
|
||||
public Function getFunction() {
|
||||
return function;
|
||||
}
|
||||
|
||||
}
|
Loading…
Reference in New Issue
Block a user