private void setFaultRole(SOAPFactory factory, SOAPFault fault) { if (faultRole != null) { SOAPFaultRole soapFaultRole = factory.createSOAPFaultRole(); soapFaultRole.setRoleValue(faultRole.toString()); fault.setRole(soapFaultRole); } }
private void setFaultRole(SOAPFactory factory, SOAPFault fault) { if (faultRole != null) { SOAPFaultRole soapFaultRole = factory.createSOAPFaultRole(); soapFaultRole.setRoleValue(faultRole.toString()); fault.setRole(soapFaultRole); } }
/** * Creates or replaces any existing Role element value for this SOAPFault object. The Role * element is optional in SOAP 1.2. * * @param uri - the URI of the Role * @throws SOAPException - if there was an error in setting the Role for this SOAPFault object * java.lang.UnsupportedOperationException - if this message does not * support the SOAP 1.2 concept of Fault Role. */ public void setFaultRole(String uri) throws SOAPException { SOAPFactory soapFactory = (SOAPFactory)this.omTarget.getOMFactory(); if (((SOAPFactory)this.omTarget.getOMFactory()).getSOAPVersion() == SOAPVersion.SOAP11) { throw new UnsupportedOperationException("message does not support the " + "SOAP 1.2 concept of Fault Role"); } SOAPFaultRole soapFaultRole = soapFactory.createSOAPFaultRole(this.omTarget); soapFaultRole.setRoleValue(uri); this.omTarget.setRole(soapFaultRole); }
/** * Creates or replaces any existing Role element value for this SOAPFault object. The Role * element is optional in SOAP 1.2. * * @param uri - the URI of the Role * @throws SOAPException - if there was an error in setting the Role for this SOAPFault object * java.lang.UnsupportedOperationException - if this message does not * support the SOAP 1.2 concept of Fault Role. */ public void setFaultRole(String uri) throws SOAPException { SOAPFactory soapFactory = (SOAPFactory)this.omTarget.getOMFactory(); if (((SOAPFactory)this.omTarget.getOMFactory()).getSOAPVersion() == SOAP11Version.getSingleton()) { throw new UnsupportedOperationException("message does not support the " + "SOAP 1.2 concept of Fault Role"); } SOAPFaultRole soapFaultRole = soapFactory.createSOAPFaultRole(this.omTarget); soapFaultRole.setRoleValue(uri); this.omTarget.setRole(soapFaultRole); }
soapFault.setRole(soapFaultRole);
/** * Sets this SOAPFault object with the given fault actor.The fault actor is the recipient in the * message path who caused the fault to happen. If this SOAPFault supports SOAP 1.2 then this * call is equivalent to setFaultRole(String) * * @param faultActor - a String identifying the actor that caused this SOAPFault object * @throws SOAPException - if there was an error in adding the faultActor to the underlying XML * tree. */ public void setFaultActor(String faultActor) throws SOAPException { if (this.omTarget.getRole() == null) { SOAPFaultRole faultRoleImpl = ((SOAPFactory)this.omTarget.getOMFactory()).createSOAPFaultRole( this.omTarget); faultRoleImpl.setRoleValue(faultActor); this.omTarget.setRole(faultRoleImpl); } else { SOAPFaultRole role = this.omTarget.getRole(); role.setRoleValue(faultActor); } }
/** * Sets this SOAPFault object with the given fault actor.The fault actor is the recipient in the * message path who caused the fault to happen. If this SOAPFault supports SOAP 1.2 then this * call is equivalent to setFaultRole(String) * * @param faultActor - a String identifying the actor that caused this SOAPFault object * @throws SOAPException - if there was an error in adding the faultActor to the underlying XML * tree. */ public void setFaultActor(String faultActor) throws SOAPException { if (this.omTarget.getRole() == null) { SOAPFaultRole faultRoleImpl = ((SOAPFactory)this.omTarget.getOMFactory()).createSOAPFaultRole( this.omTarget); faultRoleImpl.setRoleValue(faultActor); this.omTarget.setRole(faultRoleImpl); } else { SOAPFaultRole role = this.omTarget.getRole(); role.setRoleValue(faultActor); } }
} else if (axisFault != null) { if (axisFault.getFaultRoleElement() != null) { fault.setRole(axisFault.getFaultRoleElement());
} else if (axisFault != null) { if (axisFault.getFaultRoleElement() != null) { fault.setRole(axisFault.getFaultRoleElement());
SOAPFaultRole soapFaultRole = fac.createSOAPFaultRole(); soapFaultRole.setRoleValue(fault.getRole().getRoleValue()); newFault.setRole(soapFaultRole);