Java Code Examples for org.apache.commons.lang3.builder.EqualsBuilder

The following examples show how to use org.apache.commons.lang3.builder.EqualsBuilder. These examples are extracted from open source projects. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source Project: warnings-ng-plugin   Source File: DefaultIssuesTableRow.java    License: MIT License 6 votes vote down vote up
@Override
public boolean equals(final Object o) {
    if (this == o) {
        return true;
    }
    if (o == null || getClass() != o.getClass()) {
        return false;
    }
    if (!super.equals(o)) {
        return false;
    }
    DefaultIssuesTableRow that = (DefaultIssuesTableRow) o;

    EqualsBuilder builder = new EqualsBuilder();
    builder.append(getCategory(), that.getCategory())
            .append(getType(), that.getType());
    return builder.isEquals();
}
 
Example 2
Source Project: backlog4j   Source File: IssueMultiUpdatedContent.java    License: MIT License 6 votes vote down vote up
@Override
public boolean equals(Object obj) {
    if (obj == null) {
        return false;
    }
    if (obj == this) {
        return true;
    }
    if (obj.getClass() != getClass()) {
        return false;
    }
    IssueMultiUpdatedContent rhs = (IssueMultiUpdatedContent) obj;
    return new EqualsBuilder()
            .append(this.txId, rhs.txId)
            .append(this.comment, rhs.comment)
            .append(this.link, rhs.link)
            .append(this.changes, rhs.changes)
            .isEquals();
}
 
Example 3
Source Project: stratio-cassandra   Source File: CompressionParameters.java    License: Apache License 2.0 6 votes vote down vote up
@Override
public boolean equals(Object obj)
{
    if (obj == this)
    {
        return true;
    }
    else if (obj == null || obj.getClass() != getClass())
    {
        return false;
    }

    CompressionParameters cp = (CompressionParameters) obj;
    return new EqualsBuilder()
        .append(sstableCompressor, cp.sstableCompressor)
        .append(chunkLength, cp.chunkLength)
        .append(otherOptions, cp.otherOptions)
        .isEquals();
}
 
Example 4
Source Project: demo   Source File: User.java    License: MIT License 6 votes vote down vote up
public final boolean equals(@Nullable Object obj) {
    if (obj == null) {
        return false;
    }
    if (obj == this) {
        return true;
    }
    if (obj.getClass() != getClass()) {
        return false;
    }
    User rhs = (User) obj;
    return new EqualsBuilder()
            .append(id, rhs.id)
            .append(name, rhs.name)
            .isEquals();
}
 
Example 5
Source Project: chronix.spark   Source File: MetricTimeSeries.java    License: Apache License 2.0 6 votes vote down vote up
@Override
public boolean equals(Object obj) {
    if (obj == null) {
        return false;
    }
    if (obj == this) {
        return true;
    }
    if (obj.getClass() != getClass()) {
        return false;
    }
    MetricTimeSeries rhs = (MetricTimeSeries) obj;
    return new EqualsBuilder()
            .append(this.getMetric(), rhs.getMetric())
            .isEquals();
}
 
Example 6
Source Project: hbase   Source File: RegionReplicaInfo.java    License: Apache License 2.0 6 votes vote down vote up
@Override
public boolean equals(Object other) {
  if (this == other) {
    return true;
  }

  if (other == null || getClass() != other.getClass()) {
    return false;
  }

  RegionReplicaInfo that = (RegionReplicaInfo) other;

  return new EqualsBuilder()
    .append(row, that.row)
    .append(regionInfo, that.regionInfo)
    .append(regionState, that.regionState)
    .append(serverName, that.serverName)
    .append(seqNum, that.seqNum)
    .append(targetServerName, that.targetServerName)
    .append(mergeRegionInfo, that.mergeRegionInfo)
    .append(splitRegionInfo, that.splitRegionInfo)
    .isEquals();
}
 
Example 7
Source Project: backlog4j   Source File: IssueCommentedActivity.java    License: MIT License 6 votes vote down vote up
@Override
public boolean equals(Object obj) {
    if (obj == null) {
        return false;
    }
    if (obj == this) {
        return true;
    }
    if (obj.getClass() != getClass()) {
        return false;
    }
    IssueCommentedActivity rhs = (IssueCommentedActivity) obj;
    return new EqualsBuilder()
            .append(this.type, rhs.type)
            .append(this.content, rhs.content)
            .isEquals();
}
 
Example 8
Source Project: jwala   Source File: ResourceIdentifier.java    License: Apache License 2.0 6 votes vote down vote up
@Override
public boolean equals(Object o) {
    if (this == o) return true;

    if (o == null || ResourceIdentifier.class != o.getClass()) return false;

    ResourceIdentifier that = (ResourceIdentifier) o;

    return new EqualsBuilder()
            .append(resourceName, that.resourceName)
            .append(groupName, that.groupName)
            .append(webServerName, that.webServerName)
            .append(jvmName, that.jvmName)
            .append(webAppName, that.webAppName)
            .isEquals();
}
 
Example 9
public boolean equals(Object obj) {
	if (obj == null) {
		return false;
	}
	if (obj == this) {
		return true;
	}
	if (obj.getClass() != getClass()) {
		return false;
	}
	Info other = (Info) obj;
	EqualsBuilder builder = new EqualsBuilder();
	builder.append(pk, other.pk);
	builder.append(content, other.content);

	return builder.isEquals();
}
 
Example 10
Source Project: spring-security-mongo   Source File: MongoClientDetails.java    License: MIT License 6 votes vote down vote up
@Override
public boolean equals(Object o) {
    if (this == o) return true;

    if (!(o instanceof MongoClientDetails)) return false;

    MongoClientDetails that = (MongoClientDetails) o;

    return new EqualsBuilder()
            .append(clientId, that.clientId)
            .append(scope, that.scope)
            .append(resourceIds, that.resourceIds)
            .append(authorizedGrantTypes, that.authorizedGrantTypes)
            .append(registeredRedirectUris, that.registeredRedirectUris)
            .append(authorities, that.authorities)
            .append(accessTokenValiditySeconds, that.accessTokenValiditySeconds)
            .append(refreshTokenValiditySeconds, that.refreshTokenValiditySeconds)
            .append(additionalInformation, that.additionalInformation)
            .append(autoApproveScopes, that.autoApproveScopes)
            .isEquals();
}
 
Example 11
Source Project: hygieia-core   Source File: Owner.java    License: Apache License 2.0 6 votes vote down vote up
@Override
public boolean equals(Object obj) {
	if (obj == null) {
		return false;
	}
	if (obj == this) {
		return true;
	}
	if (obj.getClass() != getClass()) {
		return false;
	}
	
	Owner rhs = (Owner) obj;
	
	return new EqualsBuilder().append(username, rhs.username).append(authType, rhs.authType).isEquals();
}
 
Example 12
Source Project: backlog4j   Source File: FileDeletedActivity.java    License: MIT License 6 votes vote down vote up
@Override
public boolean equals(Object obj) {
    if (obj == null) {
        return false;
    }
    if (obj == this) {
        return true;
    }
    if (obj.getClass() != getClass()) {
        return false;
    }
    FileDeletedActivity rhs = (FileDeletedActivity) obj;
    return new EqualsBuilder()
            .append(this.type, rhs.type)
            .append(this.content, rhs.content)
            .isEquals();
}
 
Example 13
Source Project: chronix.server   Source File: Frequency.java    License: Apache License 2.0 6 votes vote down vote up
@Override
public boolean equals(Object obj) {
    if (obj == null) {
        return false;
    }
    if (obj == this) {
        return true;
    }
    if (obj.getClass() != getClass()) {
        return false;
    }
    Frequency rhs = (Frequency) obj;
    return new EqualsBuilder()
            .append(this.windowSize, rhs.windowSize)
            .append(this.windowThreshold, rhs.windowThreshold)
            .isEquals();
}
 
Example 14
@Override
public boolean equals(final Object obj) {
    if (obj == null) {
        return false;
    }
    if (obj == this) {
        return true;
    }
    if (obj.getClass() != getClass()) {
        return false;
    }
    final RegisteredServicePublicKeyImpl rhs = (RegisteredServicePublicKeyImpl) obj;
    return new EqualsBuilder()
            .append(this.location, rhs.location)
            .append(this.algorithm, rhs.algorithm)
            .isEquals();
}
 
Example 15
Source Project: backlog4j   Source File: PullRequestContent.java    License: MIT License 6 votes vote down vote up
@Override
public boolean equals(Object obj) {
    if (obj == null) {
        return false;
    }
    if (obj == this) {
        return true;
    }
    if (obj.getClass() != getClass()) {
        return false;
    }
    PullRequestContent rhs = (PullRequestContent) obj;
    return new EqualsBuilder()
            .append(this.id, rhs.id)
            .append(this.number, rhs.number)
            .append(this.summary, rhs.summary)
            .append(this.description, rhs.description)
            .append(this.comment, rhs.comment)
            .append(this.changes, rhs.changes)
            .append(this.repository, rhs.repository)
            .isEquals();
}
 
