APISonar


net.yacy.cora.federate.solr.SolrType.date

> net > yacy > cora > federate > solr > SolrType > date
net APIs yacy APIs cora APIs federate APIs solr APIs SolrType APIs date APIs

Example 1
private Date[] getDates(CollectionSchema field) {
        assert field.isMultiValued();
        assert field.getType() == SolrType.date;
        @SuppressWarnings("unchecked")
        List<Date> x = (List<Date>) this.getFieldValue(field.getSolrFieldName());
        if (x == null) return new Date[0];
        return x.toArray(new Date[x.size()]);
    }
Example 2
public final void add(final SolrInputDocument doc, final Date value) {
        assert !this.isMultiValued();
        assert this.type == SolrType.date;
        doc.setField(this.getSolrFieldName(), value);
    }
Example 3
public YearNavigator(final String title, final CollectionSchema field, final NavigatorSort sort) {
        super(title, field, sort == null ? NavigatorSort.LABEL_DESC : sort);
        if (field.getType() != SolrType.date) throw new IllegalArgumentException("field is not of type Date");
    }