User Tools

Site Tools


Sidebar

Table Of Contents

endurox:v8.0.x:api:ubf:bgetrv.3

bgetrv

Name

Bgetrv — Get data from UBF buffer, recursive, var-args path

Synopsis

#include <ubf.h>

int Bgetr (UBFH * p_ub, BFLDID *fldidocc, char * buf, BFLDLEN * buflen);

int Bgetrv (UBFH * p_ub, char * buf, BFLDLEN * buflen, …);

int CBgetr (UBFH * p_ub, BFLDID *fldidocc, char * buf, BFLDLEN * buflen, int usrtype);

int CBgetrv (UBFH * p_ub, char * buf, BFLDLEN * buflen, int usrtype, …);

char* Bfindr (UBFH *p_ub, BFLDID *fldidocc, BFLDLEN *p_len);

char* Bfindrv (UBFH *p_ub, BFLDLEN *p_len, …);

char *CBfindr (UBFH *p_ub, BFLDID *fldidocc, BFLDLEN *len, int usrtype);

char *CBfindrv (UBFH *p_ub, BFLDLEN *len, int usrtype, …);

int Bpresr (UBFH *p_ub, BFLDID *fldidocc);

int Bpresrv (UBFH *p_ub, …);

int CBvgetr(UBFH *p_ub, BFLDID *fldidocc, char *cname, BFLDOCC occ, char *buf, BFLDLEN *len, int usrtype, long flags);

int CBvgetrv(UBFH *p_ub, char *cname, BFLDOCC occ, char *buf, BFLDLEN *len, int usrtype, long flags, …);

char * CBgetallocr (UBFH *p_ub, BFLDID *fldidocc, int usrtype, BFLDLEN *extralen);

char * CBgetallocrv (UBFH *p_ub, int usrtype, BFLDLEN *extralen, …);

int Bvnullr(UBFH *p_ub, BFLDID *fldidocc, char *cname, BFLDOCC occ);

int Bvnullrv(UBFH *p_ub, char *cname, BFLDOCC occ, …);

char * CBvgetallocr(UBFH *p_ub, BFLDID *fldidocc, char *cname, BFLDOCC occ, int usrtype, long flags, BFLDLEN *extralen);

char* CBvgetallocrv(UBFH *p_ub, char *cname, BFLDOCC occ, int usrtype, long flags, BFLDLEN *extralen, …);

Link with -lubf -lnstd -lm -lpthread

DESCRIPTION

Group of macro functions used lookup to the field in sub-UBF buffers. The exact field from which to take the value at given sub-level, is specified in field id sequence. Functions with r suffix encodes the field id sequence in array specified in fldidocc parameter. Functions with rv suffix encodes the field id sequence in var-args. Last field id in sequence (leaf) identifies the UBF field id on which the target operation must be executed. For view operations, this field must correspond to the view field present in UBF buffer.

Field id sequence must be present in following form:

<FLDID>, <OCC>, …, <FLDID>, <OCC>, BBADFLDOCC.

Internally function uses Bfind(3) to search the sub-UBF buffer from internal UBF field IDs.

Function mapping is following where leaf field id is executed on sub-ubf buffer:

  1. Bgetr(3) and Bgetrv(3) translates to Bget(3) call.
  2. CBgetr(3) and CBgetrv(3) translates to CBget(3) call.
  3. CBgetallocr(3) and CBgetallocrv(3) translates to CBgetalloc(3) call.
  4. Bfindr(3) and Bfindrv(3) translates to Bfindr(3) call.
  5. Bpresr(3) and Bpresrv(3) translates to Bpres(3) call.
  6. CBvgetr(3) and CBvgetrv(3) translates to CBvget(3) call. Note that here it is expected that leaf field in field id sequence matches the view typed field in UBF buffer. Thus on this field value in UBF buffer CBvget(3) is executed.
  7. CBvgetallocr(3) and CBvgetallocrv(3) translates to CBvgetalloc(3) call. Note that here it is expected that leaf field in field id sequence matches the view typed field in UBF buffer. Thus on this field value in UBF buffer CBvgetalloc(3) is executed.
  8. Bvnullr(3) and Bvnullr