ContactWriter

class ContactWriter(val contact: Contact, val version: VCardVersion, val productId: String)

Responsible for converting the Contact data class (which is not version-specific) to the vCard that is actually sent to the server.

Properties which are not supported by the target vCard version have to be converted appropriately.

Parameters

contact

contact data to be converted into a vCard

version

vCard version to generate

productId

product ID that identifies your app (will be used as PRODID; ez-vcard version will be appended)

Constructors

Link copied to clipboard
constructor(contact: Contact, version: VCardVersion, productId: String)

Properties

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
val vCard: VCard
Link copied to clipboard
val version: VCardVersion

Functions

Link copied to clipboard
fun addLabeledProperty(labeledProperty: LabeledProperty<*>)
Link copied to clipboard
fun <T : DateOrTimeProperty> rewritePartialDate(prop: T)
Link copied to clipboard
fun writeCard(stream: OutputStream, jCard: Boolean)

Validates and writes the vCard to an output stream.