Modifier and Type | Field and Description |
---|---|
private final int[] | components
Array of components that make up DeweyDecimal |
Access | Constructor and Description |
---|---|
public | DeweyDecimal(final int[]
an array of integer components. components)Construct a DeweyDecimal from an array of integer components. |
public | DeweyDecimal(final String
the string in dewey decimal format string)Construct a DeweyDecimal from string in DeweyDecimal format. |
Modifier and Type | Method and Description |
---|---|
public int | Returns: resultanother DeweyDecimal to compare with other)Implements java. |
public boolean | equals(Object
the reference object with which to compare. o)Overrides java. |
public int | Returns: the value of component at indexthe index of components index)Return the component at specified index. |
public int | Returns: the number of components in dewey decimalReturn number of components in |
public int | |
public boolean | Returns: true if equal to other DeweyDecimal, false otherwisethe other DeweyDecimal other)Return |
public boolean | Returns: true if greater than other DeweyDecimal, false otherwisethe other DeweyDecimal other)Return |
public boolean | Returns: true if greater than or equal to other DeweyDecimal, false otherwisethe other DeweyDecimal other)Return |
public boolean | Returns: true if less than other DeweyDecimal, false otherwisethe other DeweyDecimal other)Return |
public boolean | Returns: true if less than or equal to other DeweyDecimal, false otherwisethe other DeweyDecimal other)Return |
public String | Returns: the string representation of DeweyDecimal.Overrides java. DeweyDecimal .
|
components | back to summary |
---|---|
private final int[] components Array of components that make up DeweyDecimal |
DeweyDecimal | back to summary |
---|---|
public DeweyDecimal(final int[] components) Construct a DeweyDecimal from an array of integer components.
|
DeweyDecimal | back to summary |
---|---|
public DeweyDecimal(final String string) throws NumberFormatException Construct a DeweyDecimal from string in DeweyDecimal format.
|
compareTo | back to summary |
---|---|
public int compareTo(DeweyDecimal other) Implements java. Compares this DeweyDecimal with another one.
|
equals | back to summary |
---|---|
public boolean equals(Object o) Overrides java. Doc from java. Indicates whether some other object is "equal to" this one.
The
An equivalence relation partitions the elements it operates on into equivalence classes; all the members of an equivalence class are equal to each other. Members of an equivalence class are substitutable for each other, at least for some purposes. |
get | back to summary |
---|---|
public int get(final int index) Return the component at specified index.
|
getSize | back to summary |
---|---|
public int getSize() Return number of components in
|
hashCode | back to summary |
---|---|
public int hashCode() Overrides java. Doc from java. Returns a hash code value for the object. This method is
supported for the benefit of hash tables such as those provided by
The general contract of
|
isEqual | back to summary |
---|---|
public boolean isEqual(final DeweyDecimal other) Return
|
isGreaterThan | back to summary |
---|---|
public boolean isGreaterThan(final DeweyDecimal other) Return
|
isGreaterThanOrEqual | back to summary |
---|---|
public boolean isGreaterThanOrEqual(final DeweyDecimal other) Return
|
isLessThan | back to summary |
---|---|
public boolean isLessThan(final DeweyDecimal other) Return
|
isLessThanOrEqual | back to summary |
---|---|
public boolean isLessThanOrEqual(final DeweyDecimal other) Return
|
toString | back to summary |
---|---|
public String toString() Overrides java. Return string representation of |