added properties to equals, hashCode and toString

This commit is contained in:
Sebastian Sdorra
2012-02-26 20:23:47 +01:00
parent 2f726d864f
commit ed73f0811f
3 changed files with 17 additions and 10 deletions

View File

@@ -217,7 +217,8 @@ public class Group extends BasicPropertiesAware
&& Objects.equal(members, other.members)
&& Objects.equal(type, other.type)
&& Objects.equal(creationDate, other.creationDate)
&& Objects.equal(lastModified, lastModified);
&& Objects.equal(lastModified, other.lastModified)
&& Objects.equal(properties, other.properties);
}
/**
@@ -230,7 +231,7 @@ public class Group extends BasicPropertiesAware
public int hashCode()
{
return Objects.hashCode(name, description, members, type, creationDate,
lastModified);
lastModified, properties);
}
/**
@@ -275,6 +276,7 @@ public class Group extends BasicPropertiesAware
.add("type", type)
.add("creationDate", creationDate)
.add("lastModified", lastModified)
.add("properties", properties)
.toString();
//J+
}

View File

@@ -195,7 +195,8 @@ public class Repository extends BasicPropertiesAware implements ModelObject
&& Objects.equal(type, other.type)
&& Objects.equal(url, other.url)
&& Objects.equal(creationDate, other.creationDate)
&& Objects.equal(lastModified, other.lastModified);
&& Objects.equal(lastModified, other.lastModified)
&& Objects.equal(properties, other.properties);
//J+
}
@@ -209,7 +210,8 @@ public class Repository extends BasicPropertiesAware implements ModelObject
public int hashCode()
{
return Objects.hashCode(id, name, contact, description, publicReadable,
permissions, type, url, creationDate, lastModified);
permissions, type, url, creationDate, lastModified,
properties);
}
/**
@@ -233,6 +235,7 @@ public class Repository extends BasicPropertiesAware implements ModelObject
.add("url", url)
.add("lastModified", lastModified)
.add("creationDate", creationDate)
.add("properties", properties)
.toString();
//J+
}

View File

@@ -189,7 +189,7 @@ public class User extends BasicPropertiesAware implements Principal, ModelObject
}
/**
* Method description
* {@inheritDoc}
*
*
* @param obj
@@ -218,11 +218,12 @@ public class User extends BasicPropertiesAware implements Principal, ModelObject
&& Objects.equal(admin, other.admin)
&& Objects.equal(password, other.password)
&& Objects.equal(creationDate, other.creationDate)
&& Objects.equal(lastModified, other.lastModified);
&& Objects.equal(lastModified, other.lastModified)
&& Objects.equal(properties, other.properties);
}
/**
* Method description
* {@inheritDoc}
*
*
* @return
@@ -231,11 +232,11 @@ public class User extends BasicPropertiesAware implements Principal, ModelObject
public int hashCode()
{
return Objects.hashCode(name, displayName, mail, type, admin, password,
creationDate, lastModified);
creationDate, lastModified, properties);
}
/**
* Method description
* {@inheritDoc}
*
*
* @return
@@ -257,6 +258,7 @@ public class User extends BasicPropertiesAware implements Principal, ModelObject
.add("type", type)
.add("creationDate", creationDate)
.add("lastModified", lastModified)
.add("properties", properties)
.toString();
//J+
}