java ee - difference between facade and business delegate pattern -
What is the difference between mask and business representative design patterns, both are not used to hide business logic from the customer?
Delegation customer and actual execution, usually hiding / filtering / increasing some functionality of the implementation from the client .
The mask is providing a curriculum-encrypted API that hides more complex logic and / or coordination, usually several implementations that work together, and usually as the convenience of the client.
Examples of each from Java:
Representative: Mask: If you've ever seen the ridiculous amount of code, the first thing you make a utility method to hide all the ugliness - this method can be considered a mask. Collections.unmodifiableList () gives a list that keeps the original list and representatives of all the methods For a reference, but the exception breaks if its mutator methods are called.
Comments
Post a Comment