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

FreeBSD Manual Pages

  
 
  

home | help
DC_PARSER_NEW(3)	    Library Functions Manual	      DC_PARSER_NEW(3)

NAME
       dc_parser_new, dc_parser_new2 --	create a parser	for a single dive

LIBRARY
       library "libdivecomputer"

SYNOPSIS
       #include	<libdivecomputer/parser.h>

       dc_status_t
       dc_parser_new(dc_parser_t **parser, dc_device_t *device);

       dc_status_t
       dc_parser_new2(dc_parser_t **parser,		dc_context_t *context,
	   dc_descriptor_t *descriptor,			 unsigned int devtime,
	   dc_ticks_t systime);

DESCRIPTION
       Creates	a  parser  for	a single dive extracted	from the dive computer
       with dc_device_foreach(3).  The parser operates on the data  extracted:
       it does not touch the device directly to	acquire	data.  Thus, there are
       two  forms of invocation: dc_parser_new,	which extracts relevant	values
       from the	device parameter; and dc_parser_new2, which  is	 given	device
       values (model, etc.) directly.

       After  filling  in  the	parser parameter, one usually sets parser data
       with dc_parser_set_data(3).  The	 pointer  must	later  be  freed  with
       dc_parser_destroy(3).

RETURN VALUES
       These  return  DC_STATUS_OK, and	fill in	the parser pointer on success.
       Otherwise, an error is returned.

SEE ALSO
       dc_device_foreach(3), dc_parser_destroy(3)

AUTHORS
       The library "libdivecomputer"  library  was  written  by	 Jef  Driesen,
       jef@libdivecomputer.org.	 The manpages were written by
       Kristaps	Dzonsons, kristaps@bsd.lv.

FreeBSD	Ports 14.quarterly	January	5, 2017		      DC_PARSER_NEW(3)

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

home | help