Documentation ¶
Overview ¶
Package vcard is a library made to decode vCard files into readable golang structs.
Index ¶
Constants ¶
View Source
const ( // VCardTagName represents the tag name used inside the struct VCard. VCardTagName = "vcard" // VCardVersion represents the supported version of vCard. VCardVersion = "2.1" )
Variables ¶
View Source
var ( // ErrUnsupportedType indicates that an unsupported interface type was sent for conversion. ErrUnsupportedType = errors.New("unsupported type") )
Functions ¶
Types ¶
type VCard ¶
type VCard struct { StructuredName string `vcard:"N"` FormattedName string `vcard:"FN"` Email string `vcard:"EMAIL"` Version string `vcard:"VERSION"` Addr string `vcard:"ADR"` Anniversary string `vcard:"ANNIVERSARY"` BirthDay string `vcard:"BDAY"` Nickname string `vcard:"NICKNAME"` Photo string `vcard:"PHOTO"` CalendarAddrURI string `vcard:"CALADRURI"` CalendarURI string `vcard:"CALURI"` Categories string `vcard:"CATEGORIES"` Class string `vcard:"CLASS"` ClientIDMap string `vcard:"CLIENTIDMAP"` FreeOrBusyURL string `vcard:"FBURL"` Gender string `vcard:"GENDER"` Geolocation string `vcard:"GEO"` Key string `vcard:"KEY"` Kind string `vcard:"KIND"` Language string `vcard:"LANG"` Logo string `vcard:"LOGO"` Mailer string `vcard:"MAILER"` Member string `vcard:"MEMBER"` Note string `vcard:"NOTE"` Organization string `vcard:"ORG"` ProdID string `vcard:"PRODID"` Profile string `vcard:"PROFILE"` Related string `vcard:"RELATED"` Revision string `vcard:"REV"` Role string `vcard:"ROLE"` Sound string `vcard:"SOUND"` Source string `vcard:"SOURCE"` Phone string `vcard:"TEL"` Title string `vcard:"TITLE"` TimeZone string `vcard:"TZ"` UID string `vcard:"UID"` URL string `vcard:"URL"` XML string `vcard:"XML"` // Additional properties BirthPlace string `vcard:"BIRTHPLACE"` DeathPlace string `vcard:"DEATHPLACE"` DeathDate string `vcard:"DEATHDATE"` Expertise string `vcard:"EXPERTISE"` Hobby string `vcard:"HOBBY"` InstantMessenger string `vcard:"IMPP"` Interest string `vcard:"INTEREST"` OrganizationDirectory string `vcard:"ORG-DIRECTORY"` }
VCard represents a single vCard with its fields.
func GetVCardsByFile ¶
GetVCardsByFile returns a list of vCard retrived from a golang *os.File.
Click to show internal directories.
Click to hide internal directories.