nl_tokens: Search through the originalDirective s element for elements that contain information about how to map validation keys to messages
pl_tokens: function getValidationMessageMap ( originalElement ) { // Find all the <validator> child elements and extract their (key, message) info var validationMessages = { } ; angular . forEach ( originalElement . find ( 'validator' ) , function ( element ) { // Wrap the element in jqLite/jQuery element = angular . <mask> ( element ) ; // Store the message info to be provided to the scope later // The content of the validation element may include interpolation {{}} // so we will actually store a function created by the $interpolate service // To get the interpolated message we will call this function with the scope. e.g. //   var messageString = getMessage(scope); validationMessages [ element . attr ( 'key' ) ] = $interpolate ( element . text ( ) ) ; } ) ; return validationMessages ; }