ARSperl
view release on metacpan or search on metacpan
supportrev_generated.c view on Meta::CPAN
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARAuditInfoStruct: hash value is not a hash reference" );
return -1;
}
}
}else{
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, "rev_ARAuditInfoStruct: hv_fetch returned null");
return -2;
}
}else{
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, "rev_ARAuditInfoStruct: key doesn't exist");
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, k );
return -2;
}
}else{
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARAuditInfoStruct: first argument is not a hash");
return -1;
}
return 0;
}
#endif
int
rev_ARAutomationStruct( ARControlStruct *ctrl, HV *h, char *k, ARAutomationStruct *p ){
SV **val;
int i = 0;
if( !p ){
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARAutomationStruct: AR Object param is NULL" );
return -1;
}
if( SvTYPE((SV*) h) == SVt_PVHV ){
// printf( "ARAutomationStruct: k = <%s>\n", k );
if( hv_exists(h,k,strlen(k)) ){
val = hv_fetch( h, k, strlen(k), 0 );
if( val && *val ){
{
if( SvTYPE(SvRV(*val)) == SVt_PVHV ){
int i = 0, num = 0;
HV *h = (HV* ) SvRV((SV*) *val);
char k[256];
k[255] = '\0';
{
SV **val;
strncpy( k, "isVisible", 255 );
val = hv_fetch( h, "isVisible", 9, 0 );
if( val && *val && SvOK(*val) ){
{
int flag = 0;
if( !strcmp(SvPV_nolen(*val),"true") ){
p->isVisible = TRUE;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"false") ){
p->isVisible = FALSE;
flag = 1;
}
if( flag == 0 ){
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARAutomationStruct: invalid key value" );
ARError_add( AR_RETURN_ERROR, AP_ERR_CONTINUE, SvPV_nolen(*val) );
}
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"isVisible\"" );
return -1;
}
}
{
SV **val;
strncpy( k, "autoServerName", 255 );
val = hv_fetch( h, "autoServerName", 14, 0 );
if( val && *val && SvOK(*val) ){
{
p->autoServerName = strdup( SvPV_nolen(*val) );
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"autoServerName\"" );
return -1;
}
}
{
SV **val;
strncpy( k, "action", 255 );
val = hv_fetch( h, "action", 6, 0 );
if( val && *val && SvOK(*val) ){
{
p->action = strdup( SvPV_nolen(*val) );
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"action\"" );
return -1;
}
}
{
SV **val;
strncpy( k, "methodList", 255 );
val = hv_fetch( h, "methodList", 10, 0 );
if( val && *val && SvOK(*val) ){
{
rev_ARCOMMethodList( ctrl, h, k, &(p->methodList) );
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"methodList\"" );
return -1;
}
}
{
SV **val;
strncpy( k, "clsId", 255 );
val = hv_fetch( h, "clsId", 5, 0 );
supportrev_generated.c view on Meta::CPAN
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARCallGuideStruct: hash value is not a hash reference" );
return -1;
}
}
}else{
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, "rev_ARCallGuideStruct: hv_fetch returned null");
return -2;
}
}else{
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, "rev_ARCallGuideStruct: key doesn't exist");
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, k );
return -2;
}
}else{
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARCallGuideStruct: first argument is not a hash");
return -1;
}
return 0;
}
int
rev_ARCharLimitsStruct( ARControlStruct *ctrl, HV *h, char *k, ARCharLimitsStruct *p ){
SV **val;
int i = 0;
if( !p ){
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARCharLimitsStruct: AR Object param is NULL" );
return -1;
}
if( SvTYPE((SV*) h) == SVt_PVHV ){
// printf( "ARCharLimitsStruct: k = <%s>\n", k );
if( hv_exists(h,k,strlen(k)) ){
val = hv_fetch( h, k, strlen(k), 0 );
if( val && *val ){
{
if( SvTYPE(SvRV(*val)) == SVt_PVHV ){
int i = 0, num = 0;
HV *h = (HV* ) SvRV((SV*) *val);
char k[256];
k[255] = '\0';
#if AR_CURRENT_API_VERSION >= 14
{
SV **val;
strncpy( k, "lengthUnits", 255 );
val = hv_fetch( h, "lengthUnits", 11, 0 );
if( val && *val && SvOK(*val) ){
{
int flag = 0;
if( !strcmp(SvPV_nolen(*val),"char") ){
p->lengthUnits = AR_LENGTH_UNIT_CHAR;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"byte") ){
p->lengthUnits = AR_LENGTH_UNIT_BYTE;
flag = 1;
}
if( flag == 0 ){
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARCharLimitsStruct: invalid key value" );
ARError_add( AR_RETURN_ERROR, AP_ERR_CONTINUE, SvPV_nolen(*val) );
}
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"lengthUnits\"" );
return -1;
}
}
#endif
{
SV **val;
strncpy( k, "pattern", 255 );
val = hv_fetch( h, "pattern", 7, 0 );
if( val && *val && SvOK(*val) ){
{
p->pattern = strdup( SvPV_nolen(*val) );
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"pattern\"" );
return -1;
}
}
{
SV **val;
strncpy( k, "charMenu", 255 );
val = hv_fetch( h, "charMenu", 8, 0 );
if( val && *val && SvOK(*val) ){
{
strncpy( p->charMenu, SvPV_nolen(*val), sizeof(p->charMenu) );
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"charMenu\"" );
return -1;
}
}
{
SV **val;
strncpy( k, "maxLength", 255 );
val = hv_fetch( h, "maxLength", 9, 0 );
if( val && *val && SvOK(*val) ){
{
p->maxLength = SvIV(*val);
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"maxLength\"" );
return -1;
}
}
{
SV **val;
strncpy( k, "match", 255 );
val = hv_fetch( h, "match", 5, 0 );
if( val && *val && SvOK(*val) ){
{
int flag = 0;
if( !strcmp(SvPV_nolen(*val),"leading") ){
p->qbeMatchOperation = AR_QBE_MATCH_LEADING;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"equal") ){
p->qbeMatchOperation = AR_QBE_MATCH_EQUAL;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"anywhere") ){
p->qbeMatchOperation = AR_QBE_MATCH_ANYWHERE;
flag = 1;
}
if( flag == 0 ){
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARCharLimitsStruct: invalid key value" );
ARError_add( AR_RETURN_ERROR, AP_ERR_CONTINUE, SvPV_nolen(*val) );
}
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"match\"" );
return -1;
}
}
#if AR_CURRENT_API_VERSION >= 14
{
SV **val;
strncpy( k, "storageOptionForCLOB", 255 );
val = hv_fetch( h, "storageOptionForCLOB", 20, 0 );
if( val && *val && SvOK(*val) ){
{
int flag = 0;
if( !strcmp(SvPV_nolen(*val),"inrow") ){
p->storageOptionForCLOB = AR_STORE_OPT_INROW;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"default") ){
p->storageOptionForCLOB = AR_STORE_OPT_DEF;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"outrow") ){
p->storageOptionForCLOB = AR_STORE_OPT_OUTROW;
flag = 1;
}
if( flag == 0 ){
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARCharLimitsStruct: invalid key value" );
ARError_add( AR_RETURN_ERROR, AP_ERR_CONTINUE, SvPV_nolen(*val) );
}
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"storageOptionForCLOB\"" );
return -1;
}
}
#endif
{
SV **val;
strncpy( k, "fullTextOptions", 255 );
val = hv_fetch( h, "fullTextOptions", 15, 0 );
if( val && *val && SvOK(*val) ){
{
int flag = 0;
if( !strcmp(SvPV_nolen(*val),"indexed") ){
p->fullTextOptions = AR_FULLTEXT_OPTIONS_INDEXED;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"none") ){
p->fullTextOptions = AR_FULLTEXT_OPTIONS_NONE;
flag = 1;
}
if( flag == 0 ){
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARCharLimitsStruct: invalid key value" );
ARError_add( AR_RETURN_ERROR, AP_ERR_CONTINUE, SvPV_nolen(*val) );
}
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"fullTextOptions\"" );
return -1;
}
}
{
SV **val;
strncpy( k, "menuStyle", 255 );
val = hv_fetch( h, "menuStyle", 9, 0 );
if( val && *val && SvOK(*val) ){
{
int flag = 0;
if( !strcmp(SvPV_nolen(*val),"append") ){
p->menuStyle = AR_MENU_APPEND;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"overwrite") ){
p->menuStyle = AR_MENU_OVERWRITE;
flag = 1;
}
if( flag == 0 ){
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARCharLimitsStruct: invalid key value" );
ARError_add( AR_RETURN_ERROR, AP_ERR_CONTINUE, SvPV_nolen(*val) );
}
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"menuStyle\"" );
return -1;
}
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARCharLimitsStruct: hash value is not a hash reference" );
return -1;
}
}
}else{
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, "rev_ARCharLimitsStruct: hv_fetch returned null");
return -2;
}
}else{
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, "rev_ARCharLimitsStruct: key doesn't exist");
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, k );
return -2;
}
}else{
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARCharLimitsStruct: first argument is not a hash");
return -1;
}
return 0;
}
int
rev_ARCharMenuDDFieldStruct( ARControlStruct *ctrl, HV *h, char *k, ARCharMenuDDFieldStruct *p ){
SV **val;
int i = 0;
if( !p ){
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARCharMenuDDFieldStruct: AR Object param is NULL" );
return -1;
}
if( SvTYPE((SV*) h) == SVt_PVHV ){
// printf( "ARCharMenuDDFieldStruct: k = <%s>\n", k );
if( hv_exists(h,k,strlen(k)) ){
val = hv_fetch( h, k, strlen(k), 0 );
if( val && *val ){
{
if( SvTYPE(SvRV(*val)) == SVt_PVHV ){
int i = 0, num = 0;
HV *h = (HV* ) SvRV((SV*) *val);
supportrev_generated.c view on Meta::CPAN
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARCharMenuDDFieldStruct: hash value is not a hash reference" );
return -1;
}
}
}else{
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, "rev_ARCharMenuDDFieldStruct: hv_fetch returned null");
return -2;
}
}else{
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, "rev_ARCharMenuDDFieldStruct: key doesn't exist");
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, k );
return -2;
}
}else{
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARCharMenuDDFieldStruct: first argument is not a hash");
return -1;
}
return 0;
}
int
rev_ARCharMenuDDFormStruct( ARControlStruct *ctrl, HV *h, char *k, ARCharMenuDDFormStruct *p ){
SV **val;
int i = 0;
if( !p ){
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARCharMenuDDFormStruct: AR Object param is NULL" );
return -1;
}
if( SvTYPE((SV*) h) == SVt_PVHV ){
// printf( "ARCharMenuDDFormStruct: k = <%s>\n", k );
if( hv_exists(h,k,strlen(k)) ){
val = hv_fetch( h, k, strlen(k), 0 );
if( val && *val ){
{
if( SvTYPE(SvRV(*val)) == SVt_PVHV ){
int i = 0, num = 0;
HV *h = (HV* ) SvRV((SV*) *val);
char k[256];
k[255] = '\0';
{
SV **val;
strncpy( k, "includeHidden", 255 );
val = hv_fetch( h, "includeHidden", 13, 0 );
if( val && *val && SvOK(*val) ){
{
int flag = 0;
if( !strcmp(SvPV_nolen(*val),"true") ){
p->includeHidden = TRUE;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"false") ){
p->includeHidden = FALSE;
flag = 1;
}
if( flag == 0 ){
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARCharMenuDDFormStruct: invalid key value" );
ARError_add( AR_RETURN_ERROR, AP_ERR_CONTINUE, SvPV_nolen(*val) );
}
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"includeHidden\"" );
return -1;
}
}
{
SV **val;
strncpy( k, "schemaType", 255 );
val = hv_fetch( h, "schemaType", 10, 0 );
if( val && *val && SvOK(*val) ){
{
p->schemaType = SvIV(*val);
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"schemaType\"" );
return -1;
}
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARCharMenuDDFormStruct: hash value is not a hash reference" );
return -1;
}
}
}else{
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, "rev_ARCharMenuDDFormStruct: hv_fetch returned null");
return -2;
}
}else{
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, "rev_ARCharMenuDDFormStruct: key doesn't exist");
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, k );
return -2;
}
}else{
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARCharMenuDDFormStruct: first argument is not a hash");
return -1;
}
return 0;
}
int
rev_ARCharMenuDDStruct( ARControlStruct *ctrl, HV *h, char *k, ARCharMenuDDStruct *p ){
SV **val;
int i = 0;
if( !p ){
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARCharMenuDDStruct: AR Object param is NULL" );
supportrev_generated.c view on Meta::CPAN
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARCharMenuSSStruct: hash value is not a hash reference" );
return -1;
}
}
}else{
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, "rev_ARCharMenuSSStruct: hv_fetch returned null");
return -2;
}
}else{
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, "rev_ARCharMenuSSStruct: key doesn't exist");
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, k );
return -2;
}
}else{
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARCharMenuSSStruct: first argument is not a hash");
return -1;
}
return 0;
}
int
rev_ARCloseWndStruct( ARControlStruct *ctrl, HV *h, char *k, ARCloseWndStruct *p ){
SV **val;
int i = 0;
if( !p ){
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARCloseWndStruct: AR Object param is NULL" );
return -1;
}
if( SvTYPE((SV*) h) == SVt_PVHV ){
// printf( "ARCloseWndStruct: k = <%s>\n", k );
if( hv_exists(h,k,strlen(k)) ){
val = hv_fetch( h, k, strlen(k), 0 );
if( val && *val ){
{
if( SvTYPE(SvRV(*val)) == SVt_PVHV ){
int i = 0, num = 0;
HV *h = (HV* ) SvRV((SV*) *val);
char k[256];
k[255] = '\0';
{
SV **val;
strncpy( k, "closeAll", 255 );
val = hv_fetch( h, "closeAll", 8, 0 );
if( val && *val && SvOK(*val) ){
{
int flag = 0;
if( !strcmp(SvPV_nolen(*val),"true") ){
p->closeAll = TRUE;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"false") ){
p->closeAll = FALSE;
flag = 1;
}
if( flag == 0 ){
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARCloseWndStruct: invalid key value" );
ARError_add( AR_RETURN_ERROR, AP_ERR_CONTINUE, SvPV_nolen(*val) );
}
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"closeAll\"" );
return -1;
}
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARCloseWndStruct: hash value is not a hash reference" );
return -1;
}
}
}else{
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, "rev_ARCloseWndStruct: hv_fetch returned null");
return -2;
}
}else{
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, "rev_ARCloseWndStruct: key doesn't exist");
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, k );
return -2;
}
}else{
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARCloseWndStruct: first argument is not a hash");
return -1;
}
return 0;
}
int
rev_ARColumnLimitsStruct( ARControlStruct *ctrl, HV *h, char *k, ARColumnLimitsStruct *p ){
SV **val;
int i = 0;
if( !p ){
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARColumnLimitsStruct: AR Object param is NULL" );
return -1;
}
if( SvTYPE((SV*) h) == SVt_PVHV ){
// printf( "ARColumnLimitsStruct: k = <%s>\n", k );
if( hv_exists(h,k,strlen(k)) ){
val = hv_fetch( h, k, strlen(k), 0 );
if( val && *val ){
{
if( SvTYPE(SvRV(*val)) == SVt_PVHV ){
int i = 0, num = 0;
HV *h = (HV* ) SvRV((SV*) *val);
supportrev_generated.c view on Meta::CPAN
return -2;
}
}else{
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARCompoundSchemaList: first argument is not a hash");
return -1;
}
return 0;
}
int
rev_ARContainerOwnerObj( ARControlStruct *ctrl, HV *h, char *k, ARContainerOwnerObj *p ){
SV **val;
int i = 0;
if( !p ){
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARContainerOwnerObj: AR Object param is NULL" );
return -1;
}
if( SvTYPE((SV*) h) == SVt_PVHV ){
// printf( "ARContainerOwnerObj: k = <%s>\n", k );
if( hv_exists(h,k,strlen(k)) ){
val = hv_fetch( h, k, strlen(k), 0 );
if( val && *val ){
{
if( SvTYPE(SvRV(*val)) == SVt_PVHV ){
int i = 0, num = 0;
HV *h = (HV* ) SvRV((SV*) *val);
char k[256];
k[255] = '\0';
{
SV **val;
strncpy( k, "ownerName", 255 );
val = hv_fetch( h, "ownerName", 9, 0 );
if( val && *val && SvOK(*val) ){
{
strncpy( p->ownerName, SvPV_nolen(*val), sizeof(p->ownerName) );
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"ownerName\"" );
return -1;
}
}
{
SV **val;
strncpy( k, "type", 255 );
val = hv_fetch( h, "type", 4, 0 );
if( val && *val && SvOK(*val) ){
{
int flag = 0;
if( !strcmp(SvPV_nolen(*val),"schema") ){
p->type = ARCONOWNER_SCHEMA;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"all") ){
p->type = ARCONOWNER_ALL;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"none") ){
p->type = ARCONOWNER_NONE;
flag = 1;
}
if( flag == 0 ){
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARContainerOwnerObj: invalid key value" );
ARError_add( AR_RETURN_ERROR, AP_ERR_CONTINUE, SvPV_nolen(*val) );
}
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"type\"" );
return -1;
}
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARContainerOwnerObj: hash value is not a hash reference" );
return -1;
}
}
}else{
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, "rev_ARContainerOwnerObj: hv_fetch returned null");
return -2;
}
}else{
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, "rev_ARContainerOwnerObj: key doesn't exist");
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, k );
return -2;
}
}else{
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARContainerOwnerObj: first argument is not a hash");
return -1;
}
return 0;
}
int
rev_ARContainerOwnerObjList( ARControlStruct *ctrl, HV *h, char *k, ARContainerOwnerObjList *p ){
SV **val;
int i = 0;
if( !p ){
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARContainerOwnerObjList: AR Object param is NULL" );
return -1;
}
if( SvTYPE((SV*) h) == SVt_PVHV ){
// printf( "ARContainerOwnerObjList: k = <%s>\n", k );
if( hv_exists(h,k,strlen(k)) ){
val = hv_fetch( h, k, strlen(k), 0 );
if( val && *val ){
{
{
if( SvTYPE(SvRV(*val)) == SVt_PVAV ){
int i = 0, num = 0;
AV *ar = (AV*) SvRV((SV*) *val);
supportrev_generated.c view on Meta::CPAN
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARDecimalLimitsStruct: hash value is not a hash reference" );
return -1;
}
}
}else{
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, "rev_ARDecimalLimitsStruct: hv_fetch returned null");
return -2;
}
}else{
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, "rev_ARDecimalLimitsStruct: key doesn't exist");
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, k );
return -2;
}
}else{
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARDecimalLimitsStruct: first argument is not a hash");
return -1;
}
return 0;
}
int
rev_ARDiaryLimitsStruct( ARControlStruct *ctrl, HV *h, char *k, ARDiaryLimitsStruct *p ){
SV **val;
int i = 0;
if( !p ){
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARDiaryLimitsStruct: AR Object param is NULL" );
return -1;
}
if( SvTYPE((SV*) h) == SVt_PVHV ){
// printf( "ARDiaryLimitsStruct: k = <%s>\n", k );
if( hv_exists(h,k,strlen(k)) ){
val = hv_fetch( h, k, strlen(k), 0 );
if( val && *val ){
{
if( SvTYPE(SvRV(*val)) == SVt_PVHV ){
int i = 0, num = 0;
HV *h = (HV* ) SvRV((SV*) *val);
char k[256];
k[255] = '\0';
{
SV **val;
strncpy( k, "fullTextOptions", 255 );
val = hv_fetch( h, "fullTextOptions", 15, 0 );
if( val && *val && SvOK(*val) ){
{
int flag = 0;
if( !strcmp(SvPV_nolen(*val),"indexed") ){
p->fullTextOptions = AR_FULLTEXT_OPTIONS_INDEXED;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"none") ){
p->fullTextOptions = AR_FULLTEXT_OPTIONS_NONE;
flag = 1;
}
if( flag == 0 ){
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARDiaryLimitsStruct: invalid key value" );
ARError_add( AR_RETURN_ERROR, AP_ERR_CONTINUE, SvPV_nolen(*val) );
}
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"fullTextOptions\"" );
return -1;
}
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARDiaryLimitsStruct: hash value is not a hash reference" );
return -1;
}
}
}else{
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, "rev_ARDiaryLimitsStruct: hv_fetch returned null");
return -2;
}
}else{
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, "rev_ARDiaryLimitsStruct: key doesn't exist");
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, k );
return -2;
}
}else{
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARDiaryLimitsStruct: first argument is not a hash");
return -1;
}
return 0;
}
#if AR_CURRENT_API_VERSION >= 8
int
rev_ARDisplayLimits( ARControlStruct *ctrl, HV *h, char *k, ARDisplayLimits *p ){
SV **val;
int i = 0;
if( !p ){
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARDisplayLimits: AR Object param is NULL" );
return -1;
}
if( SvTYPE((SV*) h) == SVt_PVHV ){
// printf( "ARDisplayLimits: k = <%s>\n", k );
if( hv_exists(h,k,strlen(k)) ){
val = hv_fetch( h, k, strlen(k), 0 );
if( val && *val ){
{
if( SvTYPE(SvRV(*val)) == SVt_PVHV ){
int i = 0, num = 0;
HV *h = (HV* ) SvRV((SV*) *val);
char k[256];
k[255] = '\0';
#if AR_CURRENT_API_VERSION >= 14
{
SV **val;
strncpy( k, "lengthUnits", 255 );
val = hv_fetch( h, "lengthUnits", 11, 0 );
if( val && *val && SvOK(*val) ){
{
int flag = 0;
if( !strcmp(SvPV_nolen(*val),"char") ){
p->lengthUnits = AR_LENGTH_UNIT_CHAR;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"byte") ){
p->lengthUnits = AR_LENGTH_UNIT_BYTE;
flag = 1;
}
if( flag == 0 ){
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARDisplayLimits: invalid key value" );
ARError_add( AR_RETURN_ERROR, AP_ERR_CONTINUE, SvPV_nolen(*val) );
}
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"lengthUnits\"" );
return -1;
}
}
#endif
{
SV **val;
strncpy( k, "maxLength", 255 );
val = hv_fetch( h, "maxLength", 9, 0 );
if( val && *val && SvOK(*val) ){
{
p->maxLength = SvIV(*val);
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"maxLength\"" );
return -1;
}
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARDisplayLimits: hash value is not a hash reference" );
return -1;
}
}
}else{
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, "rev_ARDisplayLimits: hv_fetch returned null");
return -2;
}
}else{
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, "rev_ARDisplayLimits: key doesn't exist");
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, k );
return -2;
}
}else{
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARDisplayLimits: first argument is not a hash");
return -1;
}
return 0;
}
#endif
int
rev_AREntryIdList( ARControlStruct *ctrl, HV *h, char *k, AREntryIdList *p ){
SV **val;
int i = 0;
if( !p ){
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_AREntryIdList: AR Object param is NULL" );
supportrev_generated.c view on Meta::CPAN
default:
sprintf( errText, "rev_AREscalationTmStruct: invalid switch value %d", p->escalationTmType );
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, errText );
}
}
}
}else{
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, "rev_AREscalationTmStruct: hv_fetch returned null");
return -2;
}
}else{
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, "rev_AREscalationTmStruct: key doesn't exist");
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, k );
return -2;
}
}else{
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_AREscalationTmStruct: first argument is not a hash");
return -1;
}
return 0;
}
int
rev_ARExitGuideStruct( ARControlStruct *ctrl, HV *h, char *k, ARExitGuideStruct *p ){
SV **val;
int i = 0;
if( !p ){
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARExitGuideStruct: AR Object param is NULL" );
return -1;
}
if( SvTYPE((SV*) h) == SVt_PVHV ){
// printf( "ARExitGuideStruct: k = <%s>\n", k );
if( hv_exists(h,k,strlen(k)) ){
val = hv_fetch( h, k, strlen(k), 0 );
if( val && *val ){
{
if( SvTYPE(SvRV(*val)) == SVt_PVHV ){
int i = 0, num = 0;
HV *h = (HV* ) SvRV((SV*) *val);
char k[256];
k[255] = '\0';
{
SV **val;
strncpy( k, "closeAll", 255 );
val = hv_fetch( h, "closeAll", 8, 0 );
if( val && *val && SvOK(*val) ){
{
int flag = 0;
if( !strcmp(SvPV_nolen(*val),"true") ){
p->closeAll = TRUE;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"false") ){
p->closeAll = FALSE;
flag = 1;
}
if( flag == 0 ){
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARExitGuideStruct: invalid key value" );
ARError_add( AR_RETURN_ERROR, AP_ERR_CONTINUE, SvPV_nolen(*val) );
}
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"closeAll\"" );
return -1;
}
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARExitGuideStruct: hash value is not a hash reference" );
return -1;
}
}
}else{
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, "rev_ARExitGuideStruct: hv_fetch returned null");
return -2;
}
}else{
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, "rev_ARExitGuideStruct: key doesn't exist");
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, k );
return -2;
}
}else{
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARExitGuideStruct: first argument is not a hash");
return -1;
}
return 0;
}
int
rev_ARFieldLimitList( ARControlStruct *ctrl, HV *h, char *k, ARFieldLimitList *p ){
SV **val;
int i = 0;
if( !p ){
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARFieldLimitList: AR Object param is NULL" );
return -1;
}
if( SvTYPE((SV*) h) == SVt_PVHV ){
// printf( "ARFieldLimitList: k = <%s>\n", k );
if( hv_exists(h,k,strlen(k)) ){
val = hv_fetch( h, k, strlen(k), 0 );
if( val && *val ){
{
{
if( SvTYPE(SvRV(*val)) == SVt_PVAV ){
int i = 0, num = 0;
AV *ar = (AV*) SvRV((SV*) *val);
supportrev_generated.c view on Meta::CPAN
SV **val;
int i = 0;
if( !p ){
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARMultiSchemaRelOpStruct: AR Object param is NULL" );
return -1;
}
if( SvTYPE((SV*) h) == SVt_PVHV ){
// printf( "ARMultiSchemaRelOpStruct: k = <%s>\n", k );
if( hv_exists(h,k,strlen(k)) ){
val = hv_fetch( h, k, strlen(k), 0 );
if( val && *val ){
{
if( SvTYPE(SvRV(*val)) == SVt_PVHV ){
int i = 0, num = 0;
HV *h = (HV* ) SvRV((SV*) *val);
char k[256];
k[255] = '\0';
{
SV **val;
strncpy( k, "left", 255 );
val = hv_fetch( h, "left", 4, 0 );
if( val && *val && SvOK(*val) ){
{
rev_ARMultiSchemaFieldValueOrArithStruct( ctrl, h, k, &(p->operandLeft) );
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"left\"" );
return -1;
}
}
{
SV **val;
strncpy( k, "right", 255 );
val = hv_fetch( h, "right", 5, 0 );
if( val && *val && SvOK(*val) ){
{
rev_ARMultiSchemaFieldValueOrArithStruct( ctrl, h, k, &(p->operandRight) );
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"right\"" );
return -1;
}
}
{
SV **val;
strncpy( k, "oper", 255 );
val = hv_fetch( h, "oper", 4, 0 );
if( val && *val && SvOK(*val) ){
{
int flag = 0;
if( !strcmp(SvPV_nolen(*val),">") ){
p->operation = AR_REL_OP_GREATER;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"in") ){
p->operation = AR_REL_OP_IN;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),">=") ){
p->operation = AR_REL_OP_GREATER_EQUAL;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"==") ){
p->operation = AR_REL_OP_EQUAL;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"like") ){
p->operation = AR_REL_OP_LIKE;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"!=") ){
p->operation = AR_REL_OP_NOT_EQUAL;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"<=") ){
p->operation = AR_REL_OP_LESS_EQUAL;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"<") ){
p->operation = AR_REL_OP_LESS;
flag = 1;
}
if( flag == 0 ){
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARMultiSchemaRelOpStruct: invalid key value" );
ARError_add( AR_RETURN_ERROR, AP_ERR_CONTINUE, SvPV_nolen(*val) );
}
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"oper\"" );
return -1;
}
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARMultiSchemaRelOpStruct: hash value is not a hash reference" );
return -1;
}
}
}else{
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, "rev_ARMultiSchemaRelOpStruct: hv_fetch returned null");
return -2;
}
}else{
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, "rev_ARMultiSchemaRelOpStruct: key doesn't exist");
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, k );
return -2;
}
}else{
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARMultiSchemaRelOpStruct: first argument is not a hash");
return -1;
}
return 0;
}
#endif
#if AR_CURRENT_API_VERSION >= 14
int
rev_ARMultiSchemaSortList( ARControlStruct *ctrl, HV *h, char *k, ARMultiSchemaSortList *p ){
SV **val;
int i = 0;
if( !p ){
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARMultiSchemaSortList: AR Object param is NULL" );
return -1;
}
if( SvTYPE((SV*) h) == SVt_PVHV ){
// printf( "ARMultiSchemaSortList: k = <%s>\n", k );
if( hv_exists(h,k,strlen(k)) ){
val = hv_fetch( h, k, strlen(k), 0 );
if( val && *val ){
{
{
if( SvTYPE(SvRV(*val)) == SVt_PVAV ){
int i = 0, num = 0;
AV *ar = (AV*) SvRV((SV*) *val);
supportrev_generated.c view on Meta::CPAN
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARNameList: hash value is not an array reference" );
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, k );
return -1;
}
}
}
}else{
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, "rev_ARNameList: hv_fetch returned null");
return -2;
}
}else{
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, "rev_ARNameList: key doesn't exist");
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, k );
return -2;
}
}else{
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARNameList: first argument is not a hash");
return -1;
}
return 0;
}
int
rev_AROpenDlgStruct( ARControlStruct *ctrl, HV *h, char *k, AROpenDlgStruct *p ){
SV **val;
int i = 0;
if( !p ){
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_AROpenDlgStruct: AR Object param is NULL" );
return -1;
}
if( SvTYPE((SV*) h) == SVt_PVHV ){
// printf( "AROpenDlgStruct: k = <%s>\n", k );
if( hv_exists(h,k,strlen(k)) ){
val = hv_fetch( h, k, strlen(k), 0 );
if( val && *val ){
{
if( SvTYPE(SvRV(*val)) == SVt_PVHV ){
int i = 0, num = 0;
HV *h = (HV* ) SvRV((SV*) *val);
char k[256];
k[255] = '\0';
#if AR_CURRENT_API_VERSION <= 9
{
SV **val;
strncpy( k, "windowMode", 255 );
val = hv_fetch( h, "windowMode", 10, 0 );
if( val && *val && SvOK(*val) ){
{
int flag = 0;
if( !strcmp(SvPV_nolen(*val),"open_search") ){
p->windowMode = AR_ACTIVE_LINK_ACTION_OPEN_SEARCH;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"open_dlg") ){
p->windowMode = AR_ACTIVE_LINK_ACTION_OPEN_DLG;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"open_dsply_detail") ){
p->windowMode = AR_ACTIVE_LINK_ACTION_OPEN_DSPLY_DETAIL;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"open_report") ){
p->windowMode = AR_ACTIVE_LINK_ACTION_OPEN_REPORT;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"open_modify_lst") ){
p->windowMode = AR_ACTIVE_LINK_ACTION_OPEN_MODIFY_LST;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"open_modify_detail") ){
p->windowMode = AR_ACTIVE_LINK_ACTION_OPEN_MODIFY_DETAIL;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"open_modify_split") ){
p->windowMode = AR_ACTIVE_LINK_ACTION_OPEN_MODIFY_SPLIT;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"open_dsply_split") ){
p->windowMode = AR_ACTIVE_LINK_ACTION_OPEN_DSPLY_SPLIT;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"open_dsply_lst") ){
p->windowMode = AR_ACTIVE_LINK_ACTION_OPEN_DSPLY_LST;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"open_submit") ){
p->windowMode = AR_ACTIVE_LINK_ACTION_OPEN_SUBMIT;
flag = 1;
}
if( flag == 0 ){
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_AROpenDlgStruct: invalid key value" );
ARError_add( AR_RETURN_ERROR, AP_ERR_CONTINUE, SvPV_nolen(*val) );
}
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"windowMode\"" );
return -1;
}
}
#endif
{
SV **val;
strncpy( k, "vuiLabel", 255 );
val = hv_fetch( h, "vuiLabel", 8, 0 );
if( val && *val && SvOK(*val) ){
{
strncpy( p->vuiLabel, SvPV_nolen(*val), sizeof(p->vuiLabel) );
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"vuiLabel\"" );
return -1;
}
}
{
SV **val;
strncpy( k, "reportString", 255 );
val = hv_fetch( h, "reportString", 12, 0 );
if( val && *val && SvOK(*val) ){
{
p->reportString = strdup( SvPV_nolen(*val) );
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"reportString\"" );
return -1;
}
}
{
SV **val;
strncpy( k, "suppressEmptyList", 255 );
val = hv_fetch( h, "suppressEmptyList", 17, 0 );
if( val && *val && SvOK(*val) ){
{
int flag = 0;
if( !strcmp(SvPV_nolen(*val),"true") ){
p->suppressEmptyLst = TRUE;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"false") ){
p->suppressEmptyLst = FALSE;
flag = 1;
}
if( flag == 0 ){
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_AROpenDlgStruct: invalid key value" );
ARError_add( AR_RETURN_ERROR, AP_ERR_CONTINUE, SvPV_nolen(*val) );
}
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"suppressEmptyList\"" );
return -1;
}
}
{
SV **val;
strncpy( k, "pollinginterval", 255 );
val = hv_fetch( h, "pollinginterval", 15, 0 );
if( val && *val && SvOK(*val) ){
{
p->pollinginterval = SvIV(*val);
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"pollinginterval\"" );
return -1;
}
}
{
SV **val;
strncpy( k, "targetLocation", 255 );
val = hv_fetch( h, "targetLocation", 14, 0 );
if( val && *val && SvOK(*val) ){
{
p->targetLocation = strdup( SvPV_nolen(*val) );
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"targetLocation\"" );
return -1;
}
}
#if AR_CURRENT_API_VERSION >= 10
{
SV **val;
strncpy( k, "windowMode", 255 );
val = hv_fetch( h, "windowMode", 10, 0 );
if( val && *val && SvOK(*val) ){
{
int flag = 0;
if( !strcmp(SvPV_nolen(*val),"open_modify") ){
p->windowMode = AR_ACTIVE_LINK_ACTION_OPEN_MODIFY;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"open_dsply") ){
p->windowMode = AR_ACTIVE_LINK_ACTION_OPEN_DSPLY;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"open_search") ){
p->windowMode = AR_ACTIVE_LINK_ACTION_OPEN_SEARCH;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"open_dlg") ){
p->windowMode = AR_ACTIVE_LINK_ACTION_OPEN_DLG;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"open_dsply_detail") ){
p->windowMode = AR_ACTIVE_LINK_ACTION_OPEN_DSPLY_DETAIL;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"open_report") ){
p->windowMode = AR_ACTIVE_LINK_ACTION_OPEN_REPORT;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"open_modify_lst") ){
p->windowMode = AR_ACTIVE_LINK_ACTION_OPEN_MODIFY_LST;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"open_modify_detail") ){
p->windowMode = AR_ACTIVE_LINK_ACTION_OPEN_MODIFY_DETAIL;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"open_modify_split") ){
p->windowMode = AR_ACTIVE_LINK_ACTION_OPEN_MODIFY_SPLIT;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"open_dsply_split") ){
p->windowMode = AR_ACTIVE_LINK_ACTION_OPEN_DSPLY_SPLIT;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"open_dsply_lst") ){
p->windowMode = AR_ACTIVE_LINK_ACTION_OPEN_DSPLY_LST;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"open_submit") ){
p->windowMode = AR_ACTIVE_LINK_ACTION_OPEN_SUBMIT;
flag = 1;
}
if( flag == 0 ){
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_AROpenDlgStruct: invalid key value" );
ARError_add( AR_RETURN_ERROR, AP_ERR_CONTINUE, SvPV_nolen(*val) );
}
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"windowMode\"" );
return -1;
}
}
#endif
{
SV **val;
strncpy( k, "outputValueFieldPairs", 255 );
val = hv_fetch( h, "outputValueFieldPairs", 21, 0 );
if( val && *val && SvOK(*val) ){
{
rev_ARFieldAssignList( ctrl, h, k, &(p->outputValueFieldPairs) );
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"outputValueFieldPairs\"" );
return -1;
}
}
{
SV **val;
strncpy( k, "query", 255 );
val = hv_fetch( h, "query", 5, 0 );
if( val && *val && SvOK(*val) ){
{
rev_ARQualifierStruct( ctrl, h, k, &(p->query) );
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"query\"" );
return -1;
}
}
{
SV **val;
strncpy( k, "serverName", 255 );
val = hv_fetch( h, "serverName", 10, 0 );
if( val && *val && SvOK(*val) ){
{
strncpy( p->serverName, SvPV_nolen(*val), sizeof(p->serverName) );
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"serverName\"" );
return -1;
}
}
{
SV **val;
strncpy( k, "message", 255 );
val = hv_fetch( h, "message", 7, 0 );
if( val && *val && SvOK(*val) ){
{
rev_ARMessageStruct( ctrl, h, k, &(p->msg) );
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"message\"" );
return -1;
}
}
{
SV **val;
strncpy( k, "noMatchContinue", 255 );
val = hv_fetch( h, "noMatchContinue", 15, 0 );
if( val && *val && SvOK(*val) ){
{
int flag = 0;
if( !strcmp(SvPV_nolen(*val),"true") ){
p->noMatchContinue = TRUE;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"false") ){
p->noMatchContinue = FALSE;
flag = 1;
}
if( flag == 0 ){
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_AROpenDlgStruct: invalid key value" );
ARError_add( AR_RETURN_ERROR, AP_ERR_CONTINUE, SvPV_nolen(*val) );
}
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"noMatchContinue\"" );
return -1;
}
}
{
SV **val;
strncpy( k, "sortOrderList", 255 );
val = hv_fetch( h, "sortOrderList", 13, 0 );
if( val && *val && SvOK(*val) ){
{
rev_ARSortList( ctrl, h, k, &(p->sortOrderList) );
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"sortOrderList\"" );
return -1;
}
}
{
SV **val;
strncpy( k, "inputValueFieldPairs", 255 );
val = hv_fetch( h, "inputValueFieldPairs", 20, 0 );
if( val && *val && SvOK(*val) ){
{
rev_ARFieldAssignList( ctrl, h, k, &(p->inputValueFieldPairs) );
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"inputValueFieldPairs\"" );
return -1;
}
}
{
SV **val;
strncpy( k, "closeBox", 255 );
val = hv_fetch( h, "closeBox", 8, 0 );
if( val && *val && SvOK(*val) ){
{
int flag = 0;
if( !strcmp(SvPV_nolen(*val),"true") ){
p->closeBox = TRUE;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"false") ){
p->closeBox = FALSE;
flag = 1;
}
if( flag == 0 ){
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_AROpenDlgStruct: invalid key value" );
ARError_add( AR_RETURN_ERROR, AP_ERR_CONTINUE, SvPV_nolen(*val) );
}
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"closeBox\"" );
return -1;
}
}
{
SV **val;
strncpy( k, "schemaName", 255 );
val = hv_fetch( h, "schemaName", 10, 0 );
if( val && *val && SvOK(*val) ){
{
strncpy( p->schemaName, SvPV_nolen(*val), sizeof(p->schemaName) );
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"schemaName\"" );
return -1;
}
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_AROpenDlgStruct: hash value is not a hash reference" );
return -1;
}
}
}else{
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, "rev_AROpenDlgStruct: hv_fetch returned null");
return -2;
}
}else{
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, "rev_AROpenDlgStruct: key doesn't exist");
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, k );
return -2;
}
}else{
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_AROpenDlgStruct: first argument is not a hash");
return -1;
}
return 0;
}
#if AR_CURRENT_API_VERSION >= 10
int
rev_ARPushFieldsActionStruct( ARControlStruct *ctrl, HV *h, char *k, ARPushFieldsActionStruct *p ){
SV **val;
int i = 0;
if( !p ){
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARPushFieldsActionStruct: AR Object param is NULL" );
supportrev_generated.c view on Meta::CPAN
return -2;
}
}else{
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARQualifierStruct: first argument is not a hash");
return -1;
}
return 0;
}
int
rev_ARQueryValueStruct( ARControlStruct *ctrl, HV *h, char *k, ARQueryValueStruct *p ){
SV **val;
int i = 0;
if( !p ){
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARQueryValueStruct: AR Object param is NULL" );
return -1;
}
if( SvTYPE((SV*) h) == SVt_PVHV ){
// printf( "ARQueryValueStruct: k = <%s>\n", k );
if( hv_exists(h,k,strlen(k)) ){
val = hv_fetch( h, k, strlen(k), 0 );
if( val && *val ){
{
if( SvTYPE(SvRV(*val)) == SVt_PVHV ){
int i = 0, num = 0;
HV *h = (HV* ) SvRV((SV*) *val);
char k[256];
k[255] = '\0';
{
SV **val;
strncpy( k, "qualifier", 255 );
val = hv_fetch( h, "qualifier", 9, 0 );
if( val && *val && SvOK(*val) ){
{
p->qualifier = MALLOCNN(sizeof(ARQualifierStruct)); rev_ARQualifierStruct( ctrl, h, k, p->qualifier );
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"qualifier\"" );
return -1;
}
}
{
SV **val;
strncpy( k, "multi", 255 );
val = hv_fetch( h, "multi", 5, 0 );
if( val && *val && SvOK(*val) ){
{
int flag = 0;
if( !strcmp(SvPV_nolen(*val),"set") ){
p->multiMatchCode = AR_QUERY_VALUE_MULTI_SET;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"error") ){
p->multiMatchCode = AR_QUERY_VALUE_MULTI_ERROR;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"first") ){
p->multiMatchCode = AR_QUERY_VALUE_MULTI_FIRST;
flag = 1;
}
if( flag == 0 ){
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARQueryValueStruct: invalid key value" );
ARError_add( AR_RETURN_ERROR, AP_ERR_CONTINUE, SvPV_nolen(*val) );
}
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"multi\"" );
return -1;
}
}
{
SV **val;
strncpy( k, "server", 255 );
val = hv_fetch( h, "server", 6, 0 );
if( val && *val && SvOK(*val) ){
{
strncpy( p->server, SvPV_nolen(*val), sizeof(p->server) );
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"server\"" );
return -1;
}
}
{
SV **val;
strncpy( k, "valueField", 255 );
val = hv_fetch( h, "valueField", 10, 0 );
if( val && *val && SvOK(*val) ){
{
p->valueField = SvIV(*val);
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"valueField\"" );
return -1;
}
}
{
SV **val;
strncpy( k, "schema", 255 );
val = hv_fetch( h, "schema", 6, 0 );
if( val && *val && SvOK(*val) ){
{
strncpy( p->schema, SvPV_nolen(*val), sizeof(p->schema) );
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"schema\"" );
return -1;
}
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARQueryValueStruct: hash value is not a hash reference" );
return -1;
}
supportrev_generated.c view on Meta::CPAN
SV **val;
int i = 0;
if( !p ){
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARRelOpStruct: AR Object param is NULL" );
return -1;
}
if( SvTYPE((SV*) h) == SVt_PVHV ){
// printf( "ARRelOpStruct: k = <%s>\n", k );
if( hv_exists(h,k,strlen(k)) ){
val = hv_fetch( h, k, strlen(k), 0 );
if( val && *val ){
{
if( SvTYPE(SvRV(*val)) == SVt_PVHV ){
int i = 0, num = 0;
HV *h = (HV* ) SvRV((SV*) *val);
char k[256];
k[255] = '\0';
{
SV **val;
strncpy( k, "left", 255 );
val = hv_fetch( h, "left", 4, 0 );
if( val && *val && SvOK(*val) ){
{
rev_ARFieldValueOrArithStruct( ctrl, h, k, &(p->operandLeft) );
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"left\"" );
return -1;
}
}
{
SV **val;
strncpy( k, "right", 255 );
val = hv_fetch( h, "right", 5, 0 );
if( val && *val && SvOK(*val) ){
{
rev_ARFieldValueOrArithStruct( ctrl, h, k, &(p->operandRight) );
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"right\"" );
return -1;
}
}
{
SV **val;
strncpy( k, "oper", 255 );
val = hv_fetch( h, "oper", 4, 0 );
if( val && *val && SvOK(*val) ){
{
int flag = 0;
if( !strcmp(SvPV_nolen(*val),">") ){
p->operation = AR_REL_OP_GREATER;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"in") ){
p->operation = AR_REL_OP_IN;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),">=") ){
p->operation = AR_REL_OP_GREATER_EQUAL;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"==") ){
p->operation = AR_REL_OP_EQUAL;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"like") ){
p->operation = AR_REL_OP_LIKE;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"!=") ){
p->operation = AR_REL_OP_NOT_EQUAL;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"<=") ){
p->operation = AR_REL_OP_LESS_EQUAL;
flag = 1;
}
if( !strcmp(SvPV_nolen(*val),"<") ){
p->operation = AR_REL_OP_LESS;
flag = 1;
}
if( flag == 0 ){
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARRelOpStruct: invalid key value" );
ARError_add( AR_RETURN_ERROR, AP_ERR_CONTINUE, SvPV_nolen(*val) );
}
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "hv_fetch error: key \"oper\"" );
return -1;
}
}
}else{
ARError_add( AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARRelOpStruct: hash value is not a hash reference" );
return -1;
}
}
}else{
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, "rev_ARRelOpStruct: hv_fetch returned null");
return -2;
}
}else{
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, "rev_ARRelOpStruct: key doesn't exist");
ARError_add(AR_RETURN_WARNING, AP_ERR_GENERAL, k );
return -2;
}
}else{
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARRelOpStruct: first argument is not a hash");
return -1;
}
return 0;
}
int
rev_ARSQLStruct( ARControlStruct *ctrl, HV *h, char *k, ARSQLStruct *p ){
SV **val;
int i = 0;
if( !p ){
ARError_add(AR_RETURN_ERROR, AP_ERR_GENERAL, "rev_ARSQLStruct: AR Object param is NULL" );
return -1;
}
if( SvTYPE((SV*) h) == SVt_PVHV ){
// printf( "ARSQLStruct: k = <%s>\n", k );
if( hv_exists(h,k,strlen(k)) ){
val = hv_fetch( h, k, strlen(k), 0 );
if( val && *val ){
{
if( SvTYPE(SvRV(*val)) == SVt_PVHV ){
int i = 0, num = 0;
HV *h = (HV* ) SvRV((SV*) *val);
( run in 1.938 second using v1.01-cache-2.11-cpan-437f7b0c052 )