Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
 package jason.asSemantics;
 
 
Useful default implementation of all methods of ArithFunction interface.

Author(s):
Jomi
public abstract class DefaultArithFunction implements ArithFunctionSerializable {
    public String getName() {
        return getClass().getName();
    }
    
    public boolean checkArity(int a) {
        return true;
    }
    public double evaluate(TransitionSystem tsTerm[] argsthrows Exception {
        return 0;
    }
    
    public boolean allowUngroundTerms() {
        return false;
    }
    @Override
    public String toString() {
        return "function "+getName();
    }
New to GrepCode? Check out our FAQ X