Example 16
Source Project: syncope   Source File: AbstractStartEndBean.java    License: Apache License 2.0 6 votes vote down vote up
@Override
public boolean equals(final Object obj) {
    if (this == obj) {
        return true;
    }
    if (obj == null) {
        return false;
    }
    if (getClass() != obj.getClass()) {
        return false;
    }
    final AbstractStartEndBean other = (AbstractStartEndBean) obj;
    return new EqualsBuilder().
            append(start, other.start).
            append(end, other.end).
            build();
}
 
Example 17
Source Project: backlog4j   Source File: FileUpdatedContent.java    License: MIT License 6 votes vote down vote up
@Override
public boolean equals(Object obj) {
    if (obj == null) {
        return false;
    }
    if (obj == this) {
        return true;
    }
    if (obj.getClass() != getClass()) {
        return false;
    }
    FileUpdatedContent rhs = (FileUpdatedContent) obj;
    return new EqualsBuilder()
            .append(this.id, rhs.id)
            .append(this.name, rhs.name)
            .append(this.dir, rhs.dir)
            .append(this.size, rhs.size)
            .isEquals();
}
 
Example 18
Source Project: sailfish-core   Source File: SimpleCell.java    License: Apache License 2.0 6 votes vote down vote up
@Override
public boolean equals(Object obj){
    if(obj == this) {
        return true;
    }

    if(!(obj instanceof SimpleCell)) {
        return false;
    }

    SimpleCell that = (SimpleCell)obj;
    EqualsBuilder builder = new EqualsBuilder();

    builder.append(value, that.value);
    builder.append(lineNumber, that.lineNumber);
    builder.append(cellStyle, that.cellStyle);

    return builder.isEquals();
}
 
Example 19
@Override
public boolean equals(final Object obj) {
    if (obj == null) {
        return false;
    }
    if (obj == this) {
        return true;
    }
    if (obj.getClass() != getClass()) {
        return false;
    }
    final DefaultRegisteredServiceAccessStrategy rhs = (DefaultRegisteredServiceAccessStrategy) obj;
    return new EqualsBuilder()
            .append(this.enabled, rhs.enabled)
            .append(this.ssoEnabled, rhs.ssoEnabled)
            .append(this.requireAllAttributes, rhs.requireAllAttributes)
            .append(this.requiredAttributes, rhs.requiredAttributes)
            .isEquals();
}
 
Example 20
Source Project: jwala   Source File: PortNumberRule.java    License: Apache License 2.0 6 votes vote down vote up
@Override
public boolean equals(Object obj) {
    if (obj == null) {
        return false;
    }
    if (obj == this) {
        return true;
    }
    if (obj.getClass() != getClass()) {
        return false;
    }
    PortNumberRule rhs = (PortNumberRule) obj;
    return new EqualsBuilder()
            .append(this.port, rhs.port)
            .append(this.error, rhs.error)
            .append(this.nullable, rhs.nullable)
            .isEquals();
}
 
Example 21
Source Project: syncope   Source File: AccessTokenTO.java    License: Apache License 2.0 6 votes vote down vote up
@Override
public boolean equals(final Object obj) {
    if (this == obj) {
        return true;
    }
    if (obj == null) {
        return false;
    }
    if (getClass() != obj.getClass()) {
        return false;
    }
    AccessTokenTO other = (AccessTokenTO) obj;
    return new EqualsBuilder().
            append(key, other.key).
            append(body, other.body).
            append(expiryTime, other.expiryTime).
            append(owner, other.owner).
            build();
}
 
Example 22
Source Project: syncope   Source File: PrivilegeCond.java    License: Apache License 2.0 6 votes vote down vote up
@Override
public boolean equals(final Object obj) {
    if (this == obj) {
        return true;
    }
    if (obj == null) {
        return false;
    }
    if (getClass() != obj.getClass()) {
        return false;
    }
    final PrivilegeCond other = (PrivilegeCond) obj;
    return new EqualsBuilder().
            append(privilege, other.privilege).
            build();
}
 
Example 23
Source Project: jstarcraft-ai   Source File: RmsPropLearner.java    License: Apache License 2.0 6 votes vote down vote up
@Override
public boolean equals(Object object) {
    if (this == object) {
        return true;
    }
    if (object == null) {
        return false;
    }
    if (getClass() != object.getClass()) {
        return false;
    } else {
        RmsPropLearner that = (RmsPropLearner) object;
        EqualsBuilder equal = new EqualsBuilder();
        equal.append(this.rmsDecay, that.rmsDecay);
        equal.append(this.epsilon, that.epsilon);
        equal.append(this.learnSchedule, that.learnSchedule);
        return equal.isEquals();
    }
}
 
