Succeed a RepositoryAttribute
If the value of a RepositoryAttribute changes, this can be replicated in enmeshed with this use case.
It allows you to update the content and keeps a coherent history of all versions by establishing a doubly linked list, using the LocalAttribute’s parameters succeeds and succeededBy.
Hence, every LocalAttribute may have exactly one predecessor and one successor.
In case you shared the preceeding version of the RepositoryAttribute, the corresponding own shared IdentityAttribute copy will only be succeeded, if you decide to notify the peer of the respective shared IdentityAttribute about the succession.
Parameters
predecessorId: theidof the RepositoryAttribute you want to succeed- The
successorContentaccording to the parameters of an IdentityAttribute as described in the data model, except for theowner, which is automatically set to theaddressof your Identity.
On Success
- The response returns a
predecessorand asuccessorLocalAttribute. - The
predecessoris an updated version of the RepositoryAttribute belonging topredecessorId, having thesucceededByfield set to thesuccessor’sid. - The
successoris a new RepositoryAttribute with the updatedsuccessorContent. Itssucceedsproperty links to thepredecessor.
On Failure
- The response cannot be created, if the
predecessorIdbelongs to a RelationshipAttribute. - The response cannot be created, if the
predecessorIdbelongs to an IdentityAttribute with ashareInfo. - The response cannot be created, if the LocalAttribute already has a successor.
- The response cannot be created, if the
successorContentcontains invalid changes, e.g. of the value type. - The response cannot be created, if the parameters are malformed.