public static < K , V > Map < K , V > constrainedMap ( Map < K , V > map , MapConstraint < ? super K , ? super V > constraint ) { return new ConstrainedMap < K , V > ( map , constraint ) ; }
Returns a constrained view of the specified map using the specified constraint . Any operations that add new mappings will call the provided constraint . However this method does not verify that existing mappings satisfy the constraint .