edu.rice.cs.plt.collect
Class AbstractFunctionalRelation.InverseFunctionalRelation
java.lang.Object
java.util.AbstractCollection<E>
java.util.AbstractSet<T>
edu.rice.cs.plt.collect.AbstractPredicateSet<Pair<T2,T1>>
edu.rice.cs.plt.collect.AbstractRelation.InverseRelation
edu.rice.cs.plt.collect.AbstractFunctionalRelation.InverseFunctionalRelation
- All Implemented Interfaces:
- InjectiveRelation<T2,T1>, PredicateSet<Pair<T2,T1>>, Relation<T2,T1>, SizedIterable<Pair<T2,T1>>, Predicate<Object>, Predicate2<T2,T1>, Serializable, Iterable<Pair<T2,T1>>, Collection<Pair<T2,T1>>, Set<Pair<T2,T1>>
- Direct Known Subclasses:
- AbstractOneToOneRelation.InverseOneToOneRelation
- Enclosing class:
- AbstractFunctionalRelation<T1,T2>
protected class AbstractFunctionalRelation.InverseFunctionalRelation
- extends AbstractRelation.InverseRelation
- implements InjectiveRelation<T2,T1>
An inverse of the enclosing relation. Extends AbstractRelation.InverseRelation with
the methods necessary to implement InjectiveRelation.
- See Also:
- Serialized Form
| Methods inherited from class edu.rice.cs.plt.collect.AbstractRelation.InverseRelation |
add, add, clear, contains, contains, containsFirst, containsSecond, excludeFirsts, excludeSeconds, firstSet, hasFixedSize, isEmpty, isInfinite, isStatic, iterator, matchFirst, matchSecond, remove, remove, secondSet, size, size |
| Methods inherited from interface edu.rice.cs.plt.collect.Relation |
contains, contains, containsFirst, containsSecond, excludeFirsts, excludeSeconds, firstSet, matchFirst, remove, remove, secondSet |
| Methods inherited from interface java.util.Set |
addAll, clear, containsAll, equals, hashCode, isEmpty, iterator, removeAll, retainAll, size, toArray, toArray |
AbstractFunctionalRelation.InverseFunctionalRelation
protected AbstractFunctionalRelation.InverseFunctionalRelation()
antecedent
public T2 antecedent(T1 second)
- Description copied from interface:
InjectiveRelation
- Produce the first corresponding to
second, or null if there is none.
- Specified by:
antecedent in interface InjectiveRelation<T2,T1>
injectionMap
public LambdaMap<T1,T2> injectionMap()
- Description copied from interface:
InjectiveRelation
- A map view of the relation, mapping seconds to firsts. Need not allow mutation, but must
reflect subsequent changes.
- Specified by:
injectionMap in interface InjectiveRelation<T2,T1>
inverse
public FunctionalRelation<T1,T2> inverse()
- Description copied from interface:
Relation
- Produce the inverse of the relation, derived by swapping the elements of each pair. Need not
allow mutation, but must reflect subsequent changes.
- Specified by:
inverse in interface InjectiveRelation<T2,T1>- Specified by:
inverse in interface Relation<T2,T1>- Overrides:
inverse in class AbstractRelation.InverseRelation