Mercurial > lada > lada-server
diff src/main/java/de/intevation/lada/model/stammdaten/MmtMessgroessePK.java @ 1028:1c41c7b8f7c2 schema-update
Updated server application to new database model. THIS IS STILL WIP!!!
author | Raimund Renkert <raimund.renkert@intevation.de> |
---|---|
date | Fri, 08 Jul 2016 15:32:36 +0200 |
parents | |
children |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/src/main/java/de/intevation/lada/model/stammdaten/MmtMessgroessePK.java Fri Jul 08 15:32:36 2016 +0200 @@ -0,0 +1,62 @@ +/* Copyright (C) 2013 by Bundesamt fuer Strahlenschutz + * Software engineering by Intevation GmbH + * + * This file is Free Software under the GNU GPL (v>=3) + * and comes with ABSOLUTELY NO WARRANTY! Check out + * the documentation coming with IMIS-Labordaten-Application for details. + */ +package de.intevation.lada.model.stammdaten; + +import java.io.Serializable; + +import javax.persistence.Column; +import javax.persistence.Embeddable; + + +@Embeddable +public class MmtMessgroessePK implements Serializable{ + + private static final long serialVersionUID = 1L; + + @Column(name="messgroesse_id") + private Integer messgroesseId; + + @Column(name="mmt_id") + private String mmtId; + + public MmtMessgroessePK() { + } + public Integer getMessgroessengruppeId() { + return this.messgroesseId; + } + public void setMessgroessengruppeId(Integer messgroesseId) { + this.messgroesseId = messgroesseId; + } + public String getMmtId() { + return this.mmtId; + } + public void setMmtId(String mmtId) { + this.mmtId = mmtId; + } + + public boolean equals(Object other) { + if (this == other) { + return true; + } + if (!(other instanceof MmtMessgroessePK)) { + return false; + } + MmtMessgroessePK castOther = (MmtMessgroessePK)other; + return + this.messgroesseId.equals(castOther.messgroesseId) + && this.mmtId.equals(castOther.mmtId); + } + + public int hashCode() { + final int prime = 31; + int hash = 17; + hash = hash * prime + this.messgroesseId.hashCode(); + hash = hash * prime + this.mmtId.hashCode(); + return hash; + } +}