]> git.mxchange.org Git - jcontacts-core.git/commitdiff
updated jar(s) + added API documentation + added referencedColumnName
authorRoland Haeder <roland@mxchange.org>
Sun, 6 Mar 2016 15:26:01 +0000 (16:26 +0100)
committerRoland Haeder <roland@mxchange.org>
Sun, 6 Mar 2016 16:45:57 +0000 (17:45 +0100)
Signed-off-by: Roland Häder <roland@mxchange.org>
lib/jcore.jar
lib/jcountry-core.jar
lib/jphone-core.jar
lib/nblibraries.properties
nbproject/project.properties
src/org/mxchange/jcontacts/contact/UserContact.java

index eda5d6c5d20ad4bf93b64edd1bba696272a33988..23ef19d3e26ecc03e092895707158a0296bb95bf 100644 (file)
Binary files a/lib/jcore.jar and b/lib/jcore.jar differ
index 2623d9d49164c0fae2cdd8b4be88478507b064bf..8f2a52866c7ad118b28db9a470c105f6fc62f655 100644 (file)
Binary files a/lib/jcountry-core.jar and b/lib/jcountry-core.jar differ
index 207f3055b3b9ebd5874341459478ee82204c4312..4d6b6c1d9de5ee390ce0a77d6897020ae114be12 100644 (file)
Binary files a/lib/jphone-core.jar and b/lib/jphone-core.jar differ
index eb8bfc75bd07f09568c9720733eeb4f2d5147ceb..8d00141fd7458a9da3e4bf3eb846cbb5cebf83d2 100644 (file)
@@ -5,5 +5,6 @@ libs.CopyLibs.prop-version=2.0
 libs.jpa20-persistence.classpath=\
     ${base}/jpa20-persistence/javax.persistence_2.1.0.v201304241213.jar
 libs.jpa20-persistence.displayName=Persistence (JPA 2.1)
-libs.jpa20-persistence.javadoc=
+libs.jpa20-persistence.javadoc=\
+    https://docs.oracle.com/javaee/7/api/
 libs.jpa20-persistence.prop-maven-dependencies=org.eclipse.persistence:javax.persistence:2.1.0:jar
index 7c117d2843f115eba8a84d3c5b8d1aa5e01f01ae..2de7e48dbeb65299194f1b9fcf902681684b9adc 100644 (file)
@@ -45,6 +45,7 @@ javac.classpath=\
 # Space-separated list of extra javac options
 javac.compilerargs=-Xlint:unchecked -Xlint:deprecation
 javac.deprecation=true
+javac.external.vm=false
 javac.processorpath=\
     ${javac.classpath}
 javac.source=1.7
index 84620d98cf364919e41ce2e58ed4fc5a7ce92ac5..5d24b7bf414156eeb86e9c79dab5d02a5be9c87e 100644 (file)
@@ -85,7 +85,7 @@ public class UserContact implements Contact, Comparable<Contact> {
        /**
         * Cellphone number
         */
-       @JoinColumn (name = "contact_cellphone_number_id")
+       @JoinColumn (name = "contact_cellphone_number_id", referencedColumnName = "cellphone_id")
        @OneToOne (targetEntity = CellphoneNumber.class, cascade = CascadeType.ALL)
        private DialableCellphoneNumber contactCellphoneNumber;
 
@@ -105,7 +105,7 @@ public class UserContact implements Contact, Comparable<Contact> {
        /**
         * Country code
         */
-       @JoinColumn (name = "contact_country_id", nullable = false)
+       @JoinColumn (name = "contact_country_id", nullable = false, referencedColumnName = "country_id")
        @OneToOne (targetEntity = CountryData.class, cascade = CascadeType.MERGE, optional = false, fetch = FetchType.EAGER)
        private Country contactCountry;
 
@@ -133,7 +133,7 @@ public class UserContact implements Contact, Comparable<Contact> {
        /**
         * Fax number
         */
-       @JoinColumn (name = "contact_fax_number_id")
+       @JoinColumn (name = "contact_fax_number_id", referencedColumnName = "fax_id")
        @OneToOne (targetEntity = FaxNumber.class, cascade = CascadeType.ALL)
        private DialableFaxNumber contactFaxNumber;
 
@@ -175,7 +175,7 @@ public class UserContact implements Contact, Comparable<Contact> {
        /**
         * Phone number
         */
-       @JoinColumn (name = "contact_phone_number_id")
+       @JoinColumn (name = "contact_phone_number_id", referencedColumnName = "phone_id")
        @OneToOne (targetEntity = LandLineNumber.class, cascade = CascadeType.ALL)
        private DialableLandLineNumber contactPhoneNumber;
 
@@ -212,6 +212,9 @@ public class UserContact implements Contact, Comparable<Contact> {
         * @param contactFamilyName Family name
         */
        public UserContact (final Gender contactGender, final String contactFirstName, final String contactFamilyName) {
+               // Call other constructor
+               this();
+
                // Set all
                this.contactGender = contactGender;
                this.contactFirstName = contactFirstName;
@@ -222,15 +225,10 @@ public class UserContact implements Contact, Comparable<Contact> {
         * Default constructor
         */
        public UserContact () {
+               // Default is not user's own contact
+               this.contactOwnContact = Boolean.FALSE;
        }
 
-       /**
-        * Compares two contacts with each other
-        * <p>
-        * @param contact Contact comparator
-        * <p>
-        * @return Comparison value
-        */
        @Override
        public int compareTo (final Contact contact) {
                // contact should not be null