|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--sub_arctic.constraints.std_objpart_encoding
Class to provide a standard object/part encoding and to provide constants for them that can be used to build constraints. These references can denote standard parts within the local neighborhood of an object and can be used as part of lightweight constraints that use minimal storage (which are the default). These lightweight references are encoded in 6 bits: depended upon objects are encoded in 3 (high order) bits and parts use another 3 (stored in the low order bits). In addition, lightweight references store an orientation for type checking purposes.
Methods are provided for creating a new instance from an existing instance by filling in the part portion only. This allows several of these objects (i.e., PARENT) to be used as "constant factories" so we get a cleaner notation (i.e., PARENT.W()).
Field Summary | |
protected int |
_encoding
The encoding of the object and part for local object references and standard parts. |
protected int |
_orientation
The orientation of this part. |
Constructor Summary | |
std_objpart_encoding(int obj_code,
int part_code,
int orient_code)
Constructor for a local reference to a standard part. |
Method Summary | |
std_objpart_encoding |
BOTTOM()
Method returning an instance designating the bottom part of this object. |
std_objpart_encoding |
ENABLED()
Method returning an instance designating the "enabled" part of this object |
int |
encoding()
The encoding of the object and part for local object references and standard parts. |
std_objpart_encoding |
H()
Method returning an instance designating the h part of this object |
std_objpart_encoding |
HCENTER()
Method returning an instance designating the horizontal center part of this object |
std_objpart_encoding |
LEFT()
Method returning an instance designating the left part of this object. |
int |
object_encoded()
Extract and return just the object designator encoding |
static int |
object_encoded(int enc)
Extract and return just the object designator from the given encoding |
int |
orientation()
The orientation of this part. |
std_objpart_encoding |
PART_A()
Method returning an instance designating the "part_a" part of this object. |
std_objpart_encoding |
PART_B()
Method returning an instance designating the "part_b" part of this object. |
int |
part_encoded()
Extract and return just the part designator encoding |
static int |
part_encoded(int enc)
Extract and return just the part designator from the given encoding |
std_objpart_encoding |
RIGHT()
Method returning an instance designating the right part of this object. |
std_objpart_encoding |
TOP()
Method returning an instance designating the top part of this object. |
std_objpart_encoding |
VCENTER()
Method returning an instance designating the vertical center part of this object |
std_objpart_encoding |
VISIBLE()
Method returning an instance designating the "visible" part of this object |
std_objpart_encoding |
W()
Method returning an instance designating the w part of this object |
std_objpart_encoding |
X()
Method returning an instance designating the x part of this object |
std_objpart_encoding |
X1()
Method returning an instance designating the x1 part of this object. |
std_objpart_encoding |
X2()
Method returning an instance designating the x2 part of this object |
std_objpart_encoding |
Y()
Method returning an instance designating the y part of this object |
std_objpart_encoding |
Y1()
Method returning an instance designating the y1 part of this object. |
std_objpart_encoding |
Y2()
Method returning an instance designating the y2 part of this object |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
Field Detail |
protected int _encoding
protected int _orientation
Constructor Detail |
public std_objpart_encoding(int obj_code, int part_code, int orient_code)
int
- obj_code value for object encoding. This must be between
zero and OBJCODE_MAX. Values outside this range
will be silently truncated.int
- part_code value for part encoding. This must be between
zero and PARTCODE_MAX. Values outside this range
will be silently truncated.int
- orient_code code for the orientation of this part. Should be
one of HORIZONTAL, VERTICAL, or NOT_ORIENTEDMethod Detail |
public int encoding()
public int orientation()
public int object_encoded()
public static int object_encoded(int enc)
public int part_encoded()
public static int part_encoded(int enc)
public std_objpart_encoding X()
public std_objpart_encoding X1()
public std_objpart_encoding LEFT()
public std_objpart_encoding Y()
public std_objpart_encoding Y1()
public std_objpart_encoding TOP()
public std_objpart_encoding X2()
public std_objpart_encoding RIGHT()
public std_objpart_encoding Y2()
public std_objpart_encoding BOTTOM()
public std_objpart_encoding W()
public std_objpart_encoding H()
public std_objpart_encoding HCENTER()
public std_objpart_encoding VCENTER()
public std_objpart_encoding VISIBLE()
public std_objpart_encoding ENABLED()
public std_objpart_encoding PART_A()
public std_objpart_encoding PART_B()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |