Uses of Interface
org.apache.commons.functor.Functor
Packages that use Functor
Package
Description
Basic functor interfaces.
Classes that adapt one functor interface to another.
Commonly used functor implementations.
Various algorithm-esque functors.
Collection-based functors, algorithms and utilities.Comparator- and
Comparable-based functors, algorithms and utilities.
Functors composed of other functors.
Contains utility code for Generators.
-
Uses of Functor in org.apache.commons.functor
Subinterfaces of Functor in org.apache.commons.functorModifier and TypeInterfaceDescriptioninterfaceBinaryFunction<L,R, T> A functor that takes two arguments and returns a value.interfaceBinaryFunctor<L,R> Marker interface for binary (two-argument) functors.interfaceBinaryPredicate<L,R> A functor that takes two arguments and returns abooleanvalue.interfaceBinaryProcedure<L,R> A functor that takes two arguments and has no return value.interfaceFunction<T>A functor that takes no arguments and returns a value.interfaceMarker interface for nullary (zero-argument) functors.interfaceA functor that takes no arguments and returns abooleanvalue.interfaceA functor that takes no arguments and returns no value.interfaceUnaryFunction<A,T> A functor that takes one argument and returns anObjectvalue.interfaceUnaryFunctor<A>Marker interface for unary (single-argument) functors.interfaceA functor that takes one argument and returns abooleanvalue.interfaceA functor that takes one argument and returns no value. -
Uses of Functor in org.apache.commons.functor.adapter
Classes in org.apache.commons.functor.adapter that implement FunctorModifier and TypeClassDescriptionfinal classfinal classAdapts aBinaryFunctionto theBinaryProcedureinterface by ignoring the value returned by the function.final classAdapts a BinaryFunction as a UnaryFunction by sending the same argument to both sides of the BinaryFunction.final classAdapts aBinaryPredicateto theBinaryFunctioninterface.final classAdapts a BinaryPredicate as a UnaryPredicate by sending the same argument to both sides of the BinaryPredicate.final classfinal classAdapts a BinaryProcedure as a UnaryProcedure by sending the same argument to both sides of the BinaryProcedure.final classAdapts aUnaryFunctionto theFunctioninterface using a constant unary argument.final classAdapts aUnaryPredicateto thePredicateinterface using a constant unary argument.final classAdapts aUnaryProcedureto theProcedureinterface using a constant unary argument.final classAdapts aBinaryFunctionto theFunctioninterface using constant arguments.final classAdapts aBinaryPredicateto theUnaryPredicateinterface using a constant left-side argument.final classAdapts aBinaryProcedureto theProcedureinterface using a constant left-side argument.final classfinal classfinal classAdapts aFunctionto theUnaryFunctioninterface by ignoring the unary argument.final classIgnoreLeftFunction<L,R, T> Adapts aUnaryFunctionto theBinaryFunctioninterface by ignoring the first binary argument.final classIgnoreLeftPredicate<L,R> Adapts aUnaryPredicateto theBinaryPredicateinterface by ignoring the first binary argument.final classIgnoreLeftProcedure<L,R> Adapts aUnaryProcedureto theBinaryProcedureinterface by ignoring the first binary argument.final classIgnoreRightFunction<L,R, T> Adapts aUnaryFunctionto theBinaryFunctioninterface by ignoring the second binary argument.final classIgnoreRightPredicate<L,R> Adapts aUnaryPredicateto theBinaryPredicateinterface by ignoring the second binary argument.final classIgnoreRightProcedure<L,R> Adapts aUnaryProcedureto theBinaryProcedureinterface by ignoring the second binary argument.final classLeftBoundFunction<A,T> Adapts aBinaryFunctionto theUnaryFunctioninterface using a constant left-side argument.final classAdapts aBinaryPredicateto theUnaryPredicateinterface using a constant left-side argument.final classAdapts aBinaryProcedureto theUnaryProcedureinterface using a constant left-side argument.final classfinal classAdapts aPredicateto theUnaryPredicateinterface by ignoring the given argument.final classfinal classAdapts aProcedureto theUnaryProcedureinterface by ignoring the arguments.final classRightBoundFunction<A,T> Adapts aBinaryFunctionto theUnaryFunctioninterface using a constant right-side argument.final classAdapts aBinaryPredicateto theUnaryPredicateinterface using a constant left-side argument.final classAdapts aBinaryProcedureto theUnaryProcedureinterface using a constant left-side argument.final classfinal classAdapts aUnaryFunctionto theUnaryProcedureinterface by ignoring the value returned by the function.final classAdapts aUnaryPredicateto theUnaryFunctioninterface.final class -
Uses of Functor in org.apache.commons.functor.core
Classes in org.apache.commons.functor.core that implement FunctorModifier and TypeClassDescriptionfinal classConstant<T>Evaluatesto constant value.final classIdentity<T>Evaluatesto its input argument.final classIsEqual<L,R> final classIsInstance<T>final classIsNotEqual<L,R> final classIsNotNull<T>final classIsNotSame<L,R> Teststhe reference (!=) inequality of its arguments.final classIsNull<A>final classIsSame<L,R> Teststhe reference (==) equality of its arguments.final classA predicate that returnstruethe first n times it is invoked.final classA procedure that does nothing at all.final classA predicate that returnsfalsethe first n times it is invoked, andtruethereafter. -
Uses of Functor in org.apache.commons.functor.core.algorithm
Classes in org.apache.commons.functor.core.algorithm that implement FunctorModifier and TypeClassDescriptionclassDo-until algorithm (test after).classDo-while algorithm (test after).final classReturn the first Object in aGeneratormatching aUnaryPredicate.private static classHelper procedure.classFoldLeft<T>Functional left-fold algorithm against the elements of aGenerator.private static classHelper procedure.classFoldRight<T>Functional right-fold algorithm against the elements of aGenerator.private static classHelper class.final classTests whether aGeneratorcontains an element that matches aUnaryPredicate.private static classHelper procedure.final classReturn the index of the first Object in aGeneratormatching aUnaryPredicate, or -1 if not found.private static classHelper procedure.final classImplements an in-place transformation of a ListIterator's contents.(package private) classBase class for predicated procedure algorithms.classTail recursion forfunctions.final classRemove elements from left Iterator that match right UnaryPredicate.final classRetain elements in left Iterator that match right UnaryPredicate.classUntil-do algorithm (test before).classWhile-do algorithm (test before). -
Uses of Functor in org.apache.commons.functor.core.collection
Classes in org.apache.commons.functor.core.collection that implement FunctorModifier and TypeClassDescriptionfinal classIsElementOf<L,R> ABinaryPredicatethat checks to see if the specified object is an element of the specified Collection.final classIsEmpty<A>final classSize<A>Returns the size of the specified Collection, or the length of the specified array or String. -
Uses of Functor in org.apache.commons.functor.core.comparator
Classes in org.apache.commons.functor.core.comparator that implement FunctorModifier and TypeClassDescriptionfinal classAdapts aComparatorto theBinaryFunctioninterface.final classIsEquivalent<T>ABinaryPredicatethatteststrueiff the left argument is equal to the right argument under the specifiedComparator.final classABinaryPredicatethatteststrueiff the left argument is greater than the right argument under the specifiedComparator.final classABinaryPredicatethatteststrueiff the left argument is greater than or equal to the right argument under the specifiedComparator.final classIsLessThan<T>ABinaryPredicatethatteststrueiff the left argument is greater than the right argument under the specifiedComparator.final classABinaryPredicatethatteststrueiff the left argument is less than or equal to the right argument under the specifiedComparator.final classABinaryPredicatethatteststrueiff the left argument is not equal to the right argument under the specifiedComparator.classIsWithinRange<A extends Comparable<A>>AUnaryPredicatethat tests whether aComparableobject is within a range.final classMax<T>Adapts aComparatorto theBinaryFunctioninterface.final classMin<T>Adapts aComparatorto theBinaryFunctioninterface. -
Uses of Functor in org.apache.commons.functor.core.composite
Classes in org.apache.commons.functor.core.composite that implement FunctorModifier and TypeClassDescriptionclassAbstract base class forWhileDoProcedureandDoWhileProcedureused to implement loop procedures.final class(package private) classAbstract base class forBinaryPredicatescomposed of a list ofBinaryPredicates.(package private) classAbstract base class forPredicatescomposed of a list ofPredicates.(package private) classAbstract base class forUnaryPredicatescomposed of a list ofUnaryPredicates.final classBinaryAnd<L,R> classABinaryFunctioncomposed of three binary functions, f, g and h, evaluating the ordered parameters x, y tof(g(x,y),h(x,y)).private static classBinaryCompositeBinaryFunction.Helper<G,H, L, R, T> Type-remembering Helper.final classBinaryNot<L,R> Teststo the logical inverse of some other predicate.final classBinaryOr<L,R> classBinarySequence<L,R> classAUnaryFunctionrepresenting the composition ofUnaryFunctions, "chaining" the output of one to the input of another.private static classEncapsulates a double function evaluation.final classAUnaryPredicaterepresenting the composition ofUnaryFunctions, "chaining" the output of one to the input of another.final classAUnaryProcedurerepresenting the composition ofUnaryFunctions, "chaining" the output of one to the input of another.final classConditionalBinaryFunction<L,R, T> ABinaryFunctionsimiliar to Java's "ternary" or "conditional" operator (? :).final classABinaryPredicatesimiliar to Java's "ternary" or "conditional" operator (? :).final classABinaryProceduresimiliar to Java's "ternary" or "conditional" operator (? :).final classAFunctionsimiliar to Java's "ternary" or "conditional" operator (? :).final classAPredicatesimiliar to Java's "ternary" or "conditional" operator (? :).final classAProceduresimiliar to Java's "ternary" or "conditional" operator (? :).final classAUnaryFunctionsimiliar to Java's "ternary" or "conditional" operator (? :).final classAUnaryPredicatesimiliar to Java's "ternary" or "conditional" operator (? :).final classAUnaryProceduresimiliar to Java's "ternary" or "conditional" operator (? :).classAProcedureimplementation of a while loop.final classTeststo the logical inverse of some other predicate.final classclassclassTransformedBinaryFunction<L,R, T> A BinaryFunction whose result is then run through a UnaryFunction.private static final classTransformedBinaryFunction.Helper<X,L, R, T> Type-remembering helper.classA BinaryProcedure composed of a BinaryFunction whose result is then run through a UnaryProcedure.private static final classType-remembering helper.classA Function whose result is then run through a UnaryFunction.private static final classType-remembering helper.classA Procedure composed of a Function whose result is then run through a UnaryProcedure.private static final classType-remembering helper.classTransposedFunction<L,R, T> Transposes (swaps) the arguments to some otherfunction.classTransposedPredicate<L,R> Transposes (swaps) the arguments to some otherpredicate.classTransposedProcedure<L,R> Transposes (swaps) the arguments to some otherprocedure.final classUnaryAnd<A>classUnaryCompositeBinaryFunction<L,R, T> ABinaryFunctioncomposed of one binary function, f, and two unary functions, g and h, evaluating the ordered parameters x, y tof(g(x),h(y)).private static classUnaryCompositeBinaryFunction.Helper<G,H, L, R, T> classABinaryPredicatecomposed of one binary predicate, p, and two unary functions, f and g, evaluating the ordered parameters x, y top(f(x),g(y)).private static classUnaryCompositeBinaryPredicate.Helper<G,H, L, R> Internal helper.final classUnaryNot<A>Teststo the logical inverse of some other predicate.final classUnaryOr<A>classclassAProcedureimplementation of a while loop. -
Uses of Functor in org.apache.commons.functor.generator.util
Classes in org.apache.commons.functor.generator.util that implement FunctorModifier and TypeClassDescriptionclassTransforms a generator into a collection.