com.basistech.rosette.apimodel.LanguageResponse Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of rosette-api-all Show documentation
Show all versions of rosette-api-all Show documentation
Babel Street Analytics API all modules combined
The newest version!
// Generated by delombok at Fri Nov 15 11:56:46 CST 2024
/*
* Copyright 2017 Basis Technology Corp.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package com.basistech.rosette.apimodel;
import com.basistech.rosette.annotations.JacksonMixin;
import java.util.List;
/**
* Simple api response data model for Rli
*/
@JacksonMixin
public class LanguageResponse extends Response {
/**
*/
private final List languageDetections;
/**
*/
private final List regionalDetections;
@SuppressWarnings("all")
LanguageResponse(final List languageDetections, final List regionalDetections) {
this.languageDetections = languageDetections;
this.regionalDetections = regionalDetections;
}
@SuppressWarnings("all")
public static class LanguageResponseBuilder {
@SuppressWarnings("all")
private List languageDetections;
@SuppressWarnings("all")
private List regionalDetections;
@SuppressWarnings("all")
LanguageResponseBuilder() {
}
/**
* @return {@code this}.
*/
@SuppressWarnings("all")
public LanguageResponse.LanguageResponseBuilder languageDetections(final List languageDetections) {
this.languageDetections = languageDetections;
return this;
}
/**
* @return {@code this}.
*/
@SuppressWarnings("all")
public LanguageResponse.LanguageResponseBuilder regionalDetections(final List regionalDetections) {
this.regionalDetections = regionalDetections;
return this;
}
@SuppressWarnings("all")
public LanguageResponse build() {
return new LanguageResponse(this.languageDetections, this.regionalDetections);
}
@Override
@SuppressWarnings("all")
public String toString() {
return "LanguageResponse.LanguageResponseBuilder(languageDetections=" + this.languageDetections + ", regionalDetections=" + this.regionalDetections + ")";
}
}
@SuppressWarnings("all")
public static LanguageResponse.LanguageResponseBuilder builder() {
return new LanguageResponse.LanguageResponseBuilder();
}
/**
* @return the list of detected whole-document languages
*/
@SuppressWarnings("all")
public List getLanguageDetections() {
return this.languageDetections;
}
/**
* @return the list of detected language regions
*/
@SuppressWarnings("all")
public List getRegionalDetections() {
return this.regionalDetections;
}
@Override
@SuppressWarnings("all")
public boolean equals(final Object o) {
if (o == this) return true;
if (!(o instanceof LanguageResponse)) return false;
final LanguageResponse other = (LanguageResponse) o;
if (!other.canEqual((Object) this)) return false;
if (!super.equals(o)) return false;
final Object this$languageDetections = this.getLanguageDetections();
final Object other$languageDetections = other.getLanguageDetections();
if (this$languageDetections == null ? other$languageDetections != null : !this$languageDetections.equals(other$languageDetections)) return false;
final Object this$regionalDetections = this.getRegionalDetections();
final Object other$regionalDetections = other.getRegionalDetections();
if (this$regionalDetections == null ? other$regionalDetections != null : !this$regionalDetections.equals(other$regionalDetections)) return false;
return true;
}
@SuppressWarnings("all")
protected boolean canEqual(final Object other) {
return other instanceof LanguageResponse;
}
@Override
@SuppressWarnings("all")
public int hashCode() {
final int PRIME = 59;
int result = super.hashCode();
final Object $languageDetections = this.getLanguageDetections();
result = result * PRIME + ($languageDetections == null ? 43 : $languageDetections.hashCode());
final Object $regionalDetections = this.getRegionalDetections();
result = result * PRIME + ($regionalDetections == null ? 43 : $regionalDetections.hashCode());
return result;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy