Skip to end of metadata
Go to start of metadata

MidPoint 3.7 and later

Getting Specific Path Segment

First-Order Chain and Proto-Role

Assignment path is often used to apply meta-roles. However, the high-order inducements in the meta-roles often need to get data from other roles in the hierarchy. That is exactly what assignment path is for. But, the entire assignment path may be confusing and quite difficult to understand and process. Therefore there are two method that are designed to make the life with assignment path easier.

Firstly, there is a way how to get first-order chain from the assignment path. This is the chain (hierarchy) of roles as the "user" understands it. The chain is formed by processing metaroles and "expanding" them. The meta-roles are not part of the chain. So this pretends that there are no meta-roles and the high order inducement are placed directly in the roles in a plain role hierarchy. The first order chain is easy to get and work with:

Especially the last segment of first-order chain is interesting. This is what we call proto-role. Proto-role is the role that the currently-processed inducement "applies to". I.e. the role that would contain this inducement in case that meta-roles were not used. This role is quite often used when working with meta-roles. Therefore even though the proto-role is quite easy to get from the first-order chain there is a special method to get it. So this is all easier and more obvious.


There are cases when meta-meta-roles and even meta-meta-meta-roles are used. First-order chain and proto-roles are generic concepts and they should work well in all those meta-meta-cases. However, these cases may need also a different roles than a proto-role or first-order roles. That is the reason why the entire assignment path structure is exposed for use in expressions.


This example "stamps" each focus with the description of assigned role.

To be effective, we outsource logic to one common meta role that all other stamping roles assigns:

Then each stamping role has assignment to this metarole:

Finally, any FocusType (e.g. UserType) assigned to Stamping role will have its fullName attribute populated with the value of the Stamping role's description ("stamp1-bearer" in this case).

See Also

  • No labels