From 8358decdf4cc65bbc6a206bc6b555eaa486078b3 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Wed, 8 Jun 2016 12:11:36 +0200 Subject: [PATCH] let's make sure that serial numbers of objects are never persisted (being ignored by JPA) --- .../mxchange/jphone/phonenumbers/cellphone/CellphoneNumber.java | 2 ++ src/org/mxchange/jphone/phonenumbers/fax/FaxNumber.java | 2 ++ .../mxchange/jphone/phonenumbers/landline/LandLineNumber.java | 2 ++ .../jphone/phonenumbers/mobileprovider/CellphoneProvider.java | 2 ++ 4 files changed, 8 insertions(+) diff --git a/src/org/mxchange/jphone/phonenumbers/cellphone/CellphoneNumber.java b/src/org/mxchange/jphone/phonenumbers/cellphone/CellphoneNumber.java index 55a1bb6..8868c24 100644 --- a/src/org/mxchange/jphone/phonenumbers/cellphone/CellphoneNumber.java +++ b/src/org/mxchange/jphone/phonenumbers/cellphone/CellphoneNumber.java @@ -32,6 +32,7 @@ import javax.persistence.OneToOne; import javax.persistence.Table; import javax.persistence.Temporal; import javax.persistence.TemporalType; +import javax.persistence.Transient; import org.mxchange.jcountry.data.Country; import org.mxchange.jphone.phonenumbers.mobileprovider.CellphoneProvider; import org.mxchange.jphone.phonenumbers.mobileprovider.MobileProvider; @@ -52,6 +53,7 @@ public class CellphoneNumber implements DialableCellphoneNumber { /** * Serial number */ + @Transient private static final long serialVersionUID = 13_859_879_482_106L; /** diff --git a/src/org/mxchange/jphone/phonenumbers/fax/FaxNumber.java b/src/org/mxchange/jphone/phonenumbers/fax/FaxNumber.java index fb9a2cb..eb63977 100644 --- a/src/org/mxchange/jphone/phonenumbers/fax/FaxNumber.java +++ b/src/org/mxchange/jphone/phonenumbers/fax/FaxNumber.java @@ -32,6 +32,7 @@ import javax.persistence.OneToOne; import javax.persistence.Table; import javax.persistence.Temporal; import javax.persistence.TemporalType; +import javax.persistence.Transient; import org.mxchange.jcountry.data.Country; import org.mxchange.jcountry.data.CountryData; @@ -51,6 +52,7 @@ public class FaxNumber implements DialableFaxNumber { /** * Serial number */ + @Transient private static final long serialVersionUID = 17_687_687_191_375L; /** diff --git a/src/org/mxchange/jphone/phonenumbers/landline/LandLineNumber.java b/src/org/mxchange/jphone/phonenumbers/landline/LandLineNumber.java index 63c830e..6d6dfde 100644 --- a/src/org/mxchange/jphone/phonenumbers/landline/LandLineNumber.java +++ b/src/org/mxchange/jphone/phonenumbers/landline/LandLineNumber.java @@ -32,6 +32,7 @@ import javax.persistence.OneToOne; import javax.persistence.Table; import javax.persistence.Temporal; import javax.persistence.TemporalType; +import javax.persistence.Transient; import org.mxchange.jcountry.data.Country; import org.mxchange.jcountry.data.CountryData; @@ -51,6 +52,7 @@ public class LandLineNumber implements DialableLandLineNumber { /** * Serial number */ + @Transient private static final long serialVersionUID = 18_563_748_781_956L; /** diff --git a/src/org/mxchange/jphone/phonenumbers/mobileprovider/CellphoneProvider.java b/src/org/mxchange/jphone/phonenumbers/mobileprovider/CellphoneProvider.java index 58175e0..7f8b63d 100644 --- a/src/org/mxchange/jphone/phonenumbers/mobileprovider/CellphoneProvider.java +++ b/src/org/mxchange/jphone/phonenumbers/mobileprovider/CellphoneProvider.java @@ -32,6 +32,7 @@ import javax.persistence.OneToOne; import javax.persistence.Table; import javax.persistence.Temporal; import javax.persistence.TemporalType; +import javax.persistence.Transient; import org.mxchange.jcountry.data.Country; import org.mxchange.jcountry.data.CountryData; @@ -51,6 +52,7 @@ public class CellphoneProvider implements MobileProvider { /** * Serial number */ + @Transient private static final long serialVersionUID = 185_878_567_810_590L; /** -- 2.39.5