public Document document(int n, FieldSelector fieldSelector) throws CorruptIndexException, IOException { Document doc = super.document(n, fieldSelector); Fieldable[] fields = doc.getFieldables(FieldNames.PROPERTIES); if (fields != null) { doc.removeFields(FieldNames.PROPERTIES); for (int i = 0; i < fields.length; i++) { String value = fields[i].stringValue(); value = value.replace('\uFFFF', '['); doc.add(new Field(FieldNames.PROPERTIES, value, Field.Store.YES, Field.Index.NOT_ANALYZED_NO_NORMS)); } } return doc; }
@Override public Document document(int n, FieldSelector fieldSelector) throws CorruptIndexException, IOException { Document doc = super.document(n, fieldSelector); Fieldable[] fields = doc.getFieldables(FieldNames.PROPERTIES); if (fields != null) { doc.removeFields(FieldNames.PROPERTIES); for (Fieldable field : fields) { String value = field.stringValue(); value = value.replace(oldSepChar, '['); doc.add(new Field(FieldNames.PROPERTIES, false, value, Field.Store.YES, Field.Index.NOT_ANALYZED_NO_NORMS, Field.TermVector.NO)); } } return doc; }
@Override public Document document(int n, FieldSelector fieldSelector) throws CorruptIndexException, IOException { Document doc = super.document(n, fieldSelector); Fieldable[] fields = doc.getFieldables(FieldNames.PROPERTIES); if (fields != null) { doc.removeFields(FieldNames.PROPERTIES); for (Fieldable field : fields) { String value = field.stringValue(); value = value.replace(oldSepChar, '['); doc.add(new Field(FieldNames.PROPERTIES, false, value, Field.Store.YES, Field.Index.NOT_ANALYZED_NO_NORMS, Field.TermVector.NO)); } } return doc; }
Fieldable[] values = document.getFieldables(field); Object comparable = null; for (Fieldable field : values)
protected final String getIndexedId(Document doc) { if (idField == null) throw new SolrException( SolrException.ErrorCode.BAD_REQUEST,"Operation requires schema to have a unique key field"); // Right now, single valued fields that require value transformation from external to internal (indexed) // form have that transformation already performed and stored as the field value. Fieldable[] id = doc.getFieldables( idField.getName() ); if (id == null || id.length < 1) throw new SolrException( SolrException.ErrorCode.BAD_REQUEST,"Document is missing uniqueKey field " + idField.getName()); if( id.length > 1 ) throw new SolrException( SolrException.ErrorCode.BAD_REQUEST,"Document specifies multiple unique ids! " + idField.getName()); return idFieldType.storedToIndexed( id[0] ); }
Fieldable[] fields = doc.getFieldables(FieldNames.FULLTEXT);
tDocs.close(); Fieldable[] fields = doc.getFieldables(FieldNames.FULLTEXT); if (fields.length == 0) { log.debug("Fulltext field not stored, using {}",
tDocs.close(); Fieldable[] fields = doc.getFieldables(FieldNames.FULLTEXT); if (fields.length == 0) { log.debug("Fulltext field not stored, using {}",
if (aggregates != null) Fieldable[] fulltext = doc.getFieldables(FieldNames.FULLTEXT); if (fulltext != null) createDocument(aggregates[j], getNamespaceMappings(), index.getIndexFormatVersion(), loadAllProperties); Fieldable[] fulltextFields = aDoc.getFieldables(FieldNames.FULLTEXT); if (fulltextFields != null) Fieldable[] fields = aDoc.getFieldables(FieldNames.PROPERTIES); for (int k = 0; k < fields.length; k++)
Document aDoc = createDocument(aggregate, getNamespaceMappings(), ifv); Fieldable[] fulltextFields = aDoc.getFieldables(FieldNames.FULLTEXT); if (fulltextFields != null) { for (Fieldable fulltextField : fulltextFields) { .getFieldables(FieldNames.FULLTEXT); doc.removeFields(FieldNames.FULLTEXT); Arrays.sort(fulltextFields, FIELDS_COMPARATOR_STORED); try { Fieldable[] fields = aDoc.getFieldables(FieldNames.PROPERTIES); for (Fieldable field : fields) {
Fieldable[] fulltextFields = aDoc.getFieldables(FieldNames.FULLTEXT); if (fulltextFields != null) { for (final Fieldable fulltextField : fulltextFields) { Fieldable[] aggrNodeUUID = aDoc.getFieldables(FieldNames.AGGREGATED_NODE_UUID); if (aggrNodeUUID != null) { for (Fieldable f : aggrNodeUUID) {
Document aDoc = createDocument(aggregate, getNamespaceMappings(), ifv); Fieldable[] fulltextFields = aDoc.getFieldables(FieldNames.FULLTEXT); if (fulltextFields != null) { for (Fieldable fulltextField : fulltextFields) { .getFieldables(FieldNames.FULLTEXT); doc.removeFields(FieldNames.FULLTEXT); Arrays.sort(fulltextFields, FIELDS_COMPARATOR_STORED); try { Fieldable[] fields = aDoc.getFieldables(FieldNames.PROPERTIES); for (Fieldable field : fields) {