From c4f65ffd8e44c388e8f5c5dd6990d4906ec5a6a8 Mon Sep 17 00:00:00 2001 From: Lukasz Antoniak Date: Thu, 19 May 2011 21:39:31 +0200 Subject: [PATCH] HHH-5808 - Code formatting --- .../AddressCompositePKEntity.java | 94 +++++++++---------- .../onetoone/unidirectional/AddressPK.java | 66 ++++++------- .../PersonCompositeFKEntity.java | 94 +++++++++---------- 3 files changed, 127 insertions(+), 127 deletions(-) diff --git a/hibernate-envers/src/test/java/org/hibernate/envers/test/integration/onetoone/unidirectional/AddressCompositePKEntity.java b/hibernate-envers/src/test/java/org/hibernate/envers/test/integration/onetoone/unidirectional/AddressCompositePKEntity.java index 74a8082a71..003d2d980a 100644 --- a/hibernate-envers/src/test/java/org/hibernate/envers/test/integration/onetoone/unidirectional/AddressCompositePKEntity.java +++ b/hibernate-envers/src/test/java/org/hibernate/envers/test/integration/onetoone/unidirectional/AddressCompositePKEntity.java @@ -14,63 +14,63 @@ import javax.persistence.IdClass; @Audited @IdClass(AddressPK.class) public class AddressCompositePKEntity { - private Integer id; - private Integer ver; - private String street; + private Integer id; + private Integer ver; + private String street; - public AddressCompositePKEntity() { - } + public AddressCompositePKEntity() { + } - public AddressCompositePKEntity(Integer id, Integer ver, String street) { - this.setId(id); - this.setVer(ver); - this.setStreet(street); - } + public AddressCompositePKEntity(Integer id, Integer ver, String street) { + this.setId(id); + this.setVer(ver); + this.setStreet(street); + } - @Id - @Column(name = "ID", nullable = false, updatable = false) - public Integer getId() { - return id; - } + @Id + @Column(name = "ID", nullable = false, updatable = false) + public Integer getId() { + return id; + } - public void setId(Integer id) { - this.id = id; - } + public void setId(Integer id) { + this.id = id; + } - @Id - @Column(name = "VER", nullable = false, updatable = false) - public Integer getVer() { - return ver; - } + @Id + @Column(name = "VER", nullable = false, updatable = false) + public Integer getVer() { + return ver; + } - public void setVer(Integer ver) { - this.ver = ver; - } + public void setVer(Integer ver) { + this.ver = ver; + } - @Column(name = "STREET", nullable = false) - public String getStreet() { - return street; - } + @Column(name = "STREET", nullable = false) + public String getStreet() { + return street; + } - public void setStreet(String street) { - this.street = street; - } + public void setStreet(String street) { + this.street = street; + } - public String toString() { - return "AddressCompositePKEntity[id = " + getId() + ", ver = " + getVer() + ", street = " + getStreet() + "]"; - } + public String toString() { + return "AddressCompositePKEntity[id = " + getId() + ", ver = " + getVer() + ", street = " + getStreet() + "]"; + } - @Override - public int hashCode() { - int result = 1; - result = 31 * result + ((id == null) ? 0 : id.hashCode()); - result = 31 * result + ((ver == null) ? 0 : ver.hashCode()); - result = 31 * result + ((street == null) ? 0 : street.hashCode()); - return result; - } + @Override + public int hashCode() { + int result = 1; + result = 31 * result + ((id == null) ? 0 : id.hashCode()); + result = 31 * result + ((ver == null) ? 0 : ver.hashCode()); + result = 31 * result + ((street == null) ? 0 : street.hashCode()); + return result; + } - @Override - public boolean equals(Object o) { + @Override + public boolean equals(Object o) { if (this == o) return true; if (!(o instanceof AddressCompositePKEntity)) return false; @@ -81,5 +81,5 @@ public class AddressCompositePKEntity { if (street != null ? !street.equals(that.street) : that.street != null) return false; return true; - } + } } diff --git a/hibernate-envers/src/test/java/org/hibernate/envers/test/integration/onetoone/unidirectional/AddressPK.java b/hibernate-envers/src/test/java/org/hibernate/envers/test/integration/onetoone/unidirectional/AddressPK.java index 8a91c7d78d..bc227bddc3 100644 --- a/hibernate-envers/src/test/java/org/hibernate/envers/test/integration/onetoone/unidirectional/AddressPK.java +++ b/hibernate-envers/src/test/java/org/hibernate/envers/test/integration/onetoone/unidirectional/AddressPK.java @@ -6,47 +6,47 @@ import java.io.Serializable; * @author Andrei Zagorneanu */ public class AddressPK implements Serializable { - private Integer id; - private Integer ver; + private Integer id; + private Integer ver; - public AddressPK() { - } + public AddressPK() { + } - public AddressPK(Integer id, Integer ver) { - this.setId(id); - this.setVer(ver); - } + public AddressPK(Integer id, Integer ver) { + this.setId(id); + this.setVer(ver); + } - public Integer getId() { - return id; - } + public Integer getId() { + return id; + } - public void setId(Integer id) { - this.id = id; - } + public void setId(Integer id) { + this.id = id; + } - public Integer getVer() { - return ver; - } + public Integer getVer() { + return ver; + } - public void setVer(Integer ver) { - this.ver = ver; - } + public void setVer(Integer ver) { + this.ver = ver; + } - public String toString() { - return "AddressPK[id = " + getId() + ", ver = " + getVer() + "]"; - } + public String toString() { + return "AddressPK[id = " + getId() + ", ver = " + getVer() + "]"; + } - @Override - public int hashCode() { - int result = 1; - result = 31 * result + ((id == null) ? 0 : id.hashCode()); - result = 31 * result + ((ver == null) ? 0 : ver.hashCode()); - return result; - } + @Override + public int hashCode() { + int result = 1; + result = 31 * result + ((id == null) ? 0 : id.hashCode()); + result = 31 * result + ((ver == null) ? 0 : ver.hashCode()); + return result; + } - @Override - public boolean equals(Object o) { + @Override + public boolean equals(Object o) { if (this == o) return true; if (!(o instanceof AddressPK)) return false; @@ -56,5 +56,5 @@ public class AddressPK implements Serializable { if (id != null ? !id.equals(that.id) : that.id != null) return false; return true; - } + } } diff --git a/hibernate-envers/src/test/java/org/hibernate/envers/test/integration/onetoone/unidirectional/PersonCompositeFKEntity.java b/hibernate-envers/src/test/java/org/hibernate/envers/test/integration/onetoone/unidirectional/PersonCompositeFKEntity.java index 1002e8a1dd..d8cc0679ab 100644 --- a/hibernate-envers/src/test/java/org/hibernate/envers/test/integration/onetoone/unidirectional/PersonCompositeFKEntity.java +++ b/hibernate-envers/src/test/java/org/hibernate/envers/test/integration/onetoone/unidirectional/PersonCompositeFKEntity.java @@ -16,64 +16,64 @@ import org.hibernate.envers.Audited; @Entity @Audited public class PersonCompositeFKEntity { - private Integer id; - private String name; - private AddressCompositePKEntity address; + private Integer id; + private String name; + private AddressCompositePKEntity address; - public PersonCompositeFKEntity() { - } + public PersonCompositeFKEntity() { + } - public PersonCompositeFKEntity(Integer id, String name, AddressCompositePKEntity address) { - this.setId(id); - this.setName(name); - this.setAddress(address); - } + public PersonCompositeFKEntity(Integer id, String name, AddressCompositePKEntity address) { + this.setId(id); + this.setName(name); + this.setAddress(address); + } - @Id - @Column(name = "ID", nullable = false, updatable = false) - public Integer getId() { - return id; - } + @Id + @Column(name = "ID", nullable = false, updatable = false) + public Integer getId() { + return id; + } - public void setId(Integer id) { - this.id = id; - } + public void setId(Integer id) { + this.id = id; + } - @Column(name = "NAME", nullable = false) - public String getName() { - return name; - } + @Column(name = "NAME", nullable = false) + public String getName() { + return name; + } - public void setName(String name) { - this.name = name; - } + public void setName(String name) { + this.name = name; + } - @OneToOne(cascade = { CascadeType.ALL }, orphanRemoval = true) - @JoinColumns({@JoinColumn(name = "ID_ADDRESS", referencedColumnName = "ID"), + @OneToOne(cascade = {CascadeType.ALL}, orphanRemoval = true) + @JoinColumns({@JoinColumn(name = "ID_ADDRESS", referencedColumnName = "ID"), @JoinColumn(name = "VER_ADDRESS", referencedColumnName = "VER")}) - public AddressCompositePKEntity getAddress() { - return address; - } + public AddressCompositePKEntity getAddress() { + return address; + } - public void setAddress(AddressCompositePKEntity address) { - this.address = address; - } + public void setAddress(AddressCompositePKEntity address) { + this.address = address; + } - public String toString() { - return "PersonCompositeFKEntity[id = " + getId() + ", name = " + getName() + "]"; - } + public String toString() { + return "PersonCompositeFKEntity[id = " + getId() + ", name = " + getName() + "]"; + } - @Override - public int hashCode() { - int result = 1; - result = 31 * result + ((id == null) ? 0 : id.hashCode()); - result = 31 * result + ((name == null) ? 0 : name.hashCode()); - return result; - } + @Override + public int hashCode() { + int result = 1; + result = 31 * result + ((id == null) ? 0 : id.hashCode()); + result = 31 * result + ((name == null) ? 0 : name.hashCode()); + return result; + } - @Override - public boolean equals(Object o) { - if (this == o) return true; + @Override + public boolean equals(Object o) { + if (this == o) return true; if (!(o instanceof PersonCompositeFKEntity)) return false; PersonCompositeFKEntity that = (PersonCompositeFKEntity) o; @@ -82,5 +82,5 @@ public class PersonCompositeFKEntity { if (name != null ? !name.equals(that.name) : that.name != null) return false; return true; - } + } }