Hi there,
Need to implement referential integrity at the user level:
When a user deletes or modify a data (he is allowed to do it), a "Controller" verify that this action won't hurt something:
- that data is not used by an other (for example is a property of an object) or if yes, the last is not used itself by an other (could be changed/erased too)
- the user have acl authorisation on modifying/deleting the data potentially related to this one
A screen should display data relational mapping, asking for instructions based on acl.
In order to keep advantage of "Rich Client", the Flex interface should handle this and let the server serving info, mostly "raw info" (not aggregated). I'm I Right ?
Each DTO has its own proxy.
I thougth I would use a proxy to handle integrity checking, requesting the server for something like "Tell me what is related to this". This ReferentialIntegrityProxy would be called by DTO proxys upon their own delete() or update() commands.
ReferentialIntegrityProxy sends a notification. A ReferentialIntegrityMediator deals with user interaction. ReferentialIntegrityProxy command the DTO proxy to allow or not the action.
Is it best practice?
Many thanks,
Patrick