use of ezvcard.io.xml.XCardDocument in project ez-vcard by mangstadt.
the class ChainingXmlWriter method createXCardDocument.
private XCardDocument createXCardDocument() {
XCardDocument document = new XCardDocument();
XCardDocumentStreamWriter writer = document.writer();
writer.setAddProdId(prodId);
writer.setVersionStrict(versionStrict);
for (Map.Entry<String, VCardDataType> entry : parameterDataTypes.entrySet()) {
String parameterName = entry.getKey();
VCardDataType dataType = entry.getValue();
writer.registerParameterDataType(parameterName, dataType);
}
if (index != null) {
writer.setScribeIndex(index);
}
for (VCard vcard : vcards) {
writer.write(vcard);
}
return document;
}
Aggregations