Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## be.ehealth.technicalconnector.ws.domain
Class GenericResponse

    java.lang.Object
      be.ehealth.technicalconnector.ws.domain.GenericResponse

    public class GenericResponse

extends Object

This class contains all the information for the generic response.

Constructor Summary
`GenericResponse(SOAPMessage message)`

Method Summary
`Node` | `asNode()` Getter that returns the response as `Node`.
`
`<T> T`
` | `asObject(Class<T> clazz)` Obtain the response as Object.
`Source` | `asSource()` Getter that returns the response as `Source`.
`String` | `asString()` Getter that returns the response as `String`.
`byte[]` | `getAttachment(String cid)` Method to obtain an Attachement based on de swaref id
`void` | `getSOAPException()` Helper method that verifies if the `SOAPBody` contains a `SOAPFault`.
`SOAPMessage` | `getSOAPMessage()` Getter that returns the original `SOAPMessage`.

Methods inherited from class java.lang.Object
`equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### GenericResponse

    public GenericResponse(SOAPMessage message)

Method Detail

### asNode

    public Node asNode()
                throws SOAPException

  Getter that returns the response as `Node`.

  Warning:For obtaining the Attachement: the method getAttachement can be used.

  Throws:
    `SOAPException`

### asString

    public String asString()
                    throws TechnicalConnectorException,
                           SOAPException

  Getter that returns the response as `String`.

  Warning:For obtaining the Attachement: the method getAttachement can be used.

  Throws:
    `TechnicalConnectorException`
    `SOAPException`

### getSOAPMessage

    public SOAPMessage getSOAPMessage()

  Getter that returns the original `SOAPMessage`.

### asObject

    public <T> T asObject(Class<T> clazz)
               throws SOAPException

  Obtain the response as Object.

  Warning: the object passed as parameter must be an JAXBObject with the @XmlRootElement annotation

  Throws:
    `SOAPException`

### getAttachment

    public byte[] getAttachment(String cid)
                         throws SOAPException

  Method to obtain an Attachement based on de swaref id

  Throws:
    `SOAPException`

### asSource

    public Source asSource()
                    throws SOAPException

  Getter that returns the response as `Source`.

  Warning:For obtaining the Attachement: the method getAttachement can be used.

  Throws:
    `SOAPException`

### getSOAPException

    public void getSOAPException()
                          throws SOAPException

  Helper method that verifies if the `SOAPBody` contains a `SOAPFault`.

  Throws:
    `SOAPException`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Connector Packaging PERSNURSE 3.24.0 API
Copyright © {inceptionYear}-2023 eHealth. All Rights Reserved.