private void validateRequiredProtocol(Element roleDescriptorElem) throws IDMException {
  String protocols=roleDescriptorElem.getAttribute(SAMLNames.PSE);
  if (!protocols.contains(SAMLNames.REQUIREDPROTOCAL)) {
    throw new IDMException(String.format("SAML meta data error. Element's attribute %s=[%s]" + "does not have required protocal declaration [%s]!",SAMLNames.PSE,protocols,SAMLNames.REQUIREDPROTOCAL));
  }
}

private void validateRequiredProtocol ( Element roleDescriptorElem ) throws IDMException { String protocols = roleDescriptorElem . getAttribute ( SAMLNames . PSE ) ; if ( ! protocols . contains ( SAMLNames . REQUIREDPROTOCAL ) ) { throw new IDMException ( String . format ( "SAML meta data error. Element's attribute %s=[%s]" + "does not have required protocal declaration [%s]!" , SAMLNames . PSE , protocols , SAMLNames . REQUIREDPROTOCAL ) ) ; } }
make sure a required protocol is contained in protocalsupportenumeration attribute .
