Skip site navigation (1)Skip section navigation (2)

FreeBSD Manual Pages

  
 
  

home | help
AFGETRESULTMD(3)		    Amberfish			AFGETRESULTMD(3)

NAME
     afgetresultmd - get metadata associated with search results

SYNOPSIS
     #include af.h

     int  afgetresultmd(const  Afresult  *result,  int	resultn, Afresultmd *re-
     sultmd);

DESCRIPTION
     The afgetresultmd function retrieves additional metadata about results  re-
     turned from afsearch(3).

     The argument result specifies the array of results.

     The argument resultn specifies the number of elements in result.

     The  argument  resultmd specifies an array with the same number of elements
     as result, to be filled in by this function.

RETURN VALUE
     This function returns 0 if it exited normally.  If an  error  occurred,  it
     returns -1 and aferrno is set.

     If the function exited normally, the array resultmd is filled in.	Each el-
     ement of resultmd consists of the following:

     typedef struct {
	  Uint4 parent;
	  char docpath[AFPATHSIZE];
	  off_t begin;
	  off_t end;
     } Afresultmd;

     The parent is the document identifier of this document's parent.  When this
     is  used, it is usually a container, for example, an outer XML element.  If
     it is unused, it is set to 0.

     The docpath is the path name of the file containing the document.

     The begin and end values are offsets delimiting  the  starting  and  ending
     points  of the document within the file docpath.  The end offset points one
     character past the end of the document.

ERRORS
     This function returns only "core" errors.

								AFGETRESULTMD(3)

Want to link to this manual page? Use this URL:
<https://man.freebsd.org/cgi/man.cgi?query=afgetresultmd&sektion=3&manpath=FreeBSD+Ports+15.1.quarterly>

home | help