Example usage for org.apache.commons.lang3.builder EqualsBuilder EqualsBuilder

List of usage examples for org.apache.commons.lang3.builder EqualsBuilder EqualsBuilder

Introduction

In this page you can find the example usage for org.apache.commons.lang3.builder EqualsBuilder EqualsBuilder.

Prototype

public EqualsBuilder() 

Source Link

Document

Constructor for EqualsBuilder.

Starts off assuming that equals is true.

Usage

From source file:com.trenako.services.view.HomeView.java

@Override
public boolean equals(Object obj) {
    if (obj == this)
        return true;
    if (!(obj instanceof HomeView))
        return false;

    HomeView other = (HomeView) obj;/*from ww  w. j  av a 2s.c o  m*/
    return new EqualsBuilder().append(this.isLogged, other.isLogged)
            .append(this.rollingStocks, other.rollingStocks).append(this.activityStream, other.activityStream)
            .isEquals();
}

From source file:com.aqnote.app.wifianalyzer.wifi.band.WiFiChannel.java

@Override
public boolean equals(Object other) {
    if (this == other)
        return true;

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

    WiFiChannel otherDetail = (WiFiChannel) other;
    return new EqualsBuilder().append(getChannel(), (otherDetail).getChannel())
            .append(getFrequency(), (otherDetail).getFrequency()).isEquals();
}

From source file:io.cloudslang.lang.entities.bindings.Output.java

@Override
public boolean equals(Object o) {

    if (this == o) {
        return true;
    }/*from w w  w . j a v a 2s  . c o m*/

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

    Output that = (Output) o;

    return new EqualsBuilder().appendSuper(super.equals(o)).append(robot, that.robot).isEquals();
}

From source file:com.github.jknack.amd4j.ResourceURI.java

@Override
public boolean equals(final Object obj) {
    if (obj instanceof ResourceURI) {
        ResourceURI that = (ResourceURI) obj;
        return new EqualsBuilder().append(prefix, that.prefix).append(path, that.path).isEquals();
    }//from w w w  . j  a  v  a  2 s.c om
    return false;
}

From source file:io.netlibs.bgp.protocol.capabilities.UnknownCapability.java

@Override
protected boolean equalsSubclass(Capability other) {
    UnknownCapability uc = (UnknownCapability) other;

    return (new EqualsBuilder()).append(getCapabilityType(), uc.getCapabilityType())
            .append(getValue(), uc.getValue()).isEquals();
}

From source file:eu.jasha.demo.sbtfragments.City.java

@Override
public boolean equals(Object obj) {
    if (obj == null) {
        return false;
    }/*from ww w . j a va 2 s  .  c om*/
    if (obj == this) {
        return true;
    }
    if (obj.getClass() != getClass()) {
        return false;
    }
    City rhs = (City) obj;
    return new EqualsBuilder().append(this.id, rhs.id).append(this.name, rhs.name)
            .append(this.foundedIn, rhs.foundedIn).append(this.population, rhs.population).isEquals();
}

From source file:com.htmlhifive.sync.service.SyncRequestCommonData.java

/**
 * @see Object#equals(Object)/*from   ww w  . j a  v  a 2  s. c om*/
 */
@Override
public boolean equals(Object obj) {

    if (obj == this)
        return true;
    if (!(obj instanceof SyncRequestCommonData))
        return false;

    SyncRequestCommonData uploadCommon = (SyncRequestCommonData) obj;

    return new EqualsBuilder().append(this.storageId, uploadCommon.storageId)
            .append(this.lastUploadTime, uploadCommon.lastUploadTime)
            .append(this.syncTime, uploadCommon.syncTime).isEquals();
}

From source file:de.kaiserpfalzEdv.office.contacts.address.phone.NumberPartDO.java

@SuppressWarnings("deprecation")
@Override//from  w  ww  .  ja  va2 s.  co  m
public boolean equals(Object obj) {
    if (obj == null) {
        return false;
    }
    if (obj == this) {
        return true;
    }
    if (obj.getClass() != getClass()) {
        return false;
    }
    NumberPartDO rhs = (NumberPartDO) obj;
    return new EqualsBuilder().append(this.getNumber(), rhs.getNumber()).isEquals();
}

From source file:com.hp.ov.sdk.dto.BootModeSettingsTemplate.java

@Override
public boolean equals(Object obj) {
    if (this == obj)
        return true;

    if (obj == null || getClass() != obj.getClass())
        return false;

    BootModeSettingsTemplate that = (BootModeSettingsTemplate) obj;

    return new EqualsBuilder().append(manageMode, that.manageMode).append(mode, that.mode)
            .append(pxeBootPolicy, that.pxeBootPolicy).isEquals();
}

From source file:de.perdian.apps.dashboard.mvc.modules.project.ProjectControllerRequest.java

@Override
public boolean equals(Object that) {
    if (that instanceof ProjectControllerRequest) {
        ProjectControllerRequest thatRequest = (ProjectControllerRequest) that;
        EqualsBuilder equalsBuilder = new EqualsBuilder();
        equalsBuilder.append(this.getJenkinsJobName(), thatRequest.getJenkinsJobName());
        equalsBuilder.append(this.getJenkinsPassword(), thatRequest.getJenkinsPassword());
        equalsBuilder.append(this.getJenkinsUrl(), thatRequest.getJenkinsUrl());
        equalsBuilder.append(this.getJenkinsUsername(), thatRequest.getJenkinsUsername());
        equalsBuilder.append(this.getSonarPassword(), thatRequest.getSonarPassword());
        equalsBuilder.append(this.getSonarProjectName(), thatRequest.getSonarProjectName());
        equalsBuilder.append(this.getSonarUrl(), thatRequest.getSonarUrl());
        equalsBuilder.append(this.getSonarUsername(), thatRequest.getSonarUsername());
        return equalsBuilder.isEquals();
    } else {/*from w  w w .ja  va2 s  . c o  m*/
        return false;
    }
}