HiLang Name & Reference
Name
| Definition |
Names are normally just a reference, but can be generic with {“<”, “>”} separating the type parameters. Entities/Aspect/Segment cannot have generic parameters (since they must have unambiguous names), but all other generic types will be expanded during compilation (except List<T> and Set<T> which are directly supported) Names will be resolved during compilation of the hilang model into source code for the target language
HiLang names are always unambiguously referenced to include all part of the name
"
Permission granted to a group user or role on a resource, typically an entity in hiperspace database.
"
segment Access.RBAC.Permission : Versioned, Access.RBAC.Permissioned
= Edge (From = owner, To = Item, Name = Item.Subject, TypeName = TypeName),
Edge2 (From = Item, To = owner, Name = Item.Subject, TypeName = TypeName + "|From")
(
" Identify all the resource item. "
Item : Access.RBAC.Resource,
" The permission being granted create, update, delete. "
Right : Access.RBAC.PermissionType
)
{
" The set of roles that have approve this permission. "
Approval : Set<Ref<Access.RBAC.Group>> /* resolved during compilation */
};
"
Group is a hierarchical organization of users or service accounts
"
entity Access.RBAC.Group : Access.RBAC.Principal ... ;
/* Helper to enable a set of references in a set */
value Ref<T>
{
Value : T
};
Reference
References are often a single name, or include their namespace separated by “.”. The name “Sparx.EA.Connector” is a reference where the namespace “Sparx.EA” is included. HiLang references are always fully qualified in the definition, but the generated code is wrapped within a namespace. For example, the entity Sparx.EA.Element has a parent (that is also an entity), but only the key is stored with the child since the parent can be retrieved from hiperspace if needed.