}
else {
sendIndentedElement("psv:facets");
if (facets != null) {
for (int i = 0; i < facets.getLength(); i++) {
XSFacet facet = (XSFacet)facets.item(i);
String name = this.translateFacetKind(facet.getFacetKind());
sendIndentedElement("psv:" + name);
sendElementEvent("psv:value", facet.getLexicalFacetValue());
sendElementEvent(
"psv:fixed",
String.valueOf(facet.getFixed()));
processPSVIAnnotation(facet.getAnnotation());
sendUnIndentedElement("psv:" + name);
}
}
if (multiValueFacets != null) {
for (int i = 0; i < multiValueFacets.getLength(); i++) {
XSMultiValueFacet facet =
(XSMultiValueFacet)multiValueFacets.item(i);
String name = this.translateFacetKind(facet.getFacetKind());
sendIndentedElement("psv:" + name);
StringList values = facet.getLexicalFacetValues();
for (int j = 0; j < values.getLength(); j++) {
sendElementEvent("psv:value", values.item(j));
}
sendElementEvent("psv:fixed", "false");
processPSVIAnnotations(facet.getAnnotations());
sendUnIndentedElement("psv:" + name);
}
}
sendUnIndentedElement("psv:facets");
}