All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.bq.corbel.eventbus.EventWithSpecificDomain Maven / Gradle / Ivy

Go to download

Publish/subscribe event bus that simplifies communication between Corbel modules

There is a newer version: 1.33.0
Show newest version
package com.bq.corbel.eventbus;

public abstract class EventWithSpecificDomain implements Event {
    protected String domain;

    public EventWithSpecificDomain() {}

    public EventWithSpecificDomain(String domain) {
        this.domain = domain;
    }

    @Override
    public String getDomain() {
        return domain;
    }

    public void setDomain(String domain) {
        this.domain = domain;
    }

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

        EventWithSpecificDomain that = (EventWithSpecificDomain) o;

        if (domain != null ? !domain.equals(that.domain) : that.domain != null)
            return false;

        return true;
    }

    @Override
    public int hashCode() {
        return domain != null ? domain.hashCode() : 0;
    }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy