public class MRef extends Object implements Serializable
Allows to reference a model object that may or not be known. The reference is made of the object metaclass name, the object identifier and optionally the object name.
Modifier and Type | Field and Description |
---|---|
String |
mc
Metaclass name.
|
String |
name
Optional element name.
|
String |
uuid
Element UUID.
|
Constructor and Description |
---|
MRef(MObject element)
Creates a reference for the given element.
|
MRef(String s)
Construct a MRef instance from a String whose format is the MRef.toString() format so that:
given mref a MRef, new MRef(mref.toString()).equals(mref) is guaranteed to be true . |
MRef(String mc,
String tuuid)
Creates a reference.
|
MRef(String mc,
String tuuid,
String name)
Creates a reference.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object obj) |
int |
hashCode() |
static void |
main(String[] argvs)
Test main method
|
String |
toString()
Produces a string representing this MRef object.
|
public String mc
public String name
public String uuid
public MRef(MObject element)
element
- The element to reference.public MRef(String mc, String tuuid)
mc
- The metaclass name.tuuid
- The UUIDpublic MRef(String mc, String tuuid, String name)
mc
- The metaclass name.tuuid
- The UUIDname
- an object name, may be null
.public MRef(String s)
new MRef(mref.toString()).equals(mref)
is guaranteed to be true
.s
- a string