public class Xml extends SimpleProperty<org.w3c.dom.Document> implements HasAltId
Contains an XML element that was not recognized when parsing an xCard (XML-formatted vCard).
Code sample
VCard vcard = new VCard(); Xml xml = new Xml("<b>Some xml</b>"); vcard.addXml(xml);
Property name: XML
Supported versions: 4.0
value
group, parameters
Constructor and Description |
---|
Xml(org.w3c.dom.Document document)
Creates an XML property.
|
Xml(org.w3c.dom.Element element)
Creates an XML property.
|
Xml(java.lang.String xml)
Creates an XML property.
|
Modifier and Type | Method and Description |
---|---|
java.util.Set<VCardVersion> |
_supportedVersions()
Gets the vCard versions that support this property.
|
java.lang.String |
getAltId()
Gets the property's ALTID parameter.
|
void |
setAltId(java.lang.String altId)
Sets the property's ALTID parameter.
|
_validate, getValue, setValue
addParameter, compareTo, getGroup, getParameter, getParameters, getParameters, getSupportedVersions, removeParameter, setGroup, setParameter, setParameters, validate
public Xml(java.lang.String xml) throws org.xml.sax.SAXException
xml
- the XML to use as the property's valueorg.xml.sax.SAXException
- if the XML cannot be parsedpublic Xml(org.w3c.dom.Element element)
element
- the XML element to use as the property's value (the
element is imported into an empty Document
object)public Xml(org.w3c.dom.Document document)
document
- the XML document to use as the property's valuepublic java.util.Set<VCardVersion> _supportedVersions()
VCardProperty
Gets the vCard versions that support this property.
This method should be overridden by child classes if the property does not support all vCard versions. The default implementation of this method returns all vCard versions.
_supportedVersions
in class VCardProperty
public java.lang.String getAltId()
HasAltId
Supported versions: 4.0
getAltId
in interface HasAltId
VCardParameters.getAltId()
public void setAltId(java.lang.String altId)
HasAltId
Supported versions: 4.0
setAltId
in interface HasAltId
altId
- the ALTID or null to removeVCardParameters.setAltId(java.lang.String)
This software is published under the BSD license. Copyright © 2003-${build.year}, CRIXP AG, Switzerland, All rights reserved. Use is subject to license terms.