org.jscience.mathematics.algebraic.categories
Class Preorder

java.lang.Object
  extended by org.jscience.mathematics.algebraic.categories.Preorder
All Implemented Interfaces:
Category

public final class Preorder
extends java.lang.Object
implements Category

The Preorder class encapsulates preorders as categories.


Nested Class Summary
 class Preorder.Relation
          DOCUMENT ME!
 class Preorder.RelationSet
          DOCUMENT ME!
 
Nested classes/interfaces inherited from interface org.jscience.mathematics.algebraic.categories.Category
Category.HomSet, Category.Morphism
 
Constructor Summary
Preorder(int n)
          Constructs a preorder category.
 
Method Summary
 java.lang.Object cardinality(java.lang.Object a)
          Returns the cardinality of an object.
 Category.HomSet hom(java.lang.Object a, java.lang.Object b)
          Returns a hom-set.
 Category.Morphism identity(java.lang.Object a)
          Returns the identity morphism for an object.
 java.lang.Object initial()
          DOCUMENT ME!
 int ordinal()
          Returns the ordinal that this category represents.
 java.lang.Object terminal()
          DOCUMENT ME!
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Preorder

public Preorder(int n)
Constructs a preorder category.

Parameters:
n - DOCUMENT ME!
Method Detail

identity

public Category.Morphism identity(java.lang.Object a)
Returns the identity morphism for an object.

Specified by:
identity in interface Category
Parameters:
a - an Integer.
Returns:
DOCUMENT ME!

cardinality

public java.lang.Object cardinality(java.lang.Object a)
Returns the cardinality of an object.

Specified by:
cardinality in interface Category
Parameters:
a - an Integer.
Returns:
an Integer.

hom

public Category.HomSet hom(java.lang.Object a,
                           java.lang.Object b)
Returns a hom-set.

Specified by:
hom in interface Category
Parameters:
a - DOCUMENT ME!
b - DOCUMENT ME!
Returns:
DOCUMENT ME!

initial

public java.lang.Object initial()
DOCUMENT ME!

Returns:
DOCUMENT ME!

terminal

public java.lang.Object terminal()
DOCUMENT ME!

Returns:
DOCUMENT ME!

ordinal

public int ordinal()
Returns the ordinal that this category represents.

Returns:
DOCUMENT ME!