VCardValue Class

A value of a vCard with its types: an email address, a telephone number, a URL...

public sealed class VCardValue

Constructors

NameDescription
VCardValue(string, IEnumerable<string>)Creates a value.

VCardValue(string, IEnumerable<string>)

VCardValue.cs

Creates a value.

public VCardValue(string value, params IEnumerable<string> types)

Parameters

value string
The value.
types IEnumerable<string>
The types, such as work, home, cell, voice or pref.

Properties

NameDescription
TypesGets the types, in lower case, such as work, home, cell, fax or pref.
ValueGets or sets the value.

Gets the types, in lower case, such as work, home, cell, fax or pref.

public IList<string> Types { get; }

Property value

IList<string>

Gets or sets the value.

public string Value { get; set; }

Property value

string

Methods

NameDescription
HasType(string)Gets whether the value has a type.
ToString()Returns the value.

HasType(string)

VCardValue.cs

Gets whether the value has a type.

public bool HasType(string type)

Parameters

type string
The type, without case.

Returns

bool true when the value has the type.

ToString()

VCardValue.cs

Returns the value.

public override string ToString()

Returns

string The value.