# HasAssignmentPolicyConstraintType (Complex Type)

### Namespace: http://midpoint.evolveum.com/xml/ns/public/common/common-3

Supertype: AbstractPolicyConstraintType
Constraint that triggers when the focus has given assignment(s).

Item Summary
Name | Type | Multiplicity | Description
--- | --- | --- | ---
name | property string | [0,1] | Identifier of the constraint.
description | property string | [0,1] |
presentation | container PolicyConstraintPresentationType | [0,1] | How should be triggering of this constraint presented, e.
enforcement | property PolicyConstraintEnforcementType | [0,1] |
targetRef | reference ObjectReferenceType | [1,1] |
direct | property boolean | [0,1] |
enabled | property boolean | [0,1] |
relation | property QName | [0,-1] |

- ### Items

  - #### name

    Flags: RAM,runtime

    Multiplicity: [0,1]

    Identifier of the constraint. It is used when midPoint needs to refer to a specific constraint, e.g. in order to record exception. This element is formally specified as optional, mostly due to the compatibility reasons. But it has to be provided in order for some functionality to work correctly.

  - #### description

    Flags: RAM,runtime

    Multiplicity: [0,1]

  - #### presentation

    Flags: RAM,runtime

    Multiplicity: [0,1]

    How should be triggering of this constraint presented, e.g. in enforcement messages, in approvals, in certification, in notifications, etc.

  - #### enforcement

    Flags: RAM,runtime,AVals:3

    Multiplicity: [0,1]

  - #### targetRef

    Flags: RAM

    Multiplicity: [1,1]

  - #### direct

    Flags: RAM,runtime

    Multiplicity: [0,1]

  - #### enabled

    Flags: RAM,runtime

    Multiplicity: [0,1]

  - #### relation

    Flags: RAM,runtime

    Multiplicity: [0,-1]