|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--sub_arctic.constraints.external_constraint | +--sub_arctic.constraints.std_ext_constraint
This class provides an external constraint that executes one of the standard constraint functions based on a (partial) standard constraint encoding along with an explicit set of operands (which involve explicitly provided objects and standard or non-standard parts).
Field Summary | |
protected int |
_const_value
Constant value passed to the constraint evaluation function. |
protected int |
_encoding
Partial encoding of the constraint. |
protected int |
_num_ops
Cache of number of operands for the encoded function |
protected interactor |
_op1_obj
Object referenced by operand 1 of the constraint. |
protected int |
_op1_part
Non-standard part number for operand 1 of the constraint. |
protected byte |
_op1_std_part
Standard part code for operand 1. |
protected interactor |
_op2_obj
Object referenced by operand 2 of the constraint. |
protected int |
_op2_part
Non-standard part number for operand 2 of the constraint. |
protected byte |
_op2_std_part
Standard part code for operand 2. |
protected interactor |
_op3_obj
Object referenced by operand 3 of the constraint. |
protected int |
_op3_part
Non-standard part number for operand 3 of the constraint. |
protected byte |
_op3_std_part
Standard part code for operand 3. |
protected byte |
_orientation
Orientation under which this constraint is evaluated. |
protected interactor |
_self_obj
The object which serves as self for the constraint. |
static byte |
IS_HORIZ
Bit mask for bit used to indicate a horizontally oriented standard part. |
static byte |
NOT_STANDARD
Flag value for non-standard part code. |
Fields inherited from class sub_arctic.constraints.external_constraint |
_doing_ood,
_notify_list |
Constructor Summary | |
std_ext_constraint(int enc,
interactor slf_obj,
int orient,
ext_objpart_encoding op1,
ext_objpart_encoding op2,
ext_objpart_encoding op3,
int c_val)
Construct a 3 operand external constraint that executes the constraint function encoded in standard from, but with arbitrary operand values. |
|
std_ext_constraint(int enc,
interactor slf_obj,
int orient,
ext_objpart_encoding op1,
ext_objpart_encoding op2,
int c_val)
Construct a 2 operand external constraint that executes the constraint function encoded in standard from, but with potentially arbitrary operand values. |
|
std_ext_constraint(int enc,
interactor slf_obj,
int orient,
ext_objpart_encoding op1,
int c_val)
Construct a 1 operand external constraint that executes the constraint function encoded in standard from, but with a potentially arbitrary operand value. |
|
std_ext_constraint(int enc,
interactor slf_obj,
int orient,
int c_val)
Construct a 0 operand external constraint that executes the constraint function encoded in standard from. |
Method Summary | |
int |
const_value()
Constant value passed to the constraint evaluation function. |
int |
encoding()
Partial encoding of the constraint. |
protected int |
fetch_part(interactor from_obj,
int std_part,
int ext_part_num)
Fetch a standard or non-standard part from the given interactor object. |
protected int |
fetch_std_part(interactor the_obj,
int the_part)
Fetch a standard part from the given object. |
java.lang.Object |
get_value(int ignored_part_number)
Actually evaluate the constraint. |
interactor |
op1_obj()
Object referenced by operand 1 of the constraint. |
int |
op1_part()
Non-standard part number for operand 1 of the constraint. |
byte |
op1_std_part()
Standard part code for operand 1. |
interactor |
op2_obj()
Object referenced by operand 2 of the constraint. |
int |
op2_part()
Non-standard part number for operand 2 of the constraint. |
byte |
op2_std_part()
Standard part code for operand 2. |
interactor |
op3_obj()
Object referenced by operand 3 of the constraint. |
int |
op3_part()
Non-standard part number for operand 3 of the constraint. |
byte |
op3_std_part()
Standard part code for operand 3. |
byte |
orientation()
Orientation under which this constraint is evaluated. |
interactor |
self_obj()
The object which serves as self for the constraint. |
void |
set_const_value(int v)
Set the constant value passed to the constraint evaluation function. |
void |
set_orientation(int ov)
Set the orientation under which this constraint is evaluated. |
void |
set_self_obj(interactor slf_obj)
Set the object which serves as self for the constraint. |
protected void |
setup_dependencies()
Establish the external dependencies needed for this constraint |
protected void |
setup_op_dependencies(byte op_std_part,
interactor op_obj,
int op_part)
Setup dependencies for a particular operand. |
protected void |
setup_std_part_dependencies(interactor for_obj,
byte part_code)
Establish the external dependencies for a particular standard part reference. |
Methods inherited from class sub_arctic.constraints.external_constraint |
attach_dependent,
detach_dependent,
value_ood |
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 _const_value
protected byte _orientation
protected interactor _self_obj
public static final byte NOT_STANDARD
public static final byte IS_HORIZ
protected byte _op1_std_part
protected byte _op2_std_part
protected byte _op3_std_part
protected int _op1_part
protected interactor _op1_obj
protected int _op2_part
protected interactor _op2_obj
protected int _op3_part
protected interactor _op3_obj
protected int _num_ops
Constructor Detail |
public std_ext_constraint(int enc, interactor slf_obj, int orient, ext_objpart_encoding op1, ext_objpart_encoding op2, ext_objpart_encoding op3, int c_val)
int
- enc The (partial) standard encoding for the
constraint (the operand encoding portions are
ignored).interactor
- slf_obj The object which acts as self for the
constraint (this is only used for constraints
that implicitly reference self or parent).int
- orient Orientation of the part we are constraining.ext_objpart_encoding
- op1 An encoding of the first operand.ext_objpart_encoding
- op2 An encoding of the second operand.ext_objpart_encoding
- op3 An encoding of the third operand.int
- c_val The constant value supplied to the constraint.public std_ext_constraint(int enc, interactor slf_obj, int orient, ext_objpart_encoding op1, ext_objpart_encoding op2, int c_val)
int
- enc The (partial) standard encoding for the
constraint (the operand encoding portions are
ignored).interactor
- slf_obj The object which acts as self for the
constraint (this is only used for constraints
that implicitly reference self or parent).int
- orient Orientation of the part we are constraining.ext_objpart_encoding
- op1 An encoding of the first operand.ext_objpart_encoding
- op2 An encoding of the second operand.int
- c_val The constant value supplied to the constraint.public std_ext_constraint(int enc, interactor slf_obj, int orient, ext_objpart_encoding op1, int c_val)
int
- enc The (partial) standard encoding for the
constraint (the operand encoding portions are
ignored).interactor
- slf_obj The object which acts as self for the
constraint (this is only used for constraints
that implicitly reference self or parent).int
- orient Orientation of the part we are constraining.ext_objpart_encoding
- op1 An encoding of the second operand.int
- c_val The constant value supplied to the constraint.public std_ext_constraint(int enc, interactor slf_obj, int orient, int c_val)
int
- enc The (partial) standard encoding for the
constraint (the operand encoding portions are
ignored).interactor
- slf_obj The object which acts as self for the
constraint (this is only used for constraints
that implicitly reference self or parent).int
- orient Orientation of the part we are constraining.int
- c_val The constant value supplied to the constraint.Method Detail |
public int encoding()
public int const_value()
public void set_const_value(int v)
public byte orientation()
public void set_orientation(int ov)
public interactor self_obj()
public void set_self_obj(interactor slf_obj)
public byte op1_std_part()
public byte op2_std_part()
public byte op3_std_part()
public int op1_part()
public interactor op1_obj()
public int op2_part()
public interactor op2_obj()
public int op3_part()
public interactor op3_obj()
protected void setup_std_part_dependencies(interactor for_obj, byte part_code)
interactor
- for_obj the object depended upon.byte
- part_code the code of the part within that object we are
dependent upon. Note: this should include the
IS_HORIZ bit as used in op*_std_part.protected void setup_op_dependencies(byte op_std_part, interactor op_obj, int op_part)
byte
- op_std_part the part (or NOT_STANDARD)interactor
- op_obj the object referred to for a non-standard part.int
- op_part the part referred to for a non-standard part.protected void setup_dependencies()
protected int fetch_std_part(interactor the_obj, int the_part)
interactor
- the_obj the object we are getting the part from.int
- the_part encoding of the part (including IS_HORIZ bit).protected int fetch_part(interactor from_obj, int std_part, int ext_part_num)
interactor
- from_obj object we are getting part value from.int
- std_part encoding for a standard part, or NOT_STANDARD.int
- ext_part number of non-standard part being referred to.public java.lang.Object get_value(int ignored_part_number)
int
- ignored_part_number Ignored.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |