Search in sources :

Example 21 with EqualsBuilder

use of org.apache.commons.lang3.builder.EqualsBuilder in project cas by apereo.

the class OidcRegisteredService method equals.

@Override
public boolean equals(final Object obj) {
    if (obj == null) {
        return false;
    }
    if (obj == this) {
        return true;
    }
    if (obj.getClass() != getClass()) {
        return false;
    }
    final OidcRegisteredService rhs = (OidcRegisteredService) obj;
    final EqualsBuilder builder = new EqualsBuilder();
    return builder.appendSuper(super.equals(obj)).append(this.jwks, rhs.jwks).append(this.implicit, rhs.implicit).append(this.signIdToken, rhs.signIdToken).append(this.encryptIdToken, rhs.encryptIdToken).append(this.idTokenEncryptionAlg, rhs.idTokenEncryptionAlg).append(this.idTokenEncryptionEncoding, rhs.idTokenEncryptionEncoding).append(this.getScopes(), rhs.getScopes()).isEquals();
}
Also used : EqualsBuilder(org.apache.commons.lang3.builder.EqualsBuilder)

Example 22 with EqualsBuilder

use of org.apache.commons.lang3.builder.EqualsBuilder in project cas by apereo.

the class YubiKeyCredential method equals.

@Override
public boolean equals(final Object obj) {
    if (!(obj instanceof YubiKeyCredential)) {
        return false;
    }
    if (obj == this) {
        return true;
    }
    final YubiKeyCredential other = (YubiKeyCredential) obj;
    final EqualsBuilder builder = new EqualsBuilder();
    builder.append(this.token, other.token);
    return builder.isEquals();
}
Also used : EqualsBuilder(org.apache.commons.lang3.builder.EqualsBuilder)

Example 23 with EqualsBuilder

use of org.apache.commons.lang3.builder.EqualsBuilder in project cas by apereo.

the class AuthyTokenCredential method equals.

@Override
public boolean equals(final Object obj) {
    if (!(obj instanceof AuthyTokenCredential)) {
        return false;
    }
    if (obj == this) {
        return true;
    }
    final AuthyTokenCredential other = (AuthyTokenCredential) obj;
    final EqualsBuilder builder = new EqualsBuilder();
    builder.append(this.token, other.token);
    return builder.isEquals();
}
Also used : EqualsBuilder(org.apache.commons.lang3.builder.EqualsBuilder)

Example 24 with EqualsBuilder

use of org.apache.commons.lang3.builder.EqualsBuilder in project cas by apereo.

the class BasicCredentialMetaData method equals.

@Override
public boolean equals(final Object other) {
    if (!(other instanceof BasicCredentialMetaData)) {
        return false;
    }
    final BasicCredentialMetaData md = (BasicCredentialMetaData) other;
    final EqualsBuilder builder = new EqualsBuilder();
    builder.append(this.id, md.id);
    builder.append(this.credentialClass, md.credentialClass);
    return builder.isEquals();
}
Also used : EqualsBuilder(org.apache.commons.lang3.builder.EqualsBuilder)

Example 25 with EqualsBuilder

use of org.apache.commons.lang3.builder.EqualsBuilder in project cas by apereo.

the class DefaultAuthentication method equals.

@Override
public boolean equals(final Object obj) {
    if (!(obj instanceof Authentication)) {
        return false;
    }
    if (obj == this) {
        return true;
    }
    final Authentication other = (Authentication) obj;
    final EqualsBuilder builder = new EqualsBuilder();
    builder.append(this.principal, other.getPrincipal());
    builder.append(this.credentials, other.getCredentials());
    builder.append(this.successes, other.getSuccesses());
    builder.append(this.authenticationDate, other.getAuthenticationDate());
    builder.append(CollectionUtils.wrap(this.attributes), other.getAttributes());
    builder.append(CollectionUtils.wrap(this.failures), other.getFailures());
    return builder.isEquals();
}
Also used : EqualsBuilder(org.apache.commons.lang3.builder.EqualsBuilder)

Aggregations

EqualsBuilder (org.apache.commons.lang3.builder.EqualsBuilder)34 lombok.val (lombok.val)2 JsonProcessingException (com.fasterxml.jackson.core.JsonProcessingException)1 JsonNode (com.fasterxml.jackson.databind.JsonNode)1 ObjectMapper (com.fasterxml.jackson.databind.ObjectMapper)1 Credential (org.apereo.cas.authentication.Credential)1 InvalidSettingsException (org.knime.core.node.InvalidSettingsException)1