public void setVCard(VCard vCard) throws XmppException {
if (vCard == null) {
throw new IllegalArgumentException("vCard must not be null.");
}
// Update the vCard
xmppSession.query(new IQ(IQ.Type.SET, vCard));
// Then inform about the update by sending a presence. The avatar manager will add the update extension.
AvatarManager avatarManager = xmppSession.getExtensionManager(AvatarManager.class);
if (isEnabled() && avatarManager.isEnabled()) {
Presence presence = xmppSession.getPresenceManager().getLastSentPresence();