[This is preliminary documentation and subject to change.]
Create a response PDU, optionally as a response to a Connect PDU, and validity checks the resultant PDU.
See Create.
If creating a response to a Connect PDU the extra Connect bytes will be added, they define the protocol version in use and the maximum packet size. The latter is as set at initialisation with bufferSize, or subsequently with LocalMru.
The response code is checked for validity, for instance throwing ProtocolViolationException if the ‘final’ bit is clear. See OBEX13.pdf sections 3.2 and 3.2.1.
| Exception Type | Condition |
|---|---|
| ProtocolViolationException | If the response code in invalid, see above. |
| For other possible exceptions see Create. |
ObexPduFactory Class | Brecham.Obex.Pdus Namespace | ObexPduFactory.CreateResponse Overload List