Class Order<T>
java.lang.Object
org.tweetyproject.comparator.Order<T>
- Type Parameters:
T- The class that is being ordered.
This class represents an order among some objects.
- Author:
- Matthias Thimm
-
Constructor Summary
ConstructorsConstructorDescriptionOrder(Collection<T> objects) Creates a new order for the given set of objects. -
Method Summary
Modifier and TypeMethodDescriptionDefaultGraph<Order<T>.org.tweetyproject.comparator.Order.OrderNode> Return the directed defaultGraph that represents the orderReturns the elements appearing in this order.getNodes()Return the bijection between objects and nodes in the defaultGraphbooleanisComparable(T object1, T object2) Return whether the objects are comparablebooleanisOrderedBefore(T object1, T object2) Checks whether object1 is ordered before object2.voidremoveNode(T n) Removes the given node and all of its relations.voidsetOrderedBefore(T object1, T object2) Adds that object1 is ordered before object2toString()
-
Constructor Details
-
Order
Creates a new order for the given set of objects.- Parameters:
objects- some set of objects.
-
-
Method Details
-
removeNode
Removes the given node and all of its relations.- Parameters:
n- The object whose node will be removed
-
setOrderedBefore
-
isOrderedBefore
-
isComparable
-
getElements
Returns the elements appearing in this order.- Returns:
- the elements appearing in this order.
-
toString
-
getDefaultGraph
Return the directed defaultGraph that represents the order- Returns:
- the directed defaultGraph that represents the order
-
getNodes
-