class ConnectedAgentAttache extends AgentAttache {

    @Override
    public boolean equals(final Object obj) {
        // Return false straight away.
        if (obj == null) {
            return false;
        }
        // No need to handle a ClassCastException. If the classes are different, then equals can return false straight ahead.
        if (this.getClass() != obj.getClass()) {
            return false;
        }
        // This should not be part of the equals() method, but I'm keeping it because it is expected behaviour based
        // on the previous implementation. The link attribute of the other object should be checked here as well
        // to verify if it's not null whilst the this is null.
        if (_link == null) {
            return false;
        }
        ConnectedAgentAttache that = (ConnectedAgentAttache)obj;
        return super.equals(obj) && _link == that._link;
    }

    public  ConnectedAgentAttache(final AgentManagerImpl agentMgr, final long id, final String name, final Link link, final boolean maintenance);

}