java.lang.Object
it.auties.whatsapp.model.contact.ContactCard
- All Implemented Interfaces:
it.auties.protobuf.base.ProtobufMessage
A model class to represent and build the vcard of a contact
-
Nested Class Summary
-
Method Summary
Modifier and TypeMethodDescriptionbuilder()
Returns the business name of this card if definedstatic ContactCard
boolean
int
hashCode()
boolean
name()
Returns the name of this card if definedstatic ContactCard
Parses a vcardstatic ContactCard
@NonNull Map<String,
ContactJid> The phone numbers, ordered by typetoString()
Converts this object in a valid vcardtoValue()
Converts this object in a valid vcardtoVcard()
Converts this object in a valid vcardversion()
Returns the version of this card if defined
-
Method Details
-
of
Parses a vcard- Parameters:
vcard
- the non-null vcard to parse- Returns:
- a non-null vcard
-
convert
-
version
Returns the version of this card if defined- Returns:
- an optional
-
name
Returns the name of this card if defined- Returns:
- an optional
-
businessName
Returns the business name of this card if defined- Returns:
- an optional
-
toVcard
Converts this object in a valid vcard- Returns:
- a non-null String
-
toString
Converts this object in a valid vcard -
toValue
Converts this object in a valid vcard- Specified by:
toValue
in interfaceit.auties.protobuf.base.ProtobufMessage
- Returns:
- a non-null String
-
isValueBased
public boolean isValueBased()- Specified by:
isValueBased
in interfaceit.auties.protobuf.base.ProtobufMessage
-
builder
-
phoneNumbers
The phone numbers, ordered by type -
equals
-
hashCode
public int hashCode() -
of
public static ContactCard of(String version, String name, @NonNull @NonNull Map<String, ContactJid> phoneNumbers, String businessName)
-