public class CreateRelationshipCommand extends ExecutableCommandWrapper implements ExecutableCommand
Items
in the Integrity database.
Constraints:
FieldValue
must be owned by its source Item
.FieldValue
must reference a Field
.Items
(either source or targets of the relation) must already exist in the database.Notes:
CompoundCommand
.Usage:
new CreateRelationshipCommand(myValue, myTargetItem).execute();
CompoundCommand
Constructor and Description |
---|
CreateRelationshipCommand(FieldValue fieldValue,
Collection<? extends Element> targetElements)
Instantiates a command to add a relationship in the database.
|
CreateRelationshipCommand(FieldValue fieldValue,
Element targetElement)
Instantiates a command to add a relationship in the database.
|
execute
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
execute
public CreateRelationshipCommand(FieldValue fieldValue, Element targetElement)
fieldValue
- the field value which references a relation to create.targetElement
- the target element of the relationship.public CreateRelationshipCommand(FieldValue fieldValue, Collection<? extends Element> targetElements)
fieldValue
- the field value which references a relation to create.targetElements
- the target elements of the relationship.