com.github.basking2.sdsai.itrex.functions.function.HasArgFunction Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of sdsai-itrex Show documentation
Show all versions of sdsai-itrex Show documentation
An S-Expression inspiried library focused on iterators.
package com.github.basking2.sdsai.itrex.functions.function;
import com.github.basking2.sdsai.itrex.EvaluationContext;
import com.github.basking2.sdsai.itrex.functions.FunctionInterface;
import java.util.Iterator;
/**
* Return True or False if the given {@link EvaluationContext} has more arguments or not.
*/
public class HasArgFunction implements FunctionInterface {
@Override
public Boolean apply(Iterator> iterator, EvaluationContext evaluationContext) {
return evaluationContext.getArguments().hasNext();
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy