nn::http::Connection::AddPostDataRaw Member Functionnn::Result AddPostDataRaw( const void * pValue, size_t valueSize );
| Name | Description | |
|---|---|---|
| in | pValue | Data content. |
| in | valueSize | Data size of pValue. |
Result listed below. | Value | Description |
|---|---|
ResultSuccess |
Process was successful. |
| ResultPostAddedAnotherErr | POST data has already been configured. The function returns this value when POST data of a different type has already been configured, if POST data of the Raw type has already been configured, or if adding POST data when in the SetLazyPostDataSetting mode. Use this function carefully to not conflict with such POST data configuration. (To reconfigure POST data, first call the Connection class's Finalize function, and then call Initialize again.) |
| ResultOutOfMemoryErr | Could not allocate POST data buffer from the buffer configured by the nn::http::Initialize function. Adjust the total size of the POST data being registered simultaneously to fit within the the buffer configured by the nn::http::Initialize function. |
| ResultConnectionStatusErr | Error indicating an invalid state. This function cannot be called in the current communication state. (For example, the function returns this error if the system is already connected. You must call this function before calling Connect.) |
| ResultInvalidParamErr | Error indicating an invalid parameter. Specify valid values for all parameters and call this function again. |
| ResultNotConnectedErr | Error indicating a Connection class instance for which the target URL is not assigned. The function has not done anything as it has been called on a Connection instance for which you have not yet successfully called Initialize. |
| ResultNotInitializedErr | Error indicating that the library is not initialized. None of this library's functions can be used until you first call nn::http::Initialize. |
| A value other than the above. | Unexpected error (See http_Result.h for details). |
Function used to configure raw POST data before Connecting.
Batch-sets all POST data to send in an HTTP request.
This function configures all POST data as direct raw data in binary format.
(Other similar functions set the label and value portions of the POST data.)
Use this function for settings before running Connect.
The POST data is sent by running the Connect function after configuring the settings.
Because this function configures all the POST data, an error is returned if a function that configures partial POST data (that is, AddPostDataAscii or AddPostDataBinary) is called after this function is used to configure all the POST data. (The Description of this error is nn::http::ER_POST_ADDED_ANOTHER.)
If this function is called multiple times to configure raw data, data that was set during previous calls is discarded and updated to the data from the most recent call.
CONFIDENTIAL