-
Notifications
You must be signed in to change notification settings - Fork 115
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
8 changed files
with
133 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
package com.meilisearch.sdk; | ||
|
||
import org.json.JSONObject; | ||
|
||
public class FederationOptions { | ||
|
||
private Double weight; | ||
|
||
public FederationOptions setWeight(Double weight) { | ||
this.weight = weight; | ||
return this; | ||
} | ||
|
||
/** | ||
* Method that returns the JSON String of the FederationOptions | ||
* | ||
* @return JSON String of the FederationOptions | ||
*/ | ||
@Override | ||
public String toString() { | ||
JSONObject jsonObject = new JSONObject().put("weight", this.weight); | ||
return jsonObject.toString(); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
39 changes: 39 additions & 0 deletions
39
src/main/java/com/meilisearch/sdk/MultiSearchFederation.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
package com.meilisearch.sdk; | ||
|
||
import org.json.JSONObject; | ||
|
||
public class MultiSearchFederation { | ||
|
||
private Integer limit; | ||
private Integer offset; | ||
|
||
public MultiSearchFederation setLimit(Integer limit) { | ||
this.limit = limit; | ||
return this; | ||
} | ||
|
||
public MultiSearchFederation setOffset(Integer offset) { | ||
this.offset = offset; | ||
return this; | ||
} | ||
|
||
public Integer getLimit() { | ||
return this.limit; | ||
} | ||
|
||
public Integer getOffset() { | ||
return this.offset; | ||
} | ||
|
||
/** | ||
* Method that returns the JSON String of the MultiSearchFederation | ||
* | ||
* @return JSON String of the MultiSearchFederation | ||
*/ | ||
@Override | ||
public String toString() { | ||
JSONObject jsonObject = | ||
new JSONObject().put("limit", this.limit).put("offset", this.offset); | ||
return jsonObject.toString(); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters