From 1896014238a5b501393fb5790d117346e72887b5 Mon Sep 17 00:00:00 2001 From: Caleb Fontenot Date: Sun, 19 Nov 2023 23:18:28 -0600 Subject: [PATCH] Mr. Markou you stress me out so freaking much --- .gitignore | 7 + .../faces-config.NavData | 6 + .../nb-configuration.xml | 21 ++ .../EventsLabValueChangeListener/pom.xml | 83 ++++++ .../JakartaRestConfiguration.java | 13 + .../resources/JakartaEE10Resource.java | 20 ++ .../src/main/java/edu/slcc/TextListener.java | 20 ++ .../src/main/java/edu/slcc/TextListener1.java | 20 ++ .../java/edu/slcc/ValueChangedTestBean.java | 100 +++++++ .../main/resources/META-INF/persistence.xml | 7 + .../src/main/resources/messages.zip | Bin 0 -> 2654 bytes .../resources/messages/messages.properties | 4 + .../messages/messages_el_GR.properties | 5 + .../messages/messages_en_US.properties | 3 + .../messages/messages_es_ES.properties | 4 + .../messages/messages_ru_RU.properties | 4 + .../messages/messages_vi_VI.properties | 4 + .../messages/messages_zn_CN.properties | 4 + .../1-value-change-listener-primefaces.xhtml | 48 ++++ .../main/webapp/1-value-change-listener.xhtml | 47 ++++ .../webapp/1-value-change-listener_1.xhtml | 45 +++ .../src/main/webapp/WEB-INF/beans.xml | 6 + .../src/main/webapp/WEB-INF/faces-config.xml | 16 ++ .../src/main/webapp/WEB-INF/glassfish-web.xml | 25 ++ .../src/main/webapp/WEB-INF/web.xml | 26 ++ .../src/main/webapp/resources/css/styles.css | 3 + .../main/webapp/resources/images/ca_flag.gif | Bin 0 -> 3116 bytes .../main/webapp/resources/images/ca_flag.jpg | Bin 0 -> 1563 bytes .../main/webapp/resources/images/ch_flag.gif | Bin 0 -> 1594 bytes .../main/webapp/resources/images/cn_flag.jpg | Bin 0 -> 1566 bytes .../main/webapp/resources/images/de_flag.gif | Bin 0 -> 191 bytes .../main/webapp/resources/images/dn_flag.gif | Bin 0 -> 1417 bytes .../main/webapp/resources/images/el_flag.png | Bin 0 -> 1542 bytes .../main/webapp/resources/images/en_flag.gif | Bin 0 -> 1900 bytes .../main/webapp/resources/images/uk_flag.gif | Bin 0 -> 528 bytes .../main/webapp/resources/images/us_flag.jpg | Bin 0 -> 5040 bytes .../faces-config.NavData | 0 .../nb-configuration.xml | 21 ++ .../pom.xml | 42 +++ .../src/main/java/beans/TextListener.java | 27 ++ .../src/main/java/beans/TextListener1.java | 27 ++ .../main/java/beans/ValueChangedTestBean.java | 101 +++++++ .../JakartaRestConfiguration.java | 13 + .../resources/JakartaEE10Resource.java | 20 ++ .../main/resources/META-INF/persistence.xml | 7 + .../resources/messages/messages.properties | 4 + .../messages/messages_el_GR.properties | 5 + .../messages/messages_en_US.properties | 3 + .../messages/messages_es_ES.properties | 4 + .../messages/messages_ru_RU.properties | 4 + .../messages/messages_vi_VI.properties | 4 + .../messages/messages_zn_CN.properties | 4 + .../main/webapp/1-value-change-listener.xhtml | 46 ++++ .../src/main/webapp/WEB-INF/beans.xml | 6 + .../src/main/webapp/WEB-INF/faces-config.xml | 32 +++ .../src/main/webapp/WEB-INF/glassfish-web.xml | 25 ++ .../src/main/webapp/WEB-INF/web.xml | 24 ++ .../src/main/webapp/resources/css/styles.css | 28 ++ .../nb-configuration.xml | 21 ++ .../pom.xml | 52 ++++ .../src/main/java/beans/ControlRender.java | 111 ++++++++ .../JakartaRestConfiguration.java | 13 + .../resources/JakartaEE10Resource.java | 20 ++ .../main/resources/META-INF/persistence.xml | 7 + .../src/main/webapp/WEB-INF/beans.xml | 6 + .../src/main/webapp/WEB-INF/glassfish-web.xml | 25 ++ .../src/main/webapp/WEB-INF/web.xml | 24 ++ .../src/main/webapp/index.xhtml | 39 +++ .../main/webapp/resources/js/do_validation.js | 20 ++ .../faces-config.NavData | 0 .../nb-configuration.xml | 20 ++ .../LabEvents_CalebFontenot/pom.xml | 42 +++ .../src/main/java/beans/FormSettings.java | 31 +++ .../main/java/beans/FormSettingsLocale.java | 100 +++++++ .../src/main/java/beans/Person.java | 66 +++++ .../JakartaRestConfiguration.java | 13 + .../resources/JakartaEE10Resource.java | 20 ++ .../main/resources/META-INF/persistence.xml | 7 + .../resources/messages/messages.properties | 14 + .../resources/messages/messages_el.properties | 14 + .../resources/messages/messages_es.properties | 14 + .../resources/messages/messages_jp.properties | 14 + .../src/main/webapp/WEB-INF/beans.xml | 6 + .../src/main/webapp/WEB-INF/faces-config.xml | 32 +++ .../src/main/webapp/WEB-INF/glassfish-web.xml | 25 ++ .../src/main/webapp/WEB-INF/web.xml | 24 ++ .../main/webapp/confirm-registration.xhtml | 21 ++ .../src/main/webapp/index.xhtml | 19 ++ .../src/main/webapp/register1.xhtml | 52 ++++ .../src/main/webapp/register3.xhtml | 55 ++++ .../src/main/webapp/resources/css/styles.css | 28 ++ .../nb-configuration.xml | 21 ++ .../Assignments/SupplierPartsCalendar/pom.xml | 87 ++++++ .../JakartaRestConfiguration.java | 13 + .../resources/JakartaEE9Resource.java | 20 ++ .../edu/slcc/asdv/beans/SupplierBean.java | 133 +++++++++ .../src/main/java/edu/slcc/asdv/bl/DBase.java | 25 ++ .../java/edu/slcc/asdv/bl/DateValidator.java | 31 +++ .../edu/slcc/asdv/bl/UtilitiesDatabase.java | 99 +++++++ .../bl/part/DatabaseManipulationPart.java | 71 +++++ .../main/java/edu/slcc/asdv/bl/part/Part.java | 86 ++++++ .../DatabaseManipulationSupplier.java | 151 ++++++++++ .../edu/slcc/asdv/bl/supplier/Supplier.java | 136 +++++++++ .../main/resources/META-INF/persistence.xml | 7 + .../src/main/webapp/WEB-INF/beans.xml | 6 + .../src/main/webapp/WEB-INF/glassfish-web.xml | 25 ++ .../src/main/webapp/WEB-INF/web.xml | 24 ++ .../src/main/webapp/index.xhtml | 51 ++++ .../src/main/webapp/part.xhtml | 68 +++++ .../src/main/webapp/resources/css/styles.css | 71 +++++ .../src/main/webapp/supplier.xhtml | 67 +++++ .../nb-configuration.xml | 21 ++ .../pom.xml | 88 ++++++ .../JakartaRestConfiguration.java | 13 + .../resources/JakartaEE9Resource.java | 20 ++ .../edu/slcc/asdv/beans/SupplierBean.java | 166 +++++++++++ .../src/main/java/edu/slcc/asdv/bl/DBase.java | 30 ++ .../edu/slcc/asdv/bl/UtilitiesDatabase.java | 103 +++++++ .../bl/part/DatabaseManipulationPart.java | 104 +++++++ .../main/java/edu/slcc/asdv/bl/part/Part.java | 75 +++++ .../DatabaseManipulationSupplier.java | 228 ++++++++++++++++ .../edu/slcc/asdv/bl/supplier/Supplier.java | 138 ++++++++++ .../main/resources/META-INF/persistence.xml | 7 + .../src/main/webapp/WEB-INF/beans.xml | 6 + .../src/main/webapp/WEB-INF/glassfish-web.xml | 25 ++ .../src/main/webapp/WEB-INF/web.xml | 24 ++ .../src/main/webapp/index.xhtml | 51 ++++ .../src/main/webapp/resources/css/styles.css | 71 +++++ .../src/main/webapp/supplier.xhtml | 101 +++++++ .../src/main/webapp/supplier.xhtml | 5 +- .../nb-configuration.xml | 21 ++ .../suppliers_parts_calendar/pom.xml | 88 ++++++ .../JakartaRestConfiguration.java | 13 + .../resources/JakartaEE9Resource.java | 20 ++ .../edu/slcc/asdv/beans/SupplierBean.java | 148 ++++++++++ .../src/main/java/edu/slcc/asdv/bl/DBase.java | 28 ++ .../edu/slcc/asdv/bl/UtilitiesDatabase.java | 103 +++++++ .../bl/part/DatabaseManipulationPart.java | 104 +++++++ .../main/java/edu/slcc/asdv/bl/part/Part.java | 75 +++++ .../DatabaseManipulationSupplier.java | 258 ++++++++++++++++++ .../edu/slcc/asdv/bl/supplier/Supplier.java | 151 ++++++++++ .../main/resources/META-INF/persistence.xml | 7 + .../src/main/webapp/WEB-INF/beans.xml | 6 + .../src/main/webapp/WEB-INF/glassfish-web.xml | 25 ++ .../src/main/webapp/WEB-INF/web.xml | 24 ++ .../src/main/webapp/index.xhtml | 51 ++++ .../src/main/webapp/resources/css/styles.css | 71 +++++ .../src/main/webapp/supplier.xhtml | 75 +++++ Semester 2/SupplierPartsCalendar.zip | Bin 0 -> 19990 bytes 149 files changed, 5677 insertions(+), 2 deletions(-) create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/faces-config.NavData create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/nb-configuration.xml create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/pom.xml create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/src/main/java/asdv/eventslabvaluechangelistener/JakartaRestConfiguration.java create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/src/main/java/asdv/eventslabvaluechangelistener/resources/JakartaEE10Resource.java create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/src/main/java/edu/slcc/TextListener.java create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/src/main/java/edu/slcc/TextListener1.java create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/src/main/java/edu/slcc/ValueChangedTestBean.java create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/src/main/resources/META-INF/persistence.xml create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/src/main/resources/messages.zip create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/src/main/resources/messages/messages.properties create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/src/main/resources/messages/messages_el_GR.properties create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/src/main/resources/messages/messages_en_US.properties create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/src/main/resources/messages/messages_es_ES.properties create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/src/main/resources/messages/messages_ru_RU.properties create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/src/main/resources/messages/messages_vi_VI.properties create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/src/main/resources/messages/messages_zn_CN.properties create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/1-value-change-listener-primefaces.xhtml create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/1-value-change-listener.xhtml create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/1-value-change-listener_1.xhtml create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/WEB-INF/beans.xml create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/WEB-INF/faces-config.xml create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/WEB-INF/glassfish-web.xml create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/WEB-INF/web.xml create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/resources/css/styles.css create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/resources/images/ca_flag.gif create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/resources/images/ca_flag.jpg create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/resources/images/ch_flag.gif create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/resources/images/cn_flag.jpg create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/resources/images/de_flag.gif create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/resources/images/dn_flag.gif create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/resources/images/el_flag.png create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/resources/images/en_flag.gif create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/resources/images/uk_flag.gif create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/resources/images/us_flag.jpg create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/faces-config.NavData create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/nb-configuration.xml create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/pom.xml create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/java/beans/TextListener.java create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/java/beans/TextListener1.java create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/java/beans/ValueChangedTestBean.java create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/java/edu/slcc/asdv/caleb/eventslabvaluechangelistener_calebfontenot/JakartaRestConfiguration.java create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/java/edu/slcc/asdv/caleb/eventslabvaluechangelistener_calebfontenot/resources/JakartaEE10Resource.java create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/resources/META-INF/persistence.xml create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/resources/messages/messages.properties create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/resources/messages/messages_el_GR.properties create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/resources/messages/messages_en_US.properties create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/resources/messages/messages_es_ES.properties create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/resources/messages/messages_ru_RU.properties create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/resources/messages/messages_vi_VI.properties create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/resources/messages/messages_zn_CN.properties create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/webapp/1-value-change-listener.xhtml create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/webapp/WEB-INF/beans.xml create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/webapp/WEB-INF/faces-config.xml create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/webapp/WEB-INF/glassfish-web.xml create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/webapp/WEB-INF/web.xml create mode 100644 Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/webapp/resources/css/styles.css create mode 100644 Semester 2/Assignments/JavaScriptValidation_CalebFontenot/nb-configuration.xml create mode 100644 Semester 2/Assignments/JavaScriptValidation_CalebFontenot/pom.xml create mode 100644 Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/java/beans/ControlRender.java create mode 100644 Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/java/edu/slcc/asdv/caleb/javascriptvalidation_calebfontenot/JakartaRestConfiguration.java create mode 100644 Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/java/edu/slcc/asdv/caleb/javascriptvalidation_calebfontenot/resources/JakartaEE10Resource.java create mode 100644 Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/resources/META-INF/persistence.xml create mode 100644 Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/webapp/WEB-INF/beans.xml create mode 100644 Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/webapp/WEB-INF/glassfish-web.xml create mode 100644 Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/webapp/WEB-INF/web.xml create mode 100644 Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/webapp/index.xhtml create mode 100644 Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/webapp/resources/js/do_validation.js create mode 100644 Semester 2/Assignments/LabEvents_CalebFontenot/faces-config.NavData create mode 100644 Semester 2/Assignments/LabEvents_CalebFontenot/nb-configuration.xml create mode 100644 Semester 2/Assignments/LabEvents_CalebFontenot/pom.xml create mode 100644 Semester 2/Assignments/LabEvents_CalebFontenot/src/main/java/beans/FormSettings.java create mode 100644 Semester 2/Assignments/LabEvents_CalebFontenot/src/main/java/beans/FormSettingsLocale.java create mode 100644 Semester 2/Assignments/LabEvents_CalebFontenot/src/main/java/beans/Person.java create mode 100644 Semester 2/Assignments/LabEvents_CalebFontenot/src/main/java/edu/slcc/asdv/caleb/labevents_calebfontenot/JakartaRestConfiguration.java create mode 100644 Semester 2/Assignments/LabEvents_CalebFontenot/src/main/java/edu/slcc/asdv/caleb/labevents_calebfontenot/resources/JakartaEE10Resource.java create mode 100644 Semester 2/Assignments/LabEvents_CalebFontenot/src/main/resources/META-INF/persistence.xml create mode 100644 Semester 2/Assignments/LabEvents_CalebFontenot/src/main/resources/messages/messages.properties create mode 100644 Semester 2/Assignments/LabEvents_CalebFontenot/src/main/resources/messages/messages_el.properties create mode 100644 Semester 2/Assignments/LabEvents_CalebFontenot/src/main/resources/messages/messages_es.properties create mode 100644 Semester 2/Assignments/LabEvents_CalebFontenot/src/main/resources/messages/messages_jp.properties create mode 100644 Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/WEB-INF/beans.xml create mode 100644 Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/WEB-INF/faces-config.xml create mode 100644 Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/WEB-INF/glassfish-web.xml create mode 100644 Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/WEB-INF/web.xml create mode 100644 Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/confirm-registration.xhtml create mode 100644 Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/index.xhtml create mode 100644 Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/register1.xhtml create mode 100644 Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/register3.xhtml create mode 100644 Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/resources/css/styles.css create mode 100644 Semester 2/Assignments/SupplierPartsCalendar/nb-configuration.xml create mode 100644 Semester 2/Assignments/SupplierPartsCalendar/pom.xml create mode 100644 Semester 2/Assignments/SupplierPartsCalendar/src/main/java/com/mycompany/supplierspartsdatabase/JakartaRestConfiguration.java create mode 100644 Semester 2/Assignments/SupplierPartsCalendar/src/main/java/com/mycompany/supplierspartsdatabase/resources/JakartaEE9Resource.java create mode 100644 Semester 2/Assignments/SupplierPartsCalendar/src/main/java/edu/slcc/asdv/beans/SupplierBean.java create mode 100644 Semester 2/Assignments/SupplierPartsCalendar/src/main/java/edu/slcc/asdv/bl/DBase.java create mode 100644 Semester 2/Assignments/SupplierPartsCalendar/src/main/java/edu/slcc/asdv/bl/DateValidator.java create mode 100644 Semester 2/Assignments/SupplierPartsCalendar/src/main/java/edu/slcc/asdv/bl/UtilitiesDatabase.java create mode 100644 Semester 2/Assignments/SupplierPartsCalendar/src/main/java/edu/slcc/asdv/bl/part/DatabaseManipulationPart.java create mode 100644 Semester 2/Assignments/SupplierPartsCalendar/src/main/java/edu/slcc/asdv/bl/part/Part.java create mode 100644 Semester 2/Assignments/SupplierPartsCalendar/src/main/java/edu/slcc/asdv/bl/supplier/DatabaseManipulationSupplier.java create mode 100644 Semester 2/Assignments/SupplierPartsCalendar/src/main/java/edu/slcc/asdv/bl/supplier/Supplier.java create mode 100644 Semester 2/Assignments/SupplierPartsCalendar/src/main/resources/META-INF/persistence.xml create mode 100644 Semester 2/Assignments/SupplierPartsCalendar/src/main/webapp/WEB-INF/beans.xml create mode 100644 Semester 2/Assignments/SupplierPartsCalendar/src/main/webapp/WEB-INF/glassfish-web.xml create mode 100644 Semester 2/Assignments/SupplierPartsCalendar/src/main/webapp/WEB-INF/web.xml create mode 100644 Semester 2/Assignments/SupplierPartsCalendar/src/main/webapp/index.xhtml create mode 100644 Semester 2/Assignments/SupplierPartsCalendar/src/main/webapp/part.xhtml create mode 100644 Semester 2/Assignments/SupplierPartsCalendar/src/main/webapp/resources/css/styles.css create mode 100644 Semester 2/Assignments/SupplierPartsCalendar/src/main/webapp/supplier.xhtml create mode 100644 Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/nb-configuration.xml create mode 100644 Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/pom.xml create mode 100644 Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/com/mycompany/supplierspartsdatabase/JakartaRestConfiguration.java create mode 100644 Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/com/mycompany/supplierspartsdatabase/resources/JakartaEE9Resource.java create mode 100644 Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/edu/slcc/asdv/beans/SupplierBean.java create mode 100644 Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/edu/slcc/asdv/bl/DBase.java create mode 100644 Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/edu/slcc/asdv/bl/UtilitiesDatabase.java create mode 100644 Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/edu/slcc/asdv/bl/part/DatabaseManipulationPart.java create mode 100644 Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/edu/slcc/asdv/bl/part/Part.java create mode 100644 Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/edu/slcc/asdv/bl/supplier/DatabaseManipulationSupplier.java create mode 100644 Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/edu/slcc/asdv/bl/supplier/Supplier.java create mode 100644 Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/resources/META-INF/persistence.xml create mode 100644 Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/webapp/WEB-INF/beans.xml create mode 100644 Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/webapp/WEB-INF/glassfish-web.xml create mode 100644 Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/webapp/WEB-INF/web.xml create mode 100644 Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/webapp/index.xhtml create mode 100644 Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/webapp/resources/css/styles.css create mode 100644 Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/webapp/supplier.xhtml create mode 100644 Semester 2/Assignments/suppliers_parts_calendar/nb-configuration.xml create mode 100644 Semester 2/Assignments/suppliers_parts_calendar/pom.xml create mode 100644 Semester 2/Assignments/suppliers_parts_calendar/src/main/java/com/mycompany/supplierspartsdatabase/JakartaRestConfiguration.java create mode 100644 Semester 2/Assignments/suppliers_parts_calendar/src/main/java/com/mycompany/supplierspartsdatabase/resources/JakartaEE9Resource.java create mode 100644 Semester 2/Assignments/suppliers_parts_calendar/src/main/java/edu/slcc/asdv/beans/SupplierBean.java create mode 100644 Semester 2/Assignments/suppliers_parts_calendar/src/main/java/edu/slcc/asdv/bl/DBase.java create mode 100644 Semester 2/Assignments/suppliers_parts_calendar/src/main/java/edu/slcc/asdv/bl/UtilitiesDatabase.java create mode 100644 Semester 2/Assignments/suppliers_parts_calendar/src/main/java/edu/slcc/asdv/bl/part/DatabaseManipulationPart.java create mode 100644 Semester 2/Assignments/suppliers_parts_calendar/src/main/java/edu/slcc/asdv/bl/part/Part.java create mode 100644 Semester 2/Assignments/suppliers_parts_calendar/src/main/java/edu/slcc/asdv/bl/supplier/DatabaseManipulationSupplier.java create mode 100644 Semester 2/Assignments/suppliers_parts_calendar/src/main/java/edu/slcc/asdv/bl/supplier/Supplier.java create mode 100644 Semester 2/Assignments/suppliers_parts_calendar/src/main/resources/META-INF/persistence.xml create mode 100644 Semester 2/Assignments/suppliers_parts_calendar/src/main/webapp/WEB-INF/beans.xml create mode 100644 Semester 2/Assignments/suppliers_parts_calendar/src/main/webapp/WEB-INF/glassfish-web.xml create mode 100644 Semester 2/Assignments/suppliers_parts_calendar/src/main/webapp/WEB-INF/web.xml create mode 100644 Semester 2/Assignments/suppliers_parts_calendar/src/main/webapp/index.xhtml create mode 100644 Semester 2/Assignments/suppliers_parts_calendar/src/main/webapp/resources/css/styles.css create mode 100644 Semester 2/Assignments/suppliers_parts_calendar/src/main/webapp/supplier.xhtml create mode 100644 Semester 2/SupplierPartsCalendar.zip diff --git a/.gitignore b/.gitignore index 45c20d7..ccbbf20 100644 --- a/.gitignore +++ b/.gitignore @@ -67,3 +67,10 @@ /Semester 2/Exams/ProgrammingExam1Question5/target/ /Semester 2/Assignments/suppliers_parts_old/target/ /Semester 2/Assignments/SuppliersPartsDatabase_old/target/ +/Semester 2/Assignments/SupplierPartsCalendar/target/ +/Semester 2/Assignments/suppliers_parts_calendar/target/ +/Semester 2/Assignments/JavaScriptValidation_CalebFontenot/target/ +/Semester 2/Assignments/LabEvents_CalebFontenot/target/ +/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/target/ +/Semester 2/Assignments/EventsLabValueChangeListener/target/ +/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/target/ diff --git a/Semester 2/Assignments/EventsLabValueChangeListener/faces-config.NavData b/Semester 2/Assignments/EventsLabValueChangeListener/faces-config.NavData new file mode 100644 index 0000000..298bfc5 --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener/faces-config.NavData @@ -0,0 +1,6 @@ + + + + + + diff --git a/Semester 2/Assignments/EventsLabValueChangeListener/nb-configuration.xml b/Semester 2/Assignments/EventsLabValueChangeListener/nb-configuration.xml new file mode 100644 index 0000000..f89ff8d --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener/nb-configuration.xml @@ -0,0 +1,21 @@ + + + + + + 10-web + gfv700ee10 + Facelets + JDK_11__System_ + + diff --git a/Semester 2/Assignments/EventsLabValueChangeListener/pom.xml b/Semester 2/Assignments/EventsLabValueChangeListener/pom.xml new file mode 100644 index 0000000..e7f5664 --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener/pom.xml @@ -0,0 +1,83 @@ + + 4.0.0 + asdv + EventsLabValueChangeListener + 1 + war + EventsLabValueChangeListener-1 + + + 11 + 11 + ${project.build.directory}/endorsed + UTF-8 + false + 10.0.0 + + + + + jakarta.platform + jakarta.jakartaee-api + ${jakartaee} + provided + + + org.primefaces + primefaces + 13.0.2 + jakarta + + + + + + + org.apache.maven.plugins + maven-compiler-plugin + 3.8.1 + + 11 + 11 + + ${endorsed.dir} + + + + + org.apache.maven.plugins + maven-war-plugin + 2.3 + + false + + + + org.apache.maven.plugins + maven-dependency-plugin + 2.6 + + + validate + + copy + + + ${endorsed.dir} + true + + + jakarta.platform + jakarta.jakartaee-api + ${jakartaee} + jar + + + + + + + + + \ No newline at end of file diff --git a/Semester 2/Assignments/EventsLabValueChangeListener/src/main/java/asdv/eventslabvaluechangelistener/JakartaRestConfiguration.java b/Semester 2/Assignments/EventsLabValueChangeListener/src/main/java/asdv/eventslabvaluechangelistener/JakartaRestConfiguration.java new file mode 100644 index 0000000..0b8ac7f --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener/src/main/java/asdv/eventslabvaluechangelistener/JakartaRestConfiguration.java @@ -0,0 +1,13 @@ +package asdv.eventslabvaluechangelistener; + +import jakarta.ws.rs.ApplicationPath; +import jakarta.ws.rs.core.Application; + +/** + * Configures Jakarta RESTful Web Services for the application. + * @author Juneau + */ +@ApplicationPath("resources") +public class JakartaRestConfiguration extends Application { + +} diff --git a/Semester 2/Assignments/EventsLabValueChangeListener/src/main/java/asdv/eventslabvaluechangelistener/resources/JakartaEE10Resource.java b/Semester 2/Assignments/EventsLabValueChangeListener/src/main/java/asdv/eventslabvaluechangelistener/resources/JakartaEE10Resource.java new file mode 100644 index 0000000..a474cbd --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener/src/main/java/asdv/eventslabvaluechangelistener/resources/JakartaEE10Resource.java @@ -0,0 +1,20 @@ +package asdv.eventslabvaluechangelistener.resources; + +import jakarta.ws.rs.GET; +import jakarta.ws.rs.Path; +import jakarta.ws.rs.core.Response; + +/** + * + * @author + */ +@Path("jakartaee10") +public class JakartaEE10Resource { + + @GET + public Response ping(){ + return Response + .ok("ping Jakarta EE") + .build(); + } +} diff --git a/Semester 2/Assignments/EventsLabValueChangeListener/src/main/java/edu/slcc/TextListener.java b/Semester 2/Assignments/EventsLabValueChangeListener/src/main/java/edu/slcc/TextListener.java new file mode 100644 index 0000000..5bb199d --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener/src/main/java/edu/slcc/TextListener.java @@ -0,0 +1,20 @@ +package edu.slcc; + +import jakarta.faces.context.FacesContext; +import jakarta.faces.event.AbortProcessingException; +import jakarta.faces.event.ValueChangeEvent; +import jakarta.faces.event.ValueChangeListener; + + +public class TextListener implements ValueChangeListener +{ + @Override + public void processValueChange(ValueChangeEvent event) + throws AbortProcessingException + { + //FacesContext context = FacesContext.getCurrentInstance(); + Object o = event.getNewValue(); + String s = o.toString(); + System.out.println(s); + } +} diff --git a/Semester 2/Assignments/EventsLabValueChangeListener/src/main/java/edu/slcc/TextListener1.java b/Semester 2/Assignments/EventsLabValueChangeListener/src/main/java/edu/slcc/TextListener1.java new file mode 100644 index 0000000..1f3f24e --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener/src/main/java/edu/slcc/TextListener1.java @@ -0,0 +1,20 @@ +package edu.slcc; + +import jakarta.faces.context.FacesContext; +import jakarta.faces.event.AbortProcessingException; +import jakarta.faces.event.ValueChangeEvent; +import jakarta.faces.event.ValueChangeListener; + + +public class TextListener1 implements ValueChangeListener +{ + @Override + public void processValueChange(ValueChangeEvent event) + throws AbortProcessingException + { + //FacesContext context = FacesContext.getCurrentInstance(); + Object o = event.getNewValue(); + String s = o.toString(); + System.out.println(s+ " 888" + "second listener called"); + } +} diff --git a/Semester 2/Assignments/EventsLabValueChangeListener/src/main/java/edu/slcc/ValueChangedTestBean.java b/Semester 2/Assignments/EventsLabValueChangeListener/src/main/java/edu/slcc/ValueChangedTestBean.java new file mode 100644 index 0000000..5f15fc6 --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener/src/main/java/edu/slcc/ValueChangedTestBean.java @@ -0,0 +1,100 @@ +package edu.slcc; + +import jakarta.inject.Named; +import jakarta.enterprise.context.SessionScoped; +import java.io.Serializable; +import java.util.Arrays; +import java.util.LinkedHashMap; +import java.util.List; +import java.util.Locale; +import java.util.Map; +import jakarta.faces.context.FacesContext; +import jakarta.faces.event.ValueChangeEvent; + +@Named(value = "vst") +@SessionScoped +public class ValueChangedTestBean implements Serializable +{ + private String name; + private String language = "en"; + private Map languagesMap; + + public ValueChangedTestBean() + { + languagesMap = new LinkedHashMap(); + languagesMap.put("US", "en");//usa + languagesMap.put("ES", "es");//spain + languagesMap.put("GR", "el");//greece + languagesMap.put("RU", "ru");//russia + languagesMap.put("CN", "zn");//china + languagesMap.put("VI", "vi");//vietnam + } + + public String getName() + { + return name; + } + + public String getLanguage() + { + return language; + } + + public void setLanguage(String language) + { + this.language = language; + } + + public void setName(String name) + { + this.name = name; + } + + public Map getLanguagesMap() + { + List list = Arrays.asList("en", "gr", "es", "ru", "zn", "vi"); + return languagesMap; + } + + public List getLanguages() + { + List list = Arrays.asList("en", "gr", "es", "ru", "zn", "vi"); + return list; + } +public void inputTextValueChangeListener( ValueChangeEvent event ) +{ + Object o = event.getNewValue(); + String s = o.toString(); + System.out.println(s); +} + public void languageChanged(ValueChangeEvent event) + { + FacesContext contextInstance = FacesContext.getCurrentInstance(); + for (Map.Entry entry : this.languagesMap.entrySet()) + { + Object o = event.getNewValue(); + String lang = entry.getValue(); + if (lang.equals(o.toString())) + { + contextInstance.getViewRoot().setLocale( + new Locale(o.toString(), entry.getKey())); + this.language = o.toString(); + name = null; + break; + } + } + //contextInstance.renderResponse(); + } + + public String newData() + { + if (name == null) + { + return ""; + } + return "

Data in
" + + "Your name: " + name + "
" + + "Your language: " + language + "
" + + "

"; + } +} diff --git a/Semester 2/Assignments/EventsLabValueChangeListener/src/main/resources/META-INF/persistence.xml b/Semester 2/Assignments/EventsLabValueChangeListener/src/main/resources/META-INF/persistence.xml new file mode 100644 index 0000000..7582bf1 --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener/src/main/resources/META-INF/persistence.xml @@ -0,0 +1,7 @@ + + + + + + + diff --git a/Semester 2/Assignments/EventsLabValueChangeListener/src/main/resources/messages.zip b/Semester 2/Assignments/EventsLabValueChangeListener/src/main/resources/messages.zip new file mode 100644 index 0000000000000000000000000000000000000000..fa8bf5c08faccf2e43c358a19cc9cd32fb9cb32d GIT binary patch literal 2654 zcmWIWW@Zs#0D*%>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&!4fpG}4MjytAC$;KAw-31hMYWHe z37dVSRuky + + + + + + #{msgs.indexWindowTitle} + + +

#{msgs.indexWindowTitle}

+ + + + + + + + + + + + + + + + + + + + + + +
+ + + diff --git a/Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/1-value-change-listener.xhtml b/Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/1-value-change-listener.xhtml new file mode 100644 index 0000000..082087a --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/1-value-change-listener.xhtml @@ -0,0 +1,47 @@ + + + + + + + #{msgs.indexWindowTitle} + + +

#{msgs.indexWindowTitle}

+ + + + + + + + + + + + + + + + + + + + + + +
+ + + diff --git a/Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/1-value-change-listener_1.xhtml b/Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/1-value-change-listener_1.xhtml new file mode 100644 index 0000000..18d6311 --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/1-value-change-listener_1.xhtml @@ -0,0 +1,45 @@ + + + + + + + #{msgs.indexWindowTitle} + + +

#{msgs.indexWindowTitle}

+ + + + + + + + + + + + + + + + + + + +
+ + + diff --git a/Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/WEB-INF/beans.xml b/Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/WEB-INF/beans.xml new file mode 100644 index 0000000..9dfae34 --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/WEB-INF/beans.xml @@ -0,0 +1,6 @@ + + + \ No newline at end of file diff --git a/Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/WEB-INF/faces-config.xml b/Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/WEB-INF/faces-config.xml new file mode 100644 index 0000000..bdb99db --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/WEB-INF/faces-config.xml @@ -0,0 +1,16 @@ + + + + + + + messages.messages + msgs + + + + + diff --git a/Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/WEB-INF/glassfish-web.xml b/Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/WEB-INF/glassfish-web.xml new file mode 100644 index 0000000..673cc06 --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/WEB-INF/glassfish-web.xml @@ -0,0 +1,25 @@ + + + + + + + + Keep a copy of the generated servlet class' java code. + + + diff --git a/Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/WEB-INF/web.xml b/Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/WEB-INF/web.xml new file mode 100644 index 0000000..847f134 --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/WEB-INF/web.xml @@ -0,0 +1,26 @@ + + + + jakarta.faces.PROJECT_STAGE + Development + + + Faces Servlet + jakarta.faces.webapp.FacesServlet + 1 + + + Faces Servlet + /faces/* + + + + 30 + + + + faces/1-value-change-listener-primefaces.xhtml + + diff --git a/Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/resources/css/styles.css b/Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/resources/css/styles.css new file mode 100644 index 0000000..69f1a60 --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/resources/css/styles.css @@ -0,0 +1,3 @@ +.columns { + vertical-align: top; +} diff --git a/Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/resources/images/ca_flag.gif b/Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/resources/images/ca_flag.gif new file mode 100644 index 0000000000000000000000000000000000000000..dd950176fc5422d8ca7e044a153e565df2de6508 GIT binary patch literal 3116 zcmeIx`#;l*9|!QyZkcOr!%km1v)rd}QmGt`Hn*mf+^0xO%4KvGl5DQ!avCCvW2z-Y zLUU~xDU=XXtFtr9b!D;;Qv2@w8{fzG{dhj!kJqoS_v7()c6GAd8{7p11K$9E0|2c6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5HHJ*0wYsVYR zf8&%ae^$m<`#W87ZfZ}fvEJL3YBta3B;7EO*!~CdanmdsSX&#MaJm1klQ3I*y9X?)?y4qv6 zb`4M9iFI`E85kNfoynw+Or{|Q*spUHjE8_e!ML|`Eve*e`qFcb2O1p3_H1 z&HP@*Pi3KfJ@z2Hcbe^Z0aCp&Lf31j4_=UFLU)9R*j?~>Z8n)#24g0>RRA#Ox^nex zBdMq#VQRNHU{#BpcEWxmV82WDt-bkvdt2hST~h_XOU?}C4Xd&Ob$_)5`KFmpfUkW|h(fa<=MOxc)OuCluoKPaH=f2lZSK4U%TNtUl= zWr`5`x~_)#yPML#KATXo%6)0&HEa-n2wXZ*&;V-dF~!*1a)$ms#|Y9 z;dr9DjZGFAnKWbL?P5wEk!OA|{&}UZK7k$HNc`Po-!;b1fbt|)VaN`|)VZl8XoQ}X z>H*cB$KV;3iM}NM@X)^7KWQ)f8)mnzKN!!@SaCLSnLi!c_D-p73ENdFp(KSp58*Df zZ3~oMI*{=9?>3yDs8NZPbK%SPc@VgZXi-zNThw)f))4-*?c|Hg)4Cmn)hC_5*b19w z7bF+B*MBbk)p2NQAZG2&^91QL+7GU0)XlNGX~b5u5*_{?f}pSEGV{*yVCUfhcrR{T_pdhb+BZi9G5EJm_5?5eu$M! I2Y~(m1q7eyr~m)} literal 0 HcmV?d00001 diff --git a/Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/resources/images/ca_flag.jpg b/Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/resources/images/ca_flag.jpg new file mode 100644 index 0000000000000000000000000000000000000000..1b051a8c0ad4dc8414475bfe14d09ea310087ce9 GIT binary patch literal 1563 zcmex=Tj zUd2?$)Y#C(R8z~uz|_>#NZ&xu)KE_o$TZb7(=s*H0*adHXc?QBn(7z=)tcz&{6D}T z$id*vFpZf}iGfLwky()O{}BcmpaYq~hyeyz*w{H3nOK>DvZewIjLb|-94suXtPp8N z1}0_}K~_aJb|FK@;*Fb3Oal{zl?oe0j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p/resources/images/ch_flag.gif b/Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/resources/images/ch_flag.gif new file mode 100644 index 0000000000000000000000000000000000000000..99eeec9f4b9b29115a8f338d2c1e439f5ceaaba0 GIT binary patch literal 1594 zcmeIx{WIGK90%}E9uSf%DRDIMIE)sH372+Eka`S@Do3;v^Kj^f)Wgn9uc%V3Gulk8 zs?n+%<$^XIwy1_igrsDoZK!JIvM#q}8+WPMZQ0k~v3>4!?|c9H`P_Y?W25Ltvzp-~ zyaf;eOae>+NRY&W6e(Dc?fw)fRYI+CMaV-go9t`$0bh`VlaQz%U7hDKJQ2 z8zF^lIczIoTLngh8jKn+Zh%n>dk8)38Njp+CL@^kz+{5|=Rb7;-~Da(e*thNAbQgo zLc!xYobBOLGGX^jgUvf}Ap!`$fX2LExGo#MGuPr8*+hvQ>6yQZv0{#U3+^toQ?uor zv7^0;8}w5Bx(~xMzKcr!-p=Yl-}0T9+&$m(wDZ0G$yY4WAf9^X!6Xg zNIecUjMoxalND==95-mGPVw=JH+?0uZ=D7u#pc-f{~-A6JZR85HOrg=Vv4P*$U(d#m3p_^?e^47Rh z5th0vAkuU?v~`4KO>OHji3P`eB{txueJY)ujAr8+>f2Ac-{U~Yea~5}gYU3?3JoQk z;ly3*=q$u<{WKHL$WOv1kZ{A?gD%h0*P4!Shn-oWY*Yp-fRe>5kEC=*R$Tm~_Yi@+ zuk7d&ttZm2u~Q)UjcF;Tzk2YCKEmL%>T zxGoG%pYAkwlT|s2_j+Z;kIetU3#-u9UwVkl$(#~Np8Fz|j}Pk{nyrXp{V{bQlTso* zWV^_lvuMDNTy$w!7s|XE?ia}qkNy%M_g~B7EoLiNfvLf-Iyv*l{^FNDjsBZZmK0&F zNM4Rwcv7nB@Kcm262qEHS5Ev!C|ym+Yz|uC6o-~S`#3{<_W7xn1mm;3TYe%&w6?W(baqXeJZ0*%=`&`|TC{k{(q+q6tX#Ee^OmjKw(r=v>(JpNM~@vpaq`rq z%U7;myME*5t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Q z#f(&7?kU@Ush49zy~}Z(*$lro|DKxX((qT=D(xoAjrn)imnbv6k-uno8W_lL>Xu3i zCj9T{i!@{Wmi}G)ZU@6}_mVT4fVpvZ{7W~M8}^Hmr};Mgz4_P6T{)>mss&%JzHGizGD*=u37B_iXeT!B9eDWVpZrbErOpeK9@LwKrObIQ z{Nd^3`x{$C8NY>tcnS4&$A!XxMajg%dBD=+r>u8`U_!m?u}V9}Z_mqh5?veqib_8J z2@DysH8mcdJ%3J!@pFz8VT)g1KVE**a!D~j@Waz!+F6Osa}Vs7tNZuwdAIl)uwZBK MboFyt=akR{05-G{X#fBK literal 0 HcmV?d00001 diff --git a/Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/resources/images/en_flag.gif b/Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/resources/images/en_flag.gif new file mode 100644 index 0000000000000000000000000000000000000000..4483f69495d92f2e9b77ea2424f8b61165b085a1 GIT binary patch literal 1900 zcmV-y2b1_mNk%w1VVnWk0J8u9000000A>IHnE(L)GnxMYnE(LH0L%aY{{R60W&r=p z0RR60W&oLHGXVep|IEzHEC2ui0Gt8Y06+x(P{>KEy*TU5yZ>P5A!KQuXsWJk>%MR- z&vb3yFy}ZTw)dAGup%5ziber4gKIjU(5Q4uZ6&YRtadx9dcWYXc#OjCmc27CslK+^ z=d5~8uiNkVynfH``~QG}f`fuOYi@^da*0N0K#mrKl9QB`mY0~Bd0d>Go}V0KqNAjx zrX+}Ok8_QzLv*dGMyIs3wzn}pcOrPayCJ>6zaYUun#ah=%FE2KpwH0Jsm;{Y*4NjF z5|AE3+#TMG!rS7+Yu_KZ>g(*L8qTY-zVgEK=Jp@(814N1{!xnpnkkotpf4@h5-MEC zun-#x2EjpWH1So%M;Bu?+{m$G!VUiT?nUet2M#)LB{hcn$FikM7SdwMoXO;+&6_Me z>fFh*r_Y~2g9;r=w5ZWJIFl+}%CxD|r%fOt?uiw9b0}F0Pv#?=lgA?BZnetWRcq37sG&Gs< zNyV5?3Dh=lv!X?HLt8yex-=KjsE@vL1-Y`WkdhzQlPwZm=G&t@x6AA<*gr8AZQ+ycWP~3(b zZjj-JHasZeh$NP1;)y7#0pf}*w&>!EFvck3jO(OmRn6)uDo|y@XDL|LzJx3rB z=Qx)^IMKwHI0l&eL%UI;5@othKu zg2SfsYi0wkT41ZC{$ko3v!bGE?6HcuajUGorg5zg+Xm5Xw4)Xop@r3vo9CzChP&gK z)3j@nvaG_pY-H*l`RBcc)oWz2DDgXPsIyR8t-C6{OK^koULf$m_%@8#!h`+GoVn|v zTdoEWN1U#z93$-PqG`UGabOOY42{0xT6`|W?Xesl$~Pw4v2imy>g=R2=V#41IF{#TV(wg*I-}awO>A$ZT8t{ zr>*wdY`5)pl4Hj$_uO>XZTH=H=N;ACeE045-+%`$_~3*OuJ_@HC$9M7j5qH1%)+efT_6SZ-J+|BE8a}V% zW0Y-u=iirp1>W;R`}^2;&XvEMs$8+lh|0ee{m_RC&Lf)k z(q%xLCGAW#{Lc+1&_2SH>R^xoqN9Z9yB?~;P1(Deu&i?~t1+=+wlU%nM>s+$PLYc6 zvm*X3_~$eLvT%jv(V{I>mBZ#;&xU8zVH(Xi!w!gXj6|GG97Qt6FuqYUpK+odllVla zF^`9L#3L5p=Ry2bd>R zVG;r<$WlhnnF)ku518o=0&*{g$|I#V14hlRqy;-SstwasmU8|5+)$NrEeNEk8rw~}Z z4mJu#O{`)U%h<*`_OXzStYjxk*~(h>vVuFTW;e^(&U*H5O|Ej6D9haDI`_HI mjjnX3OWo>P_qxkCu6DP}-R^q#yWkD4c*jfL@_r!#0029lfa{q6 literal 0 HcmV?d00001 diff --git a/Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/resources/images/uk_flag.gif b/Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/resources/images/uk_flag.gif new file mode 100644 index 0000000000000000000000000000000000000000..3acb3ac6c509964efadc78e9cc19ac73c4a7afac GIT binary patch literal 528 zcmZ?wbhEHbRAvxk_`<;O|Np;_fBu~P@c-G_bN`3mKC3liu_jMdBD-3 zKP#@%$|5ABrf>4p!opKQwLg~~_`$-ymVu$6n1Nvm1H&8!hINb#xPT5w0%R8h>wksE zJ!ezqJ@;7K-Mmlh=o+>J@5xJE2fKt!_i~(Yd!|YQ(^DY{)oF~k8PdNnwz@2KVb~Fn z#Sp&4+wulOfAV{AnP)x%2Z9AzUHm3FEDVyo!DNvgo@dF(A|_I2UQv+3m0li}J28bL zJu_clNYE=akdcX5Ok9kOk=b9YwA>)QKBy~bu~-+|Mh2!*Gd>>nef!zj4((^-5MRQ< zyzSJXv*)-)YA%V2T@t%~<@l28ckW&m)xP!U@sp>|9zJ{d>aq6yD|aq0K7RMhSEBbg0>wYnnz$gx8}+QD&BahZ8wF zd6}gc<2;3&JQI&`GbpUET%^%3oypL5jY^8p0R}r(hPgX39xI>W2w~ZJGO0;}VR4z7 z#e_rc3=I=4%F-SxE>v5@qRfy|b0o_>%q*g7!kf-XOeS2)TFVMH99ql0Q&_6!fhZG$ z;y>e{)RfZX)D#6XBUJ?lh4S)py`se8f~3@Grcy^NCF I90mq!0Gk!ciU0rr literal 0 HcmV?d00001 diff --git a/Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/resources/images/us_flag.jpg b/Semester 2/Assignments/EventsLabValueChangeListener/src/main/webapp/resources/images/us_flag.jpg new file mode 100644 index 0000000000000000000000000000000000000000..f586f66a7743722009e1f68e426019382484b7eb GIT binary patch literal 5040 zcmd5F5}_ST3}5`Hx?C8KkKU z?SZZl39}$MO#)GqfWL&u5JXS_Y)1+I^&-d-L{M<5dAdYOzu7xb);cK|cqW>#pKZT9yYK0~c37~jH zO$dfMW;O5x1H4D?ZU-^F78RE|cu~V8w5p~9`={Ew&z?6^OEK6z)#(}4d}Pj}Q2!*& zn_o#H?BaeL+8l>N8}8kY*_f!ebK3gbb^(sqwk~FFsX#iRB9QMs*{XW-RVu&Ai>OPS za`05xh+?v0`HM|YGHfJ+`_Aa?3Aq+`@MPFX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0SR196M9ZY zhC5&>&-lyrHrxCFlywfY*jO|mjDUcP*(DrGMPk9+lGQmTKcx1%ezOJUQ&sazIJjLV z*NCiAnG7uVKS~PBK+HP*#ziB`a@8GndB`ldxG?~Qbk;g=i6Q8nm z#*2Tgu+s`z!LoG)D^f-Jch!D!KJ0qiYa5|#w(36P8&60KZ$;x*+M5==nsOr%GIub( jadLu7qVYAN_U=Su=wH4RUa+{W{OPQ^_9mnI_=kT05ZRfo literal 0 HcmV?d00001 diff --git a/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/faces-config.NavData b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/faces-config.NavData new file mode 100644 index 0000000..e69de29 diff --git a/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/nb-configuration.xml b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/nb-configuration.xml new file mode 100644 index 0000000..f89ff8d --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/nb-configuration.xml @@ -0,0 +1,21 @@ + + + + + + 10-web + gfv700ee10 + Facelets + JDK_11__System_ + + diff --git a/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/pom.xml b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/pom.xml new file mode 100644 index 0000000..0f9f8f2 --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/pom.xml @@ -0,0 +1,42 @@ + + 4.0.0 + edu.slcc.asdv.caleb + EventsLabValueChangeListener_CalebFontenot + 1.0-SNAPSHOT + war + EventsLabValueChangeListener_CalebFontenot-1.0-SNAPSHOT + + + UTF-8 + 10.0.0 + + + + + jakarta.platform + jakarta.jakartaee-api + ${jakartaee} + provided + + + + + + + org.apache.maven.plugins + maven-compiler-plugin + 3.8.1 + + 11 + 11 + + + + org.apache.maven.plugins + maven-war-plugin + 3.3.2 + + + + \ No newline at end of file diff --git a/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/java/beans/TextListener.java b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/java/beans/TextListener.java new file mode 100644 index 0000000..065fa0c --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/java/beans/TextListener.java @@ -0,0 +1,27 @@ +/* + * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license + * Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template + */ +package beans; + +import jakarta.faces.context.FacesContext; +import jakarta.faces.event.AbortProcessingException; +import jakarta.faces.event.ValueChangeEvent; +import jakarta.faces.event.ValueChangeListener; + +/** + * + * @author caleb + */ +public class TextListener implements ValueChangeListener { + + @Override + public void processValueChange(ValueChangeEvent event) throws AbortProcessingException + { + FacesContext context = FacesContext.getCurrentInstance(); + Object o = event.getNewValue(); + String s = o.toString(); + System.out.println(s); + } + +} diff --git a/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/java/beans/TextListener1.java b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/java/beans/TextListener1.java new file mode 100644 index 0000000..9cf01e4 --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/java/beans/TextListener1.java @@ -0,0 +1,27 @@ +/* + * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license + * Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template + */ +package beans; + +import jakarta.faces.context.FacesContext; +import jakarta.faces.event.AbortProcessingException; +import jakarta.faces.event.ValueChangeEvent; +import jakarta.faces.event.ValueChangeListener; + +/** + * + * @author caleb + */ +public class TextListener1 implements ValueChangeListener { + + @Override + public void processValueChange(ValueChangeEvent event) throws AbortProcessingException + { + FacesContext context = FacesContext.getCurrentInstance(); + Object o = event.getNewValue(); + String s = o.toString(); + System.out.println(s + " a second listener was called"); + } + +} diff --git a/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/java/beans/ValueChangedTestBean.java b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/java/beans/ValueChangedTestBean.java new file mode 100644 index 0000000..060478c --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/java/beans/ValueChangedTestBean.java @@ -0,0 +1,101 @@ +package beans; + +import jakarta.inject.Named; +import jakarta.enterprise.context.SessionScoped; +import java.io.Serializable; +import java.util.Arrays; +import java.util.LinkedHashMap; +import java.util.List; +import java.util.Locale; +import java.util.Map; +import jakarta.faces.context.FacesContext; +import jakarta.faces.event.AbortProcessingException; +import jakarta.faces.event.ValueChangeEvent; + +@Named(value = "vst") +@SessionScoped +public class ValueChangedTestBean implements Serializable +{ + private String name; + private String language = "en"; + private Map languagesMap; + + public ValueChangedTestBean() + { + languagesMap = new LinkedHashMap(); + languagesMap.put("US", "en");//usa + languagesMap.put("ES", "es");//spain + languagesMap.put("GR", "el");//greece + languagesMap.put("RU", "ru");//russia + languagesMap.put("CN", "zn");//china + languagesMap.put("VI", "vi");//vietnam + } + + public String getName() + { + return name; + } + + public String getLanguage() + { + return language; + } + + public void setLanguage(String language) + { + this.language = language; + } + + public void setName(String name) + { + this.name = name; + } + + public Map getLanguagesMap() + { + List list = Arrays.asList("en", "gr", "es", "ru", "zn", "vi"); + return languagesMap; + } + + public List getLanguages() + { + List list = Arrays.asList("en", "gr", "es", "ru", "zn", "vi"); + return list; + } + public void inputTextValueChangeListener(ValueChangeEvent event) throws AbortProcessingException { + FacesContext context = FacesContext.getCurrentInstance(); + Object o = event.getNewValue(); + String s = o.toString(); + System.out.println(s); + } + public void languageChanged(ValueChangeEvent event) + { + FacesContext contextInstance = FacesContext.getCurrentInstance(); + for (Map.Entry entry : this.languagesMap.entrySet()) + { + Object o = event.getNewValue(); + String lang = entry.getValue(); + if (lang.equals(o.toString())) + { + contextInstance.getViewRoot().setLocale( + new Locale(o.toString(), entry.getKey())); + this.language = o.toString(); + name = null; + break; + } + } + contextInstance.renderResponse(); + } + + public String newData() + { + if (name == null) + { + return ""; + } + return "

Data in
" + + "Your name: " + name + "
" + + "Your language: " + language + "
" + + "

"; + } +} diff --git a/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/java/edu/slcc/asdv/caleb/eventslabvaluechangelistener_calebfontenot/JakartaRestConfiguration.java b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/java/edu/slcc/asdv/caleb/eventslabvaluechangelistener_calebfontenot/JakartaRestConfiguration.java new file mode 100644 index 0000000..ec5a406 --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/java/edu/slcc/asdv/caleb/eventslabvaluechangelistener_calebfontenot/JakartaRestConfiguration.java @@ -0,0 +1,13 @@ +package edu.slcc.asdv.caleb.eventslabvaluechangelistener_calebfontenot; + +import jakarta.ws.rs.ApplicationPath; +import jakarta.ws.rs.core.Application; + +/** + * Configures Jakarta RESTful Web Services for the application. + * @author Juneau + */ +@ApplicationPath("resources") +public class JakartaRestConfiguration extends Application { + +} diff --git a/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/java/edu/slcc/asdv/caleb/eventslabvaluechangelistener_calebfontenot/resources/JakartaEE10Resource.java b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/java/edu/slcc/asdv/caleb/eventslabvaluechangelistener_calebfontenot/resources/JakartaEE10Resource.java new file mode 100644 index 0000000..287b3e7 --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/java/edu/slcc/asdv/caleb/eventslabvaluechangelistener_calebfontenot/resources/JakartaEE10Resource.java @@ -0,0 +1,20 @@ +package edu.slcc.asdv.caleb.eventslabvaluechangelistener_calebfontenot.resources; + +import jakarta.ws.rs.GET; +import jakarta.ws.rs.Path; +import jakarta.ws.rs.core.Response; + +/** + * + * @author + */ +@Path("jakartaee10") +public class JakartaEE10Resource { + + @GET + public Response ping(){ + return Response + .ok("ping Jakarta EE") + .build(); + } +} diff --git a/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/resources/META-INF/persistence.xml b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/resources/META-INF/persistence.xml new file mode 100644 index 0000000..7582bf1 --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/resources/META-INF/persistence.xml @@ -0,0 +1,7 @@ + + + + + + + diff --git a/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/resources/messages/messages.properties b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/resources/messages/messages.properties new file mode 100644 index 0000000..ce3b238 --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/resources/messages/messages.properties @@ -0,0 +1,4 @@ +indexWindowTitle=Immediate +txtLang=Your language is English. +txtName=Your name: +txtEmptyName=The name cannot be empty! diff --git a/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/resources/messages/messages_el_GR.properties b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/resources/messages/messages_el_GR.properties new file mode 100644 index 0000000..b81194c --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/resources/messages/messages_el_GR.properties @@ -0,0 +1,5 @@ + +indexWindowTitle=\u1f0c\u03bc\u03b5\u03c3\u03c9\u03c2 +txtLang=\u1f29 \u03b3\u03bb\u1ff6\u03c3\u03c3\u03b1 \u03c3\u03b1\u03c2 \u03b5\u1f36\u03bd\u03b1\u03b9 \u1f19\u03bb\u03bb\u03b7\u03bd\u03b9\u03ba\u03ac. +txtName=\u03a4\u03cc \u1f44\u03bd\u03bf\u03bc\u03ac \u03c3\u03b1\u03c2 \u03b5\u1f36\u03bd\u03b1\u03b9: +txtEmptyName=\u03a4\u03cc \u1f44\u03bd\u03bf\u03bc\u03ac \u03b4\u03ac\u03bd \u03bc\u03c0\u03bf\u03c1\u03b5\u1fd6 \u03bd\u03ac \u03b5\u1f36\u03bd\u03b1\u03b9 \u1f04\u03b4\u03b5\u03b9\u03bf! \ No newline at end of file diff --git a/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/resources/messages/messages_en_US.properties b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/resources/messages/messages_en_US.properties new file mode 100644 index 0000000..9881f2a --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/resources/messages/messages_en_US.properties @@ -0,0 +1,3 @@ +txtLang=Your language is English. +txtName=Your name: +txtEmptyName=The name cannot be empty! \ No newline at end of file diff --git a/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/resources/messages/messages_es_ES.properties b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/resources/messages/messages_es_ES.properties new file mode 100644 index 0000000..06ffcd4 --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/resources/messages/messages_es_ES.properties @@ -0,0 +1,4 @@ +indexWindowTitle=Inmediato +txtLang=Tu idioma es el ingl\u00e9s. +txtName=Su nombre: +txtEmptyName=\u00a1El nombre no puede estar vac\u00edo! \ No newline at end of file diff --git a/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/resources/messages/messages_ru_RU.properties b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/resources/messages/messages_ru_RU.properties new file mode 100644 index 0000000..9403a26 --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/resources/messages/messages_ru_RU.properties @@ -0,0 +1,4 @@ +indexWindowTitle=\u041d\u0435\u043c\u0435\u0434\u043b\u0435\u043d\u043d\u043e +txtLang=\u0412\u0430\u0448 \u044f\u0437\u044b\u043a \u2014 \u0430\u043d\u0433\u043b\u0438\u0439\u0441\u043a\u0438\u0439. +txtName=\u0412\u0430\u0448\u0435 \u0438\u043c\u044f: +txtEmptyName = \u0418\u043c\u044f \u043d\u0435 \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u043f\u0443\u0441\u0442\u044b\u043c! \ No newline at end of file diff --git a/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/resources/messages/messages_vi_VI.properties b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/resources/messages/messages_vi_VI.properties new file mode 100644 index 0000000..4645e4a --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/resources/messages/messages_vi_VI.properties @@ -0,0 +1,4 @@ +indexWindowTitle=Ngay l\u1eadp t\u1ee9c +txtLang=Ng\u00f4n ng\u1eef c\u1ee7a b\u1ea1n l\u00e0 ti\u1ebfng Vi\u1ec7t. +txtName=T\u00ean b\u1ea1n l\u00e0: +txtEmptyName=T\u00ean kh\u00f4ng \u0111\u01b0\u1ee3c \u0111\u1ec3 tr\u1ed1ng! \ No newline at end of file diff --git a/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/resources/messages/messages_zn_CN.properties b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/resources/messages/messages_zn_CN.properties new file mode 100644 index 0000000..9458de8 --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/resources/messages/messages_zn_CN.properties @@ -0,0 +1,4 @@ +indexWindowTitle=\u7acb\u5373 +txtLang=\u4f60\u7684\u8bed\u8a00\u662f\u4fc4\u8bed\u3002 +txtName=\u4f60\u7684\u540d\u5b57\u662f: +txtEmptyName=\u8be5\u540d\u79f0\u4e0d\u80fd\u4e3a\u7a7a! \ No newline at end of file diff --git a/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/webapp/1-value-change-listener.xhtml b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/webapp/1-value-change-listener.xhtml new file mode 100644 index 0000000..dfd6183 --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/webapp/1-value-change-listener.xhtml @@ -0,0 +1,46 @@ + + + + + + + #{msgs.indexWindowTitle} + + +

#{msgs.indexWindowTitle}

+ + + + + + + + + + + + + + + + + + + + + +
+ + diff --git a/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/webapp/WEB-INF/beans.xml b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/webapp/WEB-INF/beans.xml new file mode 100644 index 0000000..9dfae34 --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/webapp/WEB-INF/beans.xml @@ -0,0 +1,6 @@ + + + \ No newline at end of file diff --git a/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/webapp/WEB-INF/faces-config.xml b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/webapp/WEB-INF/faces-config.xml new file mode 100644 index 0000000..8b5a26c --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/webapp/WEB-INF/faces-config.xml @@ -0,0 +1,32 @@ + + + + + + messages.messages + msgs + + + diff --git a/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/webapp/WEB-INF/glassfish-web.xml b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/webapp/WEB-INF/glassfish-web.xml new file mode 100644 index 0000000..584a477 --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/webapp/WEB-INF/glassfish-web.xml @@ -0,0 +1,25 @@ + + + + + + + + Keep a copy of the generated servlet class' java code. + + + diff --git a/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/webapp/WEB-INF/web.xml b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/webapp/WEB-INF/web.xml new file mode 100644 index 0000000..0cd9172 --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/webapp/WEB-INF/web.xml @@ -0,0 +1,24 @@ + + + + jakarta.faces.PROJECT_STAGE + Development + + + Faces Servlet + jakarta.faces.webapp.FacesServlet + 1 + + + Faces Servlet + /faces/* + + + + 30 + + + + faces/1-value-change-listener.xhtml + + \ No newline at end of file diff --git a/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/webapp/resources/css/styles.css b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/webapp/resources/css/styles.css new file mode 100644 index 0000000..34a6c9a --- /dev/null +++ b/Semester 2/Assignments/EventsLabValueChangeListener_CalebFontenot/src/main/webapp/resources/css/styles.css @@ -0,0 +1,28 @@ +/* +Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license +Click nbfs://nbhost/SystemFileSystem/Templates/ClientSide/css.css to edit this template +*/ +/* + Created on : Nov 13, 2023, 10:07:11 AM + Author : caleb +*/ + +.normalSize { font-size: 110% } +.largeSize { font-size: 200% } +body { + background-color: #e9e9e9; +} +a:hover { + color: red +} + +h1,h2,h3 { + text-align: center; + font-family: Verdana, Arial, Helvetica, sans-serif; + color: black; +} + +.button1 +{ + text-height:font-size; +} diff --git a/Semester 2/Assignments/JavaScriptValidation_CalebFontenot/nb-configuration.xml b/Semester 2/Assignments/JavaScriptValidation_CalebFontenot/nb-configuration.xml new file mode 100644 index 0000000..f89ff8d --- /dev/null +++ b/Semester 2/Assignments/JavaScriptValidation_CalebFontenot/nb-configuration.xml @@ -0,0 +1,21 @@ + + + + + + 10-web + gfv700ee10 + Facelets + JDK_11__System_ + + diff --git a/Semester 2/Assignments/JavaScriptValidation_CalebFontenot/pom.xml b/Semester 2/Assignments/JavaScriptValidation_CalebFontenot/pom.xml new file mode 100644 index 0000000..5a125fc --- /dev/null +++ b/Semester 2/Assignments/JavaScriptValidation_CalebFontenot/pom.xml @@ -0,0 +1,52 @@ + + 4.0.0 + edu.slcc.asdv.caleb + JavaScriptValidation_CalebFontenot + 1.0-SNAPSHOT + war + JavaScriptValidation_CalebFontenot-1.0-SNAPSHOT + + + UTF-8 + 10.0.0 + + + + + com.google.protobuf + protobuf-java + 3.21.9 + + + jakarta.platform + jakarta.jakartaee-api + 10.0.0 + + + org.primefaces + primefaces + 12.0.0 + jakarta + + + + + + + org.apache.maven.plugins + maven-compiler-plugin + 3.8.1 + + 11 + 11 + + + + org.apache.maven.plugins + maven-war-plugin + 3.3.2 + + + + \ No newline at end of file diff --git a/Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/java/beans/ControlRender.java b/Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/java/beans/ControlRender.java new file mode 100644 index 0000000..e5e2465 --- /dev/null +++ b/Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/java/beans/ControlRender.java @@ -0,0 +1,111 @@ +/* + * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license + * Click nbfs://nbhost/SystemFileSystem/Templates/JSF/JSFManagedBean.java to edit this template + */ + +package beans; + +import jakarta.inject.Named; +import jakarta.enterprise.context.RequestScoped; + +/** + * + * @author caleb + */ +@Named(value="controlRender") +@RequestScoped +public class ControlRender { + + private String text; + private String mask; + private int rate; + private String userName; + private String alpha; + + public String getAlpha() + { + return alpha; + } + + public void setAlpha(String alpha) + { + this.alpha = alpha; + } + + + public String getUserName() + { + return userName; + } + + public void setUserName(String userName) + { + this.userName = userName; + } + + + /** + * Get the value of rate + * + * @return the value of rate + */ + public int getRate() + { + return rate; + } + + /** + * Set the value of rate + * + * @param rate new value of rate + */ + public void setRate(int rate) + { + this.rate = rate; + } + + + /** + * Get the value of mask + * + * @return the value of mask + */ + public String getMask() + { + return mask; + } + + /** + * Set the value of mask + * + * @param mask new value of mask + */ + public void setMask(String mask) + { + this.mask = mask; + } + + + public String getText() + { + return text; + } + + public void setText(String text) + { + this.text = text; + } + + public void printToServer() { + System.out.println(this.text); + System.out.println(this.mask); + System.out.println(this.rate); + System.out.println(this.userName); + System.out.println(this.alpha); + } + + /** Creates a new instance of ControlRender */ + public ControlRender() { + } + +} diff --git a/Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/java/edu/slcc/asdv/caleb/javascriptvalidation_calebfontenot/JakartaRestConfiguration.java b/Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/java/edu/slcc/asdv/caleb/javascriptvalidation_calebfontenot/JakartaRestConfiguration.java new file mode 100644 index 0000000..d786073 --- /dev/null +++ b/Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/java/edu/slcc/asdv/caleb/javascriptvalidation_calebfontenot/JakartaRestConfiguration.java @@ -0,0 +1,13 @@ +package edu.slcc.asdv.caleb.javascriptvalidation_calebfontenot; + +import jakarta.ws.rs.ApplicationPath; +import jakarta.ws.rs.core.Application; + +/** + * Configures Jakarta RESTful Web Services for the application. + * @author Juneau + */ +@ApplicationPath("resources") +public class JakartaRestConfiguration extends Application { + +} diff --git a/Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/java/edu/slcc/asdv/caleb/javascriptvalidation_calebfontenot/resources/JakartaEE10Resource.java b/Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/java/edu/slcc/asdv/caleb/javascriptvalidation_calebfontenot/resources/JakartaEE10Resource.java new file mode 100644 index 0000000..5917789 --- /dev/null +++ b/Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/java/edu/slcc/asdv/caleb/javascriptvalidation_calebfontenot/resources/JakartaEE10Resource.java @@ -0,0 +1,20 @@ +package edu.slcc.asdv.caleb.javascriptvalidation_calebfontenot.resources; + +import jakarta.ws.rs.GET; +import jakarta.ws.rs.Path; +import jakarta.ws.rs.core.Response; + +/** + * + * @author + */ +@Path("jakartaee10") +public class JakartaEE10Resource { + + @GET + public Response ping(){ + return Response + .ok("ping Jakarta EE") + .build(); + } +} diff --git a/Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/resources/META-INF/persistence.xml b/Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/resources/META-INF/persistence.xml new file mode 100644 index 0000000..7582bf1 --- /dev/null +++ b/Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/resources/META-INF/persistence.xml @@ -0,0 +1,7 @@ + + + + + + + diff --git a/Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/webapp/WEB-INF/beans.xml b/Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/webapp/WEB-INF/beans.xml new file mode 100644 index 0000000..9dfae34 --- /dev/null +++ b/Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/webapp/WEB-INF/beans.xml @@ -0,0 +1,6 @@ + + + \ No newline at end of file diff --git a/Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/webapp/WEB-INF/glassfish-web.xml b/Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/webapp/WEB-INF/glassfish-web.xml new file mode 100644 index 0000000..673cc06 --- /dev/null +++ b/Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/webapp/WEB-INF/glassfish-web.xml @@ -0,0 +1,25 @@ + + + + + + + + Keep a copy of the generated servlet class' java code. + + + diff --git a/Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/webapp/WEB-INF/web.xml b/Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/webapp/WEB-INF/web.xml new file mode 100644 index 0000000..f182148 --- /dev/null +++ b/Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/webapp/WEB-INF/web.xml @@ -0,0 +1,24 @@ + + + + jakarta.faces.PROJECT_STAGE + Development + + + Faces Servlet + jakarta.faces.webapp.FacesServlet + 1 + + + Faces Servlet + /faces/* + + + + 30 + + + + faces/index.xhtml + + diff --git a/Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/webapp/index.xhtml b/Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/webapp/index.xhtml new file mode 100644 index 0000000..1b1d910 --- /dev/null +++ b/Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/webapp/index.xhtml @@ -0,0 +1,39 @@ + + + + + + +

Validation with javascript and primefaces

+
+ + alphanumeric input only javascript called: + + +

+ + only letters and numbers regex: + + + + +

+ + only numbers mask: + + +

+ + only letters mask: + +

+ rate: + + +
+
+ \ No newline at end of file diff --git a/Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/webapp/resources/js/do_validation.js b/Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/webapp/resources/js/do_validation.js new file mode 100644 index 0000000..e66c47e --- /dev/null +++ b/Semester 2/Assignments/JavaScriptValidation_CalebFontenot/src/main/webapp/resources/js/do_validation.js @@ -0,0 +1,20 @@ +/* + * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license + * Click nbfs://nbhost/SystemFileSystem/Templates/JSP_Servlet/JavaScript.js to edit this template + */ +function validateText(textInputID) +{ + var htmlInputText = document.getElementById(textInputID); + var text = htmlInputText.value; + + + var regex = /[^A-Za-z0-9]/g; + + if (text.search( regex) != -1) + { + newText = text.replace(regex, ""); + htmlInputText.value = newText; + alert("alphanumeric chars only please"); + } + +}; \ No newline at end of file diff --git a/Semester 2/Assignments/LabEvents_CalebFontenot/faces-config.NavData b/Semester 2/Assignments/LabEvents_CalebFontenot/faces-config.NavData new file mode 100644 index 0000000..e69de29 diff --git a/Semester 2/Assignments/LabEvents_CalebFontenot/nb-configuration.xml b/Semester 2/Assignments/LabEvents_CalebFontenot/nb-configuration.xml new file mode 100644 index 0000000..5e1a2de --- /dev/null +++ b/Semester 2/Assignments/LabEvents_CalebFontenot/nb-configuration.xml @@ -0,0 +1,20 @@ + + + + + + 10-web + gfv700ee10 + Facelets + + diff --git a/Semester 2/Assignments/LabEvents_CalebFontenot/pom.xml b/Semester 2/Assignments/LabEvents_CalebFontenot/pom.xml new file mode 100644 index 0000000..c412e81 --- /dev/null +++ b/Semester 2/Assignments/LabEvents_CalebFontenot/pom.xml @@ -0,0 +1,42 @@ + + 4.0.0 + edu.slcc.asdv.caleb + LabEvents_CalebFontenot + 1.0-SNAPSHOT + war + LabEvents_CalebFontenot-1.0-SNAPSHOT + + + UTF-8 + 10.0.0 + + + + + jakarta.platform + jakarta.jakartaee-api + ${jakartaee} + provided + + + + + + + org.apache.maven.plugins + maven-compiler-plugin + 3.8.1 + + 11 + 11 + + + + org.apache.maven.plugins + maven-war-plugin + 3.3.2 + + + + \ No newline at end of file diff --git a/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/java/beans/FormSettings.java b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/java/beans/FormSettings.java new file mode 100644 index 0000000..2265471 --- /dev/null +++ b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/java/beans/FormSettings.java @@ -0,0 +1,31 @@ +/* + * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license + * Click nbfs://nbhost/SystemFileSystem/Templates/JSF/JSFManagedBean.java to edit this template + */ + +package beans; + +import jakarta.inject.Named; +import jakarta.enterprise.context.SessionScoped; +import java.io.Serializable; +import jakarta.faces.event.ActionEvent; + +@Named(value = "formSettings") +@SessionScoped +public class FormSettings implements Serializable +{ + private boolean isNormalSize = true; + + public String getBodyStyleClass() + { + if (isNormalSize) return ("normalSize");//css class + else return ("largeSize"); + } + public void setNormalSize(ActionEvent event){ + System.out.println("****************************setNormalSize called"); + isNormalSize = true;} + public void setLargeSize(ActionEvent event){ + System.out.println( + "**************************************setLargeSize called"); + isNormalSize = false;} +} diff --git a/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/java/beans/FormSettingsLocale.java b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/java/beans/FormSettingsLocale.java new file mode 100644 index 0000000..c62686c --- /dev/null +++ b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/java/beans/FormSettingsLocale.java @@ -0,0 +1,100 @@ +/* + * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license + * Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template + */ +package beans; + +/** + * + * @author caleb + */ +import jakarta.inject.Named; +import jakarta.enterprise.context.SessionScoped; +import jakarta.faces.event.ActionEvent; +import java.io.Serializable; +import java.util.LinkedHashMap; +import java.util.Locale; +import java.util.Map; + +@Named(value = "formSettingsLocale") +@SessionScoped +public class FormSettingsLocale implements Serializable +{ + + private boolean isNormalSize = true; + private boolean isEnglish = true; + private static final Locale ENGLISH = new Locale("en"); + private static final Locale SPANISH = new Locale("es"); + private static final Locale JAPANESE = new Locale("jp"); + private static final Locale GREEK = new Locale("el"); + + private Locale locale = ENGLISH; + private String language = locale.getLanguage(); + + private static final Map LANGUAGE_MAP + = new LinkedHashMap<>(); + + static + { + LANGUAGE_MAP.put("English", "en"); + LANGUAGE_MAP.put("Español", "es"); + LANGUAGE_MAP.put("日本人", "jp"); + LANGUAGE_MAP.put(" Ἑλληνικά", "el"); + } + + public String getBodyStyleClass() + { + if (isNormalSize) + { + return ("normalSize"); + } + else + { + return ("largeSize"); + } + } + + public void setNormalSize(ActionEvent event) + { + isNormalSize = true; + } + + public void setLargeSize(ActionEvent event) + { + isNormalSize = false; + } + + public Locale getLocale() + { + return (locale); + } + + public void swapLocale( ActionEvent event ) + { + isEnglish = !isEnglish; + if (isEnglish) + { + locale = ENGLISH; + } + else + { + locale = SPANISH; + } + } + + public String getLanguage() + { + return (language); + } + + public void setLanguage(String language) + { + this.language = language; + locale = new Locale(language); + } + + public Map getLanguages() + { + return (LANGUAGE_MAP); + } +} diff --git a/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/java/beans/Person.java b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/java/beans/Person.java new file mode 100644 index 0000000..4178fc0 --- /dev/null +++ b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/java/beans/Person.java @@ -0,0 +1,66 @@ +package beans; + +import jakarta.inject.Named; +import jakarta.enterprise.context.RequestScoped; + +@Named(value = "person") +@RequestScoped +public class Person { + + private String firstName, lastName, emailAddress; + + public String getFirstName() + { + return firstName; + } + + public void setFirstName(String firstName) + { + System.out.println("---------------------------------------first name called"); + this.firstName = firstName; + } + + public String getLastName() + { + return lastName; + } + + public void setLastName(String lastName) + { + this.lastName = lastName; + } + + public String getEmailAddress() + { + return emailAddress; + } + + public void setEmailAddress(String emailAddress) + { + this.emailAddress = emailAddress; + } + + public String doRegistration() + { + if (isAnyEmpty(firstName, lastName, emailAddress)) { + return "missing-input"; + } else { + return "confirm-registration"; + } + } + + private boolean isAnyEmpty(String... values) + { + for (String value : values) { + if (isEmpty(value)) { + return true; + } + } + return false; + } + + private boolean isEmpty(String value) + { + return value == null || value.trim().length() == 0; + } +} diff --git a/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/java/edu/slcc/asdv/caleb/labevents_calebfontenot/JakartaRestConfiguration.java b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/java/edu/slcc/asdv/caleb/labevents_calebfontenot/JakartaRestConfiguration.java new file mode 100644 index 0000000..522373e --- /dev/null +++ b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/java/edu/slcc/asdv/caleb/labevents_calebfontenot/JakartaRestConfiguration.java @@ -0,0 +1,13 @@ +package edu.slcc.asdv.caleb.labevents_calebfontenot; + +import jakarta.ws.rs.ApplicationPath; +import jakarta.ws.rs.core.Application; + +/** + * Configures Jakarta RESTful Web Services for the application. + * @author Juneau + */ +@ApplicationPath("resources") +public class JakartaRestConfiguration extends Application { + +} diff --git a/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/java/edu/slcc/asdv/caleb/labevents_calebfontenot/resources/JakartaEE10Resource.java b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/java/edu/slcc/asdv/caleb/labevents_calebfontenot/resources/JakartaEE10Resource.java new file mode 100644 index 0000000..5bffd4b --- /dev/null +++ b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/java/edu/slcc/asdv/caleb/labevents_calebfontenot/resources/JakartaEE10Resource.java @@ -0,0 +1,20 @@ +package edu.slcc.asdv.caleb.labevents_calebfontenot.resources; + +import jakarta.ws.rs.GET; +import jakarta.ws.rs.Path; +import jakarta.ws.rs.core.Response; + +/** + * + * @author + */ +@Path("jakartaee10") +public class JakartaEE10Resource { + + @GET + public Response ping(){ + return Response + .ok("ping Jakarta EE") + .build(); + } +} diff --git a/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/resources/META-INF/persistence.xml b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/resources/META-INF/persistence.xml new file mode 100644 index 0000000..7582bf1 --- /dev/null +++ b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/resources/META-INF/persistence.xml @@ -0,0 +1,7 @@ + + + + + + + diff --git a/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/resources/messages/messages.properties b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/resources/messages/messages.properties new file mode 100644 index 0000000..6f2a779 --- /dev/null +++ b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/resources/messages/messages.properties @@ -0,0 +1,14 @@ +registrationTitle=Registration +firstName=First Name +lastName=Last Name +emailAddress=Email Address +registrationText=Please Enter Your {0}, {1}, and {2}. +prompt=Enter {0} +buttonLabel=Register Me +successTitle=Success +successText=You Registered Successfully. +switchLanguage=En Español +normalFont=Normal Font +largeFont=Large Font +errorTitle=Error! +missingData=Missing input. Please try again. \ No newline at end of file diff --git a/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/resources/messages/messages_el.properties b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/resources/messages/messages_el.properties new file mode 100644 index 0000000..c5b957b --- /dev/null +++ b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/resources/messages/messages_el.properties @@ -0,0 +1,14 @@ +registrationTitle=\u1f18\u03b3\u03b3\u03c1\u03b1\u03c6\u03ae +firstName= \u1f4c\u03bd\u03bf\u03bc\u03b1 +lastName=\u1f18\u03c0\u03c9\u03bd\u03c5\u03bc\u03bf\u03bd +emailAddress=\u1f38\u03bc\u03ad\u03b9\u03bb +registrationText=\u03a0\u03b1\u03c1\u03b1\u03ba\u03b1\u03bb\u1ff6 \u03b3\u03c1\u03ac\u03c8\u03b1\u03c4\u03b5 {0}, {1}, \u03ba\u03b1\u1f30 {2}. +prompt=\u0393\u03c1\u03ac\u03c8\u03b5 {0} +buttonLabel=\u1f18\u03b3\u03b3\u03c1\u03ac\u03c8\u03b5 \u03bc\u03b5 +successTitle=\u1f18\u03c0\u03b9\u03c4\u03c5\u03c7\u03af\u03b1 +successText=\u0393\u03c1\u03ac\u03c6\u03c4\u03b7\u03ba\u03b5\u03c2 +switchLanguage=\u03a3\u03c4\u03ac \u1f19\u03bb\u03bb\u03b7\u03bd\u03b9\u03ba\u03ac +normalFont=\u039c\u03b9\u03ba\u03c1\u03ac \u03b3\u03c1\u03ac\u03bc\u03bc\u03b1\u03c4\u03b1 +largeFont=\u039c\u03b5\u03b3\u03ac\u03bb\u03b1 \u03b3\u03c1\u03ac\u03bc\u03bc\u03b1\u03c4\u03b1 +errorTitle=\u039b\u03ac\u03b8\u03bf\u03c2! +missingData=\u1f18\u03bb\u03bb\u03b5\u03b9\u03c0\u1f20 \u03c3\u03c4\u03bf\u03b9\u03c7\u03b5\u1fd6\u03b1. \u03a0\u03b1\u03c1\u03b1\u03ba\u03b1\u03bb\u1ff6 \u03be\u03b1\u03bd\u03b1\u03b4\u03bf\u03ba\u03b9\u03bc\u1fb6\u03c3\u03c4\u03b5! \ No newline at end of file diff --git a/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/resources/messages/messages_es.properties b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/resources/messages/messages_es.properties new file mode 100644 index 0000000..1b3edb8 --- /dev/null +++ b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/resources/messages/messages_es.properties @@ -0,0 +1,14 @@ +registrationTitle=Registro +firstName=Primer Nombre +lastName=Apellido +emailAddress=Dirección de Email +registrationText=Incorpore Por Favor su {0}, {1}, y {2}. +prompt=Incorpore {0} +buttonLabel=Coloqúeme +successTitle=Éxito +successText=Se Registró con Éxito. +switchLanguage=In English +normalFont=Fuente Normal +largeFont=Fuente Grande +errorTitle=¡Error! +missingData=Falta de input. Por favor, inténtelo de nuevo. \ No newline at end of file diff --git a/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/resources/messages/messages_jp.properties b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/resources/messages/messages_jp.properties new file mode 100644 index 0000000..4c04071 --- /dev/null +++ b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/resources/messages/messages_jp.properties @@ -0,0 +1,14 @@ +registrationTitle=\u767B\u9332 +firstName=\u540D\u524D +lastName=\u59D3 +emailAddress=\u30E1\u30FC\u30EB\u30A2\u30C9\u30EC\u30B9 +registrationText=\u3042\u306A\u305F\u306E\u3092\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044 {0}, {1}, \u3068 {2}. +prompt=\u30BF\u30A4\u30D7 {0} +buttonLabel=\u79C1\u3092\u767B\u9332 +successTitle=\u6210\u529F +successText=\u3042\u306A\u305F\u304C\u6B63\u5E38\u306B\u767B\u9332\u3002 +switchLanguage=\u65E5\u672C\u8A9E\u3067 +normalFont=\u901A\u5E38\u306E\u30D5\u30A9\u30F3\u30C8 +largeFont=\u5927\u304D\u3044\u30D5\u30A9\u30F3\u30C8 +errorTitle=\u30A8\u30E9\u30FC\uFF01 +missingData=\u672A\u5165\u529B\u3067\u3059\u3002\u3082\u3046\u4E00\u5EA6\u3084\u308A\u76F4\u3057\u3066\u304F\u3060\u3055\u3044\u3002 \ No newline at end of file diff --git a/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/WEB-INF/beans.xml b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/WEB-INF/beans.xml new file mode 100644 index 0000000..9dfae34 --- /dev/null +++ b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/WEB-INF/beans.xml @@ -0,0 +1,6 @@ + + + \ No newline at end of file diff --git a/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/WEB-INF/faces-config.xml b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/WEB-INF/faces-config.xml new file mode 100644 index 0000000..8b5a26c --- /dev/null +++ b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/WEB-INF/faces-config.xml @@ -0,0 +1,32 @@ + + + + + + messages.messages + msgs + + + diff --git a/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/WEB-INF/glassfish-web.xml b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/WEB-INF/glassfish-web.xml new file mode 100644 index 0000000..673cc06 --- /dev/null +++ b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/WEB-INF/glassfish-web.xml @@ -0,0 +1,25 @@ + + + + + + + + Keep a copy of the generated servlet class' java code. + + + diff --git a/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/WEB-INF/web.xml b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/WEB-INF/web.xml new file mode 100644 index 0000000..f182148 --- /dev/null +++ b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/WEB-INF/web.xml @@ -0,0 +1,24 @@ + + + + jakarta.faces.PROJECT_STAGE + Development + + + Faces Servlet + jakarta.faces.webapp.FacesServlet + 1 + + + Faces Servlet + /faces/* + + + + 30 + + + + faces/index.xhtml + + diff --git a/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/confirm-registration.xhtml b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/confirm-registration.xhtml new file mode 100644 index 0000000..8f36117 --- /dev/null +++ b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/confirm-registration.xhtml @@ -0,0 +1,21 @@ + + + + #{msgs.successTitle} + + + + + +

#{msgs.successTitle}

+

#{msgs.successText}

+
    +
  • #{msgs.firstName}: #{person.firstName}
  • +
  • #{msgs.lastName}: #{person.lastName}
  • +
  • #{msgs.emailAddress}: #{person.emailAddress}
  • +
+
+ diff --git a/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/index.xhtml b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/index.xhtml new file mode 100644 index 0000000..e631438 --- /dev/null +++ b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/index.xhtml @@ -0,0 +1,19 @@ + + + + + Events + + +

Handling Application Events

+ + +
+ +
+ +
+
+
+ diff --git a/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/register1.xhtml b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/register1.xhtml new file mode 100644 index 0000000..fecafa1 --- /dev/null +++ b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/register1.xhtml @@ -0,0 +1,52 @@ + + + #{msgs.registrationTitle} + + + + + + +

#{msgs.registrationTitle}

+

+ + + + + +

+ + + + + + + + + + + + + + + + + + + + + +
+ +
+
+ \ No newline at end of file diff --git a/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/register3.xhtml b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/register3.xhtml new file mode 100644 index 0000000..bc86b76 --- /dev/null +++ b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/register3.xhtml @@ -0,0 +1,55 @@ + + + + + + #{msgs.registrationTitle} + + + +

#{msgs.registrationTitle}

+

+ + + + + +

+ + + + + + + + + + + + + + + +
+
+ + +
+ + + +
+
+
+
+ \ No newline at end of file diff --git a/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/resources/css/styles.css b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/resources/css/styles.css new file mode 100644 index 0000000..34a6c9a --- /dev/null +++ b/Semester 2/Assignments/LabEvents_CalebFontenot/src/main/webapp/resources/css/styles.css @@ -0,0 +1,28 @@ +/* +Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license +Click nbfs://nbhost/SystemFileSystem/Templates/ClientSide/css.css to edit this template +*/ +/* + Created on : Nov 13, 2023, 10:07:11 AM + Author : caleb +*/ + +.normalSize { font-size: 110% } +.largeSize { font-size: 200% } +body { + background-color: #e9e9e9; +} +a:hover { + color: red +} + +h1,h2,h3 { + text-align: center; + font-family: Verdana, Arial, Helvetica, sans-serif; + color: black; +} + +.button1 +{ + text-height:font-size; +} diff --git a/Semester 2/Assignments/SupplierPartsCalendar/nb-configuration.xml b/Semester 2/Assignments/SupplierPartsCalendar/nb-configuration.xml new file mode 100644 index 0000000..f29f292 --- /dev/null +++ b/Semester 2/Assignments/SupplierPartsCalendar/nb-configuration.xml @@ -0,0 +1,21 @@ + + + + + + 9.0-web + gfv700ee10 + Facelets + JDK_11__System_ + + diff --git a/Semester 2/Assignments/SupplierPartsCalendar/pom.xml b/Semester 2/Assignments/SupplierPartsCalendar/pom.xml new file mode 100644 index 0000000..2ac98e0 --- /dev/null +++ b/Semester 2/Assignments/SupplierPartsCalendar/pom.xml @@ -0,0 +1,87 @@ + + 4.0.0 + com.mycompany + SuppliersPartsCalendar + 1.0-SNAPSHOT + war + SuppliersPartsCalendar + + + 1.8 + 1.8 + ${project.build.directory}/endorsed + UTF-8 + false + 9.0.0 + + + + + com.mysql + mysql-connector-j + 8.1.0 + + + org.primefaces + primefaces + 12.0.0 + jakarta + + + jakarta.platform + jakarta.jakartaee-api + 10.0.0 + + + + + + + org.apache.maven.plugins + maven-compiler-plugin + 3.1 + + 1.8 + 1.8 + + ${endorsed.dir} + + + + + org.apache.maven.plugins + maven-war-plugin + 2.3 + + false + + + + org.apache.maven.plugins + maven-dependency-plugin + 2.6 + + + validate + + copy + + + ${endorsed.dir} + true + + + jakarta.platform + jakarta.jakartaee-api + ${jakartaee} + jar + + + + + + + + + \ No newline at end of file diff --git a/Semester 2/Assignments/SupplierPartsCalendar/src/main/java/com/mycompany/supplierspartsdatabase/JakartaRestConfiguration.java b/Semester 2/Assignments/SupplierPartsCalendar/src/main/java/com/mycompany/supplierspartsdatabase/JakartaRestConfiguration.java new file mode 100644 index 0000000..110a745 --- /dev/null +++ b/Semester 2/Assignments/SupplierPartsCalendar/src/main/java/com/mycompany/supplierspartsdatabase/JakartaRestConfiguration.java @@ -0,0 +1,13 @@ +package com.mycompany.supplierspartsdatabase; + +import jakarta.ws.rs.ApplicationPath; +import jakarta.ws.rs.core.Application; + +/** + * Configures Jakarta RESTful Web Services for the application. + * @author Juneau + */ +@ApplicationPath("resources") +public class JakartaRestConfiguration extends Application { + +} diff --git a/Semester 2/Assignments/SupplierPartsCalendar/src/main/java/com/mycompany/supplierspartsdatabase/resources/JakartaEE9Resource.java b/Semester 2/Assignments/SupplierPartsCalendar/src/main/java/com/mycompany/supplierspartsdatabase/resources/JakartaEE9Resource.java new file mode 100644 index 0000000..f7f850d --- /dev/null +++ b/Semester 2/Assignments/SupplierPartsCalendar/src/main/java/com/mycompany/supplierspartsdatabase/resources/JakartaEE9Resource.java @@ -0,0 +1,20 @@ +package com.mycompany.supplierspartsdatabase.resources; + +import jakarta.ws.rs.GET; +import jakarta.ws.rs.Path; +import jakarta.ws.rs.core.Response; + +/** + * + * @author + */ +@Path("jakartaee9") +public class JakartaEE9Resource { + + @GET + public Response ping(){ + return Response + .ok("ping Jakarta EE") + .build(); + } +} diff --git a/Semester 2/Assignments/SupplierPartsCalendar/src/main/java/edu/slcc/asdv/beans/SupplierBean.java b/Semester 2/Assignments/SupplierPartsCalendar/src/main/java/edu/slcc/asdv/beans/SupplierBean.java new file mode 100644 index 0000000..9e05f94 --- /dev/null +++ b/Semester 2/Assignments/SupplierPartsCalendar/src/main/java/edu/slcc/asdv/beans/SupplierBean.java @@ -0,0 +1,133 @@ +/* + * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license + * Click nbfs://nbhost/SystemFileSystem/Templates/JSF/JSFManagedBean.java to edit this template + */ +package edu.slcc.asdv.beans; + +import edu.slcc.asdv.bl.DBase; +import edu.slcc.asdv.bl.part.DatabaseManipulationPart; +import edu.slcc.asdv.bl.part.Part; +import edu.slcc.asdv.bl.supplier.DatabaseManipulationSupplier; +import edu.slcc.asdv.bl.supplier.Supplier; +import jakarta.annotation.PostConstruct; +import jakarta.inject.Named; +import jakarta.enterprise.context.SessionScoped; +import jakarta.faces.application.FacesMessage; +import jakarta.faces.application.FacesMessage.Severity; +import jakarta.faces.context.FacesContext; +import java.io.Serializable; +import java.util.Iterator; +import java.util.List; + +@Named(value = "supplierBean") +@SessionScoped +public class SupplierBean implements Serializable { + + //DBase dms; + //DBase dmp; + DBase dms = new DatabaseManipulationSupplier(); + DBase dmp = new DatabaseManipulationPart(); + List suppliers; + List parts; + + private Supplier selectedSupplier; + + public Supplier getSelectedSupplier() { + return selectedSupplier; + } + + public void setSelectedSupplier(Supplier selectedSupplier) { + this.selectedSupplier = selectedSupplier; + } + + public SupplierBean() { + suppliers = dms.listAll(); + parts = dmp.listAll(); + } + + public List getSuppliers() { + return suppliers; + } + + public List getParts() { + return parts; + } + + public void deleteFromList() { + int totalRowsUpdated = 0; + Iterator iterator = this.suppliers.iterator(); + while (iterator.hasNext()) { + Supplier s = iterator.next(); + if (s.isModify()) { + try { + int rowsUpdated = this.dms.delete(s); + if (rowsUpdated > 0) { + iterator.remove(); + } + } catch (Exception e) { + String msg = ("Numbers of rows updated is 0."); + addMessage(msg, e.getMessage(), FacesMessage.SEVERITY_ERROR); + break; + } + } + } +} + + + public void saveFromUpdate() { + int totalRowsUpdated = 0; + for (Supplier s : this.suppliers) { + if (s.isModify()) { + try { + int rowsUpdated = this.dms.update(s); + if (rowsUpdated > 0) { + totalRowsUpdated += rowsUpdated; + s.setModify(false); + } + } catch (Exception e) { + String msg = ("Numbers of rows updated is 0."); + addMessage(msg, e.getMessage(), FacesMessage.SEVERITY_ERROR); + break; + } + } + } + String msg = ("Numbers of rows updated: " + totalRowsUpdated); + addMessage(msg, "no exception", FacesMessage.SEVERITY_INFO); + } + + public void saveFromUpdatePart() { + int totalRowsUpdated = 0; + + for (Part s : this.parts) { + if (s.isModify()) { + try { + int rowsUpdated = this.dmp.update(s); + if (rowsUpdated > 0) { + totalRowsUpdated += rowsUpdated; + s.setModify(false); + } + } catch (Exception e) { + String msg = ("Numbers of rows updated is 0."); + addMessage(msg, e.getMessage(), FacesMessage.SEVERITY_ERROR); + break; + } + } + } + String msg = ("Numbers of rows updated: " + totalRowsUpdated); + addMessage(msg, "no exception", FacesMessage.SEVERITY_INFO); + } + + public void addMessage(String summary, String detail, Severity severity) { + FacesMessage msg = new FacesMessage(severity, summary, detail); + FacesContext.getCurrentInstance().addMessage(null, msg); + } + + @PostConstruct + public void init() { + try { + //suppliers.dms.listAll(); + } catch (Exception e) { + System.out.println(e); + } + } +} diff --git a/Semester 2/Assignments/SupplierPartsCalendar/src/main/java/edu/slcc/asdv/bl/DBase.java b/Semester 2/Assignments/SupplierPartsCalendar/src/main/java/edu/slcc/asdv/bl/DBase.java new file mode 100644 index 0000000..f09fd59 --- /dev/null +++ b/Semester 2/Assignments/SupplierPartsCalendar/src/main/java/edu/slcc/asdv/bl/DBase.java @@ -0,0 +1,25 @@ +/* + * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license + * Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template + */ +package edu.slcc.asdv.bl; + +import java.sql.SQLException; +import java.util.ArrayList; +import java.util.List; + +/** + * + * @author asdv5 + */ +public interface DBase +{ + List listAll(); + + int update( T t) + throws SQLException; + + int delete(T t) + throws SQLException; + +} diff --git a/Semester 2/Assignments/SupplierPartsCalendar/src/main/java/edu/slcc/asdv/bl/DateValidator.java b/Semester 2/Assignments/SupplierPartsCalendar/src/main/java/edu/slcc/asdv/bl/DateValidator.java new file mode 100644 index 0000000..b8a144d --- /dev/null +++ b/Semester 2/Assignments/SupplierPartsCalendar/src/main/java/edu/slcc/asdv/bl/DateValidator.java @@ -0,0 +1,31 @@ +/* + * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license + * Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template + */ +package edu.slcc.asdv.bl; + +import jakarta.faces.application.FacesMessage; +import jakarta.faces.component.UIComponent; +import jakarta.faces.context.FacesContext; +import jakarta.faces.validator.FacesValidator; +import jakarta.faces.validator.Validator; +import jakarta.faces.validator.ValidatorException; +import java.text.ParseException; +import java.text.SimpleDateFormat; + +@FacesValidator("dateValidator") +public class DateValidator implements Validator { + + private static final String DATE_PATTERN = "yyyy-MM-dd"; + + @Override + public void validate(FacesContext context, UIComponent component, String value) throws ValidatorException { + SimpleDateFormat sdf = new SimpleDateFormat(DATE_PATTERN); + sdf.setLenient(false); + try { + sdf.parse(value); + } catch (ParseException e) { + throw new ValidatorException(new FacesMessage(FacesMessage.SEVERITY_ERROR, "Invalid date format", "Date must be in 'yyyy-MM-dd' format")); + } + } +} diff --git a/Semester 2/Assignments/SupplierPartsCalendar/src/main/java/edu/slcc/asdv/bl/UtilitiesDatabase.java b/Semester 2/Assignments/SupplierPartsCalendar/src/main/java/edu/slcc/asdv/bl/UtilitiesDatabase.java new file mode 100644 index 0000000..36a5d46 --- /dev/null +++ b/Semester 2/Assignments/SupplierPartsCalendar/src/main/java/edu/slcc/asdv/bl/UtilitiesDatabase.java @@ -0,0 +1,99 @@ +/* + * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license + * Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template + */ +package edu.slcc.asdv.bl; + +import java.sql.Connection; +import java.sql.DriverManager; +import java.sql.SQLException; +import java.text.ParseException; +import java.text.SimpleDateFormat; + +/** + * + * @author asdv5 + */ +public class UtilitiesDatabase +{ + public Connection connection( + String databaseName, + String userName, + String password, + String URL2 + + ) //throws InstantiationException, IllegalAccessException + { +/* + String databaseName = "suppliers_parts_23"; + String userName = "root"; + String password = "root"; + String URL2 = "com.mysql.jdbc.Driver"; + Connection con = null; +*/ + Connection con; + try + {// Load Sun's jdbc driver + Class.forName(URL2).newInstance(); + System.out.println("JDBC Driver loaded!"); + } + catch (Exception e) // driver not found + { + System.err.println("Unable to load database driver"); + System.err.println("Details : " + e); + return null; + } + String ip = "localhost"; //internet connection + String url = "jdbc:mysql://" + ip + ":3306/" + databaseName + "?allowPublicKeyRetrieval=true&useSSL=false"; + try + { + con = DriverManager.getConnection(url, userName, password); + con.setReadOnly(false); + } + catch (Exception e) + { + System.err.println(e.toString()); + return null; + } + System.out.println("connection successfull"); + return con; + } + + + public void closeDatabaseConnection( Connection con) + { + try + { + if (con != null) + { + con.close(); + } + } + catch (SQLException e) + { + System.out.println(e); + e.printStackTrace(); + } + } + + + +public static java.sql.Date stringDateToSqlDate(String sDate) + { + java.util.Date date = null; + SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd"); + try + { + date = sdf.parse(sDate); + } + catch (ParseException e) + { + e.printStackTrace(); + } + return new java.sql.Date( date.getTime() ); + + } +//public static java { +// java.sqlDate sqldate = stringDateToSqlDate(); +//} +} diff --git a/Semester 2/Assignments/SupplierPartsCalendar/src/main/java/edu/slcc/asdv/bl/part/DatabaseManipulationPart.java b/Semester 2/Assignments/SupplierPartsCalendar/src/main/java/edu/slcc/asdv/bl/part/DatabaseManipulationPart.java new file mode 100644 index 0000000..2078ad6 --- /dev/null +++ b/Semester 2/Assignments/SupplierPartsCalendar/src/main/java/edu/slcc/asdv/bl/part/DatabaseManipulationPart.java @@ -0,0 +1,71 @@ +/* + * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license + * Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template + */ +package edu.slcc.asdv.bl.part; + +import edu.slcc.asdv.bl.DBase; +import edu.slcc.asdv.bl.UtilitiesDatabase; +import edu.slcc.asdv.bl.supplier.Supplier; +import java.sql.Connection; +import java.sql.PreparedStatement; +import java.sql.ResultSet; +import java.sql.SQLException; +import java.util.ArrayList; +import java.util.List; + +/** + * + * @author asdv5 + */ +public class DatabaseManipulationPart implements DBase +{ + private static final String DATABASE_NAME = "suppliers_parts_23"; +private static final String USER_NAME = "java"; +private static final String PASSWORD = "8VCS49HT2xjsEZvC"; +private static final String DRIVER_URL = "com.mysql.jdbc.Driver"; + + @Override +public List listAll() { + List tablePart = new ArrayList<>(); + String sqlStr = "SELECT * FROM part"; + try (Connection con = new UtilitiesDatabase().connection(DATABASE_NAME, USER_NAME, PASSWORD, DRIVER_URL); + PreparedStatement ps = con.prepareStatement(sqlStr); + ResultSet rs = ps.executeQuery()) { + + while (rs.next()) { + String pNumber = rs.getString(1); + String pName = rs.getString(2); + String color = rs.getString(3); + String city = rs.getString(4); + Part part = new Part(pNumber, pName, color, city); + tablePart.add(part); + } + } catch (SQLException ex) { + throw new RuntimeException("Error fetching parts from database", ex); + } + return tablePart; +} + +@Override +public int update(Part part) throws SQLException { + String sqlStr = "UPDATE part SET pname=?, color=?, city=? WHERE pnumber=?"; + try (Connection con = new UtilitiesDatabase().connection(DATABASE_NAME, USER_NAME, PASSWORD, DRIVER_URL); + PreparedStatement ps = con.prepareStatement(sqlStr)) { + + ps.setString(1, part.getPname()); + ps.setString(2, part.getColor()); + ps.setString(3, part.getCity()); + ps.setString(4, part.getPnumber()); + return ps.executeUpdate(); + + } catch (SQLException ex) { + throw new RuntimeException("Error updating part in database", ex); + } +} + + @Override + public int delete(Part t) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); // Generated from nbfs://nbhost/SystemFileSystem/Templates/Classes/Code/GeneratedMethodBody + } +} diff --git a/Semester 2/Assignments/SupplierPartsCalendar/src/main/java/edu/slcc/asdv/bl/part/Part.java b/Semester 2/Assignments/SupplierPartsCalendar/src/main/java/edu/slcc/asdv/bl/part/Part.java new file mode 100644 index 0000000..1f03a1f --- /dev/null +++ b/Semester 2/Assignments/SupplierPartsCalendar/src/main/java/edu/slcc/asdv/bl/part/Part.java @@ -0,0 +1,86 @@ +/* + * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license + * Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template + */ +package edu.slcc.asdv.bl.part; + +/** + * + * @author asdv5 + */ +public class Part +{ + private String pnumber; + private String pname; + private String color; + private String city; + + private boolean modify; + + public boolean isModify() + { + return modify; + } + + public void setModify(boolean modify) + { + this.modify = modify; + } + public Part(String pnumber, String pname, String color, String city) + { + this.pnumber = pnumber; + this.pname = pname; + this.color = color; + this.city = city; + } + + + public String getColor() + { + return color; + } + + public void setColor(String color) + { + this.color = color; + } + + public String getCity() + { + return city; + } + + public void setCity(String city) + { + this.city = city; + } + + public String getPname() + { + return pname; + } + + public void setPname(String pname) + { + this.pname = pname; + } + + public String getPnumber() + { + return pnumber; + } + + public void setPnumber(String pnumber) + { + this.pnumber = pnumber; + } + + @Override + public String toString() + { + return "Part{" + "pnumber=" + pnumber + ", pname=" + pname + ", color=" + color + ", city=" + city + '}'; + } + + + +} diff --git a/Semester 2/Assignments/SupplierPartsCalendar/src/main/java/edu/slcc/asdv/bl/supplier/DatabaseManipulationSupplier.java b/Semester 2/Assignments/SupplierPartsCalendar/src/main/java/edu/slcc/asdv/bl/supplier/DatabaseManipulationSupplier.java new file mode 100644 index 0000000..fb5b991 --- /dev/null +++ b/Semester 2/Assignments/SupplierPartsCalendar/src/main/java/edu/slcc/asdv/bl/supplier/DatabaseManipulationSupplier.java @@ -0,0 +1,151 @@ +/* + * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license + * Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template + */ +package edu.slcc.asdv.bl.supplier; + +import edu.slcc.asdv.bl.DBase; +import edu.slcc.asdv.bl.UtilitiesDatabase; +import java.sql.Connection; +import java.sql.ParameterMetaData; +import java.sql.PreparedStatement; +import java.sql.ResultSet; +import java.sql.SQLException; +import java.util.ArrayList; +import java.util.List; + +/** + * + * @author asdv5 + */ +public class DatabaseManipulationSupplier implements DBase { + + @Override + public List listAll() { + List tableSuppliers = new ArrayList(); + String databaseName = "suppliers_parts_23"; + String userName = "java"; + String password = "8VCS49HT2xjsEZvC"; + String URL2 = "com.mysql.jdbc.Driver"; + Connection con = new UtilitiesDatabase().connection( + databaseName, userName, password, URL2); + PreparedStatement ps = null; + try { + if (con == null) { + throw new RuntimeException("cannot connect to database"); + } + String table = ""; + ResultSet rs = null; + String sqlStr = "SELECT * FROM supplier"; + //prepare statement + ps = con.prepareStatement(sqlStr); + //execute + rs = ps.executeQuery(); + int row = 0; + while (rs.next()) { + String sNumber = rs.getString(1); + String sName = rs.getString(2); + String bdate = rs.getDate(3) + " "; + int status = rs.getInt(4); + String city = rs.getString(5) + " "; + Supplier supplier = new Supplier(sNumber, sName, bdate, status, city); + tableSuppliers.add(supplier); + row++; + } + } catch (Exception ex) { + ex.printStackTrace(); + } finally { + try { + new UtilitiesDatabase().closeDatabaseConnection(con); + // close the resources + if (ps != null) { + ps.close(); + } + } catch (SQLException sqle) { + sqle.printStackTrace(); + } + } + return tableSuppliers; + } + + @Override + public int update(Supplier t) + throws SQLException { + String databaseName = "suppliers_parts_23"; + String userName = "java"; + String password = "8VCS49HT2xjsEZvC"; + String URL2 = "com.mysql.jdbc.Driver"; + Connection con = new UtilitiesDatabase().connection( + databaseName, userName, password, URL2); + int result = 0; + PreparedStatement updateSupplier = null; + try { + if (con == null) { + throw new RuntimeException("cannot connect to database"); + } + + updateSupplier = con.prepareStatement( + "UPDATE supplier SET snumber=?, sname=?, status=?, birthday=?, city=? WHERE snumber=?"); + updateSupplier.setString(1, t.getSnumber()); + updateSupplier.setString(2, t.getSname()); + updateSupplier.setInt(3, t.getStatus()); + java.sql.Date bd = UtilitiesDatabase.stringDateToSqlDate(t.getBirthday()); + updateSupplier.setDate(4, bd); + updateSupplier.setString(5, t.getCity()); + updateSupplier.setString(6, t.getSnumber()); + result = updateSupplier.executeUpdate(); + } catch (SQLException ex) { + System.err.println(ex.toString()); + throw ex; + } finally { + try { + new UtilitiesDatabase().closeDatabaseConnection(con); + // close the resources + if (updateSupplier != null) { + updateSupplier.close(); + } + } catch (SQLException sqle) { + sqle.printStackTrace(); + throw sqle; + } + } + return result; + } + + @Override + public int delete(Supplier t) throws SQLException { + String databaseName = "suppliers_parts_23"; + String userName = "java"; + String password = "8VCS49HT2xjsEZvC"; + String URL2 = "com.mysql.jdbc.Driver"; + Connection con = new UtilitiesDatabase().connection( + databaseName, userName, password, URL2); + int result = 0; + PreparedStatement deleteSupplier = null; + try { + if (con == null) { + throw new RuntimeException("cannot connect to database"); + } + + deleteSupplier = con.prepareStatement( + "DELETE FROM supplier WHERE snumber=?"); + deleteSupplier.setString(1, t.getSnumber()); + result = deleteSupplier.executeUpdate(); + } catch (SQLException ex) { + System.err.println(ex.toString()); + throw ex; + } finally { + try { + new UtilitiesDatabase().closeDatabaseConnection(con); + if (deleteSupplier != null) { + deleteSupplier.close(); + } + } catch (SQLException sqle) { + sqle.printStackTrace(); + throw sqle; + } + } + return result; + } + +} diff --git a/Semester 2/Assignments/SupplierPartsCalendar/src/main/java/edu/slcc/asdv/bl/supplier/Supplier.java b/Semester 2/Assignments/SupplierPartsCalendar/src/main/java/edu/slcc/asdv/bl/supplier/Supplier.java new file mode 100644 index 0000000..d636407 --- /dev/null +++ b/Semester 2/Assignments/SupplierPartsCalendar/src/main/java/edu/slcc/asdv/bl/supplier/Supplier.java @@ -0,0 +1,136 @@ +/* + * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license + * Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template + */ +package edu.slcc.asdv.bl.supplier; + +import edu.slcc.asdv.bl.UtilitiesDatabase; +import java.io.Serializable; +import java.util.Date; +import java.text.SimpleDateFormat; + +/** + * + * @author asdv5 + */ +public class Supplier implements Serializable { + + private String snumber; + private String sname; + private String birthday; + private int status; + private String city; + private Date birthdayDate; + + /** + * Get the value of birthdayDate + * + * @return the value of birthdayDate + */ + public Date getBirthdayDate() + { + birthdayDate = UtilitiesDatabase.stringDateToJavaUtilitiesDate(this.birthday); + return birthdayDate; + } + + /** + * Set the value of birthdayDate + * + * @param birthdayDate new value of birthdayDate + */ + /* + public void setBirthdayDate(Date birthdayDate) + + { + // this.birthday = birthdayDate; + int year = this.birthdayDate.getYear() + 1900; + int month = this.birthdayDate.getMonth()+1; + int day = this.birthdayDate.getDate(); + this.birthdayDate = Integer.toString(year) + "-" + + //Integer.toString(month) + "-" + + Integer.toString(day); + } +*/ + + private boolean modify; + + public boolean isModify() + { + return modify; + } + + public void setModify(boolean modify) + { + this.modify = modify; + } + + public Supplier(String snumber, String sname, String birthday, int status, String city) + { + this.snumber = snumber; + this.sname = sname; + this.birthday = birthday; + this.status = status; + this.city = city; + this.modify = false; + } + + public String getCity() + { + return city; + } + + public void setCity(String city) + { + this.city = city; + } + + public int getStatus() + { + return status; + } + + public void setStatus(int status) + { + this.status = status; + } + + public String getBirthday() + { + return birthday; + } + + public void setBirthday(String birthday) + { + this.birthday = birthday; + } + + + public String getSname() + { + return sname; + } + + public void setSname(String sname) + { + System.out.println(sname); + this.sname = sname; + } + + public String getSnumber() + { + + return snumber; + } + + public void setSnumber(String snumber) + { + this.snumber = snumber; + } + + @Override + public String toString() + { + return "Supplier{" + "snumber=" + snumber + ", sname=" + sname + ", birthday=" + birthday + ", status=" + status + ", city=" + city + '}'; + } + +} diff --git a/Semester 2/Assignments/SupplierPartsCalendar/src/main/resources/META-INF/persistence.xml b/Semester 2/Assignments/SupplierPartsCalendar/src/main/resources/META-INF/persistence.xml new file mode 100644 index 0000000..baad290 --- /dev/null +++ b/Semester 2/Assignments/SupplierPartsCalendar/src/main/resources/META-INF/persistence.xml @@ -0,0 +1,7 @@ + + + + + + + diff --git a/Semester 2/Assignments/SupplierPartsCalendar/src/main/webapp/WEB-INF/beans.xml b/Semester 2/Assignments/SupplierPartsCalendar/src/main/webapp/WEB-INF/beans.xml new file mode 100644 index 0000000..b3a1279 --- /dev/null +++ b/Semester 2/Assignments/SupplierPartsCalendar/src/main/webapp/WEB-INF/beans.xml @@ -0,0 +1,6 @@ + + + \ No newline at end of file diff --git a/Semester 2/Assignments/SupplierPartsCalendar/src/main/webapp/WEB-INF/glassfish-web.xml b/Semester 2/Assignments/SupplierPartsCalendar/src/main/webapp/WEB-INF/glassfish-web.xml new file mode 100644 index 0000000..584a477 --- /dev/null +++ b/Semester 2/Assignments/SupplierPartsCalendar/src/main/webapp/WEB-INF/glassfish-web.xml @@ -0,0 +1,25 @@ + + + + + + + + Keep a copy of the generated servlet class' java code. + + + diff --git a/Semester 2/Assignments/SupplierPartsCalendar/src/main/webapp/WEB-INF/web.xml b/Semester 2/Assignments/SupplierPartsCalendar/src/main/webapp/WEB-INF/web.xml new file mode 100644 index 0000000..11562f0 --- /dev/null +++ b/Semester 2/Assignments/SupplierPartsCalendar/src/main/webapp/WEB-INF/web.xml @@ -0,0 +1,24 @@ + + + + jakarta.faces.PROJECT_STAGE + Development + + + Faces Servlet + jakarta.faces.webapp.FacesServlet + 1 + + + Faces Servlet + /faces/* + + + + 30 + + + + faces/supplier.xhtml + + diff --git a/Semester 2/Assignments/SupplierPartsCalendar/src/main/webapp/index.xhtml b/Semester 2/Assignments/SupplierPartsCalendar/src/main/webapp/index.xhtml new file mode 100644 index 0000000..3220605 --- /dev/null +++ b/Semester 2/Assignments/SupplierPartsCalendar/src/main/webapp/index.xhtml @@ -0,0 +1,51 @@ + + + + + + Supplier Parts DB + + + + +

Suppliers-Parts Database

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ \ No newline at end of file diff --git a/Semester 2/Assignments/SupplierPartsCalendar/src/main/webapp/part.xhtml b/Semester 2/Assignments/SupplierPartsCalendar/src/main/webapp/part.xhtml new file mode 100644 index 0000000..40bc71b --- /dev/null +++ b/Semester 2/Assignments/SupplierPartsCalendar/src/main/webapp/part.xhtml @@ -0,0 +1,68 @@ + + + + + Facelet Title + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Semester 2/Assignments/SupplierPartsCalendar/src/main/webapp/resources/css/styles.css b/Semester 2/Assignments/SupplierPartsCalendar/src/main/webapp/resources/css/styles.css new file mode 100644 index 0000000..9d96af6 --- /dev/null +++ b/Semester 2/Assignments/SupplierPartsCalendar/src/main/webapp/resources/css/styles.css @@ -0,0 +1,71 @@ +.body { + background: #eee; +} + +.button { + margin: 10px; + border-left: thin solid darkGray; + border-bottom: thin solid darkGray; + border-top: thin solid lightGray; + border-right: thin solid lightGray; + color: #777; + background: #A7C942; + font-family: "Comic Sans MS"; + border-radius: 20%; +} +h1 +{ + vertical-align: top; + text-align: middle; + font-style: italic; + color: #888; + font-size: 2em; + font-family: "Comic Sans MS"; + +} + +.label +{ + color: #888; + font-size: 0.8em; + font-family: "Comic Sans MS"; +} +.leftImage { + float: left; + margin-right: 1em; +} + +.backLink { + font-style: italic; +} + + +.tableHeader { + font-family:"Trebuchet MS", Arial, Helvetica, sans-serif; + border-collapse:collapse; + font-size:1.1em; + text-align:left; + padding-top:5px; + padding-bottom:4px; + background-color:#A7C942; + color:white; + border:1px solid #98bf21; +} + +.oddTableRow { + border:1px solid #98bf21; +} + +.evenTableRow { + background-color: #eeeeee; + font-size:1em; + + padding:3px 7px 2px 7px; + + color:#000000; + background-color:#EAF2D3; +} + +.table { + border:1px solid green; +} \ No newline at end of file diff --git a/Semester 2/Assignments/SupplierPartsCalendar/src/main/webapp/supplier.xhtml b/Semester 2/Assignments/SupplierPartsCalendar/src/main/webapp/supplier.xhtml new file mode 100644 index 0000000..b9f2794 --- /dev/null +++ b/Semester 2/Assignments/SupplierPartsCalendar/src/main/webapp/supplier.xhtml @@ -0,0 +1,67 @@ + + + + + Facelet Title + + Supplier Information + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/nb-configuration.xml b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/nb-configuration.xml new file mode 100644 index 0000000..f29f292 --- /dev/null +++ b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/nb-configuration.xml @@ -0,0 +1,21 @@ + + + + + + 9.0-web + gfv700ee10 + Facelets + JDK_11__System_ + + diff --git a/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/pom.xml b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/pom.xml new file mode 100644 index 0000000..0abdfe5 --- /dev/null +++ b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/pom.xml @@ -0,0 +1,88 @@ + + 4.0.0 + com.mycompany + Suppliers_Parts_Calendar_Primefaces + 1.0-SNAPSHOT + war + Suppliers_Parts_Calendar_Primefaces + + + 1.8 + 1.8 + ${project.build.directory}/endorsed + UTF-8 + false + 9.0.0 + + + + + jakarta.platform + jakarta.jakartaee-api + ${jakartaee} + provided + + + com.mysql + mysql-connector-j + 8.1.0 + + + org.primefaces + primefaces + 12.0.0 + jakarta + + + + + + + org.apache.maven.plugins + maven-compiler-plugin + 3.1 + + 1.8 + 1.8 + + ${endorsed.dir} + + + + + org.apache.maven.plugins + maven-war-plugin + 2.3 + + false + + + + org.apache.maven.plugins + maven-dependency-plugin + 2.6 + + + validate + + copy + + + ${endorsed.dir} + true + + + jakarta.platform + jakarta.jakartaee-api + ${jakartaee} + jar + + + + + + + + + \ No newline at end of file diff --git a/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/com/mycompany/supplierspartsdatabase/JakartaRestConfiguration.java b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/com/mycompany/supplierspartsdatabase/JakartaRestConfiguration.java new file mode 100644 index 0000000..110a745 --- /dev/null +++ b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/com/mycompany/supplierspartsdatabase/JakartaRestConfiguration.java @@ -0,0 +1,13 @@ +package com.mycompany.supplierspartsdatabase; + +import jakarta.ws.rs.ApplicationPath; +import jakarta.ws.rs.core.Application; + +/** + * Configures Jakarta RESTful Web Services for the application. + * @author Juneau + */ +@ApplicationPath("resources") +public class JakartaRestConfiguration extends Application { + +} diff --git a/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/com/mycompany/supplierspartsdatabase/resources/JakartaEE9Resource.java b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/com/mycompany/supplierspartsdatabase/resources/JakartaEE9Resource.java new file mode 100644 index 0000000..f7f850d --- /dev/null +++ b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/com/mycompany/supplierspartsdatabase/resources/JakartaEE9Resource.java @@ -0,0 +1,20 @@ +package com.mycompany.supplierspartsdatabase.resources; + +import jakarta.ws.rs.GET; +import jakarta.ws.rs.Path; +import jakarta.ws.rs.core.Response; + +/** + * + * @author + */ +@Path("jakartaee9") +public class JakartaEE9Resource { + + @GET + public Response ping(){ + return Response + .ok("ping Jakarta EE") + .build(); + } +} diff --git a/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/edu/slcc/asdv/beans/SupplierBean.java b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/edu/slcc/asdv/beans/SupplierBean.java new file mode 100644 index 0000000..a89ddc9 --- /dev/null +++ b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/edu/slcc/asdv/beans/SupplierBean.java @@ -0,0 +1,166 @@ +/* + * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license + * Click nbfs://nbhost/SystemFileSystem/Templates/JSF/JSFManagedBean.java to edit this template + */ +package edu.slcc.asdv.beans; + +import edu.slcc.asdv.bl.DBase; +import edu.slcc.asdv.bl.supplier.DatabaseManipulationSupplier; +import edu.slcc.asdv.bl.supplier.Supplier; +import jakarta.annotation.PostConstruct; +import jakarta.inject.Named; +import jakarta.enterprise.context.SessionScoped; +import jakarta.faces.application.FacesMessage; +import jakarta.faces.application.FacesMessage.Severity; +import jakarta.faces.context.FacesContext; +import jakarta.faces.event.ComponentSystemEvent; +import jakarta.inject.Inject; +import java.io.Serializable; +import java.util.List; + +@Named(value = "supplierBean") +@SessionScoped +public class SupplierBean implements Serializable { + + //DBase dms = new DatabaseManipulationSupplier(); + @Inject + DatabaseManipulationSupplier dms; + List suppliers; + + + /* + public SupplierBean() + { + try + { + suppliers = dms.listAll(); + } + catch (Exception e) + { + suppliers = null; + } + } + */ + @PostConstruct + public void init() + { + try { + suppliers = dms.listAll(); + } catch (Exception e) { + suppliers = null; + } + } + + public DatabaseManipulationSupplier getDms() + { + return dms; + } + + public void displayExceptionMessageAtPreRenderListener(ComponentSystemEvent event) + { + if (suppliers == null) { + addMessage("Database problem occured.", + "", FacesMessage.SEVERITY_ERROR); + } + } + + public List getSuppliers() + { + return suppliers; + } + + public void insertSupplier() + { + System.out.println("insertSupplier(Supplier s)"); + suppliers.add(new Supplier()); + } + + public void deleteSupplier(Supplier s) + { + if (suppliers == null) { + return; + } + int totalRowsUpdated = 0; + try { + int rowsUpdated = this.dms.delete(s); + if (rowsUpdated > 0) { + suppliers = dms.listAll(); + totalRowsUpdated += rowsUpdated; + } + } catch (Exception e) { + String msg = ("Numbers of rows updated is 0."); + addMessage(msg, e.getMessage(), FacesMessage.SEVERITY_ERROR); + } + if (totalRowsUpdated > 0) { + String msg = ("Numbers of rows updated: " + totalRowsUpdated); + addMessage(msg, "no exception", FacesMessage.SEVERITY_INFO); + } + } + + public void deleteSupplier() + { + if (suppliers == null) { + return; + } + int totalRowsUpdated = 0; + for (Supplier s : this.suppliers) { + if (s.isModify()) { + try { + int rowsUpdated = this.dms.delete(s); + if (rowsUpdated > 0) { + totalRowsUpdated += rowsUpdated; + s.setModify(false); + } + } catch (Exception e) { + String msg = ("Numbers of rows updated is 0."); + addMessage(msg, e.getMessage(), FacesMessage.SEVERITY_ERROR); + break; + } + } + } + if (totalRowsUpdated > 0) { + try { + suppliers = dms.listAll(); + } catch (Exception e) { + suppliers = null; + addMessage("Unable to obtain suppliers!", "no exception", FacesMessage.SEVERITY_INFO); + } + String msg = ("Numbers of rows updated: " + totalRowsUpdated); + addMessage(msg, "no exception", FacesMessage.SEVERITY_INFO); + } + } + + public void saveFromUpdate() + { + if (suppliers == null) { + return; + } + int totalRowsUpdated = 0; + for (Supplier s : this.suppliers) { + if (s.isModify()) { + try { + int rowsUpdated = this.dms.update(s); + if (rowsUpdated > 0) { + System.out.println(s); + totalRowsUpdated += rowsUpdated; + s.setModify(false); + } + } catch (Exception e) { + String msg = ("Numbers of rows updated is 0."); + addMessage(msg, e.getMessage(), FacesMessage.SEVERITY_ERROR); + break; + } + } + } + if (totalRowsUpdated > 0) { + String msg = ("Numbers of rows updated: " + totalRowsUpdated); + addMessage(msg, "no exception", FacesMessage.SEVERITY_INFO); + } + } + + public void addMessage(String summary, String detail, Severity severity) + { + FacesMessage msg = new FacesMessage(severity, summary, detail); + FacesContext.getCurrentInstance().addMessage(null, msg); + } +} diff --git a/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/edu/slcc/asdv/bl/DBase.java b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/edu/slcc/asdv/bl/DBase.java new file mode 100644 index 0000000..7a79952 --- /dev/null +++ b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/edu/slcc/asdv/bl/DBase.java @@ -0,0 +1,30 @@ +/* + * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license + * Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template + */ +package edu.slcc.asdv.bl; + +import java.io.Serializable; +import java.sql.SQLException; +import java.util.List; + +/** + * + * @author asdv5 + */ +public interface DBase +{ + List listAll() + throws SQLException; + + int update( T t) + throws SQLException; + + int delete( T t) + throws SQLException; + + + int insert( T t) + throws SQLException; + +} \ No newline at end of file diff --git a/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/edu/slcc/asdv/bl/UtilitiesDatabase.java b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/edu/slcc/asdv/bl/UtilitiesDatabase.java new file mode 100644 index 0000000..6fdca3b --- /dev/null +++ b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/edu/slcc/asdv/bl/UtilitiesDatabase.java @@ -0,0 +1,103 @@ +/* + * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license + * Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template + */ +package edu.slcc.asdv.bl; + +import java.sql.Connection; +import java.sql.DriverManager; +import java.sql.SQLException; +import java.text.ParseException; +import java.text.SimpleDateFormat; + +/** + * + * @author asdv5 + */ +public class UtilitiesDatabase +{ + public Connection connection( + String databaseName, + String userName, + String password, + String URL2 + + ) //throws InstantiationException, IllegalAccessException + { +/* + String databaseName = "suppliers_parts_23"; + String userName = "root"; + String password = "root"; + String URL2 = "com.mysql.jdbc.Driver"; + Connection con = null; +*/ + Connection con; + try + {// Load Sun's jdbc driver + Class.forName(URL2).newInstance(); + System.out.println("JDBC Driver loaded!"); + } + catch (Exception e) // driver not found + { + System.err.println("Unable to load database driver"); + System.err.println("Details : " + e); + return null; + } + String ip = "localhost"; //internet connection + String url = "jdbc:mysql://" + ip + ":3306/" + databaseName + "?allowPublicKeyRetrieval=true&useSSL=false"; + try + { + con = DriverManager.getConnection(url, userName, password); + con.setReadOnly(false); + } + catch (Exception e) + { + System.err.println(e.toString()); + return null; + } + System.out.println("connection successfull"); + return con; + } + + + public void closeDatabaseConnection( Connection con) + { + try + { + if (con != null) + { + con.close(); + } + } + catch (SQLException e) + { + System.out.println(e); + e.printStackTrace(); + } + } + + + +public static java.sql.Date stringDateToSqlDate(String sDate) + { + java.util.Date date = null; + SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd"); + try + { + date = sdf.parse(sDate); + } + catch (ParseException e) + { + e.printStackTrace(); + } + return new java.sql.Date( date.getTime() ); + + } + + +public static java.util.Date stringDateToJavaUtilitiesDate(String sDate) + { + java.sql.Date sqldate = stringDateToSqlDate(sDate); + return new java.util.Date(sqldate.getTime() ); + } +} diff --git a/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/edu/slcc/asdv/bl/part/DatabaseManipulationPart.java b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/edu/slcc/asdv/bl/part/DatabaseManipulationPart.java new file mode 100644 index 0000000..ebdec92 --- /dev/null +++ b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/edu/slcc/asdv/bl/part/DatabaseManipulationPart.java @@ -0,0 +1,104 @@ +/* + * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license + * Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template + */ +package edu.slcc.asdv.bl.part; + +import edu.slcc.asdv.bl.DBase; +import edu.slcc.asdv.bl.UtilitiesDatabase; +import java.sql.Connection; +import java.sql.PreparedStatement; +import java.sql.ResultSet; +import java.sql.SQLException; +import java.util.ArrayList; +import java.util.List; + +/** + * + * @author asdv5 + */ +public class DatabaseManipulationPart implements DBase +{ + @Override + public List listAll() + { + List tableParts = new ArrayList(); + String databaseName = "suppliers_parts_23"; + String userName = "root"; + String password = "root"; + String URL2 = "com.mysql.jdbc.Driver"; + Connection con = new UtilitiesDatabase().connection( + databaseName, userName, password, URL2); + PreparedStatement ps = null; + try + { + if (con == null) + { + throw new RuntimeException("cannot connect to database"); + } + String table = ""; + ResultSet rs = null; + String sqlStr = "SELECT * FROM part"; + //prepare statement + ps = con.prepareStatement(sqlStr); + //execute + rs = ps.executeQuery(); + int row = 0; + while (rs.next()) + { + String pNumber = rs.getString(1); + String pName = rs.getString(2); + String color = rs.getString(3) + " "; + String city = rs.getString(4) + " "; + Part part = new Part(pNumber, pName, color, city); + tableParts.add(part); + row++; + } + } + catch (Exception ex) + { + ex.printStackTrace(); + } + finally + { + try + { + new UtilitiesDatabase().closeDatabaseConnection(con); + // close the resources + if (ps != null) + { + ps.close(); + } + } + catch (SQLException sqle) + { + sqle.printStackTrace(); + } + } + return tableParts; + } + + public static void main(String[] args) + { + DatabaseManipulationPart dmp = new DatabaseManipulationPart(); + System.out.println(dmp.listAll()); + } + + @Override + public int update(Part t) + { + throw new UnsupportedOperationException("Not supported yet."); // Generated from nbfs://nbhost/SystemFileSystem/Templates/Classes/Code/GeneratedMethodBody + } + + @Override + public int delete(Part t) throws SQLException + { + throw new UnsupportedOperationException("Not supported yet."); // Generated from nbfs://nbhost/SystemFileSystem/Templates/Classes/Code/GeneratedMethodBody + } + + @Override + public int insert(Part t) throws SQLException + { + return -1; + } +} diff --git a/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/edu/slcc/asdv/bl/part/Part.java b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/edu/slcc/asdv/bl/part/Part.java new file mode 100644 index 0000000..54bd19a --- /dev/null +++ b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/edu/slcc/asdv/bl/part/Part.java @@ -0,0 +1,75 @@ +/* + * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license + * Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template + */ +package edu.slcc.asdv.bl.part; + +/** + * + * @author asdv5 + */ +public class Part +{ + private String pnumber; + private String pname; + private String color; + private String city; + + public Part(String pnumber, String pname, String color, String city) + { + this.pnumber = pnumber; + this.pname = pname; + this.color = color; + this.city = city; + } + + + public String getColor() + { + return color; + } + + public void setColor(String color) + { + this.color = color; + } + + public String getCity() + { + return city; + } + + public void setCity(String city) + { + this.city = city; + } + + public String getPname() + { + return pname; + } + + public void setPname(String pname) + { + this.pname = pname; + } + + public String getPnumber() + { + return pnumber; + } + + public void setPnumber(String pnumber) + { + this.pnumber = pnumber; + } + + @Override + public String toString() + { + return "Part{" + "pnumber=" + pnumber + ", pname=" + pname + ", color=" + color + ", city=" + city + '}'; + } + + + +} diff --git a/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/edu/slcc/asdv/bl/supplier/DatabaseManipulationSupplier.java b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/edu/slcc/asdv/bl/supplier/DatabaseManipulationSupplier.java new file mode 100644 index 0000000..1b60dd8 --- /dev/null +++ b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/edu/slcc/asdv/bl/supplier/DatabaseManipulationSupplier.java @@ -0,0 +1,228 @@ +/* + * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license + * Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template + */ +package edu.slcc.asdv.bl.supplier; + +import edu.slcc.asdv.bl.DBase; +import edu.slcc.asdv.bl.UtilitiesDatabase; +import java.io.Serializable; +import java.sql.Connection; +import java.sql.PreparedStatement; +import java.sql.ResultSet; +import java.sql.SQLException; +import java.util.ArrayList; +import java.util.List; + +/** + * + * @author asdv5 + */ +public class DatabaseManipulationSupplier + implements DBase, Serializable +{ + @Override + public List listAll() + throws SQLException + { + // test exception code + //if ( true) + // throw new SQLException(); + + List tableSuppliers = new ArrayList(); + String databaseName = "suppliers_parts_23"; + String userName = "java"; + String password = "8VCS49HT2xjsEZvC"; + String URL2 = "com.mysql.jdbc.Driver"; + Connection con = new UtilitiesDatabase().connection( + databaseName, userName, password, URL2); + PreparedStatement ps = null; + try + { + if (con == null) + { + throw new RuntimeException("cannot connect to database"); + } + String table = ""; + ResultSet rs = null; + String sqlStr = "SELECT * FROM supplier"; + //prepare statement + ps = con.prepareStatement(sqlStr); + //execute + rs = ps.executeQuery(); + int row = 0; + while (rs.next()) + { + String sNumber = rs.getString(1); + String sName = rs.getString(2); + String bdate = ""; + if ( rs.getDate(3) == null ) + { + bdate = "2000-01-01 "; + } + else + bdate = rs.getDate(3) + " "; + int status = rs.getInt(4); + String city = rs.getString(5) + " "; + Supplier supplier = new Supplier(sNumber, sName, bdate, status, city); + tableSuppliers.add(supplier); + row++; + } + } + catch (Exception ex) + { + ex.printStackTrace(); + throw ex; + } + finally + { + try + { + new UtilitiesDatabase().closeDatabaseConnection(con); + // close the resources + if (ps != null) + { + ps.close(); + } + } + catch (SQLException sqle) + { + System.out.println(sqle); + sqle.printStackTrace(); + throw sqle; + } + } + return tableSuppliers; + } + + @Override + public int update(Supplier t) + throws SQLException + { + String databaseName = "suppliers_parts_23"; + String userName = "java"; + String password = "8VCS49HT2xjsEZvC"; + String URL2 = "com.mysql.jdbc.Driver"; + Connection con = new UtilitiesDatabase().connection( + databaseName, userName, password, URL2); + int result = 0; + PreparedStatement updateSupplier = null; + try + { + if (con == null) + { + throw new RuntimeException("cannot connect to database"); + } + + + updateSupplier = con.prepareStatement( + "UPDATE supplier SET snumber=?, sname=?, status=?, birthday=?, city=? WHERE snumber=?"); + updateSupplier.setString(1, t.getSnumber()); + updateSupplier.setString(2, t.getSname()); + updateSupplier.setInt(3, t.getStatus()); + java.sql.Date bd = UtilitiesDatabase.stringDateToSqlDate(t.getBirthday()); + updateSupplier.setDate(4, bd); + updateSupplier.setString(5, t.getCity()); + updateSupplier.setString(6, t.getSnumber()); + result = updateSupplier.executeUpdate(); + } + catch (SQLException ex) + { + System.err.println(ex.toString()); + throw ex; + } + finally + { + try + { + new UtilitiesDatabase().closeDatabaseConnection(con); + // close the resources + if (updateSupplier != null) + { + updateSupplier.close(); + } + } + catch (SQLException sqle) + { + sqle.printStackTrace(); + throw sqle; + } + } + return result; + } + + @Override + public int delete(Supplier c) throws SQLException + { + String databaseName = "suppliers_parts_23"; + String userName = "java"; + String password = "8VCS49HT2xjsEZvC"; + String URL2 = "com.mysql.jdbc.Driver"; + Connection con = new UtilitiesDatabase().connection( + databaseName, userName, password, URL2); + int result = 0; + PreparedStatement ps = null; + try + { + if (con == null) + { + throw new RuntimeException("Database connection failed."); + } + String query = "DELETE FROM supplier WHERE snumber=? "; + ps = con.prepareStatement(query); + ps.setString(1, c.getSnumber()); + result = ps.executeUpdate(); + } + catch (Exception ex) + { + System.err.println(ex.toString()); + } + finally + { + try + { + new UtilitiesDatabase().closeDatabaseConnection(con); + // close the resources + if (ps != null) + { + ps.close(); + } + } + catch (SQLException sqlee) + { + sqlee.printStackTrace(); + } + } + return result; + } + + @Override + public int insert(Supplier c) throws SQLException { + String databaseName = "tennis-23"; + String userName = "java"; + String password = "8VCS49HT2xjsEZvC"; + String driver = "com.mysql.jdbc.Driver"; + Connection con = new UtilitiesDatabase().connection(databaseName, userName, password, driver); + ///"UPDATE supplier SET snumber=?, sname=?, status=?, birthday=?, city=? WHERE snumber=?" + String sqlStr = "INSERT INTO suppliers (snumber, sname, status, birthday, city) VALUES (?, ?, ?, ?, ?)"; + int result = 0; + + try (PreparedStatement ps = con.prepareStatement(sqlStr)) { + ps.setString(1, c.getSnumber()); + ps.setString(2, c.getSname()); + ps.setInt(3, c.getStatus()); + ps.setDate(4, new java.sql.Date(c.getBirth_Date().getTime())); // Converts java.util.Date to java.sql.Date + ps.setString(5, c.getCity()); + + result = ps.executeUpdate(); + } catch (SQLException sqle) { + sqle.printStackTrace(); + throw sqle; + } finally { + new UtilitiesDatabase().closeDatabaseConnection(con); + } + return result; + } + + +} diff --git a/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/edu/slcc/asdv/bl/supplier/Supplier.java b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/edu/slcc/asdv/bl/supplier/Supplier.java new file mode 100644 index 0000000..c7bff35 --- /dev/null +++ b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/java/edu/slcc/asdv/bl/supplier/Supplier.java @@ -0,0 +1,138 @@ +/* + * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license + * Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template + */ +package edu.slcc.asdv.bl.supplier; + +import edu.slcc.asdv.bl.UtilitiesDatabase; +import java.io.Serializable; +import java.util.Date; + +/** + * + * @author asdv5 + */ +public class Supplier implements Serializable +{ + private String snumber; + private String sname; + private String birthday; + private int status; + private String city; + private Date birthday_date; + private boolean insertFromDatatable; + private boolean modify; + + public boolean isModify() + { + return modify; + } + + public void setModify(boolean modify) + { + this.modify = modify; + } + + public Supplier() + { + this.modify = true; + insertFromDatatable = true; + birthday = "2000-01-01"; + birthday_date = UtilitiesDatabase.stringDateToJavaUtilitiesDate(birthday); + } + + public Supplier(String snumber, String sname, String birthday, int status, String city) + { + insertFromDatatable = false; + this.snumber = snumber; + this.sname = sname; + this.birthday = birthday; + this.status = status; + this.city = city; + this.modify = false; + } + + public boolean isInsertFromDatatable() + { + return insertFromDatatable; + } + + public void setInsertFromDatatable(boolean insertFromDatatable) + { + this.insertFromDatatable = insertFromDatatable; + } + + public String getCity() + { + return city; + } + + public void setCity(String city) + { + this.city = city; + } + + public int getStatus() + { + return status; + } + + public void setStatus(int status) + { + this.status = status; + } + + public String getBirthday() + { + return birthday; + } + + public void setBirthday(String birthday) + { + this.birthday = birthday; + } + + public Date getBirthday_date() + { + birthday_date = UtilitiesDatabase.stringDateToJavaUtilitiesDate(this.birthday); + return birthday_date; + } + + public void setBirthday_date(Date birthday_date) + { + this.birthday_date = birthday_date; + int year = this.birthday_date.getYear() + 1900; + int month = this.birthday_date.getMonth() + 1; + int day = this.birthday_date.getDate(); + this.birthday = Integer.toString(year) + "-" + + Integer.toString(month) + "-" + + Integer.toString(day); + } + + public String getSname() + { + return sname; + } + + public void setSname(String sname) + { + System.out.println(sname); + this.sname = sname; + } + + public String getSnumber() + { + return snumber; + } + + public void setSnumber(String snumber) + { + this.snumber = snumber; + } + + @Override + public String toString() + { + return "Supplier{" + "snumber=" + snumber + ", sname=" + sname + ", birthday=" + birthday + ", status=" + status + ", city=" + city + '}'; + } +} diff --git a/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/resources/META-INF/persistence.xml b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/resources/META-INF/persistence.xml new file mode 100644 index 0000000..baad290 --- /dev/null +++ b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/resources/META-INF/persistence.xml @@ -0,0 +1,7 @@ + + + + + + + diff --git a/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/webapp/WEB-INF/beans.xml b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/webapp/WEB-INF/beans.xml new file mode 100644 index 0000000..b3a1279 --- /dev/null +++ b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/webapp/WEB-INF/beans.xml @@ -0,0 +1,6 @@ + + + \ No newline at end of file diff --git a/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/webapp/WEB-INF/glassfish-web.xml b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/webapp/WEB-INF/glassfish-web.xml new file mode 100644 index 0000000..584a477 --- /dev/null +++ b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/webapp/WEB-INF/glassfish-web.xml @@ -0,0 +1,25 @@ + + + + + + + + Keep a copy of the generated servlet class' java code. + + + diff --git a/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/webapp/WEB-INF/web.xml b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/webapp/WEB-INF/web.xml new file mode 100644 index 0000000..11562f0 --- /dev/null +++ b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/webapp/WEB-INF/web.xml @@ -0,0 +1,24 @@ + + + + jakarta.faces.PROJECT_STAGE + Development + + + Faces Servlet + jakarta.faces.webapp.FacesServlet + 1 + + + Faces Servlet + /faces/* + + + + 30 + + + + faces/supplier.xhtml + + diff --git a/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/webapp/index.xhtml b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/webapp/index.xhtml new file mode 100644 index 0000000..3220605 --- /dev/null +++ b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/webapp/index.xhtml @@ -0,0 +1,51 @@ + + + + + + Supplier Parts DB + + + + +

Suppliers-Parts Database

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ \ No newline at end of file diff --git a/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/webapp/resources/css/styles.css b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/webapp/resources/css/styles.css new file mode 100644 index 0000000..9d96af6 --- /dev/null +++ b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/webapp/resources/css/styles.css @@ -0,0 +1,71 @@ +.body { + background: #eee; +} + +.button { + margin: 10px; + border-left: thin solid darkGray; + border-bottom: thin solid darkGray; + border-top: thin solid lightGray; + border-right: thin solid lightGray; + color: #777; + background: #A7C942; + font-family: "Comic Sans MS"; + border-radius: 20%; +} +h1 +{ + vertical-align: top; + text-align: middle; + font-style: italic; + color: #888; + font-size: 2em; + font-family: "Comic Sans MS"; + +} + +.label +{ + color: #888; + font-size: 0.8em; + font-family: "Comic Sans MS"; +} +.leftImage { + float: left; + margin-right: 1em; +} + +.backLink { + font-style: italic; +} + + +.tableHeader { + font-family:"Trebuchet MS", Arial, Helvetica, sans-serif; + border-collapse:collapse; + font-size:1.1em; + text-align:left; + padding-top:5px; + padding-bottom:4px; + background-color:#A7C942; + color:white; + border:1px solid #98bf21; +} + +.oddTableRow { + border:1px solid #98bf21; +} + +.evenTableRow { + background-color: #eeeeee; + font-size:1em; + + padding:3px 7px 2px 7px; + + color:#000000; + background-color:#EAF2D3; +} + +.table { + border:1px solid green; +} \ No newline at end of file diff --git a/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/webapp/supplier.xhtml b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/webapp/supplier.xhtml new file mode 100644 index 0000000..3372982 --- /dev/null +++ b/Semester 2/Assignments/Supplier_Parts_Calendar_Primefaces/src/main/webapp/supplier.xhtml @@ -0,0 +1,101 @@ + + + + + Suppliers Table + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ + +     + +
+ +
+
+ diff --git a/Semester 2/Assignments/SuppliersPartsDatabase/src/main/webapp/supplier.xhtml b/Semester 2/Assignments/SuppliersPartsDatabase/src/main/webapp/supplier.xhtml index ef1c1b7..752e1cd 100644 --- a/Semester 2/Assignments/SuppliersPartsDatabase/src/main/webapp/supplier.xhtml +++ b/Semester 2/Assignments/SuppliersPartsDatabase/src/main/webapp/supplier.xhtml @@ -32,7 +32,8 @@ - + + @@ -57,7 +58,7 @@ - diff --git a/Semester 2/Assignments/suppliers_parts_calendar/nb-configuration.xml b/Semester 2/Assignments/suppliers_parts_calendar/nb-configuration.xml new file mode 100644 index 0000000..f29f292 --- /dev/null +++ b/Semester 2/Assignments/suppliers_parts_calendar/nb-configuration.xml @@ -0,0 +1,21 @@ + + + + + + 9.0-web + gfv700ee10 + Facelets + JDK_11__System_ + + diff --git a/Semester 2/Assignments/suppliers_parts_calendar/pom.xml b/Semester 2/Assignments/suppliers_parts_calendar/pom.xml new file mode 100644 index 0000000..da7d077 --- /dev/null +++ b/Semester 2/Assignments/suppliers_parts_calendar/pom.xml @@ -0,0 +1,88 @@ + + 4.0.0 + com.mycompany + SuppliersPartsCalendar + 1.0-SNAPSHOT + war + Suppliers_Parts_Calendar + + + 1.8 + 1.8 + ${project.build.directory}/endorsed + UTF-8 + false + 9.0.0 + + + + + jakarta.platform + jakarta.jakartaee-api + ${jakartaee} + provided + + + com.mysql + mysql-connector-j + 8.1.0 + + + org.primefaces + primefaces + 12.0.0 + jakarta + + + + + + + org.apache.maven.plugins + maven-compiler-plugin + 3.1 + + 1.8 + 1.8 + + ${endorsed.dir} + + + + + org.apache.maven.plugins + maven-war-plugin + 2.3 + + false + + + + org.apache.maven.plugins + maven-dependency-plugin + 2.6 + + + validate + + copy + + + ${endorsed.dir} + true + + + jakarta.platform + jakarta.jakartaee-api + ${jakartaee} + jar + + + + + + + + + \ No newline at end of file diff --git a/Semester 2/Assignments/suppliers_parts_calendar/src/main/java/com/mycompany/supplierspartsdatabase/JakartaRestConfiguration.java b/Semester 2/Assignments/suppliers_parts_calendar/src/main/java/com/mycompany/supplierspartsdatabase/JakartaRestConfiguration.java new file mode 100644 index 0000000..110a745 --- /dev/null +++ b/Semester 2/Assignments/suppliers_parts_calendar/src/main/java/com/mycompany/supplierspartsdatabase/JakartaRestConfiguration.java @@ -0,0 +1,13 @@ +package com.mycompany.supplierspartsdatabase; + +import jakarta.ws.rs.ApplicationPath; +import jakarta.ws.rs.core.Application; + +/** + * Configures Jakarta RESTful Web Services for the application. + * @author Juneau + */ +@ApplicationPath("resources") +public class JakartaRestConfiguration extends Application { + +} diff --git a/Semester 2/Assignments/suppliers_parts_calendar/src/main/java/com/mycompany/supplierspartsdatabase/resources/JakartaEE9Resource.java b/Semester 2/Assignments/suppliers_parts_calendar/src/main/java/com/mycompany/supplierspartsdatabase/resources/JakartaEE9Resource.java new file mode 100644 index 0000000..f7f850d --- /dev/null +++ b/Semester 2/Assignments/suppliers_parts_calendar/src/main/java/com/mycompany/supplierspartsdatabase/resources/JakartaEE9Resource.java @@ -0,0 +1,20 @@ +package com.mycompany.supplierspartsdatabase.resources; + +import jakarta.ws.rs.GET; +import jakarta.ws.rs.Path; +import jakarta.ws.rs.core.Response; + +/** + * + * @author + */ +@Path("jakartaee9") +public class JakartaEE9Resource { + + @GET + public Response ping(){ + return Response + .ok("ping Jakarta EE") + .build(); + } +} diff --git a/Semester 2/Assignments/suppliers_parts_calendar/src/main/java/edu/slcc/asdv/beans/SupplierBean.java b/Semester 2/Assignments/suppliers_parts_calendar/src/main/java/edu/slcc/asdv/beans/SupplierBean.java new file mode 100644 index 0000000..96b42fb --- /dev/null +++ b/Semester 2/Assignments/suppliers_parts_calendar/src/main/java/edu/slcc/asdv/beans/SupplierBean.java @@ -0,0 +1,148 @@ +/* + * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license + * Click nbfs://nbhost/SystemFileSystem/Templates/JSF/JSFManagedBean.java to edit this template + */ +package edu.slcc.asdv.beans; + +import edu.slcc.asdv.bl.DBase; +import edu.slcc.asdv.bl.supplier.DatabaseManipulationSupplier; +import edu.slcc.asdv.bl.supplier.Supplier; +import jakarta.inject.Named; +import jakarta.enterprise.context.SessionScoped; +import jakarta.faces.application.FacesMessage; +import jakarta.faces.application.FacesMessage.Severity; +import jakarta.faces.component.UIComponent; +import jakarta.faces.context.FacesContext; +import jakarta.faces.event.ComponentSystemEvent; +import java.io.Serializable; +import java.sql.SQLException; +import java.util.Date; +import java.util.List; + +@Named(value = "supplierBean") +@SessionScoped +public class SupplierBean implements Serializable +{ + DBase dms = new DatabaseManipulationSupplier(); + List suppliers; + + + + public SupplierBean() + { + try + { + suppliers = dms.listAll(); + } + catch (Exception e) + { + suppliers = null; + } + } + + + + public void displayExceptionMessageAtPreRenderListener(ComponentSystemEvent event) + { + if (suppliers == null) + addMessage("Database problem occured.", + "", FacesMessage.SEVERITY_ERROR); + } + + public List getSuppliers() + { + return suppliers; + } + + public void deleteSupplier(Supplier s) + { + System.out.println("deleteSupplier(Supplier s)"); + } + public void deleteSupplier() + { + if (suppliers == null) + return; + + int totalRowsUpdated = 0; + for (Supplier s : this.suppliers) + { + if (s.isModify()) + { + try + { + int rowsUpdated = this.dms.update(s); + if (rowsUpdated > 0) + { + totalRowsUpdated += rowsUpdated; + s.setModify(false); + } + } + catch (Exception e) + { + String msg = ("Numbers of rows updated is 0."); + addMessage(msg, e.getMessage(), FacesMessage.SEVERITY_ERROR); + break; + } + } + } + if (totalRowsUpdated > 0) + { + String msg = ("Numbers of rows updated: " + totalRowsUpdated); + addMessage(msg, "no exception", FacesMessage.SEVERITY_INFO); + } + } + + public void insertNew() { + Supplier newSupplier = new Supplier(); + suppliers.add(newSupplier); + try { + this.dms.insert(newSupplier); + } catch (SQLException e) { + String msg = ("Unable to add a new row."); + addMessage(msg, e.getMessage(), FacesMessage.SEVERITY_ERROR); + } + + } + + + public void saveFromUpdate() + { + if (suppliers == null) + return; + + int totalRowsUpdated = 0; + for (Supplier s : this.suppliers) + { + if (s.isModify()) + { + try + { + int rowsUpdated = this.dms.update(s); + if (rowsUpdated > 0) + { + System.out.println(s); + totalRowsUpdated += rowsUpdated; + s.setModify(false); + } + } + catch (Exception e) + { + String msg = ("Numbers of rows updated is 0."); + addMessage(msg, e.getMessage(), FacesMessage.SEVERITY_ERROR); + break; + } + } + } + if (totalRowsUpdated > 0) + { + String msg = ("Numbers of rows updated: " + totalRowsUpdated); + addMessage(msg, "no exception", FacesMessage.SEVERITY_INFO); + } + } + + public void addMessage(String summary, String detail, Severity severity) + { + FacesMessage msg = new FacesMessage(severity, summary, detail); + FacesContext.getCurrentInstance().addMessage(null, msg); + } +} diff --git a/Semester 2/Assignments/suppliers_parts_calendar/src/main/java/edu/slcc/asdv/bl/DBase.java b/Semester 2/Assignments/suppliers_parts_calendar/src/main/java/edu/slcc/asdv/bl/DBase.java new file mode 100644 index 0000000..e9c194d --- /dev/null +++ b/Semester 2/Assignments/suppliers_parts_calendar/src/main/java/edu/slcc/asdv/bl/DBase.java @@ -0,0 +1,28 @@ +/* + * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license + * Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template + */ +package edu.slcc.asdv.bl; + +import java.sql.SQLException; +import java.util.ArrayList; +import java.util.List; + +/** + * + * @author asdv5 + */ +public interface DBase +{ + List listAll() + throws SQLException; + + int update( T t) + throws SQLException; + + int delete( T t) + throws SQLException; + + int insert (T t) + throws SQLException; +} \ No newline at end of file diff --git a/Semester 2/Assignments/suppliers_parts_calendar/src/main/java/edu/slcc/asdv/bl/UtilitiesDatabase.java b/Semester 2/Assignments/suppliers_parts_calendar/src/main/java/edu/slcc/asdv/bl/UtilitiesDatabase.java new file mode 100644 index 0000000..6fdca3b --- /dev/null +++ b/Semester 2/Assignments/suppliers_parts_calendar/src/main/java/edu/slcc/asdv/bl/UtilitiesDatabase.java @@ -0,0 +1,103 @@ +/* + * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license + * Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template + */ +package edu.slcc.asdv.bl; + +import java.sql.Connection; +import java.sql.DriverManager; +import java.sql.SQLException; +import java.text.ParseException; +import java.text.SimpleDateFormat; + +/** + * + * @author asdv5 + */ +public class UtilitiesDatabase +{ + public Connection connection( + String databaseName, + String userName, + String password, + String URL2 + + ) //throws InstantiationException, IllegalAccessException + { +/* + String databaseName = "suppliers_parts_23"; + String userName = "root"; + String password = "root"; + String URL2 = "com.mysql.jdbc.Driver"; + Connection con = null; +*/ + Connection con; + try + {// Load Sun's jdbc driver + Class.forName(URL2).newInstance(); + System.out.println("JDBC Driver loaded!"); + } + catch (Exception e) // driver not found + { + System.err.println("Unable to load database driver"); + System.err.println("Details : " + e); + return null; + } + String ip = "localhost"; //internet connection + String url = "jdbc:mysql://" + ip + ":3306/" + databaseName + "?allowPublicKeyRetrieval=true&useSSL=false"; + try + { + con = DriverManager.getConnection(url, userName, password); + con.setReadOnly(false); + } + catch (Exception e) + { + System.err.println(e.toString()); + return null; + } + System.out.println("connection successfull"); + return con; + } + + + public void closeDatabaseConnection( Connection con) + { + try + { + if (con != null) + { + con.close(); + } + } + catch (SQLException e) + { + System.out.println(e); + e.printStackTrace(); + } + } + + + +public static java.sql.Date stringDateToSqlDate(String sDate) + { + java.util.Date date = null; + SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd"); + try + { + date = sdf.parse(sDate); + } + catch (ParseException e) + { + e.printStackTrace(); + } + return new java.sql.Date( date.getTime() ); + + } + + +public static java.util.Date stringDateToJavaUtilitiesDate(String sDate) + { + java.sql.Date sqldate = stringDateToSqlDate(sDate); + return new java.util.Date(sqldate.getTime() ); + } +} diff --git a/Semester 2/Assignments/suppliers_parts_calendar/src/main/java/edu/slcc/asdv/bl/part/DatabaseManipulationPart.java b/Semester 2/Assignments/suppliers_parts_calendar/src/main/java/edu/slcc/asdv/bl/part/DatabaseManipulationPart.java new file mode 100644 index 0000000..f222e07 --- /dev/null +++ b/Semester 2/Assignments/suppliers_parts_calendar/src/main/java/edu/slcc/asdv/bl/part/DatabaseManipulationPart.java @@ -0,0 +1,104 @@ +/* + * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license + * Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template + */ +package edu.slcc.asdv.bl.part; + +import edu.slcc.asdv.bl.DBase; +import edu.slcc.asdv.bl.UtilitiesDatabase; +import java.sql.Connection; +import java.sql.PreparedStatement; +import java.sql.ResultSet; +import java.sql.SQLException; +import java.util.ArrayList; +import java.util.List; + +/** + * + * @author asdv5 + */ +public class DatabaseManipulationPart implements DBase +{ + @Override + public List listAll() + { + List tableParts = new ArrayList(); + String databaseName = "suppliers_parts_23"; + String userName = "java"; + String password = "8VCS49HT2xjsEZvC"; + String URL2 = "com.mysql.jdbc.Driver"; + Connection con = new UtilitiesDatabase().connection( + databaseName, userName, password, URL2); + PreparedStatement ps = null; + try + { + if (con == null) + { + throw new RuntimeException("cannot connect to database"); + } + String table = ""; + ResultSet rs = null; + String sqlStr = "SELECT * FROM part"; + //prepare statement + ps = con.prepareStatement(sqlStr); + //execute + rs = ps.executeQuery(); + int row = 0; + while (rs.next()) + { + String pNumber = rs.getString(1); + String pName = rs.getString(2); + String color = rs.getString(3) + " "; + String city = rs.getString(4) + " "; + Part part = new Part(pNumber, pName, color, city); + tableParts.add(part); + row++; + } + } + catch (Exception ex) + { + ex.printStackTrace(); + } + finally + { + try + { + new UtilitiesDatabase().closeDatabaseConnection(con); + // close the resources + if (ps != null) + { + ps.close(); + } + } + catch (SQLException sqle) + { + sqle.printStackTrace(); + } + } + return tableParts; + } + + public static void main(String[] args) + { + DatabaseManipulationPart dmp = new DatabaseManipulationPart(); + System.out.println(dmp.listAll()); + } + + @Override + public int update(Part t) + { + throw new UnsupportedOperationException("Not supported yet."); // Generated from nbfs://nbhost/SystemFileSystem/Templates/Classes/Code/GeneratedMethodBody + } + + @Override + public int delete(Part t) throws SQLException + { + throw new UnsupportedOperationException("Not supported yet."); // Generated from nbfs://nbhost/SystemFileSystem/Templates/Classes/Code/GeneratedMethodBody + } + + @Override + public int insert(Part t) throws SQLException + { + throw new UnsupportedOperationException("Not supported yet."); // Generated from nbfs://nbhost/SystemFileSystem/Templates/Classes/Code/GeneratedMethodBody + } +} diff --git a/Semester 2/Assignments/suppliers_parts_calendar/src/main/java/edu/slcc/asdv/bl/part/Part.java b/Semester 2/Assignments/suppliers_parts_calendar/src/main/java/edu/slcc/asdv/bl/part/Part.java new file mode 100644 index 0000000..54bd19a --- /dev/null +++ b/Semester 2/Assignments/suppliers_parts_calendar/src/main/java/edu/slcc/asdv/bl/part/Part.java @@ -0,0 +1,75 @@ +/* + * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license + * Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template + */ +package edu.slcc.asdv.bl.part; + +/** + * + * @author asdv5 + */ +public class Part +{ + private String pnumber; + private String pname; + private String color; + private String city; + + public Part(String pnumber, String pname, String color, String city) + { + this.pnumber = pnumber; + this.pname = pname; + this.color = color; + this.city = city; + } + + + public String getColor() + { + return color; + } + + public void setColor(String color) + { + this.color = color; + } + + public String getCity() + { + return city; + } + + public void setCity(String city) + { + this.city = city; + } + + public String getPname() + { + return pname; + } + + public void setPname(String pname) + { + this.pname = pname; + } + + public String getPnumber() + { + return pnumber; + } + + public void setPnumber(String pnumber) + { + this.pnumber = pnumber; + } + + @Override + public String toString() + { + return "Part{" + "pnumber=" + pnumber + ", pname=" + pname + ", color=" + color + ", city=" + city + '}'; + } + + + +} diff --git a/Semester 2/Assignments/suppliers_parts_calendar/src/main/java/edu/slcc/asdv/bl/supplier/DatabaseManipulationSupplier.java b/Semester 2/Assignments/suppliers_parts_calendar/src/main/java/edu/slcc/asdv/bl/supplier/DatabaseManipulationSupplier.java new file mode 100644 index 0000000..6c69079 --- /dev/null +++ b/Semester 2/Assignments/suppliers_parts_calendar/src/main/java/edu/slcc/asdv/bl/supplier/DatabaseManipulationSupplier.java @@ -0,0 +1,258 @@ +/* + * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license + * Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template + */ +package edu.slcc.asdv.bl.supplier; + +import edu.slcc.asdv.bl.DBase; +import edu.slcc.asdv.bl.UtilitiesDatabase; +import java.sql.Connection; +import java.sql.ParameterMetaData; +import java.sql.PreparedStatement; +import java.sql.ResultSet; +import java.sql.SQLException; +import java.util.ArrayList; +import java.util.List; + +/** + * + * @author asdv5 + */ +public class DatabaseManipulationSupplier implements DBase +{ + @Override + public List listAll() + throws SQLException + { + // test exception code + //if ( true) + // throw new SQLException(); + + List tableSuppliers = new ArrayList(); + String databaseName = "suppliers_parts_23"; + String userName = "java"; + String password = "8VCS49HT2xjsEZvC"; + String URL2 = "com.mysql.jdbc.Driver"; + Connection con = new UtilitiesDatabase().connection( + databaseName, userName, password, URL2); + PreparedStatement ps = null; + try + { + if (con == null) + { + throw new RuntimeException("cannot connect to database"); + } + String table = ""; + ResultSet rs = null; + String sqlStr = "SELECT * FROM supplier"; + //prepare statement + ps = con.prepareStatement(sqlStr); + //execute + rs = ps.executeQuery(); + int row = 0; + while (rs.next()) + { + String sNumber = rs.getString(1); + String sName = rs.getString(2); + String bdate = rs.getDate(3) + " "; + int status = rs.getInt(4); + String city = rs.getString(5) + " "; + Supplier supplier = new Supplier(sNumber, sName, bdate, status, city); + tableSuppliers.add(supplier); + row++; + } + } + catch (SQLException ex) + { + ex.printStackTrace(); + } + finally + { + try + { + new UtilitiesDatabase().closeDatabaseConnection(con); + // close the resources + if (ps != null) + { + ps.close(); + } + } + catch (SQLException sqle) + { + System.out.println(sqle); + sqle.printStackTrace(); + throw sqle; + } + } + return tableSuppliers; + } + + @Override + public int update(Supplier t) + throws SQLException + { + String databaseName = "suppliers_parts_23"; + String userName = "java"; + String password = "8VCS49HT2xjsEZvC"; + String URL2 = "com.mysql.jdbc.Driver"; + Connection con = new UtilitiesDatabase().connection( + databaseName, userName, password, URL2); + int result = 0; + PreparedStatement updateSupplier = null; + try + { + if (con == null) + { + throw new RuntimeException("cannot connect to database"); + } + + + updateSupplier = con.prepareStatement( + "UPDATE supplier SET snumber=?, sname=?, status=?, birthday=?, city=? WHERE snumber=?"); + updateSupplier.setString(1, t.getSnumber()); + updateSupplier.setString(2, t.getSname()); + updateSupplier.setInt(3, t.getStatus()); + java.sql.Date bd = UtilitiesDatabase.stringDateToSqlDate(t.getBirthday()); + updateSupplier.setDate(4, bd); + updateSupplier.setString(5, t.getCity()); + updateSupplier.setString(6, t.getSnumber()); + result = updateSupplier.executeUpdate(); + } + catch (SQLException ex) + { + System.err.println(ex.toString()); + throw ex; + } + finally + { + try + { + new UtilitiesDatabase().closeDatabaseConnection(con); + // close the resources + if (updateSupplier != null) + { + updateSupplier.close(); + } + } + catch (SQLException sqle) + { + sqle.printStackTrace(); + throw sqle; + } + } + return result; + } + + @Override + public int delete(Supplier t) throws SQLException + { + String databaseName = "suppliers_parts_23"; + String userName = "java"; + String password = "8VCS49HT2xjsEZvC"; + String URL2 = "com.mysql.jdbc.Driver"; + Connection con = new UtilitiesDatabase().connection( + databaseName, userName, password, URL2); + int result = 0; + /* + + Connection con = connection(); + if (con == null) + { + result = "cannot connect to database" ; + return ; + } + PreparedStatement ps = null; + int rowsAffected = -1; + + try + { + String query = "DELETE FROM supplier WHERE snumber=? "; + ps = con.prepareStatement(query); + ps.setString(1, snumber); + rowsAffected = ps.executeUpdate(); + result = "number of rows affected: " + rowsAffected; + } + catch (Exception ex) + { + System.err.println(ex.toString()); + } + finally + { + try + { + this.closeDatabaseConnection(con); + // close the resources + if (ps != null) + { + ps.close(); + } + + } + catch (SQLException sqlee) + { + sqlee.printStackTrace(); + } + } + + + */ + return 0; + + } + + @Override + public int insert(Supplier t) throws SQLException + { + String databaseName = "suppliers_parts_23"; + String userName = "java"; + String password = "8VCS49HT2xjsEZvC"; + String URL2 = "com.mysql.jdbc.Driver"; + Connection con = new UtilitiesDatabase().connection( + databaseName, userName, password, URL2); + int result = 0; + PreparedStatement updateSupplier = null; + try + { + if (con == null) + { + throw new RuntimeException("cannot connect to database"); + } + + + updateSupplier = con.prepareStatement( + "insert into supplier (snumber, sname, status, birthday, city) VALUES (?, ?, ?, ?, ?)"); + updateSupplier.setString(1, t.getSnumber()); + updateSupplier.setString(2, t.getSname()); + updateSupplier.setInt(3, t.getStatus()); + java.sql.Date bd = UtilitiesDatabase.stringDateToSqlDate(t.getBirthday()); + updateSupplier.setDate(4, bd); + updateSupplier.setString(5, t.getCity()); + result = updateSupplier.executeUpdate(); + } + catch (SQLException ex) + { + System.err.println(ex.toString()); + throw ex; + } + finally + { + try + { + new UtilitiesDatabase().closeDatabaseConnection(con); + // close the resources + if (updateSupplier != null) + { + updateSupplier.close(); + } + } + catch (SQLException sqle) + { + sqle.printStackTrace(); + throw sqle; + } + } + return result; + } + + +} diff --git a/Semester 2/Assignments/suppliers_parts_calendar/src/main/java/edu/slcc/asdv/bl/supplier/Supplier.java b/Semester 2/Assignments/suppliers_parts_calendar/src/main/java/edu/slcc/asdv/bl/supplier/Supplier.java new file mode 100644 index 0000000..5edca8d --- /dev/null +++ b/Semester 2/Assignments/suppliers_parts_calendar/src/main/java/edu/slcc/asdv/bl/supplier/Supplier.java @@ -0,0 +1,151 @@ +/* + * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license + * Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template + */ +package edu.slcc.asdv.bl.supplier; + +import edu.slcc.asdv.bl.UtilitiesDatabase; +import java.io.Serializable; +import java.util.Date; + +/** + * + * @author asdv5 + */ +public class Supplier implements Serializable +{ + private String snumber; + private String sname; + private String birthday; + private int status; + private String city; + private Date birthday_date; + private boolean isInsertNew; + + public boolean isIsInsertNew() + { + return isInsertNew; + } + + public void setIsInsertNew(boolean isInsertNew) + { + this.isInsertNew = isInsertNew; + } + + private boolean modify; + + public boolean isModify() + { + return modify; + } + + public void setModify(boolean modify) + { + this.modify = modify; + } + +public Supplier() { + this.birthday = "0000-00-00"; + this.isInsertNew = true; + this.modify = true; +} + + public Supplier(String snumber, String sname, String birthday, int status, String city) + { + this.snumber = snumber; + this.sname = sname; + this.birthday = birthday; + this.status = status; + this.city = city; + this.modify = false; + this.isInsertNew = false; + } + + public String getCity() + { + return city; + } + + public void setCity(String city) + { + this.city = city; + } + + + public int getStatus() + { + return status; + } + + public void setStatus(int status) + { + this.status = status; + } + + + + + public String getBirthday() + { + return birthday; + } + + public void setBirthday(String birthday) + { + this.birthday = birthday; + + } + + public Date getBirthday_date() + { + birthday_date = UtilitiesDatabase.stringDateToJavaUtilitiesDate(this.birthday); + return birthday_date; + } + + public void setBirthday_date(Date birthday_date) + { + this.birthday_date = birthday_date; + int year = this.birthday_date.getYear() + 1900; + int month = this.birthday_date.getMonth()+1; + int day = this.birthday_date.getDate(); + + + this.birthday = Integer.toString(year) + "-" + + Integer.toString(month)+ "-" + + Integer.toString(day); + + } + + + public String getSname() + { + return sname; + } + + public void setSname(String sname) + { + System.out.println( sname); + this.sname = sname; + } + + + public String getSnumber() + { + + return snumber; + } + + public void setSnumber(String snumber) + { + this.snumber = snumber; + } + + @Override + public String toString() + { + return "Supplier{" + "snumber=" + snumber + ", sname=" + sname + ", birthday=" + birthday + ", status=" + status + ", city=" + city + '}'; + } + + + +} diff --git a/Semester 2/Assignments/suppliers_parts_calendar/src/main/resources/META-INF/persistence.xml b/Semester 2/Assignments/suppliers_parts_calendar/src/main/resources/META-INF/persistence.xml new file mode 100644 index 0000000..baad290 --- /dev/null +++ b/Semester 2/Assignments/suppliers_parts_calendar/src/main/resources/META-INF/persistence.xml @@ -0,0 +1,7 @@ + + + + + + + diff --git a/Semester 2/Assignments/suppliers_parts_calendar/src/main/webapp/WEB-INF/beans.xml b/Semester 2/Assignments/suppliers_parts_calendar/src/main/webapp/WEB-INF/beans.xml new file mode 100644 index 0000000..b3a1279 --- /dev/null +++ b/Semester 2/Assignments/suppliers_parts_calendar/src/main/webapp/WEB-INF/beans.xml @@ -0,0 +1,6 @@ + + + \ No newline at end of file diff --git a/Semester 2/Assignments/suppliers_parts_calendar/src/main/webapp/WEB-INF/glassfish-web.xml b/Semester 2/Assignments/suppliers_parts_calendar/src/main/webapp/WEB-INF/glassfish-web.xml new file mode 100644 index 0000000..584a477 --- /dev/null +++ b/Semester 2/Assignments/suppliers_parts_calendar/src/main/webapp/WEB-INF/glassfish-web.xml @@ -0,0 +1,25 @@ + + + + + + + + Keep a copy of the generated servlet class' java code. + + + diff --git a/Semester 2/Assignments/suppliers_parts_calendar/src/main/webapp/WEB-INF/web.xml b/Semester 2/Assignments/suppliers_parts_calendar/src/main/webapp/WEB-INF/web.xml new file mode 100644 index 0000000..11562f0 --- /dev/null +++ b/Semester 2/Assignments/suppliers_parts_calendar/src/main/webapp/WEB-INF/web.xml @@ -0,0 +1,24 @@ + + + + jakarta.faces.PROJECT_STAGE + Development + + + Faces Servlet + jakarta.faces.webapp.FacesServlet + 1 + + + Faces Servlet + /faces/* + + + + 30 + + + + faces/supplier.xhtml + + diff --git a/Semester 2/Assignments/suppliers_parts_calendar/src/main/webapp/index.xhtml b/Semester 2/Assignments/suppliers_parts_calendar/src/main/webapp/index.xhtml new file mode 100644 index 0000000..3220605 --- /dev/null +++ b/Semester 2/Assignments/suppliers_parts_calendar/src/main/webapp/index.xhtml @@ -0,0 +1,51 @@ + + + + + + Supplier Parts DB + + + + +

Suppliers-Parts Database

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ \ No newline at end of file diff --git a/Semester 2/Assignments/suppliers_parts_calendar/src/main/webapp/resources/css/styles.css b/Semester 2/Assignments/suppliers_parts_calendar/src/main/webapp/resources/css/styles.css new file mode 100644 index 0000000..9d96af6 --- /dev/null +++ b/Semester 2/Assignments/suppliers_parts_calendar/src/main/webapp/resources/css/styles.css @@ -0,0 +1,71 @@ +.body { + background: #eee; +} + +.button { + margin: 10px; + border-left: thin solid darkGray; + border-bottom: thin solid darkGray; + border-top: thin solid lightGray; + border-right: thin solid lightGray; + color: #777; + background: #A7C942; + font-family: "Comic Sans MS"; + border-radius: 20%; +} +h1 +{ + vertical-align: top; + text-align: middle; + font-style: italic; + color: #888; + font-size: 2em; + font-family: "Comic Sans MS"; + +} + +.label +{ + color: #888; + font-size: 0.8em; + font-family: "Comic Sans MS"; +} +.leftImage { + float: left; + margin-right: 1em; +} + +.backLink { + font-style: italic; +} + + +.tableHeader { + font-family:"Trebuchet MS", Arial, Helvetica, sans-serif; + border-collapse:collapse; + font-size:1.1em; + text-align:left; + padding-top:5px; + padding-bottom:4px; + background-color:#A7C942; + color:white; + border:1px solid #98bf21; +} + +.oddTableRow { + border:1px solid #98bf21; +} + +.evenTableRow { + background-color: #eeeeee; + font-size:1em; + + padding:3px 7px 2px 7px; + + color:#000000; + background-color:#EAF2D3; +} + +.table { + border:1px solid green; +} \ No newline at end of file diff --git a/Semester 2/Assignments/suppliers_parts_calendar/src/main/webapp/supplier.xhtml b/Semester 2/Assignments/suppliers_parts_calendar/src/main/webapp/supplier.xhtml new file mode 100644 index 0000000..88c99b4 --- /dev/null +++ b/Semester 2/Assignments/suppliers_parts_calendar/src/main/webapp/supplier.xhtml @@ -0,0 +1,75 @@ + + + + + Suppliers Table + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Semester 2/SupplierPartsCalendar.zip b/Semester 2/SupplierPartsCalendar.zip new file mode 100644 index 0000000000000000000000000000000000000000..e9c386a0ddc387fcb27478c251141492eca18a05 GIT binary patch literal 19990 zcmcIsWmMK%v!}bHy9Mc#2I=nZ?(PNwL8OuHkOt}QmQql^*yCPwW|`#ehMe001BW0O-XGl>ojY)Vtqu4%XJ@CI+_BI=1$9d^+X^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