KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > JSci > maths > groups > Monoid


1 package JSci.maths.groups;
2
3 /**
4 * This interface defines a monoid.
5 * @jsci.planetmath Monoid
6 * @version 1.0
7 * @author Mark Hale
8 */

9 public interface Monoid {
10         /**
11         * Returns the identity element.
12         */

13         Member identity();
14         /**
15         * Returns true if the member is the identity element of this monoid.
16         * @param g a monoid member
17         */

18         boolean isIdentity(Member g);
19
20         /**
21         * This interface defines a member of a monoid.
22         */

23         interface Member extends Semigroup.Member {}
24 }
25
26
Popular Tags