Example #1
0
 /// <summary>Creates a sort, possibly in reverse, with a custom comparison function.</summary>
 /// <param name="field">Name of field to sort by; cannot be <code>null</code>.
 /// </param>
 /// <param name="comparator">Returns a comparator for sorting hits.
 /// </param>
 /// <param name="reverse">True if natural order should be reversed.
 /// </param>
 public SortField(System.String field, FieldComparatorSource comparator, bool reverse)
 {
     InitFieldType(field, CUSTOM);
     this.reverse          = reverse;
     this.comparatorSource = comparator;
 }
Example #2
0
		/// <summary>Creates a sort, possibly in reverse, with a custom comparison function.</summary>
		/// <param name="field">Name of field to sort by; cannot be <code>null</code>.
		/// </param>
		/// <param name="comparator">Returns a comparator for sorting hits.
		/// </param>
		/// <param name="reverse">True if natural order should be reversed.
		/// </param>
		public SortField(System.String field, FieldComparatorSource comparator, bool reverse)
		{
			InitFieldType(field, CUSTOM);
			this.reverse = reverse;
			this.comparatorSource = comparator;
		}
Example #3
0
 /// <summary>Creates a sort with a custom comparison function.</summary>
 /// <param name="field">Name of field to sort by; cannot be <code>null</code>.
 /// </param>
 /// <param name="comparator">Returns a comparator for sorting hits.
 /// </param>
 public SortField(System.String field, FieldComparatorSource comparator)
 {
     InitFieldType(field, CUSTOM);
     this.comparatorSource = comparator;
 }
Example #4
0
		/// <summary>Creates a sort with a custom comparison function.</summary>
		/// <param name="field">Name of field to sort by; cannot be <code>null</code>.
		/// </param>
		/// <param name="comparator">Returns a comparator for sorting hits.
		/// </param>
		public SortField(System.String field, FieldComparatorSource comparator)
		{
			InitFieldType(field, CUSTOM);
			this.comparatorSource = comparator;
		}