Create a new Alloy signature.
The signature's unique ID
The atoms defined by the signature
If provided, a proxied signature will be created.
Get an atom by ID
The atom ID
An atom or null if there is no atom with the specified ID
Get an array of all atoms in this signature.
If false, return only atoms defined by this signature, if true, include atoms defined by all subsignatures as well.
Create a clone of this signature.
If provided, a proxied clone will be returned.
Returns true if the set is empty, false if it is not.
Returns true if this set is equivalent to the provided set, false otherwise.
The set to compare to
Get the signature ID.
Returns true if this set is a subset of the provided set, false otherwise.
The set to compare to
Get an array of all signatures that extend this signature.
If false, return only signatures that are immediate children of this signature. If true, return all signatures that are descendants of this signature.
Create a printable string representation of this set.
Get an array of all tuples in this set.
Create a signature from an XML element and populate the signature with atoms. Any signatures that extend the one defined in the element are not created.
The XML <sig>
element
If provided, a proxied signature with proxied atoms will be returned.
Create the Int signature.
The integer bitwidth, which must be greater than or equal to zero.
If provided, a proxied Int signature with proxied atoms will be returned.
TODO: Check and document this.
Build all signatures from an XML <instance>
element. All signatures are
populated with atoms.
The XML <instance>
element
If provided, all signatures and atoms will be proxied.
A map of string IDs, as defined by the "ID" attribute for each signature, to AlloySignature objects.
Get an array of signature types associated with an XML element. Typically
this is used when parsing a field or skolem, as each <field>
and <skolem>
element will have a <types>
child. This method parses the types defined
in this element and returns the corresponding signatures.
The XML element that has a
A map of signature IDs to signatures
In Alloy, a signature introduces a set of atoms.