public void unexpectedAttribute(Attribute attribute, QName... expectedAttributes) throws JAXBException { String message = "Unexpected attribute " + attribute.getName() + ", expected " + Arrays.toString(expectedAttributes); validationError(message, attribute.getReader().getLocation(), null); }