Example 24
Source Project: jstarcraft-ai   Source File: MixtureDensityLossFunction.java    License: Apache License 2.0 6 votes vote down vote up
@Override
public boolean equals(Object object) {
    if (this == object) {
        return true;
    }
    if (object == null) {
        return false;
    }
    if (getClass() != object.getClass()) {
        return false;
    } else {
        MixtureDensityLossFunction that = (MixtureDensityLossFunction) object;
        EqualsBuilder equal = new EqualsBuilder();
        equal.append(this.mixtures, that.mixtures);
        equal.append(this.marks, that.marks);
        return equal.isEquals();
    }
}
 
Example 25
Source Project: syncope   Source File: ConnConfPropSchema.java    License: Apache License 2.0 6 votes vote down vote up
@Override
public boolean equals(final Object obj) {
    if (this == obj) {
        return true;
    }
    if (obj == null) {
        return false;
    }
    if (getClass() != obj.getClass()) {
        return false;
    }
    final ConnConfPropSchema other = (ConnConfPropSchema) obj;
    return new EqualsBuilder().
            append(name, other.name).
            append(type, other.type).
            append(required, other.required).
            append(order, other.order).
            append(confidential, other.confidential).
            build();
}
 
Example 26
Source Project: flink   Source File: AverageClusteringCoefficient.java    License: Apache License 2.0 6 votes vote down vote up
@Override
public boolean equals(Object obj) {
	if (obj == null) {
		return false;
	}

	if (obj == this) {
		return true;
	}

	if (obj.getClass() != getClass()) {
		return false;
	}

	Result rhs = (Result) obj;

	return new EqualsBuilder()
		.append(vertexCount, rhs.vertexCount)
		.append(averageLocalClusteringCoefficient, rhs.averageLocalClusteringCoefficient)
		.isEquals();
}
 
Example 27
Source Project: sailfish-core   Source File: ServiceName.java    License: Apache License 2.0 6 votes vote down vote up
@Override
public boolean equals(Object obj) {
       if(this == obj) {
           return true;
       }

       if(!(obj instanceof ServiceName)) {
           return false;
       }

       ServiceName that = (ServiceName)obj;
       EqualsBuilder builder = new EqualsBuilder();

       builder.append(StringUtils.lowerCase(environment), StringUtils.lowerCase(that.environment));
       builder.append(serviceName, that.serviceName);

       return builder.isEquals();
}
 
Example 28
Source Project: backlog4j   Source File: GitRepositoryCreatedContent.java    License: MIT License 6 votes vote down vote up
@Override
public boolean equals(Object obj) {
    if (obj == null) {
        return false;
    }
    if (obj == this) {
        return true;
    }
    if (obj.getClass() != getClass()) {
        return false;
    }
    GitRepositoryCreatedContent rhs = (GitRepositoryCreatedContent) obj;
    return new EqualsBuilder()
            .append(this.repository, rhs.repository)
            .isEquals();
}
 
Example 29
@Override
public boolean equals(Object obj) {
  if (obj == null) { return false; }
  if (obj == this) { return true; }
  if (obj.getClass() != getClass()) { return false; }
  CampaignNegativeLocationsReport other = (CampaignNegativeLocationsReport) obj;
  return new EqualsBuilder()
    .appendSuper(super.equals(obj))
    .append(accountCurrencyCode, other.accountCurrencyCode)
    .append(accountDescriptiveName, other.accountDescriptiveName)
    .append(accountTimeZone, other.accountTimeZone)
    .append(baseCampaignId, other.baseCampaignId)
    .append(campaignId, other.campaignId)
    .append(campaignName, other.campaignName)
    .append(campaignStatus, other.campaignStatus)
    .append(customerDescriptiveName, other.customerDescriptiveName)
    .append(id, other.id)
    .append(isNegative, other.isNegative)
    .isEquals();
}
 
Example 30
Source Project: flink   Source File: GlobalClusteringCoefficient.java    License: Apache License 2.0 6 votes vote down vote up
@Override
public boolean equals(Object obj) {
	if (obj == null) {
		return false;
	}

	if (obj == this) {
		return true;
	}

	if (obj.getClass() != getClass()) {
		return false;
	}

	Result rhs = (Result) obj;

	return new EqualsBuilder()
		.append(tripletCount, rhs.tripletCount)
		.append(triangleCount, rhs.triangleCount)
		.isEquals();
}