public class DsRelationDefinition
extends java.lang.Object
implements java.io.Externalizable
Modifier and Type | Field and Description |
---|---|
private boolean |
active
true if the relation is active. |
private java.lang.String |
childBuffer
The name of the child buffer.
|
private boolean |
fkeyHidden
The FOREIGN-KEY-HIDDEN status of this relation.
|
private java.lang.String |
name
The name of this relation.
|
private boolean |
nested
The NESTED status of this relation.
|
private java.lang.String |
pairs
The list of relation fields for this relation.
|
private java.lang.String |
parentBuffer
The name of the parent buffer.
|
private boolean |
parentId
true if this is a parent-id relation type. |
private boolean |
recursive
true to flag this as a RECURSIVE relation. |
private boolean |
reposition
The REPOSITION status of this relation.
|
private java.lang.String |
whereString
The WHERE-STRING string.
|
Constructor and Description |
---|
DsRelationDefinition()
Default c'tor, explicitly added to allow instances of this class to be created on
deserialization.
|
DsRelationDefinition(DataRelation rel)
Constructor used by
DataSetContainer(com.goldencode.p2j.util.handle, boolean, boolean, boolean) . |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getChildBuffer()
Retrieves the name of the buffer with child role in this relation.
|
java.lang.String |
getFieldPairs()
Get the field pairs of this relation.
|
java.lang.String |
getName()
Gets the name of this relation.
|
java.lang.String |
getParentBuffer()
Gets the name of the buffer with parent role in this relation.
|
java.lang.String |
getWhereString()
Obtain the
WHERE-STRING predicate of this relation. |
boolean |
isActive()
Checks whether this relation is active.
|
boolean |
isFkeyHidden()
Get the FOREIGN-KEY-HIDDEN status of this relation.
|
boolean |
isNested()
Get the NESTED status of this relation.
|
boolean |
isParentId()
Check whether this is a PARENT-ID relation.
|
boolean |
isRecursive()
Get the RECURSIVE status of this relation.
|
boolean |
isReposition()
Get the REPOSITION status of this relation.
|
void |
readExternal(java.io.ObjectInput in)
Read the relation definition from the specified input source.
|
void |
setActive(boolean active)
Sets the status of this relation.
|
void |
setChildBuffer(java.lang.String childBuffer)
Configures the buffer with child role in this relation.
|
void |
setFieldPairs(java.lang.String pairs)
Set the field pairs of this relation.
|
void |
setFkeyHidden(boolean fkeyHidden)
Set the FOREIGN-KEY-HIDDEN status of this relation.
|
void |
setName(java.lang.String name)
Sets the name of this relation.
|
void |
setNested(boolean nested)
Set the NESTED status of this relation.
|
void |
setParentBuffer(java.lang.String parentBuffer)
Configures the buffer with parent role in this relation.
|
void |
setParentId(boolean parentId)
Configures whether this is a PARENT-ID relation.
|
void |
setRecursive(boolean recursive)
Set the RECURSIVE status of this relation.
|
void |
setReposition(boolean reposition)
Set the REPOSITION status of this relation.
|
void |
setWhereString(java.lang.String whereString)
Configures the
WHERE-STRING predicate of this relation. |
java.lang.String |
toString()
Get a string representation of this relation.
|
void |
writeExternal(java.io.ObjectOutput out)
Send the relation definition to the specified output destination.
|
private java.lang.String name
private java.lang.String parentBuffer
private java.lang.String childBuffer
private java.lang.String whereString
private boolean active
true
if the relation is active.private boolean parentId
true
if this is a parent-id relation type.private java.lang.String pairs
private boolean fkeyHidden
private boolean recursive
true
to flag this as a RECURSIVE relation.private boolean nested
private boolean reposition
public DsRelationDefinition()
public DsRelationDefinition(DataRelation rel)
DataSetContainer(com.goldencode.p2j.util.handle, boolean, boolean, boolean)
.rel
- The DataRelation
this object will be defining.public java.lang.String getName()
public void setName(java.lang.String name)
name
- The (new) name of the relation.public java.lang.String getParentBuffer()
public void setParentBuffer(java.lang.String parentBuffer)
parentBuffer
- the name of the (new) buffer with parent role in this relation.public java.lang.String getChildBuffer()
public void setChildBuffer(java.lang.String childBuffer)
childBuffer
- the name of the (new) buffer with child role in this relation.public java.lang.String getWhereString()
WHERE-STRING
predicate of this relation.WHERE-STRING
predicate of this relation.public void setWhereString(java.lang.String whereString)
WHERE-STRING
predicate of this relation.whereString
- The WHERE-STRING
predicate of this relation.public void setFieldPairs(java.lang.String pairs)
pairs
- The field pairs of this relation.public void setFkeyHidden(boolean fkeyHidden)
fkeyHidden
- The FOREIGN-KEY-HIDDEN status of this relation.public void setRecursive(boolean recursive)
recursive
- The RECURSIVE status of this relation.public void setNested(boolean nested)
nested
- The NESTED status of this relation.public void setReposition(boolean reposition)
reposition
- The REPOSITION status of this relation.public boolean isActive()
true
when the relation is active.public void setActive(boolean active)
active
- Use true
to set the relation as active and false
otherwise.public boolean isParentId()
true
if this is a PARENT-ID relation.public java.lang.String getFieldPairs()
public boolean isFkeyHidden()
public boolean isRecursive()
public boolean isNested()
public boolean isReposition()
public void setParentId(boolean parentId)
parentId
- Use true
to set this relation as a PARENT-ID relation.public final void writeExternal(java.io.ObjectOutput out) throws java.io.IOException
writeExternal
in interface java.io.Externalizable
out
- The output destination to which the relation definition will be sent.java.io.IOException
- In case of I/O errors.public final void readExternal(java.io.ObjectInput in) throws java.io.IOException
readExternal
in interface java.io.Externalizable
in
- The input source from which the relation definition will be read.java.io.IOException
- In case of I/O errors.public java.lang.String toString()
toString
in class java.lang.Object