Certain java interfaces need to be restrict not to use a set of Java classes. For example, the Vector and ArrayList, in this case, Collection and List.
It could be used to prevent API interface from using incorrect classes, for example, web services.
Also, we could apply it to any project to loose couple the implementation from interface definition.
Log in to post a comment.