MATLAB Production Server C Client R2024b
component: mds_c_client, module directory: deployment_server/client/c/mps, copyright: MathWorks
Loading...
Searching...
No Matches
client.h
Go to the documentation of this file.
1
4#ifndef MATHWORKS_MPS_CLIENT
5#define MATHWORKS_MPS_CLIENT
6
7#define MPS_CLIENT_1_0 0x00010000
8#define MPS_CLIENT_1_1 0x00010001
9
10#ifndef MPS_MAX_VER
11#define MPS_MAX_VER MPS_CLIENT_1_1
12#endif
13
14#ifdef _MSC_VER
15#define MPS_DLL_EXPORT_SYM __declspec(dllexport)
16#define MPS_DLL_IMPORT_SYM __declspec(dllimport)
17#elif __GNUC__ >= 4
18#define MPS_DLL_EXPORT_SYM __attribute__((visibility("default")))
19#define MPS_DLL_IMPORT_SYM __attribute__((visibility("default")))
20#else
21#define MPS_DLL_EXPORT_SYM
22#define MPS_DLL_IMPORT_SYM
23#endif
24
25#if defined(BUILDING_MPSCLIENT)
26#define MPSCLIENT_PUBLISHED_API MPS_DLL_EXPORT_SYM
27#else
28#define MPSCLIENT_PUBLISHED_API MPS_DLL_IMPORT_SYM
29#endif
30
31#ifdef __cplusplus
32#define MPSCLIENT_PUBLISHED_API_EXTERN_C extern "C" MPSCLIENT_PUBLISHED_API
33#else
34#define MPSCLIENT_PUBLISHED_API_EXTERN_C extern MPSCLIENT_PUBLISHED_API
35#endif
36
37#include <limits.h>
38
39#ifdef _MSC_VER
40typedef unsigned __int64 uint64;
41#else
42#include <stddef.h>
43#include <stdint.h>
44typedef uint64_t uint64;
45#endif
46
49
52
55typedef struct mpsArray mpsArray;
56
62
70
71#ifndef TMW_BITS_PER_INT
72#if INT_MAX == 0x7FL
73#define TMW_BITS_PER_INT 8
74#elif INT_MAX == 0x7FFFL
75#define TMW_BITS_PER_INT 16
76#elif INT_MAX == 0x7FFFFFFFL
77#define TMW_BITS_PER_INT 32
78#else
79#define TMW_BITS_PER_INT -1
80#endif
81#endif
82
83#ifndef TMW_BITS_PER_LONG
84#if LONG_MAX == 0x7FL
85#define TMW_BITS_PER_LONG 8
86#elif LONG_MAX == 0x7FFFL
87#define TMW_BITS_PER_LONG 16
88#elif LONG_MAX == 0x7FFFFFFFL
89#define TMW_BITS_PER_LONG 32
90#else
91#define TMW_BITS_PER_LONG -1
92#endif
93#endif
94
95#ifndef TMW_BITS_PER_SCHAR
96#if SCHAR_MAX == 0x7FL
97#define TMW_BITS_PER_SCHAR 8
98#elif SCHAR_MAX == 0x7FFFL
99#define TMW_BITS_PER_SCHAR 16
100#elif SCHAR_MAX == 0x7FFFFFFFL
101#define TMW_BITS_PER_SCHAR 32
102#else
103#define TMW_BITS_PER_SCHAR -1
104#endif
105#endif
106
107#ifndef TMW_BITS_PER_SHRT
108#if SHRT_MAX == 0x7FL
109#define TMW_BITS_PER_SHRT 8
110#elif SHRT_MAX == 0x7FFFL
111#define TMW_BITS_PER_SHRT 16
112#elif SHRT_MAX == 0x7FFFFFFFL
113#define TMW_BITS_PER_SHRT 32
114#else
115#define TMW_BITS_PER_SHRT -1
116#endif
117#endif
118
119#ifndef UINT16_T
120#if TMW_BITS_PER_INT == 16
121#define UINT16_T unsigned int
122#elif TMW_BITS_PER_LONG == 16
123#define UINT16_T unsigned long
124#elif TMW_BITS_PER_SCHAR == 16
125#define UINT16_T unsigned char
126#elif TMW_BITS_PER_SHRT == 16
127#define UINT16_T unsigned short
128#endif
129#endif
130
131/* +0 because of a doxygen bug */
132#if (defined(__cplusplus) && (__cplusplus + 0 >= 201103L)) || \
133 (defined(_HAS_CHAR16_T_LANGUAGE_SUPPORT) && _HAS_CHAR16_T_LANGUAGE_SUPPORT)
134typedef char16_t CHAR16_T;
135#elif defined(_MSC_VER)
136typedef wchar_t CHAR16_T;
137#else
138typedef UINT16_T CHAR16_T;
139#endif
140
142
143#if !defined(__cplusplus)
144
145typedef unsigned char bool;
146
147#ifndef false
148#define false (0)
149#endif
150#ifndef true
151#define true (1)
152#endif
153
154#endif
155
158typedef bool mpsLogical;
159
161typedef enum mpsErrorInfoType {
162
165
168
171
173
174
176typedef struct mpsErrorInfoHTTP
177{
178
180 unsigned int responseCode;
181
183 const char* responseMessage;
184
186
187
189typedef struct matlabStackFrame
190{
191
193 const char* file;
194
196 const char* function;
197
199 int line;
200
202
203
205typedef struct mpsErrorInfoMATLAB
206{
207
209 const char* message;
210
212 const char* identifier;
213
216
219
221
224{
225
227 const char* genericErrorMsg;
228
230
231
233typedef struct mpsErrorInfo
234{
235
238
240 char const* message;
241
243 union {
246
249
253
255
257typedef enum mpsStatus {
258
261
264
266
268typedef enum mpsComplexity {
274
276typedef enum mpsClassID {
308
314typedef struct mpsClientRuntime
315{
316
328
333
335 void (*setResponseTimeOutSec)(mpsClientConfig* config, unsigned long value);
336
338 unsigned long (*getResponseTimeOutSec)(const mpsClientConfig* config);
339
341 void (*setResponseSizeLimit)(mpsClientConfig* config, unsigned int value);
342
344 unsigned int (*getResponseSizeLimit)(const mpsClientConfig* config);
345
359
369
383 void (*getLastErrorInfo)(mpsClientContext const* context, mpsErrorInfo* errorInfo);
384
388
412 const char* url,
413 int nlhs,
414 mpsArray* plhs[],
415 int nrhs,
416 const mpsArray* prhs[]);
417
422#if MPS_MAX_VER >= MPS_CLIENT_1_1
423
425 void (*setClientCertFile)(mpsClientConfig* config, const char* certFile);
426
428 const char* (*getClientCertFile)(const mpsClientConfig* config);
429
431 void (*setPrivateKeyFile)(mpsClientConfig* config, const char* pkFile);
432
434 const char* (*getPrivateKeyFile)(const mpsClientConfig* config);
435
437 void (*setPrivateKeyPasswd)(mpsClientConfig* config, const char* passwd);
438
440 const char* (*getPrivateKeyPasswd)(const mpsClientConfig* config);
441
443 void (*setCAFile)(mpsClientConfig* config, const char* caFile);
444
446 const char* (*getCAFile)(const mpsClientConfig* config);
447
449 void (*setRevocationListFile)(mpsClientConfig* config, const char* crlFile);
450
452 const char* (*getRevocationListFile)(const mpsClientConfig* config);
453
456 void (*setVerifyHost)(mpsClientConfig* config, mpsLogical verifyHost);
457
460
464 void (*setVerifyPeer)(mpsClientConfig* config, mpsLogical verifyPeer);
465
468
469#endif
470
472
480
491
497
502
509
516
522
528
534
540
546
552
558
564
570
576
582
588
595
601
607
613
639MPSCLIENT_PUBLISHED_API_EXTERN_C bool mpsIsClass(const mpsArray* mlArr, const char* classname);
640
646
652
661 mpsSize n,
662 mpsComplexity complexFlag);
663
669
680 mpsSize n,
681 mpsClassID classid,
682 mpsComplexity complexFlag);
683
696 const mpsSize* dims,
697 mpsClassID classid,
698 mpsComplexity complexFlag);
699
705
713 const char** str);
714
723
729
736
745
754 mpsSize n,
755 int nfields,
756 const char** fieldnames);
757
768 const mpsSize* dims,
769 int nfields,
770 const char** fieldnames);
771
778
787
800 mpsSize n,
801 mpsSize nzmax,
802 mpsComplexity complexFlag);
803
813 mpsSize n,
814 mpsSize nzmax);
815
825
831
836
842
848
856
865 const mpsSize* dims,
866 mpsSize ndim);
867
873
886 mpsSize nsubs,
887 mpsIndex* subs);
888
894
900
906
912
918
924
930
936
942
948
957
963
969
975
981
989 mpsIndex index,
990 const char* fieldname);
991
1000 mpsIndex index,
1001 const char* fieldname,
1002 mpsArray* pvalue);
1003
1009
1016 const char* fieldname);
1017
1024 int fieldnumber);
1025
1033 mpsIndex index,
1034 int fieldnumber);
1035
1043 mpsIndex index,
1044 int fieldnumber,
1045 mpsArray* pvalue);
1046
1053MPSCLIENT_PUBLISHED_API_EXTERN_C int mpsAddField(mpsArray* mlArr, const char* fieldname);
1054
1060
1067
1075
1081
1090
1096
1102
1103#endif
bool mpsIsSparse(const mpsArray *mlArr)
Determine whether array is sparse.
bool mpsIsUint8(const mpsArray *mlArr)
Determine whether mpsArray represents data as unsigned 8-bit integers.
int mpsGetNumberOfFields(const mpsArray *mlArr)
Determine the number of fields in an array of struct.
int mpsSetDimensions(mpsArray *mlArr, const mpsSize *dims, mpsSize ndim)
Modify number of dimensions and size of each dimension of an array.
mpsErrorInfoType
Types of errors that can be thrown when MATLAB function invocation fails.
Definition client.h:161
@ MPS_GENERIC_ERROR_INFO
Any error other than MATLAB execution error or a non-200 HTTP response.
Definition client.h:170
@ MPS_HTTP_ERROR_INFO
A non-200 HTTP response when MATLAB function in invoked from the client.
Definition client.h:164
@ MPS_MATLAB_ERROR_INFO
A MATLAB execution error.
Definition client.h:167
mpsLogical * mpsGetLogicals(const mpsArray *mlArr)
Access the first logical element in an array.
UINT16_T CHAR16_T
Definition client.h:138
mpsArray * mpsCreateCellMatrix(mpsSize m, mpsSize n)
Create a two-dimensional cell array.
size_t mpsGetNumberOfElements(const mpsArray *mlArr)
Determine how many elements are in the array.
bool mpsIsDouble(const mpsArray *mlArr)
Determine whether mpsArray represents data as double-precision, floating-point numbers.
double mpsGetScalar(const mpsArray *mlArr)
Determine the value of the first real element of an array.
#define MPSCLIENT_PUBLISHED_API_EXTERN_C
Definition client.h:32
bool mpsIsLogicalScalarTrue(const mpsArray *mlArr)
Determine whether scalar array is true.
mpsArray * mpsCreateLogicalScalar(mpsLogical value)
Create a scalar logical array.
bool mpsIsStruct(const mpsArray *mlArr)
Determine whether input is structure array.
int mpsAddField(mpsArray *mlArr, const char *fieldname)
Add a field to an array of struct.
struct mpsClientContext mpsClientContext
Establishes a connection between a client and a server.
Definition client.h:69
mpsComplexity
Flag specifying whether array has imaginary components.
Definition client.h:268
@ mpsREAL
Identifies an mpsArray with no imaginary components.
Definition client.h:270
@ mpsCOMPLEX
Identifies an mpsArray with imaginary components.
Definition client.h:272
mpsArray * mpsCreateSparse(mpsSize m, mpsSize n, mpsSize nzmax, mpsComplexity complexFlag)
Create a two-dimensional sparse array.
mpsArray * mpsCreateCellArray(mpsSize ndim, const mpsSize *dims)
Create a N-dimensional cell array.
uint64 mpsSize
Type that represents size values, such as array dimensions.
Definition client.h:48
bool mpsIsUint32(const mpsArray *mlArr)
Determine whether mpsArray represents data as unsigned 32-bit integers.
mpsArray * mpsGetCell(const mpsArray *mlArr, mpsIndex index)
Access the contents of a cell array at a specified index.
mpsArray * mpsCreateLogicalMatrix(mpsSize m, mpsSize n)
Create a two-dimensional logical array.
void mpsSetM(mpsArray *mlArr, mpsSize m)
Set the first dimension of an array.
bool mpsIsUint64(const mpsArray *mlArr)
Determine whether mpsArray represents data as unsigned 64-bit integers.
mpsChar * mpsGetChars(const mpsArray *mlArr)
Access the data in a character array.
const char * mpsGetInitializationErrorMessage(void)
Returns the error message representing the failure in global initialization that sets up the programm...
uint64 mpsIndex
Type that represents index values, such as indices into arrays.
Definition client.h:51
bool mpsIsInt32(const mpsArray *mlArr)
Determine whether mpsArray represents data as signed 32-bit integers.
int mpsGetFieldNumber(const mpsArray *mlArr, const char *fieldname)
Determine the number of a field in an array of struct given the field name.
bool mpsIsClass(const mpsArray *mlArr, const char *classname)
Determine whether array is member of specified class.
mpsArray * mpsCreateString(const char *str)
Create a string array.
mpsArray * mpsCreateLogicalArray(mpsSize ndim, const mpsSize *dims)
Create a N-dimensional logical array.
int mpsGetString(const mpsArray *mlArr, char *str, mpsSize len)
Copy the character data of a string array into a C-style string.
size_t mpsGetElementSize(const mpsArray *mlArr)
Determine the number of bytes in each data element of an array.
mpsArray * mpsCreateNumericMatrix(mpsSize m, mpsSize n, mpsClassID classid, mpsComplexity complexFlag)
Create a two-dimensional numeric array.
mpsSize mpsGetNumberOfDimensions(const mpsArray *mlArr)
Determine the number of dimensions in an array.
mpsArray * mpsCreateCharMatrixFromStrings(mpsSize rows, const char **str)
Create a two-dimensional string array.
void mpsSetNzmax(mpsArray *mlArr, mpsSize nzmax)
Set the maximum number of non-zero elements in a sparse array.
mpsClassID mpsGetClassID(const mpsArray *mlArr)
Determine the class of an array.
mpsIndex * mpsGetJc(const mpsArray *mlArr)
Determine the starting address of the jc array in a sparse array.
size_t mpsGetM(const mpsArray *mlArr)
Determine the first dimension of an array.
bool mpsIsSingle(const mpsArray *mlArr)
Determine whether mpsArray represents data as single-precision, floating-point numbers.
mpsArray * mpsCreateSparseLogicalMatrix(mpsSize m, mpsSize n, mpsSize nzmax)
Create a two-dimensional sparse array.
bool mpsIsEmpty(const mpsArray *mlArr)
Determine whether array is empty.
double * mpsGetPr(const mpsArray *mlArr)
Access the real data in an array of doubles.
mpsSize mpsGetNzmax(const mpsArray *mlArr)
Determine the number of non-zero elements in a sparse array.
mpsArray * mpsCreateCharArray(mpsSize ndim, const mpsSize *dims)
Create a N-dimensional string array.
void mpsTerminate(void)
Perform global clean up of resources consumed by MATLAB Production Server client environment.
void mpsSetFieldByNumber(mpsArray *mlArr, mpsIndex index, int fieldnumber, mpsArray *pvalue)
Set the value held in the specified field number at the indexed element of an array.
mpsArray * mpsCreateDoubleScalar(double value)
Create a scalar double-precision floating-point array.
bool mpsLogical
Type for logical array.
Definition client.h:158
mpsClassID
Flag identifying class of array.
Definition client.h:276
@ mpsCHAR_CLASS
Identifies a string mpsArray.
Definition client.h:302
@ mpsINT8_CLASS
Identifies a numeric mpsArray whose data is stored as either char or byte.
Definition client.h:282
@ mpsINT64_CLASS
Identifies a numeric mpsArray whose data is stored as long long.
Definition client.h:294
@ mpsUINT8_CLASS
Identifies a numeric mpsArray whose data is stored as either unsigned char or byte.
Definition client.h:279
@ mpsDOUBLE_CLASS
Identifies a numeric mpsArray whose data is stored as double.
Definition client.h:298
@ mpsINT32_CLASS
Identifies a numeric mpsArray whose data is stored as int.
Definition client.h:290
@ mpsINT16_CLASS
Identifies a numeric mpsArray whose data is stored as short.
Definition client.h:286
@ mpsUINT16_CLASS
Identifies a numeric mpsArray whose data is stored as unsigned short.
Definition client.h:284
@ mpsSTRUCT_CLASS
Identifies a structure mpsArray.
Definition client.h:304
@ mpsCELL_CLASS
Identifies a cell mpsArray.
Definition client.h:306
@ mpsUINT64_CLASS
Identifies a numeric mpsArray whose data is stored as unsigned long long.
Definition client.h:292
@ mpsSINGLE_CLASS
Identifies a numeric mpsArray whose data is stored as float.
Definition client.h:296
@ mpsUINT32_CLASS
Identifies a numeric mpsArray whose data is stored as unsigned int.
Definition client.h:288
@ mpsLOGICAL_CLASS
Identifies a logical mpsArray.
Definition client.h:300
bool mpsIsUint16(const mpsArray *mlArr)
Determine whether mpsArray represents data as unsigned 16-bit integers.
mpsIndex * mpsGetIr(const mpsArray *mlArr)
Determine the starting address of the ir array in a sparse array.
mpsArray * mpsDuplicateArray(const mpsArray *mlArr)
Make a deep copy of input mpsArray.
bool mpsIsComplex(const mpsArray *mlArr)
Determine whether mpsArray contains an imaginary part.
void mpsRemoveField(mpsArray *mlArr, int fieldnumber)
Delete a field from an array of struct.
const char * mpsGetClassName(const mpsArray *mlArr)
Determine the class of an array.
double * mpsGetPi(const mpsArray *mlArr)
Access the imaginary data in an array of doubles.
mpsIndex mpsCalcSingleSubscript(const mpsArray *mlArr, mpsSize nsubs, mpsIndex *subs)
Determine how many elements there are between the beginning of an array and a given element.
bool mpsIsNumeric(const mpsArray *mlArr)
Determine whether mpsArray contains numeric data.
size_t mpsGetN(const mpsArray *mlArr)
Determine the number of columns in an array.
bool mpsIsLogical(const mpsArray *mlArr)
Determine whether mpsArray represents data as mpsLogical.
bool mpsIsCell(const mpsArray *mlArr)
Determine whether input is cell array.
void mpsSetN(mpsArray *mlArr, mpsSize n)
Set the number of columns in an array.
mpsArray * mpsCreateStructArray(mpsSize ndim, const mpsSize *dims, int nfields, const char **fieldnames)
Create a N-dimensional struct array.
mpsStatus
Error status codes for all methods which are part of the MATLAB Production Server client API.
Definition client.h:257
@ MPS_OK
Successful invocation of a method.
Definition client.h:260
@ MPS_FAILURE
Failure.
Definition client.h:263
uint64_t uint64
Definition client.h:44
mpsClientRuntime * mpsInitialize(void)
Set up the programming environment for MATLAB Production Server client based on version 1....
void mpsDestroyArray(mpsArray *mlArr)
Deallocate the memory occupied by an array.
CHAR16_T mpsChar
Definition client.h:141
bool mpsIsInt8(const mpsArray *mlArr)
Determine whether mpsArray represents data as signed 8-bit integers.
bool mpsIsInt64(const mpsArray *mlArr)
Determine whether mpsArray represents data as signed 64-bit integers.
mpsArray * mpsGetFieldByNumber(const mpsArray *mlArr, mpsIndex index, int fieldnumber)
Access the value held in the specified field number at the indexed element of an array.
char * mpsArrayToString(const mpsArray *mlArr)
Copy the character data of a string array into a C-style string.
void mpsSetCell(mpsArray *mlArr, mpsIndex index, mpsArray *value)
Set the contents of a cell array at a specified index.
void * mpsGetImagData(const mpsArray *mlArr)
Access the imaginary data in an array.
void * mpsGetData(const mpsArray *mlArr)
Access the real numeric data in an array.
const mpsSize * mpsGetDimensions(const mpsArray *mlArr)
Determine how many elements are in each dimension of an array.
bool mpsIsInt16(const mpsArray *mlArr)
Determine whether mpsArray represents data as signed 16-bit integers.
bool mpsIsLogicalScalar(const mpsArray *mlArr)
Determine whether MATLAB treats the scalar data in the mpsArray as logical or numerical.
mpsArray * mpsCreateStructMatrix(mpsSize m, mpsSize n, int nfields, const char **fieldnames)
Create a two-dimensional struct array.
void mpsSetField(mpsArray *mlArr, mpsIndex index, const char *fieldname, mpsArray *pvalue)
Set the value held in the specified element of the specified field of an array of struct.
mpsClientRuntime * mpsInitializeEx(int version)
Set up the programming environment for MATLAB Production Server client based on the version number pr...
const char * mpsGetFieldNameByNumber(const mpsArray *mlArr, int fieldnumber)
Determine the name of a field in an array of struct given the field number.
bool mpsIsChar(const mpsArray *mlArr)
Determine whether mpsArray represents a string array.
struct mpsClientConfig mpsClientConfig
Structure containing information configuring the connection between the client and a server instance.
Definition client.h:61
void mpsFree(void *data)
Deallocate heap space using the MATLAB memory management facility.
mpsArray * mpsCreateNumericArray(mpsSize ndim, const mpsSize *dims, mpsClassID classid, mpsComplexity complexFlag)
Create a two-dimensional numeric array.
mpsArray * mpsGetField(const mpsArray *mlArr, mpsIndex index, const char *fieldname)
Access the value held in the specified element of the specified field of an array of struct.
mpsArray * mpsCreateDoubleMatrix(mpsSize m, mpsSize n, mpsComplexity complexFlag)
Create a two-dimensional double-precision floating-point array.
struct mpsArray mpsArray
Fundamental type underlying MATLAB data.
Definition client.h:55
Entry in the MATLAB runtime stack.
Definition client.h:190
const char * function
Name of the MATLAB function which in most cases is same as the MATLAB file name.
Definition client.h:196
const char * file
Name of the MATLAB file that threw the MATLAB error.
Definition client.h:193
int line
Line number in the MATLAB file where the error occurred.
Definition client.h:199
MATLAB Production Server client API container.
Definition client.h:315
mpsStatus(* createConfig)(mpsClientConfig **config)
Initialize pointer to MATLAB Production Server client configuration instance with default values.
Definition client.h:327
void(* setCAFile)(mpsClientConfig *config, const char *caFile)
Set file Certificate Authority file in PEM format.
Definition client.h:443
mpsLogical(* getVerifyPeer)(const mpsClientConfig *config)
Get the peer verification flag value.
Definition client.h:467
void(* setVerifyPeer)(mpsClientConfig *config, mpsLogical verifyPeer)
Setting this flag to false will not peform the authentication of server certificate.
Definition client.h:464
void(* setClientCertFile)(mpsClientConfig *config, const char *certFile)
MPS_CLIENT_1_1 version provides support for request execution using HTTPS protocol for secure client-...
Definition client.h:425
mpsLogical(* getVerifyHost)(const mpsClientConfig *config)
Get the host verification flag value.
Definition client.h:459
void(* setPrivateKeyPasswd)(mpsClientConfig *config, const char *passwd)
Set password for private key file.
Definition client.h:437
mpsStatus(* feval)(mpsClientContext *context, const char *url, int nlhs, mpsArray *plhs[], int nrhs, const mpsArray *prhs[])
Invoke MATLAB function hosted by a server instance and available at a Url.
Definition client.h:411
void(* getLastErrorInfo)(mpsClientContext const *context, mpsErrorInfo *errorInfo)
Access the error thrown while invoking a MATLAB function from the client A MATLAB function invocation...
Definition client.h:383
void(* setPrivateKeyFile)(mpsClientConfig *config, const char *pkFile)
Set private key file in PEM format.
Definition client.h:431
mpsStatus(* createContext)(mpsClientContext **context, const mpsClientConfig *config)
Initialize the MATLAB Production Server client execution context.
Definition client.h:358
void(* setRevocationListFile)(mpsClientConfig *config, const char *crlFile)
Set the revocation list file.
Definition client.h:449
void(* destroyContext)(mpsClientContext *context)
Clean up the memory allocated for the client execution context.
Definition client.h:368
unsigned int(* getResponseSizeLimit)(const mpsClientConfig *config)
Get the responze size limit value, in bytes, for the client.
Definition client.h:344
unsigned long(* getResponseTimeOutSec)(const mpsClientConfig *config)
Get the timeout value, in seconds, for the client to receive response from the server.
Definition client.h:338
void(* destroyLastErrorInfo)(mpsErrorInfo *errorInfo)
Cleans up dynamic memory allocated while initializing mpsErrorInfo instance.
Definition client.h:387
void(* destroyConfig)(mpsClientConfig *config)
Clean up the memory allocated to the client configuration instance.
Definition client.h:332
void(* setVerifyHost)(mpsClientConfig *config, mpsLogical verifyHost)
Setting this flag to true will verify the hostname in thr url against the common name in the certific...
Definition client.h:456
void(* setResponseSizeLimit)(mpsClientConfig *config, unsigned int value)
Set the response size limit value, in bytes, for the client.
Definition client.h:341
void(* setResponseTimeOutSec)(mpsClientConfig *config, unsigned long value)
Set the timeout value, in seconds, for the client to receive response from the server.
Definition client.h:335
Details about an error not caused by non-200 HTTP errors or MATLAB execution errors.
Definition client.h:224
const char * genericErrorMsg
Error message corresponding to the generic error.
Definition client.h:227
Details about a non-200 HTTP response.
Definition client.h:177
const char * responseMessage
HTTP response message.
Definition client.h:183
unsigned int responseCode
HTTP response code.
Definition client.h:180
Details about a MATLAB execution error.
Definition client.h:206
size_t matlabStackDepth
Number of entries in the MATLAB stack.
Definition client.h:218
const char * message
Error message corresponding to the error thrown in MATLAB.
Definition client.h:209
const matlabStackFrame * matlabStack
MATLAB stack associated with the MATLAB error.
Definition client.h:215
const char * identifier
Unique error identifier corresponding to the MATLAB error.
Definition client.h:212
Error thrown when a MATLAB function is invoked by the MATLAB Production Server client context.
Definition client.h:234
union mpsErrorInfo::@0 details
All possible errors that can be thrown when a MATLAB function is invoked from the client.
mpsErrorInfoType type
Type of underlying error.
Definition client.h:237
mpsErrorInfoGeneric general
Error other than MATLAB execution error and non-200 HTTP response.
Definition client.h:251
char const * message
Message regarding the error.
Definition client.h:240
mpsErrorInfoHTTP http
Error caused by a non-200 HTTP response.
Definition client.h:245
mpsErrorInfoMATLAB matlab
Error thrown during execution of MATLAB code.
Definition client.h:248