VCardCard

Inheritance: java.lang.Object, com.groupdocs.metadata.core.MetadataPackage, com.groupdocs.metadata.core.CustomPackage, com.groupdocs.metadata.core.VCardBasePackage, com.groupdocs.metadata.core.VCardRecordset

public class VCardCard extends VCardRecordset

Represents a single card extracted from a VCard file.

Learn more

This example shows how to use vCard property filters.

public static void run() { try (Metadata metadata = new Metadata(Constants.InputVcf)) { VCardRootPackage root = metadata.getRootPackageGeneric(); for (VCardCard vCard : root.getVCardPackage().getCards()) { // Print most preferred work phone numbers and work emails VCardCard filtered = vCard.filterWorkTags().filterPreferred(); PrintArray(filtered.getCommunicationRecordset().getTelephones()); PrintArray(filtered.getCommunicationRecordset().getEmails()); } } } private static void PrintArray(String[] values) { if (values != null) { for (String value : values) { System.out.println(value); } } }

Methods

Method Description
getGeneralRecordset() Gets the general records.
getIdentificationRecordset() Gets the identification records.
getDeliveryAddressingRecordset() Gets the delivery addressing records.
getCommunicationRecordset() Gets the communication records.
getGeographicalRecordset() Gets the geographical records.
getOrganizationalRecordset() Gets the organizational records.
getExplanatoryRecordset() Gets the explanatory records.
getSecurityRecordset() Gets the security records.
getCalendarRecordset() Gets the calendar records.
getExtensionRecords() Gets the private extension records.
getAvailableGroups() Gets the available group names.
filterByGroup(String groupName) Filters all vCard records by the group name passed as a parameter.
filterHomeTags() Filters all vCard records marked with the HOME tag.
filterWorkTags() Filters all vCard records marked with the WORK tag.
filterPreferred() Filters the preferred records.

getGeneralRecordset()

public final VCardGeneralRecordset getGeneralRecordset()

Gets the general records.

Returns: VCardGeneralRecordset - The general records.

getIdentificationRecordset()

public final VCardIdentificationRecordset getIdentificationRecordset()

Gets the identification records.

Returns: VCardIdentificationRecordset - The identification records.

getDeliveryAddressingRecordset()

public final VCardDeliveryAddressingRecordset getDeliveryAddressingRecordset()

Gets the delivery addressing records.

Returns: VCardDeliveryAddressingRecordset - The delivery addressing records.

getCommunicationRecordset()

public final VCardCommunicationRecordset getCommunicationRecordset()

Gets the communication records.

Returns: VCardCommunicationRecordset - The communication records.

getGeographicalRecordset()

public final VCardGeographicalRecordset getGeographicalRecordset()

Gets the geographical records.

Returns: VCardGeographicalRecordset - The geographical records.

getOrganizationalRecordset()

public final VCardOrganizationalRecordset getOrganizationalRecordset()

Gets the organizational records.

Returns: VCardOrganizationalRecordset - The organizational records.

getExplanatoryRecordset()

public final VCardExplanatoryRecordset getExplanatoryRecordset()

Gets the explanatory records.

Returns: VCardExplanatoryRecordset - The explanatory records.

getSecurityRecordset()

public final VCardSecurityRecordset getSecurityRecordset()

Gets the security records.

Returns: VCardSecurityRecordset - The security records.

getCalendarRecordset()

public final VCardCalendarRecordset getCalendarRecordset()

Gets the calendar records.

Returns: VCardCalendarRecordset - The calendar records.

getExtensionRecords()

public final VCardTextRecord[] getExtensionRecords()

Gets the private extension records.

Returns: com.groupdocs.metadata.core.VCardTextRecord[] - The private extension records.

getAvailableGroups()

public final String[] getAvailableGroups()

Gets the available group names.

Returns: java.lang.String[] - The available group names.

filterByGroup(String groupName)

public final VCardCard filterByGroup(String groupName)

Filters all vCard records by the group name passed as a parameter. For more information please see the method.

Parameters:

Parameter Type Description
groupName java.lang.String The name of the group.

Returns: VCardCard - The filtered vCard instance.

filterHomeTags()

public final VCardCard filterHomeTags()

Filters all vCard records marked with the HOME tag.

Returns: VCardCard - The filtered vCard instance.

filterWorkTags()

public final VCardCard filterWorkTags()

Filters all vCard records marked with the WORK tag.

Returns: VCardCard - Filtered vCard instance.

filterPreferred()

public final VCardCard filterPreferred()

Filters the preferred records.

Returns: VCardCard - The filtered vCard instance.