/* Parse incoming url constraints, if any, to check for syntactic correctness */ NCerror parsedapconstraints(NCDAPCOMMON* dapcomm, char* constraints, DCEconstraint* dceconstraint) { NCerror ncstat = NC_NOERR; char* errmsg; ASSERT(dceconstraint != NULL); nclistclear(dceconstraint->projections); nclistclear(dceconstraint->selections); ncstat = dapceparse(constraints,dceconstraint,&errmsg); if(ncstat) { nclog(NCLOGWARN,"DCE constraint parse failure: %s",errmsg); nullfree(errmsg); nclistclear(dceconstraint->projections); nclistclear(dceconstraint->selections); } else { #ifdef IGNORE int i; #ifdef DEBUG NClist* allnodes; fprintf(stderr,"constraint: %s",dumpconstraint(dceconstraint)); #endif /* Go thru each node and add annotation */ allnodes = dceallnodes((DCEnode*)dceconstraint,CES_NIL); for(i=0;i<nclistlength(allnodes);i++) { DCEnode* node = (DCEnode*)nclistget(allnodes,i); } #endif } return ncstat; }
/* Parse incoming url constraints, if any, to check for syntactic correctness */ NCerror parsedapconstraints(NCDAPCOMMON* dapcomm, char* constraints, DCEconstraint* dceconstraint) { NCerror ncstat = NC_NOERR; char* errmsg; ASSERT(dceconstraint != NULL); nclistclear(dceconstraint->projections); nclistclear(dceconstraint->selections); ncstat = dapceparse(constraints,dceconstraint,&errmsg); if(ncstat) { nclog(NCLOGWARN,"DCE constraint parse failure: %s",errmsg); nullfree(errmsg); nclistclear(dceconstraint->projections); nclistclear(dceconstraint->selections); } return ncstat; }
/* Parse incoming url constraints, if any, to check for syntactic correctness */ int dapparseconstraints(char* constraints, DCEconstraint* dapconstraint) { int ncstat = NC_NOERR; char* errmsg; assert(dapconstraint != NULL); nclistclear(dapconstraint->projections); nclistclear(dapconstraint->selections); ncstat = dapceparse(constraints,dapconstraint,&errmsg); if(ncstat) { nclog(NCLOGWARN,"DAP constraint parse failure: %s",errmsg); if(errmsg) free(errmsg); nclistclear(dapconstraint->projections); nclistclear(dapconstraint->selections); } #ifdef DEBUG fprintf(stderr,"constraint: %s",dcetostring((DCEnode*)dapconstraint)); #endif return ncstat; }