]> git.mxchange.org Git - jfinancials-swing.git/commitdiff
They are model classes again ...
authorRoland Haeder <roland@mxchange.org>
Fri, 4 Sep 2015 17:25:01 +0000 (19:25 +0200)
committerRoland Haeder <roland@mxchange.org>
Fri, 4 Sep 2015 17:25:01 +0000 (19:25 +0200)
Signed-off-by:Roland Häder <roland@mxchange.org>

src/org/mxchange/addressbook/client/console/ConsoleClient.java
src/org/mxchange/addressbook/contact/book/BookContact.java [deleted file]
src/org/mxchange/addressbook/contact/user/UserContact.java [deleted file]
src/org/mxchange/addressbook/model/contact/book/BookContact.java [new file with mode: 0644]
src/org/mxchange/addressbook/model/contact/user/UserContact.java [new file with mode: 0644]

index 6b08d12d5f7f0fff74ba6d5208edfa5fc972b002..61ff2f70fddd3c8750ccd4cc0c8f817c9b74c358 100644 (file)
@@ -25,7 +25,7 @@ import java.util.Scanner;
 import org.mxchange.addressbook.application.AddressbookApplication;
 import org.mxchange.addressbook.client.AddressbookClient;
 import org.mxchange.addressbook.client.BaseAddressbookClient;
-import org.mxchange.addressbook.contact.user.UserContact;
+import org.mxchange.addressbook.model.contact.user.UserContact;
 import org.mxchange.addressbook.exceptions.ContactAlreadyAddedException;
 import org.mxchange.addressbook.manager.contact.ManageableAddressbookContact;
 import org.mxchange.addressbook.menu.Menu;
diff --git a/src/org/mxchange/addressbook/contact/book/BookContact.java b/src/org/mxchange/addressbook/contact/book/BookContact.java
deleted file mode 100644 (file)
index d4f4bf1..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-/*
- * Copyright (C) 2015 Roland Haeder
- *
- * This program is free software: you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation, either version 3 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program.  If not, see <http://www.gnu.org/licenses/>.
- */
-package org.mxchange.addressbook.contact.book;
-
-import org.mxchange.jcore.contact.BaseContact;
-import org.mxchange.jcore.contact.Contact;
-
-/**
- * A contact that can be placed into "contact books"
- *
- * @author Roland Haeder
- * @version 0.0
- */
-public class BookContact extends BaseContact implements Contact {
-
-       /**
-        * Default constructor, may only be used from database backend
-        */
-       public BookContact () {
-       }
-
-}
diff --git a/src/org/mxchange/addressbook/contact/user/UserContact.java b/src/org/mxchange/addressbook/contact/user/UserContact.java
deleted file mode 100644 (file)
index 652ea11..0000000
+++ /dev/null
@@ -1,64 +0,0 @@
-/*
- * Copyright (C) 2015 Roland Haeder
- *
- * This program is free software: you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation, either version 3 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program.  If not, see <http://www.gnu.org/licenses/>.
- */
-package org.mxchange.addressbook.contact.user;
-
-import java.text.MessageFormat;
-import org.mxchange.addressbook.contact.book.BookContact;
-import org.mxchange.jcore.contact.Contact;
-import org.mxchange.jcore.contact.gender.Gender;
-
-/**
- *
- * @author Roland Haeder
- * TODO After a Collection has been used in ContactManager, change to
- * BaseContact
- */
-public class UserContact extends BookContact implements Contact {
-
-       /**
-        * Creates own contact entry
-        *
-        * @param gender Gender to be set
-        * @param firstName First name to be set
-        * @param familyName Family name to be set
-        * @param companyName Company name
-        * TODO Add validation of data
-        */
-       public UserContact (final Gender gender, final String firstName, final String familyName, final String companyName) {
-               // Make sure all constructors are called
-               this();
-
-               // Trace message
-               this.getLogger().trace(MessageFormat.format("gender={0},firstName={1},familyName={2},companyName={3} - CALLED!", gender, firstName, familyName, companyName)); //NOI18N
-
-               // Update all data
-               this.setGender(gender);
-               this.setFirstName(firstName);
-               this.setFamilyName(familyName);
-               this.setCompanyName(companyName);
-
-               // Trace message
-               this.getLogger().trace("EXIT!"); //NOI18N
-       }
-
-       /**
-        * Default constructor, may only be used from database backend
-        */
-       public UserContact () {
-               this.enableFlagOwnContact();
-       }
-}
diff --git a/src/org/mxchange/addressbook/model/contact/book/BookContact.java b/src/org/mxchange/addressbook/model/contact/book/BookContact.java
new file mode 100644 (file)
index 0000000..0ee136f
--- /dev/null
@@ -0,0 +1,36 @@
+/*
+ * Copyright (C) 2015 Roland Haeder
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program.  If not, see <http://www.gnu.org/licenses/>.
+ */
+package org.mxchange.addressbook.model.contact.book;
+
+import org.mxchange.jcore.contact.BaseContact;
+import org.mxchange.jcore.contact.Contact;
+
+/**
+ * A contact that can be placed into "contact books"
+ *
+ * @author Roland Haeder
+ * @version 0.0
+ */
+public class BookContact extends BaseContact implements Contact {
+
+       /**
+        * Default constructor, may only be used from database backend
+        */
+       public BookContact () {
+       }
+
+}
diff --git a/src/org/mxchange/addressbook/model/contact/user/UserContact.java b/src/org/mxchange/addressbook/model/contact/user/UserContact.java
new file mode 100644 (file)
index 0000000..7b47c0e
--- /dev/null
@@ -0,0 +1,64 @@
+/*
+ * Copyright (C) 2015 Roland Haeder
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program.  If not, see <http://www.gnu.org/licenses/>.
+ */
+package org.mxchange.addressbook.model.contact.user;
+
+import java.text.MessageFormat;
+import org.mxchange.addressbook.model.contact.book.BookContact;
+import org.mxchange.jcore.contact.Contact;
+import org.mxchange.jcore.contact.gender.Gender;
+
+/**
+ *
+ * @author Roland Haeder
+ * TODO After a Collection has been used in ContactManager, change to
+ * BaseContact
+ */
+public class UserContact extends BookContact implements Contact {
+
+       /**
+        * Creates own contact entry
+        *
+        * @param gender Gender to be set
+        * @param firstName First name to be set
+        * @param familyName Family name to be set
+        * @param companyName Company name
+        * TODO Add validation of data
+        */
+       public UserContact (final Gender gender, final String firstName, final String familyName, final String companyName) {
+               // Make sure all constructors are called
+               this();
+
+               // Trace message
+               this.getLogger().trace(MessageFormat.format("gender={0},firstName={1},familyName={2},companyName={3} - CALLED!", gender, firstName, familyName, companyName)); //NOI18N
+
+               // Update all data
+               this.setGender(gender);
+               this.setFirstName(firstName);
+               this.setFamilyName(familyName);
+               this.setCompanyName(companyName);
+
+               // Trace message
+               this.getLogger().trace("EXIT!"); //NOI18N
+       }
+
+       /**
+        * Default constructor, may only be used from database backend
+        */
+       public UserContact () {
+               this.enableFlagOwnContact();
+       }
+}