protected static void addMessageDescriptorToMessageContext ( final MessageContext context , final MessageDescriptor warning ) { val builder = new MessageBuilder ( ) . warning ( ) . code ( warning . getCode ( ) ) . defaultText ( warning . getDefaultMessage ( ) ) . args ( ( Object [ ] ) warning . getParams ( ) ) ; context . addMessage ( builder . build ( ) ) ; }
Adds a warning message to the message context .