Skip to content

Commit

Permalink
fix(specs): proper title with linter (generated)
Browse files Browse the repository at this point in the history
algolia/api-clients-automation#3444

Co-authored-by: algolia-bot <accounts+algolia-api-client-bot@algolia.com>
Co-authored-by: Pierre Millot <pierre.millot@algolia.com>
  • Loading branch information
algolia-bot and millotp committed Jul 30, 2024
1 parent 67e1cb7 commit 47a89b2
Show file tree
Hide file tree
Showing 44 changed files with 583 additions and 311 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -683,8 +683,7 @@ public CompletableFuture<ConfigurationResponse> getConfigAsync(@Nonnull String i
* the transporter requestOptions.
* @throws AlgoliaRuntimeException If it fails to process the API call
*/
public GetConfigStatus200Response getConfigStatus(@Nonnull String indexName, RequestOptions requestOptions)
throws AlgoliaRuntimeException {
public ConfigStatus getConfigStatus(@Nonnull String indexName, RequestOptions requestOptions) throws AlgoliaRuntimeException {
return LaunderThrowable.await(getConfigStatusAsync(indexName, requestOptions));
}

Expand All @@ -694,7 +693,7 @@ public GetConfigStatus200Response getConfigStatus(@Nonnull String indexName, Req
* @param indexName Query Suggestions index name. (required)
* @throws AlgoliaRuntimeException If it fails to process the API call
*/
public GetConfigStatus200Response getConfigStatus(@Nonnull String indexName) throws AlgoliaRuntimeException {
public ConfigStatus getConfigStatus(@Nonnull String indexName) throws AlgoliaRuntimeException {
return this.getConfigStatus(indexName, null);
}

Expand All @@ -706,12 +705,12 @@ public GetConfigStatus200Response getConfigStatus(@Nonnull String indexName) thr
* the transporter requestOptions.
* @throws AlgoliaRuntimeException If it fails to process the API call
*/
public CompletableFuture<GetConfigStatus200Response> getConfigStatusAsync(@Nonnull String indexName, RequestOptions requestOptions)
public CompletableFuture<ConfigStatus> getConfigStatusAsync(@Nonnull String indexName, RequestOptions requestOptions)
throws AlgoliaRuntimeException {
Parameters.requireNonNull(indexName, "Parameter `indexName` is required when calling `getConfigStatus`.");

HttpRequest request = HttpRequest.builder().setPath("/1/configs/{indexName}/status", indexName).setMethod("GET").build();
return executeAsync(request, requestOptions, new TypeReference<GetConfigStatus200Response>() {});
return executeAsync(request, requestOptions, new TypeReference<ConfigStatus>() {});
}

/**
Expand All @@ -720,7 +719,7 @@ public CompletableFuture<GetConfigStatus200Response> getConfigStatusAsync(@Nonnu
* @param indexName Query Suggestions index name. (required)
* @throws AlgoliaRuntimeException If it fails to process the API call
*/
public CompletableFuture<GetConfigStatus200Response> getConfigStatusAsync(@Nonnull String indexName) throws AlgoliaRuntimeException {
public CompletableFuture<ConfigStatus> getConfigStatusAsync(@Nonnull String indexName) throws AlgoliaRuntimeException {
return this.getConfigStatusAsync(indexName, null);
}

Expand All @@ -732,7 +731,7 @@ public CompletableFuture<GetConfigStatus200Response> getConfigStatusAsync(@Nonnu
* the transporter requestOptions.
* @throws AlgoliaRuntimeException If it fails to process the API call
*/
public GetLogFile200Response getLogFile(@Nonnull String indexName, RequestOptions requestOptions) throws AlgoliaRuntimeException {
public LogFile getLogFile(@Nonnull String indexName, RequestOptions requestOptions) throws AlgoliaRuntimeException {
return LaunderThrowable.await(getLogFileAsync(indexName, requestOptions));
}

Expand All @@ -742,7 +741,7 @@ public GetLogFile200Response getLogFile(@Nonnull String indexName, RequestOption
* @param indexName Query Suggestions index name. (required)
* @throws AlgoliaRuntimeException If it fails to process the API call
*/
public GetLogFile200Response getLogFile(@Nonnull String indexName) throws AlgoliaRuntimeException {
public LogFile getLogFile(@Nonnull String indexName) throws AlgoliaRuntimeException {
return this.getLogFile(indexName, null);
}

Expand All @@ -754,13 +753,13 @@ public GetLogFile200Response getLogFile(@Nonnull String indexName) throws Algoli
* the transporter requestOptions.
* @throws AlgoliaRuntimeException If it fails to process the API call
*/
public CompletableFuture<GetLogFile200Response> getLogFileAsync(@Nonnull String indexName, RequestOptions requestOptions)
public CompletableFuture<LogFile> getLogFileAsync(@Nonnull String indexName, RequestOptions requestOptions)
throws AlgoliaRuntimeException {
Parameters.requireNonNull(indexName, "Parameter `indexName` is required when calling `getLogFile`.");

HttpRequest request = HttpRequest.builder().setPath("/1/logs/{indexName}", indexName).setMethod("GET").build();

return executeAsync(request, requestOptions, new TypeReference<GetLogFile200Response>() {});
return executeAsync(request, requestOptions, new TypeReference<LogFile>() {});
}

/**
Expand All @@ -769,7 +768,7 @@ public CompletableFuture<GetLogFile200Response> getLogFileAsync(@Nonnull String
* @param indexName Query Suggestions index name. (required)
* @throws AlgoliaRuntimeException If it fails to process the API call
*/
public CompletableFuture<GetLogFile200Response> getLogFileAsync(@Nonnull String indexName) throws AlgoliaRuntimeException {
public CompletableFuture<LogFile> getLogFileAsync(@Nonnull String indexName) throws AlgoliaRuntimeException {
return this.getLogFileAsync(indexName, null);
}

Expand Down
47 changes: 20 additions & 27 deletions algoliasearch/src/main/java/com/algolia/api/UsageClient.java
Original file line number Diff line number Diff line change
Expand Up @@ -594,7 +594,7 @@ public CompletableFuture<Object> customPutAsync(@Nonnull String path) throws Alg
* the transporter requestOptions.
* @throws AlgoliaRuntimeException If it fails to process the API call
*/
public GetUsage200Response getIndexUsage(
public IndexUsage getIndexUsage(
@Nonnull Statistic statistic,
@Nonnull String indexName,
@Nonnull String startDate,
Expand Down Expand Up @@ -735,7 +735,7 @@ public GetUsage200Response getIndexUsage(
* days. (optional, default to daily)
* @throws AlgoliaRuntimeException If it fails to process the API call
*/
public GetUsage200Response getIndexUsage(
public IndexUsage getIndexUsage(
@Nonnull Statistic statistic,
@Nonnull String indexName,
@Nonnull String startDate,
Expand Down Expand Up @@ -874,7 +874,7 @@ public GetUsage200Response getIndexUsage(
* the transporter requestOptions.
* @throws AlgoliaRuntimeException If it fails to process the API call
*/
public GetUsage200Response getIndexUsage(
public IndexUsage getIndexUsage(
@Nonnull Statistic statistic,
@Nonnull String indexName,
@Nonnull String startDate,
Expand Down Expand Up @@ -1011,7 +1011,7 @@ public GetUsage200Response getIndexUsage(
* @param endDate End date of the period to analyze, in `YYYY-MM-DD` format. (required)
* @throws AlgoliaRuntimeException If it fails to process the API call
*/
public GetUsage200Response getIndexUsage(
public IndexUsage getIndexUsage(
@Nonnull Statistic statistic,
@Nonnull String indexName,
@Nonnull String startDate,
Expand Down Expand Up @@ -1152,7 +1152,7 @@ public GetUsage200Response getIndexUsage(
* the transporter requestOptions.
* @throws AlgoliaRuntimeException If it fails to process the API call
*/
public CompletableFuture<GetUsage200Response> getIndexUsageAsync(
public CompletableFuture<IndexUsage> getIndexUsageAsync(
@Nonnull Statistic statistic,
@Nonnull String indexName,
@Nonnull String startDate,
Expand All @@ -1175,7 +1175,7 @@ public CompletableFuture<GetUsage200Response> getIndexUsageAsync(
.addQueryParameter("endDate", endDate)
.addQueryParameter("granularity", granularity)
.build();
return executeAsync(request, requestOptions, new TypeReference<GetUsage200Response>() {});
return executeAsync(request, requestOptions, new TypeReference<IndexUsage>() {});
}

/**
Expand Down Expand Up @@ -1308,7 +1308,7 @@ public CompletableFuture<GetUsage200Response> getIndexUsageAsync(
* days. (optional, default to daily)
* @throws AlgoliaRuntimeException If it fails to process the API call
*/
public CompletableFuture<GetUsage200Response> getIndexUsageAsync(
public CompletableFuture<IndexUsage> getIndexUsageAsync(
@Nonnull Statistic statistic,
@Nonnull String indexName,
@Nonnull String startDate,
Expand Down Expand Up @@ -1447,7 +1447,7 @@ public CompletableFuture<GetUsage200Response> getIndexUsageAsync(
* the transporter requestOptions.
* @throws AlgoliaRuntimeException If it fails to process the API call
*/
public CompletableFuture<GetUsage200Response> getIndexUsageAsync(
public CompletableFuture<IndexUsage> getIndexUsageAsync(
@Nonnull Statistic statistic,
@Nonnull String indexName,
@Nonnull String startDate,
Expand Down Expand Up @@ -1584,7 +1584,7 @@ public CompletableFuture<GetUsage200Response> getIndexUsageAsync(
* @param endDate End date of the period to analyze, in `YYYY-MM-DD` format. (required)
* @throws AlgoliaRuntimeException If it fails to process the API call
*/
public CompletableFuture<GetUsage200Response> getIndexUsageAsync(
public CompletableFuture<IndexUsage> getIndexUsageAsync(
@Nonnull Statistic statistic,
@Nonnull String indexName,
@Nonnull String startDate,
Expand Down Expand Up @@ -1724,7 +1724,7 @@ public CompletableFuture<GetUsage200Response> getIndexUsageAsync(
* the transporter requestOptions.
* @throws AlgoliaRuntimeException If it fails to process the API call
*/
public GetUsage200Response getUsage(
public IndexUsage getUsage(
@Nonnull Statistic statistic,
@Nonnull String startDate,
@Nonnull String endDate,
Expand Down Expand Up @@ -1863,12 +1863,8 @@ public GetUsage200Response getUsage(
* days. (optional, default to daily)
* @throws AlgoliaRuntimeException If it fails to process the API call
*/
public GetUsage200Response getUsage(
@Nonnull Statistic statistic,
@Nonnull String startDate,
@Nonnull String endDate,
Granularity granularity
) throws AlgoliaRuntimeException {
public IndexUsage getUsage(@Nonnull Statistic statistic, @Nonnull String startDate, @Nonnull String endDate, Granularity granularity)
throws AlgoliaRuntimeException {
return this.getUsage(statistic, startDate, endDate, granularity, null);
}

Expand Down Expand Up @@ -2000,7 +1996,7 @@ public GetUsage200Response getUsage(
* the transporter requestOptions.
* @throws AlgoliaRuntimeException If it fails to process the API call
*/
public GetUsage200Response getUsage(
public IndexUsage getUsage(
@Nonnull Statistic statistic,
@Nonnull String startDate,
@Nonnull String endDate,
Expand Down Expand Up @@ -2135,7 +2131,7 @@ public GetUsage200Response getUsage(
* @param endDate End date of the period to analyze, in `YYYY-MM-DD` format. (required)
* @throws AlgoliaRuntimeException If it fails to process the API call
*/
public GetUsage200Response getUsage(@Nonnull Statistic statistic, @Nonnull String startDate, @Nonnull String endDate)
public IndexUsage getUsage(@Nonnull Statistic statistic, @Nonnull String startDate, @Nonnull String endDate)
throws AlgoliaRuntimeException {
return this.getUsage(statistic, startDate, endDate, null, null);
}
Expand Down Expand Up @@ -2271,7 +2267,7 @@ public GetUsage200Response getUsage(@Nonnull Statistic statistic, @Nonnull Strin
* the transporter requestOptions.
* @throws AlgoliaRuntimeException If it fails to process the API call
*/
public CompletableFuture<GetUsage200Response> getUsageAsync(
public CompletableFuture<IndexUsage> getUsageAsync(
@Nonnull Statistic statistic,
@Nonnull String startDate,
@Nonnull String endDate,
Expand All @@ -2291,7 +2287,7 @@ public CompletableFuture<GetUsage200Response> getUsageAsync(
.addQueryParameter("endDate", endDate)
.addQueryParameter("granularity", granularity)
.build();
return executeAsync(request, requestOptions, new TypeReference<GetUsage200Response>() {});
return executeAsync(request, requestOptions, new TypeReference<IndexUsage>() {});
}

/**
Expand Down Expand Up @@ -2423,7 +2419,7 @@ public CompletableFuture<GetUsage200Response> getUsageAsync(
* days. (optional, default to daily)
* @throws AlgoliaRuntimeException If it fails to process the API call
*/
public CompletableFuture<GetUsage200Response> getUsageAsync(
public CompletableFuture<IndexUsage> getUsageAsync(
@Nonnull Statistic statistic,
@Nonnull String startDate,
@Nonnull String endDate,
Expand Down Expand Up @@ -2560,7 +2556,7 @@ public CompletableFuture<GetUsage200Response> getUsageAsync(
* the transporter requestOptions.
* @throws AlgoliaRuntimeException If it fails to process the API call
*/
public CompletableFuture<GetUsage200Response> getUsageAsync(
public CompletableFuture<IndexUsage> getUsageAsync(
@Nonnull Statistic statistic,
@Nonnull String startDate,
@Nonnull String endDate,
Expand Down Expand Up @@ -2695,11 +2691,8 @@ public CompletableFuture<GetUsage200Response> getUsageAsync(
* @param endDate End date of the period to analyze, in `YYYY-MM-DD` format. (required)
* @throws AlgoliaRuntimeException If it fails to process the API call
*/
public CompletableFuture<GetUsage200Response> getUsageAsync(
@Nonnull Statistic statistic,
@Nonnull String startDate,
@Nonnull String endDate
) throws AlgoliaRuntimeException {
public CompletableFuture<IndexUsage> getUsageAsync(@Nonnull Statistic statistic, @Nonnull String startDate, @Nonnull String endDate)
throws AlgoliaRuntimeException {
return this.getUsageAsync(statistic, startDate, endDate, null, null);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,15 @@
import java.util.Objects;

/** Empty searches removed from the A/B test as a result of configuration settings. */
public class FilterEffectsEmptySearch {
public class EmptySearchFilter {

@JsonProperty("usersCount")
private Integer usersCount;

@JsonProperty("trackedSearchesCount")
private Integer trackedSearchesCount;

public FilterEffectsEmptySearch setUsersCount(Integer usersCount) {
public EmptySearchFilter setUsersCount(Integer usersCount) {
this.usersCount = usersCount;
return this;
}
Expand All @@ -27,7 +27,7 @@ public Integer getUsersCount() {
return usersCount;
}

public FilterEffectsEmptySearch setTrackedSearchesCount(Integer trackedSearchesCount) {
public EmptySearchFilter setTrackedSearchesCount(Integer trackedSearchesCount) {
this.trackedSearchesCount = trackedSearchesCount;
return this;
}
Expand All @@ -46,10 +46,10 @@ public boolean equals(Object o) {
if (o == null || getClass() != o.getClass()) {
return false;
}
FilterEffectsEmptySearch filterEffectsEmptySearch = (FilterEffectsEmptySearch) o;
EmptySearchFilter emptySearchFilter = (EmptySearchFilter) o;
return (
Objects.equals(this.usersCount, filterEffectsEmptySearch.usersCount) &&
Objects.equals(this.trackedSearchesCount, filterEffectsEmptySearch.trackedSearchesCount)
Objects.equals(this.usersCount, emptySearchFilter.usersCount) &&
Objects.equals(this.trackedSearchesCount, emptySearchFilter.trackedSearchesCount)
);
}

Expand All @@ -61,7 +61,7 @@ public int hashCode() {
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class FilterEffectsEmptySearch {\n");
sb.append("class EmptySearchFilter {\n");
sb.append(" usersCount: ").append(toIndentedString(usersCount)).append("\n");
sb.append(" trackedSearchesCount: ").append(toIndentedString(trackedSearchesCount)).append("\n");
sb.append("}");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,30 +11,30 @@
public class FilterEffects {

@JsonProperty("outliers")
private FilterEffectsOutliers outliers;
private OutliersFilter outliers;

@JsonProperty("emptySearch")
private FilterEffectsEmptySearch emptySearch;
private EmptySearchFilter emptySearch;

public FilterEffects setOutliers(FilterEffectsOutliers outliers) {
public FilterEffects setOutliers(OutliersFilter outliers) {
this.outliers = outliers;
return this;
}

/** Get outliers */
@javax.annotation.Nullable
public FilterEffectsOutliers getOutliers() {
public OutliersFilter getOutliers() {
return outliers;
}

public FilterEffects setEmptySearch(FilterEffectsEmptySearch emptySearch) {
public FilterEffects setEmptySearch(EmptySearchFilter emptySearch) {
this.emptySearch = emptySearch;
return this;
}

/** Get emptySearch */
@javax.annotation.Nullable
public FilterEffectsEmptySearch getEmptySearch() {
public EmptySearchFilter getEmptySearch() {
return emptySearch;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,15 @@
import java.util.Objects;

/** Outliers removed from the A/B test as a result of configuration settings. */
public class FilterEffectsOutliers {
public class OutliersFilter {

@JsonProperty("usersCount")
private Integer usersCount;

@JsonProperty("trackedSearchesCount")
private Integer trackedSearchesCount;

public FilterEffectsOutliers setUsersCount(Integer usersCount) {
public OutliersFilter setUsersCount(Integer usersCount) {
this.usersCount = usersCount;
return this;
}
Expand All @@ -27,7 +27,7 @@ public Integer getUsersCount() {
return usersCount;
}

public FilterEffectsOutliers setTrackedSearchesCount(Integer trackedSearchesCount) {
public OutliersFilter setTrackedSearchesCount(Integer trackedSearchesCount) {
this.trackedSearchesCount = trackedSearchesCount;
return this;
}
Expand All @@ -46,10 +46,10 @@ public boolean equals(Object o) {
if (o == null || getClass() != o.getClass()) {
return false;
}
FilterEffectsOutliers filterEffectsOutliers = (FilterEffectsOutliers) o;
OutliersFilter outliersFilter = (OutliersFilter) o;
return (
Objects.equals(this.usersCount, filterEffectsOutliers.usersCount) &&
Objects.equals(this.trackedSearchesCount, filterEffectsOutliers.trackedSearchesCount)
Objects.equals(this.usersCount, outliersFilter.usersCount) &&
Objects.equals(this.trackedSearchesCount, outliersFilter.trackedSearchesCount)
);
}

Expand All @@ -61,7 +61,7 @@ public int hashCode() {
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class FilterEffectsOutliers {\n");
sb.append("class OutliersFilter {\n");
sb.append(" usersCount: ").append(toIndentedString(usersCount)).append("\n");
sb.append(" trackedSearchesCount: ").append(toIndentedString(trackedSearchesCount)).append("\n");
sb.append("}");
Expand Down
Loading

0 comments on commit 47a89b2

Please sign in to comment.