EBookContacts.VCardAttributeParam

Fields

None

Methods

class

new (name)

add_value (value)

copy ()

free ()

get_name ()

get_values ()

remove_values ()

Details

class EBookContacts.VCardAttributeParam
classmethod new(name)
Parameters:

name (str) – the name of the new parameter

Returns:

A new EBookContacts.VCardAttributeParam.

Return type:

EBookContacts.VCardAttributeParam

Creates a new parameter named name.

add_value(value)
Parameters:

value (str) – a string value to add

Appends value to self's list of values.

copy()
Returns:

a new EBookContacts.VCardAttributeParam identical to self.

Return type:

EBookContacts.VCardAttributeParam

Makes a copy of self and all its values.

free()

Frees self and its values.

get_name()
Returns:

The name of the parameter.

Return type:

str

Gets the name of self.

For example, for the only parameter of the vCard attribute:

TEL;TYPE=WORK,VOICE:(111) 555-1212

this would return TYPE (which is string-equivalent to EBookContacts.EVC_TYPE).

get_values()
Returns:

A list of string elements representing the parameter’s values.

Return type:

[str]

Gets the list of values from self. The list and its contents are owned by self, and must not be freed.

For example, for the TYPE parameter of the vCard attribute:

TEL;TYPE=WORK,VOICE:(111) 555-1212

this would return the list WORK, VOICE.

remove_values()

Removes and frees all values from self.