|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.planet_ink.coffee_mud.Common.DefaultCMIntegerGrouper
public class DefaultCMIntegerGrouper
| Field Summary | |
|---|---|
int[] |
xs
|
long[] |
ys
|
| Fields inherited from interface com.planet_ink.coffee_mud.Common.interfaces.CMIntegerGrouper |
|---|
GRID_FLAGL, NEXT_BITS, NEXT_BITSL, NEXT_FLAG, NEXT_FLAGL |
| Constructor Summary | |
|---|---|
DefaultCMIntegerGrouper()
|
|
| Method Summary | |
|---|---|
CMIntegerGrouper |
add(CMIntegerGrouper grp)
Adds a group of room numbers |
CMIntegerGrouper |
add(long x)
Adds the room number |
void |
addx(int x)
Adds the single digit |
void |
addy(long x)
Adds the single digit |
int[] |
allPrimaryRoomNums()
Return all primary raw room numbers. |
long[] |
allRoomNums()
Return all raw room numbers, with grid locales encoded. |
int |
compareTo(CMObject o)
|
void |
consolodatex()
|
void |
consolodatey()
|
boolean |
contains(long x)
Returns whether this list contains the given coded room number. |
CMObject |
copyOf()
Similar to Cloneable.clone(), but does its best to make sure that any internal objects to this class are also copyOfed. |
int |
getXindex(int x)
|
int |
getYindex(long y)
|
void |
growarrayx(int here,
int amount)
|
void |
growarrayy(int here,
int amount)
|
java.lang.String |
ID()
The CoffeeMud Java Class ID shared by all instances of this object. |
void |
initializeClass()
Called ONCE after all objects are loaded, but before the map is read in during initialization. |
CMObject |
newInstance()
Returns a new instance of this class. |
long[] |
packedGridRoomNums()
Return all packed grid room numbers, with grid locales encoded. |
int[] |
packedRoomNums()
Return all packed grid room numbers, with grid locales encoded. |
CMIntegerGrouper |
parseText(java.lang.String txt)
Creates a nice storage of integers from a saved string. |
long |
random()
Return a random coded room number from this set. |
CMIntegerGrouper |
remove(CMIntegerGrouper grp)
Removes the room number |
CMIntegerGrouper |
remove(long x)
Removes the room number |
void |
removex(int x)
|
void |
removey(long x)
|
int |
roomCount()
The total number of digits represented by this grouping. |
void |
shrinkarrayx(int here,
int amount)
|
void |
shrinkarrayy(int here,
int amount)
|
java.lang.String |
text()
This set of integers as a savable string. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public int[] xs
public long[] ys
| Constructor Detail |
|---|
public DefaultCMIntegerGrouper()
| Method Detail |
|---|
public java.lang.String ID()
CMObject
ID in interface CMObjectpublic int compareTo(CMObject o)
compareTo in interface java.lang.Comparable<CMObject>public void initializeClass()
CMObject
initializeClass in interface CMObjectpublic CMObject newInstance()
CMObject
newInstance in interface CMObjectpublic java.lang.String text()
CMIntegerGrouper
text in interface CMIntegerGrouperpublic CMObject copyOf()
CMObject
copyOf in interface CMObjectpublic CMIntegerGrouper parseText(java.lang.String txt)
CMIntegerGrouper
parseText in interface CMIntegerGroupertxt - the list as a string
public long[] packedGridRoomNums()
CMIntegerGrouper
packedGridRoomNums in interface CMIntegerGrouperpublic int[] packedRoomNums()
CMIntegerGrouper
packedRoomNums in interface CMIntegerGrouperpublic boolean contains(long x)
CMIntegerGrouper
contains in interface CMIntegerGrouperx - the number to look for, coded as a room number
public int getXindex(int x)
public int getYindex(long y)
public int[] allPrimaryRoomNums()
CMIntegerGrouper
allPrimaryRoomNums in interface CMIntegerGrouperpublic long[] allRoomNums()
CMIntegerGrouper
allRoomNums in interface CMIntegerGrouperpublic int roomCount()
CMIntegerGrouper
roomCount in interface CMIntegerGrouperpublic long random()
CMIntegerGrouper
random in interface CMIntegerGrouper
public void growarrayx(int here,
int amount)
public void growarrayy(int here,
int amount)
public CMIntegerGrouper remove(long x)
CMIntegerGrouper
remove in interface CMIntegerGrouperx - the coded digit pair to remove.
public CMIntegerGrouper remove(CMIntegerGrouper grp)
CMIntegerGrouper
remove in interface CMIntegerGroupergrp - the coded digit pair to remove.
public void shrinkarrayx(int here,
int amount)
public void shrinkarrayy(int here,
int amount)
public void consolodatex()
public void consolodatey()
public CMIntegerGrouper add(CMIntegerGrouper grp)
CMIntegerGrouper
add in interface CMIntegerGroupergrp - the coded digit pairs to add.
public CMIntegerGrouper add(long x)
CMIntegerGrouper
add in interface CMIntegerGrouperx - the coded digit pair to add.
public void addy(long x)
CMIntegerGrouper
addy in interface CMIntegerGrouperx - the single digit to add.public void addx(int x)
CMIntegerGrouper
addx in interface CMIntegerGrouperx - the single digit to add.public void removey(long x)
public void removex(int x)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||