|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--de.tfhberlin.panitz.eliza.Li
An abstract description of a simple linked list.
Constructor Summary | |
Li()
|
Method Summary | |
abstract de.tfhberlin.panitz.eliza.Li |
cons(java.lang.Object x,
de.tfhberlin.panitz.eliza.Li xs)
Constructs a new list by adding an element in front of an existing list. |
abstract de.tfhberlin.panitz.eliza.Li |
drop(int i)
Removes the first i elements from a list. |
abstract de.tfhberlin.panitz.eliza.Li |
empty()
Constructs a new empty list. |
abstract java.lang.Object |
head()
Returns the first element of this list. |
abstract boolean |
isEmpty()
Tests, if the list contains some element. |
abstract boolean |
isPrefixIgnoreCaseOf(de.tfhberlin.panitz.eliza.Li other)
Tests if this list of Strings is a prefix of the other list of Strings. |
abstract de.tfhberlin.panitz.eliza.Li |
reverse()
Reverses the element order of the list. |
abstract void |
rotate()
Mutates this list, by appending first element as last. |
abstract de.tfhberlin.panitz.eliza.Li |
tail()
Returns the list after the first element has been skipped. |
abstract de.tfhberlin.panitz.eliza.Li |
tails()
Makes a list of lists of all taillists. |
java.lang.String |
toString()
|
abstract java.lang.String |
unwords()
Makes a list of String to a String. |
abstract de.tfhberlin.panitz.eliza.Li |
words(java.lang.String str)
Produces a list of the words within a String. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public Li()
Method Detail |
public abstract de.tfhberlin.panitz.eliza.Li empty()
public abstract de.tfhberlin.panitz.eliza.Li cons(java.lang.Object x, de.tfhberlin.panitz.eliza.Li xs)
x
- the first element for the new list.xs
- the tail for the new list.
public abstract boolean isEmpty()
public abstract java.lang.Object head()
public abstract de.tfhberlin.panitz.eliza.Li tail()
public abstract de.tfhberlin.panitz.eliza.Li tails()
public abstract de.tfhberlin.panitz.eliza.Li drop(int i)
i
- a positive number of elements to be skipped
from the beginning of the list.
public abstract de.tfhberlin.panitz.eliza.Li reverse()
public abstract de.tfhberlin.panitz.eliza.Li words(java.lang.String str)
str
- the string, which is to be splitted into words
public abstract java.lang.String unwords()
public abstract boolean isPrefixIgnoreCaseOf(de.tfhberlin.panitz.eliza.Li other)
other
- the List of Strings, which is tested ,if it extends this
List of Strings.
public abstract void rotate()
public java.lang.String toString()
toString
in class java.lang.Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |