Struct espr::ast::InverseAttribute [−][src]
pub struct InverseAttribute {
pub name: AttributeDecl,
pub dest: String,
pub dest_aggregation: AggregationOption,
pub attribute: String,
pub attribute_prefix: Option<String>,
}
Expand description
Attribute of an inverse clause parsed by inverse_attr
From ISO 10303-11 document,
ENTITY door;
handle : knob; -- inverse relationship for this attribute
hinges : SET [1:?] OF hinge;
END_ENTITY;
ENTITY knob;
...
INVERSE
opens : door FOR handle;
(* ^ ^ ^
| | attribute name used in the parent entity
| The entity which has `SELF` as attribute
name of this inverse relationship *)
END_ENTITY;
This means
knobs can only exist if they are used in the role of handle in one instance of a door
Fields
name: AttributeDecl
Name of this inverse relationship
opens
in above example
dest: String
The entity name which has SELF
as an attribute
door
in above example
dest_aggregation: AggregationOption
Used if SET
or BAG
for parent entity specification
attribute: String
The attribute name used in the parent entity
handle
in above example
attribute_prefix: Option<String>
Prefix of the attribute, used if the attribute is a sub-attribute of dest
entity
Trait Implementations
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
This method tests for !=
.
Auto Trait Implementations
impl RefUnwindSafe for InverseAttribute
impl Send for InverseAttribute
impl Sync for InverseAttribute
impl Unpin for InverseAttribute
impl UnwindSafe for InverseAttribute
Blanket Implementations
Mutably borrows from an owned value. Read more