Libical API Documentation 4.0 STABLE VERSION [Visit the v3.0 documentation]
Loading...
Searching...
No Matches
vcardderivedvalue.h
Go to the documentation of this file.
1/*======================================================================
2 FILE: vcardderivedvalue.h
3 CREATOR: Ken Murchison 24 Aug 2022 <murch@fastmailteam.com>
4
5 SPDX-FileCopyrightText: 2022, Fastmail Pty. Ltd. (https://fastmail.com)
6 SPDX-License-Identifier: LGPL-2.1-only OR MPL-2.0
7 ======================================================================*/
8
13
14#ifndef VCARDDERIVEDVALUE_H
15#define VCARDDERIVEDVALUE_H
16
17#include "libical_vcard_export.h"
18#include "vcardstrarray.h"
19#include "vcardstructured.h"
20#include "vcardtime.h"
21#include "vcardtypes.h"
22
23#include <stdbool.h>
24
36
42
65
71
72typedef struct vcardvalue_impl vcardvalue;
73
74LIBICAL_VCARD_EXPORT void vcardvalue_set_x(vcardvalue *value, const char *v);
75LIBICAL_VCARD_EXPORT vcardvalue *vcardvalue_new_x(const char *v);
76LIBICAL_VCARD_EXPORT const char *vcardvalue_get_x(const vcardvalue *value);
77
79LIBICAL_VCARD_EXPORT void vcardvalue_set_structured(vcardvalue *value,
81LIBICAL_VCARD_EXPORT vcardstructuredtype *vcardvalue_get_structured(const vcardvalue *value);
82
84LIBICAL_VCARD_EXPORT void vcardvalue_set_geo(vcardvalue *value, vcardgeotype v);
85LIBICAL_VCARD_EXPORT vcardgeotype vcardvalue_get_geo(const vcardvalue *value);
86
87LIBICAL_VCARD_EXPORT vcardvalue *vcardvalue_new_tz(vcardtztype v);
88LIBICAL_VCARD_EXPORT void vcardvalue_set_tz(vcardvalue *value, vcardtztype v);
89LIBICAL_VCARD_EXPORT vcardtztype vcardvalue_get_tz(const vcardvalue *value);
90
115
116#define VCARDPROPERTY_FIRST_ENUM 10000
117
128
139
147
148#define VCARDPROPERTY_LAST_ENUM 10300
149
150/* BOOLEAN */
151LIBICAL_VCARD_EXPORT vcardvalue *vcardvalue_new_boolean(int v);
152LIBICAL_VCARD_EXPORT int vcardvalue_get_boolean(const vcardvalue *value);
153LIBICAL_VCARD_EXPORT void vcardvalue_set_boolean(vcardvalue *value, int v);
154
155/* DATE */
157LIBICAL_VCARD_EXPORT vcardtimetype vcardvalue_get_date(const vcardvalue *value);
158LIBICAL_VCARD_EXPORT void vcardvalue_set_date(vcardvalue *value, vcardtimetype v);
159
160/* DATE-AND-OR-TIME */
162LIBICAL_VCARD_EXPORT vcardtimetype vcardvalue_get_dateandortime(const vcardvalue *value);
163LIBICAL_VCARD_EXPORT void vcardvalue_set_dateandortime(vcardvalue *value, vcardtimetype v);
164
165/* DATE-TIME */
167LIBICAL_VCARD_EXPORT vcardtimetype vcardvalue_get_datetime(const vcardvalue *value);
168LIBICAL_VCARD_EXPORT void vcardvalue_set_datetime(vcardvalue *value, vcardtimetype v);
169
170/* FLOAT */
171LIBICAL_VCARD_EXPORT vcardvalue *vcardvalue_new_float(float v);
172LIBICAL_VCARD_EXPORT float vcardvalue_get_float(const vcardvalue *value);
173LIBICAL_VCARD_EXPORT void vcardvalue_set_float(vcardvalue *value, float v);
174
175/* GRAMGENDER */
177LIBICAL_VCARD_EXPORT enum vcardproperty_gramgender vcardvalue_get_gramgender(const vcardvalue *value);
178LIBICAL_VCARD_EXPORT void vcardvalue_set_gramgender(vcardvalue *value, enum vcardproperty_gramgender v);
179
180/* INTEGER */
181LIBICAL_VCARD_EXPORT vcardvalue *vcardvalue_new_integer(int v);
182LIBICAL_VCARD_EXPORT int vcardvalue_get_integer(const vcardvalue *value);
183LIBICAL_VCARD_EXPORT void vcardvalue_set_integer(vcardvalue *value, int v);
184
185/* KIND */
187LIBICAL_VCARD_EXPORT enum vcardproperty_kindenum vcardvalue_get_kind(const vcardvalue *value);
188LIBICAL_VCARD_EXPORT void vcardvalue_set_kind(vcardvalue *value, enum vcardproperty_kindenum v);
189
190/* LANGUAGE-TAG */
191LIBICAL_VCARD_EXPORT vcardvalue *vcardvalue_new_languagetag(const char * v);
192LIBICAL_VCARD_EXPORT const char * vcardvalue_get_languagetag(const vcardvalue *value);
193LIBICAL_VCARD_EXPORT void vcardvalue_set_languagetag(vcardvalue *value, const char * v);
194
195/* TEXT */
196LIBICAL_VCARD_EXPORT vcardvalue *vcardvalue_new_text(const char * v);
197LIBICAL_VCARD_EXPORT const char * vcardvalue_get_text(const vcardvalue *value);
198LIBICAL_VCARD_EXPORT void vcardvalue_set_text(vcardvalue *value, const char * v);
199
200/* TEXTLIST */
202LIBICAL_VCARD_EXPORT vcardstrarray * vcardvalue_get_textlist(const vcardvalue *value);
203LIBICAL_VCARD_EXPORT void vcardvalue_set_textlist(vcardvalue *value, vcardstrarray * v);
204
205/* TIME */
207LIBICAL_VCARD_EXPORT vcardtimetype vcardvalue_get_time(const vcardvalue *value);
208LIBICAL_VCARD_EXPORT void vcardvalue_set_time(vcardvalue *value, vcardtimetype v);
209
210/* TIMESTAMP */
212LIBICAL_VCARD_EXPORT vcardtimetype vcardvalue_get_timestamp(const vcardvalue *value);
213LIBICAL_VCARD_EXPORT void vcardvalue_set_timestamp(vcardvalue *value, vcardtimetype v);
214
215/* URI */
216LIBICAL_VCARD_EXPORT vcardvalue *vcardvalue_new_uri(const char * v);
217LIBICAL_VCARD_EXPORT const char * vcardvalue_get_uri(const vcardvalue *value);
218LIBICAL_VCARD_EXPORT void vcardvalue_set_uri(vcardvalue *value, const char * v);
219
220/* UTC-OFFSET */
221LIBICAL_VCARD_EXPORT vcardvalue *vcardvalue_new_utcoffset(int v);
222LIBICAL_VCARD_EXPORT int vcardvalue_get_utcoffset(const vcardvalue *value);
223LIBICAL_VCARD_EXPORT void vcardvalue_set_utcoffset(vcardvalue *value, int v);
224
225/* VERSION */
227LIBICAL_VCARD_EXPORT enum vcardproperty_version vcardvalue_get_version(const vcardvalue *value);
228LIBICAL_VCARD_EXPORT void vcardvalue_set_version(vcardvalue *value, enum vcardproperty_version v);
229#endif /*VCARDVALUE_H*/
void vcardvalue_set_datetime(vcardvalue *value, vcardtimetype v)
vcardvalue * vcardvalue_new_textlist(vcardstrarray *v)
void vcardvalue_set_float(vcardvalue *value, float v)
struct vcardvalue_impl vcardvalue
void vcardvalue_set_dateandortime(vcardvalue *value, vcardtimetype v)
void vcardvalue_set_time(vcardvalue *value, vcardtimetype v)
vcardtimetype vcardvalue_get_datetime(const vcardvalue *value)
void vcardvalue_set_uri(vcardvalue *value, const char *v)
void vcardvalue_set_utcoffset(vcardvalue *value, int v)
vcardvalue * vcardvalue_new_geo(vcardgeotype v)
int vcardvalue_get_utcoffset(const vcardvalue *value)
void vcardvalue_set_textlist(vcardvalue *value, vcardstrarray *v)
void vcardvalue_set_tz(vcardvalue *value, vcardtztype v)
vcardvalue * vcardvalue_new_integer(int v)
void vcardvalue_set_boolean(vcardvalue *value, int v)
vcardproperty_kindenum
@ VCARD_KIND_ORG
@ VCARD_KIND_NONE
@ VCARD_KIND_LOCATION
@ VCARD_KIND_DEVICE
@ VCARD_KIND_APPLICATION
@ VCARD_KIND_INDIVIDUAL
@ VCARD_KIND_X
@ VCARD_KIND_GROUP
vcardvalue * vcardvalue_new_time(vcardtimetype v)
vcardvalue * vcardvalue_new_x(const char *v)
vcardvalue * vcardvalue_new_dateandortime(vcardtimetype v)
vcardstrarray * vcardvalue_get_textlist(const vcardvalue *value)
vcardvalue * vcardvalue_new_languagetag(const char *v)
int vcardvalue_get_integer(const vcardvalue *value)
vcard_adr_field
@ VCARD_ADR_FLOOR
@ VCARD_ADR_COUNTRY
@ VCARD_ADR_LOCALITY
@ VCARD_ADR_STREET_NUMBER
@ VCARD_ADR_POSTAL_CODE
@ VCARD_ADR_STREET
@ VCARD_ADR_EXTENDED
@ VCARD_ADR_REGION
@ VCARD_ADR_SUBDISTRICT
@ VCARD_ADR_DIRECTION
@ VCARD_ADR_LANDMARK
@ VCARD_NUM_ADR_FIELDS
@ VCARD_ADR_BUILDING
@ VCARD_ADR_STREET_NAME
@ VCARD_ADR_ROOM
@ VCARD_ADR_BLOCK
@ VCARD_ADR_PO_BOX
@ VCARD_ADR_DISTRICT
@ VCARD_ADR_APARTMENT
void vcardvalue_set_version(vcardvalue *value, enum vcardproperty_version v)
vcardtimetype vcardvalue_get_time(const vcardvalue *value)
void vcardvalue_set_x(vcardvalue *value, const char *v)
void vcardvalue_set_geo(vcardvalue *value, vcardgeotype v)
vcardvalue * vcardvalue_new_timestamp(vcardtimetype v)
void vcardvalue_set_structured(vcardvalue *value, vcardstructuredtype *v)
vcardvalue * vcardvalue_new_float(float v)
vcardvalue * vcardvalue_new_uri(const char *v)
float vcardvalue_get_float(const vcardvalue *value)
vcardtimetype vcardvalue_get_date(const vcardvalue *value)
const char * vcardvalue_get_languagetag(const vcardvalue *value)
vcardproperty_version
@ VCARD_VERSION_21
@ VCARD_VERSION_30
@ VCARD_VERSION_40
@ VCARD_VERSION_NONE
@ VCARD_VERSION_X
enum vcardproperty_gramgender vcardvalue_get_gramgender(const vcardvalue *value)
vcard_gender_field
@ VCARD_GENDER_SEX
@ VCARD_NUM_GENDER_FIELDS
@ VCARD_GENDER_TEXT
vcardvalue * vcardvalue_new_structured(vcardstructuredtype *v)
vcardvalue * vcardvalue_new_kind(enum vcardproperty_kindenum v)
vcard_clientpidmap_field
@ VCARD_CLIENTPIDMAP_ID
@ VCARD_CLIENTPIDMAP_URI
@ VCARD_NUM_CLIENTPIDMAP_FIELDS
vcardtimetype vcardvalue_get_timestamp(const vcardvalue *value)
vcardvalue_kind
@ VCARD_TZ_VALUE
@ VCARD_INTEGER_VALUE
@ VCARD_TIMESTAMP_VALUE
@ VCARD_URI_VALUE
@ VCARD_VERSION_VALUE
@ VCARD_TEXTLIST_VALUE
@ VCARD_BOOLEAN_VALUE
@ VCARD_KIND_VALUE
@ VCARD_X_VALUE
@ VCARD_DATETIME_VALUE
@ VCARD_GRAMGENDER_VALUE
@ VCARD_GEO_VALUE
@ VCARD_UTCOFFSET_VALUE
@ VCARD_DATE_VALUE
@ VCARD_FLOAT_VALUE
@ VCARD_DATEANDORTIME_VALUE
@ VCARD_STRUCTURED_VALUE
@ VCARD_LANGUAGETAG_VALUE
@ VCARD_NO_VALUE
@ VCARD_ANY_VALUE
@ VCARD_TEXT_VALUE
@ VCARD_TIME_VALUE
const char * vcardvalue_get_uri(const vcardvalue *value)
vcardvalue * vcardvalue_new_version(enum vcardproperty_version v)
vcardgeotype vcardvalue_get_geo(const vcardvalue *value)
vcardtimetype vcardvalue_get_dateandortime(const vcardvalue *value)
enum vcardproperty_version vcardvalue_get_version(const vcardvalue *value)
void vcardvalue_set_date(vcardvalue *value, vcardtimetype v)
vcardvalue * vcardvalue_new_text(const char *v)
int vcardvalue_get_boolean(const vcardvalue *value)
vcardvalue * vcardvalue_new_utcoffset(int v)
void vcardvalue_set_languagetag(vcardvalue *value, const char *v)
void vcardvalue_set_integer(vcardvalue *value, int v)
void vcardvalue_set_timestamp(vcardvalue *value, vcardtimetype v)
vcard_n_field
@ VCARD_NUM_N_FIELDS
@ VCARD_N_GIVEN
@ VCARD_N_ADDITIONAL
@ VCARD_N_FAMILY
@ VCARD_N_SUFFIX
@ VCARD_N_PREFIX
@ VCARD_N_SECONDARY
@ VCARD_N_GENERATION
vcardvalue * vcardvalue_new_boolean(int v)
void vcardvalue_set_kind(vcardvalue *value, enum vcardproperty_kindenum v)
void vcardvalue_set_gramgender(vcardvalue *value, enum vcardproperty_gramgender v)
vcardvalue * vcardvalue_new_gramgender(enum vcardproperty_gramgender v)
vcardvalue * vcardvalue_new_datetime(vcardtimetype v)
vcardvalue * vcardvalue_new_tz(vcardtztype v)
vcardtztype vcardvalue_get_tz(const vcardvalue *value)
void vcardvalue_set_text(vcardvalue *value, const char *v)
vcardproperty_gramgender
@ VCARD_GRAMGENDER_ANIMATE
@ VCARD_GRAMGENDER_COMMON
@ VCARD_GRAMGENDER_INANIMATE
@ VCARD_GRAMGENDER_NEUTER
@ VCARD_GRAMGENDER_X
@ VCARD_GRAMGENDER_FEMININE
@ VCARD_GRAMGENDER_MASCULINE
@ VCARD_GRAMGENDER_NONE
vcardstructuredtype * vcardvalue_get_structured(const vcardvalue *value)
enum vcardproperty_kindenum vcardvalue_get_kind(const vcardvalue *value)
const char * vcardvalue_get_x(const vcardvalue *value)
vcardvalue * vcardvalue_new_date(vcardtimetype v)
const char * vcardvalue_get_text(const vcardvalue *value)
Namespace the icalstrarray functions for vcard.
icalstrarray vcardstrarray
Defines the data structure representing vCard structured values.
struct vcardstructuredtype_impl vcardstructuredtype
Represents a decoded, structured text value.
Defines the data structure representing vCard date-times.
Defines vcard internal types.