ref: a0054fa2fc711277c267fbd7d6b48bff6e0d4a82
dir: /man/vcard.2/
.TH VCARD 2 .SH NAME vcparse, vcparsefile, vcmserialize, vcfreeparams, vcfreelines, vcfreecards \- vcard library .SH SYNOPSIS .ft L .nf #include "vcard.h" .fi .PP .ft L .nf typedef struct Vcard Vcard; typedef struct Vline Vline; typedef struct Vparam Vparam; .fi .PP .ft L .nf .ta \w' 'u +\w'Vparam 'u +\w'Vparam 'u struct Vcard { Vline *content; Vcard *next; }; .fi .PP .ft L .nf struct Vline { char *name; char *value; char *group; Vparam *params; .fi .B }; .PP .ft L .nf struct Vparam { char *name; char *value; Vparam *next; }; .fi .PP .ft L .nf .ta \w'Vparam 'u +\w'Vparam 'u +\w'Vparam 'u Vcard* vcparse(char *string); Vcard* vcparsefile(char *file); char* vcmserialize(Vcard*); .fi .PP .ft L .nf void vcfreeparams(Vparam*); void vcfreelines(Vline*); void vcfreecards(Vcard*); .fi .SH DESCRIPTION This library provides parsing functionality for vcard files based on the specification for version 4.0 of the vcard file format. The parsing functionality is generic enough to be able to parse all common versions of vcard, it does no semantic validation. .PP .I Vcparse and .I vcparsefile parse .I string or .I file respectively. They return a valid allocated .I Vcard structure, or .I nil on error. .PP .IR Vcfreeparams , .IR vcfreelines and .I vcfreecards free the specified chain of structures. If you only want to free a single structure, it is necessary to set the .I next pointer to .IR nil . .PP .I Vcmserialize returns an allocated string of the supplied chain of .I Vcard structures. .SH SOURCE .B https://shithub.us/sirjofri/vcardfs - libvcard .br .B https://git.sr.ht/~sirjofri/vcardfs - libvcard .SH SEE ALSO .IR vcardfs (1) .SH DIAGNOSTICS Sets .IR errstr . .SH BUGS Sure.