Add constructor IndexRequest(String index, String type) and fix javadoc

This commit is contained in:
David Pilato 2012-09-25 13:16:08 +02:00 committed by Shay Banon
parent b2597b5316
commit 83257c8af8
1 changed files with 11 additions and 2 deletions

View File

@ -133,13 +133,22 @@ public class IndexRequest extends ShardReplicationOperationRequest<IndexRequest>
} }
/** /**
* Constructs a new index request against the specific index. The {@link #type(String)}, * Constructs a new index request against the specific index. The {@link #type(String)}
* {@link #id(String)} and {@link #source(byte[])} must be set. * {@link #source(byte[])} must be set.
*/ */
public IndexRequest(String index) { public IndexRequest(String index) {
this.index = index; this.index = index;
} }
/**
* Constructs a new index request against the specific index and type. The
* {@link #source(byte[])} must be set.
*/
public IndexRequest(String index, String type) {
this.index = index;
this.type = type;
}
/** /**
* Constructs a new index request against the index, type, id and using the source. * Constructs a new index request against the index, type, id and using the source.
* *