Skip to content

Commit

Permalink
feat: custom requests (#757)
Browse files Browse the repository at this point in the history
  • Loading branch information
aallam committed Oct 18, 2021
1 parent 6661b67 commit 6e7d842
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,12 @@
import com.algolia.search.exceptions.LaunderThrowable;
import com.algolia.search.models.HttpMethod;
import com.algolia.search.models.RequestOptions;
import com.algolia.search.models.analytics.*;
import com.algolia.search.models.analytics.ABTest;
import com.algolia.search.models.analytics.ABTestResponse;
import com.algolia.search.models.analytics.ABTests;
import com.algolia.search.models.analytics.AddABTestResponse;
import com.algolia.search.models.analytics.DeleteAbTestResponse;
import com.algolia.search.models.analytics.StopAbTestResponse;
import com.algolia.search.models.common.CallType;
import java.io.Closeable;
import java.io.IOException;
Expand Down Expand Up @@ -67,6 +72,11 @@ public ConfigBase getConfig() {
return config;
}

/** Transport object responsible for the serialization/deserialization and the retry strategy. */
public HttpTransport getTransport() {
return transport;
}

/** Get an A/B test information and results. */
public ABTests getABTests() {
return LaunderThrowable.await(getABTestsAsync(0, 10, null));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,11 @@ public ConfigBase getConfig() {
return config;
}

/** Transport object responsible for the serialization/deserialization and the retry strategy. */
public HttpTransport getTransport() {
return transport;
}

/** @param userToken the user config */
public UserInsightsClient user(@Nonnull String userToken) {
return new UserInsightsClient(userToken, this);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,11 @@ public void close() throws IOException {
transport.close();
}

/** Transport object responsible for the serialization/deserialization and the retry strategy. */
public HttpTransport getTransport() {
return transport;
}

/**
* Returns the personalization strategy of the application
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ public void close() throws IOException {
transport.close();
}

/** Transport object responsible for the serialization/deserialization and the retry strategy. */
public HttpTransport getTransport() {
return transport;
}
Expand Down

0 comments on commit 6e7d842

Please sign in to comment.