From 98f48f99876e325e23015968f7c77858918cf186 Mon Sep 17 00:00:00 2001 From: "Javier A. Ortiz Bultron" Date: Tue, 13 Jun 2017 17:01:59 -0500 Subject: [PATCH] Release version 0.3.3 (#57) * Change version to 0.4.1-SNAPSHOT. * Change version to 0.4.1-SNAPSHOT. Task #3 - Implement Trace Matrix * Use right version. * Copy over all fields when increasing the minor version. Task #29 - Baselining an item with major version > 0 resets to 0 * Add toString method with normal username and last name properly formatted. * Update from database. * prevent unnecessary versions while baselining. Task #30 - Baselining: Don't change the revision of an item not modified since last baseline * Fix various test issues along with bug (ommission) in code. Task #31 - Adding Test Case for execution didn't include Step text * Fix other bugs * Set size if there's something to show. * Fix issue where some Id's were not unique making them not show everywhere they needed to be. Task #32 - Trace Matrix: Test Cases don't show for all applicable Requirements * Removing dependence not used at this point. * Finish Trace Matrix implementation. Task #3 - Implement Trace Matrix * Implement internationalization. Task #5 - Allow full internationalization * Fix some issues in translations. * Add some locales. * Update VMMessages_es.properties (POEditor.com) * Implement date format setting. (#35) Task #11 - Add setting for date format * Add javadoc. * Implement internationalization. Task #5 - Allow full internationalization * Fix typo. * Add profile tab. Task #5 - Allow full internationalization * Fix missing translations. * Remove unused classes. * Translate component. * Add notification system. * More work in progress. Task #12 - Implement Notification system * Basic functionality of the Notification manager. Task #12 - Implement Notification system * Formatting. * Use right notification type. * Add item ID. * Use right split. * Update VMMessages_es.properties (POEditor.com) * Implemented translation interface. Task #38 - Provide interface to add translations from possible plug ins. * Add versioning to the menu. * Move classes that are not API classes to a different package. * Change hierarchy. * Move out of API folder. * Remove unused classes. * Use correct file package. * Replace add on for Vaadin provided one. * Add archieved field to notifications. * WIP Task #12 - Implement Notification system * Add sorting capabilities to notification grid. Task #12 - Implement Notification system * Update VMMessages_es.properties (POEditor.com) * Address Javadoc warnings. * Apply licensing. * Getting ready to release to GitHub. * Fix bug. * [maven-release-plugin] rollback the release of Validation-Manager-0.3.1 * Remove file. * Update submodule branch. * Release 0.3.1. * Add Wizards submodule. * Add missing Break. * Add missing translations. * Change version to 0.3.2-SNAPSHOT for development. * Change version to 0.3.2-SNAPSHOT for development. Task #44 - Main tab doesn't show on UI * Release Hot Fix 0.3.2. * Fix issue. Task #46 - Notifications Tab not translating when changing locale. * Change to development version. * Add mail related settings. * Implement engine and settings along with related unit tests. Task #42 - Support Sending email Task #42 - Support Sending email * Integrate with UI. Task #42 - Support Sending email * Fix NPE issue. * When running update() on the server class, it adds the initial history to the server but never persists to the database. So we update it when we are creating the record instead. Task #50 - History not correctly created if updating from EntityServer * 1) Make User versionable. 2) Add test to server class. 3) Fix multiple bugs uncovered during testing. Task #50 - History not correctly created if updating from EntityServer * Fix Cobertura issue. Task #52 - Code Coverage not working * Fix Cobertura issue. Task #52 - Code Coverage not working * Add missing test. * Revert last change that broke it. Task #52 - Code Coverage not working * Lots of unit tests and bug fixes identified during testing. * Fix javadoc errors. * Handle null passwords (i.e. user creation) * Implement adding users. Task #43 - Add user management * Implement User Management. Task #43 - Add user management * Add tests to check failed login attempts and account locking. * Fix various test failures. * Reorganize code to address possible NPE. * Fix extra comma on the toString method. * 1) Fix POM to avoid testing twice. 2) Add action for a Cobertura test run. * 1) Add a test to check all versionable classes. 2) Add missing Auditable fields in Project. * Test all fields of the Versionable entities. * Fixing test cases and bugs. * Fix auto incrementing notification ids. Task #55 - Notification not autoincrementing. * Only show the component to update roles to admin users. * Use correct Exception type. * Translate Demo screen. Task #49 - Demo tab not internationalized * WIP to fix bug. * Lower logging level for this message. * Add missing field. * Fix bug with modifier user. * Some more work to translate Demo tab after switching language. Task #49 - Demo tab not internationalized * Minor refactoring/formatting. * Fix initial value to be greater than the default entries. * Implement Issue Type portion. Task #53 - Add Admin management for configurable items * Update VMMessages_es.properties (POEditor.com) * Update before saving just in case. * Implement Requirement Type and Issue Resolution portions. Task #53 - Add Admin management for configurable items * Update version preparing for release. * Address Codacy review observations. --- DB/Validation Master.mwb | Bin 194165 -> 193340 bytes DB/Validation Master.mwb.bak | Bin 194164 -> 193325 bytes VM-Core/nbactions.xml | 37 + VM-Core/pom.xml | 80 +- .../manager/core/ContentProvider.java | 79 +- .../manager/core/DataBaseManager.java | 1268 +++++------ .../validation/manager/core/DemoBuilder.java | 502 ++-- .../validation/manager/core/EntityServer.java | 88 +- .../manager/core/ImportException.java | 24 - .../manager/core/ImporterInterface.java | 74 +- .../manager/core/VMIdGenerator.java | 64 - .../validation/manager/core/VaadinUtils.java | 320 +-- .../core/adapter/TimestampAdapter.java | 45 - .../email/IEmailManager.java} | 45 +- .../InternationalizationProvider.java | 62 +- .../manager/core/db/AssigmentType.java | 256 +-- .../manager/core/db/AssignmentStatus.java | 262 +-- .../manager/core/db/Attachment.java | 314 +-- .../manager/core/db/AttachmentType.java | 241 +- .../validation/manager/core/db/Baseline.java | 346 +-- .../com/validation/manager/core/db/Cause.java | 274 +-- .../manager/core/db/CorrectiveAction.java | 268 +-- .../manager/core/db/ExecutionResult.java | 237 +- .../manager/core/db/ExecutionStep.java | 724 +++--- .../manager/core/db/FailureMode.java | 274 +-- .../com/validation/manager/core/db/Fmea.java | 338 +-- .../validation/manager/core/db/Hazard.java | 276 +-- .../validation/manager/core/db/History.java | 583 ++--- .../manager/core/db/HistoryField.java | 286 +-- .../manager/core/db/Investigation.java | 254 +-- .../com/validation/manager/core/db/Issue.java | 346 +-- .../manager/core/db/IssueResolution.java | 242 +- .../validation/manager/core/db/IssueType.java | 265 ++- .../manager/core/db/Notification.java | 358 +-- .../manager/core/db/NotificationPK.java | 169 +- .../validation/manager/core/db/Project.java | 379 ++-- .../manager/core/db/Requirement.java | 526 ++--- .../manager/core/db/RequirementSpec.java | 384 ++-- .../manager/core/db/RequirementSpecNode.java | 414 ++-- .../core/db/RequirementSpecNodePK.java | 244 +- .../manager/core/db/RequirementSpecPK.java | 204 +- .../manager/core/db/RequirementStatus.java | 230 +- .../manager/core/db/RequirementType.java | 302 +-- .../manager/core/db/RiskCategory.java | 314 +-- .../manager/core/db/RiskControlPK.java | 168 +- .../manager/core/db/RiskControlType.java | 262 +-- .../manager/core/db/RiskItemPK.java | 166 +- .../com/validation/manager/core/db/Role.java | 364 +-- .../validation/manager/core/db/RootCause.java | 300 +-- .../manager/core/db/RootCausePK.java | 170 +- .../manager/core/db/RootCauseType.java | 274 +-- .../validation/manager/core/db/SpecLevel.java | 264 +-- .../com/validation/manager/core/db/Step.java | 392 ++-- .../validation/manager/core/db/StepPK.java | 168 +- .../validation/manager/core/db/TestCase.java | 420 ++-- .../manager/core/db/TestCaseExecution.java | 284 +-- .../validation/manager/core/db/TestPlan.java | 418 ++-- .../manager/core/db/TestPlanPK.java | 170 +- .../manager/core/db/TestProject.java | 336 +-- .../manager/core/db/UserAssigmentPK.java | 246 +- .../validation/manager/core/db/UserRight.java | 252 +-- .../manager/core/db/UserStatus.java | 258 +-- .../validation/manager/core/db/VmSetting.java | 352 +-- .../validation/manager/core/db/VmUser.java | 848 +++---- .../AssigmentTypeJpaController.java | 412 ++-- .../AssignmentStatusJpaController.java | 412 ++-- .../controller/AttachmentJpaController.java | 496 ++-- .../AttachmentTypeJpaController.java | 426 ++-- .../db/controller/BaselineJpaController.java | 424 ++-- .../db/controller/CauseJpaController.java | 366 +-- .../CorrectiveActionJpaController.java | 492 ++-- .../ExecutionResultJpaController.java | 386 ++-- .../ExecutionStepHasIssueJpaController.java | 524 ++--- .../ExecutionStepJpaController.java | 1200 +++++----- .../controller/FailureModeJpaController.java | 366 +-- .../db/controller/FieldTypeJpaController.java | 412 ++-- .../core/db/controller/FmeaJpaController.java | 646 +++--- .../db/controller/HazardJpaController.java | 366 +-- .../db/controller/HistoryJpaController.java | 892 ++++---- .../InvestigationJpaController.java | 520 ++--- .../db/controller/IssueJpaController.java | 554 ++--- .../IssueResolutionJpaController.java | 412 ++-- .../db/controller/IssueTypeJpaController.java | 412 ++-- .../NotificationTypeJpaController.java | 412 ++-- .../db/controller/ProjectJpaController.java | 756 +++---- .../controller/RequirementJpaController.java | 920 ++++---- .../RequirementSpecJpaController.java | 666 +++--- .../RequirementSpecNodeJpaController.java | 658 +++--- .../RequirementStatusJpaController.java | 412 ++-- .../RequirementTypeJpaController.java | 412 ++-- .../controller/ReviewResultJpaController.java | 386 ++-- .../controller/RiskCategoryJpaController.java | 492 ++-- .../controller/RiskControlJpaController.java | 762 +++---- .../RiskControlTypeJpaController.java | 412 ++-- .../db/controller/RiskItemJpaController.java | 894 ++++---- .../core/db/controller/RoleJpaController.java | 788 +++---- .../db/controller/RootCauseJpaController.java | 576 ++--- .../RootCauseTypeJpaController.java | 412 ++-- .../db/controller/SpecLevelJpaController.java | 412 ++-- .../core/db/controller/StepJpaController.java | 684 +++--- .../TestCaseExecutionJpaController.java | 412 ++-- .../db/controller/TestCaseJpaController.java | 600 ++--- .../db/controller/TestPlanJpaController.java | 730 +++--- .../controller/TestProjectJpaController.java | 600 ++--- .../db/controller/UserRightJpaController.java | 366 +-- .../controller/UserStatusJpaController.java | 412 ++-- .../db/controller/VmSettingJpaController.java | 412 ++-- .../db/controller/VmUserJpaController.java | 2011 +++++++++-------- .../manager/core/history/Login.java | 57 - .../manager/core/history/Versionable.java | 788 ++++--- .../core/server/core/AttachmentServer.java | 246 +- .../server/core/AttachmentTypeServer.java | 143 +- .../server/core/ExecutionResultServer.java | 153 +- .../core/server/core/ExecutionStepServer.java | 342 +-- .../core/server/core/FieldTypeServer.java | 124 +- .../core/server/core/HistoryServer.java | 197 +- .../core/server/core/IssueTypeServer.java | 147 +- .../core/server/core/NotificationServer.java | 158 +- .../core/server/core/ProjectServer.java | 284 ++- .../server/core/RequirementStatusServer.java | 130 +- .../server/core/RequirementTypeServer.java | 148 +- .../core/server/core/ReviewResultServer.java | 143 +- .../core/server/core/RiskControlServer.java | 191 +- .../manager/core/server/core/RoleServer.java | 156 +- .../server/core/TestCaseExecutionServer.java | 424 ++-- .../core/server/core/TestCaseServer.java | 210 +- .../core/server/core/TestPlanServer.java | 265 +-- .../core/server/core/TestProjectServer.java | 188 +- .../server/core/UserTestPlanRoleServer.java | 164 +- .../core/UserTestProjectRoleServer.java | 195 +- .../core/server/core/VMUserServer.java | 1002 ++++---- .../manager/core/server/fmea/CauseServer.java | 136 +- .../manager/core/spi/email/EmailManager.java | 94 + .../DefaultInternationalizationProvider.java | 125 +- .../com/validation/manager/core/tool/MD5.java | 88 +- .../manager/resources/VMMessages.properties | 28 +- .../resources/VMMessages_es.properties | 28 +- .../resources/VMMessages_fr_FR.properties | 5 +- .../resources/VMMessages_zh_CN.properties | 5 +- .../db/migration/V1_4__New_Setings.sql | 14 + .../core/api/email/IEmailManagerTest.java | 79 + .../InternationalizationProviderTest.java | 65 + .../manager/core/db/ProjectTest.java | 225 +- .../core/db/RequirementHierarchyTest.java | 351 +-- .../validation/manager/core/db/UserTest.java | 109 +- .../manager/core/history/VersionableTest.java | 289 +++ .../server/core/AttachmentTypeServerTest.java | 52 + .../core/ExecutionResultServerTest.java | 63 + .../core/server/core/IssueTypeServerTest.java | 52 + .../server/core/NotificationServerTest.java | 108 +- .../core/server/core/ProjectServerTest.java | 247 +- .../server/core/RequirementServerTest.java | 699 +++--- .../core/RequirementStatusServerTest.java} | 58 +- .../core/RequirementTypeServerTest.java | 52 + .../server/core/ReviewResultServerTest.java | 51 + .../core/server/core/RoleServerTest.java | 50 + .../core/UserTestProjectRoleServerTest.java | 69 + .../core/server/core/VMUserServerTest.java | 264 +++ .../core/server/core/VersionListenerIT.java | 82 - .../manager/core/tool/ToolTest.java | 100 + .../table/extractor/TableExtractorTest.java | 165 +- .../core/tool/table/extractor/Tables.xlsm | Bin 0 -> 8873 bytes .../manager/test/AbstractVMTestCase.java | 394 ++-- .../validation/manager/test/TestHelper.java | 419 ++-- Validation-Manager-Web/pom.xml | 14 +- .../validation/manager/web/LoginDialog.java | 328 +-- .../manager/web/ValidationManagerUI.java | 14 +- .../web/admin/AdminScreenProvider.java | 712 ++++-- .../ByteToStringConverter.java | 102 +- .../component/IssueResolutionComponent.java | 127 ++ .../web/component/IssueTypeComponent.java | 124 + .../component/RequirementTypeComponent.java | 131 ++ .../web/component/TranslationConverter.java | 55 + .../{ => component}/TreeTableCheckBox.java | 174 +- .../manager/web/component/UserComponent.java | 302 +++ .../UserPasswordConverter.java | 90 +- .../web/component/UserStatusConverter.java | 67 + .../UserToStringConverter.java | 76 +- .../web/{provider => demo}/DemoProvider.java | 179 +- .../web/execution/ExecutionWizardStep.java | 1490 ++++++------ .../web/notification/NotificationManager.java | 96 +- .../NotificationScreenProvider.java | 29 +- .../manager/web/profile/ProfileProvider.java | 230 +- .../manager/web/tester/ExecutionScreen.java | 724 +++--- .../web/wizard/assign/AssignUserStep.java | 294 +-- .../manager/web/wizard/plan/DetailStep.java | 250 +- .../web/wizard/plan/SelectTestCasesStep.java | 390 ++-- pom.xml | 20 +- 188 files changed, 31050 insertions(+), 28814 deletions(-) delete mode 100644 VM-Core/src/main/java/com/validation/manager/core/ImportException.java delete mode 100755 VM-Core/src/main/java/com/validation/manager/core/VMIdGenerator.java delete mode 100644 VM-Core/src/main/java/com/validation/manager/core/adapter/TimestampAdapter.java rename VM-Core/src/main/java/com/validation/manager/core/{tool/step/importer/StepImportException.java => api/email/IEmailManager.java} (55%) delete mode 100644 VM-Core/src/main/java/com/validation/manager/core/history/Login.java create mode 100644 VM-Core/src/main/java/com/validation/manager/core/spi/email/EmailManager.java create mode 100644 VM-Core/src/main/resources/db/migration/V1_4__New_Setings.sql create mode 100644 VM-Core/src/test/java/com/validation/manager/core/api/email/IEmailManagerTest.java create mode 100644 VM-Core/src/test/java/com/validation/manager/core/api/internationalization/InternationalizationProviderTest.java create mode 100644 VM-Core/src/test/java/com/validation/manager/core/history/VersionableTest.java create mode 100644 VM-Core/src/test/java/com/validation/manager/core/server/core/AttachmentTypeServerTest.java create mode 100644 VM-Core/src/test/java/com/validation/manager/core/server/core/ExecutionResultServerTest.java create mode 100644 VM-Core/src/test/java/com/validation/manager/core/server/core/IssueTypeServerTest.java rename VM-Core/src/{main/java/com/validation/manager/core/tool/Timer.java => test/java/com/validation/manager/core/server/core/RequirementStatusServerTest.java} (50%) create mode 100644 VM-Core/src/test/java/com/validation/manager/core/server/core/RequirementTypeServerTest.java create mode 100644 VM-Core/src/test/java/com/validation/manager/core/server/core/ReviewResultServerTest.java create mode 100644 VM-Core/src/test/java/com/validation/manager/core/server/core/RoleServerTest.java create mode 100644 VM-Core/src/test/java/com/validation/manager/core/server/core/UserTestProjectRoleServerTest.java create mode 100644 VM-Core/src/test/java/com/validation/manager/core/server/core/VMUserServerTest.java delete mode 100644 VM-Core/src/test/java/com/validation/manager/core/server/core/VersionListenerIT.java create mode 100644 VM-Core/src/test/java/com/validation/manager/core/tool/ToolTest.java create mode 100644 VM-Core/src/test/java/com/validation/manager/core/tool/table/extractor/Tables.xlsm rename Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/{ => component}/ByteToStringConverter.java (93%) create mode 100644 Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/IssueResolutionComponent.java create mode 100644 Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/IssueTypeComponent.java create mode 100644 Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/RequirementTypeComponent.java create mode 100644 Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/TranslationConverter.java rename Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/{ => component}/TreeTableCheckBox.java (95%) create mode 100644 Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/UserComponent.java rename Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/{profile => component}/UserPasswordConverter.java (83%) create mode 100644 Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/UserStatusConverter.java rename Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/{ => component}/UserToStringConverter.java (92%) rename Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/{provider => demo}/DemoProvider.java (79%) diff --git a/DB/Validation Master.mwb b/DB/Validation Master.mwb index 333dd93e5fab4c0ca5ec86d2c0580fc394163e06..739c74ad7ff0e8e708da414ef7c7d5793a26c8f9 100644 GIT binary patch literal 193340 zcmagFV{j&K^er0O$;7s8+vda*P58#PZQJI=wkFABq6y#FHYR#=Gr#k{=bjIz>VDbX z)z9vyySlnI)>>Ot0TK!e3=9koEH!9UUZ%MG^~VLlK*xv`SB9)0eV?X+2Y2@s5r9x0HwY0 z+$?^)Pk%fZ8|NG32|gd}o<7eU;WVh!gWeey{jc{Ao@3e@cr0~h8bA-<@2-sfUK>b0 z#sdOwMP^w1->qF9cS%(GgaSIf9u_YKueYvi96${;Dxfn5nubmL{PnlBXO)kw!_h?@ z73K!!&AyJ{=9J}&oR2rN)PSk0kDod!%Eq8qovS8l2Lmp&FMOg}2&#!F(bBGS0y<_d zA^|9$`{&^F8}<3UUl~Vj<^8#>DCq6?58lY%S$t-xU{N-D2fpgKzLWCP6Qs0@4*3kA zK_teYBc&Cy%gOCu`6m{r(G?ly3>fo#ygW5*qWW_@PB*_lyUuJG7z#S{-+=<6lVzR$ zPUnpKyLqn?zl=VwYUPmr{af~Sv%$ndSCIea>~#C`-rUpke0p2cZ|8+p8<`IBP0Xkm zF6bfN9R*I++%0!P|5_5OH&)65*%+Z}JUVRU8@zROdVVY$8waqRKBu902z@-~)L_>Y zBskuYwDkvgKTf@VxOzr6^gTBObb?SpZ!^Yu`S0GwU*E?^7d@`}1MXlyyq1VRa-5Rh zjX&6tK7@lEK6ZS{dH+&D9Co+G2MBDu-MywXn;@?XzFb_r^I1Ig0!^c2yzUYL3^$Du zmS=9qc^djXo)`13Hq$LYCmlRzg1l*|f3{aHZNY2gejix$T6n%dfcY)VED(;&8(vHQf&rhZuJe^nHm~Q8 z)dk7a-TM!c{F6Q&M#NlD`1`Xu==GW9;ePQ@g!%VY-}8@?_vbo&Tfo$UZ0o?n+sgN& zhl$stjv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w6gis}(!(aK+ny_2LKFF{RuVeaViO3{ zmvbmP7JIXpmbZAXx%)S*Dpx;wZhulHM-WB`U1weHqllJw?YTrN(1nrJ-C#r)r-9Z@ z=wJ?Rs=^{UH&K|!73ol3+oGNQH z8zdw9!DWkFn>dp<4TXcyQWk(_?;9B+u`J~ho1v7NLNxdrIzl1|=KTT4E0U*1<)(5V zE9+nOS+0EXf4>vT`%G)EsN&T!mYM&dOxpj~L)A~loRby<3v0b`b0umYH&NVg5^CDE zS!zqqKU*$$AJiY;{j6xiao_t;EI+$73+OJXqT*y&e}Psr{nMKv#6~heAE-bcqj;lT zs$A!W1B+-wV&dV%u1g_Z94Rx>y~KcbCz^$k!*PzYRoxDtSb*lkebQ~AMUh3AgI}8!B`^Cihn(uU zX_a{Kc+;b9D(zwYn4kIWnoqKZMs+2sOk5b1ommr~1|?mho{x63_@z2sWv21Gz$2UO zEc0dZCTm|%F*oUI!!Q|=x4%fUFgObsnRZ@|ihq)9nbGtU$%19_Ga8M_vP(CizlybR ziQA@XN@M2UXUWj}w6qS23Qtgt9>^}7B&4}hP1Q@v{Hv~tyZM|3y4lZApiOxQ;j^@iBKeFveccv@tPbFTA zHEkg74=~hV)$$1cs(ebUuYS)^FsdAHFE|D$E`lt>NReT`( zteh$-*N$a(wP=c{#mySnQ*%#pk^U_&Ruyx`Ge`?{nZ<#gFqb!%YBTJoJ!eU7!-GNT z#}-XO#rtMDf_FC>4g+7`@2+D(Gkhln+K%IYp-|AsNRPcn*M

+dMrkWhEI^Pvew(KPr#D~-MYMwwG3$4p z>f_!#NBv5>xQB%u=&2tsj(z`kWoF`8hBP@e2~V k-JRisfuRm=wlHaCKU-HPjI6ekhr6|#t-CG6!JF{^0M&k`DF6Tf diff --git a/DB/Validation Master.mwb.bak b/DB/Validation Master.mwb.bak index 53d7d31ba311c742582c64feeb1cc560c833db94..fbe3498399e145ab53c43e22691cb51959b293a2 100644 GIT binary patch literal 193325 zcmagFWl&sQ)HR5^OK=PB65QQ`yS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NY@l(+ zNGPfdZ#N`{TS637ipN!rJ$1~_pC(d<^D9~`536Wj?nxO{Vvaq_&Pw4VQM0=ZcX#z2 zsRjDCd{~vt=}(}|)TNgD`XXFDTxw15pAMYGIraAjWFA^J3Y)}wP>Eqh5eU=!b2YEn z%O^ZAD4_y3)`*Nu5(dMA_%&#}0w`LOt{d>WNH8ukiy1y}x}N{wV;>O!@)h`#d?P=4 zoFVtCfa#euF8jL_Rs69pq&YCxLzU zf^8{~Xepj~R7d}Hs2Krx&q_$LCKG1ax9j{!Ww94hQ+-xZUV3UZWcMMXUsP?$twBxn zLwZ0J-mz{Ed^_9+c2G#rNaJUSGicl>%V)Ulpj25g1zZCL+SoXhxVJLYSXdkw8R{Xk zu^T*0`u26__T>M4v_{+}+&m$!|C{43mLw(zxQl}2H4+CajDQX6{{MU(b8L;^#JoFr zLj2qvJ$wb+1MCF?-QE7*-2Xq>>;EaBHR3y_%>PFO+dvx+|Mo*%%(Dt}^!|l|rGlj! z^wdy?+04_&)!xwq0%O+obZ~TIw)26&oc$e{g$0BN-EYtE!yzz7cRRQYv%j62Ge%b1 R+0(gYrGe*hkZsFVNz diff --git a/VM-Core/nbactions.xml b/VM-Core/nbactions.xml index 98e195af..d27d733c 100644 --- a/VM-Core/nbactions.xml +++ b/VM-Core/nbactions.xml @@ -43,4 +43,41 @@ java + + test + + * + + + test + + + true + + + + test.single + + * + + + test-compile + surefire:test + + + ${packageClassName} + true + + + + CUSTOM-Coverage Report + Coverage Report + + verify + + + true + false + + diff --git a/VM-Core/pom.xml b/VM-Core/pom.xml index ee661c95..04419742 100644 --- a/VM-Core/pom.xml +++ b/VM-Core/pom.xml @@ -4,7 +4,7 @@ net.sourceforge.javydreamercsw Validation-Manager - 0.3.2 + 0.3.3 VM-Core @@ -141,6 +141,25 @@ jacoco-maven-plugin test + + + javax.mail + javax.mail-api + 1.5.6 + + + com.sun.mail + javax.mail + 1.5.6 + + + + de.saly + javamail-mock2-fullmock + 0.5-beta4 + test + + @@ -158,52 +177,53 @@ + + maven-surefire-plugin + + ${cobertura.test} + + + + unit-test + test + + test + + + ${maven.test.skip} + ${argLine} + + **/*IT.java + + + + + org.jacoco jacoco-maven-plugin 0.7.9 + + ${skipTests} + file + true + - - pre-unit-test + jacoco-initialize prepare-agent - - - jacocoArgLine - - - post-unit-test - test + jacoco-site + verify report - - org.apache.maven.plugins - maven-surefire-report-plugin - 2.20 - - - - ${jacocoArgLine} - - diff --git a/VM-Core/src/main/java/com/validation/manager/core/ContentProvider.java b/VM-Core/src/main/java/com/validation/manager/core/ContentProvider.java index e3a5d1e2..d3d2dae9 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/ContentProvider.java +++ b/VM-Core/src/main/java/com/validation/manager/core/ContentProvider.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,39 +13,44 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core; - -import com.vaadin.ui.Component; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public interface ContentProvider { - - /** - * Return the component caption. This will be attempted to be translated. - * - * @return component caption - */ - String getComponentCaption(); - - /** - * The Content of the provider - * - * @return content. - */ - Component getContent(); - - /** - * This is the unique id of the provider - * - * @return unique id for the provider. - */ - String getId(); - - /** - * Refresh the contents. - */ - void update(); -} +package com.validation.manager.core; + +import com.vaadin.ui.Component; +import com.validation.manager.core.api.internationalization.InternationalizationProvider; +import org.openide.util.Lookup; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public interface ContentProvider { + + static final InternationalizationProvider TRANSLATOR + = Lookup.getDefault().lookup(InternationalizationProvider.class); + + /** + * Return the component caption. This will be attempted to be translated. + * + * @return component caption + */ + String getComponentCaption(); + + /** + * The Content of the provider + * + * @return content. + */ + Component getContent(); + + /** + * This is the unique id of the provider + * + * @return unique id for the provider. + */ + String getId(); + + /** + * Refresh the contents. + */ + void update(); +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/DataBaseManager.java b/VM-Core/src/main/java/com/validation/manager/core/DataBaseManager.java index e1ac70bb..fdd87224 100755 --- a/VM-Core/src/main/java/com/validation/manager/core/DataBaseManager.java +++ b/VM-Core/src/main/java/com/validation/manager/core/DataBaseManager.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,636 +13,636 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core; - -import com.googlecode.flyway.core.Flyway; -import com.googlecode.flyway.core.api.FlywayException; -import com.googlecode.flyway.core.api.MigrationInfo; -import com.googlecode.flyway.core.api.MigrationState; -import com.validation.manager.core.db.controller.VmIdJpaController; -import com.validation.manager.core.server.core.VMIdServer; -import com.validation.manager.core.server.core.VMSettingServer; -import static java.lang.Class.forName; -import static java.lang.Integer.parseInt; -import static java.lang.Long.valueOf; -import static java.lang.Thread.sleep; -import java.lang.reflect.Field; -import java.sql.Connection; -import java.sql.PreparedStatement; -import java.sql.ResultSet; -import java.sql.SQLException; -import java.util.HashMap; -import java.util.Iterator; -import java.util.List; -import java.util.Map; -import java.util.Map.Entry; -import java.util.StringTokenizer; -import java.util.concurrent.TimeUnit; -import java.util.logging.Level; -import java.util.logging.Logger; -import static java.util.logging.Logger.getLogger; -import javax.naming.InitialContext; -import javax.naming.NamingException; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; -import javax.persistence.EntityTransaction; -import static javax.persistence.Persistence.createEntityManagerFactory; -import javax.persistence.Query; -import javax.persistence.TableGenerator; -import javax.sql.DataSource; -import org.h2.jdbcx.JdbcDataSource; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class DataBaseManager { - - private static EntityManagerFactory emf; - private static Map properties; - //Default. Can be overwritten using setPersistenceUnitName(String aPU) - private static String PU = "VMPU"; - private static EntityManager em; - private static boolean dbError = false; - private static final Logger LOG - = getLogger(DataBaseManager.class.getSimpleName()); - private static DBState state = DBState.START_UP; - private static boolean locked = false; - private static boolean usingContext; - private static boolean demo; - private static Long demoResetPeriod; - private static DataBaseManager instance; - private static boolean versioning_enabled = true; - - /** - * @return the versioning enabled - */ - public static boolean isVersioningEnabled() { - return versioning_enabled; - } - - /** - * @param aVersioning_enabled the versioning_enabled to set - */ - public static void setVersioningEnabled(boolean aVersioning_enabled) { - versioning_enabled = aVersioning_enabled; - } - - /** - * @return the demoResetPeriod - */ - public static Long getDemoResetPeriod() { - return demoResetPeriod; - } - - private DataBaseManager() { - } - - public static DataBaseManager get() throws Exception { - if (instance == null) { - instance = new DataBaseManager(); - } - return instance; - } - - @SuppressWarnings("unchecked") - private static void processFields(Field[] fields) { - try { - for (Field field : fields) { - if (field.isAnnotationPresent(TableGenerator.class)) { - field.setAccessible(true); - TableGenerator annotation = field.getAnnotation(TableGenerator.class); - field.setAccessible(false); - Map parameters = new HashMap<>(); - String tableName = annotation.pkColumnValue(); - parameters.put("tableName", tableName); - if (namedQuery("VmId.findByTableName", parameters, false).isEmpty()) { - LOG.log(Level.FINE, "Adding: {0}: {1}", - new Object[]{tableName, annotation.initialValue() - 1}); - VMIdServer temp = new VMIdServer(tableName, annotation.initialValue() - 1); - temp.write2DB(); - LOG.log(Level.FINE, "Added: {0}: {1}", - new Object[]{tableName, annotation.initialValue() - 1}); - } - } - } - } - catch (VMException ex1) { - LOG.log(Level.SEVERE, null, ex1); - } - finally { - if (LOG.isLoggable(Level.CONFIG)) { - VmIdJpaController controller = new VmIdJpaController( - getEntityManagerFactory()); - controller.findVmIdEntities().stream().forEach((next) -> { - LOG.log(Level.CONFIG, "{0}, {1}, {2}", new Object[]{next.getId(), - next.getTableName(), next.getLastId()}); - }); - } - } - } - - private static void generateIDs() { - if (!dbError) { - LOG.log(Level.FINE, - "Creating ids to work around eclipse issue " - + "(https://bugs.eclipse.org/bugs/show_bug.cgi?id=366852)..."); - getEntityManager().getMetamodel().getEmbeddables().forEach((et) -> { - processFields(et.getJavaType().getDeclaredFields()); - }); - getEntityManager().getMetamodel().getEntities().forEach((et) -> { - processFields(et.getBindableJavaType().getDeclaredFields()); - }); - LOG.log(Level.FINE, "Done!"); - } - } - - /** - * @return the properties - */ - public static Map getProperties() { - return properties; - } - - /** - * Get the current persistence unit name - * - * @return current persistence unit name - */ - public static String getPersistenceUnitName() { - return PU; - } - - /** - * @param aPU the PU to set - */ - public static void setPersistenceUnitName(String aPU) { - PU = aPU; - LOG.log(Level.FINE, "Changed persistence unit name to: {0}", PU); - //Set it to null so it's recreated with new Persistence Unit next time is requested. - emf = null; - em = null; - try { - reload(); - } - catch (VMException ex) { - LOG.log(Level.SEVERE, null, ex); - } - } - - public static void setEntityManagerFactory(EntityManagerFactory newEMF) { - emf = newEMF; - } - - /** - * @return the emf - */ - public static EntityManagerFactory getEntityManagerFactory() { - if (emf == null && !dbError) { - try { - InitialContext ctx = new InitialContext(); - //Use the context defined Database connection - PU = (String) ctx.lookup("java:comp/env/validation-manager/JNDIDB"); - try { - demo = (Boolean) ctx.lookup("java:comp/env/validation-manager/demo"); - } - catch (NamingException e) { - LOG.log(Level.SEVERE, null, e); - demo = false; - } - if (isDemo()) { - try { - demoResetPeriod = (Long) ctx - .lookup("java:comp/env/validation-manager/demo-period"); - } - catch (NamingException e) { - LOG.log(Level.SEVERE, null, e); - demoResetPeriod = valueOf(0); - } - if (getDemoResetPeriod() > 0) { - Long millis = getDemoResetPeriod(); - String format = String.format("%02d min, %02d sec", - TimeUnit.MILLISECONDS.toMinutes(millis), - TimeUnit.MILLISECONDS.toSeconds(millis) - - TimeUnit.MINUTES.toSeconds(TimeUnit.MILLISECONDS.toMinutes(millis)) - ); - LOG.log(Level.WARNING, - "Instance configured as demo, database will reset" - + " each {0}", format); - } - } - final String JNDIDB = (String) ctx.lookup("java:comp/env/validation-manager/JNDIDB"); - emf = createEntityManagerFactory(JNDIDB); - LOG.log(Level.FINE, "Using context defined database connection: {0}", JNDIDB); - usingContext = true; - } - catch (NamingException e) { - LOG.log(Level.FINE, null, e); - if (!usingContext) { - LOG.log(Level.WARNING, - "Manually specified connection parameters. " - + "Using pre-defined persistence unit: {0}", PU); - emf = createEntityManagerFactory(PU); - } else { - LOG.log(Level.SEVERE, - "Context doesn't exist. Check your configuration.", e); - dbError = true; - } - } - } - return emf; - } - - /** - * @return the demo - */ - public static boolean isDemo() { - return demo; - } - - public static EntityManager getEntityManager() { - if (em == null) { - em = getEntityManagerFactory().createEntityManager(); - LOG.log(Level.FINE, - "Creating EntityManager from: {0}", PU); - properties = em.getProperties(); - } - return em; - } - - public static List createdQuery(String query) { - return createdQuery(query, null); - } - - @SuppressWarnings("unchecked") - public static List createdQuery(String query, Map parameters) { - Query q = getEntityManager().createQuery(query); - if (parameters != null) { - Iterator> entries = parameters.entrySet().iterator(); - while (entries.hasNext()) { - Entry e = entries.next(); - q.setParameter(e.getKey(), e.getValue()); - } - } - return q.getResultList(); - } - - /** - * Named query that will modify the database - * - * @param query query to execute - */ - public static void namedUpdateQuery(String query) { - namedQuery(query, null, true); - } - - public static List nativeQuery(String query) { - List resultList - = getEntityManager().createNativeQuery(query).getResultList(); - return resultList; - } - - public static List createdQuery(String query, T result) { - List resultList - = getEntityManager().createQuery(query).getResultList(); - return resultList; - } - - public static void nativeUpdateQuery(String query) { - getEntityManager().createNativeQuery(query).executeUpdate(); - } - - /** - * Named query (not for updates) - * - * @param query query to execute - * @return query result - */ - public static List namedQuery(String query) { - return namedQuery(query, null, false); - } - - /** - * Named query that will modify the database - * - * @param query query to execute - * @param parameters query parameters - */ - public static void namedUpdateQuery(String query, Map parameters) { - namedQuery(query, parameters, true); - } - - /** - * Named query (not for updates) - * - * @param query query to execute - * @param parameters query parameters - * @return query result - */ - public static List namedQuery(String query, - Map parameters) { - return namedQuery(query, parameters, false); - } - - @SuppressWarnings("unchecked") - private static List namedQuery(String query, - Map parameters, boolean change) { - EntityTransaction transaction = getEntityManager().getTransaction(); - if (change) { - transaction.begin(); - } - Query q = getEntityManager().createNamedQuery(query); - if (parameters != null) { - Iterator> entries - = parameters.entrySet().iterator(); - while (entries.hasNext()) { - Entry e = entries.next(); - q.setParameter(e.getKey(), e.getValue()); - } - } - if (change) { - transaction.commit(); - } - return q.getResultList(); - } - - public static void close() { - getEntityManager().close(); - getEntityManagerFactory().close(); - emf = null; - em = null; - } - - public static EntityTransaction getTransaction() { - return getEntityManager().getTransaction(); - } - - public static void reload() throws VMException { - reload(false); - } - - public static void reload(boolean close) throws VMException { - if (close) { - close(); - } - updateDBState(); - getEntityManager(); - generateIDs(); - } - - public static void updateDBState() { - DataSource ds = null; - Connection conn = null; - PreparedStatement stmt = null; - ResultSet rs = null; - try { - ds = (javax.sql.DataSource) new InitialContext().lookup("java:comp/env/jdbc/VMDB"); - conn = ds.getConnection(); - } - catch (NamingException ne) { - LOG.log(Level.FINE, null, ne); - if (emf == null) { - try { - //It might be the tests, use an H2 Database - ds = new JdbcDataSource(); - ((JdbcDataSource) ds).setPassword(""); - ((JdbcDataSource) ds).setUser("vm_user"); - ((JdbcDataSource) ds).setURL( - "jdbc:h2:file:./target/data/test/validation-manager-test;AUTO_SERVER=TRUE"); - //Load the H2 driver - forName("org.h2.Driver"); - conn = ds.getConnection(); - } - catch (ClassNotFoundException | SQLException ex) { - LOG.log(Level.SEVERE, null, ex); - } - } else { - EntityTransaction transaction = getEntityManager().getTransaction(); - transaction.begin(); - conn = getEntityManager().unwrap(java.sql.Connection.class); - transaction.commit(); - } - } - catch (SQLException ex) { - LOG.log(Level.SEVERE, null, ex); - } - if (conn != null) { - try { - stmt = conn.prepareStatement("select * from vm_setting"); - rs = stmt.executeQuery(); - if (!rs.next()) { - //Tables there but empty? Not safe to proceed - setState(DBState.NEED_MANUAL_UPDATE); - } - } - catch (SQLException ex) { - LOG.log(Level.FINE, null, ex); - //Need INIT, probably nothing there - setState(DBState.NEED_INIT); - //Create the database - getEntityManager(); - } - finally { - try { - conn.close(); - } - catch (SQLException ex) { - LOG.log(Level.SEVERE, null, ex); - } - try { - if (stmt != null) { - stmt.close(); - } - } - catch (SQLException ex) { - LOG.log(Level.SEVERE, null, ex); - } - try { - if (rs != null) { - rs.close(); - } - } - catch (SQLException ex) { - LOG.log(Level.SEVERE, null, ex); - } - } - } - if (ds != null) { - //Initialize flyway - initializeFlyway(ds); - updateDatabase(ds); - } else { - state = DBState.ERROR; - } - - if (state != DBState.VALID) { - waitForDB(); - } - } - - private static void updateDatabase(DataSource dataSource) { - Flyway flyway = new Flyway(); - try { - flyway.setDataSource(dataSource); - flyway.setLocations("db.migration"); - LOG.fine("Starting migration..."); - flyway.migrate(); - LOG.fine("Done!"); - } - catch (FlywayException fe) { - LOG.log(Level.SEVERE, "Unable to migrate data", fe); - setState(DBState.ERROR); - } - try { - LOG.fine("Validating migration..."); - flyway.validate(); - LOG.fine("Done!"); - setState(flyway.info().current().getState() - == MigrationState.SUCCESS ? DBState.VALID : DBState.ERROR); - } - catch (FlywayException fe) { - LOG.log(Level.SEVERE, "Unable to validate", fe); - setState(DBState.ERROR); - } - } - - protected static void setState(DBState newState) { - state = newState; - } - - public static void waitForDB() { - while (getState() != DBState.VALID - && getState() != DBState.UPDATED - && getState() != DBState.ERROR) { - LOG.log(Level.FINE, - "Waiting for DB initialization. Current state: {0}", - (getState() != null ? getState().name() : null)); - try { - sleep(100); - } - catch (InterruptedException ex) { - LOG.log(Level.SEVERE, null, ex); - } - } - LOG.log(Level.FINE, "DB ready, resuming..."); - } - - /** - * @return the state - */ - public static DBState getState() { - return state; - } - - /** - * @param lock the lock to set - */ - public static void setLocked(boolean lock) { - LOG.log(Level.WARNING, "{0} the database.", - (lock ? "Locking" : "Unlocking")); - locked = lock; - } - - public static String getVersion() { - return getVersionNumber() - + ((VMSettingServer.getSetting("version.postfix") - .getStringVal().isEmpty() - ? "" : " " - + VMSettingServer.getSetting("version.postfix") - .getStringVal())); - } - - public static String getVersionNumber() { - StringBuilder version = new StringBuilder(); - version.append(VMSettingServer.getSetting("version.high").getIntVal()); - version.append("."); - version.append(VMSettingServer.getSetting("version.mid").getIntVal()); - version.append("."); - version.append(VMSettingServer.getSetting("version.low").getIntVal()); - return version.toString(); - } - - /** - * Compare two number strings. For example: 2.1.0 == 2.01.00 - * - * @param first first string to compare - * @param second second string to compare - * @return true if same, false otherwise - */ - public static boolean compareNumberStrings(String first, String second) { - return compareNumberStrings(first, second, "."); - } - - /** - * Compare two number strings. For example: 2.1.0 == 2.01.00 - * - * @param first first string to compare - * @param second second string to compare - * @param separator separator of fields (i.e. for 2.1.0 is '.') - * @return true if same, false otherwise - */ - public static boolean compareNumberStrings(String first, String second, - String separator) { - boolean result = true; - StringTokenizer firstST = new StringTokenizer(first, separator); - StringTokenizer secondST = new StringTokenizer(second, separator); - if (firstST.countTokens() != secondST.countTokens()) { - //Different amount of fields, not equal. (i.e. 2.1 and 2.1.1 - result = false; - } else { - try { - while (firstST.hasMoreTokens()) { - int firstInt = parseInt(firstST.nextToken()); - int secondInt = parseInt(secondST.nextToken()); - //Both numbers let's continue - if (firstInt != secondInt) { - result = false; - break; - } - } - //Everything the same - } - catch (java.lang.NumberFormatException e) { - LOG.log(Level.WARNING, null, e); - //Is not a number - result = false; - } - } - return result; - } - - /** - * @return the locked - */ - public static boolean isLocked() { - return locked; - } - - private static void initializeFlyway(DataSource dataSource) { - assert dataSource != null; - setState(DBState.START_UP); - Flyway flyway = new Flyway(); - flyway.setDataSource(dataSource); - MigrationInfo status = flyway.info().current(); - if (status == null) { - setState(DBState.NEED_INIT); - LOG.fine("Initialize the metadata..."); - try { - flyway.init(); - LOG.fine("Done!"); - } - catch (FlywayException fe) { - LOG.log(Level.SEVERE, "Unable to initialize database", fe); - setState(DBState.ERROR); - } - } else { - LOG.fine("Database has Flyway metadata already..."); - displayDBStatus(status); - } - } - - private static void displayDBStatus(MigrationInfo status) { - LOG.log(Level.FINE, "Description: {0}\nState: {1}\nVersion: {2}", - new Object[]{status.getDescription(), status.getState(), status.getVersion()}); - } -} +package com.validation.manager.core; + +import com.googlecode.flyway.core.Flyway; +import com.googlecode.flyway.core.api.FlywayException; +import com.googlecode.flyway.core.api.MigrationInfo; +import com.googlecode.flyway.core.api.MigrationState; +import com.validation.manager.core.db.controller.VmIdJpaController; +import com.validation.manager.core.server.core.VMIdServer; +import com.validation.manager.core.server.core.VMSettingServer; +import static java.lang.Class.forName; +import static java.lang.Integer.parseInt; +import static java.lang.Long.valueOf; +import static java.lang.Thread.sleep; +import java.lang.reflect.Field; +import java.sql.Connection; +import java.sql.PreparedStatement; +import java.sql.ResultSet; +import java.sql.SQLException; +import java.util.HashMap; +import java.util.Iterator; +import java.util.List; +import java.util.Map; +import java.util.Map.Entry; +import java.util.StringTokenizer; +import java.util.concurrent.TimeUnit; +import java.util.logging.Level; +import java.util.logging.Logger; +import static java.util.logging.Logger.getLogger; +import javax.naming.InitialContext; +import javax.naming.NamingException; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; +import javax.persistence.EntityTransaction; +import static javax.persistence.Persistence.createEntityManagerFactory; +import javax.persistence.Query; +import javax.persistence.TableGenerator; +import javax.sql.DataSource; +import org.h2.jdbcx.JdbcDataSource; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class DataBaseManager { + + private static EntityManagerFactory emf; + private static Map properties; + //Default. Can be overwritten using setPersistenceUnitName(String aPU) + private static String PU = "VMPU"; + private static EntityManager em; + private static boolean dbError = false; + private static final Logger LOG + = getLogger(DataBaseManager.class.getSimpleName()); + private static DBState state = DBState.START_UP; + private static boolean locked = false; + private static boolean usingContext; + private static boolean demo; + private static Long demoResetPeriod; + private static DataBaseManager instance; + private static boolean versioning_enabled = true; + + /** + * @return the versioning enabled + */ + public static boolean isVersioningEnabled() { + return versioning_enabled; + } + + /** + * @param aVersioning_enabled the versioning_enabled to set + */ + public static void setVersioningEnabled(boolean aVersioning_enabled) { + versioning_enabled = aVersioning_enabled; + } + + /** + * @return the demoResetPeriod + */ + public static Long getDemoResetPeriod() { + return demoResetPeriod; + } + + private DataBaseManager() { + } + + public static DataBaseManager get() throws Exception { + if (instance == null) { + instance = new DataBaseManager(); + } + return instance; + } + + @SuppressWarnings("unchecked") + private static void processFields(Field[] fields) { + try { + for (Field field : fields) { + if (field.isAnnotationPresent(TableGenerator.class)) { + field.setAccessible(true); + TableGenerator annotation = field.getAnnotation(TableGenerator.class); + field.setAccessible(false); + Map parameters = new HashMap<>(); + String tableName = annotation.pkColumnValue(); + parameters.put("tableName", tableName); + if (namedQuery("VmId.findByTableName", parameters, false).isEmpty()) { + LOG.log(Level.FINE, "Adding: {0}: {1}", + new Object[]{tableName, annotation.initialValue() - 1}); + VMIdServer temp = new VMIdServer(tableName, annotation.initialValue() - 1); + temp.write2DB(); + LOG.log(Level.FINE, "Added: {0}: {1}", + new Object[]{tableName, annotation.initialValue() - 1}); + } + } + } + } + catch (VMException ex1) { + LOG.log(Level.SEVERE, null, ex1); + } + finally { + if (LOG.isLoggable(Level.CONFIG)) { + VmIdJpaController controller = new VmIdJpaController( + getEntityManagerFactory()); + controller.findVmIdEntities().stream().forEach((next) -> { + LOG.log(Level.CONFIG, "{0}, {1}, {2}", new Object[]{next.getId(), + next.getTableName(), next.getLastId()}); + }); + } + } + } + + private static void generateIDs() { + if (!dbError) { + LOG.log(Level.FINE, + "Creating ids to work around eclipse issue " + + "(https://bugs.eclipse.org/bugs/show_bug.cgi?id=366852)..."); + getEntityManager().getMetamodel().getEmbeddables().forEach((et) -> { + processFields(et.getJavaType().getDeclaredFields()); + }); + getEntityManager().getMetamodel().getEntities().forEach((et) -> { + processFields(et.getBindableJavaType().getDeclaredFields()); + }); + LOG.log(Level.FINE, "Done!"); + } + } + + /** + * @return the properties + */ + public static Map getProperties() { + return properties; + } + + /** + * Get the current persistence unit name + * + * @return current persistence unit name + */ + public static String getPersistenceUnitName() { + return PU; + } + + /** + * @param aPU the PU to set + */ + public static void setPersistenceUnitName(String aPU) { + PU = aPU; + LOG.log(Level.FINE, "Changed persistence unit name to: {0}", PU); + //Set it to null so it's recreated with new Persistence Unit next time is requested. + emf = null; + em = null; + try { + reload(); + } + catch (VMException ex) { + LOG.log(Level.SEVERE, null, ex); + } + } + + public static void setEntityManagerFactory(EntityManagerFactory newEMF) { + emf = newEMF; + } + + /** + * @return the emf + */ + public static EntityManagerFactory getEntityManagerFactory() { + if (emf == null && !dbError) { + try { + InitialContext ctx = new InitialContext(); + //Use the context defined Database connection + PU = (String) ctx.lookup("java:comp/env/validation-manager/JNDIDB"); + try { + demo = (Boolean) ctx.lookup("java:comp/env/validation-manager/demo"); + } + catch (NamingException e) { + LOG.log(Level.SEVERE, null, e); + demo = false; + } + if (isDemo()) { + try { + demoResetPeriod = (Long) ctx + .lookup("java:comp/env/validation-manager/demo-period"); + } + catch (NamingException e) { + LOG.log(Level.SEVERE, null, e); + demoResetPeriod = valueOf(0); + } + if (getDemoResetPeriod() > 0) { + Long millis = getDemoResetPeriod(); + String format = String.format("%02d min, %02d sec", + TimeUnit.MILLISECONDS.toMinutes(millis), + TimeUnit.MILLISECONDS.toSeconds(millis) + - TimeUnit.MINUTES.toSeconds(TimeUnit.MILLISECONDS.toMinutes(millis)) + ); + LOG.log(Level.WARNING, + "Instance configured as demo, database will reset" + + " each {0}", format); + } + } + final String JNDIDB = (String) ctx.lookup("java:comp/env/validation-manager/JNDIDB"); + emf = createEntityManagerFactory(JNDIDB); + LOG.log(Level.FINE, "Using context defined database connection: {0}", JNDIDB); + usingContext = true; + } + catch (NamingException e) { + LOG.log(Level.FINE, null, e); + if (!usingContext) { + LOG.log(Level.WARNING, + "Manually specified connection parameters. " + + "Using pre-defined persistence unit: {0}", PU); + emf = createEntityManagerFactory(PU); + } else { + LOG.log(Level.SEVERE, + "Context doesn't exist. Check your configuration.", e); + dbError = true; + } + } + } + return emf; + } + + /** + * @return the demo + */ + public static boolean isDemo() { + return demo; + } + + public static EntityManager getEntityManager() { + if (em == null) { + em = getEntityManagerFactory().createEntityManager(); + LOG.log(Level.FINE, + "Creating EntityManager from: {0}", PU); + properties = em.getProperties(); + } + return em; + } + + public static List createdQuery(String query) { + return createdQuery(query, null); + } + + @SuppressWarnings("unchecked") + public static List createdQuery(String query, Map parameters) { + Query q = getEntityManager().createQuery(query); + if (parameters != null) { + Iterator> entries = parameters.entrySet().iterator(); + while (entries.hasNext()) { + Entry e = entries.next(); + q.setParameter(e.getKey(), e.getValue()); + } + } + return q.getResultList(); + } + + /** + * Named query that will modify the database + * + * @param query query to execute + */ + public static void namedUpdateQuery(String query) { + namedQuery(query, null, true); + } + + public static List nativeQuery(String query) { + List resultList + = getEntityManager().createNativeQuery(query).getResultList(); + return resultList; + } + + public static List createdQuery(String query, T result) { + List resultList + = getEntityManager().createQuery(query).getResultList(); + return resultList; + } + + public static void nativeUpdateQuery(String query) { + getEntityManager().createNativeQuery(query).executeUpdate(); + } + + /** + * Named query (not for updates) + * + * @param query query to execute + * @return query result + */ + public static List namedQuery(String query) { + return namedQuery(query, null, false); + } + + /** + * Named query that will modify the database + * + * @param query query to execute + * @param parameters query parameters + */ + public static void namedUpdateQuery(String query, Map parameters) { + namedQuery(query, parameters, true); + } + + /** + * Named query (not for updates) + * + * @param query query to execute + * @param parameters query parameters + * @return query result + */ + public static List namedQuery(String query, + Map parameters) { + return namedQuery(query, parameters, false); + } + + @SuppressWarnings("unchecked") + private static List namedQuery(String query, + Map parameters, boolean change) { + EntityTransaction transaction = getEntityManager().getTransaction(); + if (change) { + transaction.begin(); + } + Query q = getEntityManager().createNamedQuery(query); + if (parameters != null) { + Iterator> entries + = parameters.entrySet().iterator(); + while (entries.hasNext()) { + Entry e = entries.next(); + q.setParameter(e.getKey(), e.getValue()); + } + } + if (change) { + transaction.commit(); + } + return q.getResultList(); + } + + public static void close() { + getEntityManager().close(); + getEntityManagerFactory().close(); + emf = null; + em = null; + } + + public static EntityTransaction getTransaction() { + return getEntityManager().getTransaction(); + } + + public static void reload() throws VMException { + reload(false); + } + + public static void reload(boolean close) throws VMException { + if (close) { + close(); + } + updateDBState(); + getEntityManager(); + generateIDs(); + } + + public static void updateDBState() { + DataSource ds = null; + Connection conn = null; + PreparedStatement stmt = null; + ResultSet rs = null; + try { + ds = (javax.sql.DataSource) new InitialContext().lookup("java:comp/env/jdbc/VMDB"); + conn = ds.getConnection(); + } + catch (NamingException ne) { + LOG.log(Level.FINE, null, ne); + if (emf == null) { + try { + //It might be the tests, use an H2 Database + ds = new JdbcDataSource(); + ((JdbcDataSource) ds).setPassword(""); + ((JdbcDataSource) ds).setUser("vm_user"); + ((JdbcDataSource) ds).setURL( + "jdbc:h2:file:./target/data/test/validation-manager-test;AUTO_SERVER=TRUE"); + //Load the H2 driver + forName("org.h2.Driver"); + conn = ds.getConnection(); + } + catch (ClassNotFoundException | SQLException ex) { + LOG.log(Level.SEVERE, null, ex); + } + } else { + EntityTransaction transaction = getEntityManager().getTransaction(); + transaction.begin(); + conn = getEntityManager().unwrap(java.sql.Connection.class); + transaction.commit(); + } + } + catch (SQLException ex) { + LOG.log(Level.SEVERE, null, ex); + } + if (conn != null) { + try { + stmt = conn.prepareStatement("select * from vm_setting"); + rs = stmt.executeQuery(); + if (!rs.next()) { + //Tables there but empty? Not safe to proceed + setState(DBState.NEED_MANUAL_UPDATE); + } + } + catch (SQLException ex) { + LOG.log(Level.FINE, null, ex); + //Need INIT, probably nothing there + setState(DBState.NEED_INIT); + //Create the database + getEntityManager(); + } + finally { + try { + conn.close(); + } + catch (SQLException ex) { + LOG.log(Level.SEVERE, null, ex); + } + try { + if (stmt != null) { + stmt.close(); + } + } + catch (SQLException ex) { + LOG.log(Level.SEVERE, null, ex); + } + try { + if (rs != null) { + rs.close(); + } + } + catch (SQLException ex) { + LOG.log(Level.SEVERE, null, ex); + } + } + } + if (ds != null) { + //Initialize flyway + initializeFlyway(ds); + updateDatabase(ds); + } else { + state = DBState.ERROR; + } + + if (state != DBState.VALID) { + waitForDB(); + } + } + + private static void updateDatabase(DataSource dataSource) { + Flyway flyway = new Flyway(); + try { + flyway.setDataSource(dataSource); + flyway.setLocations("db.migration"); + LOG.fine("Starting migration..."); + flyway.migrate(); + LOG.fine("Done!"); + } + catch (FlywayException fe) { + LOG.log(Level.SEVERE, "Unable to migrate data", fe); + setState(DBState.ERROR); + } + try { + LOG.fine("Validating migration..."); + flyway.validate(); + LOG.fine("Done!"); + setState(flyway.info().current().getState() + == MigrationState.SUCCESS ? DBState.VALID : DBState.ERROR); + } + catch (FlywayException fe) { + LOG.log(Level.SEVERE, "Unable to validate", fe); + setState(DBState.ERROR); + } + } + + protected static void setState(DBState newState) { + state = newState; + } + + public static void waitForDB() { + while (getState() != DBState.VALID + && getState() != DBState.UPDATED + && getState() != DBState.ERROR) { + LOG.log(Level.FINE, + "Waiting for DB initialization. Current state: {0}", + (getState() != null ? getState().name() : null)); + try { + sleep(100); + } + catch (InterruptedException ex) { + LOG.log(Level.SEVERE, null, ex); + } + } + LOG.log(Level.FINE, "DB ready, resuming..."); + } + + /** + * @return the state + */ + public static DBState getState() { + return state; + } + + /** + * @param lock the lock to set + */ + public static void setLocked(boolean lock) { + LOG.log(Level.WARNING, "{0} the database.", + (lock ? "Locking" : "Unlocking")); + locked = lock; + } + + public static String getVersion() { + return getVersionNumber() + + ((VMSettingServer.getSetting("version.postfix") + .getStringVal().isEmpty() + ? "" : " " + + VMSettingServer.getSetting("version.postfix") + .getStringVal())); + } + + public static String getVersionNumber() { + StringBuilder version = new StringBuilder(); + version.append(VMSettingServer.getSetting("version.high").getIntVal()); + version.append("."); + version.append(VMSettingServer.getSetting("version.mid").getIntVal()); + version.append("."); + version.append(VMSettingServer.getSetting("version.low").getIntVal()); + return version.toString(); + } + + /** + * Compare two number strings. For example: 2.1.0 == 2.01.00 + * + * @param first first string to compare + * @param second second string to compare + * @return true if same, false otherwise + */ + public static boolean compareNumberStrings(String first, String second) { + return compareNumberStrings(first, second, "."); + } + + /** + * Compare two number strings. For example: 2.1.0 == 2.01.00 + * + * @param first first string to compare + * @param second second string to compare + * @param separator separator of fields (i.e. for 2.1.0 is '.') + * @return true if same, false otherwise + */ + public static boolean compareNumberStrings(String first, String second, + String separator) { + boolean result = true; + StringTokenizer firstST = new StringTokenizer(first, separator); + StringTokenizer secondST = new StringTokenizer(second, separator); + if (firstST.countTokens() != secondST.countTokens()) { + //Different amount of fields, not equal. (i.e. 2.1 and 2.1.1 + result = false; + } else { + try { + while (firstST.hasMoreTokens()) { + int firstInt = parseInt(firstST.nextToken()); + int secondInt = parseInt(secondST.nextToken()); + //Both numbers let's continue + if (firstInt != secondInt) { + result = false; + break; + } + } + //Everything the same + } + catch (java.lang.NumberFormatException e) { + LOG.log(Level.WARNING, null, e); + //Is not a number + result = false; + } + } + return result; + } + + /** + * @return the locked + */ + public static boolean isLocked() { + return locked; + } + + private static void initializeFlyway(DataSource dataSource) { + assert dataSource != null; + setState(DBState.START_UP); + Flyway flyway = new Flyway(); + flyway.setDataSource(dataSource); + MigrationInfo status = flyway.info().current(); + if (status == null) { + setState(DBState.NEED_INIT); + LOG.fine("Initialize the metadata..."); + try { + flyway.init(); + LOG.fine("Done!"); + } + catch (FlywayException fe) { + LOG.log(Level.SEVERE, "Unable to initialize database", fe); + setState(DBState.ERROR); + } + } else { + LOG.fine("Database has Flyway metadata already..."); + displayDBStatus(status); + } + } + + private static void displayDBStatus(MigrationInfo status) { + LOG.log(Level.FINE, "Description: {0}\nState: {1}\nVersion: {2}", + new Object[]{status.getDescription(), status.getState(), status.getVersion()}); + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/DemoBuilder.java b/VM-Core/src/main/java/com/validation/manager/core/DemoBuilder.java index 9e561abf..107bb18d 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/DemoBuilder.java +++ b/VM-Core/src/main/java/com/validation/manager/core/DemoBuilder.java @@ -13,254 +13,254 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core; - -import com.validation.manager.core.db.Project; -import com.validation.manager.core.db.Requirement; -import com.validation.manager.core.db.Step; -import com.validation.manager.core.db.TestCase; -import com.validation.manager.core.db.controller.ProjectJpaController; -import com.validation.manager.core.db.controller.RequirementJpaController; -import com.validation.manager.core.db.controller.TestCaseJpaController; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import com.validation.manager.core.server.core.ExecutionStepServer; -import com.validation.manager.core.server.core.ProjectServer; -import com.validation.manager.core.server.core.RequirementServer; -import com.validation.manager.core.server.core.RequirementSpecNodeServer; -import com.validation.manager.core.server.core.RequirementSpecServer; -import com.validation.manager.core.server.core.StepServer; -import com.validation.manager.core.server.core.TestCaseExecutionServer; -import com.validation.manager.core.server.core.TestCaseServer; -import com.validation.manager.core.server.core.TestPlanServer; -import com.validation.manager.core.server.core.TestProjectServer; -import com.validation.manager.core.server.core.VMUserServer; -import java.util.ArrayList; -import java.util.Date; -import java.util.List; -import java.util.Random; -import java.util.logging.Level; -import java.util.logging.Logger; - -/** - * - * @author Javier Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class DemoBuilder { - - private static final Logger LOG - = Logger.getLogger(DemoBuilder.class.getSimpleName()); - private static int tcCounter = 1, tpCounter, reqCounter; - - public static void buildDemoProject() throws Exception { - LOG.info("Creating demo projects..."); - ProjectJpaController controller - = new ProjectJpaController(DataBaseManager - .getEntityManagerFactory()); - Project rootProject = new Project("Demo"); - controller.create(rootProject); - for (int i = 0; i < 2; i++) { - Project temp = new Project("Sub " + (i + 1)); - temp.setParentProjectId(rootProject); - controller.create(temp); - ProjectServer ps = new ProjectServer(temp); - addDemoProjectRequirements(ps.getEntity()); - addDemoProjectTestProject(ps.getEntity()); - rootProject.getProjectList().add(ps.getEntity()); - } - addDemoProjectRequirements(rootProject); - controller.edit(rootProject); - //Link requirements with steps - List requirements - = new RequirementJpaController(DataBaseManager - .getEntityManagerFactory()) - .findRequirementEntities(); - LOG.log(Level.INFO, "Total: {0}", requirements.size()); - List tcs = new TestCaseJpaController(DataBaseManager - .getEntityManagerFactory()).findTestCaseEntities(); - int amount = tcs.size(); - int size = requirements.size() / amount; - int i = 0; - for (TestCase tc : tcs) { - for (Step step : tc.getStepList()) { - try { - StepServer ss = new StepServer(step); - ss.getRequirementList().addAll(requirements - .subList(i * size, i * size + size)); - ss.write2DB(); - } - catch (Exception ex) { - LOG.log(Level.SEVERE, null, ex); - } - } - i++; - } - for (Project p : controller.findProjectEntities()) { - addDemoExecution(p); - } - LOG.info("Done!"); - } - - private static void addDemoProjectRequirements(Project p) - throws Exception { - tpCounter = 1; - reqCounter = 1; - //Create User Needs spec - RequirementSpecServer un = createRequirementSpec(p, 1, 1, 5, - "User Need", "User Need Desc"); - List subSpecs = new ArrayList<>(); - for (int i = 0; i < 5; i++) { - //Create a spec - subSpecs.add(createRequirementSpec(p, 5, 1, 5, "Spec " + i, - "Desc " + i)); - } - //Now link UN requirement to lower level requirements - un.getRequirementSpecNodeList().forEach(rsn -> { - int count = 0; - for (Requirement r : rsn.getRequirementList()) { - subSpecs.get(count).getRequirementSpecNodeList().forEach(nl -> { - nl.getRequirementList().forEach(sr -> { - try { - new RequirementServer(r) - .addChildRequirement(sr); - } - catch (VMException ex) { - LOG.log(Level.SEVERE, null, ex); - } - catch (Exception ex) { - LOG.log(Level.SEVERE, null, ex); - } - }); - }); - count++; - } - }); - new ProjectJpaController(DataBaseManager - .getEntityManagerFactory()).edit(p); - } - - /** - * Create a requirement spec for the provided project on the specified - * requirement level. - * - * @param p Project to add the spec to. - * @param level Spec level - * @param nodeAmount Amount of nodes to create - * @param reqAmount Amount of requirements to add to each node of this spec. - * @param specName Spec desired name - * @param specDesc Spec description - * @return Created Requirement Spec - * @throws Exception - */ - private static RequirementSpecServer createRequirementSpec(Project p, - int level, int nodeAmount, int reqAmount, String specName, - String specDesc) throws Exception { - RequirementSpecServer temp - = new RequirementSpecServer(specName, - specDesc, - p.getId(), level); - temp.write2DB(); - if (nodeAmount > 0) { - for (int i = 0; i < nodeAmount; i++) { - RequirementSpecNodeServer node - = temp.addSpecNode("Node " + (i + 1), - "Description " + (i + 1), "Scope " + (i + 1)); - if (reqAmount > 0) { - for (int y = 0; y < reqAmount; y++) { - String header = ""; - switch (level) { - case 1: - header = "PS"; - break; - case 5: - header = "SRS"; - break; - default: - header = "SRS"; - break; - } - RequirementServer req - = new RequirementServer(header - + String.format("%05d", reqCounter), - "Description " + reqCounter, - node.getRequirementSpecNodePK(), - "Notes", 1, 1); - req.write2DB(); - node.getRequirementList().add(req.getEntity()); - reqCounter++; - } - } - node.write2DB(); - } - p.getRequirementSpecList().add(temp.getEntity()); - temp.update(); - } - return temp; - } - - private static void addDemoProjectTestProject(Project p) throws - NonexistentEntityException, Exception { - TestProjectServer tp - = new TestProjectServer("Test Project", true); - tp.setName("Test Project"); - tp.setNotes("Notes"); - tp.setActive(true); - tp.write2DB(); - //Add the test structure - TestPlanServer tps = new TestPlanServer(tp.getEntity(), - true, true); - tps.setName("Test Plan #" + (tpCounter++)); - tps.setNotes("Notes"); - tps.write2DB(); - int amount = 5; - for (int i = 0; i < 5; i++) { - //Add steps - TestCaseServer tcs - = new TestCaseServer("Test Case #" - + (tcCounter++), - new Date()); - tcs.write2DB(); - for (int j = 0; j < amount; j++) { - tcs.addStep((j + 1), "Step #" + (j + 1), "Note", - "Criteria", - new ArrayList<>()); - } - tcs.write2DB(); - tps.addTestCase(tcs.getEntity()); - } - ProjectServer ps = new ProjectServer(p); - if (ps.getTestProjectList() == null) { - ps.setTestProjectList(new ArrayList<>()); - } - ps.getTestProjectList().add(tp.getEntity()); - //Save it - ps.write2DB(); - } - - private static void addDemoExecution(Project p) - throws NonexistentEntityException, Exception { - int i = 1; - TestCaseExecutionServer tces - = new TestCaseExecutionServer("Execution " + i, - "Test Scope " + i); - tces.setConclusion("Conclusion!"); - tces.write2DB(); - p.getTestProjectList().forEach((tp) -> { - tces.addTestProject(tp); - }); - tces.write2DB(); - VMUserServer tester1 = new VMUserServer(2);//Tester - VMUserServer tester2 = new VMUserServer(3);//Tester - VMUserServer assigner = new VMUserServer(6);//Tester - Random r = new Random(); - tces.getExecutionStepList().stream().map((es) - -> new ExecutionStepServer(es)).forEachOrdered((ess) - -> { - ess.getStep().getRequirementList().forEach(req -> { - ess.getHistoryList().add(req.getHistoryList().get(0)); - }); - ess.setStepHistory(ess.getStep().getHistoryList().get(0)); - ess.assignUser(r.nextBoolean() ? tester1.getEntity() - : tester2.getEntity(), assigner.getEntity()); - }); - } -} +package com.validation.manager.core; + +import com.validation.manager.core.db.Project; +import com.validation.manager.core.db.Requirement; +import com.validation.manager.core.db.Step; +import com.validation.manager.core.db.TestCase; +import com.validation.manager.core.db.controller.ProjectJpaController; +import com.validation.manager.core.db.controller.RequirementJpaController; +import com.validation.manager.core.db.controller.TestCaseJpaController; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import com.validation.manager.core.server.core.ExecutionStepServer; +import com.validation.manager.core.server.core.ProjectServer; +import com.validation.manager.core.server.core.RequirementServer; +import com.validation.manager.core.server.core.RequirementSpecNodeServer; +import com.validation.manager.core.server.core.RequirementSpecServer; +import com.validation.manager.core.server.core.StepServer; +import com.validation.manager.core.server.core.TestCaseExecutionServer; +import com.validation.manager.core.server.core.TestCaseServer; +import com.validation.manager.core.server.core.TestPlanServer; +import com.validation.manager.core.server.core.TestProjectServer; +import com.validation.manager.core.server.core.VMUserServer; +import java.util.ArrayList; +import java.util.Date; +import java.util.List; +import java.util.Random; +import java.util.logging.Level; +import java.util.logging.Logger; + +/** + * + * @author Javier Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class DemoBuilder { + + private static final Logger LOG + = Logger.getLogger(DemoBuilder.class.getSimpleName()); + private static int tcCounter = 1, tpCounter, reqCounter; + + public static void buildDemoProject() throws Exception { + LOG.info("Creating demo projects..."); + ProjectJpaController controller + = new ProjectJpaController(DataBaseManager + .getEntityManagerFactory()); + Project rootProject = new Project("Demo"); + controller.create(rootProject); + for (int i = 0; i < 2; i++) { + Project temp = new Project("Sub " + (i + 1)); + temp.setParentProjectId(rootProject); + controller.create(temp); + ProjectServer ps = new ProjectServer(temp); + addDemoProjectRequirements(ps.getEntity()); + addDemoProjectTestProject(ps.getEntity()); + rootProject.getProjectList().add(ps.getEntity()); + } + addDemoProjectRequirements(rootProject); + controller.edit(rootProject); + //Link requirements with steps + List requirements + = new RequirementJpaController(DataBaseManager + .getEntityManagerFactory()) + .findRequirementEntities(); + LOG.log(Level.FINE, "Total Requirements: {0}", requirements.size()); + List tcs = new TestCaseJpaController(DataBaseManager + .getEntityManagerFactory()).findTestCaseEntities(); + int amount = tcs.size(); + int size = requirements.size() / amount; + int i = 0; + for (TestCase tc : tcs) { + for (Step step : tc.getStepList()) { + try { + StepServer ss = new StepServer(step); + ss.getRequirementList().addAll(requirements + .subList(i * size, i * size + size)); + ss.write2DB(); + } + catch (Exception ex) { + LOG.log(Level.SEVERE, null, ex); + } + } + i++; + } + for (Project p : controller.findProjectEntities()) { + addDemoExecution(p); + } + LOG.info("Done!"); + } + + private static void addDemoProjectRequirements(Project p) + throws Exception { + tpCounter = 1; + reqCounter = 1; + //Create User Needs spec + RequirementSpecServer un = createRequirementSpec(p, 1, 1, 5, + "User Need", "User Need Desc"); + List subSpecs = new ArrayList<>(); + for (int i = 0; i < 5; i++) { + //Create a spec + subSpecs.add(createRequirementSpec(p, 5, 1, 5, "Spec " + i, + "Desc " + i)); + } + //Now link UN requirement to lower level requirements + un.getRequirementSpecNodeList().forEach(rsn -> { + int count = 0; + for (Requirement r : rsn.getRequirementList()) { + subSpecs.get(count).getRequirementSpecNodeList().forEach(nl -> { + nl.getRequirementList().forEach(sr -> { + try { + new RequirementServer(r) + .addChildRequirement(sr); + } + catch (VMException ex) { + LOG.log(Level.SEVERE, null, ex); + } + catch (Exception ex) { + LOG.log(Level.SEVERE, null, ex); + } + }); + }); + count++; + } + }); + new ProjectJpaController(DataBaseManager + .getEntityManagerFactory()).edit(p); + } + + /** + * Create a requirement spec for the provided project on the specified + * requirement level. + * + * @param p Project to add the spec to. + * @param level Spec level + * @param nodeAmount Amount of nodes to create + * @param reqAmount Amount of requirements to add to each node of this spec. + * @param specName Spec desired name + * @param specDesc Spec description + * @return Created Requirement Spec + * @throws Exception + */ + private static RequirementSpecServer createRequirementSpec(Project p, + int level, int nodeAmount, int reqAmount, String specName, + String specDesc) throws Exception { + RequirementSpecServer temp + = new RequirementSpecServer(specName, + specDesc, + p.getId(), level); + temp.write2DB(); + if (nodeAmount > 0) { + for (int i = 0; i < nodeAmount; i++) { + RequirementSpecNodeServer node + = temp.addSpecNode("Node " + (i + 1), + "Description " + (i + 1), "Scope " + (i + 1)); + if (reqAmount > 0) { + for (int y = 0; y < reqAmount; y++) { + String header = ""; + switch (level) { + case 1: + header = "PS"; + break; + case 5: + header = "SRS"; + break; + default: + header = "SRS"; + break; + } + RequirementServer req + = new RequirementServer(header + + String.format("%05d", reqCounter), + "Description " + reqCounter, + node.getRequirementSpecNodePK(), + "Notes", 1, 1); + req.write2DB(); + node.getRequirementList().add(req.getEntity()); + reqCounter++; + } + } + node.write2DB(); + } + p.getRequirementSpecList().add(temp.getEntity()); + temp.update(); + } + return temp; + } + + private static void addDemoProjectTestProject(Project p) throws + NonexistentEntityException, Exception { + TestProjectServer tp + = new TestProjectServer("Test Project", true); + tp.setName("Test Project"); + tp.setNotes("Notes"); + tp.setActive(true); + tp.write2DB(); + //Add the test structure + TestPlanServer tps = new TestPlanServer(tp.getEntity(), + true, true); + tps.setName("Test Plan #" + (tpCounter++)); + tps.setNotes("Notes"); + tps.write2DB(); + int amount = 5; + for (int i = 0; i < 5; i++) { + //Add steps + TestCaseServer tcs + = new TestCaseServer("Test Case #" + + (tcCounter++), + new Date()); + tcs.write2DB(); + for (int j = 0; j < amount; j++) { + tcs.addStep((j + 1), "Step #" + (j + 1), "Note", + "Criteria", + new ArrayList<>()); + } + tcs.write2DB(); + tps.addTestCase(tcs.getEntity()); + } + ProjectServer ps = new ProjectServer(p); + if (ps.getTestProjectList() == null) { + ps.setTestProjectList(new ArrayList<>()); + } + ps.getTestProjectList().add(tp.getEntity()); + //Save it + ps.write2DB(); + } + + private static void addDemoExecution(Project p) + throws NonexistentEntityException, Exception { + int i = 1; + TestCaseExecutionServer tces + = new TestCaseExecutionServer("Execution " + i, + "Test Scope " + i); + tces.setConclusion("Conclusion!"); + tces.write2DB(); + p.getTestProjectList().forEach((tp) -> { + tces.addTestProject(tp); + }); + tces.write2DB(); + VMUserServer tester1 = new VMUserServer(2);//Tester + VMUserServer tester2 = new VMUserServer(3);//Tester + VMUserServer assigner = new VMUserServer(6);//Tester + Random r = new Random(); + tces.getExecutionStepList().stream().map((es) + -> new ExecutionStepServer(es)).forEachOrdered((ess) + -> { + ess.getStep().getRequirementList().forEach(req -> { + ess.getHistoryList().add(req.getHistoryList().get(0)); + }); + ess.setStepHistory(ess.getStep().getHistoryList().get(0)); + ess.assignUser(r.nextBoolean() ? tester1.getEntity() + : tester2.getEntity(), assigner.getEntity()); + }); + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/EntityServer.java b/VM-Core/src/main/java/com/validation/manager/core/EntityServer.java index 9b82bb85..818a26ef 100755 --- a/VM-Core/src/main/java/com/validation/manager/core/EntityServer.java +++ b/VM-Core/src/main/java/com/validation/manager/core/EntityServer.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,46 +13,46 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core; - -import java.util.HashMap; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - * @param Entity - */ -public interface EntityServer { - - static HashMap PARAMETERS = new HashMap(); - - /** - * Write Entity to database - * - * @return Id for entity (new if just created) - * @throws Exception if there was an issue updating the database. - */ - public int write2DB() throws Exception; - - /** - * Gets the entity represented by this EntityServer. Easy method to access - * underlying entity for use with controllers and such. - * - * @return The entity. - */ - public T getEntity(); - - /** - * Update the target with the source object. - * - * @param target object to update. - * @param source object to update from. - */ - public void update(T target, T source); - - /** - * Update the enclosed entity. - * - */ - public void update(); -} +package com.validation.manager.core; + +import java.util.HashMap; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + * @param Entity + */ +public interface EntityServer { + + static HashMap PARAMETERS = new HashMap(); + + /** + * Write Entity to database + * + * @return Id for entity (new if just created) + * @throws Exception if there was an issue updating the database. + */ + public int write2DB() throws Exception; + + /** + * Gets the entity represented by this EntityServer. Easy method to access + * underlying entity for use with controllers and such. + * + * @return The entity. + */ + public T getEntity(); + + /** + * Update the target with the source object. + * + * @param target object to update. + * @param source object to update from. + */ + public void update(T target, T source); + + /** + * Update the enclosed entity. + * + */ + public void update(); +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/ImportException.java b/VM-Core/src/main/java/com/validation/manager/core/ImportException.java deleted file mode 100644 index 2f8ac722..00000000 --- a/VM-Core/src/main/java/com/validation/manager/core/ImportException.java +++ /dev/null @@ -1,24 +0,0 @@ -/* - * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.validation.manager.core; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class ImportException extends VMException { - -} diff --git a/VM-Core/src/main/java/com/validation/manager/core/ImporterInterface.java b/VM-Core/src/main/java/com/validation/manager/core/ImporterInterface.java index 6be248cd..29072572 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/ImporterInterface.java +++ b/VM-Core/src/main/java/com/validation/manager/core/ImporterInterface.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,39 +13,39 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core; - -import java.util.List; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - * @param Class type for template. - */ -public interface ImporterInterface { - - /** - * Import the file. - * - * @return List of imported entities - * @throws ImportException If something goes wrong in the importing process. - */ - List importFile() throws VMException; - - /** - * Import the file. - * - * @param header File has header row. - * @return List of imported entities - * @throws ImportException If something goes wrong in the importing process. - */ - List importFile(boolean header) throws VMException; - - /** - * Process the imported data. - * - * @return true if processed successfully, false otherwise. - * @throws VMException if there was an issue during import. - */ - boolean processImport() throws VMException; -} +package com.validation.manager.core; + +import java.util.List; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + * @param Class type for template. + */ +public interface ImporterInterface { + + /** + * Import the file. + * + * @return List of imported entities + * @throws VMException If something goes wrong in the importing process. + */ + List importFile() throws VMException; + + /** + * Import the file. + * + * @param header File has header row. + * @return List of imported entities + * @throws VMException If something goes wrong in the importing process. + */ + List importFile(boolean header) throws VMException; + + /** + * Process the imported data. + * + * @return true if processed successfully, false otherwise. + * @throws VMException if there was an issue during import. + */ + boolean processImport() throws VMException; +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/VMIdGenerator.java b/VM-Core/src/main/java/com/validation/manager/core/VMIdGenerator.java deleted file mode 100755 index 76f263b4..00000000 --- a/VM-Core/src/main/java/com/validation/manager/core/VMIdGenerator.java +++ /dev/null @@ -1,64 +0,0 @@ -/* - * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.validation.manager.core; - -import static com.validation.manager.core.DataBaseManager.namedQuery; -import com.validation.manager.core.db.VmId; -import java.util.HashMap; -import java.util.logging.Level; -import java.util.logging.Logger; -import static java.util.logging.Logger.getLogger; -import javax.persistence.PrePersist; - -/** - * Work around issue with sequencing on H2 databases on Linux - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class VMIdGenerator { - - private static final Logger LOG - = getLogger(VMIdGenerator.class.getSimpleName()); - - /** - * Just before persisting an entity. - * - * @param o object to be persisted - * @throws Exception if something goes wrong - */ - @PrePersist - public void persistEntity(Object o) throws Exception { - LOG.log(Level.FINE, "Pre-persist: {0}", o); - if (o instanceof VmId) { - VmId vmId = (VmId) o; - if (vmId.getId() == null || vmId.getId() <= 0) { - LOG.log(Level.FINE, "Detected: {0}, fixing id...", vmId); - HashMap parameters = new HashMap<>(); - int id = namedQuery("VmId.findAll").size() + 1; - while (vmId.getId() <= 0) { - parameters.put("id", id); - if (namedQuery("VmId.findById", parameters).isEmpty()) { - vmId.setId(id); - LOG.log(Level.FINE, "Assigned id: {0} to {1}", - new Object[]{id, vmId.getTableName()}); - } else { - id++; - } - } - } - } - } -} diff --git a/VM-Core/src/main/java/com/validation/manager/core/VaadinUtils.java b/VM-Core/src/main/java/com/validation/manager/core/VaadinUtils.java index 5d177b4a..41c4a185 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/VaadinUtils.java +++ b/VM-Core/src/main/java/com/validation/manager/core/VaadinUtils.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,162 +13,162 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core; - -import com.vaadin.data.Property; -import com.vaadin.ui.Component; -import com.vaadin.ui.HasComponents; -import com.vaadin.ui.UI; -import java.io.UnsupportedEncodingException; -import java.util.Collections; -import java.util.Enumeration; -import java.util.Locale; -import java.util.ResourceBundle; -import java.util.SortedSet; -import java.util.TreeSet; -import java.util.logging.Level; -import java.util.logging.Logger; - -/** - * {@code VaadinUtils} offers some utility functions for the - * Vaadin UI Framework. - * - * @author Javier Ortiz Bultron - * Based on code from: Ronald K. Muller - * https://gist.github.com/rmuller/10980706 - */ -public final class VaadinUtils { - - private static final Logger LOG - = Logger.getLogger(VaadinUtils.class.getSimpleName()); - - // Utility class - private VaadinUtils() { - } - - /** - * Change all {@code Locale} dependant properties of the - * {@code com.vaadin.ui.Component}s within of the given component container - * (typically an {@link UI} or other top level layout component). If the - * specified {@code Locale} is the same as the current {@code Locale} of the - * component container, this method does nothing. Otherwise it'll go thru - * the components searching for it's component id. If it is in the resource - * bundle, it'll set it's caption to the right translated string. - * - *

- * To use this method, do something like: - *

-     * public class MyUI extends UI {
-     *
-     *     {@literal @}Override
-     *     public void init(final VaadinRequest request) {
-     *         // ... usual code
-     *         // somewhere in the UI the user can change the "Form Locale". This code must
-     *         // call myUI#setLocale(newLocale);
-     *     }
-     *
-     *     // ...
-     *
-     * }
-     *
-     *      String key = "demo.tab.message";
-     *      VerticalLayout vl = new VerticalLayout();
-     *      Button b = new Button(key);
-     *      vl.addComponent(b);
-     *      ResourceBundle rb = ResourceBundle.getBundle(
-     *              "resource.bundle",
-     *              new Locale("es"));
-     *      VaadinUtils.updateLocale(vl, new Locale("es"), rb);
-     *
-     *      It also works with components implementing Property:
-     *
-     *      VerticalLayout vl = new VerticalLayout();
-     *      Label l = new Label(key);
-     *      vl.addComponent(l);
-     *      ResourceBundle rb = ResourceBundle.getBundle(
-     *              "resource.bundle",
-     *              new Locale("es"));
-     *      VaadinUtils.updateLocale(vl, new Locale("es"), rb);
-     * 
- * - * @param ui The component container for which the {@code Locale} dependent - * component properties must be changed, never {@code null} - * @param locale The new {@code Locale}, never {@code null} - * @param rb The {@code ResourceBundle} for the specified {@code Locale}, - * never {@code null} - */ - public static void updateLocale(final HasComponents ui, final Locale locale, - final ResourceBundle rb) { - - // locale may not be null, however the current UI Locale may be null! - if (locale.equals(ui.getLocale())) { - return; - } - final long time = System.currentTimeMillis(); - walkComponentTree(ui, (Component c) -> { - String id = c.getId(); - String caption; - if (c instanceof Property - && ((Property) c).getValue() instanceof String) { - caption = (String) ((Property) c).getValue(); - } else { - caption = c.getCaption(); - } - if (id != null && !id.trim().isEmpty()) { - if (rb.containsKey(id)) { - try { - c.setCaption(new String(rb.getString(id) - .getBytes("ISO-8859-1"), "UTF-8")); - } - catch (UnsupportedEncodingException ex) { - LOG.log(Level.SEVERE, null, ex); - } - } - } else if (caption != null && !caption.trim().isEmpty()) { - /** - * This is a more complex scenario where the caption uses more - * than one key for translation. Sort the keys in reverse so - * substitutions are correct. - */ - final SortedSet ss = new TreeSet<>(Collections.reverseOrder()); - for (Enumeration e = rb.getKeys(); e.hasMoreElements();) { - try { - String key = e.nextElement(); - ss.add(key); - caption = caption.replaceAll(key, new String(rb.getString(key) - .getBytes("ISO-8859-1"), "UTF-8")); - } - catch (UnsupportedEncodingException ex) { - LOG.log(Level.SEVERE, null, ex); - } - } - if (c instanceof Property) { - ((Property) c).setValue(caption); - } else { - c.setCaption(caption); - } - } - }); - LOG.log(Level.INFO, "Locale updated: {0} -> {1} in {2} ms.", - new Object[]{ui.getLocale(), locale, - System.currentTimeMillis() - time}); - } - - // private - // if switching to Java 8, remove this and replace by java.util.funtion.Consumer - // (and make to code more functional) - interface Consumer { - - void accept(T t); - } - - // recursively walk the Component true - private static void walkComponentTree(Component c, Consumer visitor) { - visitor.accept(c); - if (c instanceof HasComponents) { - for (Component child : ((HasComponents) c)) { - walkComponentTree(child, visitor); - } - } - } -} +package com.validation.manager.core; + +import com.vaadin.data.Property; +import com.vaadin.ui.Component; +import com.vaadin.ui.HasComponents; +import com.vaadin.ui.UI; +import java.io.UnsupportedEncodingException; +import java.util.Collections; +import java.util.Enumeration; +import java.util.Locale; +import java.util.ResourceBundle; +import java.util.SortedSet; +import java.util.TreeSet; +import java.util.logging.Level; +import java.util.logging.Logger; + +/** + * {@code VaadinUtils} offers some utility functions for the + * Vaadin UI Framework. + * + * @author Javier Ortiz Bultron + * Based on code from: Ronald K. Muller + * https://gist.github.com/rmuller/10980706 + */ +public final class VaadinUtils { + + private static final Logger LOG + = Logger.getLogger(VaadinUtils.class.getSimpleName()); + + // Utility class + private VaadinUtils() { + } + + /** + * Change all {@code Locale} dependant properties of the + * {@code com.vaadin.ui.Component}s within of the given component container + * (typically an {@link UI} or other top level layout component). If the + * specified {@code Locale} is the same as the current {@code Locale} of the + * component container, this method does nothing. Otherwise it'll go thru + * the components searching for it's component id. If it is in the resource + * bundle, it'll set it's caption to the right translated string. + * + *

+ * To use this method, do something like: + *

+     * public class MyUI extends UI {
+     *
+     *     {@literal @}Override
+     *     public void init(final VaadinRequest request) {
+     *         // ... usual code
+     *         // somewhere in the UI the user can change the "Form Locale". This code must
+     *         // call myUI#setLocale(newLocale);
+     *     }
+     *
+     *     // ...
+     *
+     * }
+     *
+     *      String key = "demo.tab.message";
+     *      VerticalLayout vl = new VerticalLayout();
+     *      Button b = new Button(key);
+     *      vl.addComponent(b);
+     *      ResourceBundle rb = ResourceBundle.getBundle(
+     *              "resource.bundle",
+     *              new Locale("es"));
+     *      VaadinUtils.updateLocale(vl, new Locale("es"), rb);
+     *
+     *      It also works with components implementing Property:
+     *
+     *      VerticalLayout vl = new VerticalLayout();
+     *      Label l = new Label(key);
+     *      vl.addComponent(l);
+     *      ResourceBundle rb = ResourceBundle.getBundle(
+     *              "resource.bundle",
+     *              new Locale("es"));
+     *      VaadinUtils.updateLocale(vl, new Locale("es"), rb);
+     * 
+ * + * @param ui The component container for which the {@code Locale} dependent + * component properties must be changed, never {@code null} + * @param locale The new {@code Locale}, never {@code null} + * @param rb The {@code ResourceBundle} for the specified {@code Locale}, + * never {@code null} + */ + public static void updateLocale(final HasComponents ui, final Locale locale, + final ResourceBundle rb) { + + // locale may not be null, however the current UI Locale may be null! + if (locale.equals(ui.getLocale())) { + return; + } + final long time = System.currentTimeMillis(); + walkComponentTree(ui, (Component c) -> { + String id = c.getId(); + String caption; + if (c instanceof Property + && ((Property) c).getValue() instanceof String) { + caption = (String) ((Property) c).getValue(); + } else { + caption = c.getCaption(); + } + if (id != null && !id.trim().isEmpty()) { + if (rb.containsKey(id)) { + try { + c.setCaption(new String(rb.getString(id) + .getBytes("ISO-8859-1"), "UTF-8")); + } + catch (UnsupportedEncodingException ex) { + LOG.log(Level.SEVERE, null, ex); + } + } + } else if (caption != null && !caption.trim().isEmpty()) { + /** + * This is a more complex scenario where the caption uses more + * than one key for translation. Sort the keys in reverse so + * substitutions are correct. + */ + final SortedSet ss = new TreeSet<>(Collections.reverseOrder()); + for (Enumeration e = rb.getKeys(); e.hasMoreElements();) { + try { + String key = e.nextElement(); + ss.add(key); + caption = caption.replaceAll(key, new String(rb.getString(key) + .getBytes("ISO-8859-1"), "UTF-8")); + } + catch (UnsupportedEncodingException ex) { + LOG.log(Level.SEVERE, null, ex); + } + } + if (c instanceof Property) { + ((Property) c).setValue(caption); + } else { + c.setCaption(caption); + } + } + }); + LOG.log(Level.FINE, "Locale updated: {0} -> {1} in {2} ms.", + new Object[]{ui.getLocale(), locale, + System.currentTimeMillis() - time}); + } + + // private + // if switching to Java 8, remove this and replace by java.util.funtion.Consumer + // (and make to code more functional) + interface Consumer { + + void accept(T t); + } + + // recursively walk the Component true + private static void walkComponentTree(Component c, Consumer visitor) { + visitor.accept(c); + if (c instanceof HasComponents) { + for (Component child : ((HasComponents) c)) { + walkComponentTree(child, visitor); + } + } + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/adapter/TimestampAdapter.java b/VM-Core/src/main/java/com/validation/manager/core/adapter/TimestampAdapter.java deleted file mode 100644 index 63edb98b..00000000 --- a/VM-Core/src/main/java/com/validation/manager/core/adapter/TimestampAdapter.java +++ /dev/null @@ -1,45 +0,0 @@ -/* - * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.validation.manager.core.adapter; - -import java.sql.Timestamp; -import java.util.Date; -import javax.xml.bind.annotation.adapters.XmlAdapter; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class TimestampAdapter extends XmlAdapter { - - @Override - public Timestamp unmarshal(Date v) throws Exception { - if (v == null) { - return null; - } else { - return new Timestamp(v.getTime()); - } - } - - @Override - public Date marshal(Timestamp v) throws Exception { - if (v == null) { - return null; - } else { - return new Date(v.getTime()); - } - } -} diff --git a/VM-Core/src/main/java/com/validation/manager/core/tool/step/importer/StepImportException.java b/VM-Core/src/main/java/com/validation/manager/core/api/email/IEmailManager.java similarity index 55% rename from VM-Core/src/main/java/com/validation/manager/core/tool/step/importer/StepImportException.java rename to VM-Core/src/main/java/com/validation/manager/core/api/email/IEmailManager.java index 26091df3..8be830e8 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/tool/step/importer/StepImportException.java +++ b/VM-Core/src/main/java/com/validation/manager/core/api/email/IEmailManager.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,23 +13,26 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.tool.step.importer; - -import static java.util.Locale.getDefault; -import java.util.ResourceBundle; -import static java.util.ResourceBundle.getBundle; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class StepImportException extends Exception { - - private static final ResourceBundle RB - = getBundle("com.validation.manager.resources.VMMessages", - getDefault()); - - public StepImportException(String message) { - super(RB.containsKey(message) ? RB.getString(message) : message); - } -} +package com.validation.manager.core.api.email; + +import javax.mail.MessagingException; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public interface IEmailManager { + + /** + * Create an email message. + * + * @param to Recipient email + * @param cc Email to copy to + * @param from Sender email + * @param subject Subject + * @param bodyText Message + * @throws MessagingException If there's an error sending the message + */ + void sendEmail(String to, String cc, String from, + String subject, String bodyText) throws MessagingException; +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/api/internationalization/InternationalizationProvider.java b/VM-Core/src/main/java/com/validation/manager/core/api/internationalization/InternationalizationProvider.java index d9b47f8d..d4f48fc5 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/api/internationalization/InternationalizationProvider.java +++ b/VM-Core/src/main/java/com/validation/manager/core/api/internationalization/InternationalizationProvider.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,28 +13,38 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.api.internationalization; - -import java.util.ResourceBundle; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public interface InternationalizationProvider extends LocaleListener { - - /** - * Translate a string. - * - * @param mess String to translate - * @return Translated string or the same string if no translation found. - */ - public String translate(String mess); - - /** - * Get the ResourceBundle. - * - * @return The resource bundle. - */ - public ResourceBundle getResourceBundle(); -} +package com.validation.manager.core.api.internationalization; + +import java.util.Locale; +import java.util.ResourceBundle; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public interface InternationalizationProvider { + + /** + * Translate a string. + * + * @param mess String to translate + * @return Translated string or the same string if no translation found. + */ + public String translate(String mess); + + /** + * Translate a string. + * + * @param mess String to translate + * @param l Locale to translate into. + * @return Translated string or the same string if no translation found. + */ + public String translate(String mess, Locale l); + + /** + * Get the ResourceBundle. + * + * @return The resource bundle. + */ + public ResourceBundle getResourceBundle(); +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/AssigmentType.java b/VM-Core/src/main/java/com/validation/manager/core/db/AssigmentType.java index cb095ed2..9be79510 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/AssigmentType.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/AssigmentType.java @@ -13,131 +13,131 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.CascadeType; -import javax.persistence.Column; -import javax.persistence.Entity; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.Id; -import javax.persistence.Lob; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.OneToMany; -import javax.persistence.Table; -import javax.persistence.TableGenerator; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "assigment_type") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "AssigmentType.findAll", - query = "SELECT a FROM AssigmentType a") - , @NamedQuery(name = "AssigmentType.findById", - query = "SELECT a FROM AssigmentType a WHERE a.id = :id") - , @NamedQuery(name = "AssigmentType.findByFkTable", - query = "SELECT a FROM AssigmentType a WHERE a.fkTable = :fkTable")}) -public class AssigmentType implements Serializable { - - private static final long serialVersionUID = 1L; - @Id - @Basic(optional = false) - @GeneratedValue(strategy = GenerationType.TABLE, - generator = "Assignment_Type_IDGEN") - @TableGenerator(name = "Assignment_Type_IDGEN", table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "assigment_type", - initialValue = 1000, - allocationSize = 1) - @NotNull - @Column(name = "id") - private Integer id; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 255) - @Column(name = "fk_table") - private String fkTable; - @Lob - @Size(max = 2147483647) - @Column(name = "description") - private String description; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "assigmentType") - private List userAssigmentList; - - public AssigmentType() { - } - - public AssigmentType(String fkTable) { - this.fkTable = fkTable; - } - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - public String getFkTable() { - return fkTable; - } - - public void setFkTable(String fkTable) { - this.fkTable = fkTable; - } - - public String getDescription() { - return description; - } - - public void setDescription(String description) { - this.description = description; - } - - @XmlTransient - @JsonIgnore - public List getUserAssigmentList() { - return userAssigmentList; - } - - public void setUserAssigmentList(List userAssigmentList) { - this.userAssigmentList = userAssigmentList; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (id != null ? id.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof AssigmentType)) { - return false; - } - AssigmentType other = (AssigmentType) object; - return (this.id.equals(other.id)); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.AssigmentType[ id=" + id + " ]"; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.CascadeType; +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.Id; +import javax.persistence.Lob; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.OneToMany; +import javax.persistence.Table; +import javax.persistence.TableGenerator; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "assigment_type") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "AssigmentType.findAll", + query = "SELECT a FROM AssigmentType a") + , @NamedQuery(name = "AssigmentType.findById", + query = "SELECT a FROM AssigmentType a WHERE a.id = :id") + , @NamedQuery(name = "AssigmentType.findByFkTable", + query = "SELECT a FROM AssigmentType a WHERE a.fkTable = :fkTable")}) +public class AssigmentType implements Serializable { + + private static final long serialVersionUID = 1L; + @Id + @Basic(optional = false) + @GeneratedValue(strategy = GenerationType.TABLE, + generator = "Assignment_Type_IDGEN") + @TableGenerator(name = "Assignment_Type_IDGEN", table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "assigment_type", + initialValue = 1_000, + allocationSize = 1) + @NotNull + @Column(name = "id") + private Integer id; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 255) + @Column(name = "fk_table") + private String fkTable; + @Lob + @Size(max = 2_147_483_647) + @Column(name = "description") + private String description; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "assigmentType") + private List userAssigmentList; + + public AssigmentType() { + } + + public AssigmentType(String fkTable) { + this.fkTable = fkTable; + } + + public Integer getId() { + return id; + } + + public void setId(Integer id) { + this.id = id; + } + + public String getFkTable() { + return fkTable; + } + + public void setFkTable(String fkTable) { + this.fkTable = fkTable; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + @XmlTransient + @JsonIgnore + public List getUserAssigmentList() { + return userAssigmentList; + } + + public void setUserAssigmentList(List userAssigmentList) { + this.userAssigmentList = userAssigmentList; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (id != null ? id.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof AssigmentType)) { + return false; + } + AssigmentType other = (AssigmentType) object; + return (this.id.equals(other.id)); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.AssigmentType[ id=" + id + " ]"; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/AssignmentStatus.java b/VM-Core/src/main/java/com/validation/manager/core/db/AssignmentStatus.java index 3dc1809c..3db70fa0 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/AssignmentStatus.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/AssignmentStatus.java @@ -13,134 +13,134 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.CascadeType; -import javax.persistence.Column; -import javax.persistence.Entity; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.Id; -import javax.persistence.Lob; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.OneToMany; -import javax.persistence.Table; -import javax.persistence.TableGenerator; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "assignment_status") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "AssignmentStatus.findAll", - query = "SELECT a FROM AssignmentStatus a") - , @NamedQuery(name = "AssignmentStatus.findById", - query = "SELECT a FROM AssignmentStatus a WHERE a.id = :id") - , @NamedQuery(name = "AssignmentStatus.findByName", - query = "SELECT a FROM AssignmentStatus a WHERE a.name = :name")}) -public class AssignmentStatus implements Serializable { - - private static final long serialVersionUID = 1L; - @Id - @Basic(optional = false) - @GeneratedValue(strategy = GenerationType.TABLE, - generator = "Assignment_Status_IDGEN") - @TableGenerator(name = "Assignment_Status_IDGEN", table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "assigment_status", - initialValue = 1000, - allocationSize = 1) - @NotNull - @Column(name = "id") - private Integer id; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 255) - @Column(name = "name") - private String name; - @Basic(optional = false) - @NotNull - @Lob - @Size(max = 2147483647) - @Column(name = "description") - private String description; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "assignmentStatus") - private List userAssigmentList; - - public AssignmentStatus() { - } - - public AssignmentStatus(String name, String description) { - this.name = name; - this.description = description; - } - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - public String getName() { - return name; - } - - public void setName(String name) { - this.name = name; - } - - public String getDescription() { - return description; - } - - public void setDescription(String description) { - this.description = description; - } - - @XmlTransient - @JsonIgnore - public List getUserAssigmentList() { - return userAssigmentList; - } - - public void setUserAssigmentList(List userAssigmentList) { - this.userAssigmentList = userAssigmentList; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (id != null ? id.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof AssignmentStatus)) { - return false; - } - AssignmentStatus other = (AssignmentStatus) object; - return (this.id.equals(other.id)); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.AssignmentStatus[ id=" + id + " ]"; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.CascadeType; +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.Id; +import javax.persistence.Lob; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.OneToMany; +import javax.persistence.Table; +import javax.persistence.TableGenerator; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "assignment_status") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "AssignmentStatus.findAll", + query = "SELECT a FROM AssignmentStatus a") + , @NamedQuery(name = "AssignmentStatus.findById", + query = "SELECT a FROM AssignmentStatus a WHERE a.id = :id") + , @NamedQuery(name = "AssignmentStatus.findByName", + query = "SELECT a FROM AssignmentStatus a WHERE a.name = :name")}) +public class AssignmentStatus implements Serializable { + + private static final long serialVersionUID = 1L; + @Id + @Basic(optional = false) + @GeneratedValue(strategy = GenerationType.TABLE, + generator = "Assignment_Status_IDGEN") + @TableGenerator(name = "Assignment_Status_IDGEN", table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "assigment_status", + initialValue = 1_000, + allocationSize = 1) + @NotNull + @Column(name = "id") + private Integer id; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 255) + @Column(name = "name") + private String name; + @Basic(optional = false) + @NotNull + @Lob + @Size(max = 2_147_483_647) + @Column(name = "description") + private String description; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "assignmentStatus") + private List userAssigmentList; + + public AssignmentStatus() { + } + + public AssignmentStatus(String name, String description) { + this.name = name; + this.description = description; + } + + public Integer getId() { + return id; + } + + public void setId(Integer id) { + this.id = id; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + @XmlTransient + @JsonIgnore + public List getUserAssigmentList() { + return userAssigmentList; + } + + public void setUserAssigmentList(List userAssigmentList) { + this.userAssigmentList = userAssigmentList; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (id != null ? id.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof AssignmentStatus)) { + return false; + } + AssignmentStatus other = (AssignmentStatus) object; + return (this.id.equals(other.id)); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.AssignmentStatus[ id=" + id + " ]"; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/Attachment.java b/VM-Core/src/main/java/com/validation/manager/core/db/Attachment.java index 781a7810..cace5615 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/Attachment.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/Attachment.java @@ -13,160 +13,160 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import java.util.List; -import javax.persistence.CascadeType; -import javax.persistence.Column; -import javax.persistence.EmbeddedId; -import javax.persistence.Entity; -import javax.persistence.JoinColumn; -import javax.persistence.Lob; -import javax.persistence.ManyToOne; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.OneToMany; -import javax.persistence.Table; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "attachment") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "Attachment.findAll", - query = "SELECT a FROM Attachment a") - , @NamedQuery(name = "Attachment.findById", - query = "SELECT a FROM Attachment a WHERE a.attachmentPK.id = :id") - , @NamedQuery(name = "Attachment.findByAttachmentTypeId", - query = "SELECT a FROM Attachment a WHERE a.attachmentPK.attachmentTypeId = :attachmentTypeId") - , @NamedQuery(name = "Attachment.findByStringValue", - query = "SELECT a FROM Attachment a WHERE a.stringValue = :stringValue") - , @NamedQuery(name = "Attachment.findByFileName", - query = "SELECT a FROM Attachment a WHERE a.fileName = :fileName")}) -public class Attachment implements Serializable { - - private static final long serialVersionUID = 1L; - @EmbeddedId - protected AttachmentPK attachmentPK; - @Size(max = 255) - @Column(name = "string_value") - private String stringValue; - @Lob - @Column(name = "file") - private byte[] file; - @Lob - @Size(max = 2147483647) - @Column(name = "TEXT_VALUE") - private String textValue; - @Size(max = 255) - @Column(name = "file_name") - private String fileName; - @JoinColumn(name = "attachment_type_id", referencedColumnName = "id", - insertable = false, updatable = false) - @ManyToOne(optional = false) - private AttachmentType attachmentType; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "attachment") - private List executionStepHasAttachmentList; - - public Attachment() { - } - - public Attachment(AttachmentPK attachmentPK) { - this.attachmentPK = attachmentPK; - } - - public Attachment(int id, int attachmentTypeId) { - this.attachmentPK = new AttachmentPK(id, attachmentTypeId); - } - - public AttachmentPK getAttachmentPK() { - return attachmentPK; - } - - public void setAttachmentPK(AttachmentPK attachmentPK) { - this.attachmentPK = attachmentPK; - } - - public String getStringValue() { - return stringValue; - } - - public void setStringValue(String stringValue) { - this.stringValue = stringValue; - } - - public String getTextValue() { - return textValue; - } - - public void setTextValue(String textValue) { - this.textValue = textValue; - } - - public String getFileName() { - return fileName; - } - - public void setFileName(String fileName) { - this.fileName = fileName; - } - - public AttachmentType getAttachmentType() { - return attachmentType; - } - - public void setAttachmentType(AttachmentType attachmentType) { - this.attachmentType = attachmentType; - } - - @XmlTransient - @JsonIgnore - public List getExecutionStepHasAttachmentList() { - return executionStepHasAttachmentList; - } - - public void setExecutionStepHasAttachmentList(List executionStepHasAttachmentList) { - this.executionStepHasAttachmentList = executionStepHasAttachmentList; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (attachmentPK != null ? attachmentPK.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof Attachment)) { - return false; - } - Attachment other = (Attachment) object; - return !((this.attachmentPK == null && other.attachmentPK != null) - || (this.attachmentPK != null - && !this.attachmentPK.equals(other.attachmentPK))); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.Attachment[ attachmentPK=" - + attachmentPK + " ]"; - } - - public byte[] getFile() { - return file; - } - - public void setFile(byte[] file) { - this.file = file; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import java.util.List; +import javax.persistence.CascadeType; +import javax.persistence.Column; +import javax.persistence.EmbeddedId; +import javax.persistence.Entity; +import javax.persistence.JoinColumn; +import javax.persistence.Lob; +import javax.persistence.ManyToOne; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.OneToMany; +import javax.persistence.Table; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "attachment") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "Attachment.findAll", + query = "SELECT a FROM Attachment a") + , @NamedQuery(name = "Attachment.findById", + query = "SELECT a FROM Attachment a WHERE a.attachmentPK.id = :id") + , @NamedQuery(name = "Attachment.findByAttachmentTypeId", + query = "SELECT a FROM Attachment a WHERE a.attachmentPK.attachmentTypeId = :attachmentTypeId") + , @NamedQuery(name = "Attachment.findByStringValue", + query = "SELECT a FROM Attachment a WHERE a.stringValue = :stringValue") + , @NamedQuery(name = "Attachment.findByFileName", + query = "SELECT a FROM Attachment a WHERE a.fileName = :fileName")}) +public class Attachment implements Serializable { + + private static final long serialVersionUID = 1L; + @EmbeddedId + protected AttachmentPK attachmentPK; + @Size(max = 255) + @Column(name = "string_value") + private String stringValue; + @Lob + @Column(name = "file") + private byte[] file; + @Lob + @Size(max = 2_147_483_647) + @Column(name = "TEXT_VALUE") + private String textValue; + @Size(max = 255) + @Column(name = "file_name") + private String fileName; + @JoinColumn(name = "attachment_type_id", referencedColumnName = "id", + insertable = false, updatable = false) + @ManyToOne(optional = false) + private AttachmentType attachmentType; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "attachment") + private List executionStepHasAttachmentList; + + public Attachment() { + } + + public Attachment(AttachmentPK attachmentPK) { + this.attachmentPK = attachmentPK; + } + + public Attachment(int id, int attachmentTypeId) { + this.attachmentPK = new AttachmentPK(id, attachmentTypeId); + } + + public AttachmentPK getAttachmentPK() { + return attachmentPK; + } + + public void setAttachmentPK(AttachmentPK attachmentPK) { + this.attachmentPK = attachmentPK; + } + + public String getStringValue() { + return stringValue; + } + + public void setStringValue(String stringValue) { + this.stringValue = stringValue; + } + + public String getTextValue() { + return textValue; + } + + public void setTextValue(String textValue) { + this.textValue = textValue; + } + + public String getFileName() { + return fileName; + } + + public void setFileName(String fileName) { + this.fileName = fileName; + } + + public AttachmentType getAttachmentType() { + return attachmentType; + } + + public void setAttachmentType(AttachmentType attachmentType) { + this.attachmentType = attachmentType; + } + + @XmlTransient + @JsonIgnore + public List getExecutionStepHasAttachmentList() { + return executionStepHasAttachmentList; + } + + public void setExecutionStepHasAttachmentList(List executionStepHasAttachmentList) { + this.executionStepHasAttachmentList = executionStepHasAttachmentList; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (attachmentPK != null ? attachmentPK.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof Attachment)) { + return false; + } + Attachment other = (Attachment) object; + return !((this.attachmentPK == null && other.attachmentPK != null) + || (this.attachmentPK != null + && !this.attachmentPK.equals(other.attachmentPK))); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.Attachment[ attachmentPK=" + + attachmentPK + " ]"; + } + + public byte[] getFile() { + return file; + } + + public void setFile(byte[] file) { + this.file = file; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/AttachmentType.java b/VM-Core/src/main/java/com/validation/manager/core/db/AttachmentType.java index 247ae686..2015e8f8 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/AttachmentType.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/AttachmentType.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,125 +13,120 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.CascadeType; -import javax.persistence.Column; -import javax.persistence.Entity; -import javax.persistence.Id; -import javax.persistence.Lob; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.OneToMany; -import javax.persistence.Table; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "attachment_type") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "AttachmentType.findAll", - query = "SELECT a FROM AttachmentType a") - , @NamedQuery(name = "AttachmentType.findById", - query = "SELECT a FROM AttachmentType a WHERE a.id = :id") - , @NamedQuery(name = "AttachmentType.findByType", - query = "SELECT a FROM AttachmentType a WHERE a.type = :type")}) -public class AttachmentType implements Serializable { - - private static final long serialVersionUID = 1L; - @Id - @Basic(optional = false) - @NotNull - @Column(name = "id") - private Integer id; - @Lob - @Size(max = 65535) - @Column(name = "description") - private String description; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 255) - @Column(name = "TYPE") - private String type; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "attachmentType") - private List attachmentList; - - public AttachmentType() { - } - - public AttachmentType(Integer id) { - this.id = id; - } - - public AttachmentType(Integer id, String type) { - this.id = id; - this.type = type; - } - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - public String getDescription() { - return description; - } - - public void setDescription(String description) { - this.description = description; - } - - public String getType() { - return type; - } - - public void setType(String type) { - this.type = type; - } - - @XmlTransient - @JsonIgnore - public List getAttachmentList() { - return attachmentList; - } - - public void setAttachmentList(List attachmentList) { - this.attachmentList = attachmentList; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (id != null ? id.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof AttachmentType)) { - return false; - } - AttachmentType other = (AttachmentType) object; - return this.id.equals(other.id); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.AttachmentType[ id=" + id + " ]"; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.CascadeType; +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.Id; +import javax.persistence.Lob; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.OneToMany; +import javax.persistence.Table; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "attachment_type") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "AttachmentType.findAll", + query = "SELECT a FROM AttachmentType a") + , @NamedQuery(name = "AttachmentType.findById", + query = "SELECT a FROM AttachmentType a WHERE a.id = :id") + , @NamedQuery(name = "AttachmentType.findByType", + query = "SELECT a FROM AttachmentType a WHERE a.type = :type")}) +public class AttachmentType implements Serializable { + + private static final long serialVersionUID = 1L; + @Id + @Basic(optional = false) + @NotNull + @Column(name = "id") + private Integer id; + @Lob + @Size(max = 65_535) + @Column(name = "description") + private String description; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 255) + @Column(name = "TYPE") + private String type; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "attachmentType") + private List attachmentList; + + public AttachmentType() { + } + + public AttachmentType(String type) { + this.type = type; + } + + public Integer getId() { + return id; + } + + public void setId(Integer id) { + this.id = id; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public String getType() { + return type; + } + + public void setType(String type) { + this.type = type; + } + + @XmlTransient + @JsonIgnore + public List getAttachmentList() { + return attachmentList; + } + + public void setAttachmentList(List attachmentList) { + this.attachmentList = attachmentList; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (id != null ? id.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof AttachmentType)) { + return false; + } + AttachmentType other = (AttachmentType) object; + return this.id.equals(other.id); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.AttachmentType[ id=" + id + " ]"; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/Baseline.java b/VM-Core/src/main/java/com/validation/manager/core/db/Baseline.java index e6e11160..91a3cc0b 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/Baseline.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/Baseline.java @@ -13,176 +13,176 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import java.util.Date; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.Column; -import javax.persistence.Entity; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.Id; -import javax.persistence.JoinColumn; -import javax.persistence.JoinColumns; -import javax.persistence.JoinTable; -import javax.persistence.Lob; -import javax.persistence.ManyToMany; -import javax.persistence.ManyToOne; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.Table; -import javax.persistence.TableGenerator; -import javax.persistence.Temporal; -import javax.persistence.TemporalType; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "baseline") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "Baseline.findAll", - query = "SELECT b FROM Baseline b") - , @NamedQuery(name = "Baseline.findById", - query = "SELECT b FROM Baseline b WHERE b.id = :id") - , @NamedQuery(name = "Baseline.findByCreationDate", - query = "SELECT b FROM Baseline b WHERE b.creationDate = :creationDate") - , @NamedQuery(name = "Baseline.findByBaselineName", - query = "SELECT b FROM Baseline b WHERE b.baselineName = :baselineName")}) -public class Baseline implements Serializable { - - private static final long serialVersionUID = 1L; - @Id - @Basic(optional = false) - @NotNull - @Column(name = "id") - @GeneratedValue(strategy = GenerationType.TABLE, - generator = "Baseline_IDGEN") - @TableGenerator(name = "Baseline_IDGEN", table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "baseline", - initialValue = 1, - allocationSize = 1) - private Integer id; - @Basic(optional = false) - @NotNull - @Column(name = "creation_date") - @Temporal(TemporalType.TIMESTAMP) - private Date creationDate; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 255) - @Column(name = "baseline_name") - private String baselineName; - @Lob - @Size(max = 2147483647) - @Column(name = "description") - private String description; - @JoinTable(name = "baseline_has_history", joinColumns = { - @JoinColumn(name = "baseline_id", referencedColumnName = "id")}, inverseJoinColumns = { - @JoinColumn(name = "history_id", referencedColumnName = "id")}) - @ManyToMany - private List historyList; - @JoinColumns({ - @JoinColumn(name = "requirement_spec_id", referencedColumnName = "id") - , @JoinColumn(name = "requirement_spec_project_id", referencedColumnName = "project_id") - , @JoinColumn(name = "requirement_spec_spec_level_id", referencedColumnName = "spec_level_id")}) - @ManyToOne(optional = false) - private RequirementSpec requirementSpec; - - public Baseline() { - } - - public Baseline(Date creationDate, String baselineName) { - this.creationDate = creationDate; - this.baselineName = baselineName; - } - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - public Date getCreationDate() { - return creationDate; - } - - public void setCreationDate(Date creationDate) { - this.creationDate = creationDate; - } - - public String getBaselineName() { - return baselineName; - } - - public void setBaselineName(String baselineName) { - this.baselineName = baselineName; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (id != null ? id.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof Baseline)) { - return false; - } - Baseline other = (Baseline) object; - return this.id.equals(other.id); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.Baseline[ id=" + id + " ]"; - } - - /** - * @return the description - */ - public String getDescription() { - return description; - } - - /** - * @param description the description to set - */ - public void setDescription(String description) { - this.description = description; - } - - @XmlTransient - @JsonIgnore - public List getHistoryList() { - return historyList; - } - - public void setHistoryList(List historyList) { - this.historyList = historyList; - } - - public RequirementSpec getRequirementSpec() { - return requirementSpec; - } - - public void setRequirementSpec(RequirementSpec requirementSpec) { - this.requirementSpec = requirementSpec; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import java.util.Date; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.Id; +import javax.persistence.JoinColumn; +import javax.persistence.JoinColumns; +import javax.persistence.JoinTable; +import javax.persistence.Lob; +import javax.persistence.ManyToMany; +import javax.persistence.ManyToOne; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.Table; +import javax.persistence.TableGenerator; +import javax.persistence.Temporal; +import javax.persistence.TemporalType; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "baseline") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "Baseline.findAll", + query = "SELECT b FROM Baseline b") + , @NamedQuery(name = "Baseline.findById", + query = "SELECT b FROM Baseline b WHERE b.id = :id") + , @NamedQuery(name = "Baseline.findByCreationDate", + query = "SELECT b FROM Baseline b WHERE b.creationDate = :creationDate") + , @NamedQuery(name = "Baseline.findByBaselineName", + query = "SELECT b FROM Baseline b WHERE b.baselineName = :baselineName")}) +public class Baseline implements Serializable { + + private static final long serialVersionUID = 1L; + @Id + @Basic(optional = false) + @NotNull + @Column(name = "id") + @GeneratedValue(strategy = GenerationType.TABLE, + generator = "Baseline_IDGEN") + @TableGenerator(name = "Baseline_IDGEN", table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "baseline", + initialValue = 1, + allocationSize = 1) + private Integer id; + @Basic(optional = false) + @NotNull + @Column(name = "creation_date") + @Temporal(TemporalType.TIMESTAMP) + private Date creationDate; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 255) + @Column(name = "baseline_name") + private String baselineName; + @Lob + @Size(max = 2_147_483_647) + @Column(name = "description") + private String description; + @JoinTable(name = "baseline_has_history", joinColumns = { + @JoinColumn(name = "baseline_id", referencedColumnName = "id")}, inverseJoinColumns = { + @JoinColumn(name = "history_id", referencedColumnName = "id")}) + @ManyToMany + private List historyList; + @JoinColumns({ + @JoinColumn(name = "requirement_spec_id", referencedColumnName = "id") + , @JoinColumn(name = "requirement_spec_project_id", referencedColumnName = "project_id") + , @JoinColumn(name = "requirement_spec_spec_level_id", referencedColumnName = "spec_level_id")}) + @ManyToOne(optional = false) + private RequirementSpec requirementSpec; + + public Baseline() { + } + + public Baseline(Date creationDate, String baselineName) { + this.creationDate = creationDate; + this.baselineName = baselineName; + } + + public Integer getId() { + return id; + } + + public void setId(Integer id) { + this.id = id; + } + + public Date getCreationDate() { + return creationDate; + } + + public void setCreationDate(Date creationDate) { + this.creationDate = creationDate; + } + + public String getBaselineName() { + return baselineName; + } + + public void setBaselineName(String baselineName) { + this.baselineName = baselineName; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (id != null ? id.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof Baseline)) { + return false; + } + Baseline other = (Baseline) object; + return this.id.equals(other.id); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.Baseline[ id=" + id + " ]"; + } + + /** + * @return the description + */ + public String getDescription() { + return description; + } + + /** + * @param description the description to set + */ + public void setDescription(String description) { + this.description = description; + } + + @XmlTransient + @JsonIgnore + public List getHistoryList() { + return historyList; + } + + public void setHistoryList(List historyList) { + this.historyList = historyList; + } + + public RequirementSpec getRequirementSpec() { + return requirementSpec; + } + + public void setRequirementSpec(RequirementSpec requirementSpec) { + this.requirementSpec = requirementSpec; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/Cause.java b/VM-Core/src/main/java/com/validation/manager/core/db/Cause.java index d3bd4036..6b99ceb7 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/Cause.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/Cause.java @@ -13,140 +13,140 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.Column; -import javax.persistence.Entity; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.Id; -import javax.persistence.JoinColumn; -import javax.persistence.JoinTable; -import javax.persistence.Lob; -import javax.persistence.ManyToMany; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.Table; -import javax.persistence.TableGenerator; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "cause") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "Cause.findAll", - query = "SELECT c FROM Cause c") - , @NamedQuery(name = "Cause.findById", - query = "SELECT c FROM Cause c WHERE c.id = :id") - , @NamedQuery(name = "Cause.findByName", - query = "SELECT c FROM Cause c WHERE c.name = :name")}) -public class Cause implements Serializable { - - private static final long serialVersionUID = 1L; - @Id - @Basic(optional = false) - @GeneratedValue(strategy = GenerationType.TABLE, generator = "CauseGen") - @TableGenerator(name = "CauseGen", table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "cause", - allocationSize = 1, - initialValue = 1000) - @Column(name = "id") - private Integer id; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 255) - @Column(name = "name") - private String name; - @Basic(optional = false) - @NotNull - @Lob - @Size(min = 1, max = 65535) - @Column(name = "description") - private String description; - @JoinTable(name = "risk_item_has_cause", joinColumns = { - @JoinColumn(name = "cause_id", referencedColumnName = "id")}, - inverseJoinColumns = { - @JoinColumn(name = "risk_item_id", referencedColumnName = "id") - , @JoinColumn(name = "risk_item_FMEA_id", - referencedColumnName = "FMEA_id")}) - @ManyToMany - private List riskItemList; - - public Cause() { - } - - public Cause(String name, String description) { - this.name = name; - this.description = description; - } - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - public String getName() { - return name; - } - - public void setName(String name) { - this.name = name; - } - - public String getDescription() { - return description; - } - - public void setDescription(String description) { - this.description = description; - } - - @XmlTransient - @JsonIgnore - public List getRiskItemList() { - return riskItemList; - } - - public void setRiskItemList(List riskItemList) { - this.riskItemList = riskItemList; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (id != null ? id.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof Cause)) { - return false; - } - Cause other = (Cause) object; - return !((this.id == null && other.id != null) - || (this.id != null && !this.id.equals(other.id))); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.Cause[ id=" + id + " ]"; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.Id; +import javax.persistence.JoinColumn; +import javax.persistence.JoinTable; +import javax.persistence.Lob; +import javax.persistence.ManyToMany; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.Table; +import javax.persistence.TableGenerator; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "cause") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "Cause.findAll", + query = "SELECT c FROM Cause c") + , @NamedQuery(name = "Cause.findById", + query = "SELECT c FROM Cause c WHERE c.id = :id") + , @NamedQuery(name = "Cause.findByName", + query = "SELECT c FROM Cause c WHERE c.name = :name")}) +public class Cause implements Serializable { + + private static final long serialVersionUID = 1L; + @Id + @Basic(optional = false) + @GeneratedValue(strategy = GenerationType.TABLE, generator = "CauseGen") + @TableGenerator(name = "CauseGen", table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "cause", + allocationSize = 1, + initialValue = 1_000) + @Column(name = "id") + private Integer id; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 255) + @Column(name = "name") + private String name; + @Basic(optional = false) + @NotNull + @Lob + @Size(min = 1, max = 65_535) + @Column(name = "description") + private String description; + @JoinTable(name = "risk_item_has_cause", joinColumns = { + @JoinColumn(name = "cause_id", referencedColumnName = "id")}, + inverseJoinColumns = { + @JoinColumn(name = "risk_item_id", referencedColumnName = "id") + , @JoinColumn(name = "risk_item_FMEA_id", + referencedColumnName = "FMEA_id")}) + @ManyToMany + private List riskItemList; + + public Cause() { + } + + public Cause(String name, String description) { + this.name = name; + this.description = description; + } + + public Integer getId() { + return id; + } + + public void setId(Integer id) { + this.id = id; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + @XmlTransient + @JsonIgnore + public List getRiskItemList() { + return riskItemList; + } + + public void setRiskItemList(List riskItemList) { + this.riskItemList = riskItemList; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (id != null ? id.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof Cause)) { + return false; + } + Cause other = (Cause) object; + return !((this.id == null && other.id != null) + || (this.id != null && !this.id.equals(other.id))); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.Cause[ id=" + id + " ]"; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/CorrectiveAction.java b/VM-Core/src/main/java/com/validation/manager/core/db/CorrectiveAction.java index 9baeffe3..62860b2c 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/CorrectiveAction.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/CorrectiveAction.java @@ -13,137 +13,137 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.CascadeType; -import javax.persistence.Column; -import javax.persistence.Entity; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.Id; -import javax.persistence.JoinColumn; -import javax.persistence.JoinTable; -import javax.persistence.Lob; -import javax.persistence.ManyToMany; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.OneToMany; -import javax.persistence.Table; -import javax.persistence.TableGenerator; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "corrective_action") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "CorrectiveAction.findAll", - query = "SELECT c FROM CorrectiveAction c") - , @NamedQuery(name = "CorrectiveAction.findById", - query = "SELECT c FROM CorrectiveAction c WHERE c.id = :id")}) -public class CorrectiveAction implements Serializable { - - @OneToMany(cascade = CascadeType.ALL, mappedBy = "correctiveAction") - private List exceptionHasCorrectiveActionList; - - private static final long serialVersionUID = 1L; - @Id - @Basic(optional = false) - @GeneratedValue(strategy = GenerationType.TABLE, generator = "CAGen") - @TableGenerator(name = "CAGen", table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "corrective_action", - allocationSize = 1, - initialValue = 1000) - @NotNull - @Column(name = "id") - private Integer id; - @Basic(optional = false) - @NotNull - @Lob - @Size(min = 1, max = 65535) - @Column(name = "details") - private String details; - @JoinTable(name = "user_has_corrective_action", joinColumns = { - @JoinColumn(name = "corrective_action_id", - referencedColumnName = "id")}, inverseJoinColumns = { - @JoinColumn(name = "user_id", referencedColumnName = "id")}) - @ManyToMany - private List vmUserList; - - public CorrectiveAction() { - } - - public CorrectiveAction(String details) { - this.details = details; - } - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - public String getDetails() { - return details; - } - - public void setDetails(String details) { - this.details = details; - } - - @XmlTransient - @JsonIgnore - public List getVmUserList() { - return vmUserList; - } - - public void setVmUserList(List vmUserList) { - this.vmUserList = vmUserList; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (id != null ? id.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof CorrectiveAction)) { - return false; - } - CorrectiveAction other = (CorrectiveAction) object; - return this.id.equals(other.id); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.CorrectiveAction[ id=" + id + " ]"; - } - - @XmlTransient - @JsonIgnore - public List getExceptionHasCorrectiveActionList() { - return exceptionHasCorrectiveActionList; - } - - public void setExceptionHasCorrectiveActionList(List exceptionHasCorrectiveActionList) { - this.exceptionHasCorrectiveActionList = exceptionHasCorrectiveActionList; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.CascadeType; +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.Id; +import javax.persistence.JoinColumn; +import javax.persistence.JoinTable; +import javax.persistence.Lob; +import javax.persistence.ManyToMany; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.OneToMany; +import javax.persistence.Table; +import javax.persistence.TableGenerator; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "corrective_action") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "CorrectiveAction.findAll", + query = "SELECT c FROM CorrectiveAction c") + , @NamedQuery(name = "CorrectiveAction.findById", + query = "SELECT c FROM CorrectiveAction c WHERE c.id = :id")}) +public class CorrectiveAction implements Serializable { + + @OneToMany(cascade = CascadeType.ALL, mappedBy = "correctiveAction") + private List exceptionHasCorrectiveActionList; + + private static final long serialVersionUID = 1L; + @Id + @Basic(optional = false) + @GeneratedValue(strategy = GenerationType.TABLE, generator = "CAGen") + @TableGenerator(name = "CAGen", table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "corrective_action", + allocationSize = 1, + initialValue = 1_000) + @NotNull + @Column(name = "id") + private Integer id; + @Basic(optional = false) + @NotNull + @Lob + @Size(min = 1, max = 65_535) + @Column(name = "details") + private String details; + @JoinTable(name = "user_has_corrective_action", joinColumns = { + @JoinColumn(name = "corrective_action_id", + referencedColumnName = "id")}, inverseJoinColumns = { + @JoinColumn(name = "user_id", referencedColumnName = "id")}) + @ManyToMany + private List vmUserList; + + public CorrectiveAction() { + } + + public CorrectiveAction(String details) { + this.details = details; + } + + public Integer getId() { + return id; + } + + public void setId(Integer id) { + this.id = id; + } + + public String getDetails() { + return details; + } + + public void setDetails(String details) { + this.details = details; + } + + @XmlTransient + @JsonIgnore + public List getVmUserList() { + return vmUserList; + } + + public void setVmUserList(List vmUserList) { + this.vmUserList = vmUserList; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (id != null ? id.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof CorrectiveAction)) { + return false; + } + CorrectiveAction other = (CorrectiveAction) object; + return this.id.equals(other.id); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.CorrectiveAction[ id=" + id + " ]"; + } + + @XmlTransient + @JsonIgnore + public List getExceptionHasCorrectiveActionList() { + return exceptionHasCorrectiveActionList; + } + + public void setExceptionHasCorrectiveActionList(List exceptionHasCorrectiveActionList) { + this.exceptionHasCorrectiveActionList = exceptionHasCorrectiveActionList; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/ExecutionResult.java b/VM-Core/src/main/java/com/validation/manager/core/db/ExecutionResult.java index 0e22e234..55f3e4e6 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/ExecutionResult.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/ExecutionResult.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,123 +13,118 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.Column; -import javax.persistence.Entity; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.Id; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.OneToMany; -import javax.persistence.Table; -import javax.persistence.TableGenerator; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "execution_result") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "ExecutionResult.findAll", - query = "SELECT e FROM ExecutionResult e") - , @NamedQuery(name = "ExecutionResult.findById", - query = "SELECT e FROM ExecutionResult e WHERE e.id = :id") - , @NamedQuery(name = "ExecutionResult.findByResultName", - query = "SELECT e FROM ExecutionResult e WHERE e.resultName = :resultName")}) -public class ExecutionResult implements Serializable { - - private static final long serialVersionUID = 1L; - @Id - @Basic(optional = false) - @NotNull - @Column(name = "id") - @GeneratedValue(strategy = GenerationType.TABLE, - generator = "ExecutionResult_IDGEN") - @TableGenerator(name = "ExecutionResult_IDGEN", table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "execution_result", - initialValue = 1, - allocationSize = 1) - private Integer id; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 255) - @Column(name = "result_name") - private String resultName; - @OneToMany(mappedBy = "resultId") - private List executionStepList; - - public ExecutionResult() { - } - - public ExecutionResult(Integer id) { - this.id = id; - } - - public ExecutionResult(Integer id, String resultName) { - this.id = id; - this.resultName = resultName; - } - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - public String getResultName() { - return resultName; - } - - public void setResultName(String resultName) { - this.resultName = resultName; - } - - @XmlTransient - @JsonIgnore - public List getExecutionStepList() { - return executionStepList; - } - - public void setExecutionStepList(List executionStepList) { - this.executionStepList = executionStepList; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (id != null ? id.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof ExecutionResult)) { - return false; - } - ExecutionResult other = (ExecutionResult) object; - return this.id.equals(other.id); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.ExecutionResult[ id=" + id + " ]"; - } - -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.Id; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.OneToMany; +import javax.persistence.Table; +import javax.persistence.TableGenerator; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "execution_result") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "ExecutionResult.findAll", + query = "SELECT e FROM ExecutionResult e") + , @NamedQuery(name = "ExecutionResult.findById", + query = "SELECT e FROM ExecutionResult e WHERE e.id = :id") + , @NamedQuery(name = "ExecutionResult.findByResultName", + query = "SELECT e FROM ExecutionResult e WHERE e.resultName = :resultName")}) +public class ExecutionResult implements Serializable { + + private static final long serialVersionUID = 1L; + @Id + @Basic(optional = false) + @NotNull + @Column(name = "id") + @GeneratedValue(strategy = GenerationType.TABLE, + generator = "ExecutionResult_IDGEN") + @TableGenerator(name = "ExecutionResult_IDGEN", table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "execution_result", + initialValue = 1, + allocationSize = 1) + private Integer id; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 255) + @Column(name = "result_name") + private String resultName; + @OneToMany(mappedBy = "resultId") + private List executionStepList; + + public ExecutionResult() { + } + + public ExecutionResult(String resultName) { + this.resultName = resultName; + } + + public Integer getId() { + return id; + } + + public void setId(Integer id) { + this.id = id; + } + + public String getResultName() { + return resultName; + } + + public void setResultName(String resultName) { + this.resultName = resultName; + } + + @XmlTransient + @JsonIgnore + public List getExecutionStepList() { + return executionStepList; + } + + public void setExecutionStepList(List executionStepList) { + this.executionStepList = executionStepList; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (id != null ? id.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof ExecutionResult)) { + return false; + } + ExecutionResult other = (ExecutionResult) object; + return this.id.equals(other.id); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.ExecutionResult[ id=" + id + " ]"; + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/ExecutionStep.java b/VM-Core/src/main/java/com/validation/manager/core/db/ExecutionStep.java index 7d83e548..f3570a21 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/ExecutionStep.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/ExecutionStep.java @@ -13,365 +13,365 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import java.util.Date; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.CascadeType; -import javax.persistence.Column; -import javax.persistence.EmbeddedId; -import javax.persistence.Entity; -import javax.persistence.JoinColumn; -import javax.persistence.JoinColumns; -import javax.persistence.JoinTable; -import javax.persistence.Lob; -import javax.persistence.ManyToMany; -import javax.persistence.ManyToOne; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.OneToMany; -import javax.persistence.Table; -import javax.persistence.Temporal; -import javax.persistence.TemporalType; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "execution_step") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "ExecutionStep.findAll", - query = "SELECT e FROM ExecutionStep e") - , @NamedQuery(name = "ExecutionStep.findByTestCaseExecutionId", - query = "SELECT e FROM ExecutionStep e WHERE e.executionStepPK.testCaseExecutionId = :testCaseExecutionId") - , @NamedQuery(name = "ExecutionStep.findByStepId", - query = "SELECT e FROM ExecutionStep e WHERE e.executionStepPK.stepId = :stepId") - , @NamedQuery(name = "ExecutionStep.findByStepTestCaseId", - query = "SELECT e FROM ExecutionStep e WHERE e.executionStepPK.stepTestCaseId = :stepTestCaseId") - , @NamedQuery(name = "ExecutionStep.findByExecutionTime", - query = "SELECT e FROM ExecutionStep e WHERE e.executionTime = :executionTime") - , @NamedQuery(name = "ExecutionStep.findByExecutionStart", - query = "SELECT e FROM ExecutionStep e WHERE e.executionStart = :executionStart") - , @NamedQuery(name = "ExecutionStep.findByExecutionEnd", - query = "SELECT e FROM ExecutionStep e WHERE e.executionEnd = :executionEnd") - , @NamedQuery(name = "ExecutionStep.findByAssignedTime", - query = "SELECT e FROM ExecutionStep e WHERE e.assignedTime = :assignedTime") - , @NamedQuery(name = "ExecutionStep.findByLocked", - query = "SELECT e FROM ExecutionStep e WHERE e.locked = :locked") - , @NamedQuery(name = "ExecutionStep.findByReviewed", - query = "SELECT e FROM ExecutionStep e WHERE e.reviewed = :reviewed")}) -public class ExecutionStep implements Serializable { - - private static final long serialVersionUID = 1L; - @EmbeddedId - protected ExecutionStepPK executionStepPK; - // @Max(value=?) @Min(value=?)//if you know range of your decimal fields consider using these annotations to enforce field validation - @Column(name = "execution_time") - private Double executionTime; - @Lob - @Size(max = 2147483647) - @Column(name = "comment") - private String comment; - @Column(name = "execution_start") - @Temporal(TemporalType.TIMESTAMP) - private Date executionStart; - @Column(name = "execution_end") - @Temporal(TemporalType.TIMESTAMP) - private Date executionEnd; - @Column(name = "review_date") - @Temporal(TemporalType.TIMESTAMP) - private Date reviewDate; - @Column(name = "assigned_time") - @Temporal(TemporalType.TIMESTAMP) - private Date assignedTime; - @Basic(optional = false) - @NotNull - @Column(name = "locked") - private boolean locked; - @Basic(optional = false) - @NotNull - @Column(name = "reviewed") - private boolean reviewed; - @JoinColumn(name = "result_id", referencedColumnName = "id") - @ManyToOne - private ExecutionResult resultId; - @JoinColumn(name = "review_result_id", referencedColumnName = "id") - @ManyToOne - private ReviewResult reviewResultId; - @JoinColumn(name = "assignee", referencedColumnName = "id") - @ManyToOne - private VmUser assignee; - @JoinColumn(name = "assigner", referencedColumnName = "id") - @ManyToOne - private VmUser assigner; - @JoinColumn(name = "reviewer", referencedColumnName = "id") - @ManyToOne - private VmUser reviewer; - @JoinColumns({ - @JoinColumn(name = "step_id", referencedColumnName = "id", - insertable = false, updatable = false) - , @JoinColumn(name = "step_test_case_id", - referencedColumnName = "test_case_id", insertable = false, - updatable = false)}) - @ManyToOne(optional = false) - private Step step; - @JoinColumn(name = "test_case_execution_id", referencedColumnName = "id", - insertable = false, updatable = false) - @ManyToOne(optional = false) - private TestCaseExecution testCaseExecution; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "executionStep") - private List executionStepHasAttachmentList; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "executionStep") - private List executionStepHasIssueList; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "executionStep") - private List executionStepHasVmUserList; - @JoinTable(name = "execution_step_has_history", joinColumns = { - @JoinColumn(name = "execution_step_test_case_execution_id", referencedColumnName = "test_case_execution_id") - , @JoinColumn(name = "execution_step_step_id", referencedColumnName = "step_id") - , @JoinColumn(name = "execution_step_step_test_case_id", referencedColumnName = "step_test_case_id")}, inverseJoinColumns = { - @JoinColumn(name = "history_id", referencedColumnName = "id")}) - @ManyToMany - private List historyList; - @JoinColumn(name = "step_history", referencedColumnName = "id") - @ManyToOne(optional = false) - private History stepHistory; - - public ExecutionStep() { - } - - public ExecutionStep(ExecutionStepPK executionStepPK) { - this.executionStepPK = executionStepPK; - } - - public ExecutionStep(ExecutionStepPK executionStepPK, boolean locked, boolean reviewed) { - this.executionStepPK = executionStepPK; - this.locked = locked; - this.reviewed = reviewed; - } - - public ExecutionStep(int testCaseExecutionId, int stepId, int stepTestCaseId) { - this.executionStepPK = new ExecutionStepPK(testCaseExecutionId, - stepId, stepTestCaseId); - } - - public ExecutionStepPK getExecutionStepPK() { - return executionStepPK; - } - - public void setExecutionStepPK(ExecutionStepPK executionStepPK) { - this.executionStepPK = executionStepPK; - } - - public Double getExecutionTime() { - return executionTime; - } - - public void setExecutionTime(Double executionTime) { - this.executionTime = executionTime; - } - - public String getComment() { - return comment; - } - - public void setComment(String comment) { - this.comment = comment; - } - - public Date getExecutionStart() { - return executionStart; - } - - public void setExecutionStart(Date executionStart) { - this.executionStart = executionStart; - } - - public Date getExecutionEnd() { - return executionEnd; - } - - public void setExecutionEnd(Date executionEnd) { - this.executionEnd = executionEnd; - } - - public Date getAssignedTime() { - return assignedTime; - } - - public void setAssignedTime(Date assignedTime) { - this.assignedTime = assignedTime; - } - - public boolean getLocked() { - return locked; - } - - public void setLocked(boolean locked) { - this.locked = locked; - } - - public boolean getReviewed() { - return reviewed; - } - - public void setReviewed(boolean reviewed) { - this.reviewed = reviewed; - } - - public ExecutionResult getResultId() { - return resultId; - } - - public void setResultId(ExecutionResult resultId) { - this.resultId = resultId; - } - - public ReviewResult getReviewResultId() { - return reviewResultId; - } - - public void setReviewResultId(ReviewResult reviewResultId) { - this.reviewResultId = reviewResultId; - } - - public VmUser getAssignee() { - return assignee; - } - - public void setAssignee(VmUser assignee) { - this.assignee = assignee; - } - - public VmUser getAssigner() { - return assigner; - } - - public void setAssigner(VmUser assigner) { - this.assigner = assigner; - } - - public Step getStep() { - return step; - } - - public void setStep(Step step) { - this.step = step; - } - - public TestCaseExecution getTestCaseExecution() { - return testCaseExecution; - } - - public void setTestCaseExecution(TestCaseExecution testCaseExecution) { - this.testCaseExecution = testCaseExecution; - } - - @XmlTransient - @JsonIgnore - public List getExecutionStepHasAttachmentList() { - return executionStepHasAttachmentList; - } - - public void setExecutionStepHasAttachmentList(List executionStepHasAttachmentList) { - this.executionStepHasAttachmentList = executionStepHasAttachmentList; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (executionStepPK != null ? executionStepPK.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof ExecutionStep)) { - return false; - } - ExecutionStep other = (ExecutionStep) object; - return !((this.executionStepPK == null && other.executionStepPK != null) - || (this.executionStepPK != null - && !this.executionStepPK.equals(other.executionStepPK))); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.ExecutionStep[ executionStepPK=" + executionStepPK + " ]"; - } - - @XmlTransient - @JsonIgnore - public List getExecutionStepHasIssueList() { - return executionStepHasIssueList; - } - - public void setExecutionStepHasIssueList(List executionStepHasIssueList) { - this.executionStepHasIssueList = executionStepHasIssueList; - } - - /** - * @return the reviewDate - */ - public Date getReviewDate() { - return reviewDate; - } - - /** - * @param reviewDate the reviewDate to set - */ - public void setReviewDate(Date reviewDate) { - this.reviewDate = reviewDate; - } - - /** - * @return the reviewer - */ - public VmUser getReviewer() { - return reviewer; - } - - /** - * @param reviewer the reviewer to set - */ - public void setReviewer(VmUser reviewer) { - this.reviewer = reviewer; - } - - @XmlTransient - @JsonIgnore - public List getExecutionStepHasVmUserList() { - return executionStepHasVmUserList; - } - - public void setExecutionStepHasVmUserList(List executionStepHasVmUserList) { - this.executionStepHasVmUserList = executionStepHasVmUserList; - } - - @XmlTransient - @JsonIgnore - public List getHistoryList() { - return historyList; - } - - public void setHistoryList(List historyList) { - this.historyList = historyList; - } - - public History getStepHistory() { - return stepHistory; - } - - public void setStepHistory(History stepHistory) { - this.stepHistory = stepHistory; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import java.util.Date; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.CascadeType; +import javax.persistence.Column; +import javax.persistence.EmbeddedId; +import javax.persistence.Entity; +import javax.persistence.JoinColumn; +import javax.persistence.JoinColumns; +import javax.persistence.JoinTable; +import javax.persistence.Lob; +import javax.persistence.ManyToMany; +import javax.persistence.ManyToOne; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.OneToMany; +import javax.persistence.Table; +import javax.persistence.Temporal; +import javax.persistence.TemporalType; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "execution_step") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "ExecutionStep.findAll", + query = "SELECT e FROM ExecutionStep e") + , @NamedQuery(name = "ExecutionStep.findByTestCaseExecutionId", + query = "SELECT e FROM ExecutionStep e WHERE e.executionStepPK.testCaseExecutionId = :testCaseExecutionId") + , @NamedQuery(name = "ExecutionStep.findByStepId", + query = "SELECT e FROM ExecutionStep e WHERE e.executionStepPK.stepId = :stepId") + , @NamedQuery(name = "ExecutionStep.findByStepTestCaseId", + query = "SELECT e FROM ExecutionStep e WHERE e.executionStepPK.stepTestCaseId = :stepTestCaseId") + , @NamedQuery(name = "ExecutionStep.findByExecutionTime", + query = "SELECT e FROM ExecutionStep e WHERE e.executionTime = :executionTime") + , @NamedQuery(name = "ExecutionStep.findByExecutionStart", + query = "SELECT e FROM ExecutionStep e WHERE e.executionStart = :executionStart") + , @NamedQuery(name = "ExecutionStep.findByExecutionEnd", + query = "SELECT e FROM ExecutionStep e WHERE e.executionEnd = :executionEnd") + , @NamedQuery(name = "ExecutionStep.findByAssignedTime", + query = "SELECT e FROM ExecutionStep e WHERE e.assignedTime = :assignedTime") + , @NamedQuery(name = "ExecutionStep.findByLocked", + query = "SELECT e FROM ExecutionStep e WHERE e.locked = :locked") + , @NamedQuery(name = "ExecutionStep.findByReviewed", + query = "SELECT e FROM ExecutionStep e WHERE e.reviewed = :reviewed")}) +public class ExecutionStep implements Serializable { + + private static final long serialVersionUID = 1L; + @EmbeddedId + protected ExecutionStepPK executionStepPK; + // @Max(value=?) @Min(value=?)//if you know range of your decimal fields consider using these annotations to enforce field validation + @Column(name = "execution_time") + private Double executionTime; + @Lob + @Size(max = 2_147_483_647) + @Column(name = "comment") + private String comment; + @Column(name = "execution_start") + @Temporal(TemporalType.TIMESTAMP) + private Date executionStart; + @Column(name = "execution_end") + @Temporal(TemporalType.TIMESTAMP) + private Date executionEnd; + @Column(name = "review_date") + @Temporal(TemporalType.TIMESTAMP) + private Date reviewDate; + @Column(name = "assigned_time") + @Temporal(TemporalType.TIMESTAMP) + private Date assignedTime; + @Basic(optional = false) + @NotNull + @Column(name = "locked") + private boolean locked; + @Basic(optional = false) + @NotNull + @Column(name = "reviewed") + private boolean reviewed; + @JoinColumn(name = "result_id", referencedColumnName = "id") + @ManyToOne + private ExecutionResult resultId; + @JoinColumn(name = "review_result_id", referencedColumnName = "id") + @ManyToOne + private ReviewResult reviewResultId; + @JoinColumn(name = "assignee", referencedColumnName = "id") + @ManyToOne + private VmUser assignee; + @JoinColumn(name = "assigner", referencedColumnName = "id") + @ManyToOne + private VmUser assigner; + @JoinColumn(name = "reviewer", referencedColumnName = "id") + @ManyToOne + private VmUser reviewer; + @JoinColumns({ + @JoinColumn(name = "step_id", referencedColumnName = "id", + insertable = false, updatable = false) + , @JoinColumn(name = "step_test_case_id", + referencedColumnName = "test_case_id", insertable = false, + updatable = false)}) + @ManyToOne(optional = false) + private Step step; + @JoinColumn(name = "test_case_execution_id", referencedColumnName = "id", + insertable = false, updatable = false) + @ManyToOne(optional = false) + private TestCaseExecution testCaseExecution; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "executionStep") + private List executionStepHasAttachmentList; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "executionStep") + private List executionStepHasIssueList; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "executionStep") + private List executionStepHasVmUserList; + @JoinTable(name = "execution_step_has_history", joinColumns = { + @JoinColumn(name = "execution_step_test_case_execution_id", referencedColumnName = "test_case_execution_id") + , @JoinColumn(name = "execution_step_step_id", referencedColumnName = "step_id") + , @JoinColumn(name = "execution_step_step_test_case_id", referencedColumnName = "step_test_case_id")}, inverseJoinColumns = { + @JoinColumn(name = "history_id", referencedColumnName = "id")}) + @ManyToMany + private List historyList; + @JoinColumn(name = "step_history", referencedColumnName = "id") + @ManyToOne(optional = false) + private History stepHistory; + + public ExecutionStep() { + } + + public ExecutionStep(ExecutionStepPK executionStepPK) { + this.executionStepPK = executionStepPK; + } + + public ExecutionStep(ExecutionStepPK executionStepPK, boolean locked, boolean reviewed) { + this.executionStepPK = executionStepPK; + this.locked = locked; + this.reviewed = reviewed; + } + + public ExecutionStep(int testCaseExecutionId, int stepId, int stepTestCaseId) { + this.executionStepPK = new ExecutionStepPK(testCaseExecutionId, + stepId, stepTestCaseId); + } + + public ExecutionStepPK getExecutionStepPK() { + return executionStepPK; + } + + public void setExecutionStepPK(ExecutionStepPK executionStepPK) { + this.executionStepPK = executionStepPK; + } + + public Double getExecutionTime() { + return executionTime; + } + + public void setExecutionTime(Double executionTime) { + this.executionTime = executionTime; + } + + public String getComment() { + return comment; + } + + public void setComment(String comment) { + this.comment = comment; + } + + public Date getExecutionStart() { + return executionStart; + } + + public void setExecutionStart(Date executionStart) { + this.executionStart = executionStart; + } + + public Date getExecutionEnd() { + return executionEnd; + } + + public void setExecutionEnd(Date executionEnd) { + this.executionEnd = executionEnd; + } + + public Date getAssignedTime() { + return assignedTime; + } + + public void setAssignedTime(Date assignedTime) { + this.assignedTime = assignedTime; + } + + public boolean getLocked() { + return locked; + } + + public void setLocked(boolean locked) { + this.locked = locked; + } + + public boolean getReviewed() { + return reviewed; + } + + public void setReviewed(boolean reviewed) { + this.reviewed = reviewed; + } + + public ExecutionResult getResultId() { + return resultId; + } + + public void setResultId(ExecutionResult resultId) { + this.resultId = resultId; + } + + public ReviewResult getReviewResultId() { + return reviewResultId; + } + + public void setReviewResultId(ReviewResult reviewResultId) { + this.reviewResultId = reviewResultId; + } + + public VmUser getAssignee() { + return assignee; + } + + public void setAssignee(VmUser assignee) { + this.assignee = assignee; + } + + public VmUser getAssigner() { + return assigner; + } + + public void setAssigner(VmUser assigner) { + this.assigner = assigner; + } + + public Step getStep() { + return step; + } + + public void setStep(Step step) { + this.step = step; + } + + public TestCaseExecution getTestCaseExecution() { + return testCaseExecution; + } + + public void setTestCaseExecution(TestCaseExecution testCaseExecution) { + this.testCaseExecution = testCaseExecution; + } + + @XmlTransient + @JsonIgnore + public List getExecutionStepHasAttachmentList() { + return executionStepHasAttachmentList; + } + + public void setExecutionStepHasAttachmentList(List executionStepHasAttachmentList) { + this.executionStepHasAttachmentList = executionStepHasAttachmentList; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (executionStepPK != null ? executionStepPK.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof ExecutionStep)) { + return false; + } + ExecutionStep other = (ExecutionStep) object; + return !((this.executionStepPK == null && other.executionStepPK != null) + || (this.executionStepPK != null + && !this.executionStepPK.equals(other.executionStepPK))); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.ExecutionStep[ executionStepPK=" + executionStepPK + " ]"; + } + + @XmlTransient + @JsonIgnore + public List getExecutionStepHasIssueList() { + return executionStepHasIssueList; + } + + public void setExecutionStepHasIssueList(List executionStepHasIssueList) { + this.executionStepHasIssueList = executionStepHasIssueList; + } + + /** + * @return the reviewDate + */ + public Date getReviewDate() { + return reviewDate; + } + + /** + * @param reviewDate the reviewDate to set + */ + public void setReviewDate(Date reviewDate) { + this.reviewDate = reviewDate; + } + + /** + * @return the reviewer + */ + public VmUser getReviewer() { + return reviewer; + } + + /** + * @param reviewer the reviewer to set + */ + public void setReviewer(VmUser reviewer) { + this.reviewer = reviewer; + } + + @XmlTransient + @JsonIgnore + public List getExecutionStepHasVmUserList() { + return executionStepHasVmUserList; + } + + public void setExecutionStepHasVmUserList(List executionStepHasVmUserList) { + this.executionStepHasVmUserList = executionStepHasVmUserList; + } + + @XmlTransient + @JsonIgnore + public List getHistoryList() { + return historyList; + } + + public void setHistoryList(List historyList) { + this.historyList = historyList; + } + + public History getStepHistory() { + return stepHistory; + } + + public void setStepHistory(History stepHistory) { + this.stepHistory = stepHistory; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/FailureMode.java b/VM-Core/src/main/java/com/validation/manager/core/db/FailureMode.java index 0da6dbee..4b1714cd 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/FailureMode.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/FailureMode.java @@ -13,140 +13,140 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.Column; -import javax.persistence.Entity; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.Id; -import javax.persistence.JoinColumn; -import javax.persistence.JoinTable; -import javax.persistence.Lob; -import javax.persistence.ManyToMany; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.Table; -import javax.persistence.TableGenerator; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "failure_mode") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "FailureMode.findAll", - query = "SELECT f FROM FailureMode f") - , @NamedQuery(name = "FailureMode.findById", - query = "SELECT f FROM FailureMode f WHERE f.id = :id") - , @NamedQuery(name = "FailureMode.findByName", - query = "SELECT f FROM FailureMode f WHERE f.name = :name")}) -public class FailureMode implements Serializable { - - private static final long serialVersionUID = 1L; - @Id - @GeneratedValue(strategy = GenerationType.TABLE, generator = "FMGen") - @TableGenerator(name = "FMGen", table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "failure_mode", - allocationSize = 1, - initialValue = 1000) - @Basic(optional = false) - @Column(name = "id") - private Integer id; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 255) - @Column(name = "name") - private String name; - @Basic(optional = false) - @NotNull - @Lob - @Size(min = 1, max = 65535) - @Column(name = "description") - private String description; - @JoinTable(name = "risk_item_has_failure_mode", joinColumns = { - @JoinColumn(name = "failure_mode_id", referencedColumnName = "id")}, - inverseJoinColumns = { - @JoinColumn(name = "risk_item_id", referencedColumnName = "id") - , @JoinColumn(name = "risk_item_FMEA_id", - referencedColumnName = "FMEA_id")}) - @ManyToMany - private List riskItemList; - - public FailureMode() { - } - - public FailureMode(String name, String description) { - this.name = name; - this.description = description; - } - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - public String getName() { - return name; - } - - public void setName(String name) { - this.name = name; - } - - public String getDescription() { - return description; - } - - public void setDescription(String description) { - this.description = description; - } - - @XmlTransient - @JsonIgnore - public List getRiskItemList() { - return riskItemList; - } - - public void setRiskItemList(List riskItemList) { - this.riskItemList = riskItemList; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (id != null ? id.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof FailureMode)) { - return false; - } - FailureMode other = (FailureMode) object; - return !((this.id == null && other.id != null) - || (this.id != null && !this.id.equals(other.id))); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.FailureMode[ id=" + id + " ]"; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.Id; +import javax.persistence.JoinColumn; +import javax.persistence.JoinTable; +import javax.persistence.Lob; +import javax.persistence.ManyToMany; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.Table; +import javax.persistence.TableGenerator; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "failure_mode") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "FailureMode.findAll", + query = "SELECT f FROM FailureMode f") + , @NamedQuery(name = "FailureMode.findById", + query = "SELECT f FROM FailureMode f WHERE f.id = :id") + , @NamedQuery(name = "FailureMode.findByName", + query = "SELECT f FROM FailureMode f WHERE f.name = :name")}) +public class FailureMode implements Serializable { + + private static final long serialVersionUID = 1L; + @Id + @GeneratedValue(strategy = GenerationType.TABLE, generator = "FMGen") + @TableGenerator(name = "FMGen", table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "failure_mode", + allocationSize = 1, + initialValue = 1_000) + @Basic(optional = false) + @Column(name = "id") + private Integer id; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 255) + @Column(name = "name") + private String name; + @Basic(optional = false) + @NotNull + @Lob + @Size(min = 1, max = 65_535) + @Column(name = "description") + private String description; + @JoinTable(name = "risk_item_has_failure_mode", joinColumns = { + @JoinColumn(name = "failure_mode_id", referencedColumnName = "id")}, + inverseJoinColumns = { + @JoinColumn(name = "risk_item_id", referencedColumnName = "id") + , @JoinColumn(name = "risk_item_FMEA_id", + referencedColumnName = "FMEA_id")}) + @ManyToMany + private List riskItemList; + + public FailureMode() { + } + + public FailureMode(String name, String description) { + this.name = name; + this.description = description; + } + + public Integer getId() { + return id; + } + + public void setId(Integer id) { + this.id = id; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + @XmlTransient + @JsonIgnore + public List getRiskItemList() { + return riskItemList; + } + + public void setRiskItemList(List riskItemList) { + this.riskItemList = riskItemList; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (id != null ? id.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof FailureMode)) { + return false; + } + FailureMode other = (FailureMode) object; + return !((this.id == null && other.id != null) + || (this.id != null && !this.id.equals(other.id))); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.FailureMode[ id=" + id + " ]"; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/Fmea.java b/VM-Core/src/main/java/com/validation/manager/core/db/Fmea.java index edd94860..d0472f58 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/Fmea.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/Fmea.java @@ -13,172 +13,172 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.CascadeType; -import javax.persistence.Column; -import javax.persistence.Entity; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.Id; -import javax.persistence.JoinColumn; -import javax.persistence.JoinTable; -import javax.persistence.ManyToMany; -import javax.persistence.ManyToOne; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.OneToMany; -import javax.persistence.Table; -import javax.persistence.TableGenerator; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "fmea") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "Fmea.findAll", query = "SELECT f FROM Fmea f") - , @NamedQuery(name = "Fmea.findById", query = "SELECT f FROM Fmea f " - + "WHERE f.id = :id") - , @NamedQuery(name = "Fmea.findByName", query = "SELECT f FROM Fmea f " - + "WHERE f.name = :name") - , @NamedQuery(name = "Fmea.findByDescription", query = "SELECT f FROM " - + "Fmea f WHERE f.description = :description")}) -public class Fmea implements Serializable { - - private static final long serialVersionUID = 1L; - @Id - @Basic(optional = false) - @NotNull - @GeneratedValue(strategy = GenerationType.TABLE, generator = "FMEAGen") - @TableGenerator(name = "FMEAGen", table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "fmea", - allocationSize = 1, - initialValue = 1000) - @Column(name = "id") - private Integer id; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 45) - @Column(name = "name") - private String name; - @Size(max = 45) - @Column(name = "description") - private String description; - @JoinTable(name = "fmea_has_risk_category", joinColumns = { - @JoinColumn(name = "FMEA_id", referencedColumnName = "id")}, - inverseJoinColumns = { - @JoinColumn(name = "risk_category_id", referencedColumnName = "id")}) - @ManyToMany - private List riskCategoryList; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "fmea") - private List riskItemList; - @OneToMany(mappedBy = "parent") - private List fmeaList; - @JoinColumn(name = "parent", referencedColumnName = "id") - @ManyToOne - private Fmea parent; - - public Fmea() { - } - - public Fmea(String name) { - this.name = name; - } - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - public String getName() { - return name; - } - - public void setName(String name) { - this.name = name; - } - - public String getDescription() { - return description; - } - - public void setDescription(String description) { - this.description = description; - } - - @XmlTransient - @JsonIgnore - public List getRiskCategoryList() { - return riskCategoryList; - } - - public void setRiskCategoryList(List riskCategoryList) { - this.riskCategoryList = riskCategoryList; - } - - @XmlTransient - @JsonIgnore - public List getRiskItemList() { - return riskItemList; - } - - public void setRiskItemList(List riskItemList) { - this.riskItemList = riskItemList; - } - - @XmlTransient - @JsonIgnore - public List getFmeaList() { - return fmeaList; - } - - public void setFmeaList(List fmeaList) { - this.fmeaList = fmeaList; - } - - public Fmea getParent() { - return parent; - } - - public void setParent(Fmea parent) { - this.parent = parent; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (id != null ? id.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof Fmea)) { - return false; - } - Fmea other = (Fmea) object; - return this.id.equals(other.id); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.Fmea[ id=" + id + " ]"; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.CascadeType; +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.Id; +import javax.persistence.JoinColumn; +import javax.persistence.JoinTable; +import javax.persistence.ManyToMany; +import javax.persistence.ManyToOne; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.OneToMany; +import javax.persistence.Table; +import javax.persistence.TableGenerator; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "fmea") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "Fmea.findAll", query = "SELECT f FROM Fmea f") + , @NamedQuery(name = "Fmea.findById", query = "SELECT f FROM Fmea f " + + "WHERE f.id = :id") + , @NamedQuery(name = "Fmea.findByName", query = "SELECT f FROM Fmea f " + + "WHERE f.name = :name") + , @NamedQuery(name = "Fmea.findByDescription", query = "SELECT f FROM " + + "Fmea f WHERE f.description = :description")}) +public class Fmea implements Serializable { + + private static final long serialVersionUID = 1L; + @Id + @Basic(optional = false) + @NotNull + @GeneratedValue(strategy = GenerationType.TABLE, generator = "FMEAGen") + @TableGenerator(name = "FMEAGen", table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "fmea", + allocationSize = 1, + initialValue = 1_000) + @Column(name = "id") + private Integer id; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 45) + @Column(name = "name") + private String name; + @Size(max = 45) + @Column(name = "description") + private String description; + @JoinTable(name = "fmea_has_risk_category", joinColumns = { + @JoinColumn(name = "FMEA_id", referencedColumnName = "id")}, + inverseJoinColumns = { + @JoinColumn(name = "risk_category_id", referencedColumnName = "id")}) + @ManyToMany + private List riskCategoryList; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "fmea") + private List riskItemList; + @OneToMany(mappedBy = "parent") + private List fmeaList; + @JoinColumn(name = "parent", referencedColumnName = "id") + @ManyToOne + private Fmea parent; + + public Fmea() { + } + + public Fmea(String name) { + this.name = name; + } + + public Integer getId() { + return id; + } + + public void setId(Integer id) { + this.id = id; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + @XmlTransient + @JsonIgnore + public List getRiskCategoryList() { + return riskCategoryList; + } + + public void setRiskCategoryList(List riskCategoryList) { + this.riskCategoryList = riskCategoryList; + } + + @XmlTransient + @JsonIgnore + public List getRiskItemList() { + return riskItemList; + } + + public void setRiskItemList(List riskItemList) { + this.riskItemList = riskItemList; + } + + @XmlTransient + @JsonIgnore + public List getFmeaList() { + return fmeaList; + } + + public void setFmeaList(List fmeaList) { + this.fmeaList = fmeaList; + } + + public Fmea getParent() { + return parent; + } + + public void setParent(Fmea parent) { + this.parent = parent; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (id != null ? id.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof Fmea)) { + return false; + } + Fmea other = (Fmea) object; + return this.id.equals(other.id); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.Fmea[ id=" + id + " ]"; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/Hazard.java b/VM-Core/src/main/java/com/validation/manager/core/db/Hazard.java index 0c94bfae..1ce93ed3 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/Hazard.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/Hazard.java @@ -13,141 +13,141 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.Column; -import javax.persistence.Entity; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.Id; -import javax.persistence.JoinColumn; -import javax.persistence.JoinTable; -import javax.persistence.Lob; -import javax.persistence.ManyToMany; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.Table; -import javax.persistence.TableGenerator; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "hazard") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "Hazard.findAll", - query = "SELECT h FROM Hazard h") - , @NamedQuery(name = "Hazard.findById", - query = "SELECT h FROM Hazard h WHERE h.id = :id") - , @NamedQuery(name = "Hazard.findByName", - query = "SELECT h FROM Hazard h WHERE h.name = :name")}) -public class Hazard implements Serializable { - - private static final long serialVersionUID = 1L; - @Id - @GeneratedValue(strategy = GenerationType.TABLE, - generator = "HazardGen") - @TableGenerator(name = "HazardGen", table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "hazard", - allocationSize = 1, - initialValue = 1000) - @Basic(optional = false) - @Column(name = "id") - private Integer id; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 255) - @Column(name = "name") - private String name; - @Basic(optional = false) - @NotNull - @Lob - @Size(min = 1, max = 65535) - @Column(name = "description") - private String description; - @JoinTable(name = "risk_item_has_hazard", joinColumns = { - @JoinColumn(name = "hazard_id", referencedColumnName = "id")}, - inverseJoinColumns = { - @JoinColumn(name = "risk_item_id", referencedColumnName = "id") - , @JoinColumn(name = "risk_item_FMEA_id", - referencedColumnName = "FMEA_id")}) - @ManyToMany - private List riskItemList; - - public Hazard() { - } - - public Hazard(String name, String description) { - this.name = name; - this.description = description; - } - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - public String getName() { - return name; - } - - public void setName(String name) { - this.name = name; - } - - public String getDescription() { - return description; - } - - public void setDescription(String description) { - this.description = description; - } - - @XmlTransient - @JsonIgnore - public List getRiskItemList() { - return riskItemList; - } - - public void setRiskItemList(List riskItemList) { - this.riskItemList = riskItemList; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (id != null ? id.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof Hazard)) { - return false; - } - Hazard other = (Hazard) object; - return !((this.id == null && other.id != null) - || (this.id != null && !this.id.equals(other.id))); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.Hazard[ id=" + id + " ]"; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.Id; +import javax.persistence.JoinColumn; +import javax.persistence.JoinTable; +import javax.persistence.Lob; +import javax.persistence.ManyToMany; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.Table; +import javax.persistence.TableGenerator; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "hazard") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "Hazard.findAll", + query = "SELECT h FROM Hazard h") + , @NamedQuery(name = "Hazard.findById", + query = "SELECT h FROM Hazard h WHERE h.id = :id") + , @NamedQuery(name = "Hazard.findByName", + query = "SELECT h FROM Hazard h WHERE h.name = :name")}) +public class Hazard implements Serializable { + + private static final long serialVersionUID = 1L; + @Id + @GeneratedValue(strategy = GenerationType.TABLE, + generator = "HazardGen") + @TableGenerator(name = "HazardGen", table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "hazard", + allocationSize = 1, + initialValue = 1_000) + @Basic(optional = false) + @Column(name = "id") + private Integer id; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 255) + @Column(name = "name") + private String name; + @Basic(optional = false) + @NotNull + @Lob + @Size(min = 1, max = 65_535) + @Column(name = "description") + private String description; + @JoinTable(name = "risk_item_has_hazard", joinColumns = { + @JoinColumn(name = "hazard_id", referencedColumnName = "id")}, + inverseJoinColumns = { + @JoinColumn(name = "risk_item_id", referencedColumnName = "id") + , @JoinColumn(name = "risk_item_FMEA_id", + referencedColumnName = "FMEA_id")}) + @ManyToMany + private List riskItemList; + + public Hazard() { + } + + public Hazard(String name, String description) { + this.name = name; + this.description = description; + } + + public Integer getId() { + return id; + } + + public void setId(Integer id) { + this.id = id; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + @XmlTransient + @JsonIgnore + public List getRiskItemList() { + return riskItemList; + } + + public void setRiskItemList(List riskItemList) { + this.riskItemList = riskItemList; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (id != null ? id.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof Hazard)) { + return false; + } + Hazard other = (Hazard) object; + return !((this.id == null && other.id != null) + || (this.id != null && !this.id.equals(other.id))); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.Hazard[ id=" + id + " ]"; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/History.java b/VM-Core/src/main/java/com/validation/manager/core/db/History.java index ef7f7f15..b9e98349 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/History.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/History.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,287 +13,300 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import java.util.Date; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.CascadeType; -import javax.persistence.Column; -import javax.persistence.Entity; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.Id; -import javax.persistence.JoinColumn; -import javax.persistence.JoinColumns; -import javax.persistence.Lob; -import javax.persistence.ManyToMany; -import javax.persistence.ManyToOne; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.OneToMany; -import javax.persistence.Table; -import javax.persistence.TableGenerator; -import javax.persistence.Temporal; -import javax.persistence.TemporalType; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "history") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "History.findAll", - query = "SELECT h FROM History h") - , @NamedQuery(name = "History.findById", - query = "SELECT h FROM History h WHERE h.id = :id") - , @NamedQuery(name = "History.findByVersionMajor", - query = "SELECT h FROM History h WHERE h.versionMajor = :versionMajor") - , @NamedQuery(name = "History.findByVersionMid", - query = "SELECT h FROM History h WHERE h.versionMid = :versionMid") - , @NamedQuery(name = "History.findByVersionMinor", - query = "SELECT h FROM History h WHERE h.versionMinor = :versionMinor") - , @NamedQuery(name = "History.findByModificationTime", - query = "SELECT h FROM History h WHERE h.modificationTime = :modificationTime")}) -public class History implements Serializable { - - private static final long serialVersionUID = 1L; - @Id - @Basic(optional = false) - @GeneratedValue(strategy = GenerationType.TABLE, - generator = "History_IDGEN") - @TableGenerator(name = "History_IDGEN", table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "history", - initialValue = 1, - allocationSize = 1) - @Column(name = "id") - private Integer id; - @Basic(optional = false) - @NotNull - @Column(name = "version_major") - private int versionMajor = 0; - @Basic(optional = false) - @NotNull - @Column(name = "version_mid") - private int versionMid = 0; - @Basic(optional = false) - @NotNull - @Column(name = "version_minor") - private int versionMinor = 1; - @Basic(optional = false) - @NotNull - @Lob - @Size(min = 1, max = 2147483647) - @Column(name = "reason") - private String reason; - @Basic(optional = false) - @NotNull - @Column(name = "modification_time") - @Temporal(TemporalType.TIMESTAMP) - private Date modificationTime; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "history") - private List historyFieldList; - @JoinColumn(name = "modifier_id", referencedColumnName = "id") - @ManyToOne(optional = false) - private VmUser modifierId; - @ManyToMany(mappedBy = "historyList") - private List executionStepList; - @ManyToMany(mappedBy = "historyList") - private List baselineList; - @JoinColumn(name = "requirement_id", referencedColumnName = "id") - @ManyToOne(optional = true) - private Requirement requirementId; - @JoinColumn(name = "project_id", referencedColumnName = "id") - @ManyToOne(optional = false) - private Project projectId; - @JoinColumns({ - @JoinColumn(name = "step_id", referencedColumnName = "id") - , @JoinColumn(name = "step_test_case_id", - referencedColumnName = "test_case_id")}) - @ManyToOne(optional = false) - private Step step; - @JoinColumn(name = "vm_setting_id", referencedColumnName = "id") - @ManyToOne(optional = false) - private VmSetting vmSettingId; - - public History() { - } - - public History(Integer id) { - this.id = id; - } - - public History(Integer id, int versionMajor, int versionMid, - int versionMinor, String reason, Date modificationTime) { - this.id = id; - this.versionMajor = versionMajor; - this.versionMid = versionMid; - this.versionMinor = versionMinor; - this.reason = reason; - this.modificationTime = modificationTime; - } - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - public int getMajorVersion() { - return versionMajor; - } - - public void setMajorVersion(int versionMajor) { - this.versionMajor = versionMajor; - } - - public int getMidVersion() { - return versionMid; - } - - public void setMidVersion(int versionMid) { - this.versionMid = versionMid; - } - - public int getMinorVersion() { - return versionMinor; - } - - public void setMinorVersion(int versionMinor) { - this.versionMinor = versionMinor; - } - - public String getReason() { - return reason; - } - - public void setReason(String reason) { - this.reason = reason; - } - - public Date getModificationTime() { - return modificationTime; - } - - public void setModificationTime(Date modificationTime) { - this.modificationTime = modificationTime; - } - - @XmlTransient - @JsonIgnore - public List getHistoryFieldList() { - return historyFieldList; - } - - public void setHistoryFieldList(List historyFieldList) { - this.historyFieldList = historyFieldList; - } - - public VmUser getModifierId() { - return modifierId; - } - - public void setModifierId(VmUser modifierId) { - this.modifierId = modifierId; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (id != null ? id.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof History)) { - return false; - } - History other = (History) object; - return !((this.id == null && other.id != null) || (this.id != null - && !this.id.equals(other.id))); - } - - @Override - public String toString() { - StringBuilder sb = new StringBuilder("Fields: "); - getHistoryFieldList().forEach(hf -> { - if (!sb.toString().isEmpty()) { - sb.append(", "); - } - sb.append(hf.getFieldName()) - .append("= ") - .append(hf.getFieldValue()); - }); - return "History{" + "id=" + id + ", versionMajor=" + versionMajor - + ", versionMid=" + versionMid + ", versionMinor=" - + versionMinor + ", reason=" + reason + ", modificationTime=" - + modificationTime + ", modifierId=" + modifierId - + "," + sb.toString() + '}'; - } - - @XmlTransient - @JsonIgnore - public List getBaselineList() { - return baselineList; - } - - public void setBaselineList(List baselineList) { - this.baselineList = baselineList; - } - - @XmlTransient - @JsonIgnore - public List getExecutionStepList() { - return executionStepList; - } - - public void setExecutionStepList(List executionStepList) { - this.executionStepList = executionStepList; - } - - public Requirement getRequirementId() { - return requirementId; - } - - public void setRequirementId(Requirement requirement) { - this.requirementId = requirement; - } - - public Project getProjectId() { - return projectId; - } - - public void setProjectId(Project projectId) { - this.projectId = projectId; - } - - public Step getStep() { - return step; - } - - public void setStep(Step step) { - this.step = step; - } - - public VmSetting getVmSettingId() { - return vmSettingId; - } - - public void setVmSettingId(VmSetting vmSettingId) { - this.vmSettingId = vmSettingId; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import java.util.Date; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.CascadeType; +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.Id; +import javax.persistence.JoinColumn; +import javax.persistence.JoinColumns; +import javax.persistence.Lob; +import javax.persistence.ManyToMany; +import javax.persistence.ManyToOne; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.OneToMany; +import javax.persistence.Table; +import javax.persistence.TableGenerator; +import javax.persistence.Temporal; +import javax.persistence.TemporalType; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "history") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "History.findAll", + query = "SELECT h FROM History h") + , @NamedQuery(name = "History.findById", + query = "SELECT h FROM History h WHERE h.id = :id") + , @NamedQuery(name = "History.findByVersionMajor", + query = "SELECT h FROM History h WHERE h.versionMajor = :versionMajor") + , @NamedQuery(name = "History.findByVersionMid", + query = "SELECT h FROM History h WHERE h.versionMid = :versionMid") + , @NamedQuery(name = "History.findByVersionMinor", + query = "SELECT h FROM History h WHERE h.versionMinor = :versionMinor") + , @NamedQuery(name = "History.findByModificationTime", + query = "SELECT h FROM History h WHERE h.modificationTime = :modificationTime")}) +public class History implements Serializable { + + private static final long serialVersionUID = 1L; + @Id + @Basic(optional = false) + @GeneratedValue(strategy = GenerationType.TABLE, + generator = "History_IDGEN") + @TableGenerator(name = "History_IDGEN", table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "history", + initialValue = 1, + allocationSize = 1) + @Column(name = "id") + private Integer id; + @Basic(optional = false) + @NotNull + @Column(name = "version_major") + private int versionMajor = 0; + @Basic(optional = false) + @NotNull + @Column(name = "version_mid") + private int versionMid = 0; + @Basic(optional = false) + @NotNull + @Column(name = "version_minor") + private int versionMinor = 1; + @Basic(optional = false) + @NotNull + @Lob + @Size(min = 1, max = 2_147_483_647) + @Column(name = "reason") + private String reason; + @Basic(optional = false) + @NotNull + @Column(name = "modification_time") + @Temporal(TemporalType.TIMESTAMP) + private Date modificationTime; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "history") + private List historyFieldList; + @JoinColumn(name = "modifier_id", referencedColumnName = "id") + @ManyToOne(optional = false) + private VmUser modifierId; + @ManyToMany(mappedBy = "historyList") + private List executionStepList; + @ManyToMany(mappedBy = "historyList") + private List baselineList; + @JoinColumn(name = "requirement_id", referencedColumnName = "id") + @ManyToOne(optional = true) + private Requirement requirementId; + @JoinColumn(name = "project_id", referencedColumnName = "id") + @ManyToOne(optional = false) + private Project projectId; + @JoinColumns({ + @JoinColumn(name = "step_id", referencedColumnName = "id") + , @JoinColumn(name = "step_test_case_id", + referencedColumnName = "test_case_id")}) + @ManyToOne(optional = false) + private Step step; + @JoinColumn(name = "vm_setting_id", referencedColumnName = "id") + @ManyToOne(optional = false) + private VmSetting vmSettingId; + @JoinColumn(name = "vm_user_id", referencedColumnName = "id") + @ManyToOne(optional = false) + private VmUser vmUserId; + + public History() { + } + + public History(Integer id) { + this.id = id; + } + + public History(Integer id, int versionMajor, int versionMid, + int versionMinor, String reason, Date modificationTime) { + this.id = id; + this.versionMajor = versionMajor; + this.versionMid = versionMid; + this.versionMinor = versionMinor; + this.reason = reason; + this.modificationTime = modificationTime; + } + + public Integer getId() { + return id; + } + + public void setId(Integer id) { + this.id = id; + } + + public int getMajorVersion() { + return versionMajor; + } + + public void setMajorVersion(int versionMajor) { + this.versionMajor = versionMajor; + } + + public int getMidVersion() { + return versionMid; + } + + public void setMidVersion(int versionMid) { + this.versionMid = versionMid; + } + + public int getMinorVersion() { + return versionMinor; + } + + public void setMinorVersion(int versionMinor) { + this.versionMinor = versionMinor; + } + + public String getReason() { + return reason; + } + + public void setReason(String reason) { + this.reason = reason; + } + + public Date getModificationTime() { + return modificationTime; + } + + public void setModificationTime(Date modificationTime) { + this.modificationTime = modificationTime; + } + + @XmlTransient + @JsonIgnore + public List getHistoryFieldList() { + return historyFieldList; + } + + public void setHistoryFieldList(List historyFieldList) { + this.historyFieldList = historyFieldList; + } + + public VmUser getModifierId() { + return modifierId; + } + + public void setModifierId(VmUser modifierId) { + this.modifierId = modifierId; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (id != null ? id.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof History)) { + return false; + } + History other = (History) object; + return !((this.id == null && other.id != null) || (this.id != null + && !this.id.equals(other.id))); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + getHistoryFieldList().forEach(hf -> { + if (sb.toString().isEmpty()) { + sb.append("Fields: "); + } else { + sb.append(", "); + } + sb.append(hf.getFieldName()) + .append("= ") + .append(hf.getFieldValue()); + }); + return "History{" + "id=" + id + ", versionMajor=" + versionMajor + + ", versionMid=" + versionMid + ", versionMinor=" + + versionMinor + ", reason=" + reason + ", modificationTime=" + + modificationTime + ", modifierId=" + modifierId + + "," + sb.toString() + '}'; + } + + @XmlTransient + @JsonIgnore + public List getBaselineList() { + return baselineList; + } + + public void setBaselineList(List baselineList) { + this.baselineList = baselineList; + } + + @XmlTransient + @JsonIgnore + public List getExecutionStepList() { + return executionStepList; + } + + public void setExecutionStepList(List executionStepList) { + this.executionStepList = executionStepList; + } + + public Requirement getRequirementId() { + return requirementId; + } + + public void setRequirementId(Requirement requirement) { + this.requirementId = requirement; + } + + public Project getProjectId() { + return projectId; + } + + public void setProjectId(Project projectId) { + this.projectId = projectId; + } + + public Step getStep() { + return step; + } + + public void setStep(Step step) { + this.step = step; + } + + public VmSetting getVmSettingId() { + return vmSettingId; + } + + public void setVmSettingId(VmSetting vmSettingId) { + this.vmSettingId = vmSettingId; + } + + public VmUser getVmUserId() { + return vmUserId; + } + + public void setVmUserId(VmUser vmUserId) { + this.vmUserId = vmUserId; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/HistoryField.java b/VM-Core/src/main/java/com/validation/manager/core/db/HistoryField.java index 684f2ea6..ca34b2f1 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/HistoryField.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/HistoryField.java @@ -13,146 +13,146 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import javax.persistence.Basic; -import javax.persistence.Column; -import javax.persistence.EmbeddedId; -import javax.persistence.Entity; -import javax.persistence.JoinColumn; -import javax.persistence.Lob; -import javax.persistence.ManyToOne; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.Table; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "history_field") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "HistoryField.findAll", - query = "SELECT h FROM HistoryField h") - , @NamedQuery(name = "HistoryField.findById", - query = "SELECT h FROM HistoryField h WHERE h.historyFieldPK.id = :id") - , @NamedQuery(name = "HistoryField.findByFieldTypeId", - query = "SELECT h FROM HistoryField h WHERE h.historyFieldPK.fieldTypeId = :fieldTypeId") - , @NamedQuery(name = "HistoryField.findByHistoryId", - query = "SELECT h FROM HistoryField h WHERE h.historyFieldPK.historyId = :historyId") - , @NamedQuery(name = "HistoryField.findByFieldName", - query = "SELECT h FROM HistoryField h WHERE h.fieldName = :fieldName")}) -public class HistoryField implements Serializable { - - private static final long serialVersionUID = 1L; - @EmbeddedId - protected HistoryFieldPK historyFieldPK; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 45) - @Column(name = "field_name") - private String fieldName; - @Basic(optional = false) - @NotNull - @Lob - @Size(min = 1, max = 2147483647) - @Column(name = "field_value") - private String fieldValue; - @JoinColumn(name = "field_type_id", referencedColumnName = "id", - insertable = false, updatable = false) - @ManyToOne(optional = false) - private FieldType fieldType; - @JoinColumn(name = "history_id", referencedColumnName = "id", - insertable = false, updatable = false) - @ManyToOne(optional = false) - private History history; - - public HistoryField() { - } - - public HistoryField(HistoryFieldPK historyFieldPK) { - this.historyFieldPK = historyFieldPK; - } - - public HistoryField(HistoryFieldPK historyFieldPK, String fieldName, - String fieldValue) { - this.historyFieldPK = historyFieldPK; - this.fieldName = fieldName; - this.fieldValue = fieldValue; - } - - public HistoryField(int fieldTypeId, int historyId) { - this.historyFieldPK = new HistoryFieldPK(fieldTypeId, historyId); - } - - public HistoryFieldPK getHistoryFieldPK() { - return historyFieldPK; - } - - public void setHistoryFieldPK(HistoryFieldPK historyFieldPK) { - this.historyFieldPK = historyFieldPK; - } - - public String getFieldName() { - return fieldName; - } - - public void setFieldName(String fieldName) { - this.fieldName = fieldName; - } - - public String getFieldValue() { - return fieldValue; - } - - public void setFieldValue(String fieldValue) { - this.fieldValue = fieldValue; - } - - public FieldType getFieldType() { - return fieldType; - } - - public void setFieldType(FieldType fieldType) { - this.fieldType = fieldType; - } - - public History getHistory() { - return history; - } - - public void setHistory(History history) { - this.history = history; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (historyFieldPK != null ? historyFieldPK.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof HistoryField)) { - return false; - } - HistoryField other = (HistoryField) object; - return !((this.historyFieldPK == null && other.historyFieldPK != null) - || (this.historyFieldPK != null - && !this.historyFieldPK.equals(other.historyFieldPK))); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.HistoryField[ historyFieldPK=" - + historyFieldPK + " ]"; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import javax.persistence.Basic; +import javax.persistence.Column; +import javax.persistence.EmbeddedId; +import javax.persistence.Entity; +import javax.persistence.JoinColumn; +import javax.persistence.Lob; +import javax.persistence.ManyToOne; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.Table; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "history_field") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "HistoryField.findAll", + query = "SELECT h FROM HistoryField h") + , @NamedQuery(name = "HistoryField.findById", + query = "SELECT h FROM HistoryField h WHERE h.historyFieldPK.id = :id") + , @NamedQuery(name = "HistoryField.findByFieldTypeId", + query = "SELECT h FROM HistoryField h WHERE h.historyFieldPK.fieldTypeId = :fieldTypeId") + , @NamedQuery(name = "HistoryField.findByHistoryId", + query = "SELECT h FROM HistoryField h WHERE h.historyFieldPK.historyId = :historyId") + , @NamedQuery(name = "HistoryField.findByFieldName", + query = "SELECT h FROM HistoryField h WHERE h.fieldName = :fieldName")}) +public class HistoryField implements Serializable { + + private static final long serialVersionUID = 1L; + @EmbeddedId + protected HistoryFieldPK historyFieldPK; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 45) + @Column(name = "field_name") + private String fieldName; + @Basic(optional = false) + @NotNull + @Lob + @Size(min = 1, max = 2_147_483_647) + @Column(name = "field_value") + private String fieldValue; + @JoinColumn(name = "field_type_id", referencedColumnName = "id", + insertable = false, updatable = false) + @ManyToOne(optional = false) + private FieldType fieldType; + @JoinColumn(name = "history_id", referencedColumnName = "id", + insertable = false, updatable = false) + @ManyToOne(optional = false) + private History history; + + public HistoryField() { + } + + public HistoryField(HistoryFieldPK historyFieldPK) { + this.historyFieldPK = historyFieldPK; + } + + public HistoryField(HistoryFieldPK historyFieldPK, String fieldName, + String fieldValue) { + this.historyFieldPK = historyFieldPK; + this.fieldName = fieldName; + this.fieldValue = fieldValue; + } + + public HistoryField(int fieldTypeId, int historyId) { + this.historyFieldPK = new HistoryFieldPK(fieldTypeId, historyId); + } + + public HistoryFieldPK getHistoryFieldPK() { + return historyFieldPK; + } + + public void setHistoryFieldPK(HistoryFieldPK historyFieldPK) { + this.historyFieldPK = historyFieldPK; + } + + public String getFieldName() { + return fieldName; + } + + public void setFieldName(String fieldName) { + this.fieldName = fieldName; + } + + public String getFieldValue() { + return fieldValue; + } + + public void setFieldValue(String fieldValue) { + this.fieldValue = fieldValue; + } + + public FieldType getFieldType() { + return fieldType; + } + + public void setFieldType(FieldType fieldType) { + this.fieldType = fieldType; + } + + public History getHistory() { + return history; + } + + public void setHistory(History history) { + this.history = history; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (historyFieldPK != null ? historyFieldPK.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof HistoryField)) { + return false; + } + HistoryField other = (HistoryField) object; + return !((this.historyFieldPK == null && other.historyFieldPK != null) + || (this.historyFieldPK != null + && !this.historyFieldPK.equals(other.historyFieldPK))); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.HistoryField[ historyFieldPK=" + + historyFieldPK + " ]"; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/Investigation.java b/VM-Core/src/main/java/com/validation/manager/core/db/Investigation.java index 45d0a89f..7eb0c3c7 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/Investigation.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/Investigation.java @@ -13,130 +13,130 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.CascadeType; -import javax.persistence.Column; -import javax.persistence.Entity; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.Id; -import javax.persistence.Lob; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.OneToMany; -import javax.persistence.Table; -import javax.persistence.TableGenerator; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "investigation") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "Investigation.findAll", - query = "SELECT i FROM Investigation i") - , @NamedQuery(name = "Investigation.findById", - query = "SELECT i FROM Investigation i WHERE i.id = :id")}) -public class Investigation implements Serializable { - - private static final long serialVersionUID = 1L; - @Id - @Basic(optional = false) - @GeneratedValue(strategy = GenerationType.TABLE, - generator = "InvestigationGen") - @TableGenerator(name = "InvestigationGen", table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "investigation", - allocationSize = 1, - initialValue = 1000) - @NotNull - @Column(name = "id") - private Integer id; - @Basic(optional = false) - @NotNull - @Lob - @Size(min = 1, max = 65535) - @Column(name = "description") - private String description; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "investigation") - private List userHasInvestigationList; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "investigation") - private List exceptionHasInvestigationList; - - public Investigation() { - } - - public Investigation(String description) { - this.description = description; - } - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - public String getDescription() { - return description; - } - - public void setDescription(String description) { - this.description = description; - } - - @XmlTransient - @JsonIgnore - public List getUserHasInvestigationList() { - return userHasInvestigationList; - } - - public void setUserHasInvestigationList(List userHasInvestigationList) { - this.userHasInvestigationList = userHasInvestigationList; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (id != null ? id.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof Investigation)) { - return false; - } - Investigation other = (Investigation) object; - return this.id.equals(other.id); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.Investigation[ id=" + id + " ]"; - } - - @XmlTransient - @JsonIgnore - public List getExceptionHasInvestigationList() { - return exceptionHasInvestigationList; - } - - public void setExceptionHasInvestigationList(List exceptionHasInvestigationList) { - this.exceptionHasInvestigationList = exceptionHasInvestigationList; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.CascadeType; +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.Id; +import javax.persistence.Lob; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.OneToMany; +import javax.persistence.Table; +import javax.persistence.TableGenerator; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "investigation") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "Investigation.findAll", + query = "SELECT i FROM Investigation i") + , @NamedQuery(name = "Investigation.findById", + query = "SELECT i FROM Investigation i WHERE i.id = :id")}) +public class Investigation implements Serializable { + + private static final long serialVersionUID = 1L; + @Id + @Basic(optional = false) + @GeneratedValue(strategy = GenerationType.TABLE, + generator = "InvestigationGen") + @TableGenerator(name = "InvestigationGen", table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "investigation", + allocationSize = 1, + initialValue = 1_000) + @NotNull + @Column(name = "id") + private Integer id; + @Basic(optional = false) + @NotNull + @Lob + @Size(min = 1, max = 65_535) + @Column(name = "description") + private String description; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "investigation") + private List userHasInvestigationList; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "investigation") + private List exceptionHasInvestigationList; + + public Investigation() { + } + + public Investigation(String description) { + this.description = description; + } + + public Integer getId() { + return id; + } + + public void setId(Integer id) { + this.id = id; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + @XmlTransient + @JsonIgnore + public List getUserHasInvestigationList() { + return userHasInvestigationList; + } + + public void setUserHasInvestigationList(List userHasInvestigationList) { + this.userHasInvestigationList = userHasInvestigationList; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (id != null ? id.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof Investigation)) { + return false; + } + Investigation other = (Investigation) object; + return this.id.equals(other.id); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.Investigation[ id=" + id + " ]"; + } + + @XmlTransient + @JsonIgnore + public List getExceptionHasInvestigationList() { + return exceptionHasInvestigationList; + } + + public void setExceptionHasInvestigationList(List exceptionHasInvestigationList) { + this.exceptionHasInvestigationList = exceptionHasInvestigationList; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/Issue.java b/VM-Core/src/main/java/com/validation/manager/core/db/Issue.java index bf097a94..1ba3108f 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/Issue.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/Issue.java @@ -13,176 +13,176 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import java.util.Date; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.CascadeType; -import javax.persistence.Column; -import javax.persistence.EmbeddedId; -import javax.persistence.Entity; -import javax.persistence.JoinColumn; -import javax.persistence.Lob; -import javax.persistence.ManyToOne; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.OneToMany; -import javax.persistence.Table; -import javax.persistence.Temporal; -import javax.persistence.TemporalType; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "issue") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "Issue.findAll", query = "SELECT i FROM Issue i") - , @NamedQuery(name = "Issue.findById", - query = "SELECT i FROM Issue i WHERE i.issuePK.id = :id") - , @NamedQuery(name = "Issue.findByIssueTypeId", - query = "SELECT i FROM Issue i WHERE i.issuePK.issueTypeId = :issueTypeId") - , @NamedQuery(name = "Issue.findByTitle", - query = "SELECT i FROM Issue i WHERE i.title = :title") - , @NamedQuery(name = "Issue.findByCreationTime", - query = "SELECT i FROM Issue i WHERE i.creationTime = :creationTime")}) -public class Issue implements Serializable { - - private static final long serialVersionUID = 1L; - @EmbeddedId - protected IssuePK issuePK; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 255) - @Column(name = "title") - private String title; - @Basic(optional = false) - @NotNull - @Lob - @Size(min = 1, max = 2147483647) - @Column(name = "description") - private String description; - @Basic(optional = false) - @NotNull - @Column(name = "creationTime") - @Temporal(TemporalType.TIMESTAMP) - private Date creationTime; - @JoinColumn(name = "issue_resolution_id", referencedColumnName = "id") - @ManyToOne(optional = false) - private IssueResolution issueResolutionId; - @JoinColumn(name = "issue_type_id", referencedColumnName = "id", - insertable = false, updatable = false) - @ManyToOne(optional = false) - private IssueType issueType; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "issue") - private List executionStepHasIssueList; - - public Issue() { - } - - public Issue(IssuePK issuePK) { - this.issuePK = issuePK; - } - - public Issue(IssuePK issuePK, String title, String description, - Date creationTime) { - this.issuePK = issuePK; - this.title = title; - this.description = description; - this.creationTime = creationTime; - } - - public Issue(int issueTypeId) { - this.issuePK = new IssuePK(issueTypeId); - } - - public IssuePK getIssuePK() { - return issuePK; - } - - public void setIssuePK(IssuePK issuePK) { - this.issuePK = issuePK; - } - - public String getTitle() { - return title; - } - - public void setTitle(String title) { - this.title = title; - } - - public String getDescription() { - return description; - } - - public void setDescription(String description) { - this.description = description; - } - - public Date getCreationTime() { - return creationTime; - } - - public void setCreationTime(Date creationTime) { - this.creationTime = creationTime; - } - - public IssueResolution getIssueResolutionId() { - return issueResolutionId; - } - - public void setIssueResolutionId(IssueResolution issueResolutionId) { - this.issueResolutionId = issueResolutionId; - } - - public IssueType getIssueType() { - return issueType; - } - - public void setIssueType(IssueType issueType) { - this.issueType = issueType; - } - - @XmlTransient - @JsonIgnore - public List getExecutionStepHasIssueList() { - return executionStepHasIssueList; - } - - public void setExecutionStepHasIssueList(List executionStepHasIssueList) { - this.executionStepHasIssueList = executionStepHasIssueList; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (issuePK != null ? issuePK.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof Issue)) { - return false; - } - Issue other = (Issue) object; - return !((this.issuePK == null && other.issuePK != null) - || (this.issuePK != null && !this.issuePK.equals(other.issuePK))); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.Issue[ issuePK=" + issuePK + " ]"; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import java.util.Date; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.CascadeType; +import javax.persistence.Column; +import javax.persistence.EmbeddedId; +import javax.persistence.Entity; +import javax.persistence.JoinColumn; +import javax.persistence.Lob; +import javax.persistence.ManyToOne; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.OneToMany; +import javax.persistence.Table; +import javax.persistence.Temporal; +import javax.persistence.TemporalType; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "issue") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "Issue.findAll", query = "SELECT i FROM Issue i") + , @NamedQuery(name = "Issue.findById", + query = "SELECT i FROM Issue i WHERE i.issuePK.id = :id") + , @NamedQuery(name = "Issue.findByIssueTypeId", + query = "SELECT i FROM Issue i WHERE i.issuePK.issueTypeId = :issueTypeId") + , @NamedQuery(name = "Issue.findByTitle", + query = "SELECT i FROM Issue i WHERE i.title = :title") + , @NamedQuery(name = "Issue.findByCreationTime", + query = "SELECT i FROM Issue i WHERE i.creationTime = :creationTime")}) +public class Issue implements Serializable { + + private static final long serialVersionUID = 1L; + @EmbeddedId + protected IssuePK issuePK; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 255) + @Column(name = "title") + private String title; + @Basic(optional = false) + @NotNull + @Lob + @Size(min = 1, max = 2_147_483_647) + @Column(name = "description") + private String description; + @Basic(optional = false) + @NotNull + @Column(name = "creationTime") + @Temporal(TemporalType.TIMESTAMP) + private Date creationTime; + @JoinColumn(name = "issue_resolution_id", referencedColumnName = "id") + @ManyToOne(optional = false) + private IssueResolution issueResolutionId; + @JoinColumn(name = "issue_type_id", referencedColumnName = "id", + insertable = false, updatable = false) + @ManyToOne(optional = false) + private IssueType issueType; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "issue") + private List executionStepHasIssueList; + + public Issue() { + } + + public Issue(IssuePK issuePK) { + this.issuePK = issuePK; + } + + public Issue(IssuePK issuePK, String title, String description, + Date creationTime) { + this.issuePK = issuePK; + this.title = title; + this.description = description; + this.creationTime = creationTime; + } + + public Issue(int issueTypeId) { + this.issuePK = new IssuePK(issueTypeId); + } + + public IssuePK getIssuePK() { + return issuePK; + } + + public void setIssuePK(IssuePK issuePK) { + this.issuePK = issuePK; + } + + public String getTitle() { + return title; + } + + public void setTitle(String title) { + this.title = title; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public Date getCreationTime() { + return creationTime; + } + + public void setCreationTime(Date creationTime) { + this.creationTime = creationTime; + } + + public IssueResolution getIssueResolutionId() { + return issueResolutionId; + } + + public void setIssueResolutionId(IssueResolution issueResolutionId) { + this.issueResolutionId = issueResolutionId; + } + + public IssueType getIssueType() { + return issueType; + } + + public void setIssueType(IssueType issueType) { + this.issueType = issueType; + } + + @XmlTransient + @JsonIgnore + public List getExecutionStepHasIssueList() { + return executionStepHasIssueList; + } + + public void setExecutionStepHasIssueList(List executionStepHasIssueList) { + this.executionStepHasIssueList = executionStepHasIssueList; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (issuePK != null ? issuePK.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof Issue)) { + return false; + } + Issue other = (Issue) object; + return !((this.issuePK == null && other.issuePK != null) + || (this.issuePK != null && !this.issuePK.equals(other.issuePK))); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.Issue[ issuePK=" + issuePK + " ]"; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/IssueResolution.java b/VM-Core/src/main/java/com/validation/manager/core/db/IssueResolution.java index 9816c790..e0b3c8d4 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/IssueResolution.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/IssueResolution.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,123 +13,123 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.CascadeType; -import javax.persistence.Column; -import javax.persistence.Entity; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.Id; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.OneToMany; -import javax.persistence.Table; -import javax.persistence.TableGenerator; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "issue_resolution") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "IssueResolution.findAll", - query = "SELECT i FROM IssueResolution i") - , @NamedQuery(name = "IssueResolution.findById", - query = "SELECT i FROM IssueResolution i WHERE i.id = :id") - , @NamedQuery(name = "IssueResolution.findByName", - query = "SELECT i FROM IssueResolution i WHERE i.name = :name")}) -public class IssueResolution implements Serializable { - - private static final long serialVersionUID = 1L; - @Id - @Basic(optional = false) - @NotNull - @Column(name = "id") - @GeneratedValue(strategy = GenerationType.TABLE, - generator = "ISSUE_RESOLUTION_IDGEN") - @TableGenerator(name = "ISSUE_RESOLUTION_IDGEN", table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "issue_resolution", - initialValue = 1, - allocationSize = 1) - private Integer id; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 45) - @Column(name = "name") - private String name; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "issueResolutionId") - private List issueList; - - public IssueResolution() { - } - - public IssueResolution(Integer id) { - this.id = id; - } - - public IssueResolution(Integer id, String name) { - this.id = id; - this.name = name; - } - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - public String getName() { - return name; - } - - public void setName(String name) { - this.name = name; - } - - @XmlTransient - @JsonIgnore - public List getIssueList() { - return issueList; - } - - public void setIssueList(List issueList) { - this.issueList = issueList; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (id != null ? id.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof IssueResolution)) { - return false; - } - IssueResolution other = (IssueResolution) object; - return this.id.equals(other.id); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.IssueResolution[ id=" + id + " ]"; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.CascadeType; +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.Id; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.OneToMany; +import javax.persistence.Table; +import javax.persistence.TableGenerator; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "issue_resolution") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "IssueResolution.findAll", + query = "SELECT i FROM IssueResolution i") + , @NamedQuery(name = "IssueResolution.findById", + query = "SELECT i FROM IssueResolution i WHERE i.id = :id") + , @NamedQuery(name = "IssueResolution.findByName", + query = "SELECT i FROM IssueResolution i WHERE i.name = :name")}) +public class IssueResolution implements Serializable { + + private static final long serialVersionUID = 1L; + @Id + @Basic(optional = false) + @NotNull + @Column(name = "id") + @GeneratedValue(strategy = GenerationType.TABLE, + generator = "ISSUE_RESOLUTION_IDGEN") + @TableGenerator(name = "ISSUE_RESOLUTION_IDGEN", table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "issue_resolution", + initialValue = 1_000, + allocationSize = 1) + private Integer id; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 45) + @Column(name = "name") + private String name; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "issueResolutionId") + private List issueList; + + public IssueResolution() { + } + + public IssueResolution(Integer id) { + this.id = id; + } + + public IssueResolution(Integer id, String name) { + this.id = id; + this.name = name; + } + + public Integer getId() { + return id; + } + + public void setId(Integer id) { + this.id = id; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + @XmlTransient + @JsonIgnore + public List getIssueList() { + return issueList; + } + + public void setIssueList(List issueList) { + this.issueList = issueList; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (id != null ? id.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof IssueResolution)) { + return false; + } + IssueResolution other = (IssueResolution) object; + return this.id.equals(other.id); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.IssueResolution[ id=" + id + " ]"; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/IssueType.java b/VM-Core/src/main/java/com/validation/manager/core/db/IssueType.java index 7ffc2ada..7aee0e0a 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/IssueType.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/IssueType.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,137 +13,132 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.CascadeType; -import javax.persistence.Column; -import javax.persistence.Entity; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.Id; -import javax.persistence.Lob; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.OneToMany; -import javax.persistence.Table; -import javax.persistence.TableGenerator; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "issue_type") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "IssueType.findAll", - query = "SELECT i FROM IssueType i") - , @NamedQuery(name = "IssueType.findById", - query = "SELECT i FROM IssueType i WHERE i.id = :id") - , @NamedQuery(name = "IssueType.findByTypeName", - query = "SELECT i FROM IssueType i WHERE i.typeName = :typeName")}) -public class IssueType implements Serializable { - - private static final long serialVersionUID = 1L; - @Id - @Basic(optional = false) - @NotNull - @Column(name = "id") - @GeneratedValue(strategy = GenerationType.TABLE, - generator = "ISSUE_TYPE_IDGEN") - @TableGenerator(name = "ISSUE_TYPE_IDGEN", table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "issue_type", - initialValue = 1, - allocationSize = 1) - private Integer id; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 45) - @Column(name = "type_name") - private String typeName; - @Lob - @Size(max = 2147483647) - @Column(name = "description") - private String description; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "issueType") - private List issueList; - - public IssueType() { - } - - public IssueType(Integer id) { - this.id = id; - } - - public IssueType(Integer id, String typeName) { - this.id = id; - this.typeName = typeName; - } - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - public String getTypeName() { - return typeName; - } - - public void setTypeName(String typeName) { - this.typeName = typeName; - } - - public String getDescription() { - return description; - } - - public void setDescription(String description) { - this.description = description; - } - - @XmlTransient - @JsonIgnore - public List getIssueList() { - return issueList; - } - - public void setIssueList(List issueList) { - this.issueList = issueList; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (id != null ? id.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof IssueType)) { - return false; - } - IssueType other = (IssueType) object; - return this.id.equals(other.id); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.IssueType[ id=" + id + " ]"; - } - -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.CascadeType; +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.Id; +import javax.persistence.Lob; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.OneToMany; +import javax.persistence.Table; +import javax.persistence.TableGenerator; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "issue_type") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "IssueType.findAll", + query = "SELECT i FROM IssueType i") + , @NamedQuery(name = "IssueType.findById", + query = "SELECT i FROM IssueType i WHERE i.id = :id") + , @NamedQuery(name = "IssueType.findByTypeName", + query = "SELECT i FROM IssueType i WHERE i.typeName = :typeName")}) +public class IssueType implements Serializable { + + private static final long serialVersionUID = 1L; + @Id + @Basic(optional = false) + @NotNull + @Column(name = "id") + @GeneratedValue(strategy = GenerationType.TABLE, + generator = "ISSUE_TYPE_IDGEN") + @TableGenerator(name = "ISSUE_TYPE_IDGEN", table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "issue_type", + initialValue = 1_000, + allocationSize = 1) + private Integer id; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 45) + @Column(name = "type_name") + private String typeName; + @Lob + @Size(max = 2_147_483_647) + @Column(name = "description") + private String description; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "issueType") + private List issueList; + + public IssueType() { + } + + public IssueType(String typeName) { + this.typeName = typeName; + } + + public Integer getId() { + return id; + } + + public void setId(Integer id) { + this.id = id; + } + + public String getTypeName() { + return typeName; + } + + public void setTypeName(String typeName) { + this.typeName = typeName; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + @XmlTransient + @JsonIgnore + public List getIssueList() { + return issueList; + } + + public void setIssueList(List issueList) { + this.issueList = issueList; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (id != null ? id.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof IssueType)) { + return false; + } + IssueType other = (IssueType) object; + return this.id.equals(other.id); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.IssueType[ id=" + id + " ]"; + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/Notification.java b/VM-Core/src/main/java/com/validation/manager/core/db/Notification.java index a3c8912d..f4e3ceb8 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/Notification.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/Notification.java @@ -13,182 +13,182 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import java.util.Date; -import javax.persistence.Basic; -import javax.persistence.Column; -import javax.persistence.EmbeddedId; -import javax.persistence.Entity; -import javax.persistence.JoinColumn; -import javax.persistence.Lob; -import javax.persistence.ManyToOne; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.Table; -import javax.persistence.Temporal; -import javax.persistence.TemporalType; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "notification") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "Notification.findAll", - query = "SELECT n FROM Notification n") - , @NamedQuery(name = "Notification.findById", - query = "SELECT n FROM Notification n WHERE n.notificationPK.id = :id") - , @NamedQuery(name = "Notification.findByNotificationTypeId", - query = "SELECT n FROM Notification n WHERE n.notificationPK.notificationTypeId = :notificationTypeId") - , @NamedQuery(name = "Notification.findByCreationDate", - query = "SELECT n FROM Notification n WHERE n.creationDate = :creationDate") - , @NamedQuery(name = "Notification.findByAcknowledgeDate", - query = "SELECT n FROM Notification n WHERE n.acknowledgeDate = :acknowledgeDate")}) -public class Notification implements Serializable { - - private static final long serialVersionUID = 1L; - @EmbeddedId - protected NotificationPK notificationPK; - @Basic(optional = false) - @NotNull - @Lob - @Size(min = 1, max = 2147483647) - @Column(name = "content") - private String content; - @Basic(optional = false) - @NotNull - @Column(name = "creation_date") - @Temporal(TemporalType.TIMESTAMP) - private Date creationDate; - @Column(name = "acknowledge_date") - @Temporal(TemporalType.TIMESTAMP) - private Date acknowledgeDate; - @JoinColumn(name = "notification_type_id", referencedColumnName = "id", - insertable = false, updatable = false) - @ManyToOne(optional = false) - private NotificationType notificationType; - @JoinColumn(name = "target_user", referencedColumnName = "id") - @ManyToOne(optional = false) - private VmUser targetUser; - @JoinColumn(name = "author", referencedColumnName = "id") - @ManyToOne(optional = false) - private VmUser author; - @Basic(optional = false) - @NotNull - @Column(name = "archieved") - private boolean archieved; - - public Notification() { - } - - public Notification(NotificationPK notificationPK) { - this.notificationPK = notificationPK; - } - - public Notification(NotificationPK notificationPK, String content, Date creationDate) { - this.notificationPK = notificationPK; - this.content = content; - this.creationDate = creationDate; - } - - public Notification(int id, int notificationTypeId) { - this.notificationPK = new NotificationPK(id, notificationTypeId); - } - - public NotificationPK getNotificationPK() { - return notificationPK; - } - - public void setNotificationPK(NotificationPK notificationPK) { - this.notificationPK = notificationPK; - } - - public String getContent() { - return content; - } - - public void setContent(String content) { - this.content = content; - } - - public Date getCreationDate() { - return creationDate; - } - - public void setCreationDate(Date creationDate) { - this.creationDate = creationDate; - } - - public Date getAcknowledgeDate() { - return acknowledgeDate; - } - - public void setAcknowledgeDate(Date acknowledgeDate) { - this.acknowledgeDate = acknowledgeDate; - } - - public NotificationType getNotificationType() { - return notificationType; - } - - public void setNotificationType(NotificationType notificationType) { - this.notificationType = notificationType; - } - - public VmUser getTargetUser() { - return targetUser; - } - - public void setTargetUser(VmUser targetUser) { - this.targetUser = targetUser; - } - - public VmUser getAuthor() { - return author; - } - - public void setAuthor(VmUser author) { - this.author = author; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (notificationPK != null ? notificationPK.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - // TODO: Warning - this method won't work in the case the id fields are not set - if (!(object instanceof Notification)) { - return false; - } - Notification other = (Notification) object; - if ((this.notificationPK == null && other.notificationPK != null) || (this.notificationPK != null && !this.notificationPK.equals(other.notificationPK))) { - return false; - } - return true; - } - - @Override - public String toString() { - return "com.validation.manager.core.db.Notification[ notificationPK=" + notificationPK + " ]"; - } - - public boolean getArchieved() { - return archieved; - } - - public void setArchieved(boolean archieved) { - this.archieved = archieved; - } - -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import java.util.Date; +import javax.persistence.Basic; +import javax.persistence.Column; +import javax.persistence.EmbeddedId; +import javax.persistence.Entity; +import javax.persistence.JoinColumn; +import javax.persistence.Lob; +import javax.persistence.ManyToOne; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.Table; +import javax.persistence.Temporal; +import javax.persistence.TemporalType; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "notification") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "Notification.findAll", + query = "SELECT n FROM Notification n") + , @NamedQuery(name = "Notification.findById", + query = "SELECT n FROM Notification n WHERE n.notificationPK.id = :id") + , @NamedQuery(name = "Notification.findByNotificationTypeId", + query = "SELECT n FROM Notification n WHERE n.notificationPK.notificationTypeId = :notificationTypeId") + , @NamedQuery(name = "Notification.findByCreationDate", + query = "SELECT n FROM Notification n WHERE n.creationDate = :creationDate") + , @NamedQuery(name = "Notification.findByAcknowledgeDate", + query = "SELECT n FROM Notification n WHERE n.acknowledgeDate = :acknowledgeDate")}) +public class Notification implements Serializable { + + private static final long serialVersionUID = 1L; + @EmbeddedId + protected NotificationPK notificationPK; + @Basic(optional = false) + @NotNull + @Lob + @Size(min = 1, max = 2_147_483_647) + @Column(name = "content") + private String content; + @Basic(optional = false) + @NotNull + @Column(name = "creation_date") + @Temporal(TemporalType.TIMESTAMP) + private Date creationDate; + @Column(name = "acknowledge_date") + @Temporal(TemporalType.TIMESTAMP) + private Date acknowledgeDate; + @JoinColumn(name = "notification_type_id", referencedColumnName = "id", + insertable = false, updatable = false) + @ManyToOne(optional = false) + private NotificationType notificationType; + @JoinColumn(name = "target_user", referencedColumnName = "id") + @ManyToOne(optional = false) + private VmUser targetUser; + @JoinColumn(name = "author", referencedColumnName = "id") + @ManyToOne(optional = false) + private VmUser author; + @Basic(optional = false) + @NotNull + @Column(name = "archieved") + private boolean archieved; + + public Notification() { + } + + public Notification(NotificationPK notificationPK) { + this.notificationPK = notificationPK; + } + + public Notification(NotificationPK notificationPK, String content, Date creationDate) { + this.notificationPK = notificationPK; + this.content = content; + this.creationDate = creationDate; + } + + public Notification(int id, int notificationTypeId) { + this.notificationPK = new NotificationPK(id, notificationTypeId); + } + + public NotificationPK getNotificationPK() { + return notificationPK; + } + + public void setNotificationPK(NotificationPK notificationPK) { + this.notificationPK = notificationPK; + } + + public String getContent() { + return content; + } + + public void setContent(String content) { + this.content = content; + } + + public Date getCreationDate() { + return creationDate; + } + + public void setCreationDate(Date creationDate) { + this.creationDate = creationDate; + } + + public Date getAcknowledgeDate() { + return acknowledgeDate; + } + + public void setAcknowledgeDate(Date acknowledgeDate) { + this.acknowledgeDate = acknowledgeDate; + } + + public NotificationType getNotificationType() { + return notificationType; + } + + public void setNotificationType(NotificationType notificationType) { + this.notificationType = notificationType; + } + + public VmUser getTargetUser() { + return targetUser; + } + + public void setTargetUser(VmUser targetUser) { + this.targetUser = targetUser; + } + + public VmUser getAuthor() { + return author; + } + + public void setAuthor(VmUser author) { + this.author = author; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (notificationPK != null ? notificationPK.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + // TODO: Warning - this method won't work in the case the id fields are not set + if (!(object instanceof Notification)) { + return false; + } + Notification other = (Notification) object; + if ((this.notificationPK == null && other.notificationPK != null) || (this.notificationPK != null && !this.notificationPK.equals(other.notificationPK))) { + return false; + } + return true; + } + + @Override + public String toString() { + return "com.validation.manager.core.db.Notification[ notificationPK=" + notificationPK + " ]"; + } + + public boolean getArchieved() { + return archieved; + } + + public void setArchieved(boolean archieved) { + this.archieved = archieved; + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/NotificationPK.java b/VM-Core/src/main/java/com/validation/manager/core/db/NotificationPK.java index 2945c91a..59f4b8d2 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/NotificationPK.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/NotificationPK.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,81 +13,92 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import javax.persistence.Basic; -import javax.persistence.Column; -import javax.persistence.Embeddable; -import javax.validation.constraints.NotNull; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Embeddable -public class NotificationPK implements Serializable { - - @Basic(optional = false) - @NotNull - @Column(name = "id") - private int id; - @Basic(optional = false) - @NotNull - @Column(name = "notification_type_id") - private int notificationTypeId; - - public NotificationPK() { - } - - public NotificationPK(int id, int notificationTypeId) { - this.id = id; - this.notificationTypeId = notificationTypeId; - } - - public int getId() { - return id; - } - - public void setId(int id) { - this.id = id; - } - - public int getNotificationTypeId() { - return notificationTypeId; - } - - public void setNotificationTypeId(int notificationTypeId) { - this.notificationTypeId = notificationTypeId; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (int) id; - hash += (int) notificationTypeId; - return hash; - } - - @Override - public boolean equals(Object object) { - // TODO: Warning - this method won't work in the case the id fields are not set - if (!(object instanceof NotificationPK)) { - return false; - } - NotificationPK other = (NotificationPK) object; - if (this.id != other.id) { - return false; - } - if (this.notificationTypeId != other.notificationTypeId) { - return false; - } - return true; - } - - @Override - public String toString() { - return "com.validation.manager.core.db.NotificationPK[ id=" + id + ", notificationTypeId=" + notificationTypeId + " ]"; - } - -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import javax.persistence.Basic; +import javax.persistence.Column; +import javax.persistence.Embeddable; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.TableGenerator; +import javax.validation.constraints.NotNull; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Embeddable +public class NotificationPK implements Serializable { + + @Basic(optional = false) + @NotNull + @Column(name = "id") + @GeneratedValue(strategy = GenerationType.TABLE, + generator = "Notification_IDGEN") + @TableGenerator(name = "Notification_IDGEN", table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "notification", + initialValue = 1, + allocationSize = 1) + private int id; + @Basic(optional = false) + @NotNull + @Column(name = "notification_type_id") + private int notificationTypeId; + + public NotificationPK() { + } + + public NotificationPK(int id, int notificationTypeId) { + this.id = id; + this.notificationTypeId = notificationTypeId; + } + + public int getId() { + return id; + } + + public void setId(int id) { + this.id = id; + } + + public int getNotificationTypeId() { + return notificationTypeId; + } + + public void setNotificationTypeId(int notificationTypeId) { + this.notificationTypeId = notificationTypeId; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (int) id; + hash += (int) notificationTypeId; + return hash; + } + + @Override + public boolean equals(Object object) { + // TODO: Warning - this method won't work in the case the id fields are not set + if (!(object instanceof NotificationPK)) { + return false; + } + NotificationPK other = (NotificationPK) object; + if (this.id != other.id) { + return false; + } + if (this.notificationTypeId != other.notificationTypeId) { + return false; + } + return true; + } + + @Override + public String toString() { + return "com.validation.manager.core.db.NotificationPK[ id=" + id + ", notificationTypeId=" + notificationTypeId + " ]"; + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/Project.java b/VM-Core/src/main/java/com/validation/manager/core/db/Project.java index 3158f241..0d1bf42b 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/Project.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/Project.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,190 +13,193 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import com.validation.manager.core.history.Versionable; -import java.io.Serializable; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.CascadeType; -import javax.persistence.Column; -import javax.persistence.Entity; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.Id; -import javax.persistence.JoinColumn; -import javax.persistence.JoinTable; -import javax.persistence.Lob; -import javax.persistence.ManyToMany; -import javax.persistence.ManyToOne; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.OneToMany; -import javax.persistence.Table; -import javax.persistence.TableGenerator; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "project") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "Project.findAll", - query = "SELECT p FROM Project p") - , @NamedQuery(name = "Project.findById", - query = "SELECT p FROM Project p WHERE p.id = :id") - , @NamedQuery(name = "Project.findByName", - query = "SELECT p FROM Project p WHERE p.name = :name")}) -public class Project extends Versionable implements Serializable { - - private static final long serialVersionUID = 1L; - @Id - @Basic(optional = false) - @GeneratedValue(strategy = GenerationType.TABLE, - generator = "ProjectGen") - @TableGenerator(name = "ProjectGen", table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "project", - allocationSize = 1, - initialValue = 1000) - @NotNull - @Column(name = "id") - private Integer id; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 255) - @Column(name = "name") - private String name; - @Lob - @Size(max = 2147483647) - @Column(name = "notes") - private String notes; - @JoinTable(name = "project_has_test_project", joinColumns = { - @JoinColumn(name = "project_id", referencedColumnName = "id")}, - inverseJoinColumns = { - @JoinColumn(name = "test_project_id", - referencedColumnName = "id")}) - @ManyToMany - private List testProjectList; - @OneToMany(mappedBy = "parentProjectId") - private List projectList; - @JoinColumn(name = "parent_project_id", referencedColumnName = "id") - @ManyToOne - private Project parentProjectId; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "project") - private List requirementSpecList; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "projectId") - private List historyList; - - public Project(String name) { - this.name = name; - } - - public Project() { - } - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - public String getName() { - return name; - } - - public void setName(String name) { - this.name = name; - } - - public String getNotes() { - return notes; - } - - public void setNotes(String notes) { - this.notes = notes; - } - - @XmlTransient - @JsonIgnore - public List getTestProjectList() { - return testProjectList; - } - - public void setTestProjectList(List testProjectList) { - this.testProjectList = testProjectList; - } - - @XmlTransient - @JsonIgnore - public List getProjectList() { - return projectList; - } - - public void setProjectList(List projectList) { - this.projectList = projectList; - } - - public Project getParentProjectId() { - return parentProjectId; - } - - public void setParentProjectId(Project parentProjectId) { - this.parentProjectId = parentProjectId; - } - - @XmlTransient - @JsonIgnore - public List getRequirementSpecList() { - return requirementSpecList; - } - - public void setRequirementSpecList(List requirementSpecList) { - this.requirementSpecList = requirementSpecList; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (id != null ? id.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof Project)) { - return false; - } - Project other = (Project) object; - return this.id.equals(other.id); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.Project[ id=" + id + " ]"; - } - - @XmlTransient - @JsonIgnore - @Override - public List getHistoryList() { - return historyList; - } - - @Override - public void setHistoryList(List historyList) { - this.historyList = historyList; - } -} +package com.validation.manager.core.db; + +import com.validation.manager.core.history.Auditable; +import com.validation.manager.core.history.Versionable; +import java.io.Serializable; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.CascadeType; +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.Id; +import javax.persistence.JoinColumn; +import javax.persistence.JoinTable; +import javax.persistence.Lob; +import javax.persistence.ManyToMany; +import javax.persistence.ManyToOne; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.OneToMany; +import javax.persistence.Table; +import javax.persistence.TableGenerator; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "project") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "Project.findAll", + query = "SELECT p FROM Project p") + , @NamedQuery(name = "Project.findById", + query = "SELECT p FROM Project p WHERE p.id = :id") + , @NamedQuery(name = "Project.findByName", + query = "SELECT p FROM Project p WHERE p.name = :name")}) +public class Project extends Versionable implements Serializable { + + private static final long serialVersionUID = 1L; + @Id + @Basic(optional = false) + @GeneratedValue(strategy = GenerationType.TABLE, + generator = "ProjectGen") + @TableGenerator(name = "ProjectGen", table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "project", + allocationSize = 1, + initialValue = 1_000) + @NotNull + @Column(name = "id") + private Integer id; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 255) + @Column(name = "name") + @Auditable + private String name; + @Lob + @Size(max = 2_147_483_647) + @Column(name = "notes") + @Auditable + private String notes; + @JoinTable(name = "project_has_test_project", joinColumns = { + @JoinColumn(name = "project_id", referencedColumnName = "id")}, + inverseJoinColumns = { + @JoinColumn(name = "test_project_id", + referencedColumnName = "id")}) + @ManyToMany + private List testProjectList; + @OneToMany(mappedBy = "parentProjectId") + private List projectList; + @JoinColumn(name = "parent_project_id", referencedColumnName = "id") + @ManyToOne + private Project parentProjectId; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "project") + private List requirementSpecList; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "projectId") + private List historyList; + + public Project(String name) { + this.name = name; + } + + public Project() { + } + + public Integer getId() { + return id; + } + + public void setId(Integer id) { + this.id = id; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getNotes() { + return notes; + } + + public void setNotes(String notes) { + this.notes = notes; + } + + @XmlTransient + @JsonIgnore + public List getTestProjectList() { + return testProjectList; + } + + public void setTestProjectList(List testProjectList) { + this.testProjectList = testProjectList; + } + + @XmlTransient + @JsonIgnore + public List getProjectList() { + return projectList; + } + + public void setProjectList(List projectList) { + this.projectList = projectList; + } + + public Project getParentProjectId() { + return parentProjectId; + } + + public void setParentProjectId(Project parentProjectId) { + this.parentProjectId = parentProjectId; + } + + @XmlTransient + @JsonIgnore + public List getRequirementSpecList() { + return requirementSpecList; + } + + public void setRequirementSpecList(List requirementSpecList) { + this.requirementSpecList = requirementSpecList; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (id != null ? id.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof Project)) { + return false; + } + Project other = (Project) object; + return this.id.equals(other.id); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.Project[ id=" + id + " ]"; + } + + @XmlTransient + @JsonIgnore + @Override + public List getHistoryList() { + return historyList; + } + + @Override + public void setHistoryList(List historyList) { + this.historyList = historyList; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/Requirement.java b/VM-Core/src/main/java/com/validation/manager/core/db/Requirement.java index bd0f08d0..bbadbe2b 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/Requirement.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/Requirement.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,265 +13,265 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import com.validation.manager.core.history.Auditable; -import com.validation.manager.core.history.Versionable; -import java.io.Serializable; -import java.util.ArrayList; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.CascadeType; -import javax.persistence.Column; -import javax.persistence.Entity; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.Id; -import javax.persistence.JoinColumn; -import javax.persistence.JoinColumns; -import javax.persistence.JoinTable; -import javax.persistence.Lob; -import javax.persistence.ManyToMany; -import javax.persistence.ManyToOne; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.OneToMany; -import javax.persistence.Table; -import javax.persistence.TableGenerator; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "requirement") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "Requirement.findAll", - query = "SELECT r FROM Requirement r") - , @NamedQuery(name = "Requirement.findById", - query = "SELECT r FROM Requirement r WHERE r.id = :id") - , @NamedQuery(name = "Requirement.findByUniqueId", - query = "SELECT r FROM Requirement r WHERE r.uniqueId = :uniqueId")}) -public class Requirement extends Versionable implements Serializable { - - private static final long serialVersionUID = 1L; - @Id - @Basic(optional = false) - @GeneratedValue(strategy = GenerationType.TABLE, - generator = "ReqGen") - @TableGenerator(name = "ReqGen", table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "requirement", - allocationSize = 1, - initialValue = 1000) - @NotNull - @Column(name = "id") - private Integer id; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 255) - @Column(name = "unique_id") - @Auditable - private String uniqueId; - @Basic(optional = false) - @NotNull - @Lob - @Size(max = 2147483647) - @Column(name = "description") - @Auditable - private String description; - @Lob - @Size(max = 2147483647) - @Column(name = "notes") - @Auditable - private String notes; - @OneToMany(mappedBy = "parentRequirementId") - private List requirementList; - @JoinTable(name = "step_has_requirement", joinColumns = { - @JoinColumn(name = "requirement_id", referencedColumnName = "id")}, - inverseJoinColumns = { - @JoinColumn(name = "step_id", referencedColumnName = "id") - , @JoinColumn(name = "step_test_case_id", - referencedColumnName = "test_case_id")}) - @ManyToMany - private List stepList; - @JoinColumn(name = "parent_requirement_id", referencedColumnName = "id") - @ManyToOne - private Requirement parentRequirementId; - @JoinColumns({ - @JoinColumn(name = "requirement_spec_node_id", - referencedColumnName = "id") - , @JoinColumn(name = "requirement_spec_node_requirement_spec_id", - referencedColumnName = "requirement_spec_id") - , @JoinColumn(name = "requirement_spec_node_requirement_spec_project_id", - referencedColumnName = "requirement_spec_project_id") - , @JoinColumn(name = "requirement_spec_node_requirement_spec_spec_level_id", - referencedColumnName = "requirement_spec_spec_level_id")}) - @ManyToOne(optional = false) - private RequirementSpecNode requirementSpecNode; - @JoinColumn(name = "requirement_status_id", referencedColumnName = "id") - @ManyToOne(optional = false) - private RequirementStatus requirementStatusId; - @JoinColumn(name = "requirement_type_id", referencedColumnName = "id") - @ManyToOne(optional = false) - private RequirementType requirementTypeId; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "requirement") - private List riskControlHasRequirementList; - @OneToMany(mappedBy = "requirementId") - private List historyList; - - public Requirement() { - super(); - } - - public Requirement(String uniqueId, String description) { - this.uniqueId = uniqueId; - this.description = description; - } - - public Requirement(String uniqueId, String description, String notes) { - this.uniqueId = uniqueId; - this.description = description; - this.notes = notes; - setRiskControlHasRequirementList(new ArrayList<>()); - setRequirementList(new ArrayList<>()); - setStepList(new ArrayList<>()); - } - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - public String getUniqueId() { - return uniqueId; - } - - public void setUniqueId(String uniqueId) { - this.uniqueId = uniqueId; - } - - public String getDescription() { - return description; - } - - public void setDescription(String description) { - this.description = description; - } - - public String getNotes() { - return notes; - } - - public void setNotes(String notes) { - this.notes = notes; - } - - @XmlTransient - @JsonIgnore - public List getRequirementList() { - return requirementList; - } - - public void setRequirementList(List requirementList) { - this.requirementList = requirementList; - } - - public Requirement getParentRequirementId() { - return parentRequirementId; - } - - public void setParentRequirementId(Requirement parentRequirementId) { - this.parentRequirementId = parentRequirementId; - } - - @XmlTransient - @JsonIgnore - public List getStepList() { - return stepList; - } - - public void setStepList(List stepList) { - this.stepList = stepList; - } - - public RequirementSpecNode getRequirementSpecNode() { - return requirementSpecNode; - } - - public void setRequirementSpecNode(RequirementSpecNode requirementSpecNode) { - this.requirementSpecNode = requirementSpecNode; - } - - public RequirementStatus getRequirementStatusId() { - return requirementStatusId; - } - - public void setRequirementStatusId(RequirementStatus requirementStatusId) { - this.requirementStatusId = requirementStatusId; - } - - public RequirementType getRequirementTypeId() { - return requirementTypeId; - } - - public void setRequirementTypeId(RequirementType requirementTypeId) { - this.requirementTypeId = requirementTypeId; - } - - @XmlTransient - @JsonIgnore - public List getRiskControlHasRequirementList() { - return riskControlHasRequirementList; - } - - public void setRiskControlHasRequirementList(List riskControlHasRequirementList) { - this.riskControlHasRequirementList = riskControlHasRequirementList; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (id != null ? id.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - if (!(object instanceof Requirement)) { - return false; - } - Requirement other = (Requirement) object; - return this.id.equals(other.id); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.Requirement[ id=" + getId() - + ", uniqueId=" + getUniqueId() - + ", description=" + getDescription() - + " " + super.toString() + " ]"; - } - - @XmlTransient - @JsonIgnore - @Override - public List getHistoryList() { - return historyList; - } - - @Override - public void setHistoryList(List historyList) { - this.historyList = historyList; - } -} +package com.validation.manager.core.db; + +import com.validation.manager.core.history.Auditable; +import com.validation.manager.core.history.Versionable; +import java.io.Serializable; +import java.util.ArrayList; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.CascadeType; +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.Id; +import javax.persistence.JoinColumn; +import javax.persistence.JoinColumns; +import javax.persistence.JoinTable; +import javax.persistence.Lob; +import javax.persistence.ManyToMany; +import javax.persistence.ManyToOne; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.OneToMany; +import javax.persistence.Table; +import javax.persistence.TableGenerator; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "requirement") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "Requirement.findAll", + query = "SELECT r FROM Requirement r") + , @NamedQuery(name = "Requirement.findById", + query = "SELECT r FROM Requirement r WHERE r.id = :id") + , @NamedQuery(name = "Requirement.findByUniqueId", + query = "SELECT r FROM Requirement r WHERE r.uniqueId = :uniqueId")}) +public class Requirement extends Versionable implements Serializable { + + private static final long serialVersionUID = 1L; + @Id + @Basic(optional = false) + @GeneratedValue(strategy = GenerationType.TABLE, + generator = "ReqGen") + @TableGenerator(name = "ReqGen", table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "requirement", + allocationSize = 1, + initialValue = 1_000) + @NotNull + @Column(name = "id") + private Integer id; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 255) + @Column(name = "unique_id") + @Auditable + private String uniqueId; + @Basic(optional = false) + @NotNull + @Lob + @Size(max = 2_147_483_647) + @Column(name = "description") + @Auditable + private String description; + @Lob + @Size(max = 2_147_483_647) + @Column(name = "notes") + @Auditable + private String notes; + @OneToMany(mappedBy = "parentRequirementId") + private List requirementList; + @JoinTable(name = "step_has_requirement", joinColumns = { + @JoinColumn(name = "requirement_id", referencedColumnName = "id")}, + inverseJoinColumns = { + @JoinColumn(name = "step_id", referencedColumnName = "id") + , @JoinColumn(name = "step_test_case_id", + referencedColumnName = "test_case_id")}) + @ManyToMany + private List stepList; + @JoinColumn(name = "parent_requirement_id", referencedColumnName = "id") + @ManyToOne + private Requirement parentRequirementId; + @JoinColumns({ + @JoinColumn(name = "requirement_spec_node_id", + referencedColumnName = "id") + , @JoinColumn(name = "requirement_spec_node_requirement_spec_id", + referencedColumnName = "requirement_spec_id") + , @JoinColumn(name = "requirement_spec_node_requirement_spec_project_id", + referencedColumnName = "requirement_spec_project_id") + , @JoinColumn(name = "requirement_spec_node_requirement_spec_spec_level_id", + referencedColumnName = "requirement_spec_spec_level_id")}) + @ManyToOne(optional = false) + private RequirementSpecNode requirementSpecNode; + @JoinColumn(name = "requirement_status_id", referencedColumnName = "id") + @ManyToOne(optional = false) + private RequirementStatus requirementStatusId; + @JoinColumn(name = "requirement_type_id", referencedColumnName = "id") + @ManyToOne(optional = false) + private RequirementType requirementTypeId; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "requirement") + private List riskControlHasRequirementList; + @OneToMany(mappedBy = "requirementId") + private List historyList; + + public Requirement() { + super(); + } + + public Requirement(String uniqueId, String description) { + this.uniqueId = uniqueId; + this.description = description; + } + + public Requirement(String uniqueId, String description, String notes) { + this.uniqueId = uniqueId; + this.description = description; + this.notes = notes; + setRiskControlHasRequirementList(new ArrayList<>()); + setRequirementList(new ArrayList<>()); + setStepList(new ArrayList<>()); + } + + public Integer getId() { + return id; + } + + public void setId(Integer id) { + this.id = id; + } + + public String getUniqueId() { + return uniqueId; + } + + public void setUniqueId(String uniqueId) { + this.uniqueId = uniqueId; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public String getNotes() { + return notes; + } + + public void setNotes(String notes) { + this.notes = notes; + } + + @XmlTransient + @JsonIgnore + public List getRequirementList() { + return requirementList; + } + + public void setRequirementList(List requirementList) { + this.requirementList = requirementList; + } + + public Requirement getParentRequirementId() { + return parentRequirementId; + } + + public void setParentRequirementId(Requirement parentRequirementId) { + this.parentRequirementId = parentRequirementId; + } + + @XmlTransient + @JsonIgnore + public List getStepList() { + return stepList; + } + + public void setStepList(List stepList) { + this.stepList = stepList; + } + + public RequirementSpecNode getRequirementSpecNode() { + return requirementSpecNode; + } + + public void setRequirementSpecNode(RequirementSpecNode requirementSpecNode) { + this.requirementSpecNode = requirementSpecNode; + } + + public RequirementStatus getRequirementStatusId() { + return requirementStatusId; + } + + public void setRequirementStatusId(RequirementStatus requirementStatusId) { + this.requirementStatusId = requirementStatusId; + } + + public RequirementType getRequirementTypeId() { + return requirementTypeId; + } + + public void setRequirementTypeId(RequirementType requirementTypeId) { + this.requirementTypeId = requirementTypeId; + } + + @XmlTransient + @JsonIgnore + public List getRiskControlHasRequirementList() { + return riskControlHasRequirementList; + } + + public void setRiskControlHasRequirementList(List riskControlHasRequirementList) { + this.riskControlHasRequirementList = riskControlHasRequirementList; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (id != null ? id.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + if (!(object instanceof Requirement)) { + return false; + } + Requirement other = (Requirement) object; + return this.id.equals(other.id); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.Requirement[ id=" + getId() + + ", uniqueId=" + getUniqueId() + + ", description=" + getDescription() + + " " + super.toString() + " ]"; + } + + @XmlTransient + @JsonIgnore + @Override + public List getHistoryList() { + return historyList; + } + + @Override + public void setHistoryList(List historyList) { + this.historyList = historyList; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/RequirementSpec.java b/VM-Core/src/main/java/com/validation/manager/core/db/RequirementSpec.java index 311ed1af..961d9360 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/RequirementSpec.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/RequirementSpec.java @@ -13,195 +13,195 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import java.util.Date; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.CascadeType; -import javax.persistence.Column; -import javax.persistence.EmbeddedId; -import javax.persistence.Entity; -import javax.persistence.JoinColumn; -import javax.persistence.Lob; -import javax.persistence.ManyToOne; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.OneToMany; -import javax.persistence.Table; -import javax.persistence.Temporal; -import javax.persistence.TemporalType; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "requirement_spec") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "RequirementSpec.findAll", - query = "SELECT r FROM RequirementSpec r") - , @NamedQuery(name = "RequirementSpec.findById", - query = "SELECT r FROM RequirementSpec r WHERE r.requirementSpecPK.id = :id") - , @NamedQuery(name = "RequirementSpec.findByProjectId", - query = "SELECT r FROM RequirementSpec r WHERE r.requirementSpecPK.projectId = :projectId") - , @NamedQuery(name = "RequirementSpec.findBySpecLevelId", - query = "SELECT r FROM RequirementSpec r WHERE r.requirementSpecPK.specLevelId = :specLevelId") - , @NamedQuery(name = "RequirementSpec.findByName", - query = "SELECT r FROM RequirementSpec r WHERE r.name = :name") - , @NamedQuery(name = "RequirementSpec.findByModificationDate", - query = "SELECT r FROM RequirementSpec r WHERE r.modificationDate = :modificationDate")}) -public class RequirementSpec implements Serializable { - - private static final long serialVersionUID = 1L; - @EmbeddedId - protected RequirementSpecPK requirementSpecPK; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 255) - @Column(name = "name") - private String name; - @Lob - @Size(max = 2147483647) - @Column(name = "description") - private String description; - @Basic(optional = false) - @NotNull - @Column(name = "modificationDate") - @Temporal(TemporalType.TIMESTAMP) - private Date modificationDate; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "requirementSpec") - private List requirementSpecNodeList; - @JoinColumn(name = "project_id", referencedColumnName = "id", - insertable = false, updatable = false) - @ManyToOne(optional = false) - private Project project; - @JoinColumn(name = "spec_level_id", referencedColumnName = "id", - insertable = false, updatable = false) - @ManyToOne(optional = false) - private SpecLevel specLevel; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "requirementSpec") - private List baselineList; - - public RequirementSpec() { - super(); - } - - public RequirementSpec(RequirementSpecPK requirementSpecPK) { - this.requirementSpecPK = requirementSpecPK; - } - - public RequirementSpec(RequirementSpecPK requirementSpecPK, - String name, Date modificationDate) { - super(); - this.requirementSpecPK = requirementSpecPK; - this.name = name; - this.modificationDate = modificationDate; - } - - public RequirementSpec(int projectId, int specLevelId) { - super(); - this.requirementSpecPK = new RequirementSpecPK(projectId, specLevelId); - } - - public RequirementSpecPK getRequirementSpecPK() { - return requirementSpecPK; - } - - public void setRequirementSpecPK(RequirementSpecPK requirementSpecPK) { - this.requirementSpecPK = requirementSpecPK; - } - - public String getName() { - return name; - } - - public void setName(String name) { - this.name = name; - } - - public String getDescription() { - return description; - } - - public void setDescription(String description) { - this.description = description; - } - - public Date getModificationDate() { - return modificationDate; - } - - public void setModificationDate(Date modificationDate) { - this.modificationDate = modificationDate; - } - - @XmlTransient - @JsonIgnore - public List getRequirementSpecNodeList() { - return requirementSpecNodeList; - } - - public void setRequirementSpecNodeList(List requirementSpecNodeList) { - this.requirementSpecNodeList = requirementSpecNodeList; - } - - public Project getProject() { - return project; - } - - public void setProject(Project project) { - this.project = project; - } - - public SpecLevel getSpecLevel() { - return specLevel; - } - - public void setSpecLevel(SpecLevel specLevel) { - this.specLevel = specLevel; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (requirementSpecPK != null ? requirementSpecPK.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof RequirementSpec)) { - return false; - } - RequirementSpec other = (RequirementSpec) object; - return !((this.requirementSpecPK == null - && other.requirementSpecPK != null) - || (this.requirementSpecPK != null - && !this.requirementSpecPK.equals(other.requirementSpecPK))); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.RequirementSpec[ requirementSpecPK=" - + requirementSpecPK + " ]"; - } - - @XmlTransient - @JsonIgnore - public List getBaselineList() { - return baselineList; - } - - public void setBaselineList(List baselineList) { - this.baselineList = baselineList; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import java.util.Date; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.CascadeType; +import javax.persistence.Column; +import javax.persistence.EmbeddedId; +import javax.persistence.Entity; +import javax.persistence.JoinColumn; +import javax.persistence.Lob; +import javax.persistence.ManyToOne; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.OneToMany; +import javax.persistence.Table; +import javax.persistence.Temporal; +import javax.persistence.TemporalType; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "requirement_spec") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "RequirementSpec.findAll", + query = "SELECT r FROM RequirementSpec r") + , @NamedQuery(name = "RequirementSpec.findById", + query = "SELECT r FROM RequirementSpec r WHERE r.requirementSpecPK.id = :id") + , @NamedQuery(name = "RequirementSpec.findByProjectId", + query = "SELECT r FROM RequirementSpec r WHERE r.requirementSpecPK.projectId = :projectId") + , @NamedQuery(name = "RequirementSpec.findBySpecLevelId", + query = "SELECT r FROM RequirementSpec r WHERE r.requirementSpecPK.specLevelId = :specLevelId") + , @NamedQuery(name = "RequirementSpec.findByName", + query = "SELECT r FROM RequirementSpec r WHERE r.name = :name") + , @NamedQuery(name = "RequirementSpec.findByModificationDate", + query = "SELECT r FROM RequirementSpec r WHERE r.modificationDate = :modificationDate")}) +public class RequirementSpec implements Serializable { + + private static final long serialVersionUID = 1L; + @EmbeddedId + protected RequirementSpecPK requirementSpecPK; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 255) + @Column(name = "name") + private String name; + @Lob + @Size(max = 2_147_483_647) + @Column(name = "description") + private String description; + @Basic(optional = false) + @NotNull + @Column(name = "modificationDate") + @Temporal(TemporalType.TIMESTAMP) + private Date modificationDate; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "requirementSpec") + private List requirementSpecNodeList; + @JoinColumn(name = "project_id", referencedColumnName = "id", + insertable = false, updatable = false) + @ManyToOne(optional = false) + private Project project; + @JoinColumn(name = "spec_level_id", referencedColumnName = "id", + insertable = false, updatable = false) + @ManyToOne(optional = false) + private SpecLevel specLevel; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "requirementSpec") + private List baselineList; + + public RequirementSpec() { + super(); + } + + public RequirementSpec(RequirementSpecPK requirementSpecPK) { + this.requirementSpecPK = requirementSpecPK; + } + + public RequirementSpec(RequirementSpecPK requirementSpecPK, + String name, Date modificationDate) { + super(); + this.requirementSpecPK = requirementSpecPK; + this.name = name; + this.modificationDate = modificationDate; + } + + public RequirementSpec(int projectId, int specLevelId) { + super(); + this.requirementSpecPK = new RequirementSpecPK(projectId, specLevelId); + } + + public RequirementSpecPK getRequirementSpecPK() { + return requirementSpecPK; + } + + public void setRequirementSpecPK(RequirementSpecPK requirementSpecPK) { + this.requirementSpecPK = requirementSpecPK; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public Date getModificationDate() { + return modificationDate; + } + + public void setModificationDate(Date modificationDate) { + this.modificationDate = modificationDate; + } + + @XmlTransient + @JsonIgnore + public List getRequirementSpecNodeList() { + return requirementSpecNodeList; + } + + public void setRequirementSpecNodeList(List requirementSpecNodeList) { + this.requirementSpecNodeList = requirementSpecNodeList; + } + + public Project getProject() { + return project; + } + + public void setProject(Project project) { + this.project = project; + } + + public SpecLevel getSpecLevel() { + return specLevel; + } + + public void setSpecLevel(SpecLevel specLevel) { + this.specLevel = specLevel; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (requirementSpecPK != null ? requirementSpecPK.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof RequirementSpec)) { + return false; + } + RequirementSpec other = (RequirementSpec) object; + return !((this.requirementSpecPK == null + && other.requirementSpecPK != null) + || (this.requirementSpecPK != null + && !this.requirementSpecPK.equals(other.requirementSpecPK))); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.RequirementSpec[ requirementSpecPK=" + + requirementSpecPK + " ]"; + } + + @XmlTransient + @JsonIgnore + public List getBaselineList() { + return baselineList; + } + + public void setBaselineList(List baselineList) { + this.baselineList = baselineList; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/RequirementSpecNode.java b/VM-Core/src/main/java/com/validation/manager/core/db/RequirementSpecNode.java index 8a322c02..abe1f015 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/RequirementSpecNode.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/RequirementSpecNode.java @@ -13,210 +13,210 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.CascadeType; -import javax.persistence.Column; -import javax.persistence.EmbeddedId; -import javax.persistence.Entity; -import javax.persistence.JoinColumn; -import javax.persistence.JoinColumns; -import javax.persistence.Lob; -import javax.persistence.ManyToOne; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.OneToMany; -import javax.persistence.Table; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "requirement_spec_node") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "RequirementSpecNode.findAll", - query = "SELECT r FROM RequirementSpecNode r") - , @NamedQuery(name = "RequirementSpecNode.findById", - query = "SELECT r FROM RequirementSpecNode r WHERE r.requirementSpecNodePK.id = :id") - , @NamedQuery(name = "RequirementSpecNode.findByRequirementSpecId", - query = "SELECT r FROM RequirementSpecNode r WHERE r.requirementSpecNodePK.requirementSpecId = :requirementSpecId") - , @NamedQuery(name = "RequirementSpecNode.findByRequirementSpecProjectId", - query = "SELECT r FROM RequirementSpecNode r WHERE r.requirementSpecNodePK.requirementSpecProjectId = :requirementSpecProjectId") - , @NamedQuery(name = "RequirementSpecNode.findByRequirementSpecSpecLevelId", - query = "SELECT r FROM RequirementSpecNode r WHERE r.requirementSpecNodePK.requirementSpecSpecLevelId = :requirementSpecSpecLevelId") - , @NamedQuery(name = "RequirementSpecNode.findByName", - query = "SELECT r FROM RequirementSpecNode r WHERE r.name = :name")}) -public class RequirementSpecNode implements Serializable { - - private static final long serialVersionUID = 1L; - @EmbeddedId - protected RequirementSpecNodePK requirementSpecNodePK; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 255) - @Column(name = "name") - private String name; - @Lob - @Size(max = 2147483647) - @Column(name = "description") - private String description; - @Lob - @Size(max = 2147483647) - @Column(name = "scope") - private String scope; - @JoinColumns({ - @JoinColumn(name = "requirement_spec_id", referencedColumnName = "id", - insertable = false, updatable = false) - , @JoinColumn(name = "requirement_spec_project_id", - referencedColumnName = "project_id", insertable = false, - updatable = false) - , @JoinColumn(name = "requirement_spec_spec_level_id", - referencedColumnName = "spec_level_id", insertable = false, - updatable = false)}) - @ManyToOne(optional = false) - private RequirementSpec requirementSpec; - @OneToMany(mappedBy = "requirementSpecNode") - private List requirementSpecNodeList; - @JoinColumns({ - @JoinColumn(name = "requirement_spec_node_id", - referencedColumnName = "id") - , @JoinColumn(name = "requirement_spec_node_requirement_spec_id", - referencedColumnName = "requirement_spec_id") - , @JoinColumn(name = "requirement_spec_node_requirement_spec_project_id", - referencedColumnName = "requirement_spec_project_id") - , @JoinColumn(name = "requirement_spec_node_requirement_spec_spec_level_id", - referencedColumnName = "requirement_spec_spec_level_id")}) - @ManyToOne - private RequirementSpecNode requirementSpecNode; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "requirementSpecNode") - private List requirementList; - - public RequirementSpecNode() { - } - - public RequirementSpecNode(RequirementSpecNodePK requirementSpecNodePK) { - this.requirementSpecNodePK = requirementSpecNodePK; - } - - public RequirementSpecNode(RequirementSpecNodePK requirementSpecNodePK, - String name) { - this.requirementSpecNodePK = requirementSpecNodePK; - this.name = name; - } - - public RequirementSpecNode(RequirementSpecPK pk) { - this.requirementSpecNodePK = new RequirementSpecNodePK(pk.getId(), - pk.getProjectId(), pk.getSpecLevelId()); - } - - public RequirementSpecNode(int requirementSpecId, - int requirementSpecProjectId, int requirementSpecSpecLevelId) { - this.requirementSpecNodePK - = new RequirementSpecNodePK(requirementSpecId, - requirementSpecProjectId, requirementSpecSpecLevelId); - } - - public RequirementSpecNodePK getRequirementSpecNodePK() { - return requirementSpecNodePK; - } - - public void setRequirementSpecNodePK(RequirementSpecNodePK requirementSpecNodePK) { - this.requirementSpecNodePK = requirementSpecNodePK; - } - - public String getName() { - return name; - } - - public void setName(String name) { - this.name = name; - } - - public String getDescription() { - return description; - } - - public void setDescription(String description) { - this.description = description; - } - - public String getScope() { - return scope; - } - - public void setScope(String scope) { - this.scope = scope; - } - - public RequirementSpec getRequirementSpec() { - return requirementSpec; - } - - public void setRequirementSpec(RequirementSpec requirementSpec) { - this.requirementSpec = requirementSpec; - } - - @XmlTransient - @JsonIgnore - public List getRequirementSpecNodeList() { - return requirementSpecNodeList; - } - - public void setRequirementSpecNodeList(List requirementSpecNodeList) { - this.requirementSpecNodeList = requirementSpecNodeList; - } - - public RequirementSpecNode getRequirementSpecNode() { - return requirementSpecNode; - } - - public void setRequirementSpecNode(RequirementSpecNode requirementSpecNode) { - this.requirementSpecNode = requirementSpecNode; - } - - @XmlTransient - @JsonIgnore - public List getRequirementList() { - return requirementList; - } - - public void setRequirementList(List requirementList) { - this.requirementList = requirementList; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (requirementSpecNodePK != null ? requirementSpecNodePK.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof RequirementSpecNode)) { - return false; - } - RequirementSpecNode other = (RequirementSpecNode) object; - return !((this.requirementSpecNodePK == null - && other.requirementSpecNodePK != null) - || (this.requirementSpecNodePK != null - && !this.requirementSpecNodePK.equals(other.requirementSpecNodePK))); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.RequirementSpecNode[ requirementSpecNodePK=" - + requirementSpecNodePK + " ]"; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.CascadeType; +import javax.persistence.Column; +import javax.persistence.EmbeddedId; +import javax.persistence.Entity; +import javax.persistence.JoinColumn; +import javax.persistence.JoinColumns; +import javax.persistence.Lob; +import javax.persistence.ManyToOne; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.OneToMany; +import javax.persistence.Table; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "requirement_spec_node") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "RequirementSpecNode.findAll", + query = "SELECT r FROM RequirementSpecNode r") + , @NamedQuery(name = "RequirementSpecNode.findById", + query = "SELECT r FROM RequirementSpecNode r WHERE r.requirementSpecNodePK.id = :id") + , @NamedQuery(name = "RequirementSpecNode.findByRequirementSpecId", + query = "SELECT r FROM RequirementSpecNode r WHERE r.requirementSpecNodePK.requirementSpecId = :requirementSpecId") + , @NamedQuery(name = "RequirementSpecNode.findByRequirementSpecProjectId", + query = "SELECT r FROM RequirementSpecNode r WHERE r.requirementSpecNodePK.requirementSpecProjectId = :requirementSpecProjectId") + , @NamedQuery(name = "RequirementSpecNode.findByRequirementSpecSpecLevelId", + query = "SELECT r FROM RequirementSpecNode r WHERE r.requirementSpecNodePK.requirementSpecSpecLevelId = :requirementSpecSpecLevelId") + , @NamedQuery(name = "RequirementSpecNode.findByName", + query = "SELECT r FROM RequirementSpecNode r WHERE r.name = :name")}) +public class RequirementSpecNode implements Serializable { + + private static final long serialVersionUID = 1L; + @EmbeddedId + protected RequirementSpecNodePK requirementSpecNodePK; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 255) + @Column(name = "name") + private String name; + @Lob + @Size(max = 2_147_483_647) + @Column(name = "description") + private String description; + @Lob + @Size(max = 2_147_483_647) + @Column(name = "scope") + private String scope; + @JoinColumns({ + @JoinColumn(name = "requirement_spec_id", referencedColumnName = "id", + insertable = false, updatable = false) + , @JoinColumn(name = "requirement_spec_project_id", + referencedColumnName = "project_id", insertable = false, + updatable = false) + , @JoinColumn(name = "requirement_spec_spec_level_id", + referencedColumnName = "spec_level_id", insertable = false, + updatable = false)}) + @ManyToOne(optional = false) + private RequirementSpec requirementSpec; + @OneToMany(mappedBy = "requirementSpecNode") + private List requirementSpecNodeList; + @JoinColumns({ + @JoinColumn(name = "requirement_spec_node_id", + referencedColumnName = "id") + , @JoinColumn(name = "requirement_spec_node_requirement_spec_id", + referencedColumnName = "requirement_spec_id") + , @JoinColumn(name = "requirement_spec_node_requirement_spec_project_id", + referencedColumnName = "requirement_spec_project_id") + , @JoinColumn(name = "requirement_spec_node_requirement_spec_spec_level_id", + referencedColumnName = "requirement_spec_spec_level_id")}) + @ManyToOne + private RequirementSpecNode requirementSpecNode; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "requirementSpecNode") + private List requirementList; + + public RequirementSpecNode() { + } + + public RequirementSpecNode(RequirementSpecNodePK requirementSpecNodePK) { + this.requirementSpecNodePK = requirementSpecNodePK; + } + + public RequirementSpecNode(RequirementSpecNodePK requirementSpecNodePK, + String name) { + this.requirementSpecNodePK = requirementSpecNodePK; + this.name = name; + } + + public RequirementSpecNode(RequirementSpecPK pk) { + this.requirementSpecNodePK = new RequirementSpecNodePK(pk.getId(), + pk.getProjectId(), pk.getSpecLevelId()); + } + + public RequirementSpecNode(int requirementSpecId, + int requirementSpecProjectId, int requirementSpecSpecLevelId) { + this.requirementSpecNodePK + = new RequirementSpecNodePK(requirementSpecId, + requirementSpecProjectId, requirementSpecSpecLevelId); + } + + public RequirementSpecNodePK getRequirementSpecNodePK() { + return requirementSpecNodePK; + } + + public void setRequirementSpecNodePK(RequirementSpecNodePK requirementSpecNodePK) { + this.requirementSpecNodePK = requirementSpecNodePK; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public String getScope() { + return scope; + } + + public void setScope(String scope) { + this.scope = scope; + } + + public RequirementSpec getRequirementSpec() { + return requirementSpec; + } + + public void setRequirementSpec(RequirementSpec requirementSpec) { + this.requirementSpec = requirementSpec; + } + + @XmlTransient + @JsonIgnore + public List getRequirementSpecNodeList() { + return requirementSpecNodeList; + } + + public void setRequirementSpecNodeList(List requirementSpecNodeList) { + this.requirementSpecNodeList = requirementSpecNodeList; + } + + public RequirementSpecNode getRequirementSpecNode() { + return requirementSpecNode; + } + + public void setRequirementSpecNode(RequirementSpecNode requirementSpecNode) { + this.requirementSpecNode = requirementSpecNode; + } + + @XmlTransient + @JsonIgnore + public List getRequirementList() { + return requirementList; + } + + public void setRequirementList(List requirementList) { + this.requirementList = requirementList; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (requirementSpecNodePK != null ? requirementSpecNodePK.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof RequirementSpecNode)) { + return false; + } + RequirementSpecNode other = (RequirementSpecNode) object; + return !((this.requirementSpecNodePK == null + && other.requirementSpecNodePK != null) + || (this.requirementSpecNodePK != null + && !this.requirementSpecNodePK.equals(other.requirementSpecNodePK))); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.RequirementSpecNode[ requirementSpecNodePK=" + + requirementSpecNodePK + " ]"; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/RequirementSpecNodePK.java b/VM-Core/src/main/java/com/validation/manager/core/db/RequirementSpecNodePK.java index 2f76c9b8..fdad1f04 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/RequirementSpecNodePK.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/RequirementSpecNodePK.java @@ -13,125 +13,125 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import javax.persistence.Basic; -import javax.persistence.Column; -import javax.persistence.Embeddable; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.TableGenerator; -import javax.validation.constraints.NotNull; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Embeddable -public class RequirementSpecNodePK implements Serializable { - - @Basic(optional = false) - @GeneratedValue(strategy = GenerationType.TABLE, - generator = "RequirementSpecNodeGen") - @TableGenerator(name = "RequirementSpecNodeGen", table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "requirement_spec_node", - allocationSize = 1, - initialValue = 1000) - @NotNull - @Column(name = "id") - private int id; - @Basic(optional = false) - @NotNull - @Column(name = "requirement_spec_id") - private int requirementSpecId; - @Basic(optional = false) - @NotNull - @Column(name = "requirement_spec_project_id") - private int requirementSpecProjectId; - @Basic(optional = false) - @NotNull - @Column(name = "requirement_spec_spec_level_id") - private int requirementSpecSpecLevelId; - - public RequirementSpecNodePK() { - } - - public RequirementSpecNodePK(int requirementSpecId, - int requirementSpecProjectId, int requirementSpecSpecLevelId) { - this.requirementSpecId = requirementSpecId; - this.requirementSpecProjectId = requirementSpecProjectId; - this.requirementSpecSpecLevelId = requirementSpecSpecLevelId; - } - - public int getId() { - return id; - } - - public void setId(int id) { - this.id = id; - } - - public int getRequirementSpecId() { - return requirementSpecId; - } - - public void setRequirementSpecId(int requirementSpecId) { - this.requirementSpecId = requirementSpecId; - } - - public int getRequirementSpecProjectId() { - return requirementSpecProjectId; - } - - public void setRequirementSpecProjectId(int requirementSpecProjectId) { - this.requirementSpecProjectId = requirementSpecProjectId; - } - - public int getRequirementSpecSpecLevelId() { - return requirementSpecSpecLevelId; - } - - public void setRequirementSpecSpecLevelId(int requirementSpecSpecLevelId) { - this.requirementSpecSpecLevelId = requirementSpecSpecLevelId; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (int) id; - hash += (int) requirementSpecId; - hash += (int) requirementSpecProjectId; - hash += (int) requirementSpecSpecLevelId; - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof RequirementSpecNodePK)) { - return false; - } - RequirementSpecNodePK other = (RequirementSpecNodePK) object; - if (this.id != other.id) { - return false; - } - if (this.requirementSpecId != other.requirementSpecId) { - return false; - } - if (this.requirementSpecProjectId != other.requirementSpecProjectId) { - return false; - } - return this.requirementSpecSpecLevelId == other.requirementSpecSpecLevelId; - } - - @Override - public String toString() { - return "com.validation.manager.core.db.RequirementSpecNodePK[ id=" - + id + ", requirementSpecId=" + requirementSpecId - + ", requirementSpecProjectId=" + requirementSpecProjectId - + ", requirementSpecSpecLevelId=" + requirementSpecSpecLevelId + " ]"; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import javax.persistence.Basic; +import javax.persistence.Column; +import javax.persistence.Embeddable; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.TableGenerator; +import javax.validation.constraints.NotNull; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Embeddable +public class RequirementSpecNodePK implements Serializable { + + @Basic(optional = false) + @GeneratedValue(strategy = GenerationType.TABLE, + generator = "RequirementSpecNodeGen") + @TableGenerator(name = "RequirementSpecNodeGen", table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "requirement_spec_node", + allocationSize = 1, + initialValue = 1_000) + @NotNull + @Column(name = "id") + private int id; + @Basic(optional = false) + @NotNull + @Column(name = "requirement_spec_id") + private int requirementSpecId; + @Basic(optional = false) + @NotNull + @Column(name = "requirement_spec_project_id") + private int requirementSpecProjectId; + @Basic(optional = false) + @NotNull + @Column(name = "requirement_spec_spec_level_id") + private int requirementSpecSpecLevelId; + + public RequirementSpecNodePK() { + } + + public RequirementSpecNodePK(int requirementSpecId, + int requirementSpecProjectId, int requirementSpecSpecLevelId) { + this.requirementSpecId = requirementSpecId; + this.requirementSpecProjectId = requirementSpecProjectId; + this.requirementSpecSpecLevelId = requirementSpecSpecLevelId; + } + + public int getId() { + return id; + } + + public void setId(int id) { + this.id = id; + } + + public int getRequirementSpecId() { + return requirementSpecId; + } + + public void setRequirementSpecId(int requirementSpecId) { + this.requirementSpecId = requirementSpecId; + } + + public int getRequirementSpecProjectId() { + return requirementSpecProjectId; + } + + public void setRequirementSpecProjectId(int requirementSpecProjectId) { + this.requirementSpecProjectId = requirementSpecProjectId; + } + + public int getRequirementSpecSpecLevelId() { + return requirementSpecSpecLevelId; + } + + public void setRequirementSpecSpecLevelId(int requirementSpecSpecLevelId) { + this.requirementSpecSpecLevelId = requirementSpecSpecLevelId; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (int) id; + hash += (int) requirementSpecId; + hash += (int) requirementSpecProjectId; + hash += (int) requirementSpecSpecLevelId; + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof RequirementSpecNodePK)) { + return false; + } + RequirementSpecNodePK other = (RequirementSpecNodePK) object; + if (this.id != other.id) { + return false; + } + if (this.requirementSpecId != other.requirementSpecId) { + return false; + } + if (this.requirementSpecProjectId != other.requirementSpecProjectId) { + return false; + } + return this.requirementSpecSpecLevelId == other.requirementSpecSpecLevelId; + } + + @Override + public String toString() { + return "com.validation.manager.core.db.RequirementSpecNodePK[ id=" + + id + ", requirementSpecId=" + requirementSpecId + + ", requirementSpecProjectId=" + requirementSpecProjectId + + ", requirementSpecSpecLevelId=" + requirementSpecSpecLevelId + " ]"; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/RequirementSpecPK.java b/VM-Core/src/main/java/com/validation/manager/core/db/RequirementSpecPK.java index 73396a14..df54ea48 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/RequirementSpecPK.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/RequirementSpecPK.java @@ -13,105 +13,105 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import javax.persistence.Basic; -import javax.persistence.Column; -import javax.persistence.Embeddable; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.TableGenerator; -import javax.validation.constraints.NotNull; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Embeddable -public class RequirementSpecPK implements Serializable { - - @Basic(optional = false) - @GeneratedValue(strategy = GenerationType.TABLE, generator = "ReqSpecGen") - @TableGenerator(name = "ReqSpecGen", table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "requirement_spec", - allocationSize = 1, - initialValue = 1000) - @NotNull - @Column(name = "id") - private int id; - @Basic(optional = false) - @NotNull - @Column(name = "project_id") - private int projectId; - @Basic(optional = false) - @NotNull - @Column(name = "spec_level_id") - private int specLevelId; - - public RequirementSpecPK() { - } - - public RequirementSpecPK(int projectId, int specLevelId) { - this.projectId = projectId; - this.specLevelId = specLevelId; - } - - public int getId() { - return id; - } - - public void setId(int id) { - this.id = id; - } - - public int getProjectId() { - return projectId; - } - - public void setProjectId(int projectId) { - this.projectId = projectId; - } - - public int getSpecLevelId() { - return specLevelId; - } - - public void setSpecLevelId(int specLevelId) { - this.specLevelId = specLevelId; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (int) id; - hash += (int) projectId; - hash += (int) specLevelId; - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof RequirementSpecPK)) { - return false; - } - RequirementSpecPK other = (RequirementSpecPK) object; - if (this.id != other.id) { - return false; - } - if (this.projectId != other.projectId) { - return false; - } - return this.specLevelId == other.specLevelId; - } - - @Override - public String toString() { - return "com.validation.manager.core.db.RequirementSpecPK[ id=" + id - + ", projectId=" + projectId + ", specLevelId=" + specLevelId + " ]"; - } - -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import javax.persistence.Basic; +import javax.persistence.Column; +import javax.persistence.Embeddable; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.TableGenerator; +import javax.validation.constraints.NotNull; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Embeddable +public class RequirementSpecPK implements Serializable { + + @Basic(optional = false) + @GeneratedValue(strategy = GenerationType.TABLE, generator = "ReqSpecGen") + @TableGenerator(name = "ReqSpecGen", table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "requirement_spec", + allocationSize = 1, + initialValue = 1_000) + @NotNull + @Column(name = "id") + private int id; + @Basic(optional = false) + @NotNull + @Column(name = "project_id") + private int projectId; + @Basic(optional = false) + @NotNull + @Column(name = "spec_level_id") + private int specLevelId; + + public RequirementSpecPK() { + } + + public RequirementSpecPK(int projectId, int specLevelId) { + this.projectId = projectId; + this.specLevelId = specLevelId; + } + + public int getId() { + return id; + } + + public void setId(int id) { + this.id = id; + } + + public int getProjectId() { + return projectId; + } + + public void setProjectId(int projectId) { + this.projectId = projectId; + } + + public int getSpecLevelId() { + return specLevelId; + } + + public void setSpecLevelId(int specLevelId) { + this.specLevelId = specLevelId; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (int) id; + hash += (int) projectId; + hash += (int) specLevelId; + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof RequirementSpecPK)) { + return false; + } + RequirementSpecPK other = (RequirementSpecPK) object; + if (this.id != other.id) { + return false; + } + if (this.projectId != other.projectId) { + return false; + } + return this.specLevelId == other.specLevelId; + } + + @Override + public String toString() { + return "com.validation.manager.core.db.RequirementSpecPK[ id=" + id + + ", projectId=" + projectId + ", specLevelId=" + specLevelId + " ]"; + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/RequirementStatus.java b/VM-Core/src/main/java/com/validation/manager/core/db/RequirementStatus.java index 9c2cd3c9..87c14762 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/RequirementStatus.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/RequirementStatus.java @@ -13,118 +13,118 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.CascadeType; -import javax.persistence.Column; -import javax.persistence.Entity; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.Id; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.OneToMany; -import javax.persistence.Table; -import javax.persistence.TableGenerator; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "requirement_status") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "RequirementStatus.findAll", - query = "SELECT r FROM RequirementStatus r") - , @NamedQuery(name = "RequirementStatus.findById", - query = "SELECT r FROM RequirementStatus r WHERE r.id = :id") - , @NamedQuery(name = "RequirementStatus.findByStatus", - query = "SELECT r FROM RequirementStatus r WHERE r.status = :status")}) -public class RequirementStatus implements Serializable { - - private static final long serialVersionUID = 1L; - @Id - @GeneratedValue(strategy = GenerationType.TABLE, - generator = "ReqStatusGen") - @TableGenerator(name = "ReqStatusGen", table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "requirement_status", - allocationSize = 1, - initialValue = 1000) - @Basic(optional = false) - @Column(name = "id") - private Integer id; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 255) - @Column(name = "status") - private String status; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "requirementStatusId") - private List requirementList; - - public RequirementStatus() { - } - - public RequirementStatus(String status) { - this.status = status; - } - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - public String getStatus() { - return status; - } - - public void setStatus(String status) { - this.status = status; - } - - @XmlTransient - @JsonIgnore - public List getRequirementList() { - return requirementList; - } - - public void setRequirementList(List requirementList) { - this.requirementList = requirementList; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (id != null ? id.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof RequirementStatus)) { - return false; - } - RequirementStatus other = (RequirementStatus) object; - return !((this.id == null && other.id != null) - || (this.id != null && !this.id.equals(other.id))); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.RequirementStatus[ id=" + id + " ]"; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.CascadeType; +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.Id; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.OneToMany; +import javax.persistence.Table; +import javax.persistence.TableGenerator; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "requirement_status") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "RequirementStatus.findAll", + query = "SELECT r FROM RequirementStatus r") + , @NamedQuery(name = "RequirementStatus.findById", + query = "SELECT r FROM RequirementStatus r WHERE r.id = :id") + , @NamedQuery(name = "RequirementStatus.findByStatus", + query = "SELECT r FROM RequirementStatus r WHERE r.status = :status")}) +public class RequirementStatus implements Serializable { + + private static final long serialVersionUID = 1L; + @Id + @GeneratedValue(strategy = GenerationType.TABLE, + generator = "ReqStatusGen") + @TableGenerator(name = "ReqStatusGen", table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "requirement_status", + allocationSize = 1, + initialValue = 1_000) + @Basic(optional = false) + @Column(name = "id") + private Integer id; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 255) + @Column(name = "status") + private String status; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "requirementStatusId") + private List requirementList; + + public RequirementStatus() { + } + + public RequirementStatus(String status) { + this.status = status; + } + + public Integer getId() { + return id; + } + + public void setId(Integer id) { + this.id = id; + } + + public String getStatus() { + return status; + } + + public void setStatus(String status) { + this.status = status; + } + + @XmlTransient + @JsonIgnore + public List getRequirementList() { + return requirementList; + } + + public void setRequirementList(List requirementList) { + this.requirementList = requirementList; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (id != null ? id.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof RequirementStatus)) { + return false; + } + RequirementStatus other = (RequirementStatus) object; + return !((this.id == null && other.id != null) + || (this.id != null && !this.id.equals(other.id))); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.RequirementStatus[ id=" + id + " ]"; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/RequirementType.java b/VM-Core/src/main/java/com/validation/manager/core/db/RequirementType.java index ea37099e..1a1b185a 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/RequirementType.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/RequirementType.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,153 +13,153 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.CascadeType; -import javax.persistence.Column; -import javax.persistence.Entity; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.Id; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.OneToMany; -import javax.persistence.Table; -import javax.persistence.TableGenerator; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "requirement_type") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "RequirementType.findAll", - query = "SELECT r FROM RequirementType r") - , @NamedQuery(name = "RequirementType.findById", - query = "SELECT r FROM RequirementType r WHERE r.id = :id") - , @NamedQuery(name = "RequirementType.findByName", - query = "SELECT r FROM RequirementType r WHERE r.name = :name") - , @NamedQuery(name = "RequirementType.findByDescription", - query = "SELECT r FROM RequirementType r WHERE " - + "r.description = :description")}) -public class RequirementType implements Serializable { - - @Basic(optional = false) - @NotNull - @Column(name = "level") - private int level; - - private static final long serialVersionUID = 1L; - @Id - @Basic(optional = false) - @GeneratedValue(strategy = GenerationType.TABLE, - generator = "ReqTypeGen") - @TableGenerator(name = "ReqType", table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "requirement_type", - allocationSize = 1, - initialValue = 1000) - @NotNull - @Column(name = "id") - private Integer id; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 255) - @Column(name = "name") - private String name; - @Size(max = 255) - @Column(name = "description") - private String description; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "requirementTypeId") - private List requirementList; - - public RequirementType() { - super(); - } - - public RequirementType(String name) { - super(); - this.name = name; - } - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - public String getName() { - return name; - } - - public void setName(String name) { - this.name = name; - } - - public String getDescription() { - return description; - } - - public void setDescription(String description) { - this.description = description; - } - - @XmlTransient - @JsonIgnore - public List getRequirementList() { - return requirementList; - } - - public void setRequirementList(List requirementList) { - this.requirementList = requirementList; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (id != null ? id.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof RequirementType)) { - return false; - } - RequirementType other = (RequirementType) object; - return !this.id.equals(other.id); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.RequirementType[ id=" + id + " ]"; - } - - /** - * @return the level - */ - public int getLevel() { - return level; - } - - /** - * @param level the level to set - */ - public void setLevel(int level) { - this.level = level; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.CascadeType; +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.Id; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.OneToMany; +import javax.persistence.Table; +import javax.persistence.TableGenerator; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "requirement_type") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "RequirementType.findAll", + query = "SELECT r FROM RequirementType r") + , @NamedQuery(name = "RequirementType.findById", + query = "SELECT r FROM RequirementType r WHERE r.id = :id") + , @NamedQuery(name = "RequirementType.findByName", + query = "SELECT r FROM RequirementType r WHERE r.name = :name") + , @NamedQuery(name = "RequirementType.findByDescription", + query = "SELECT r FROM RequirementType r WHERE " + + "r.description = :description")}) +public class RequirementType implements Serializable { + + @Basic(optional = false) + @NotNull + @Column(name = "level") + private int level; + + private static final long serialVersionUID = 1L; + @Id + @Basic(optional = false) + @GeneratedValue(strategy = GenerationType.TABLE, + generator = "ReqTypeGen") + @TableGenerator(name = "ReqTypeGen", table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "requirement_type", + allocationSize = 1, + initialValue = 1_000) + @NotNull + @Column(name = "id") + private Integer id; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 255) + @Column(name = "name") + private String name; + @Size(max = 255) + @Column(name = "description") + private String description; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "requirementTypeId") + private List requirementList; + + public RequirementType() { + super(); + } + + public RequirementType(String name) { + super(); + this.name = name; + } + + public Integer getId() { + return id; + } + + public void setId(Integer id) { + this.id = id; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + @XmlTransient + @JsonIgnore + public List getRequirementList() { + return requirementList; + } + + public void setRequirementList(List requirementList) { + this.requirementList = requirementList; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (id != null ? id.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof RequirementType)) { + return false; + } + RequirementType other = (RequirementType) object; + return !this.id.equals(other.id); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.RequirementType[ id=" + id + " ]"; + } + + /** + * @return the level + */ + public int getLevel() { + return level; + } + + /** + * @param level the level to set + */ + public void setLevel(int level) { + this.level = level; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/RiskCategory.java b/VM-Core/src/main/java/com/validation/manager/core/db/RiskCategory.java index 96f1c92d..c3db294c 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/RiskCategory.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/RiskCategory.java @@ -13,160 +13,160 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.CascadeType; -import javax.persistence.Column; -import javax.persistence.Entity; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.Id; -import javax.persistence.ManyToMany; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.OneToMany; -import javax.persistence.Table; -import javax.persistence.TableGenerator; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "risk_category") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "RiskCategory.findAll", - query = "SELECT r FROM RiskCategory r") - , @NamedQuery(name = "RiskCategory.findById", - query = "SELECT r FROM RiskCategory r WHERE r.id = :id") - , @NamedQuery(name = "RiskCategory.findByName", - query = "SELECT r FROM RiskCategory r WHERE r.name = :name") - , @NamedQuery(name = "RiskCategory.findByMinimum", - query = "SELECT r FROM RiskCategory r WHERE r.minimum = :minimum") - , @NamedQuery(name = "RiskCategory.findByMaximum", - query = "SELECT r FROM RiskCategory r WHERE r.maximum = :maximum")}) -public class RiskCategory implements Serializable { - - private static final long serialVersionUID = 1L; - @Id - @GeneratedValue(strategy = GenerationType.TABLE, generator = "RCGen") - @TableGenerator(name = "RCGen", table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "risk_category", - allocationSize = 1, - initialValue = 1000) - @Basic(optional = false) - @Column(name = "id") - private Integer id; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 45) - @Column(name = "name") - private String name; - @Basic(optional = false) - @NotNull - @Column(name = "minimum") - private int minimum; - @Basic(optional = false) - @NotNull - @Column(name = "maximum") - private int maximum; - @ManyToMany(mappedBy = "riskCategoryList") - private List fmeaList; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "riskCategory") - private List riskItemHasRiskCategoryList; - - public RiskCategory() { - } - - public RiskCategory(String name, int minimum, int maximum) { - this.name = name; - this.minimum = minimum; - this.maximum = maximum; - } - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - public String getName() { - return name; - } - - public void setName(String name) { - this.name = name; - } - - public int getMinimum() { - return minimum; - } - - public void setMinimum(int minimum) { - this.minimum = minimum; - } - - public int getMaximum() { - return maximum; - } - - public void setMaximum(int maximum) { - this.maximum = maximum; - } - - @XmlTransient - @JsonIgnore - public List getFmeaList() { - return fmeaList; - } - - public void setFmeaList(List fmeaList) { - this.fmeaList = fmeaList; - } - - @XmlTransient - @JsonIgnore - public List getRiskItemHasRiskCategoryList() { - return riskItemHasRiskCategoryList; - } - - public void setRiskItemHasRiskCategoryList(List riskItemHasRiskCategoryList) { - this.riskItemHasRiskCategoryList = riskItemHasRiskCategoryList; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (id != null ? id.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof RiskCategory)) { - return false; - } - RiskCategory other = (RiskCategory) object; - return !((this.id == null && other.id != null) - || (this.id != null && !this.id.equals(other.id))); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.RiskCategory[ id=" + id + " ]"; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.CascadeType; +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.Id; +import javax.persistence.ManyToMany; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.OneToMany; +import javax.persistence.Table; +import javax.persistence.TableGenerator; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "risk_category") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "RiskCategory.findAll", + query = "SELECT r FROM RiskCategory r") + , @NamedQuery(name = "RiskCategory.findById", + query = "SELECT r FROM RiskCategory r WHERE r.id = :id") + , @NamedQuery(name = "RiskCategory.findByName", + query = "SELECT r FROM RiskCategory r WHERE r.name = :name") + , @NamedQuery(name = "RiskCategory.findByMinimum", + query = "SELECT r FROM RiskCategory r WHERE r.minimum = :minimum") + , @NamedQuery(name = "RiskCategory.findByMaximum", + query = "SELECT r FROM RiskCategory r WHERE r.maximum = :maximum")}) +public class RiskCategory implements Serializable { + + private static final long serialVersionUID = 1L; + @Id + @GeneratedValue(strategy = GenerationType.TABLE, generator = "RCGen") + @TableGenerator(name = "RCGen", table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "risk_category", + allocationSize = 1, + initialValue = 1_000) + @Basic(optional = false) + @Column(name = "id") + private Integer id; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 45) + @Column(name = "name") + private String name; + @Basic(optional = false) + @NotNull + @Column(name = "minimum") + private int minimum; + @Basic(optional = false) + @NotNull + @Column(name = "maximum") + private int maximum; + @ManyToMany(mappedBy = "riskCategoryList") + private List fmeaList; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "riskCategory") + private List riskItemHasRiskCategoryList; + + public RiskCategory() { + } + + public RiskCategory(String name, int minimum, int maximum) { + this.name = name; + this.minimum = minimum; + this.maximum = maximum; + } + + public Integer getId() { + return id; + } + + public void setId(Integer id) { + this.id = id; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public int getMinimum() { + return minimum; + } + + public void setMinimum(int minimum) { + this.minimum = minimum; + } + + public int getMaximum() { + return maximum; + } + + public void setMaximum(int maximum) { + this.maximum = maximum; + } + + @XmlTransient + @JsonIgnore + public List getFmeaList() { + return fmeaList; + } + + public void setFmeaList(List fmeaList) { + this.fmeaList = fmeaList; + } + + @XmlTransient + @JsonIgnore + public List getRiskItemHasRiskCategoryList() { + return riskItemHasRiskCategoryList; + } + + public void setRiskItemHasRiskCategoryList(List riskItemHasRiskCategoryList) { + this.riskItemHasRiskCategoryList = riskItemHasRiskCategoryList; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (id != null ? id.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof RiskCategory)) { + return false; + } + RiskCategory other = (RiskCategory) object; + return !((this.id == null && other.id != null) + || (this.id != null && !this.id.equals(other.id))); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.RiskCategory[ id=" + id + " ]"; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/RiskControlPK.java b/VM-Core/src/main/java/com/validation/manager/core/db/RiskControlPK.java index 0c1492a0..e9dd0147 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/RiskControlPK.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/RiskControlPK.java @@ -13,87 +13,87 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import javax.persistence.Basic; -import javax.persistence.Column; -import javax.persistence.Embeddable; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.TableGenerator; -import javax.validation.constraints.NotNull; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Embeddable -public class RiskControlPK implements Serializable { - - @Basic(optional = false) - @NotNull - @Column(name = "id") - @GeneratedValue(strategy = GenerationType.TABLE, generator = "RiskCGen") - @TableGenerator(name = "RiskCGen", table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "risk_control", - allocationSize = 1, - initialValue = 1000) - private int id; - @Basic(optional = false) - @NotNull - @Column(name = "risk_control_type_id") - private int riskControlTypeId; - - public RiskControlPK() { - } - - public RiskControlPK(int riskControlTypeId) { - this.riskControlTypeId = riskControlTypeId; - } - - public int getId() { - return id; - } - - public void setId(int id) { - this.id = id; - } - - public int getRiskControlTypeId() { - return riskControlTypeId; - } - - public void setRiskControlTypeId(int riskControlTypeId) { - this.riskControlTypeId = riskControlTypeId; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (int) id; - hash += (int) riskControlTypeId; - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof RiskControlPK)) { - return false; - } - RiskControlPK other = (RiskControlPK) object; - if (this.id != other.id) { - return false; - } - return this.riskControlTypeId == other.riskControlTypeId; - } - - @Override - public String toString() { - return "com.validation.manager.core.db.RiskControlPK[ id=" + id - + ", riskControlTypeId=" + riskControlTypeId + " ]"; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import javax.persistence.Basic; +import javax.persistence.Column; +import javax.persistence.Embeddable; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.TableGenerator; +import javax.validation.constraints.NotNull; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Embeddable +public class RiskControlPK implements Serializable { + + @Basic(optional = false) + @NotNull + @Column(name = "id") + @GeneratedValue(strategy = GenerationType.TABLE, generator = "RiskCGen") + @TableGenerator(name = "RiskCGen", table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "risk_control", + allocationSize = 1, + initialValue = 1_000) + private int id; + @Basic(optional = false) + @NotNull + @Column(name = "risk_control_type_id") + private int riskControlTypeId; + + public RiskControlPK() { + } + + public RiskControlPK(int riskControlTypeId) { + this.riskControlTypeId = riskControlTypeId; + } + + public int getId() { + return id; + } + + public void setId(int id) { + this.id = id; + } + + public int getRiskControlTypeId() { + return riskControlTypeId; + } + + public void setRiskControlTypeId(int riskControlTypeId) { + this.riskControlTypeId = riskControlTypeId; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (int) id; + hash += (int) riskControlTypeId; + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof RiskControlPK)) { + return false; + } + RiskControlPK other = (RiskControlPK) object; + if (this.id != other.id) { + return false; + } + return this.riskControlTypeId == other.riskControlTypeId; + } + + @Override + public String toString() { + return "com.validation.manager.core.db.RiskControlPK[ id=" + id + + ", riskControlTypeId=" + riskControlTypeId + " ]"; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/RiskControlType.java b/VM-Core/src/main/java/com/validation/manager/core/db/RiskControlType.java index 3a25038c..1fc3a017 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/RiskControlType.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/RiskControlType.java @@ -13,134 +13,134 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.CascadeType; -import javax.persistence.Column; -import javax.persistence.Entity; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.Id; -import javax.persistence.Lob; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.OneToMany; -import javax.persistence.Table; -import javax.persistence.TableGenerator; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "risk_control_type") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "RiskControlType.findAll", - query = "SELECT r FROM RiskControlType r") - , @NamedQuery(name = "RiskControlType.findById", - query = "SELECT r FROM RiskControlType r WHERE r.id = :id") - , @NamedQuery(name = "RiskControlType.findByName", - query = "SELECT r FROM RiskControlType r WHERE r.name = :name")}) -public class RiskControlType implements Serializable { - - private static final long serialVersionUID = 1L; - @Id - @GeneratedValue(strategy = GenerationType.TABLE, - generator = "RiskControlTypeGen") - @TableGenerator(name = "RiskControlTypeGen", table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "risk_control_type", - allocationSize = 1, - initialValue = 1000) - @Basic(optional = false) - @Column(name = "id") - private Integer id; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 255) - @Column(name = "name") - private String name; - @Basic(optional = false) - @NotNull - @Lob - @Size(max = 2147483647) - @Column(name = "description") - private String description; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "riskControlType") - private List riskControlList; - - public RiskControlType() { - } - - public RiskControlType(String name, String description) { - this.name = name; - this.description = description; - } - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - public String getName() { - return name; - } - - public void setName(String name) { - this.name = name; - } - - public String getDescription() { - return description; - } - - public void setDescription(String description) { - this.description = description; - } - - @XmlTransient - @JsonIgnore - public List getRiskControlList() { - return riskControlList; - } - - public void setRiskControlList(List riskControlList) { - this.riskControlList = riskControlList; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (id != null ? id.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof RiskControlType)) { - return false; - } - RiskControlType other = (RiskControlType) object; - return !((this.id == null && other.id != null) - || (this.id != null && !this.id.equals(other.id))); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.RiskControlType[ id=" + id + " ]"; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.CascadeType; +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.Id; +import javax.persistence.Lob; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.OneToMany; +import javax.persistence.Table; +import javax.persistence.TableGenerator; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "risk_control_type") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "RiskControlType.findAll", + query = "SELECT r FROM RiskControlType r") + , @NamedQuery(name = "RiskControlType.findById", + query = "SELECT r FROM RiskControlType r WHERE r.id = :id") + , @NamedQuery(name = "RiskControlType.findByName", + query = "SELECT r FROM RiskControlType r WHERE r.name = :name")}) +public class RiskControlType implements Serializable { + + private static final long serialVersionUID = 1L; + @Id + @GeneratedValue(strategy = GenerationType.TABLE, + generator = "RiskControlTypeGen") + @TableGenerator(name = "RiskControlTypeGen", table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "risk_control_type", + allocationSize = 1, + initialValue = 1_000) + @Basic(optional = false) + @Column(name = "id") + private Integer id; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 255) + @Column(name = "name") + private String name; + @Basic(optional = false) + @NotNull + @Lob + @Size(max = 2_147_483_647) + @Column(name = "description") + private String description; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "riskControlType") + private List riskControlList; + + public RiskControlType() { + } + + public RiskControlType(String name, String description) { + this.name = name; + this.description = description; + } + + public Integer getId() { + return id; + } + + public void setId(Integer id) { + this.id = id; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + @XmlTransient + @JsonIgnore + public List getRiskControlList() { + return riskControlList; + } + + public void setRiskControlList(List riskControlList) { + this.riskControlList = riskControlList; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (id != null ? id.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof RiskControlType)) { + return false; + } + RiskControlType other = (RiskControlType) object; + return !((this.id == null && other.id != null) + || (this.id != null && !this.id.equals(other.id))); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.RiskControlType[ id=" + id + " ]"; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/RiskItemPK.java b/VM-Core/src/main/java/com/validation/manager/core/db/RiskItemPK.java index 56185f60..48d6e758 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/RiskItemPK.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/RiskItemPK.java @@ -13,86 +13,86 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import javax.persistence.Basic; -import javax.persistence.Column; -import javax.persistence.Embeddable; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.TableGenerator; -import javax.validation.constraints.NotNull; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Embeddable -public class RiskItemPK implements Serializable { - - @Basic(optional = false) - @Column(name = "id") - @GeneratedValue(strategy = GenerationType.TABLE, generator = "RIGen") - @TableGenerator(name = "RIGen", table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "risk_item", - allocationSize = 1, - initialValue = 1000) - private int id; - @Basic(optional = false) - @NotNull - @Column(name = "FMEA_id") - private int fMEAid; - - public RiskItemPK() { - } - - public RiskItemPK(int fMEAid) { - this.fMEAid = fMEAid; - } - - public int getId() { - return id; - } - - public void setId(int id) { - this.id = id; - } - - public int getFMEAid() { - return fMEAid; - } - - public void setFMEAid(int fMEAid) { - this.fMEAid = fMEAid; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (int) id; - hash += (int) fMEAid; - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof RiskItemPK)) { - return false; - } - RiskItemPK other = (RiskItemPK) object; - if (this.id != other.id) { - return false; - } - return this.fMEAid == other.fMEAid; - } - - @Override - public String toString() { - return "com.validation.manager.core.db.RiskItemPK[ id=" + id - + ", fMEAid=" + fMEAid + " ]"; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import javax.persistence.Basic; +import javax.persistence.Column; +import javax.persistence.Embeddable; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.TableGenerator; +import javax.validation.constraints.NotNull; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Embeddable +public class RiskItemPK implements Serializable { + + @Basic(optional = false) + @Column(name = "id") + @GeneratedValue(strategy = GenerationType.TABLE, generator = "RIGen") + @TableGenerator(name = "RIGen", table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "risk_item", + allocationSize = 1, + initialValue = 1_000) + private int id; + @Basic(optional = false) + @NotNull + @Column(name = "FMEA_id") + private int fMEAid; + + public RiskItemPK() { + } + + public RiskItemPK(int fMEAid) { + this.fMEAid = fMEAid; + } + + public int getId() { + return id; + } + + public void setId(int id) { + this.id = id; + } + + public int getFMEAid() { + return fMEAid; + } + + public void setFMEAid(int fMEAid) { + this.fMEAid = fMEAid; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (int) id; + hash += (int) fMEAid; + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof RiskItemPK)) { + return false; + } + RiskItemPK other = (RiskItemPK) object; + if (this.id != other.id) { + return false; + } + return this.fMEAid == other.fMEAid; + } + + @Override + public String toString() { + return "com.validation.manager.core.db.RiskItemPK[ id=" + id + + ", fMEAid=" + fMEAid + " ]"; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/Role.java b/VM-Core/src/main/java/com/validation/manager/core/db/Role.java index 20c2f5b7..2ceab0b1 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/Role.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/Role.java @@ -13,185 +13,185 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.CascadeType; -import javax.persistence.Column; -import javax.persistence.Entity; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.Id; -import javax.persistence.JoinColumn; -import javax.persistence.JoinTable; -import javax.persistence.Lob; -import javax.persistence.ManyToMany; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.OneToMany; -import javax.persistence.Table; -import javax.persistence.TableGenerator; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "role") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "Role.findAll", query = "SELECT r FROM Role r") - , @NamedQuery(name = "Role.findById", - query = "SELECT r FROM Role r WHERE r.id = :id") - , @NamedQuery(name = "Role.findByName", - query = "SELECT r FROM Role r WHERE r.roleName = :name")}) -public class Role implements Serializable { - - private static final long serialVersionUID = 1L; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "role") - private List executionStepHasVmUserList; - @Id - @Basic(optional = false) - @GeneratedValue(strategy = GenerationType.TABLE, generator = "RoleGen") - @TableGenerator(name = "RoleGen", table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "role", - allocationSize = 1, - initialValue = 1000) - @NotNull - @Column(name = "id") - private Integer id; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 255) - @Column(name = "role_name") - private String roleName; - @Lob - @Size(max = 65535) - @Column(name = "description") - private String description; - @JoinTable(name = "user_has_role", joinColumns = { - @JoinColumn(name = "role_id", referencedColumnName = "id")}, - inverseJoinColumns = { - @JoinColumn(name = "user_id", referencedColumnName = "id")}) - @ManyToMany - private List vmUserList; - @ManyToMany(mappedBy = "roleList") - private List userRightList; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "role") - private List userTestProjectRoleList; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "role") - private List userTestPlanRoleList; - - public Role() { - } - - public Role(String description) { - this.description = description; - } - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - public String getRoleName() { - return roleName; - } - - public void setRoleName(String roleName) { - this.roleName = roleName; - } - - public String getDescription() { - return description; - } - - public void setDescription(String description) { - this.description = description; - } - - @XmlTransient - @JsonIgnore - public List getVmUserList() { - return vmUserList; - } - - public void setVmUserList(List vmUserList) { - this.vmUserList = vmUserList; - } - - @XmlTransient - @JsonIgnore - public List getUserRightList() { - return userRightList; - } - - public void setUserRightList(List userRightList) { - this.userRightList = userRightList; - } - - @XmlTransient - @JsonIgnore - public List getUserTestProjectRoleList() { - return userTestProjectRoleList; - } - - public void setUserTestProjectRoleList(List userTestProjectRoleList) { - this.userTestProjectRoleList = userTestProjectRoleList; - } - - @XmlTransient - @JsonIgnore - public List getUserTestPlanRoleList() { - return userTestPlanRoleList; - } - - public void setUserTestPlanRoleList(List userTestPlanRoleList) { - this.userTestPlanRoleList = userTestPlanRoleList; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (id != null ? id.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof Role)) { - return false; - } - Role other = (Role) object; - return !((this.id == null && other.id != null) - || (this.id != null && !this.id.equals(other.id))); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.Role[ id=" + id + " ]"; - } - - @XmlTransient - @JsonIgnore - public List getExecutionStepHasVmUserList() { - return executionStepHasVmUserList; - } - - public void setExecutionStepHasVmUserList(List executionStepHasVmUserList) { - this.executionStepHasVmUserList = executionStepHasVmUserList; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.CascadeType; +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.Id; +import javax.persistence.JoinColumn; +import javax.persistence.JoinTable; +import javax.persistence.Lob; +import javax.persistence.ManyToMany; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.OneToMany; +import javax.persistence.Table; +import javax.persistence.TableGenerator; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "role") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "Role.findAll", query = "SELECT r FROM Role r") + , @NamedQuery(name = "Role.findById", + query = "SELECT r FROM Role r WHERE r.id = :id") + , @NamedQuery(name = "Role.findByName", + query = "SELECT r FROM Role r WHERE r.roleName = :name")}) +public class Role implements Serializable { + + private static final long serialVersionUID = 1L; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "role") + private List executionStepHasVmUserList; + @Id + @Basic(optional = false) + @GeneratedValue(strategy = GenerationType.TABLE, generator = "RoleGen") + @TableGenerator(name = "RoleGen", table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "role", + allocationSize = 1, + initialValue = 1_000) + @NotNull + @Column(name = "id") + private Integer id; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 255) + @Column(name = "role_name") + private String roleName; + @Lob + @Size(max = 65_535) + @Column(name = "description") + private String description; + @JoinTable(name = "user_has_role", joinColumns = { + @JoinColumn(name = "role_id", referencedColumnName = "id")}, + inverseJoinColumns = { + @JoinColumn(name = "user_id", referencedColumnName = "id")}) + @ManyToMany + private List vmUserList; + @ManyToMany(mappedBy = "roleList") + private List userRightList; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "role") + private List userTestProjectRoleList; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "role") + private List userTestPlanRoleList; + + public Role() { + } + + public Role(String description) { + this.description = description; + } + + public Integer getId() { + return id; + } + + public void setId(Integer id) { + this.id = id; + } + + public String getRoleName() { + return roleName; + } + + public void setRoleName(String roleName) { + this.roleName = roleName; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + @XmlTransient + @JsonIgnore + public List getVmUserList() { + return vmUserList; + } + + public void setVmUserList(List vmUserList) { + this.vmUserList = vmUserList; + } + + @XmlTransient + @JsonIgnore + public List getUserRightList() { + return userRightList; + } + + public void setUserRightList(List userRightList) { + this.userRightList = userRightList; + } + + @XmlTransient + @JsonIgnore + public List getUserTestProjectRoleList() { + return userTestProjectRoleList; + } + + public void setUserTestProjectRoleList(List userTestProjectRoleList) { + this.userTestProjectRoleList = userTestProjectRoleList; + } + + @XmlTransient + @JsonIgnore + public List getUserTestPlanRoleList() { + return userTestPlanRoleList; + } + + public void setUserTestPlanRoleList(List userTestPlanRoleList) { + this.userTestPlanRoleList = userTestPlanRoleList; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (id != null ? id.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof Role)) { + return false; + } + Role other = (Role) object; + return !((this.id == null && other.id != null) + || (this.id != null && !this.id.equals(other.id))); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.Role[ id=" + id + " ]"; + } + + @XmlTransient + @JsonIgnore + public List getExecutionStepHasVmUserList() { + return executionStepHasVmUserList; + } + + public void setExecutionStepHasVmUserList(List executionStepHasVmUserList) { + this.executionStepHasVmUserList = executionStepHasVmUserList; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/RootCause.java b/VM-Core/src/main/java/com/validation/manager/core/db/RootCause.java index 212ee4fd..1536da24 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/RootCause.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/RootCause.java @@ -13,153 +13,153 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.CascadeType; -import javax.persistence.Column; -import javax.persistence.EmbeddedId; -import javax.persistence.Entity; -import javax.persistence.JoinColumn; -import javax.persistence.JoinTable; -import javax.persistence.Lob; -import javax.persistence.ManyToMany; -import javax.persistence.ManyToOne; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.OneToMany; -import javax.persistence.Table; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "root_cause") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "RootCause.findAll", - query = "SELECT r FROM RootCause r") - , @NamedQuery(name = "RootCause.findById", - query = "SELECT r FROM RootCause r WHERE r.rootCausePK.id = :id") - , @NamedQuery(name = "RootCause.findByRootCauseTypeId", - query = "SELECT r FROM RootCause r WHERE " - + "r.rootCausePK.rootCauseTypeId = :rootCauseTypeId")}) -public class RootCause implements Serializable { - - private static final long serialVersionUID = 1L; - @EmbeddedId - protected RootCausePK rootCausePK; - @Basic(optional = false) - @NotNull - @Lob - @Size(max = 2147483647) - @Column(name = "details") - private String details; - @JoinTable(name = "root_cause_has_user", joinColumns = { - @JoinColumn(name = "root_cause_id", referencedColumnName = "id") - , @JoinColumn(name = "root_cause_root_cause_type_id", - referencedColumnName = "root_cause_type_id")}, - inverseJoinColumns = { - @JoinColumn(name = "vm_user_id", referencedColumnName = "id")}) - @ManyToMany - private List vmUserList; - @JoinColumn(name = "root_cause_type_id", referencedColumnName = "id", - insertable = false, updatable = false) - @ManyToOne(optional = false) - private RootCauseType rootCauseType; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "rootCause") - private List exceptionHasRootCauseList; - - public RootCause() { - } - - public RootCause(RootCausePK rootCausePK) { - this.rootCausePK = rootCausePK; - } - - public RootCause(RootCausePK rootCausePK, String details) { - this.rootCausePK = rootCausePK; - this.details = details; - } - - public RootCause(int id, int rootCauseTypeId) { - this.rootCausePK = new RootCausePK(id, rootCauseTypeId); - } - - public RootCausePK getRootCausePK() { - return rootCausePK; - } - - public void setRootCausePK(RootCausePK rootCausePK) { - this.rootCausePK = rootCausePK; - } - - public String getDetails() { - return details; - } - - public void setDetails(String details) { - this.details = details; - } - - @XmlTransient - @JsonIgnore - public List getVmUserList() { - return vmUserList; - } - - public void setVmUserList(List vmUserList) { - this.vmUserList = vmUserList; - } - - public RootCauseType getRootCauseType() { - return rootCauseType; - } - - public void setRootCauseType(RootCauseType rootCauseType) { - this.rootCauseType = rootCauseType; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (rootCausePK != null ? rootCausePK.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof RootCause)) { - return false; - } - RootCause other = (RootCause) object; - return !((this.rootCausePK == null && other.rootCausePK != null) - || (this.rootCausePK != null - && !this.rootCausePK.equals(other.rootCausePK))); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.RootCause[ rootCausePK=" - + rootCausePK + " ]"; - } - - @XmlTransient - @JsonIgnore - public List getExceptionHasRootCauseList() { - return exceptionHasRootCauseList; - } - - public void setExceptionHasRootCauseList(List exceptionHasRootCauseList) { - this.exceptionHasRootCauseList = exceptionHasRootCauseList; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.CascadeType; +import javax.persistence.Column; +import javax.persistence.EmbeddedId; +import javax.persistence.Entity; +import javax.persistence.JoinColumn; +import javax.persistence.JoinTable; +import javax.persistence.Lob; +import javax.persistence.ManyToMany; +import javax.persistence.ManyToOne; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.OneToMany; +import javax.persistence.Table; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "root_cause") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "RootCause.findAll", + query = "SELECT r FROM RootCause r") + , @NamedQuery(name = "RootCause.findById", + query = "SELECT r FROM RootCause r WHERE r.rootCausePK.id = :id") + , @NamedQuery(name = "RootCause.findByRootCauseTypeId", + query = "SELECT r FROM RootCause r WHERE " + + "r.rootCausePK.rootCauseTypeId = :rootCauseTypeId")}) +public class RootCause implements Serializable { + + private static final long serialVersionUID = 1L; + @EmbeddedId + protected RootCausePK rootCausePK; + @Basic(optional = false) + @NotNull + @Lob + @Size(max = 2_147_483_647) + @Column(name = "details") + private String details; + @JoinTable(name = "root_cause_has_user", joinColumns = { + @JoinColumn(name = "root_cause_id", referencedColumnName = "id") + , @JoinColumn(name = "root_cause_root_cause_type_id", + referencedColumnName = "root_cause_type_id")}, + inverseJoinColumns = { + @JoinColumn(name = "vm_user_id", referencedColumnName = "id")}) + @ManyToMany + private List vmUserList; + @JoinColumn(name = "root_cause_type_id", referencedColumnName = "id", + insertable = false, updatable = false) + @ManyToOne(optional = false) + private RootCauseType rootCauseType; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "rootCause") + private List exceptionHasRootCauseList; + + public RootCause() { + } + + public RootCause(RootCausePK rootCausePK) { + this.rootCausePK = rootCausePK; + } + + public RootCause(RootCausePK rootCausePK, String details) { + this.rootCausePK = rootCausePK; + this.details = details; + } + + public RootCause(int id, int rootCauseTypeId) { + this.rootCausePK = new RootCausePK(id, rootCauseTypeId); + } + + public RootCausePK getRootCausePK() { + return rootCausePK; + } + + public void setRootCausePK(RootCausePK rootCausePK) { + this.rootCausePK = rootCausePK; + } + + public String getDetails() { + return details; + } + + public void setDetails(String details) { + this.details = details; + } + + @XmlTransient + @JsonIgnore + public List getVmUserList() { + return vmUserList; + } + + public void setVmUserList(List vmUserList) { + this.vmUserList = vmUserList; + } + + public RootCauseType getRootCauseType() { + return rootCauseType; + } + + public void setRootCauseType(RootCauseType rootCauseType) { + this.rootCauseType = rootCauseType; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (rootCausePK != null ? rootCausePK.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof RootCause)) { + return false; + } + RootCause other = (RootCause) object; + return !((this.rootCausePK == null && other.rootCausePK != null) + || (this.rootCausePK != null + && !this.rootCausePK.equals(other.rootCausePK))); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.RootCause[ rootCausePK=" + + rootCausePK + " ]"; + } + + @XmlTransient + @JsonIgnore + public List getExceptionHasRootCauseList() { + return exceptionHasRootCauseList; + } + + public void setExceptionHasRootCauseList(List exceptionHasRootCauseList) { + this.exceptionHasRootCauseList = exceptionHasRootCauseList; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/RootCausePK.java b/VM-Core/src/main/java/com/validation/manager/core/db/RootCausePK.java index 75f22b5d..395fd8ed 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/RootCausePK.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/RootCausePK.java @@ -13,88 +13,88 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import javax.persistence.Basic; -import javax.persistence.Column; -import javax.persistence.Embeddable; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.TableGenerator; -import javax.validation.constraints.NotNull; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Embeddable -public class RootCausePK implements Serializable { - - @Basic(optional = false) - @NotNull - @Column(name = "id") - @GeneratedValue(strategy = GenerationType.TABLE, generator = "RootCGen") - @TableGenerator(name = "RootCGen", table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "root_cause", - allocationSize = 1, - initialValue = 1000) - private int id; - @Basic(optional = false) - @NotNull - @Column(name = "root_cause_type_id") - private int rootCauseTypeId; - - public RootCausePK() { - } - - public RootCausePK(int id, int rootCauseTypeId) { - this.id = id; - this.rootCauseTypeId = rootCauseTypeId; - } - - public int getId() { - return id; - } - - public void setId(int id) { - this.id = id; - } - - public int getRootCauseTypeId() { - return rootCauseTypeId; - } - - public void setRootCauseTypeId(int rootCauseTypeId) { - this.rootCauseTypeId = rootCauseTypeId; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (int) id; - hash += (int) rootCauseTypeId; - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof RootCausePK)) { - return false; - } - RootCausePK other = (RootCausePK) object; - if (this.id != other.id) { - return false; - } - return this.rootCauseTypeId == other.rootCauseTypeId; - } - - @Override - public String toString() { - return "com.validation.manager.core.db.RootCausePK[ id=" + id - + ", rootCauseTypeId=" + rootCauseTypeId + " ]"; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import javax.persistence.Basic; +import javax.persistence.Column; +import javax.persistence.Embeddable; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.TableGenerator; +import javax.validation.constraints.NotNull; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Embeddable +public class RootCausePK implements Serializable { + + @Basic(optional = false) + @NotNull + @Column(name = "id") + @GeneratedValue(strategy = GenerationType.TABLE, generator = "RootCGen") + @TableGenerator(name = "RootCGen", table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "root_cause", + allocationSize = 1, + initialValue = 1_000) + private int id; + @Basic(optional = false) + @NotNull + @Column(name = "root_cause_type_id") + private int rootCauseTypeId; + + public RootCausePK() { + } + + public RootCausePK(int id, int rootCauseTypeId) { + this.id = id; + this.rootCauseTypeId = rootCauseTypeId; + } + + public int getId() { + return id; + } + + public void setId(int id) { + this.id = id; + } + + public int getRootCauseTypeId() { + return rootCauseTypeId; + } + + public void setRootCauseTypeId(int rootCauseTypeId) { + this.rootCauseTypeId = rootCauseTypeId; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (int) id; + hash += (int) rootCauseTypeId; + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof RootCausePK)) { + return false; + } + RootCausePK other = (RootCausePK) object; + if (this.id != other.id) { + return false; + } + return this.rootCauseTypeId == other.rootCauseTypeId; + } + + @Override + public String toString() { + return "com.validation.manager.core.db.RootCausePK[ id=" + id + + ", rootCauseTypeId=" + rootCauseTypeId + " ]"; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/RootCauseType.java b/VM-Core/src/main/java/com/validation/manager/core/db/RootCauseType.java index 726f6b01..78ba305e 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/RootCauseType.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/RootCauseType.java @@ -13,140 +13,140 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.CascadeType; -import javax.persistence.Column; -import javax.persistence.Entity; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.Id; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.OneToMany; -import javax.persistence.Table; -import javax.persistence.TableGenerator; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "root_cause_type") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "RootCauseType.findAll", - query = "SELECT r FROM RootCauseType r") - , @NamedQuery(name = "RootCauseType.findById", - query = "SELECT r FROM RootCauseType r WHERE r.id = :id") - , @NamedQuery(name = "RootCauseType.findByName", - query = "SELECT r FROM RootCauseType r WHERE r.name = :name") - , @NamedQuery(name = "RootCauseType.findByDescription", - query = "SELECT r FROM RootCauseType r WHERE r.description = :description")}) -public class RootCauseType implements Serializable { - - private static final long serialVersionUID = 1L; - @Id - @Basic(optional = false) - @NotNull - @GeneratedValue(strategy = GenerationType.TABLE, - generator = "RootCauseTypeGen") - @TableGenerator(name = "RootCauseTypeGen", table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "root_cause_type", - allocationSize = 1, - initialValue = 1000) - @Column(name = "id") - private Integer id; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 255) - @Column(name = "name") - private String name; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 255) - @Column(name = "description") - private String description; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "rootCauseType") - private List rootCauseList; - - public RootCauseType() { - } - - public RootCauseType(Integer id) { - this.id = id; - } - - public RootCauseType(Integer id, String name, String description) { - this.id = id; - this.name = name; - this.description = description; - } - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - public String getName() { - return name; - } - - public void setName(String name) { - this.name = name; - } - - public String getDescription() { - return description; - } - - public void setDescription(String description) { - this.description = description; - } - - @XmlTransient - @JsonIgnore - public List getRootCauseList() { - return rootCauseList; - } - - public void setRootCauseList(List rootCauseList) { - this.rootCauseList = rootCauseList; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (id != null ? id.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof RootCauseType)) { - return false; - } - RootCauseType other = (RootCauseType) object; - return !((this.id == null && other.id != null) - || (this.id != null && !this.id.equals(other.id))); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.RootCauseType[ id=" + id + " ]"; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.CascadeType; +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.Id; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.OneToMany; +import javax.persistence.Table; +import javax.persistence.TableGenerator; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "root_cause_type") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "RootCauseType.findAll", + query = "SELECT r FROM RootCauseType r") + , @NamedQuery(name = "RootCauseType.findById", + query = "SELECT r FROM RootCauseType r WHERE r.id = :id") + , @NamedQuery(name = "RootCauseType.findByName", + query = "SELECT r FROM RootCauseType r WHERE r.name = :name") + , @NamedQuery(name = "RootCauseType.findByDescription", + query = "SELECT r FROM RootCauseType r WHERE r.description = :description")}) +public class RootCauseType implements Serializable { + + private static final long serialVersionUID = 1L; + @Id + @Basic(optional = false) + @NotNull + @GeneratedValue(strategy = GenerationType.TABLE, + generator = "RootCauseTypeGen") + @TableGenerator(name = "RootCauseTypeGen", table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "root_cause_type", + allocationSize = 1, + initialValue = 1_000) + @Column(name = "id") + private Integer id; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 255) + @Column(name = "name") + private String name; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 255) + @Column(name = "description") + private String description; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "rootCauseType") + private List rootCauseList; + + public RootCauseType() { + } + + public RootCauseType(Integer id) { + this.id = id; + } + + public RootCauseType(Integer id, String name, String description) { + this.id = id; + this.name = name; + this.description = description; + } + + public Integer getId() { + return id; + } + + public void setId(Integer id) { + this.id = id; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + @XmlTransient + @JsonIgnore + public List getRootCauseList() { + return rootCauseList; + } + + public void setRootCauseList(List rootCauseList) { + this.rootCauseList = rootCauseList; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (id != null ? id.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof RootCauseType)) { + return false; + } + RootCauseType other = (RootCauseType) object; + return !((this.id == null && other.id != null) + || (this.id != null && !this.id.equals(other.id))); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.RootCauseType[ id=" + id + " ]"; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/SpecLevel.java b/VM-Core/src/main/java/com/validation/manager/core/db/SpecLevel.java index bab75591..ff61abbb 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/SpecLevel.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/SpecLevel.java @@ -13,135 +13,135 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.CascadeType; -import javax.persistence.Column; -import javax.persistence.Entity; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.Id; -import javax.persistence.Lob; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.OneToMany; -import javax.persistence.Table; -import javax.persistence.TableGenerator; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "spec_level") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "SpecLevel.findAll", - query = "SELECT s FROM SpecLevel s") - , @NamedQuery(name = "SpecLevel.findById", - query = "SELECT s FROM SpecLevel s WHERE s.id = :id") - , @NamedQuery(name = "SpecLevel.findByName", - query = "SELECT s FROM SpecLevel s WHERE s.name = :name")}) -public class SpecLevel implements Serializable { - - private static final long serialVersionUID = 1L; - @Id - @Basic(optional = false) - @GeneratedValue(strategy = GenerationType.TABLE, - generator = "Spec_Level_IDGEN") - @TableGenerator(name = "Spec_Level_IDGEN", table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "spec_level", - initialValue = 1000, - allocationSize = 1) - @NotNull - @Column(name = "id") - private Integer id; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 255) - @Column(name = "name") - private String name; - @Basic(optional = false) - @NotNull - @Lob - @Size(min = 1, max = 65535) - @Column(name = "description") - private String description; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "specLevel") - private List requirementSpecList; - - public SpecLevel() { - } - - public SpecLevel(String name, String description) { - this.name = name; - this.description = description; - } - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - public String getName() { - return name; - } - - public void setName(String name) { - this.name = name; - } - - public String getDescription() { - return description; - } - - public void setDescription(String description) { - this.description = description; - } - - @XmlTransient - @JsonIgnore - public List getRequirementSpecList() { - return requirementSpecList; - } - - public void setRequirementSpecList(List requirementSpecList) { - this.requirementSpecList = requirementSpecList; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (id != null ? id.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof SpecLevel)) { - return false; - } - SpecLevel other = (SpecLevel) object; - return !((this.id == null && other.id != null) - || (this.id != null && !this.id.equals(other.id))); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.SpecLevel[ id=" + id + " ]"; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.CascadeType; +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.Id; +import javax.persistence.Lob; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.OneToMany; +import javax.persistence.Table; +import javax.persistence.TableGenerator; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "spec_level") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "SpecLevel.findAll", + query = "SELECT s FROM SpecLevel s") + , @NamedQuery(name = "SpecLevel.findById", + query = "SELECT s FROM SpecLevel s WHERE s.id = :id") + , @NamedQuery(name = "SpecLevel.findByName", + query = "SELECT s FROM SpecLevel s WHERE s.name = :name")}) +public class SpecLevel implements Serializable { + + private static final long serialVersionUID = 1L; + @Id + @Basic(optional = false) + @GeneratedValue(strategy = GenerationType.TABLE, + generator = "Spec_Level_IDGEN") + @TableGenerator(name = "Spec_Level_IDGEN", table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "spec_level", + initialValue = 1_000, + allocationSize = 1) + @NotNull + @Column(name = "id") + private Integer id; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 255) + @Column(name = "name") + private String name; + @Basic(optional = false) + @NotNull + @Lob + @Size(min = 1, max = 65_535) + @Column(name = "description") + private String description; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "specLevel") + private List requirementSpecList; + + public SpecLevel() { + } + + public SpecLevel(String name, String description) { + this.name = name; + this.description = description; + } + + public Integer getId() { + return id; + } + + public void setId(Integer id) { + this.id = id; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + @XmlTransient + @JsonIgnore + public List getRequirementSpecList() { + return requirementSpecList; + } + + public void setRequirementSpecList(List requirementSpecList) { + this.requirementSpecList = requirementSpecList; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (id != null ? id.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof SpecLevel)) { + return false; + } + SpecLevel other = (SpecLevel) object; + return !((this.id == null && other.id != null) + || (this.id != null && !this.id.equals(other.id))); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.SpecLevel[ id=" + id + " ]"; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/Step.java b/VM-Core/src/main/java/com/validation/manager/core/db/Step.java index d99d2fbd..b8b74211 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/Step.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/Step.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,198 +13,198 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import com.validation.manager.core.history.Auditable; -import com.validation.manager.core.history.Versionable; -import java.io.Serializable; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.CascadeType; -import javax.persistence.Column; -import javax.persistence.EmbeddedId; -import javax.persistence.Entity; -import javax.persistence.JoinColumn; -import javax.persistence.Lob; -import javax.persistence.ManyToMany; -import javax.persistence.ManyToOne; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.OneToMany; -import javax.persistence.Table; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "step") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "Step.findAll", - query = "SELECT s FROM Step s") - , @NamedQuery(name = "Step.findById", - query = "SELECT s FROM Step s WHERE s.stepPK.id = :id") - , @NamedQuery(name = "Step.findByTestCaseId", - query = "SELECT s FROM Step s WHERE s.stepPK.testCaseId = :testCaseId") - , @NamedQuery(name = "Step.findByStepSequence", - query = "SELECT s FROM Step s WHERE s.stepSequence = :stepSequence")}) -public class Step extends Versionable implements Serializable { - - private static final long serialVersionUID = 1L; - @EmbeddedId - protected StepPK stepPK; - @Basic(optional = false) - @NotNull - @Column(name = "step_sequence") - private int stepSequence; - @Basic(optional = false) - @NotNull - @Lob - @Column(name = "text") - @Auditable - private byte[] text; - @Lob - @Column(name = "expected_result") - @Auditable - private byte[] expectedResult; - @Lob - @Size(max = 2147483647) - @Column(name = "notes") - @Auditable - private String notes; - @ManyToMany(mappedBy = "stepList") - private List requirementList; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "step") - private List executionStepList; - @JoinColumn(name = "test_case_id", referencedColumnName = "id", - insertable = false, updatable = false) - @ManyToOne(optional = false) - private TestCase testCase; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "step") - private List historyList; - - public Step() { - } - - public Step(StepPK stepPK) { - this.stepPK = stepPK; - } - - public Step(StepPK stepPK, int stepSequence, byte[] text) { - this.stepPK = stepPK; - this.stepSequence = stepSequence; - this.text = text; - } - - public Step(int testCaseId) { - this.stepPK = new StepPK(testCaseId); - } - - public StepPK getStepPK() { - return stepPK; - } - - public void setStepPK(StepPK stepPK) { - this.stepPK = stepPK; - } - - public int getStepSequence() { - return stepSequence; - } - - public void setStepSequence(int stepSequence) { - this.stepSequence = stepSequence; - } - - public byte[] getExpectedResult() { - return expectedResult; - } - - public void setExpectedResult(byte[] expectedResult) { - this.expectedResult = expectedResult; - } - - public String getNotes() { - return notes; - } - - public void setNotes(String notes) { - this.notes = notes; - } - - @XmlTransient - @JsonIgnore - public List getRequirementList() { - return requirementList; - } - - public void setRequirementList(List requirementList) { - this.requirementList = requirementList; - } - - @XmlTransient - @JsonIgnore - public List getExecutionStepList() { - return executionStepList; - } - - public void setExecutionStepList(List executionStepList) { - this.executionStepList = executionStepList; - } - - public TestCase getTestCase() { - return testCase; - } - - public void setTestCase(TestCase testCase) { - this.testCase = testCase; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (stepPK != null ? stepPK.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - if (!(object instanceof Step)) { - return false; - } - Step other = (Step) object; - return !((this.stepPK == null && other.stepPK != null) - || (this.stepPK != null && !this.stepPK.equals(other.stepPK))); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.Step[ stepPK=" + stepPK + " ]"; - } - - public byte[] getText() { - return text; - } - - public void setText(byte[] text) { - this.text = text; - } - - @XmlTransient - @JsonIgnore - @Override - public List getHistoryList() { - return historyList; - } - - @Override - public void setHistoryList(List historyList) { - this.historyList = historyList; - } -} +package com.validation.manager.core.db; + +import com.validation.manager.core.history.Auditable; +import com.validation.manager.core.history.Versionable; +import java.io.Serializable; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.CascadeType; +import javax.persistence.Column; +import javax.persistence.EmbeddedId; +import javax.persistence.Entity; +import javax.persistence.JoinColumn; +import javax.persistence.Lob; +import javax.persistence.ManyToMany; +import javax.persistence.ManyToOne; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.OneToMany; +import javax.persistence.Table; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "step") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "Step.findAll", + query = "SELECT s FROM Step s") + , @NamedQuery(name = "Step.findById", + query = "SELECT s FROM Step s WHERE s.stepPK.id = :id") + , @NamedQuery(name = "Step.findByTestCaseId", + query = "SELECT s FROM Step s WHERE s.stepPK.testCaseId = :testCaseId") + , @NamedQuery(name = "Step.findByStepSequence", + query = "SELECT s FROM Step s WHERE s.stepSequence = :stepSequence")}) +public class Step extends Versionable implements Serializable { + + private static final long serialVersionUID = 1L; + @EmbeddedId + protected StepPK stepPK; + @Basic(optional = false) + @NotNull + @Column(name = "step_sequence") + private int stepSequence; + @Basic(optional = false) + @NotNull + @Lob + @Column(name = "text") + @Auditable + private byte[] text; + @Lob + @Column(name = "expected_result") + @Auditable + private byte[] expectedResult; + @Lob + @Size(max = 2_147_483_647) + @Column(name = "notes") + @Auditable + private String notes; + @ManyToMany(mappedBy = "stepList") + private List requirementList; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "step") + private List executionStepList; + @JoinColumn(name = "test_case_id", referencedColumnName = "id", + insertable = false, updatable = false) + @ManyToOne(optional = false) + private TestCase testCase; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "step") + private List historyList; + + public Step() { + } + + public Step(StepPK stepPK) { + this.stepPK = stepPK; + } + + public Step(StepPK stepPK, int stepSequence, byte[] text) { + this.stepPK = stepPK; + this.stepSequence = stepSequence; + this.text = text; + } + + public Step(int testCaseId) { + this.stepPK = new StepPK(testCaseId); + } + + public StepPK getStepPK() { + return stepPK; + } + + public void setStepPK(StepPK stepPK) { + this.stepPK = stepPK; + } + + public int getStepSequence() { + return stepSequence; + } + + public void setStepSequence(int stepSequence) { + this.stepSequence = stepSequence; + } + + public byte[] getExpectedResult() { + return expectedResult; + } + + public void setExpectedResult(byte[] expectedResult) { + this.expectedResult = expectedResult; + } + + public String getNotes() { + return notes; + } + + public void setNotes(String notes) { + this.notes = notes; + } + + @XmlTransient + @JsonIgnore + public List getRequirementList() { + return requirementList; + } + + public void setRequirementList(List requirementList) { + this.requirementList = requirementList; + } + + @XmlTransient + @JsonIgnore + public List getExecutionStepList() { + return executionStepList; + } + + public void setExecutionStepList(List executionStepList) { + this.executionStepList = executionStepList; + } + + public TestCase getTestCase() { + return testCase; + } + + public void setTestCase(TestCase testCase) { + this.testCase = testCase; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (stepPK != null ? stepPK.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + if (!(object instanceof Step)) { + return false; + } + Step other = (Step) object; + return !((this.stepPK == null && other.stepPK != null) + || (this.stepPK != null && !this.stepPK.equals(other.stepPK))); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.Step[ stepPK=" + stepPK + " ]"; + } + + @XmlTransient + @JsonIgnore + @Override + public List getHistoryList() { + return historyList; + } + + @Override + public void setHistoryList(List historyList) { + this.historyList = historyList; + } + + public byte[] getText() { + return text; + } + + public void setText(byte[] text) { + this.text = text; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/StepPK.java b/VM-Core/src/main/java/com/validation/manager/core/db/StepPK.java index 9c9ab829..f6e1d7dc 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/StepPK.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/StepPK.java @@ -13,87 +13,87 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import javax.persistence.Basic; -import javax.persistence.Column; -import javax.persistence.Embeddable; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.TableGenerator; -import javax.validation.constraints.NotNull; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Embeddable -public class StepPK implements Serializable { - - @Basic(optional = false) - @GeneratedValue(strategy = GenerationType.TABLE, generator = "StepGen") - @TableGenerator(name = "StepGen", table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "step", - allocationSize = 1, - initialValue = 1000) - @NotNull - @Column(name = "id") - private int id; - @Basic(optional = false) - @NotNull - @Column(name = "test_case_id") - private int testCaseId; - - public StepPK() { - } - - public StepPK(int testCaseId) { - this.testCaseId = testCaseId; - } - - public int getId() { - return id; - } - - public void setId(int id) { - this.id = id; - } - - public int getTestCaseId() { - return testCaseId; - } - - public void setTestCaseId(int testCaseId) { - this.testCaseId = testCaseId; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (int) id; - hash += (int) testCaseId; - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof StepPK)) { - return false; - } - StepPK other = (StepPK) object; - if (this.id != other.id) { - return false; - } - return this.testCaseId == other.testCaseId; - } - - @Override - public String toString() { - return "com.validation.manager.core.db.StepPK[ id=" + id - + ", testCaseId=" + testCaseId + " ]"; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import javax.persistence.Basic; +import javax.persistence.Column; +import javax.persistence.Embeddable; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.TableGenerator; +import javax.validation.constraints.NotNull; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Embeddable +public class StepPK implements Serializable { + + @Basic(optional = false) + @GeneratedValue(strategy = GenerationType.TABLE, generator = "StepGen") + @TableGenerator(name = "StepGen", table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "step", + allocationSize = 1, + initialValue = 1_000) + @NotNull + @Column(name = "id") + private int id; + @Basic(optional = false) + @NotNull + @Column(name = "test_case_id") + private int testCaseId; + + public StepPK() { + } + + public StepPK(int testCaseId) { + this.testCaseId = testCaseId; + } + + public int getId() { + return id; + } + + public void setId(int id) { + this.id = id; + } + + public int getTestCaseId() { + return testCaseId; + } + + public void setTestCaseId(int testCaseId) { + this.testCaseId = testCaseId; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (int) id; + hash += (int) testCaseId; + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof StepPK)) { + return false; + } + StepPK other = (StepPK) object; + if (this.id != other.id) { + return false; + } + return this.testCaseId == other.testCaseId; + } + + @Override + public String toString() { + return "com.validation.manager.core.db.StepPK[ id=" + id + + ", testCaseId=" + testCaseId + " ]"; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/TestCase.java b/VM-Core/src/main/java/com/validation/manager/core/db/TestCase.java index f22c6ad4..ef598c9d 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/TestCase.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/TestCase.java @@ -13,213 +13,213 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import java.util.Date; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.CascadeType; -import javax.persistence.Column; -import javax.persistence.Entity; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.Id; -import javax.persistence.JoinColumn; -import javax.persistence.JoinTable; -import javax.persistence.Lob; -import javax.persistence.ManyToMany; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.OneToMany; -import javax.persistence.Table; -import javax.persistence.TableGenerator; -import javax.persistence.Temporal; -import javax.persistence.TemporalType; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "test_case") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "TestCase.findAll", - query = "SELECT t FROM TestCase t") - , @NamedQuery(name = "TestCase.findById", - query = "SELECT t FROM TestCase t WHERE t.id = :id") - , @NamedQuery(name = "TestCase.findByName", - query = "SELECT t FROM TestCase t WHERE t.name = :name") - , @NamedQuery(name = "TestCase.findByCreationDate", - query = "SELECT t FROM TestCase t WHERE t.creationDate = :creationDate") - , @NamedQuery(name = "TestCase.findByActive", - query = "SELECT t FROM TestCase t WHERE t.active = :active") - , @NamedQuery(name = "TestCase.findByIsOpen", - query = "SELECT t FROM TestCase t WHERE t.isOpen = :isOpen")}) -public class TestCase implements Serializable { - - @Lob - @Column(name = "summary") - private byte[] summary; - - private static final long serialVersionUID = 1L; - @Id - @Basic(optional = false) - @NotNull - @Column(name = "id") - @GeneratedValue(strategy = GenerationType.TABLE, - generator = "TestCase_IDGEN") - @TableGenerator(name = "TestCase_IDGEN", table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "test_case", - initialValue = 1000, - allocationSize = 1) - private Integer id; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 255) - @Column(name = "name") - private String name; - @Basic(optional = false) - @NotNull - @Column(name = "creation_date") - @Temporal(TemporalType.TIMESTAMP) - private Date creationDate; - @Column(name = "active") - private Boolean active; - @Column(name = "is_open") - private Boolean isOpen; - @JoinTable(name = "test_plan_has_test_case", joinColumns = { - @JoinColumn(name = "test_case_id", referencedColumnName = "id")}, - inverseJoinColumns = { - @JoinColumn(name = "test_plan_id", referencedColumnName = "id") - , @JoinColumn(name = "test_plan_test_project_id", - referencedColumnName = "test_project_id")}) - @ManyToMany - private List testPlanList; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "testCase") - private List riskControlHasTestCaseList; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "testCase") - private List stepList; - - public TestCase() { - } - - public TestCase(int id) { - this.id = id; - } - - public TestCase(String name, Date creationDate) { - this.name = name; - this.creationDate = creationDate; - } - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - public String getName() { - return name; - } - - public void setName(String name) { - this.name = name; - } - - - public Date getCreationDate() { - return creationDate; - } - - public void setCreationDate(Date creationDate) { - this.creationDate = creationDate; - } - - public Boolean getActive() { - return active; - } - - public void setActive(Boolean active) { - this.active = active; - } - - public Boolean getIsOpen() { - return isOpen; - } - - public void setIsOpen(Boolean isOpen) { - this.isOpen = isOpen; - } - - @XmlTransient - @JsonIgnore - public List getTestPlanList() { - return testPlanList; - } - - public void setTestPlanList(List testPlanList) { - this.testPlanList = testPlanList; - } - - @XmlTransient - @JsonIgnore - public List getRiskControlHasTestCaseList() { - return riskControlHasTestCaseList; - } - - public void setRiskControlHasTestCaseList(List riskControlHasTestCaseList) { - this.riskControlHasTestCaseList = riskControlHasTestCaseList; - } - - @XmlTransient - @JsonIgnore - public List getStepList() { - return stepList; - } - - public void setStepList(List stepList) { - this.stepList = stepList; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (id != null ? id.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof TestCase)) { - return false; - } - TestCase other = (TestCase) object; - return !((this.id == null && other.id != null) - || (this.id != null && !this.id.equals(other.id))); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.TestCase[ id=" + id + " ]"; - } - - public byte[] getSummary() { - return summary; - } - - public void setSummary(byte[] summary) { - this.summary = summary; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import java.util.Date; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.CascadeType; +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.Id; +import javax.persistence.JoinColumn; +import javax.persistence.JoinTable; +import javax.persistence.Lob; +import javax.persistence.ManyToMany; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.OneToMany; +import javax.persistence.Table; +import javax.persistence.TableGenerator; +import javax.persistence.Temporal; +import javax.persistence.TemporalType; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "test_case") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "TestCase.findAll", + query = "SELECT t FROM TestCase t") + , @NamedQuery(name = "TestCase.findById", + query = "SELECT t FROM TestCase t WHERE t.id = :id") + , @NamedQuery(name = "TestCase.findByName", + query = "SELECT t FROM TestCase t WHERE t.name = :name") + , @NamedQuery(name = "TestCase.findByCreationDate", + query = "SELECT t FROM TestCase t WHERE t.creationDate = :creationDate") + , @NamedQuery(name = "TestCase.findByActive", + query = "SELECT t FROM TestCase t WHERE t.active = :active") + , @NamedQuery(name = "TestCase.findByIsOpen", + query = "SELECT t FROM TestCase t WHERE t.isOpen = :isOpen")}) +public class TestCase implements Serializable { + + @Lob + @Column(name = "summary") + private byte[] summary; + + private static final long serialVersionUID = 1L; + @Id + @Basic(optional = false) + @NotNull + @Column(name = "id") + @GeneratedValue(strategy = GenerationType.TABLE, + generator = "TestCase_IDGEN") + @TableGenerator(name = "TestCase_IDGEN", table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "test_case", + initialValue = 1_000, + allocationSize = 1) + private Integer id; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 255) + @Column(name = "name") + private String name; + @Basic(optional = false) + @NotNull + @Column(name = "creation_date") + @Temporal(TemporalType.TIMESTAMP) + private Date creationDate; + @Column(name = "active") + private Boolean active; + @Column(name = "is_open") + private Boolean isOpen; + @JoinTable(name = "test_plan_has_test_case", joinColumns = { + @JoinColumn(name = "test_case_id", referencedColumnName = "id")}, + inverseJoinColumns = { + @JoinColumn(name = "test_plan_id", referencedColumnName = "id") + , @JoinColumn(name = "test_plan_test_project_id", + referencedColumnName = "test_project_id")}) + @ManyToMany + private List testPlanList; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "testCase") + private List riskControlHasTestCaseList; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "testCase") + private List stepList; + + public TestCase() { + } + + public TestCase(int id) { + this.id = id; + } + + public TestCase(String name, Date creationDate) { + this.name = name; + this.creationDate = creationDate; + } + + public Integer getId() { + return id; + } + + public void setId(Integer id) { + this.id = id; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + + public Date getCreationDate() { + return creationDate; + } + + public void setCreationDate(Date creationDate) { + this.creationDate = creationDate; + } + + public Boolean getActive() { + return active; + } + + public void setActive(Boolean active) { + this.active = active; + } + + public Boolean getIsOpen() { + return isOpen; + } + + public void setIsOpen(Boolean isOpen) { + this.isOpen = isOpen; + } + + @XmlTransient + @JsonIgnore + public List getTestPlanList() { + return testPlanList; + } + + public void setTestPlanList(List testPlanList) { + this.testPlanList = testPlanList; + } + + @XmlTransient + @JsonIgnore + public List getRiskControlHasTestCaseList() { + return riskControlHasTestCaseList; + } + + public void setRiskControlHasTestCaseList(List riskControlHasTestCaseList) { + this.riskControlHasTestCaseList = riskControlHasTestCaseList; + } + + @XmlTransient + @JsonIgnore + public List getStepList() { + return stepList; + } + + public void setStepList(List stepList) { + this.stepList = stepList; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (id != null ? id.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof TestCase)) { + return false; + } + TestCase other = (TestCase) object; + return !((this.id == null && other.id != null) + || (this.id != null && !this.id.equals(other.id))); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.TestCase[ id=" + id + " ]"; + } + + public byte[] getSummary() { + return summary; + } + + public void setSummary(byte[] summary) { + this.summary = summary; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/TestCaseExecution.java b/VM-Core/src/main/java/com/validation/manager/core/db/TestCaseExecution.java index 2f1ea4b2..bbd217db 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/TestCaseExecution.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/TestCaseExecution.java @@ -13,145 +13,145 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.CascadeType; -import javax.persistence.Column; -import javax.persistence.Entity; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.Id; -import javax.persistence.Lob; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.OneToMany; -import javax.persistence.Table; -import javax.persistence.TableGenerator; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "test_case_execution") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "TestCaseExecution.findAll", - query = "SELECT t FROM TestCaseExecution t") - , @NamedQuery(name = "TestCaseExecution.findById", - query = "SELECT t FROM TestCaseExecution t WHERE t.id = :id")}) -public class TestCaseExecution implements Serializable { - - private static final long serialVersionUID = 1L; - @Id - @Basic(optional = false) - @GeneratedValue(strategy = GenerationType.TABLE, - generator = "TestCaseExecGen") - @TableGenerator(name = "TestCaseExecGen", table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "test_case_execution", - allocationSize = 1, - initialValue = 1000) - @NotNull - @Column(name = "id") - private Integer id; - @Basic(optional = false) - @NotNull - @Lob - @Size(max = 2147483647) - @Column(name = "scope") - private String scope; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 255) - @Column(name = "name") - private String name; - @Lob - @Size(max = 2147483647) - @Column(name = "conclusion") - private String conclusion; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "testCaseExecution") - private List executionStepList; - - public TestCaseExecution(String name, String scope) { - this.name = name; - this.scope = scope; - } - - public TestCaseExecution() { - } - - public Integer getId() { - return this.id; - } - - public void setId(Integer id) { - this.id = id; - } - - public String getScope() { - return scope; - } - - public void setScope(String scope) { - this.scope = scope; - } - - public String getName() { - return name; - } - - public void setName(String name) { - this.name = name; - } - - public String getConclusion() { - return conclusion; - } - - public void setConclusion(String conclusion) { - this.conclusion = conclusion; - } - - @XmlTransient - @JsonIgnore - public List getExecutionStepList() { - return executionStepList; - } - - public void setExecutionStepList(List executionStepList) { - this.executionStepList = executionStepList; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (id != null ? id.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof TestCaseExecution)) { - return false; - } - TestCaseExecution other = (TestCaseExecution) object; - return !((this.id == null && other.id != null) - || (this.id != null && !this.id.equals(other.id))); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.TestCaseExecution[ id=" + id + " ]"; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.CascadeType; +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.Id; +import javax.persistence.Lob; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.OneToMany; +import javax.persistence.Table; +import javax.persistence.TableGenerator; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "test_case_execution") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "TestCaseExecution.findAll", + query = "SELECT t FROM TestCaseExecution t") + , @NamedQuery(name = "TestCaseExecution.findById", + query = "SELECT t FROM TestCaseExecution t WHERE t.id = :id")}) +public class TestCaseExecution implements Serializable { + + private static final long serialVersionUID = 1L; + @Id + @Basic(optional = false) + @GeneratedValue(strategy = GenerationType.TABLE, + generator = "TestCaseExecGen") + @TableGenerator(name = "TestCaseExecGen", table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "test_case_execution", + allocationSize = 1, + initialValue = 1_000) + @NotNull + @Column(name = "id") + private Integer id; + @Basic(optional = false) + @NotNull + @Lob + @Size(max = 2_147_483_647) + @Column(name = "scope") + private String scope; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 255) + @Column(name = "name") + private String name; + @Lob + @Size(max = 2_147_483_647) + @Column(name = "conclusion") + private String conclusion; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "testCaseExecution") + private List executionStepList; + + public TestCaseExecution(String name, String scope) { + this.name = name; + this.scope = scope; + } + + public TestCaseExecution() { + } + + public Integer getId() { + return this.id; + } + + public void setId(Integer id) { + this.id = id; + } + + public String getScope() { + return scope; + } + + public void setScope(String scope) { + this.scope = scope; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getConclusion() { + return conclusion; + } + + public void setConclusion(String conclusion) { + this.conclusion = conclusion; + } + + @XmlTransient + @JsonIgnore + public List getExecutionStepList() { + return executionStepList; + } + + public void setExecutionStepList(List executionStepList) { + this.executionStepList = executionStepList; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (id != null ? id.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof TestCaseExecution)) { + return false; + } + TestCaseExecution other = (TestCaseExecution) object; + return !((this.id == null && other.id != null) + || (this.id != null && !this.id.equals(other.id))); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.TestCaseExecution[ id=" + id + " ]"; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/TestPlan.java b/VM-Core/src/main/java/com/validation/manager/core/db/TestPlan.java index cfc51caf..baa778d3 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/TestPlan.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/TestPlan.java @@ -13,212 +13,212 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.CascadeType; -import javax.persistence.Column; -import javax.persistence.EmbeddedId; -import javax.persistence.Entity; -import javax.persistence.JoinColumn; -import javax.persistence.JoinColumns; -import javax.persistence.Lob; -import javax.persistence.ManyToMany; -import javax.persistence.ManyToOne; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.OneToMany; -import javax.persistence.Table; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "test_plan") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "TestPlan.findAll", - query = "SELECT t FROM TestPlan t") - , @NamedQuery(name = "TestPlan.findById", - query = "SELECT t FROM TestPlan t WHERE t.testPlanPK.id = :id") - , @NamedQuery(name = "TestPlan.findByTestProjectId", - query = "SELECT t FROM TestPlan t WHERE t.testPlanPK.testProjectId = :testProjectId") - , @NamedQuery(name = "TestPlan.findByName", - query = "SELECT t FROM TestPlan t WHERE t.name = :name") - , @NamedQuery(name = "TestPlan.findByActive", - query = "SELECT t FROM TestPlan t WHERE t.active = :active") - , @NamedQuery(name = "TestPlan.findByIsOpen", - query = "SELECT t FROM TestPlan t WHERE t.isOpen = :isOpen")}) -public class TestPlan implements Serializable { - - private static final long serialVersionUID = 1L; - @EmbeddedId - protected TestPlanPK testPlanPK; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 255) - @Column(name = "name") - private String name; - @Lob - @Size(max = 65535) - @Column(name = "notes") - private String notes; - @Basic(optional = false) - @NotNull - @Column(name = "active") - private boolean active; - @Basic(optional = false) - @NotNull - @Column(name = "is_open") - private boolean isOpen; - @ManyToMany(mappedBy = "testPlanList") - private List testCaseList; - @OneToMany(mappedBy = "testPlan") - private List testPlanList; - @JoinColumns({ - @JoinColumn(name = "regression_test_plan_id", - referencedColumnName = "id") - , @JoinColumn(name = "regression_test_plan_test_project_id", - referencedColumnName = "test_project_id")}) - @ManyToOne - private TestPlan testPlan; - @JoinColumn(name = "test_project_id", referencedColumnName = "id", - insertable = false, updatable = false) - @ManyToOne(optional = false) - private TestProject testProject; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "testPlan") - private List userTestPlanRoleList; - - public TestPlan() { - } - - public TestPlan(TestPlanPK testPlanPK) { - this.testPlanPK = testPlanPK; - } - - public TestPlan(TestProject testProject, boolean active, boolean isOpen) { - this.testProject = testProject; - this.testPlanPK = new TestPlanPK(testProject.getId()); - this.active = active; - this.isOpen = isOpen; - } - - public TestPlanPK getTestPlanPK() { - return testPlanPK; - } - - public void setTestPlanPK(TestPlanPK testPlanPK) { - this.testPlanPK = testPlanPK; - } - - public String getName() { - return name; - } - - public void setName(String name) { - this.name = name; - } - - public String getNotes() { - return notes; - } - - public void setNotes(String notes) { - this.notes = notes; - } - - public boolean getActive() { - return active; - } - - public void setActive(boolean active) { - this.active = active; - } - - public boolean getIsOpen() { - return isOpen; - } - - public void setIsOpen(boolean isOpen) { - this.isOpen = isOpen; - } - - @XmlTransient - @JsonIgnore - public List getTestCaseList() { - return testCaseList; - } - - public void setTestCaseList(List testCaseList) { - this.testCaseList = testCaseList; - } - - @XmlTransient - @JsonIgnore - public List getTestPlanList() { - return testPlanList; - } - - public void setTestPlanList(List testPlanList) { - this.testPlanList = testPlanList; - } - - public TestPlan getTestPlan() { - return testPlan; - } - - public void setTestPlan(TestPlan testPlan) { - this.testPlan = testPlan; - } - - public TestProject getTestProject() { - return testProject; - } - - public void setTestProject(TestProject testProject) { - this.testProject = testProject; - } - - @XmlTransient - @JsonIgnore - public List getUserTestPlanRoleList() { - return userTestPlanRoleList; - } - - public void setUserTestPlanRoleList(List userTestPlanRoleList) { - this.userTestPlanRoleList = userTestPlanRoleList; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (testPlanPK != null ? testPlanPK.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof TestPlan)) { - return false; - } - TestPlan other = (TestPlan) object; - return !((this.testPlanPK == null && other.testPlanPK != null) - || (this.testPlanPK != null - && !this.testPlanPK.equals(other.testPlanPK))); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.TestPlan[ testPlanPK=" - + testPlanPK + " ]"; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.CascadeType; +import javax.persistence.Column; +import javax.persistence.EmbeddedId; +import javax.persistence.Entity; +import javax.persistence.JoinColumn; +import javax.persistence.JoinColumns; +import javax.persistence.Lob; +import javax.persistence.ManyToMany; +import javax.persistence.ManyToOne; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.OneToMany; +import javax.persistence.Table; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "test_plan") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "TestPlan.findAll", + query = "SELECT t FROM TestPlan t") + , @NamedQuery(name = "TestPlan.findById", + query = "SELECT t FROM TestPlan t WHERE t.testPlanPK.id = :id") + , @NamedQuery(name = "TestPlan.findByTestProjectId", + query = "SELECT t FROM TestPlan t WHERE t.testPlanPK.testProjectId = :testProjectId") + , @NamedQuery(name = "TestPlan.findByName", + query = "SELECT t FROM TestPlan t WHERE t.name = :name") + , @NamedQuery(name = "TestPlan.findByActive", + query = "SELECT t FROM TestPlan t WHERE t.active = :active") + , @NamedQuery(name = "TestPlan.findByIsOpen", + query = "SELECT t FROM TestPlan t WHERE t.isOpen = :isOpen")}) +public class TestPlan implements Serializable { + + private static final long serialVersionUID = 1L; + @EmbeddedId + protected TestPlanPK testPlanPK; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 255) + @Column(name = "name") + private String name; + @Lob + @Size(max = 65_535) + @Column(name = "notes") + private String notes; + @Basic(optional = false) + @NotNull + @Column(name = "active") + private boolean active; + @Basic(optional = false) + @NotNull + @Column(name = "is_open") + private boolean isOpen; + @ManyToMany(mappedBy = "testPlanList") + private List testCaseList; + @OneToMany(mappedBy = "testPlan") + private List testPlanList; + @JoinColumns({ + @JoinColumn(name = "regression_test_plan_id", + referencedColumnName = "id") + , @JoinColumn(name = "regression_test_plan_test_project_id", + referencedColumnName = "test_project_id")}) + @ManyToOne + private TestPlan testPlan; + @JoinColumn(name = "test_project_id", referencedColumnName = "id", + insertable = false, updatable = false) + @ManyToOne(optional = false) + private TestProject testProject; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "testPlan") + private List userTestPlanRoleList; + + public TestPlan() { + } + + public TestPlan(TestPlanPK testPlanPK) { + this.testPlanPK = testPlanPK; + } + + public TestPlan(TestProject testProject, boolean active, boolean isOpen) { + this.testProject = testProject; + this.testPlanPK = new TestPlanPK(testProject.getId()); + this.active = active; + this.isOpen = isOpen; + } + + public TestPlanPK getTestPlanPK() { + return testPlanPK; + } + + public void setTestPlanPK(TestPlanPK testPlanPK) { + this.testPlanPK = testPlanPK; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public String getNotes() { + return notes; + } + + public void setNotes(String notes) { + this.notes = notes; + } + + public boolean getActive() { + return active; + } + + public void setActive(boolean active) { + this.active = active; + } + + public boolean getIsOpen() { + return isOpen; + } + + public void setIsOpen(boolean isOpen) { + this.isOpen = isOpen; + } + + @XmlTransient + @JsonIgnore + public List getTestCaseList() { + return testCaseList; + } + + public void setTestCaseList(List testCaseList) { + this.testCaseList = testCaseList; + } + + @XmlTransient + @JsonIgnore + public List getTestPlanList() { + return testPlanList; + } + + public void setTestPlanList(List testPlanList) { + this.testPlanList = testPlanList; + } + + public TestPlan getTestPlan() { + return testPlan; + } + + public void setTestPlan(TestPlan testPlan) { + this.testPlan = testPlan; + } + + public TestProject getTestProject() { + return testProject; + } + + public void setTestProject(TestProject testProject) { + this.testProject = testProject; + } + + @XmlTransient + @JsonIgnore + public List getUserTestPlanRoleList() { + return userTestPlanRoleList; + } + + public void setUserTestPlanRoleList(List userTestPlanRoleList) { + this.userTestPlanRoleList = userTestPlanRoleList; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (testPlanPK != null ? testPlanPK.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof TestPlan)) { + return false; + } + TestPlan other = (TestPlan) object; + return !((this.testPlanPK == null && other.testPlanPK != null) + || (this.testPlanPK != null + && !this.testPlanPK.equals(other.testPlanPK))); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.TestPlan[ testPlanPK=" + + testPlanPK + " ]"; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/TestPlanPK.java b/VM-Core/src/main/java/com/validation/manager/core/db/TestPlanPK.java index 5740b29a..84fd961a 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/TestPlanPK.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/TestPlanPK.java @@ -13,88 +13,88 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import javax.persistence.Basic; -import javax.persistence.Column; -import javax.persistence.Embeddable; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.TableGenerator; -import javax.validation.constraints.NotNull; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Embeddable -public class TestPlanPK implements Serializable { - - @Basic(optional = false) - @GeneratedValue(strategy = GenerationType.TABLE, generator = "Test_Plan_IDGEN") - @TableGenerator(name = "Test_Plan_IDGEN", - table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "test_plan", - initialValue = 1000, - allocationSize = 1) - @NotNull - @Column(name = "id") - private int id; - @Basic(optional = false) - @NotNull - @Column(name = "test_project_id") - private int testProjectId; - - public TestPlanPK() { - } - - public TestPlanPK(int testProjectId) { - this.testProjectId = testProjectId; - } - - public int getId() { - return id; - } - - public void setId(int id) { - this.id = id; - } - - public int getTestProjectId() { - return testProjectId; - } - - public void setTestProjectId(int testProjectId) { - this.testProjectId = testProjectId; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (int) id; - hash += (int) testProjectId; - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof TestPlanPK)) { - return false; - } - TestPlanPK other = (TestPlanPK) object; - if (this.id != other.id) { - return false; - } - return this.testProjectId == other.testProjectId; - } - - @Override - public String toString() { - return "com.validation.manager.core.db.TestPlanPK[ id=" + id - + ", testProjectId=" + testProjectId + " ]"; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import javax.persistence.Basic; +import javax.persistence.Column; +import javax.persistence.Embeddable; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.TableGenerator; +import javax.validation.constraints.NotNull; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Embeddable +public class TestPlanPK implements Serializable { + + @Basic(optional = false) + @GeneratedValue(strategy = GenerationType.TABLE, generator = "Test_Plan_IDGEN") + @TableGenerator(name = "Test_Plan_IDGEN", + table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "test_plan", + initialValue = 1_000, + allocationSize = 1) + @NotNull + @Column(name = "id") + private int id; + @Basic(optional = false) + @NotNull + @Column(name = "test_project_id") + private int testProjectId; + + public TestPlanPK() { + } + + public TestPlanPK(int testProjectId) { + this.testProjectId = testProjectId; + } + + public int getId() { + return id; + } + + public void setId(int id) { + this.id = id; + } + + public int getTestProjectId() { + return testProjectId; + } + + public void setTestProjectId(int testProjectId) { + this.testProjectId = testProjectId; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (int) id; + hash += (int) testProjectId; + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof TestPlanPK)) { + return false; + } + TestPlanPK other = (TestPlanPK) object; + if (this.id != other.id) { + return false; + } + return this.testProjectId == other.testProjectId; + } + + @Override + public String toString() { + return "com.validation.manager.core.db.TestPlanPK[ id=" + id + + ", testProjectId=" + testProjectId + " ]"; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/TestProject.java b/VM-Core/src/main/java/com/validation/manager/core/db/TestProject.java index 5dd5e4ea..2beb68e4 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/TestProject.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/TestProject.java @@ -13,171 +13,171 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.CascadeType; -import javax.persistence.Column; -import javax.persistence.Entity; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.Id; -import javax.persistence.Lob; -import javax.persistence.ManyToMany; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.OneToMany; -import javax.persistence.Table; -import javax.persistence.TableGenerator; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "test_project") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "TestProject.findAll", - query = "SELECT t FROM TestProject t") - , @NamedQuery(name = "TestProject.findById", - query = "SELECT t FROM TestProject t WHERE t.id = :id") - , @NamedQuery(name = "TestProject.findByName", - query = "SELECT t FROM TestProject t WHERE t.name = :name") - , @NamedQuery(name = "TestProject.findByActive", - query = "SELECT t FROM TestProject t WHERE t.active = :active")}) -public class TestProject implements Serializable { - - private static final long serialVersionUID = 1L; - @Id - @GeneratedValue(strategy = GenerationType.TABLE, generator = "TestProjectGen") - @TableGenerator(name = "TestProjectGen", table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "test_project", - allocationSize = 1, - initialValue = 1000) - @Basic(optional = false) - @NotNull - @Column(name = "id") - private Integer id; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 255) - @Column(name = "name") - private String name; - @Basic(optional = false) - @NotNull - @Column(name = "active") - private boolean active; - @Lob - @Size(max = 2147483647) - @Column(name = "notes") - private String notes; - @ManyToMany(mappedBy = "testProjectList") - private List projectList; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "testProject") - private List userTestProjectRoleList; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "testProject") - private List testPlanList; - - public TestProject() { - } - - public TestProject(String name, boolean active) { - this.name = name; - this.active = active; - } - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - public String getName() { - return name; - } - - public void setName(String name) { - this.name = name; - } - - public boolean getActive() { - return active; - } - - public void setActive(boolean active) { - this.active = active; - } - - public String getNotes() { - return notes; - } - - public void setNotes(String notes) { - this.notes = notes; - } - - @XmlTransient - @JsonIgnore - public List getProjectList() { - return projectList; - } - - public void setProjectList(List projectList) { - this.projectList = projectList; - } - - @XmlTransient - @JsonIgnore - public List getUserTestProjectRoleList() { - return userTestProjectRoleList; - } - - public void setUserTestProjectRoleList(List userTestProjectRoleList) { - this.userTestProjectRoleList = userTestProjectRoleList; - } - - @XmlTransient - @JsonIgnore - public List getTestPlanList() { - return testPlanList; - } - - public void setTestPlanList(List testPlanList) { - this.testPlanList = testPlanList; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (id != null ? id.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof TestProject)) { - return false; - } - TestProject other = (TestProject) object; - return !((this.id == null && other.id != null) - || (this.id != null && !this.id.equals(other.id))); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.TestProject[ id=" + id + " ]"; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.CascadeType; +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.Id; +import javax.persistence.Lob; +import javax.persistence.ManyToMany; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.OneToMany; +import javax.persistence.Table; +import javax.persistence.TableGenerator; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "test_project") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "TestProject.findAll", + query = "SELECT t FROM TestProject t") + , @NamedQuery(name = "TestProject.findById", + query = "SELECT t FROM TestProject t WHERE t.id = :id") + , @NamedQuery(name = "TestProject.findByName", + query = "SELECT t FROM TestProject t WHERE t.name = :name") + , @NamedQuery(name = "TestProject.findByActive", + query = "SELECT t FROM TestProject t WHERE t.active = :active")}) +public class TestProject implements Serializable { + + private static final long serialVersionUID = 1L; + @Id + @GeneratedValue(strategy = GenerationType.TABLE, generator = "TestProjectGen") + @TableGenerator(name = "TestProjectGen", table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "test_project", + allocationSize = 1, + initialValue = 1_000) + @Basic(optional = false) + @NotNull + @Column(name = "id") + private Integer id; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 255) + @Column(name = "name") + private String name; + @Basic(optional = false) + @NotNull + @Column(name = "active") + private boolean active; + @Lob + @Size(max = 2_147_483_647) + @Column(name = "notes") + private String notes; + @ManyToMany(mappedBy = "testProjectList") + private List projectList; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "testProject") + private List userTestProjectRoleList; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "testProject") + private List testPlanList; + + public TestProject() { + } + + public TestProject(String name, boolean active) { + this.name = name; + this.active = active; + } + + public Integer getId() { + return id; + } + + public void setId(Integer id) { + this.id = id; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public boolean getActive() { + return active; + } + + public void setActive(boolean active) { + this.active = active; + } + + public String getNotes() { + return notes; + } + + public void setNotes(String notes) { + this.notes = notes; + } + + @XmlTransient + @JsonIgnore + public List getProjectList() { + return projectList; + } + + public void setProjectList(List projectList) { + this.projectList = projectList; + } + + @XmlTransient + @JsonIgnore + public List getUserTestProjectRoleList() { + return userTestProjectRoleList; + } + + public void setUserTestProjectRoleList(List userTestProjectRoleList) { + this.userTestProjectRoleList = userTestProjectRoleList; + } + + @XmlTransient + @JsonIgnore + public List getTestPlanList() { + return testPlanList; + } + + public void setTestPlanList(List testPlanList) { + this.testPlanList = testPlanList; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (id != null ? id.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof TestProject)) { + return false; + } + TestProject other = (TestProject) object; + return !((this.id == null && other.id != null) + || (this.id != null && !this.id.equals(other.id))); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.TestProject[ id=" + id + " ]"; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/UserAssigmentPK.java b/VM-Core/src/main/java/com/validation/manager/core/db/UserAssigmentPK.java index 42277d09..68985775 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/UserAssigmentPK.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/UserAssigmentPK.java @@ -13,126 +13,126 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import javax.persistence.Basic; -import javax.persistence.Column; -import javax.persistence.Embeddable; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.TableGenerator; -import javax.validation.constraints.NotNull; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Embeddable -public class UserAssigmentPK implements Serializable { - - @Basic(optional = false) - @GeneratedValue(strategy = GenerationType.TABLE, - generator = "UserAssignmentGEN") - @TableGenerator(name = "UserAssignmentGEN", - table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "user_assignment", - initialValue = 1000, - allocationSize = 1) - @NotNull - @Column(name = "id") - private int id; - @Basic(optional = false) - @NotNull - @Column(name = "assigner_id") - private int assignerId; - @Basic(optional = false) - @NotNull - @Column(name = "assigment_type_id") - private int assigmentTypeId; - @Basic(optional = false) - @NotNull - @Column(name = "assignment_status_id") - private int assignmentStatusId; - - public UserAssigmentPK() { - } - - public UserAssigmentPK(int assignerId, int assigmentTypeId, - int assignmentStatusId) { - this.assignerId = assignerId; - this.assigmentTypeId = assigmentTypeId; - this.assignmentStatusId = assignmentStatusId; - } - - public int getId() { - return id; - } - - public void setId(int id) { - this.id = id; - } - - public int getAssignerId() { - return assignerId; - } - - public void setAssignerId(int assignerId) { - this.assignerId = assignerId; - } - - public int getAssigmentTypeId() { - return assigmentTypeId; - } - - public void setAssigmentTypeId(int assigmentTypeId) { - this.assigmentTypeId = assigmentTypeId; - } - - public int getAssignmentStatusId() { - return assignmentStatusId; - } - - public void setAssignmentStatusId(int assignmentStatusId) { - this.assignmentStatusId = assignmentStatusId; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (int) id; - hash += (int) assignerId; - hash += (int) assigmentTypeId; - hash += (int) assignmentStatusId; - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof UserAssigmentPK)) { - return false; - } - UserAssigmentPK other = (UserAssigmentPK) object; - if (this.id != other.id) { - return false; - } - if (this.assignerId != other.assignerId) { - return false; - } - if (this.assigmentTypeId != other.assigmentTypeId) { - return false; - } - return this.assignmentStatusId == other.assignmentStatusId; - } - - @Override - public String toString() { - return "com.validation.manager.core.db.UserAssigmentPK[ id=" + id - + ", assignerId=" + assignerId + ", assigmentTypeId=" - + assigmentTypeId + ", assignmentStatusId=" - + assignmentStatusId + " ]"; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import javax.persistence.Basic; +import javax.persistence.Column; +import javax.persistence.Embeddable; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.TableGenerator; +import javax.validation.constraints.NotNull; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Embeddable +public class UserAssigmentPK implements Serializable { + + @Basic(optional = false) + @GeneratedValue(strategy = GenerationType.TABLE, + generator = "UserAssignmentGEN") + @TableGenerator(name = "UserAssignmentGEN", + table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "user_assignment", + initialValue = 1_000, + allocationSize = 1) + @NotNull + @Column(name = "id") + private int id; + @Basic(optional = false) + @NotNull + @Column(name = "assigner_id") + private int assignerId; + @Basic(optional = false) + @NotNull + @Column(name = "assigment_type_id") + private int assigmentTypeId; + @Basic(optional = false) + @NotNull + @Column(name = "assignment_status_id") + private int assignmentStatusId; + + public UserAssigmentPK() { + } + + public UserAssigmentPK(int assignerId, int assigmentTypeId, + int assignmentStatusId) { + this.assignerId = assignerId; + this.assigmentTypeId = assigmentTypeId; + this.assignmentStatusId = assignmentStatusId; + } + + public int getId() { + return id; + } + + public void setId(int id) { + this.id = id; + } + + public int getAssignerId() { + return assignerId; + } + + public void setAssignerId(int assignerId) { + this.assignerId = assignerId; + } + + public int getAssigmentTypeId() { + return assigmentTypeId; + } + + public void setAssigmentTypeId(int assigmentTypeId) { + this.assigmentTypeId = assigmentTypeId; + } + + public int getAssignmentStatusId() { + return assignmentStatusId; + } + + public void setAssignmentStatusId(int assignmentStatusId) { + this.assignmentStatusId = assignmentStatusId; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (int) id; + hash += (int) assignerId; + hash += (int) assigmentTypeId; + hash += (int) assignmentStatusId; + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof UserAssigmentPK)) { + return false; + } + UserAssigmentPK other = (UserAssigmentPK) object; + if (this.id != other.id) { + return false; + } + if (this.assignerId != other.assignerId) { + return false; + } + if (this.assigmentTypeId != other.assigmentTypeId) { + return false; + } + return this.assignmentStatusId == other.assignmentStatusId; + } + + @Override + public String toString() { + return "com.validation.manager.core.db.UserAssigmentPK[ id=" + id + + ", assignerId=" + assignerId + ", assigmentTypeId=" + + assigmentTypeId + ", assignmentStatusId=" + + assignmentStatusId + " ]"; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/UserRight.java b/VM-Core/src/main/java/com/validation/manager/core/db/UserRight.java index dd67004e..ffcb2bb2 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/UserRight.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/UserRight.java @@ -13,129 +13,129 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.Column; -import javax.persistence.Entity; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.Id; -import javax.persistence.JoinColumn; -import javax.persistence.JoinTable; -import javax.persistence.ManyToMany; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.Table; -import javax.persistence.TableGenerator; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "user_right") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "UserRight.findAll", - query = "SELECT u FROM UserRight u") - , @NamedQuery(name = "UserRight.findById", - query = "SELECT u FROM UserRight u WHERE u.id = :id") - , @NamedQuery(name = "UserRight.findByDescription", - query = "SELECT u FROM UserRight u WHERE u.description = :description")}) -public class UserRight implements Serializable { - - private static final long serialVersionUID = 1L; - @Id - @Basic(optional = false) - @GeneratedValue(strategy = GenerationType.TABLE, generator = "UserRightGEN") - @TableGenerator(name = "UserRightGEN", - table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "user_right", - initialValue = 1000, - allocationSize = 1) - @NotNull - @Column(name = "id") - private Integer id; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 255) - @Column(name = "description") - private String description; - @JoinTable(name = "role_has_right", joinColumns = { - @JoinColumn(name = "right_id", referencedColumnName = "id")}, - inverseJoinColumns = { - @JoinColumn(name = "role_id", referencedColumnName = "id")}) - @ManyToMany - private List roleList; - - public UserRight() { - } - - public UserRight(Integer id) { - this.id = id; - } - - public UserRight(Integer id, String description) { - this.id = id; - this.description = description; - } - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - public String getDescription() { - return description; - } - - public void setDescription(String description) { - this.description = description; - } - - @XmlTransient - @JsonIgnore - public List getRoleList() { - return roleList; - } - - public void setRoleList(List roleList) { - this.roleList = roleList; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (id != null ? id.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof UserRight)) { - return false; - } - UserRight other = (UserRight) object; - return !((this.id == null && other.id != null) - || (this.id != null && !this.id.equals(other.id))); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.UserRight[ id=" + id + " ]"; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.Id; +import javax.persistence.JoinColumn; +import javax.persistence.JoinTable; +import javax.persistence.ManyToMany; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.Table; +import javax.persistence.TableGenerator; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "user_right") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "UserRight.findAll", + query = "SELECT u FROM UserRight u") + , @NamedQuery(name = "UserRight.findById", + query = "SELECT u FROM UserRight u WHERE u.id = :id") + , @NamedQuery(name = "UserRight.findByDescription", + query = "SELECT u FROM UserRight u WHERE u.description = :description")}) +public class UserRight implements Serializable { + + private static final long serialVersionUID = 1L; + @Id + @Basic(optional = false) + @GeneratedValue(strategy = GenerationType.TABLE, generator = "UserRightGEN") + @TableGenerator(name = "UserRightGEN", + table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "user_right", + initialValue = 1_000, + allocationSize = 1) + @NotNull + @Column(name = "id") + private Integer id; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 255) + @Column(name = "description") + private String description; + @JoinTable(name = "role_has_right", joinColumns = { + @JoinColumn(name = "right_id", referencedColumnName = "id")}, + inverseJoinColumns = { + @JoinColumn(name = "role_id", referencedColumnName = "id")}) + @ManyToMany + private List roleList; + + public UserRight() { + } + + public UserRight(Integer id) { + this.id = id; + } + + public UserRight(Integer id, String description) { + this.id = id; + this.description = description; + } + + public Integer getId() { + return id; + } + + public void setId(Integer id) { + this.id = id; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + @XmlTransient + @JsonIgnore + public List getRoleList() { + return roleList; + } + + public void setRoleList(List roleList) { + this.roleList = roleList; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (id != null ? id.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof UserRight)) { + return false; + } + UserRight other = (UserRight) object; + return !((this.id == null && other.id != null) + || (this.id != null && !this.id.equals(other.id))); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.UserRight[ id=" + id + " ]"; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/UserStatus.java b/VM-Core/src/main/java/com/validation/manager/core/db/UserStatus.java index 8176d883..8d902398 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/UserStatus.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/UserStatus.java @@ -13,132 +13,132 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import java.io.Serializable; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.CascadeType; -import javax.persistence.Column; -import javax.persistence.Entity; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.Id; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.OneToMany; -import javax.persistence.Table; -import javax.persistence.TableGenerator; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "user_status") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "UserStatus.findAll", - query = "SELECT u FROM UserStatus u") - , @NamedQuery(name = "UserStatus.findById", - query = "SELECT u FROM UserStatus u WHERE u.id = :id") - , @NamedQuery(name = "UserStatus.findByStatus", - query = "SELECT u FROM UserStatus u WHERE u.status = :status") - , @NamedQuery(name = "UserStatus.findByDescription", - query = "SELECT u FROM UserStatus u WHERE u.description = :description")}) -public class UserStatus implements Serializable { - - private static final long serialVersionUID = 1L; - @Id - @Basic(optional = false) - @GeneratedValue(strategy = GenerationType.TABLE, generator = "UserStatusGEN") - @TableGenerator(name = "UserStatusGEN", - table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "user_status", - initialValue = 1000, - allocationSize = 1) - @NotNull - @Column(name = "id") - private Integer id; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 255) - @Column(name = "status") - private String status; - @Size(max = 255) - @Column(name = "description") - private String description; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "userStatusId") - private List vmUserList; - - public UserStatus() { - } - - public UserStatus(String status) { - this.status = status; - } - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - public String getStatus() { - return status; - } - - public void setStatus(String status) { - this.status = status; - } - - public String getDescription() { - return description; - } - - public void setDescription(String description) { - this.description = description; - } - - @XmlTransient - @JsonIgnore - public List getVmUserList() { - return vmUserList; - } - - public void setVmUserList(List vmUserList) { - this.vmUserList = vmUserList; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (id != null ? id.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof UserStatus)) { - return false; - } - UserStatus other = (UserStatus) object; - return !((this.id == null && other.id != null) - || (this.id != null && !this.id.equals(other.id))); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.UserStatus[ id=" + id + " ]"; - } -} +package com.validation.manager.core.db; + +import java.io.Serializable; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.CascadeType; +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.Id; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.OneToMany; +import javax.persistence.Table; +import javax.persistence.TableGenerator; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "user_status") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "UserStatus.findAll", + query = "SELECT u FROM UserStatus u") + , @NamedQuery(name = "UserStatus.findById", + query = "SELECT u FROM UserStatus u WHERE u.id = :id") + , @NamedQuery(name = "UserStatus.findByStatus", + query = "SELECT u FROM UserStatus u WHERE u.status = :status") + , @NamedQuery(name = "UserStatus.findByDescription", + query = "SELECT u FROM UserStatus u WHERE u.description = :description")}) +public class UserStatus implements Serializable { + + private static final long serialVersionUID = 1L; + @Id + @Basic(optional = false) + @GeneratedValue(strategy = GenerationType.TABLE, generator = "UserStatusGEN") + @TableGenerator(name = "UserStatusGEN", + table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "user_status", + initialValue = 1_000, + allocationSize = 1) + @NotNull + @Column(name = "id") + private Integer id; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 255) + @Column(name = "status") + private String status; + @Size(max = 255) + @Column(name = "description") + private String description; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "userStatusId") + private List vmUserList; + + public UserStatus() { + } + + public UserStatus(String status) { + this.status = status; + } + + public Integer getId() { + return id; + } + + public void setId(Integer id) { + this.id = id; + } + + public String getStatus() { + return status; + } + + public void setStatus(String status) { + this.status = status; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + @XmlTransient + @JsonIgnore + public List getVmUserList() { + return vmUserList; + } + + public void setVmUserList(List vmUserList) { + this.vmUserList = vmUserList; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (id != null ? id.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof UserStatus)) { + return false; + } + UserStatus other = (UserStatus) object; + return !((this.id == null && other.id != null) + || (this.id != null && !this.id.equals(other.id))); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.UserStatus[ id=" + id + " ]"; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/VmSetting.java b/VM-Core/src/main/java/com/validation/manager/core/db/VmSetting.java index d4bce094..bff702e2 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/VmSetting.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/VmSetting.java @@ -13,179 +13,179 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import com.validation.manager.core.history.Auditable; -import com.validation.manager.core.history.Versionable; -import java.io.Serializable; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.CascadeType; -import javax.persistence.Column; -import javax.persistence.Entity; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.Id; -import javax.persistence.Lob; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.OneToMany; -import javax.persistence.Table; -import javax.persistence.TableGenerator; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "vm_setting") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "VmSetting.findAll", - query = "SELECT v FROM VmSetting v") - , @NamedQuery(name = "VmSetting.findById", - query = "SELECT v FROM VmSetting v WHERE v.id = :id") - , @NamedQuery(name = "VmSetting.findBySetting", - query = "SELECT v FROM VmSetting v WHERE v.setting = :setting") - , @NamedQuery(name = "VmSetting.findByBoolVal", - query = "SELECT v FROM VmSetting v WHERE v.boolVal = :boolVal") - , @NamedQuery(name = "VmSetting.findByIntVal", - query = "SELECT v FROM VmSetting v WHERE v.intVal = :intVal")}) -public class VmSetting extends Versionable implements Serializable { - - private static final long serialVersionUID = 1L; - @Id - @Basic(optional = false) - @GeneratedValue(strategy = GenerationType.TABLE, generator = "VM_SettingGEN") - @TableGenerator(name = "VM_SettingGEN", - table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "vm_setting", - initialValue = 1000, - allocationSize = 1) - @NotNull - @Column(name = "id") - private Integer id; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 255) - @Auditable - @Column(name = "setting") - private String setting; - @Auditable - @Column(name = "bool_val") - private Boolean boolVal; - @Auditable - @Column(name = "int_val") - private Integer intVal; - @Lob - @Size(max = 2147483647) - @Auditable - @Column(name = "long_val") - private String longVal; - @Lob - @Size(max = 2147483647) - @Auditable - @Column(name = "string_val") - private String stringVal; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "vmSettingId") - private List historyList; - - public VmSetting() { - } - - public VmSetting(String setting) { - this.setting = setting; - } - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - public String getSetting() { - return setting; - } - - public void setSetting(String setting) { - this.setting = setting; - } - - public Boolean getBoolVal() { - return boolVal; - } - - public void setBoolVal(Boolean boolVal) { - this.boolVal = boolVal; - } - - public Integer getIntVal() { - return intVal; - } - - public void setIntVal(Integer intVal) { - this.intVal = intVal; - } - - public String getLongVal() { - return longVal; - } - - public void setLongVal(String longVal) { - this.longVal = longVal; - } - - public String getStringVal() { - return stringVal; - } - - public void setStringVal(String stringVal) { - this.stringVal = stringVal; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (id != null ? id.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof VmSetting)) { - return false; - } - VmSetting other = (VmSetting) object; - return this.id.equals(other.id); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.VmSetting[ id=" + id + " ]"; - } - - @XmlTransient - @JsonIgnore - @Override - public List getHistoryList() { - return historyList; - } - - /** - * @param historyList the historyList to set - */ - @Override - public void setHistoryList(List historyList) { - this.historyList = historyList; - } -} +package com.validation.manager.core.db; + +import com.validation.manager.core.history.Auditable; +import com.validation.manager.core.history.Versionable; +import java.io.Serializable; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.CascadeType; +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.Id; +import javax.persistence.Lob; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.OneToMany; +import javax.persistence.Table; +import javax.persistence.TableGenerator; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "vm_setting") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "VmSetting.findAll", + query = "SELECT v FROM VmSetting v") + , @NamedQuery(name = "VmSetting.findById", + query = "SELECT v FROM VmSetting v WHERE v.id = :id") + , @NamedQuery(name = "VmSetting.findBySetting", + query = "SELECT v FROM VmSetting v WHERE v.setting = :setting") + , @NamedQuery(name = "VmSetting.findByBoolVal", + query = "SELECT v FROM VmSetting v WHERE v.boolVal = :boolVal") + , @NamedQuery(name = "VmSetting.findByIntVal", + query = "SELECT v FROM VmSetting v WHERE v.intVal = :intVal")}) +public class VmSetting extends Versionable implements Serializable { + + private static final long serialVersionUID = 1L; + @Id + @Basic(optional = false) + @GeneratedValue(strategy = GenerationType.TABLE, generator = "VM_SettingGEN") + @TableGenerator(name = "VM_SettingGEN", + table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "vm_setting", + initialValue = 1_000, + allocationSize = 1) + @NotNull + @Column(name = "id") + private Integer id; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 255) + @Auditable + @Column(name = "setting") + private String setting; + @Auditable + @Column(name = "bool_val") + private Boolean boolVal; + @Auditable + @Column(name = "int_val") + private Integer intVal; + @Lob + @Size(max = 2_147_483_647) + @Auditable + @Column(name = "long_val") + private String longVal; + @Lob + @Size(max = 2_147_483_647) + @Auditable + @Column(name = "string_val") + private String stringVal; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "vmSettingId") + private List historyList; + + public VmSetting() { + } + + public VmSetting(String setting) { + this.setting = setting; + } + + public Integer getId() { + return id; + } + + public void setId(Integer id) { + this.id = id; + } + + public String getSetting() { + return setting; + } + + public void setSetting(String setting) { + this.setting = setting; + } + + public Boolean getBoolVal() { + return boolVal; + } + + public void setBoolVal(Boolean boolVal) { + this.boolVal = boolVal; + } + + public Integer getIntVal() { + return intVal; + } + + public void setIntVal(Integer intVal) { + this.intVal = intVal; + } + + public String getLongVal() { + return longVal; + } + + public void setLongVal(String longVal) { + this.longVal = longVal; + } + + public String getStringVal() { + return stringVal; + } + + public void setStringVal(String stringVal) { + this.stringVal = stringVal; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (id != null ? id.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof VmSetting)) { + return false; + } + VmSetting other = (VmSetting) object; + return this.id.equals(other.id); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.VmSetting[ id=" + id + " ]"; + } + + @XmlTransient + @JsonIgnore + @Override + public List getHistoryList() { + return historyList; + } + + /** + * @param historyList the historyList to set + */ + @Override + public void setHistoryList(List historyList) { + this.historyList = historyList; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/VmUser.java b/VM-Core/src/main/java/com/validation/manager/core/db/VmUser.java index 318d00c4..e528c520 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/VmUser.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/VmUser.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,414 +13,438 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import com.validation.manager.core.history.Auditable; -import com.validation.manager.core.history.Login; -import java.io.Serializable; -import java.util.Date; -import java.util.List; -import javax.persistence.Basic; -import javax.persistence.CascadeType; -import javax.persistence.Column; -import javax.persistence.Entity; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.Id; -import javax.persistence.JoinColumn; -import javax.persistence.ManyToMany; -import javax.persistence.ManyToOne; -import javax.persistence.NamedQueries; -import javax.persistence.NamedQuery; -import javax.persistence.OneToMany; -import javax.persistence.Table; -import javax.persistence.TableGenerator; -import javax.validation.constraints.NotNull; -import javax.validation.constraints.Pattern; -import javax.validation.constraints.Size; -import javax.xml.bind.annotation.XmlRootElement; -import javax.xml.bind.annotation.XmlTransient; -import org.codehaus.jackson.annotate.JsonIgnore; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@Entity -@Table(name = "vm_user") -@XmlRootElement -@NamedQueries({ - @NamedQuery(name = "VmUser.findAll", - query = "SELECT v FROM VmUser v") - , @NamedQuery(name = "VmUser.findById", - query = "SELECT v FROM VmUser v WHERE v.id = :id") - , @NamedQuery(name = "VmUser.findByUsername", - query = "SELECT v FROM VmUser v WHERE v.username = :username") - , @NamedQuery(name = "VmUser.findByPassword", - query = "SELECT v FROM VmUser v WHERE v.password = :password") - , @NamedQuery(name = "VmUser.findByEmail", - query = "SELECT v FROM VmUser v WHERE v.email = :email") - , @NamedQuery(name = "VmUser.findByFirstName", - query = "SELECT v FROM VmUser v WHERE v.firstName = :firstName") - , @NamedQuery(name = "VmUser.findByLastName", - query = "SELECT v FROM VmUser v WHERE v.lastName = :lastName") - , @NamedQuery(name = "VmUser.findByLocale", - query = "SELECT v FROM VmUser v WHERE v.locale = :locale") - , @NamedQuery(name = "VmUser.findByLastModified", - query = "SELECT v FROM VmUser v WHERE v.lastModified = :lastModified") - , @NamedQuery(name = "VmUser.findByAttempts", - query = "SELECT v FROM VmUser v WHERE v.attempts = :attempts")}) -public class VmUser extends Login implements Serializable { - - private static final long serialVersionUID = 1L; - @Id - @Basic(optional = false) - @GeneratedValue(strategy = GenerationType.TABLE, generator = "VM_UserGEN") - @TableGenerator(name = "VM_UserGEN", - table = "vm_id", - pkColumnName = "table_name", - valueColumnName = "last_id", - pkColumnValue = "vm_user", - initialValue = 1000, - allocationSize = 1) - @NotNull - @Column(name = "id") - private Integer id; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 255) - @Auditable - @Column(name = "username") - private String username; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 255) - @Column(name = "password") - @Auditable - private String password; - @Pattern(regexp = "[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\\.[a-z0-9!#$%&'*+/=?^_`" - + "{|}~-]+)*@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\\.)+[a-z0-9](?:" - + "[a-z0-9-]*[a-z0-9])?", - message = "Invalid email")//if the field contains email address consider using this annotation to enforce field validation - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 100) - @Auditable - @Column(name = "email") - private String email; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 255) - @Column(name = "first_name") - @Auditable - private String firstName; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 255) - @Column(name = "last_name") - @Auditable - private String lastName; - @Basic(optional = false) - @NotNull - @Size(min = 1, max = 255) - @Auditable - @Column(name = "locale") - private String locale; - @ManyToMany(mappedBy = "vmUserList") - private List correctiveActionList; - @ManyToMany(mappedBy = "vmUserList") - private List roleList; - @ManyToMany(mappedBy = "vmUserList") - private List rootCauseList; - @JoinColumn(name = "user_status_id", referencedColumnName = "id") - @ManyToOne(optional = false) - private UserStatus userStatusId; - @OneToMany(mappedBy = "assignee") - private List executionStepList; - @OneToMany(mappedBy = "assigner") - private List executionStepList1; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "vmUser") - private List userTestProjectRoleList; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "vmUser") - private List userTestPlanRoleList; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "vmUser") - private List userModifiedRecordList; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "vmUser") - private List userHasInvestigationList; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "vmUser") - private List userAssigmentList; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "assigneeId") - private List userAssigmentList1; - @ManyToMany(mappedBy = "vmUserList") - private List executionStepHasIssueList; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "vmUser") - private List executionStepHasVmUserList; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "modifierId") - private List historyModificationList; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "targetUser") - private List notificationList; - @OneToMany(cascade = CascadeType.ALL, mappedBy = "author") - private List notificationList1; - - public VmUser() { - super(); - } - - public VmUser(String username, String password, String email, String first, - String last, String locale, Date lastModified, - UserStatus userStatus, int attempts) { - this.username = username; - this.password = password; - this.email = email; - this.firstName = first; - this.lastName = last; - this.locale = locale; - this.userStatusId = userStatus; - } - - public Integer getId() { - return id; - } - - public void setId(Integer id) { - this.id = id; - } - - public String getUsername() { - return username; - } - - public void setUsername(String username) { - this.username = username; - } - - public String getPassword() { - return password; - } - - public void setPassword(String password) { - this.password = password; - } - - public String getEmail() { - return email; - } - - public void setEmail(String email) { - this.email = email; - } - - public String getFirstName() { - return firstName; - } - - public void setFirstName(String firstName) { - this.firstName = firstName; - } - - public String getLastName() { - return lastName; - } - - public void setLastName(String lastName) { - this.lastName = lastName; - } - - public String getLocale() { - return locale; - } - - public void setLocale(String locale) { - this.locale = locale; - } - - @XmlTransient - @JsonIgnore - public List getCorrectiveActionList() { - return correctiveActionList; - } - - public void setCorrectiveActionList(List correctiveActionList) { - this.correctiveActionList = correctiveActionList; - } - - @XmlTransient - @JsonIgnore - public List getRoleList() { - return roleList; - } - - public void setRoleList(List roleList) { - this.roleList = roleList; - } - - @XmlTransient - @JsonIgnore - public List getRootCauseList() { - return rootCauseList; - } - - public void setRootCauseList(List rootCauseList) { - this.rootCauseList = rootCauseList; - } - - public UserStatus getUserStatusId() { - return userStatusId; - } - - public void setUserStatusId(UserStatus userStatusId) { - this.userStatusId = userStatusId; - } - - @XmlTransient - @JsonIgnore - public List getExecutionStepList() { - return executionStepList; - } - - public void setExecutionStepList(List executionStepList) { - this.executionStepList = executionStepList; - } - - @XmlTransient - @JsonIgnore - public List getExecutionStepList1() { - return executionStepList1; - } - - public void setExecutionStepList1(List executionStepList1) { - this.executionStepList1 = executionStepList1; - } - - @XmlTransient - @JsonIgnore - public List getUserTestProjectRoleList() { - return userTestProjectRoleList; - } - - public void setUserTestProjectRoleList(List userTestProjectRoleList) { - this.userTestProjectRoleList = userTestProjectRoleList; - } - - @XmlTransient - @JsonIgnore - public List getUserTestPlanRoleList() { - return userTestPlanRoleList; - } - - public void setUserTestPlanRoleList(List userTestPlanRoleList) { - this.userTestPlanRoleList = userTestPlanRoleList; - } - - @XmlTransient - @JsonIgnore - public List getUserModifiedRecordList() { - return userModifiedRecordList; - } - - public void setUserModifiedRecordList(List userModifiedRecordList) { - this.userModifiedRecordList = userModifiedRecordList; - } - - @XmlTransient - @JsonIgnore - public List getUserHasInvestigationList() { - return userHasInvestigationList; - } - - public void setUserHasInvestigationList(List userHasInvestigationList) { - this.userHasInvestigationList = userHasInvestigationList; - } - - @XmlTransient - @JsonIgnore - public List getUserAssigmentList() { - return userAssigmentList; - } - - public void setUserAssigmentList(List userAssigmentList) { - this.userAssigmentList = userAssigmentList; - } - - @XmlTransient - @JsonIgnore - public List getUserAssigmentList1() { - return userAssigmentList1; - } - - public void setUserAssigmentList1(List userAssigmentList1) { - this.userAssigmentList1 = userAssigmentList1; - } - - @Override - public int hashCode() { - int hash = 0; - hash += (id != null ? id.hashCode() : 0); - return hash; - } - - @Override - public boolean equals(Object object) { - - if (!(object instanceof VmUser)) { - return false; - } - VmUser other = (VmUser) object; - return this.id.equals(other.id); - } - - @Override - public String toString() { - return "com.validation.manager.core.db.VmUser[ id=" + id + " ]"; - } - - @XmlTransient - @JsonIgnore - public List getExecutionStepHasIssueList() { - return executionStepHasIssueList; - } - - public void setExecutionStepHasIssueList(List executionStepHasIssueList) { - this.executionStepHasIssueList = executionStepHasIssueList; - } - - @XmlTransient - @JsonIgnore - public List getExecutionStepHasVmUserList() { - return executionStepHasVmUserList; - } - - public void setExecutionStepHasVmUserList(List executionStepHasVmUserList) { - this.executionStepHasVmUserList = executionStepHasVmUserList; - } - - @XmlTransient - @JsonIgnore - public List getHistoryModificationList() { - return historyModificationList; - } - - public void setHistoryModificationList(List historyList) { - this.historyModificationList = historyList; - } - - @XmlTransient - @JsonIgnore - public List getNotificationList() { - return notificationList; - } - - public void setNotificationList(List notificationList) { - this.notificationList = notificationList; - } - - @XmlTransient - @JsonIgnore - public List getNotificationList1() { - return notificationList1; - } - - public void setNotificationList1(List notificationList1) { - this.notificationList1 = notificationList1; - } -} +package com.validation.manager.core.db; + +import com.validation.manager.core.history.Auditable; +import com.validation.manager.core.history.Versionable; +import java.io.Serializable; +import java.util.List; +import javax.persistence.Basic; +import javax.persistence.CascadeType; +import javax.persistence.Column; +import javax.persistence.Entity; +import javax.persistence.GeneratedValue; +import javax.persistence.GenerationType; +import javax.persistence.Id; +import javax.persistence.JoinColumn; +import javax.persistence.ManyToMany; +import javax.persistence.ManyToOne; +import javax.persistence.NamedQueries; +import javax.persistence.NamedQuery; +import javax.persistence.OneToMany; +import javax.persistence.Table; +import javax.persistence.TableGenerator; +import javax.validation.constraints.Min; +import javax.validation.constraints.NotNull; +import javax.validation.constraints.Pattern; +import javax.validation.constraints.Size; +import javax.xml.bind.annotation.XmlRootElement; +import javax.xml.bind.annotation.XmlTransient; +import org.codehaus.jackson.annotate.JsonIgnore; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@Entity +@Table(name = "vm_user") +@XmlRootElement +@NamedQueries({ + @NamedQuery(name = "VmUser.findAll", + query = "SELECT v FROM VmUser v") + , @NamedQuery(name = "VmUser.findById", + query = "SELECT v FROM VmUser v WHERE v.id = :id") + , @NamedQuery(name = "VmUser.findByUsername", + query = "SELECT v FROM VmUser v WHERE v.username = :username") + , @NamedQuery(name = "VmUser.findByPassword", + query = "SELECT v FROM VmUser v WHERE v.password = :password") + , @NamedQuery(name = "VmUser.findByEmail", + query = "SELECT v FROM VmUser v WHERE v.email = :email") + , @NamedQuery(name = "VmUser.findByFirstName", + query = "SELECT v FROM VmUser v WHERE v.firstName = :firstName") + , @NamedQuery(name = "VmUser.findByLastName", + query = "SELECT v FROM VmUser v WHERE v.lastName = :lastName") + , @NamedQuery(name = "VmUser.findByLocale", + query = "SELECT v FROM VmUser v WHERE v.locale = :locale") + , @NamedQuery(name = "VmUser.findByAttempts", + query = "SELECT v FROM VmUser v WHERE v.attempts = :attempts")}) +public class VmUser extends Versionable implements Serializable { + + private static final long serialVersionUID = 1L; + @Id + @Basic(optional = false) + @GeneratedValue(strategy = GenerationType.TABLE, generator = "VM_UserGEN") + @TableGenerator(name = "VM_UserGEN", + table = "vm_id", + pkColumnName = "table_name", + valueColumnName = "last_id", + pkColumnValue = "vm_user", + initialValue = 1_000, + allocationSize = 1) + @NotNull + @Column(name = "id") + private Integer id; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 255) + @Auditable + @Column(name = "username") + private String username; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 255) + @Column(name = "password") + @Auditable + private String password; + @Pattern(regexp = "[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\\.[a-z0-9!#$%&'*+/=?^_`" + + "{|}~-]+)*@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\\.)+[a-z0-9](?:" + + "[a-z0-9-]*[a-z0-9])?", + message = "Invalid email")//if the field contains email address consider using this annotation to enforce field validation + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 100) + @Auditable + @Column(name = "email") + private String email; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 255) + @Column(name = "first_name") + @Auditable + private String firstName; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 255) + @Column(name = "last_name") + @Auditable + private String lastName; + @Basic(optional = false) + @NotNull + @Size(min = 1, max = 255) + @Auditable + @Column(name = "locale") + private String locale; + @ManyToMany(mappedBy = "vmUserList") + private List correctiveActionList; + @ManyToMany(mappedBy = "vmUserList") + private List roleList; + @ManyToMany(mappedBy = "vmUserList") + private List rootCauseList; + @JoinColumn(name = "user_status_id", referencedColumnName = "id") + @ManyToOne(optional = false) + private UserStatus userStatusId; + @OneToMany(mappedBy = "assignee") + private List executionStepList; + @OneToMany(mappedBy = "assigner") + private List executionStepList1; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "vmUser") + private List userTestProjectRoleList; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "vmUser") + private List userTestPlanRoleList; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "vmUser") + private List userModifiedRecordList; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "vmUser") + private List userHasInvestigationList; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "vmUser") + private List userAssigmentList; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "assigneeId") + private List userAssigmentList1; + @ManyToMany(mappedBy = "vmUserList") + private List executionStepHasIssueList; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "vmUser") + private List executionStepHasVmUserList; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "modifierId") + private List historyModificationList; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "targetUser") + private List notificationList; + @OneToMany(cascade = CascadeType.ALL, mappedBy = "author") + private List notificationList1; + @OneToMany(mappedBy = "vmUserId") + private List historyList; + @Basic(optional = false) + @NotNull + @Column(name = "attempts") + @Min(value = 0) + private int attempts; + + public VmUser() { + super(); + } + + public VmUser(String username, String password, String email, String first, + String last, String locale, UserStatus userStatus, int attempts) { + this.username = username; + this.password = password; + this.email = email; + this.firstName = first; + this.lastName = last; + this.locale = locale; + this.userStatusId = userStatus; + } + + public Integer getId() { + return id; + } + + public void setId(Integer id) { + this.id = id; + } + + public String getUsername() { + return username; + } + + public void setUsername(String username) { + this.username = username; + } + + public String getPassword() { + return password; + } + + public void setPassword(String password) { + this.password = password; + } + + public String getEmail() { + return email; + } + + public void setEmail(String email) { + this.email = email; + } + + public String getFirstName() { + return firstName; + } + + public void setFirstName(String firstName) { + this.firstName = firstName; + } + + public String getLastName() { + return lastName; + } + + public void setLastName(String lastName) { + this.lastName = lastName; + } + + public String getLocale() { + return locale; + } + + public void setLocale(String locale) { + this.locale = locale; + } + + @XmlTransient + @JsonIgnore + public List getCorrectiveActionList() { + return correctiveActionList; + } + + public void setCorrectiveActionList(List correctiveActionList) { + this.correctiveActionList = correctiveActionList; + } + + @XmlTransient + @JsonIgnore + public List getRoleList() { + return roleList; + } + + public void setRoleList(List roleList) { + this.roleList = roleList; + } + + @XmlTransient + @JsonIgnore + public List getRootCauseList() { + return rootCauseList; + } + + public void setRootCauseList(List rootCauseList) { + this.rootCauseList = rootCauseList; + } + + public UserStatus getUserStatusId() { + return userStatusId; + } + + public void setUserStatusId(UserStatus userStatusId) { + this.userStatusId = userStatusId; + } + + @XmlTransient + @JsonIgnore + public List getExecutionStepList() { + return executionStepList; + } + + public void setExecutionStepList(List executionStepList) { + this.executionStepList = executionStepList; + } + + @XmlTransient + @JsonIgnore + public List getExecutionStepList1() { + return executionStepList1; + } + + public void setExecutionStepList1(List executionStepList1) { + this.executionStepList1 = executionStepList1; + } + + @XmlTransient + @JsonIgnore + public List getUserTestProjectRoleList() { + return userTestProjectRoleList; + } + + public void setUserTestProjectRoleList(List userTestProjectRoleList) { + this.userTestProjectRoleList = userTestProjectRoleList; + } + + @XmlTransient + @JsonIgnore + public List getUserTestPlanRoleList() { + return userTestPlanRoleList; + } + + public void setUserTestPlanRoleList(List userTestPlanRoleList) { + this.userTestPlanRoleList = userTestPlanRoleList; + } + + @XmlTransient + @JsonIgnore + public List getUserModifiedRecordList() { + return userModifiedRecordList; + } + + public void setUserModifiedRecordList(List userModifiedRecordList) { + this.userModifiedRecordList = userModifiedRecordList; + } + + @XmlTransient + @JsonIgnore + public List getUserHasInvestigationList() { + return userHasInvestigationList; + } + + public void setUserHasInvestigationList(List userHasInvestigationList) { + this.userHasInvestigationList = userHasInvestigationList; + } + + @XmlTransient + @JsonIgnore + public List getUserAssigmentList() { + return userAssigmentList; + } + + public void setUserAssigmentList(List userAssigmentList) { + this.userAssigmentList = userAssigmentList; + } + + @XmlTransient + @JsonIgnore + public List getUserAssigmentList1() { + return userAssigmentList1; + } + + public void setUserAssigmentList1(List userAssigmentList1) { + this.userAssigmentList1 = userAssigmentList1; + } + + @Override + public int hashCode() { + int hash = 0; + hash += (id != null ? id.hashCode() : 0); + return hash; + } + + @Override + public boolean equals(Object object) { + + if (!(object instanceof VmUser)) { + return false; + } + VmUser other = (VmUser) object; + return this.id.equals(other.id); + } + + @Override + public String toString() { + return "com.validation.manager.core.db.VmUser[ id=" + id + " ]"; + } + + @XmlTransient + @JsonIgnore + public List getExecutionStepHasIssueList() { + return executionStepHasIssueList; + } + + public void setExecutionStepHasIssueList(List executionStepHasIssueList) { + this.executionStepHasIssueList = executionStepHasIssueList; + } + + @XmlTransient + @JsonIgnore + public List getExecutionStepHasVmUserList() { + return executionStepHasVmUserList; + } + + public void setExecutionStepHasVmUserList(List executionStepHasVmUserList) { + this.executionStepHasVmUserList = executionStepHasVmUserList; + } + + @XmlTransient + @JsonIgnore + public List getHistoryModificationList() { + return historyModificationList; + } + + public void setHistoryModificationList(List historyList) { + this.historyModificationList = historyList; + } + + @XmlTransient + @JsonIgnore + public List getNotificationList() { + return notificationList; + } + + public void setNotificationList(List notificationList) { + this.notificationList = notificationList; + } + + @XmlTransient + @JsonIgnore + public List getNotificationList1() { + return notificationList1; + } + + public void setNotificationList1(List notificationList1) { + this.notificationList1 = notificationList1; + } + + @XmlTransient + @JsonIgnore + @Override + public List getHistoryList() { + return historyList; + } + + @Override + public void setHistoryList(List historyList) { + this.historyList = historyList; + } + + public int getAttempts() { + return attempts; + } + + public void setAttempts(int attempts) { + this.attempts = attempts; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/AssigmentTypeJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/AssigmentTypeJpaController.java index 9844a7af..9dd288ab 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/AssigmentTypeJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/AssigmentTypeJpaController.java @@ -13,209 +13,209 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import com.validation.manager.core.db.AssigmentType; -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.UserAssigment; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import java.util.ArrayList; -import java.util.List; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class AssigmentTypeJpaController implements Serializable { - - public AssigmentTypeJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(AssigmentType assigmentType) { - if (assigmentType.getUserAssigmentList() == null) { - assigmentType.setUserAssigmentList(new ArrayList()); - } - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - List attachedUserAssigmentList = new ArrayList(); - for (UserAssigment userAssigmentListUserAssigmentToAttach : assigmentType.getUserAssigmentList()) { - userAssigmentListUserAssigmentToAttach = em.getReference(userAssigmentListUserAssigmentToAttach.getClass(), userAssigmentListUserAssigmentToAttach.getUserAssigmentPK()); - attachedUserAssigmentList.add(userAssigmentListUserAssigmentToAttach); - } - assigmentType.setUserAssigmentList(attachedUserAssigmentList); - em.persist(assigmentType); - for (UserAssigment userAssigmentListUserAssigment : assigmentType.getUserAssigmentList()) { - AssigmentType oldAssigmentTypeOfUserAssigmentListUserAssigment = userAssigmentListUserAssigment.getAssigmentType(); - userAssigmentListUserAssigment.setAssigmentType(assigmentType); - userAssigmentListUserAssigment = em.merge(userAssigmentListUserAssigment); - if (oldAssigmentTypeOfUserAssigmentListUserAssigment != null) { - oldAssigmentTypeOfUserAssigmentListUserAssigment.getUserAssigmentList().remove(userAssigmentListUserAssigment); - oldAssigmentTypeOfUserAssigmentListUserAssigment = em.merge(oldAssigmentTypeOfUserAssigmentListUserAssigment); - } - } - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(AssigmentType assigmentType) throws IllegalOrphanException, NonexistentEntityException, Exception { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - AssigmentType persistentAssigmentType = em.find(AssigmentType.class, assigmentType.getId()); - List userAssigmentListOld = persistentAssigmentType.getUserAssigmentList(); - List userAssigmentListNew = assigmentType.getUserAssigmentList(); - List illegalOrphanMessages = null; - for (UserAssigment userAssigmentListOldUserAssigment : userAssigmentListOld) { - if (!userAssigmentListNew.contains(userAssigmentListOldUserAssigment)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain UserAssigment " + userAssigmentListOldUserAssigment + " since its assigmentType field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - List attachedUserAssigmentListNew = new ArrayList(); - for (UserAssigment userAssigmentListNewUserAssigmentToAttach : userAssigmentListNew) { - userAssigmentListNewUserAssigmentToAttach = em.getReference(userAssigmentListNewUserAssigmentToAttach.getClass(), userAssigmentListNewUserAssigmentToAttach.getUserAssigmentPK()); - attachedUserAssigmentListNew.add(userAssigmentListNewUserAssigmentToAttach); - } - userAssigmentListNew = attachedUserAssigmentListNew; - assigmentType.setUserAssigmentList(userAssigmentListNew); - assigmentType = em.merge(assigmentType); - for (UserAssigment userAssigmentListNewUserAssigment : userAssigmentListNew) { - if (!userAssigmentListOld.contains(userAssigmentListNewUserAssigment)) { - AssigmentType oldAssigmentTypeOfUserAssigmentListNewUserAssigment = userAssigmentListNewUserAssigment.getAssigmentType(); - userAssigmentListNewUserAssigment.setAssigmentType(assigmentType); - userAssigmentListNewUserAssigment = em.merge(userAssigmentListNewUserAssigment); - if (oldAssigmentTypeOfUserAssigmentListNewUserAssigment != null && !oldAssigmentTypeOfUserAssigmentListNewUserAssigment.equals(assigmentType)) { - oldAssigmentTypeOfUserAssigmentListNewUserAssigment.getUserAssigmentList().remove(userAssigmentListNewUserAssigment); - oldAssigmentTypeOfUserAssigmentListNewUserAssigment = em.merge(oldAssigmentTypeOfUserAssigmentListNewUserAssigment); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - Integer id = assigmentType.getId(); - if (findAssigmentType(id) == null) { - throw new NonexistentEntityException("The assigmentType with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - AssigmentType assigmentType; - try { - assigmentType = em.getReference(AssigmentType.class, id); - assigmentType.getId(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The assigmentType with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List userAssigmentListOrphanCheck = assigmentType.getUserAssigmentList(); - for (UserAssigment userAssigmentListOrphanCheckUserAssigment : userAssigmentListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This AssigmentType (" + assigmentType + ") cannot be destroyed since the UserAssigment " + userAssigmentListOrphanCheckUserAssigment + " in its userAssigmentList field has a non-nullable assigmentType field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - em.remove(assigmentType); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findAssigmentTypeEntities() { - return findAssigmentTypeEntities(true, -1, -1); - } - - public List findAssigmentTypeEntities(int maxResults, int firstResult) { - return findAssigmentTypeEntities(false, maxResults, firstResult); - } - - private List findAssigmentTypeEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(AssigmentType.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public AssigmentType findAssigmentType(Integer id) { - EntityManager em = getEntityManager(); - try { - return em.find(AssigmentType.class, id); - } - finally { - em.close(); - } - } - - public int getAssigmentTypeCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(AssigmentType.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import com.validation.manager.core.db.AssigmentType; +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.UserAssigment; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import java.util.ArrayList; +import java.util.List; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class AssigmentTypeJpaController implements Serializable { + + public AssigmentTypeJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(AssigmentType assigmentType) { + if (assigmentType.getUserAssigmentList() == null) { + assigmentType.setUserAssigmentList(new ArrayList<>()); + } + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + List attachedUserAssigmentList = new ArrayList<>(); + for (UserAssigment userAssigmentListUserAssigmentToAttach : assigmentType.getUserAssigmentList()) { + userAssigmentListUserAssigmentToAttach = em.getReference(userAssigmentListUserAssigmentToAttach.getClass(), userAssigmentListUserAssigmentToAttach.getUserAssigmentPK()); + attachedUserAssigmentList.add(userAssigmentListUserAssigmentToAttach); + } + assigmentType.setUserAssigmentList(attachedUserAssigmentList); + em.persist(assigmentType); + for (UserAssigment userAssigmentListUserAssigment : assigmentType.getUserAssigmentList()) { + AssigmentType oldAssigmentTypeOfUserAssigmentListUserAssigment = userAssigmentListUserAssigment.getAssigmentType(); + userAssigmentListUserAssigment.setAssigmentType(assigmentType); + userAssigmentListUserAssigment = em.merge(userAssigmentListUserAssigment); + if (oldAssigmentTypeOfUserAssigmentListUserAssigment != null) { + oldAssigmentTypeOfUserAssigmentListUserAssigment.getUserAssigmentList().remove(userAssigmentListUserAssigment); + oldAssigmentTypeOfUserAssigmentListUserAssigment = em.merge(oldAssigmentTypeOfUserAssigmentListUserAssigment); + } + } + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(AssigmentType assigmentType) throws IllegalOrphanException, NonexistentEntityException, Exception { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + AssigmentType persistentAssigmentType = em.find(AssigmentType.class, assigmentType.getId()); + List userAssigmentListOld = persistentAssigmentType.getUserAssigmentList(); + List userAssigmentListNew = assigmentType.getUserAssigmentList(); + List illegalOrphanMessages = null; + for (UserAssigment userAssigmentListOldUserAssigment : userAssigmentListOld) { + if (!userAssigmentListNew.contains(userAssigmentListOldUserAssigment)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain UserAssigment " + userAssigmentListOldUserAssigment + " since its assigmentType field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + List attachedUserAssigmentListNew = new ArrayList<>(); + for (UserAssigment userAssigmentListNewUserAssigmentToAttach : userAssigmentListNew) { + userAssigmentListNewUserAssigmentToAttach = em.getReference(userAssigmentListNewUserAssigmentToAttach.getClass(), userAssigmentListNewUserAssigmentToAttach.getUserAssigmentPK()); + attachedUserAssigmentListNew.add(userAssigmentListNewUserAssigmentToAttach); + } + userAssigmentListNew = attachedUserAssigmentListNew; + assigmentType.setUserAssigmentList(userAssigmentListNew); + assigmentType = em.merge(assigmentType); + for (UserAssigment userAssigmentListNewUserAssigment : userAssigmentListNew) { + if (!userAssigmentListOld.contains(userAssigmentListNewUserAssigment)) { + AssigmentType oldAssigmentTypeOfUserAssigmentListNewUserAssigment = userAssigmentListNewUserAssigment.getAssigmentType(); + userAssigmentListNewUserAssigment.setAssigmentType(assigmentType); + userAssigmentListNewUserAssigment = em.merge(userAssigmentListNewUserAssigment); + if (oldAssigmentTypeOfUserAssigmentListNewUserAssigment != null && !oldAssigmentTypeOfUserAssigmentListNewUserAssigment.equals(assigmentType)) { + oldAssigmentTypeOfUserAssigmentListNewUserAssigment.getUserAssigmentList().remove(userAssigmentListNewUserAssigment); + oldAssigmentTypeOfUserAssigmentListNewUserAssigment = em.merge(oldAssigmentTypeOfUserAssigmentListNewUserAssigment); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + Integer id = assigmentType.getId(); + if (findAssigmentType(id) == null) { + throw new NonexistentEntityException("The assigmentType with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + AssigmentType assigmentType; + try { + assigmentType = em.getReference(AssigmentType.class, id); + assigmentType.getId(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The assigmentType with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List userAssigmentListOrphanCheck = assigmentType.getUserAssigmentList(); + for (UserAssigment userAssigmentListOrphanCheckUserAssigment : userAssigmentListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This AssigmentType (" + assigmentType + ") cannot be destroyed since the UserAssigment " + userAssigmentListOrphanCheckUserAssigment + " in its userAssigmentList field has a non-nullable assigmentType field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + em.remove(assigmentType); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findAssigmentTypeEntities() { + return findAssigmentTypeEntities(true, -1, -1); + } + + public List findAssigmentTypeEntities(int maxResults, int firstResult) { + return findAssigmentTypeEntities(false, maxResults, firstResult); + } + + private List findAssigmentTypeEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(AssigmentType.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public AssigmentType findAssigmentType(Integer id) { + EntityManager em = getEntityManager(); + try { + return em.find(AssigmentType.class, id); + } + finally { + em.close(); + } + } + + public int getAssigmentTypeCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(AssigmentType.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/AssignmentStatusJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/AssignmentStatusJpaController.java index 618ca14c..97769f3c 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/AssignmentStatusJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/AssignmentStatusJpaController.java @@ -13,209 +13,209 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import com.validation.manager.core.db.AssignmentStatus; -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.UserAssigment; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import java.util.ArrayList; -import java.util.List; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class AssignmentStatusJpaController implements Serializable { - - public AssignmentStatusJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(AssignmentStatus assignmentStatus) { - if (assignmentStatus.getUserAssigmentList() == null) { - assignmentStatus.setUserAssigmentList(new ArrayList()); - } - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - List attachedUserAssigmentList = new ArrayList(); - for (UserAssigment userAssigmentListUserAssigmentToAttach : assignmentStatus.getUserAssigmentList()) { - userAssigmentListUserAssigmentToAttach = em.getReference(userAssigmentListUserAssigmentToAttach.getClass(), userAssigmentListUserAssigmentToAttach.getUserAssigmentPK()); - attachedUserAssigmentList.add(userAssigmentListUserAssigmentToAttach); - } - assignmentStatus.setUserAssigmentList(attachedUserAssigmentList); - em.persist(assignmentStatus); - for (UserAssigment userAssigmentListUserAssigment : assignmentStatus.getUserAssigmentList()) { - AssignmentStatus oldAssignmentStatusOfUserAssigmentListUserAssigment = userAssigmentListUserAssigment.getAssignmentStatus(); - userAssigmentListUserAssigment.setAssignmentStatus(assignmentStatus); - userAssigmentListUserAssigment = em.merge(userAssigmentListUserAssigment); - if (oldAssignmentStatusOfUserAssigmentListUserAssigment != null) { - oldAssignmentStatusOfUserAssigmentListUserAssigment.getUserAssigmentList().remove(userAssigmentListUserAssigment); - oldAssignmentStatusOfUserAssigmentListUserAssigment = em.merge(oldAssignmentStatusOfUserAssigmentListUserAssigment); - } - } - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(AssignmentStatus assignmentStatus) throws IllegalOrphanException, NonexistentEntityException, Exception { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - AssignmentStatus persistentAssignmentStatus = em.find(AssignmentStatus.class, assignmentStatus.getId()); - List userAssigmentListOld = persistentAssignmentStatus.getUserAssigmentList(); - List userAssigmentListNew = assignmentStatus.getUserAssigmentList(); - List illegalOrphanMessages = null; - for (UserAssigment userAssigmentListOldUserAssigment : userAssigmentListOld) { - if (!userAssigmentListNew.contains(userAssigmentListOldUserAssigment)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain UserAssigment " + userAssigmentListOldUserAssigment + " since its assignmentStatus field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - List attachedUserAssigmentListNew = new ArrayList(); - for (UserAssigment userAssigmentListNewUserAssigmentToAttach : userAssigmentListNew) { - userAssigmentListNewUserAssigmentToAttach = em.getReference(userAssigmentListNewUserAssigmentToAttach.getClass(), userAssigmentListNewUserAssigmentToAttach.getUserAssigmentPK()); - attachedUserAssigmentListNew.add(userAssigmentListNewUserAssigmentToAttach); - } - userAssigmentListNew = attachedUserAssigmentListNew; - assignmentStatus.setUserAssigmentList(userAssigmentListNew); - assignmentStatus = em.merge(assignmentStatus); - for (UserAssigment userAssigmentListNewUserAssigment : userAssigmentListNew) { - if (!userAssigmentListOld.contains(userAssigmentListNewUserAssigment)) { - AssignmentStatus oldAssignmentStatusOfUserAssigmentListNewUserAssigment = userAssigmentListNewUserAssigment.getAssignmentStatus(); - userAssigmentListNewUserAssigment.setAssignmentStatus(assignmentStatus); - userAssigmentListNewUserAssigment = em.merge(userAssigmentListNewUserAssigment); - if (oldAssignmentStatusOfUserAssigmentListNewUserAssigment != null && !oldAssignmentStatusOfUserAssigmentListNewUserAssigment.equals(assignmentStatus)) { - oldAssignmentStatusOfUserAssigmentListNewUserAssigment.getUserAssigmentList().remove(userAssigmentListNewUserAssigment); - oldAssignmentStatusOfUserAssigmentListNewUserAssigment = em.merge(oldAssignmentStatusOfUserAssigmentListNewUserAssigment); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - Integer id = assignmentStatus.getId(); - if (findAssignmentStatus(id) == null) { - throw new NonexistentEntityException("The assignmentStatus with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - AssignmentStatus assignmentStatus; - try { - assignmentStatus = em.getReference(AssignmentStatus.class, id); - assignmentStatus.getId(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The assignmentStatus with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List userAssigmentListOrphanCheck = assignmentStatus.getUserAssigmentList(); - for (UserAssigment userAssigmentListOrphanCheckUserAssigment : userAssigmentListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This AssignmentStatus (" + assignmentStatus + ") cannot be destroyed since the UserAssigment " + userAssigmentListOrphanCheckUserAssigment + " in its userAssigmentList field has a non-nullable assignmentStatus field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - em.remove(assignmentStatus); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findAssignmentStatusEntities() { - return findAssignmentStatusEntities(true, -1, -1); - } - - public List findAssignmentStatusEntities(int maxResults, int firstResult) { - return findAssignmentStatusEntities(false, maxResults, firstResult); - } - - private List findAssignmentStatusEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(AssignmentStatus.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public AssignmentStatus findAssignmentStatus(Integer id) { - EntityManager em = getEntityManager(); - try { - return em.find(AssignmentStatus.class, id); - } - finally { - em.close(); - } - } - - public int getAssignmentStatusCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(AssignmentStatus.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import com.validation.manager.core.db.AssignmentStatus; +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.UserAssigment; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import java.util.ArrayList; +import java.util.List; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class AssignmentStatusJpaController implements Serializable { + + public AssignmentStatusJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(AssignmentStatus assignmentStatus) { + if (assignmentStatus.getUserAssigmentList() == null) { + assignmentStatus.setUserAssigmentList(new ArrayList<>()); + } + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + List attachedUserAssigmentList = new ArrayList<>(); + for (UserAssigment userAssigmentListUserAssigmentToAttach : assignmentStatus.getUserAssigmentList()) { + userAssigmentListUserAssigmentToAttach = em.getReference(userAssigmentListUserAssigmentToAttach.getClass(), userAssigmentListUserAssigmentToAttach.getUserAssigmentPK()); + attachedUserAssigmentList.add(userAssigmentListUserAssigmentToAttach); + } + assignmentStatus.setUserAssigmentList(attachedUserAssigmentList); + em.persist(assignmentStatus); + for (UserAssigment userAssigmentListUserAssigment : assignmentStatus.getUserAssigmentList()) { + AssignmentStatus oldAssignmentStatusOfUserAssigmentListUserAssigment = userAssigmentListUserAssigment.getAssignmentStatus(); + userAssigmentListUserAssigment.setAssignmentStatus(assignmentStatus); + userAssigmentListUserAssigment = em.merge(userAssigmentListUserAssigment); + if (oldAssignmentStatusOfUserAssigmentListUserAssigment != null) { + oldAssignmentStatusOfUserAssigmentListUserAssigment.getUserAssigmentList().remove(userAssigmentListUserAssigment); + oldAssignmentStatusOfUserAssigmentListUserAssigment = em.merge(oldAssignmentStatusOfUserAssigmentListUserAssigment); + } + } + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(AssignmentStatus assignmentStatus) throws IllegalOrphanException, NonexistentEntityException, Exception { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + AssignmentStatus persistentAssignmentStatus = em.find(AssignmentStatus.class, assignmentStatus.getId()); + List userAssigmentListOld = persistentAssignmentStatus.getUserAssigmentList(); + List userAssigmentListNew = assignmentStatus.getUserAssigmentList(); + List illegalOrphanMessages = null; + for (UserAssigment userAssigmentListOldUserAssigment : userAssigmentListOld) { + if (!userAssigmentListNew.contains(userAssigmentListOldUserAssigment)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain UserAssigment " + userAssigmentListOldUserAssigment + " since its assignmentStatus field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + List attachedUserAssigmentListNew = new ArrayList<>(); + for (UserAssigment userAssigmentListNewUserAssigmentToAttach : userAssigmentListNew) { + userAssigmentListNewUserAssigmentToAttach = em.getReference(userAssigmentListNewUserAssigmentToAttach.getClass(), userAssigmentListNewUserAssigmentToAttach.getUserAssigmentPK()); + attachedUserAssigmentListNew.add(userAssigmentListNewUserAssigmentToAttach); + } + userAssigmentListNew = attachedUserAssigmentListNew; + assignmentStatus.setUserAssigmentList(userAssigmentListNew); + assignmentStatus = em.merge(assignmentStatus); + for (UserAssigment userAssigmentListNewUserAssigment : userAssigmentListNew) { + if (!userAssigmentListOld.contains(userAssigmentListNewUserAssigment)) { + AssignmentStatus oldAssignmentStatusOfUserAssigmentListNewUserAssigment = userAssigmentListNewUserAssigment.getAssignmentStatus(); + userAssigmentListNewUserAssigment.setAssignmentStatus(assignmentStatus); + userAssigmentListNewUserAssigment = em.merge(userAssigmentListNewUserAssigment); + if (oldAssignmentStatusOfUserAssigmentListNewUserAssigment != null && !oldAssignmentStatusOfUserAssigmentListNewUserAssigment.equals(assignmentStatus)) { + oldAssignmentStatusOfUserAssigmentListNewUserAssigment.getUserAssigmentList().remove(userAssigmentListNewUserAssigment); + oldAssignmentStatusOfUserAssigmentListNewUserAssigment = em.merge(oldAssignmentStatusOfUserAssigmentListNewUserAssigment); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + Integer id = assignmentStatus.getId(); + if (findAssignmentStatus(id) == null) { + throw new NonexistentEntityException("The assignmentStatus with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + AssignmentStatus assignmentStatus; + try { + assignmentStatus = em.getReference(AssignmentStatus.class, id); + assignmentStatus.getId(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The assignmentStatus with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List userAssigmentListOrphanCheck = assignmentStatus.getUserAssigmentList(); + for (UserAssigment userAssigmentListOrphanCheckUserAssigment : userAssigmentListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This AssignmentStatus (" + assignmentStatus + ") cannot be destroyed since the UserAssigment " + userAssigmentListOrphanCheckUserAssigment + " in its userAssigmentList field has a non-nullable assignmentStatus field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + em.remove(assignmentStatus); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findAssignmentStatusEntities() { + return findAssignmentStatusEntities(true, -1, -1); + } + + public List findAssignmentStatusEntities(int maxResults, int firstResult) { + return findAssignmentStatusEntities(false, maxResults, firstResult); + } + + private List findAssignmentStatusEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(AssignmentStatus.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public AssignmentStatus findAssignmentStatus(Integer id) { + EntityManager em = getEntityManager(); + try { + return em.find(AssignmentStatus.class, id); + } + finally { + em.close(); + } + } + + public int getAssignmentStatusCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(AssignmentStatus.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/AttachmentJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/AttachmentJpaController.java index ff5bc8d6..db0b078a 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/AttachmentJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/AttachmentJpaController.java @@ -13,251 +13,251 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import com.validation.manager.core.db.Attachment; -import com.validation.manager.core.db.AttachmentPK; -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.AttachmentType; -import com.validation.manager.core.db.ExecutionStepHasAttachment; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import com.validation.manager.core.db.controller.exceptions.PreexistingEntityException; -import java.util.ArrayList; -import java.util.List; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class AttachmentJpaController implements Serializable { - - public AttachmentJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(Attachment attachment) throws PreexistingEntityException, Exception { - if (attachment.getAttachmentPK() == null) { - attachment.setAttachmentPK(new AttachmentPK()); - } - if (attachment.getExecutionStepHasAttachmentList() == null) { - attachment.setExecutionStepHasAttachmentList(new ArrayList()); - } - attachment.getAttachmentPK().setAttachmentTypeId(attachment.getAttachmentType().getId()); - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - AttachmentType attachmentType = attachment.getAttachmentType(); - if (attachmentType != null) { - attachmentType = em.getReference(attachmentType.getClass(), attachmentType.getId()); - attachment.setAttachmentType(attachmentType); - } - List attachedExecutionStepHasAttachmentList = new ArrayList(); - for (ExecutionStepHasAttachment executionStepHasAttachmentListExecutionStepHasAttachmentToAttach : attachment.getExecutionStepHasAttachmentList()) { - executionStepHasAttachmentListExecutionStepHasAttachmentToAttach = em.getReference(executionStepHasAttachmentListExecutionStepHasAttachmentToAttach.getClass(), executionStepHasAttachmentListExecutionStepHasAttachmentToAttach.getExecutionStepHasAttachmentPK()); - attachedExecutionStepHasAttachmentList.add(executionStepHasAttachmentListExecutionStepHasAttachmentToAttach); - } - attachment.setExecutionStepHasAttachmentList(attachedExecutionStepHasAttachmentList); - em.persist(attachment); - if (attachmentType != null) { - attachmentType.getAttachmentList().add(attachment); - attachmentType = em.merge(attachmentType); - } - for (ExecutionStepHasAttachment executionStepHasAttachmentListExecutionStepHasAttachment : attachment.getExecutionStepHasAttachmentList()) { - Attachment oldAttachmentOfExecutionStepHasAttachmentListExecutionStepHasAttachment = executionStepHasAttachmentListExecutionStepHasAttachment.getAttachment(); - executionStepHasAttachmentListExecutionStepHasAttachment.setAttachment(attachment); - executionStepHasAttachmentListExecutionStepHasAttachment = em.merge(executionStepHasAttachmentListExecutionStepHasAttachment); - if (oldAttachmentOfExecutionStepHasAttachmentListExecutionStepHasAttachment != null) { - oldAttachmentOfExecutionStepHasAttachmentListExecutionStepHasAttachment.getExecutionStepHasAttachmentList().remove(executionStepHasAttachmentListExecutionStepHasAttachment); - oldAttachmentOfExecutionStepHasAttachmentListExecutionStepHasAttachment = em.merge(oldAttachmentOfExecutionStepHasAttachmentListExecutionStepHasAttachment); - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - if (findAttachment(attachment.getAttachmentPK()) != null) { - throw new PreexistingEntityException("Attachment " + attachment + " already exists.", ex); - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(Attachment attachment) throws IllegalOrphanException, NonexistentEntityException, Exception { - attachment.getAttachmentPK().setAttachmentTypeId(attachment.getAttachmentType().getId()); - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - Attachment persistentAttachment = em.find(Attachment.class, attachment.getAttachmentPK()); - AttachmentType attachmentTypeOld = persistentAttachment.getAttachmentType(); - AttachmentType attachmentTypeNew = attachment.getAttachmentType(); - List executionStepHasAttachmentListOld = persistentAttachment.getExecutionStepHasAttachmentList(); - List executionStepHasAttachmentListNew = attachment.getExecutionStepHasAttachmentList(); - List illegalOrphanMessages = null; - for (ExecutionStepHasAttachment executionStepHasAttachmentListOldExecutionStepHasAttachment : executionStepHasAttachmentListOld) { - if (!executionStepHasAttachmentListNew.contains(executionStepHasAttachmentListOldExecutionStepHasAttachment)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain ExecutionStepHasAttachment " + executionStepHasAttachmentListOldExecutionStepHasAttachment + " since its attachment field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - if (attachmentTypeNew != null) { - attachmentTypeNew = em.getReference(attachmentTypeNew.getClass(), attachmentTypeNew.getId()); - attachment.setAttachmentType(attachmentTypeNew); - } - List attachedExecutionStepHasAttachmentListNew = new ArrayList(); - for (ExecutionStepHasAttachment executionStepHasAttachmentListNewExecutionStepHasAttachmentToAttach : executionStepHasAttachmentListNew) { - executionStepHasAttachmentListNewExecutionStepHasAttachmentToAttach = em.getReference(executionStepHasAttachmentListNewExecutionStepHasAttachmentToAttach.getClass(), executionStepHasAttachmentListNewExecutionStepHasAttachmentToAttach.getExecutionStepHasAttachmentPK()); - attachedExecutionStepHasAttachmentListNew.add(executionStepHasAttachmentListNewExecutionStepHasAttachmentToAttach); - } - executionStepHasAttachmentListNew = attachedExecutionStepHasAttachmentListNew; - attachment.setExecutionStepHasAttachmentList(executionStepHasAttachmentListNew); - attachment = em.merge(attachment); - if (attachmentTypeOld != null && !attachmentTypeOld.equals(attachmentTypeNew)) { - attachmentTypeOld.getAttachmentList().remove(attachment); - attachmentTypeOld = em.merge(attachmentTypeOld); - } - if (attachmentTypeNew != null && !attachmentTypeNew.equals(attachmentTypeOld)) { - attachmentTypeNew.getAttachmentList().add(attachment); - attachmentTypeNew = em.merge(attachmentTypeNew); - } - for (ExecutionStepHasAttachment executionStepHasAttachmentListNewExecutionStepHasAttachment : executionStepHasAttachmentListNew) { - if (!executionStepHasAttachmentListOld.contains(executionStepHasAttachmentListNewExecutionStepHasAttachment)) { - Attachment oldAttachmentOfExecutionStepHasAttachmentListNewExecutionStepHasAttachment = executionStepHasAttachmentListNewExecutionStepHasAttachment.getAttachment(); - executionStepHasAttachmentListNewExecutionStepHasAttachment.setAttachment(attachment); - executionStepHasAttachmentListNewExecutionStepHasAttachment = em.merge(executionStepHasAttachmentListNewExecutionStepHasAttachment); - if (oldAttachmentOfExecutionStepHasAttachmentListNewExecutionStepHasAttachment != null && !oldAttachmentOfExecutionStepHasAttachmentListNewExecutionStepHasAttachment.equals(attachment)) { - oldAttachmentOfExecutionStepHasAttachmentListNewExecutionStepHasAttachment.getExecutionStepHasAttachmentList().remove(executionStepHasAttachmentListNewExecutionStepHasAttachment); - oldAttachmentOfExecutionStepHasAttachmentListNewExecutionStepHasAttachment = em.merge(oldAttachmentOfExecutionStepHasAttachmentListNewExecutionStepHasAttachment); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - AttachmentPK id = attachment.getAttachmentPK(); - if (findAttachment(id) == null) { - throw new NonexistentEntityException("The attachment with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(AttachmentPK id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - Attachment attachment; - try { - attachment = em.getReference(Attachment.class, id); - attachment.getAttachmentPK(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The attachment with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List executionStepHasAttachmentListOrphanCheck = attachment.getExecutionStepHasAttachmentList(); - for (ExecutionStepHasAttachment executionStepHasAttachmentListOrphanCheckExecutionStepHasAttachment : executionStepHasAttachmentListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This Attachment (" + attachment + ") cannot be destroyed since the ExecutionStepHasAttachment " + executionStepHasAttachmentListOrphanCheckExecutionStepHasAttachment + " in its executionStepHasAttachmentList field has a non-nullable attachment field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - AttachmentType attachmentType = attachment.getAttachmentType(); - if (attachmentType != null) { - attachmentType.getAttachmentList().remove(attachment); - attachmentType = em.merge(attachmentType); - } - em.remove(attachment); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findAttachmentEntities() { - return findAttachmentEntities(true, -1, -1); - } - - public List findAttachmentEntities(int maxResults, int firstResult) { - return findAttachmentEntities(false, maxResults, firstResult); - } - - private List findAttachmentEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(Attachment.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public Attachment findAttachment(AttachmentPK id) { - EntityManager em = getEntityManager(); - try { - return em.find(Attachment.class, id); - } - finally { - em.close(); - } - } - - public int getAttachmentCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(Attachment.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import com.validation.manager.core.db.Attachment; +import com.validation.manager.core.db.AttachmentPK; +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.AttachmentType; +import com.validation.manager.core.db.ExecutionStepHasAttachment; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import com.validation.manager.core.db.controller.exceptions.PreexistingEntityException; +import java.util.ArrayList; +import java.util.List; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class AttachmentJpaController implements Serializable { + + public AttachmentJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(Attachment attachment) throws PreexistingEntityException, Exception { + if (attachment.getAttachmentPK() == null) { + attachment.setAttachmentPK(new AttachmentPK()); + } + if (attachment.getExecutionStepHasAttachmentList() == null) { + attachment.setExecutionStepHasAttachmentList(new ArrayList<>()); + } + attachment.getAttachmentPK().setAttachmentTypeId(attachment.getAttachmentType().getId()); + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + AttachmentType attachmentType = attachment.getAttachmentType(); + if (attachmentType != null) { + attachmentType = em.getReference(attachmentType.getClass(), attachmentType.getId()); + attachment.setAttachmentType(attachmentType); + } + List attachedExecutionStepHasAttachmentList = new ArrayList<>(); + for (ExecutionStepHasAttachment executionStepHasAttachmentListExecutionStepHasAttachmentToAttach : attachment.getExecutionStepHasAttachmentList()) { + executionStepHasAttachmentListExecutionStepHasAttachmentToAttach = em.getReference(executionStepHasAttachmentListExecutionStepHasAttachmentToAttach.getClass(), executionStepHasAttachmentListExecutionStepHasAttachmentToAttach.getExecutionStepHasAttachmentPK()); + attachedExecutionStepHasAttachmentList.add(executionStepHasAttachmentListExecutionStepHasAttachmentToAttach); + } + attachment.setExecutionStepHasAttachmentList(attachedExecutionStepHasAttachmentList); + em.persist(attachment); + if (attachmentType != null) { + attachmentType.getAttachmentList().add(attachment); + attachmentType = em.merge(attachmentType); + } + for (ExecutionStepHasAttachment executionStepHasAttachmentListExecutionStepHasAttachment : attachment.getExecutionStepHasAttachmentList()) { + Attachment oldAttachmentOfExecutionStepHasAttachmentListExecutionStepHasAttachment = executionStepHasAttachmentListExecutionStepHasAttachment.getAttachment(); + executionStepHasAttachmentListExecutionStepHasAttachment.setAttachment(attachment); + executionStepHasAttachmentListExecutionStepHasAttachment = em.merge(executionStepHasAttachmentListExecutionStepHasAttachment); + if (oldAttachmentOfExecutionStepHasAttachmentListExecutionStepHasAttachment != null) { + oldAttachmentOfExecutionStepHasAttachmentListExecutionStepHasAttachment.getExecutionStepHasAttachmentList().remove(executionStepHasAttachmentListExecutionStepHasAttachment); + oldAttachmentOfExecutionStepHasAttachmentListExecutionStepHasAttachment = em.merge(oldAttachmentOfExecutionStepHasAttachmentListExecutionStepHasAttachment); + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + if (findAttachment(attachment.getAttachmentPK()) != null) { + throw new PreexistingEntityException("Attachment " + attachment + " already exists.", ex); + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(Attachment attachment) throws IllegalOrphanException, NonexistentEntityException, Exception { + attachment.getAttachmentPK().setAttachmentTypeId(attachment.getAttachmentType().getId()); + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + Attachment persistentAttachment = em.find(Attachment.class, attachment.getAttachmentPK()); + AttachmentType attachmentTypeOld = persistentAttachment.getAttachmentType(); + AttachmentType attachmentTypeNew = attachment.getAttachmentType(); + List executionStepHasAttachmentListOld = persistentAttachment.getExecutionStepHasAttachmentList(); + List executionStepHasAttachmentListNew = attachment.getExecutionStepHasAttachmentList(); + List illegalOrphanMessages = null; + for (ExecutionStepHasAttachment executionStepHasAttachmentListOldExecutionStepHasAttachment : executionStepHasAttachmentListOld) { + if (!executionStepHasAttachmentListNew.contains(executionStepHasAttachmentListOldExecutionStepHasAttachment)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain ExecutionStepHasAttachment " + executionStepHasAttachmentListOldExecutionStepHasAttachment + " since its attachment field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + if (attachmentTypeNew != null) { + attachmentTypeNew = em.getReference(attachmentTypeNew.getClass(), attachmentTypeNew.getId()); + attachment.setAttachmentType(attachmentTypeNew); + } + List attachedExecutionStepHasAttachmentListNew = new ArrayList<>(); + for (ExecutionStepHasAttachment executionStepHasAttachmentListNewExecutionStepHasAttachmentToAttach : executionStepHasAttachmentListNew) { + executionStepHasAttachmentListNewExecutionStepHasAttachmentToAttach = em.getReference(executionStepHasAttachmentListNewExecutionStepHasAttachmentToAttach.getClass(), executionStepHasAttachmentListNewExecutionStepHasAttachmentToAttach.getExecutionStepHasAttachmentPK()); + attachedExecutionStepHasAttachmentListNew.add(executionStepHasAttachmentListNewExecutionStepHasAttachmentToAttach); + } + executionStepHasAttachmentListNew = attachedExecutionStepHasAttachmentListNew; + attachment.setExecutionStepHasAttachmentList(executionStepHasAttachmentListNew); + attachment = em.merge(attachment); + if (attachmentTypeOld != null && !attachmentTypeOld.equals(attachmentTypeNew)) { + attachmentTypeOld.getAttachmentList().remove(attachment); + attachmentTypeOld = em.merge(attachmentTypeOld); + } + if (attachmentTypeNew != null && !attachmentTypeNew.equals(attachmentTypeOld)) { + attachmentTypeNew.getAttachmentList().add(attachment); + attachmentTypeNew = em.merge(attachmentTypeNew); + } + for (ExecutionStepHasAttachment executionStepHasAttachmentListNewExecutionStepHasAttachment : executionStepHasAttachmentListNew) { + if (!executionStepHasAttachmentListOld.contains(executionStepHasAttachmentListNewExecutionStepHasAttachment)) { + Attachment oldAttachmentOfExecutionStepHasAttachmentListNewExecutionStepHasAttachment = executionStepHasAttachmentListNewExecutionStepHasAttachment.getAttachment(); + executionStepHasAttachmentListNewExecutionStepHasAttachment.setAttachment(attachment); + executionStepHasAttachmentListNewExecutionStepHasAttachment = em.merge(executionStepHasAttachmentListNewExecutionStepHasAttachment); + if (oldAttachmentOfExecutionStepHasAttachmentListNewExecutionStepHasAttachment != null && !oldAttachmentOfExecutionStepHasAttachmentListNewExecutionStepHasAttachment.equals(attachment)) { + oldAttachmentOfExecutionStepHasAttachmentListNewExecutionStepHasAttachment.getExecutionStepHasAttachmentList().remove(executionStepHasAttachmentListNewExecutionStepHasAttachment); + oldAttachmentOfExecutionStepHasAttachmentListNewExecutionStepHasAttachment = em.merge(oldAttachmentOfExecutionStepHasAttachmentListNewExecutionStepHasAttachment); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + AttachmentPK id = attachment.getAttachmentPK(); + if (findAttachment(id) == null) { + throw new NonexistentEntityException("The attachment with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(AttachmentPK id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + Attachment attachment; + try { + attachment = em.getReference(Attachment.class, id); + attachment.getAttachmentPK(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The attachment with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List executionStepHasAttachmentListOrphanCheck = attachment.getExecutionStepHasAttachmentList(); + for (ExecutionStepHasAttachment executionStepHasAttachmentListOrphanCheckExecutionStepHasAttachment : executionStepHasAttachmentListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This Attachment (" + attachment + ") cannot be destroyed since the ExecutionStepHasAttachment " + executionStepHasAttachmentListOrphanCheckExecutionStepHasAttachment + " in its executionStepHasAttachmentList field has a non-nullable attachment field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + AttachmentType attachmentType = attachment.getAttachmentType(); + if (attachmentType != null) { + attachmentType.getAttachmentList().remove(attachment); + attachmentType = em.merge(attachmentType); + } + em.remove(attachment); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findAttachmentEntities() { + return findAttachmentEntities(true, -1, -1); + } + + public List findAttachmentEntities(int maxResults, int firstResult) { + return findAttachmentEntities(false, maxResults, firstResult); + } + + private List findAttachmentEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(Attachment.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public Attachment findAttachment(AttachmentPK id) { + EntityManager em = getEntityManager(); + try { + return em.find(Attachment.class, id); + } + finally { + em.close(); + } + } + + public int getAttachmentCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(Attachment.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/AttachmentTypeJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/AttachmentTypeJpaController.java index dc21299b..bed6c230 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/AttachmentTypeJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/AttachmentTypeJpaController.java @@ -13,216 +13,216 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.Attachment; -import com.validation.manager.core.db.AttachmentType; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import com.validation.manager.core.db.controller.exceptions.PreexistingEntityException; -import java.util.ArrayList; -import java.util.List; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class AttachmentTypeJpaController implements Serializable { - - public AttachmentTypeJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(AttachmentType attachmentType) throws PreexistingEntityException, Exception { - if (attachmentType.getAttachmentList() == null) { - attachmentType.setAttachmentList(new ArrayList()); - } - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - List attachedAttachmentList = new ArrayList(); - for (Attachment attachmentListAttachmentToAttach : attachmentType.getAttachmentList()) { - attachmentListAttachmentToAttach = em.getReference(attachmentListAttachmentToAttach.getClass(), attachmentListAttachmentToAttach.getAttachmentPK()); - attachedAttachmentList.add(attachmentListAttachmentToAttach); - } - attachmentType.setAttachmentList(attachedAttachmentList); - em.persist(attachmentType); - for (Attachment attachmentListAttachment : attachmentType.getAttachmentList()) { - AttachmentType oldAttachmentTypeOfAttachmentListAttachment = attachmentListAttachment.getAttachmentType(); - attachmentListAttachment.setAttachmentType(attachmentType); - attachmentListAttachment = em.merge(attachmentListAttachment); - if (oldAttachmentTypeOfAttachmentListAttachment != null) { - oldAttachmentTypeOfAttachmentListAttachment.getAttachmentList().remove(attachmentListAttachment); - oldAttachmentTypeOfAttachmentListAttachment = em.merge(oldAttachmentTypeOfAttachmentListAttachment); - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - if (findAttachmentType(attachmentType.getId()) != null) { - throw new PreexistingEntityException("AttachmentType " + attachmentType + " already exists.", ex); - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(AttachmentType attachmentType) throws IllegalOrphanException, NonexistentEntityException, Exception { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - AttachmentType persistentAttachmentType = em.find(AttachmentType.class, attachmentType.getId()); - List attachmentListOld = persistentAttachmentType.getAttachmentList(); - List attachmentListNew = attachmentType.getAttachmentList(); - List illegalOrphanMessages = null; - for (Attachment attachmentListOldAttachment : attachmentListOld) { - if (!attachmentListNew.contains(attachmentListOldAttachment)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain Attachment " + attachmentListOldAttachment + " since its attachmentType field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - List attachedAttachmentListNew = new ArrayList(); - for (Attachment attachmentListNewAttachmentToAttach : attachmentListNew) { - attachmentListNewAttachmentToAttach = em.getReference(attachmentListNewAttachmentToAttach.getClass(), attachmentListNewAttachmentToAttach.getAttachmentPK()); - attachedAttachmentListNew.add(attachmentListNewAttachmentToAttach); - } - attachmentListNew = attachedAttachmentListNew; - attachmentType.setAttachmentList(attachmentListNew); - attachmentType = em.merge(attachmentType); - for (Attachment attachmentListNewAttachment : attachmentListNew) { - if (!attachmentListOld.contains(attachmentListNewAttachment)) { - AttachmentType oldAttachmentTypeOfAttachmentListNewAttachment = attachmentListNewAttachment.getAttachmentType(); - attachmentListNewAttachment.setAttachmentType(attachmentType); - attachmentListNewAttachment = em.merge(attachmentListNewAttachment); - if (oldAttachmentTypeOfAttachmentListNewAttachment != null && !oldAttachmentTypeOfAttachmentListNewAttachment.equals(attachmentType)) { - oldAttachmentTypeOfAttachmentListNewAttachment.getAttachmentList().remove(attachmentListNewAttachment); - oldAttachmentTypeOfAttachmentListNewAttachment = em.merge(oldAttachmentTypeOfAttachmentListNewAttachment); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - Integer id = attachmentType.getId(); - if (findAttachmentType(id) == null) { - throw new NonexistentEntityException("The attachmentType with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - AttachmentType attachmentType; - try { - attachmentType = em.getReference(AttachmentType.class, id); - attachmentType.getId(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The attachmentType with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List attachmentListOrphanCheck = attachmentType.getAttachmentList(); - for (Attachment attachmentListOrphanCheckAttachment : attachmentListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This AttachmentType (" + attachmentType + ") cannot be destroyed since the Attachment " + attachmentListOrphanCheckAttachment + " in its attachmentList field has a non-nullable attachmentType field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - em.remove(attachmentType); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findAttachmentTypeEntities() { - return findAttachmentTypeEntities(true, -1, -1); - } - - public List findAttachmentTypeEntities(int maxResults, int firstResult) { - return findAttachmentTypeEntities(false, maxResults, firstResult); - } - - private List findAttachmentTypeEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(AttachmentType.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public AttachmentType findAttachmentType(Integer id) { - EntityManager em = getEntityManager(); - try { - return em.find(AttachmentType.class, id); - } - finally { - em.close(); - } - } - - public int getAttachmentTypeCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(AttachmentType.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.Attachment; +import com.validation.manager.core.db.AttachmentType; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import com.validation.manager.core.db.controller.exceptions.PreexistingEntityException; +import java.util.ArrayList; +import java.util.List; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class AttachmentTypeJpaController implements Serializable { + + public AttachmentTypeJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(AttachmentType attachmentType) throws PreexistingEntityException, Exception { + if (attachmentType.getAttachmentList() == null) { + attachmentType.setAttachmentList(new ArrayList<>()); + } + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + List attachedAttachmentList = new ArrayList<>(); + for (Attachment attachmentListAttachmentToAttach : attachmentType.getAttachmentList()) { + attachmentListAttachmentToAttach = em.getReference(attachmentListAttachmentToAttach.getClass(), attachmentListAttachmentToAttach.getAttachmentPK()); + attachedAttachmentList.add(attachmentListAttachmentToAttach); + } + attachmentType.setAttachmentList(attachedAttachmentList); + em.persist(attachmentType); + for (Attachment attachmentListAttachment : attachmentType.getAttachmentList()) { + AttachmentType oldAttachmentTypeOfAttachmentListAttachment = attachmentListAttachment.getAttachmentType(); + attachmentListAttachment.setAttachmentType(attachmentType); + attachmentListAttachment = em.merge(attachmentListAttachment); + if (oldAttachmentTypeOfAttachmentListAttachment != null) { + oldAttachmentTypeOfAttachmentListAttachment.getAttachmentList().remove(attachmentListAttachment); + oldAttachmentTypeOfAttachmentListAttachment = em.merge(oldAttachmentTypeOfAttachmentListAttachment); + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + if (findAttachmentType(attachmentType.getId()) != null) { + throw new PreexistingEntityException("AttachmentType " + attachmentType + " already exists.", ex); + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(AttachmentType attachmentType) throws IllegalOrphanException, NonexistentEntityException, Exception { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + AttachmentType persistentAttachmentType = em.find(AttachmentType.class, attachmentType.getId()); + List attachmentListOld = persistentAttachmentType.getAttachmentList(); + List attachmentListNew = attachmentType.getAttachmentList(); + List illegalOrphanMessages = null; + for (Attachment attachmentListOldAttachment : attachmentListOld) { + if (!attachmentListNew.contains(attachmentListOldAttachment)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain Attachment " + attachmentListOldAttachment + " since its attachmentType field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + List attachedAttachmentListNew = new ArrayList<>(); + for (Attachment attachmentListNewAttachmentToAttach : attachmentListNew) { + attachmentListNewAttachmentToAttach = em.getReference(attachmentListNewAttachmentToAttach.getClass(), attachmentListNewAttachmentToAttach.getAttachmentPK()); + attachedAttachmentListNew.add(attachmentListNewAttachmentToAttach); + } + attachmentListNew = attachedAttachmentListNew; + attachmentType.setAttachmentList(attachmentListNew); + attachmentType = em.merge(attachmentType); + for (Attachment attachmentListNewAttachment : attachmentListNew) { + if (!attachmentListOld.contains(attachmentListNewAttachment)) { + AttachmentType oldAttachmentTypeOfAttachmentListNewAttachment = attachmentListNewAttachment.getAttachmentType(); + attachmentListNewAttachment.setAttachmentType(attachmentType); + attachmentListNewAttachment = em.merge(attachmentListNewAttachment); + if (oldAttachmentTypeOfAttachmentListNewAttachment != null && !oldAttachmentTypeOfAttachmentListNewAttachment.equals(attachmentType)) { + oldAttachmentTypeOfAttachmentListNewAttachment.getAttachmentList().remove(attachmentListNewAttachment); + oldAttachmentTypeOfAttachmentListNewAttachment = em.merge(oldAttachmentTypeOfAttachmentListNewAttachment); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + Integer id = attachmentType.getId(); + if (findAttachmentType(id) == null) { + throw new NonexistentEntityException("The attachmentType with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + AttachmentType attachmentType; + try { + attachmentType = em.getReference(AttachmentType.class, id); + attachmentType.getId(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The attachmentType with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List attachmentListOrphanCheck = attachmentType.getAttachmentList(); + for (Attachment attachmentListOrphanCheckAttachment : attachmentListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This AttachmentType (" + attachmentType + ") cannot be destroyed since the Attachment " + attachmentListOrphanCheckAttachment + " in its attachmentList field has a non-nullable attachmentType field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + em.remove(attachmentType); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findAttachmentTypeEntities() { + return findAttachmentTypeEntities(true, -1, -1); + } + + public List findAttachmentTypeEntities(int maxResults, int firstResult) { + return findAttachmentTypeEntities(false, maxResults, firstResult); + } + + private List findAttachmentTypeEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(AttachmentType.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public AttachmentType findAttachmentType(Integer id) { + EntityManager em = getEntityManager(); + try { + return em.find(AttachmentType.class, id); + } + finally { + em.close(); + } + } + + public int getAttachmentTypeCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(AttachmentType.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/BaselineJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/BaselineJpaController.java index b0be06f0..00adada8 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/BaselineJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/BaselineJpaController.java @@ -13,215 +13,215 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import com.validation.manager.core.db.Baseline; -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.RequirementSpec; -import com.validation.manager.core.db.History; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import java.util.ArrayList; -import java.util.List; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class BaselineJpaController implements Serializable { - - public BaselineJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(Baseline baseline) { - if (baseline.getHistoryList() == null) { - baseline.setHistoryList(new ArrayList()); - } - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - RequirementSpec requirementSpec = baseline.getRequirementSpec(); - if (requirementSpec != null) { - requirementSpec = em.getReference(requirementSpec.getClass(), requirementSpec.getRequirementSpecPK()); - baseline.setRequirementSpec(requirementSpec); - } - List attachedHistoryList = new ArrayList(); - for (History historyListHistoryToAttach : baseline.getHistoryList()) { - historyListHistoryToAttach = em.getReference(historyListHistoryToAttach.getClass(), historyListHistoryToAttach.getId()); - attachedHistoryList.add(historyListHistoryToAttach); - } - baseline.setHistoryList(attachedHistoryList); - em.persist(baseline); - if (requirementSpec != null) { - requirementSpec.getBaselineList().add(baseline); - requirementSpec = em.merge(requirementSpec); - } - for (History historyListHistory : baseline.getHistoryList()) { - historyListHistory.getBaselineList().add(baseline); - historyListHistory = em.merge(historyListHistory); - } - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(Baseline baseline) throws NonexistentEntityException, Exception { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - Baseline persistentBaseline = em.find(Baseline.class, baseline.getId()); - RequirementSpec requirementSpecOld = persistentBaseline.getRequirementSpec(); - RequirementSpec requirementSpecNew = baseline.getRequirementSpec(); - List historyListOld = persistentBaseline.getHistoryList(); - List historyListNew = baseline.getHistoryList(); - if (requirementSpecNew != null) { - requirementSpecNew = em.getReference(requirementSpecNew.getClass(), requirementSpecNew.getRequirementSpecPK()); - baseline.setRequirementSpec(requirementSpecNew); - } - List attachedHistoryListNew = new ArrayList(); - for (History historyListNewHistoryToAttach : historyListNew) { - historyListNewHistoryToAttach = em.getReference(historyListNewHistoryToAttach.getClass(), historyListNewHistoryToAttach.getId()); - attachedHistoryListNew.add(historyListNewHistoryToAttach); - } - historyListNew = attachedHistoryListNew; - baseline.setHistoryList(historyListNew); - baseline = em.merge(baseline); - if (requirementSpecOld != null && !requirementSpecOld.equals(requirementSpecNew)) { - requirementSpecOld.getBaselineList().remove(baseline); - requirementSpecOld = em.merge(requirementSpecOld); - } - if (requirementSpecNew != null && !requirementSpecNew.equals(requirementSpecOld)) { - requirementSpecNew.getBaselineList().add(baseline); - requirementSpecNew = em.merge(requirementSpecNew); - } - for (History historyListOldHistory : historyListOld) { - if (!historyListNew.contains(historyListOldHistory)) { - historyListOldHistory.getBaselineList().remove(baseline); - historyListOldHistory = em.merge(historyListOldHistory); - } - } - for (History historyListNewHistory : historyListNew) { - if (!historyListOld.contains(historyListNewHistory)) { - historyListNewHistory.getBaselineList().add(baseline); - historyListNewHistory = em.merge(historyListNewHistory); - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - Integer id = baseline.getId(); - if (findBaseline(id) == null) { - throw new NonexistentEntityException("The baseline with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(Integer id) throws NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - Baseline baseline; - try { - baseline = em.getReference(Baseline.class, id); - baseline.getId(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The baseline with id " + id + " no longer exists.", enfe); - } - RequirementSpec requirementSpec = baseline.getRequirementSpec(); - if (requirementSpec != null) { - requirementSpec.getBaselineList().remove(baseline); - requirementSpec = em.merge(requirementSpec); - } - List historyList = baseline.getHistoryList(); - for (History historyListHistory : historyList) { - historyListHistory.getBaselineList().remove(baseline); - historyListHistory = em.merge(historyListHistory); - } - em.remove(baseline); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findBaselineEntities() { - return findBaselineEntities(true, -1, -1); - } - - public List findBaselineEntities(int maxResults, int firstResult) { - return findBaselineEntities(false, maxResults, firstResult); - } - - private List findBaselineEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(Baseline.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public Baseline findBaseline(Integer id) { - EntityManager em = getEntityManager(); - try { - return em.find(Baseline.class, id); - } - finally { - em.close(); - } - } - - public int getBaselineCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(Baseline.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import com.validation.manager.core.db.Baseline; +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.RequirementSpec; +import com.validation.manager.core.db.History; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import java.util.ArrayList; +import java.util.List; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class BaselineJpaController implements Serializable { + + public BaselineJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(Baseline baseline) { + if (baseline.getHistoryList() == null) { + baseline.setHistoryList(new ArrayList<>()); + } + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + RequirementSpec requirementSpec = baseline.getRequirementSpec(); + if (requirementSpec != null) { + requirementSpec = em.getReference(requirementSpec.getClass(), requirementSpec.getRequirementSpecPK()); + baseline.setRequirementSpec(requirementSpec); + } + List attachedHistoryList = new ArrayList<>(); + for (History historyListHistoryToAttach : baseline.getHistoryList()) { + historyListHistoryToAttach = em.getReference(historyListHistoryToAttach.getClass(), historyListHistoryToAttach.getId()); + attachedHistoryList.add(historyListHistoryToAttach); + } + baseline.setHistoryList(attachedHistoryList); + em.persist(baseline); + if (requirementSpec != null) { + requirementSpec.getBaselineList().add(baseline); + requirementSpec = em.merge(requirementSpec); + } + for (History historyListHistory : baseline.getHistoryList()) { + historyListHistory.getBaselineList().add(baseline); + historyListHistory = em.merge(historyListHistory); + } + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(Baseline baseline) throws NonexistentEntityException, Exception { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + Baseline persistentBaseline = em.find(Baseline.class, baseline.getId()); + RequirementSpec requirementSpecOld = persistentBaseline.getRequirementSpec(); + RequirementSpec requirementSpecNew = baseline.getRequirementSpec(); + List historyListOld = persistentBaseline.getHistoryList(); + List historyListNew = baseline.getHistoryList(); + if (requirementSpecNew != null) { + requirementSpecNew = em.getReference(requirementSpecNew.getClass(), requirementSpecNew.getRequirementSpecPK()); + baseline.setRequirementSpec(requirementSpecNew); + } + List attachedHistoryListNew = new ArrayList<>(); + for (History historyListNewHistoryToAttach : historyListNew) { + historyListNewHistoryToAttach = em.getReference(historyListNewHistoryToAttach.getClass(), historyListNewHistoryToAttach.getId()); + attachedHistoryListNew.add(historyListNewHistoryToAttach); + } + historyListNew = attachedHistoryListNew; + baseline.setHistoryList(historyListNew); + baseline = em.merge(baseline); + if (requirementSpecOld != null && !requirementSpecOld.equals(requirementSpecNew)) { + requirementSpecOld.getBaselineList().remove(baseline); + requirementSpecOld = em.merge(requirementSpecOld); + } + if (requirementSpecNew != null && !requirementSpecNew.equals(requirementSpecOld)) { + requirementSpecNew.getBaselineList().add(baseline); + requirementSpecNew = em.merge(requirementSpecNew); + } + for (History historyListOldHistory : historyListOld) { + if (!historyListNew.contains(historyListOldHistory)) { + historyListOldHistory.getBaselineList().remove(baseline); + historyListOldHistory = em.merge(historyListOldHistory); + } + } + for (History historyListNewHistory : historyListNew) { + if (!historyListOld.contains(historyListNewHistory)) { + historyListNewHistory.getBaselineList().add(baseline); + historyListNewHistory = em.merge(historyListNewHistory); + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + Integer id = baseline.getId(); + if (findBaseline(id) == null) { + throw new NonexistentEntityException("The baseline with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(Integer id) throws NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + Baseline baseline; + try { + baseline = em.getReference(Baseline.class, id); + baseline.getId(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The baseline with id " + id + " no longer exists.", enfe); + } + RequirementSpec requirementSpec = baseline.getRequirementSpec(); + if (requirementSpec != null) { + requirementSpec.getBaselineList().remove(baseline); + requirementSpec = em.merge(requirementSpec); + } + List historyList = baseline.getHistoryList(); + for (History historyListHistory : historyList) { + historyListHistory.getBaselineList().remove(baseline); + historyListHistory = em.merge(historyListHistory); + } + em.remove(baseline); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findBaselineEntities() { + return findBaselineEntities(true, -1, -1); + } + + public List findBaselineEntities(int maxResults, int firstResult) { + return findBaselineEntities(false, maxResults, firstResult); + } + + private List findBaselineEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(Baseline.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public Baseline findBaseline(Integer id) { + EntityManager em = getEntityManager(); + try { + return em.find(Baseline.class, id); + } + finally { + em.close(); + } + } + + public int getBaselineCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(Baseline.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/CauseJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/CauseJpaController.java index 1ed661c0..fd88059d 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/CauseJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/CauseJpaController.java @@ -13,186 +13,186 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import com.validation.manager.core.db.Cause; -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.RiskItem; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import java.util.ArrayList; -import java.util.List; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class CauseJpaController implements Serializable { - - public CauseJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(Cause cause) { - if (cause.getRiskItemList() == null) { - cause.setRiskItemList(new ArrayList()); - } - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - List attachedRiskItemList = new ArrayList(); - for (RiskItem riskItemListRiskItemToAttach : cause.getRiskItemList()) { - riskItemListRiskItemToAttach = em.getReference(riskItemListRiskItemToAttach.getClass(), riskItemListRiskItemToAttach.getRiskItemPK()); - attachedRiskItemList.add(riskItemListRiskItemToAttach); - } - cause.setRiskItemList(attachedRiskItemList); - em.persist(cause); - for (RiskItem riskItemListRiskItem : cause.getRiskItemList()) { - riskItemListRiskItem.getCauseList().add(cause); - riskItemListRiskItem = em.merge(riskItemListRiskItem); - } - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(Cause cause) throws NonexistentEntityException, Exception { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - Cause persistentCause = em.find(Cause.class, cause.getId()); - List riskItemListOld = persistentCause.getRiskItemList(); - List riskItemListNew = cause.getRiskItemList(); - List attachedRiskItemListNew = new ArrayList(); - for (RiskItem riskItemListNewRiskItemToAttach : riskItemListNew) { - riskItemListNewRiskItemToAttach = em.getReference(riskItemListNewRiskItemToAttach.getClass(), riskItemListNewRiskItemToAttach.getRiskItemPK()); - attachedRiskItemListNew.add(riskItemListNewRiskItemToAttach); - } - riskItemListNew = attachedRiskItemListNew; - cause.setRiskItemList(riskItemListNew); - cause = em.merge(cause); - for (RiskItem riskItemListOldRiskItem : riskItemListOld) { - if (!riskItemListNew.contains(riskItemListOldRiskItem)) { - riskItemListOldRiskItem.getCauseList().remove(cause); - riskItemListOldRiskItem = em.merge(riskItemListOldRiskItem); - } - } - for (RiskItem riskItemListNewRiskItem : riskItemListNew) { - if (!riskItemListOld.contains(riskItemListNewRiskItem)) { - riskItemListNewRiskItem.getCauseList().add(cause); - riskItemListNewRiskItem = em.merge(riskItemListNewRiskItem); - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - Integer id = cause.getId(); - if (findCause(id) == null) { - throw new NonexistentEntityException("The cause with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(Integer id) throws NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - Cause cause; - try { - cause = em.getReference(Cause.class, id); - cause.getId(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The cause with id " + id + " no longer exists.", enfe); - } - List riskItemList = cause.getRiskItemList(); - for (RiskItem riskItemListRiskItem : riskItemList) { - riskItemListRiskItem.getCauseList().remove(cause); - riskItemListRiskItem = em.merge(riskItemListRiskItem); - } - em.remove(cause); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findCauseEntities() { - return findCauseEntities(true, -1, -1); - } - - public List findCauseEntities(int maxResults, int firstResult) { - return findCauseEntities(false, maxResults, firstResult); - } - - private List findCauseEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(Cause.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public Cause findCause(Integer id) { - EntityManager em = getEntityManager(); - try { - return em.find(Cause.class, id); - } - finally { - em.close(); - } - } - - public int getCauseCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(Cause.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import com.validation.manager.core.db.Cause; +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.RiskItem; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import java.util.ArrayList; +import java.util.List; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class CauseJpaController implements Serializable { + + public CauseJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(Cause cause) { + if (cause.getRiskItemList() == null) { + cause.setRiskItemList(new ArrayList<>()); + } + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + List attachedRiskItemList = new ArrayList<>(); + for (RiskItem riskItemListRiskItemToAttach : cause.getRiskItemList()) { + riskItemListRiskItemToAttach = em.getReference(riskItemListRiskItemToAttach.getClass(), riskItemListRiskItemToAttach.getRiskItemPK()); + attachedRiskItemList.add(riskItemListRiskItemToAttach); + } + cause.setRiskItemList(attachedRiskItemList); + em.persist(cause); + for (RiskItem riskItemListRiskItem : cause.getRiskItemList()) { + riskItemListRiskItem.getCauseList().add(cause); + riskItemListRiskItem = em.merge(riskItemListRiskItem); + } + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(Cause cause) throws NonexistentEntityException, Exception { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + Cause persistentCause = em.find(Cause.class, cause.getId()); + List riskItemListOld = persistentCause.getRiskItemList(); + List riskItemListNew = cause.getRiskItemList(); + List attachedRiskItemListNew = new ArrayList<>(); + for (RiskItem riskItemListNewRiskItemToAttach : riskItemListNew) { + riskItemListNewRiskItemToAttach = em.getReference(riskItemListNewRiskItemToAttach.getClass(), riskItemListNewRiskItemToAttach.getRiskItemPK()); + attachedRiskItemListNew.add(riskItemListNewRiskItemToAttach); + } + riskItemListNew = attachedRiskItemListNew; + cause.setRiskItemList(riskItemListNew); + cause = em.merge(cause); + for (RiskItem riskItemListOldRiskItem : riskItemListOld) { + if (!riskItemListNew.contains(riskItemListOldRiskItem)) { + riskItemListOldRiskItem.getCauseList().remove(cause); + riskItemListOldRiskItem = em.merge(riskItemListOldRiskItem); + } + } + for (RiskItem riskItemListNewRiskItem : riskItemListNew) { + if (!riskItemListOld.contains(riskItemListNewRiskItem)) { + riskItemListNewRiskItem.getCauseList().add(cause); + riskItemListNewRiskItem = em.merge(riskItemListNewRiskItem); + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + Integer id = cause.getId(); + if (findCause(id) == null) { + throw new NonexistentEntityException("The cause with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(Integer id) throws NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + Cause cause; + try { + cause = em.getReference(Cause.class, id); + cause.getId(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The cause with id " + id + " no longer exists.", enfe); + } + List riskItemList = cause.getRiskItemList(); + for (RiskItem riskItemListRiskItem : riskItemList) { + riskItemListRiskItem.getCauseList().remove(cause); + riskItemListRiskItem = em.merge(riskItemListRiskItem); + } + em.remove(cause); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findCauseEntities() { + return findCauseEntities(true, -1, -1); + } + + public List findCauseEntities(int maxResults, int firstResult) { + return findCauseEntities(false, maxResults, firstResult); + } + + private List findCauseEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(Cause.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public Cause findCause(Integer id) { + EntityManager em = getEntityManager(); + try { + return em.find(Cause.class, id); + } + finally { + em.close(); + } + } + + public int getCauseCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(Cause.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/CorrectiveActionJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/CorrectiveActionJpaController.java index 6e8a30b7..3f22d37b 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/CorrectiveActionJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/CorrectiveActionJpaController.java @@ -13,249 +13,249 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import com.validation.manager.core.db.CorrectiveAction; -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.VmUser; -import java.util.ArrayList; -import java.util.List; -import com.validation.manager.core.db.ExceptionHasCorrectiveAction; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class CorrectiveActionJpaController implements Serializable { - - public CorrectiveActionJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(CorrectiveAction correctiveAction) { - if (correctiveAction.getVmUserList() == null) { - correctiveAction.setVmUserList(new ArrayList()); - } - if (correctiveAction.getExceptionHasCorrectiveActionList() == null) { - correctiveAction.setExceptionHasCorrectiveActionList(new ArrayList()); - } - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - List attachedVmUserList = new ArrayList(); - for (VmUser vmUserListVmUserToAttach : correctiveAction.getVmUserList()) { - vmUserListVmUserToAttach = em.getReference(vmUserListVmUserToAttach.getClass(), vmUserListVmUserToAttach.getId()); - attachedVmUserList.add(vmUserListVmUserToAttach); - } - correctiveAction.setVmUserList(attachedVmUserList); - List attachedExceptionHasCorrectiveActionList = new ArrayList(); - for (ExceptionHasCorrectiveAction exceptionHasCorrectiveActionListExceptionHasCorrectiveActionToAttach : correctiveAction.getExceptionHasCorrectiveActionList()) { - exceptionHasCorrectiveActionListExceptionHasCorrectiveActionToAttach = em.getReference(exceptionHasCorrectiveActionListExceptionHasCorrectiveActionToAttach.getClass(), exceptionHasCorrectiveActionListExceptionHasCorrectiveActionToAttach.getExceptionHasCorrectiveActionPK()); - attachedExceptionHasCorrectiveActionList.add(exceptionHasCorrectiveActionListExceptionHasCorrectiveActionToAttach); - } - correctiveAction.setExceptionHasCorrectiveActionList(attachedExceptionHasCorrectiveActionList); - em.persist(correctiveAction); - for (VmUser vmUserListVmUser : correctiveAction.getVmUserList()) { - vmUserListVmUser.getCorrectiveActionList().add(correctiveAction); - vmUserListVmUser = em.merge(vmUserListVmUser); - } - for (ExceptionHasCorrectiveAction exceptionHasCorrectiveActionListExceptionHasCorrectiveAction : correctiveAction.getExceptionHasCorrectiveActionList()) { - CorrectiveAction oldCorrectiveActionOfExceptionHasCorrectiveActionListExceptionHasCorrectiveAction = exceptionHasCorrectiveActionListExceptionHasCorrectiveAction.getCorrectiveAction(); - exceptionHasCorrectiveActionListExceptionHasCorrectiveAction.setCorrectiveAction(correctiveAction); - exceptionHasCorrectiveActionListExceptionHasCorrectiveAction = em.merge(exceptionHasCorrectiveActionListExceptionHasCorrectiveAction); - if (oldCorrectiveActionOfExceptionHasCorrectiveActionListExceptionHasCorrectiveAction != null) { - oldCorrectiveActionOfExceptionHasCorrectiveActionListExceptionHasCorrectiveAction.getExceptionHasCorrectiveActionList().remove(exceptionHasCorrectiveActionListExceptionHasCorrectiveAction); - oldCorrectiveActionOfExceptionHasCorrectiveActionListExceptionHasCorrectiveAction = em.merge(oldCorrectiveActionOfExceptionHasCorrectiveActionListExceptionHasCorrectiveAction); - } - } - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(CorrectiveAction correctiveAction) throws IllegalOrphanException, NonexistentEntityException, Exception { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - CorrectiveAction persistentCorrectiveAction = em.find(CorrectiveAction.class, correctiveAction.getId()); - List vmUserListOld = persistentCorrectiveAction.getVmUserList(); - List vmUserListNew = correctiveAction.getVmUserList(); - List exceptionHasCorrectiveActionListOld = persistentCorrectiveAction.getExceptionHasCorrectiveActionList(); - List exceptionHasCorrectiveActionListNew = correctiveAction.getExceptionHasCorrectiveActionList(); - List illegalOrphanMessages = null; - for (ExceptionHasCorrectiveAction exceptionHasCorrectiveActionListOldExceptionHasCorrectiveAction : exceptionHasCorrectiveActionListOld) { - if (!exceptionHasCorrectiveActionListNew.contains(exceptionHasCorrectiveActionListOldExceptionHasCorrectiveAction)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain ExceptionHasCorrectiveAction " + exceptionHasCorrectiveActionListOldExceptionHasCorrectiveAction + " since its correctiveAction field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - List attachedVmUserListNew = new ArrayList(); - for (VmUser vmUserListNewVmUserToAttach : vmUserListNew) { - vmUserListNewVmUserToAttach = em.getReference(vmUserListNewVmUserToAttach.getClass(), vmUserListNewVmUserToAttach.getId()); - attachedVmUserListNew.add(vmUserListNewVmUserToAttach); - } - vmUserListNew = attachedVmUserListNew; - correctiveAction.setVmUserList(vmUserListNew); - List attachedExceptionHasCorrectiveActionListNew = new ArrayList(); - for (ExceptionHasCorrectiveAction exceptionHasCorrectiveActionListNewExceptionHasCorrectiveActionToAttach : exceptionHasCorrectiveActionListNew) { - exceptionHasCorrectiveActionListNewExceptionHasCorrectiveActionToAttach = em.getReference(exceptionHasCorrectiveActionListNewExceptionHasCorrectiveActionToAttach.getClass(), exceptionHasCorrectiveActionListNewExceptionHasCorrectiveActionToAttach.getExceptionHasCorrectiveActionPK()); - attachedExceptionHasCorrectiveActionListNew.add(exceptionHasCorrectiveActionListNewExceptionHasCorrectiveActionToAttach); - } - exceptionHasCorrectiveActionListNew = attachedExceptionHasCorrectiveActionListNew; - correctiveAction.setExceptionHasCorrectiveActionList(exceptionHasCorrectiveActionListNew); - correctiveAction = em.merge(correctiveAction); - for (VmUser vmUserListOldVmUser : vmUserListOld) { - if (!vmUserListNew.contains(vmUserListOldVmUser)) { - vmUserListOldVmUser.getCorrectiveActionList().remove(correctiveAction); - vmUserListOldVmUser = em.merge(vmUserListOldVmUser); - } - } - for (VmUser vmUserListNewVmUser : vmUserListNew) { - if (!vmUserListOld.contains(vmUserListNewVmUser)) { - vmUserListNewVmUser.getCorrectiveActionList().add(correctiveAction); - vmUserListNewVmUser = em.merge(vmUserListNewVmUser); - } - } - for (ExceptionHasCorrectiveAction exceptionHasCorrectiveActionListNewExceptionHasCorrectiveAction : exceptionHasCorrectiveActionListNew) { - if (!exceptionHasCorrectiveActionListOld.contains(exceptionHasCorrectiveActionListNewExceptionHasCorrectiveAction)) { - CorrectiveAction oldCorrectiveActionOfExceptionHasCorrectiveActionListNewExceptionHasCorrectiveAction = exceptionHasCorrectiveActionListNewExceptionHasCorrectiveAction.getCorrectiveAction(); - exceptionHasCorrectiveActionListNewExceptionHasCorrectiveAction.setCorrectiveAction(correctiveAction); - exceptionHasCorrectiveActionListNewExceptionHasCorrectiveAction = em.merge(exceptionHasCorrectiveActionListNewExceptionHasCorrectiveAction); - if (oldCorrectiveActionOfExceptionHasCorrectiveActionListNewExceptionHasCorrectiveAction != null && !oldCorrectiveActionOfExceptionHasCorrectiveActionListNewExceptionHasCorrectiveAction.equals(correctiveAction)) { - oldCorrectiveActionOfExceptionHasCorrectiveActionListNewExceptionHasCorrectiveAction.getExceptionHasCorrectiveActionList().remove(exceptionHasCorrectiveActionListNewExceptionHasCorrectiveAction); - oldCorrectiveActionOfExceptionHasCorrectiveActionListNewExceptionHasCorrectiveAction = em.merge(oldCorrectiveActionOfExceptionHasCorrectiveActionListNewExceptionHasCorrectiveAction); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - Integer id = correctiveAction.getId(); - if (findCorrectiveAction(id) == null) { - throw new NonexistentEntityException("The correctiveAction with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - CorrectiveAction correctiveAction; - try { - correctiveAction = em.getReference(CorrectiveAction.class, id); - correctiveAction.getId(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The correctiveAction with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List exceptionHasCorrectiveActionListOrphanCheck = correctiveAction.getExceptionHasCorrectiveActionList(); - for (ExceptionHasCorrectiveAction exceptionHasCorrectiveActionListOrphanCheckExceptionHasCorrectiveAction : exceptionHasCorrectiveActionListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This CorrectiveAction (" + correctiveAction + ") cannot be destroyed since the ExceptionHasCorrectiveAction " + exceptionHasCorrectiveActionListOrphanCheckExceptionHasCorrectiveAction + " in its exceptionHasCorrectiveActionList field has a non-nullable correctiveAction field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - List vmUserList = correctiveAction.getVmUserList(); - for (VmUser vmUserListVmUser : vmUserList) { - vmUserListVmUser.getCorrectiveActionList().remove(correctiveAction); - vmUserListVmUser = em.merge(vmUserListVmUser); - } - em.remove(correctiveAction); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findCorrectiveActionEntities() { - return findCorrectiveActionEntities(true, -1, -1); - } - - public List findCorrectiveActionEntities(int maxResults, int firstResult) { - return findCorrectiveActionEntities(false, maxResults, firstResult); - } - - private List findCorrectiveActionEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(CorrectiveAction.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public CorrectiveAction findCorrectiveAction(Integer id) { - EntityManager em = getEntityManager(); - try { - return em.find(CorrectiveAction.class, id); - } - finally { - em.close(); - } - } - - public int getCorrectiveActionCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(CorrectiveAction.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import com.validation.manager.core.db.CorrectiveAction; +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.VmUser; +import java.util.ArrayList; +import java.util.List; +import com.validation.manager.core.db.ExceptionHasCorrectiveAction; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class CorrectiveActionJpaController implements Serializable { + + public CorrectiveActionJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(CorrectiveAction correctiveAction) { + if (correctiveAction.getVmUserList() == null) { + correctiveAction.setVmUserList(new ArrayList<>()); + } + if (correctiveAction.getExceptionHasCorrectiveActionList() == null) { + correctiveAction.setExceptionHasCorrectiveActionList(new ArrayList<>()); + } + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + List attachedVmUserList = new ArrayList<>(); + for (VmUser vmUserListVmUserToAttach : correctiveAction.getVmUserList()) { + vmUserListVmUserToAttach = em.getReference(vmUserListVmUserToAttach.getClass(), vmUserListVmUserToAttach.getId()); + attachedVmUserList.add(vmUserListVmUserToAttach); + } + correctiveAction.setVmUserList(attachedVmUserList); + List attachedExceptionHasCorrectiveActionList = new ArrayList<>(); + for (ExceptionHasCorrectiveAction exceptionHasCorrectiveActionListExceptionHasCorrectiveActionToAttach : correctiveAction.getExceptionHasCorrectiveActionList()) { + exceptionHasCorrectiveActionListExceptionHasCorrectiveActionToAttach = em.getReference(exceptionHasCorrectiveActionListExceptionHasCorrectiveActionToAttach.getClass(), exceptionHasCorrectiveActionListExceptionHasCorrectiveActionToAttach.getExceptionHasCorrectiveActionPK()); + attachedExceptionHasCorrectiveActionList.add(exceptionHasCorrectiveActionListExceptionHasCorrectiveActionToAttach); + } + correctiveAction.setExceptionHasCorrectiveActionList(attachedExceptionHasCorrectiveActionList); + em.persist(correctiveAction); + for (VmUser vmUserListVmUser : correctiveAction.getVmUserList()) { + vmUserListVmUser.getCorrectiveActionList().add(correctiveAction); + vmUserListVmUser = em.merge(vmUserListVmUser); + } + for (ExceptionHasCorrectiveAction exceptionHasCorrectiveActionListExceptionHasCorrectiveAction : correctiveAction.getExceptionHasCorrectiveActionList()) { + CorrectiveAction oldCorrectiveActionOfExceptionHasCorrectiveActionListExceptionHasCorrectiveAction = exceptionHasCorrectiveActionListExceptionHasCorrectiveAction.getCorrectiveAction(); + exceptionHasCorrectiveActionListExceptionHasCorrectiveAction.setCorrectiveAction(correctiveAction); + exceptionHasCorrectiveActionListExceptionHasCorrectiveAction = em.merge(exceptionHasCorrectiveActionListExceptionHasCorrectiveAction); + if (oldCorrectiveActionOfExceptionHasCorrectiveActionListExceptionHasCorrectiveAction != null) { + oldCorrectiveActionOfExceptionHasCorrectiveActionListExceptionHasCorrectiveAction.getExceptionHasCorrectiveActionList().remove(exceptionHasCorrectiveActionListExceptionHasCorrectiveAction); + oldCorrectiveActionOfExceptionHasCorrectiveActionListExceptionHasCorrectiveAction = em.merge(oldCorrectiveActionOfExceptionHasCorrectiveActionListExceptionHasCorrectiveAction); + } + } + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(CorrectiveAction correctiveAction) throws IllegalOrphanException, NonexistentEntityException, Exception { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + CorrectiveAction persistentCorrectiveAction = em.find(CorrectiveAction.class, correctiveAction.getId()); + List vmUserListOld = persistentCorrectiveAction.getVmUserList(); + List vmUserListNew = correctiveAction.getVmUserList(); + List exceptionHasCorrectiveActionListOld = persistentCorrectiveAction.getExceptionHasCorrectiveActionList(); + List exceptionHasCorrectiveActionListNew = correctiveAction.getExceptionHasCorrectiveActionList(); + List illegalOrphanMessages = null; + for (ExceptionHasCorrectiveAction exceptionHasCorrectiveActionListOldExceptionHasCorrectiveAction : exceptionHasCorrectiveActionListOld) { + if (!exceptionHasCorrectiveActionListNew.contains(exceptionHasCorrectiveActionListOldExceptionHasCorrectiveAction)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain ExceptionHasCorrectiveAction " + exceptionHasCorrectiveActionListOldExceptionHasCorrectiveAction + " since its correctiveAction field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + List attachedVmUserListNew = new ArrayList<>(); + for (VmUser vmUserListNewVmUserToAttach : vmUserListNew) { + vmUserListNewVmUserToAttach = em.getReference(vmUserListNewVmUserToAttach.getClass(), vmUserListNewVmUserToAttach.getId()); + attachedVmUserListNew.add(vmUserListNewVmUserToAttach); + } + vmUserListNew = attachedVmUserListNew; + correctiveAction.setVmUserList(vmUserListNew); + List attachedExceptionHasCorrectiveActionListNew = new ArrayList<>(); + for (ExceptionHasCorrectiveAction exceptionHasCorrectiveActionListNewExceptionHasCorrectiveActionToAttach : exceptionHasCorrectiveActionListNew) { + exceptionHasCorrectiveActionListNewExceptionHasCorrectiveActionToAttach = em.getReference(exceptionHasCorrectiveActionListNewExceptionHasCorrectiveActionToAttach.getClass(), exceptionHasCorrectiveActionListNewExceptionHasCorrectiveActionToAttach.getExceptionHasCorrectiveActionPK()); + attachedExceptionHasCorrectiveActionListNew.add(exceptionHasCorrectiveActionListNewExceptionHasCorrectiveActionToAttach); + } + exceptionHasCorrectiveActionListNew = attachedExceptionHasCorrectiveActionListNew; + correctiveAction.setExceptionHasCorrectiveActionList(exceptionHasCorrectiveActionListNew); + correctiveAction = em.merge(correctiveAction); + for (VmUser vmUserListOldVmUser : vmUserListOld) { + if (!vmUserListNew.contains(vmUserListOldVmUser)) { + vmUserListOldVmUser.getCorrectiveActionList().remove(correctiveAction); + vmUserListOldVmUser = em.merge(vmUserListOldVmUser); + } + } + for (VmUser vmUserListNewVmUser : vmUserListNew) { + if (!vmUserListOld.contains(vmUserListNewVmUser)) { + vmUserListNewVmUser.getCorrectiveActionList().add(correctiveAction); + vmUserListNewVmUser = em.merge(vmUserListNewVmUser); + } + } + for (ExceptionHasCorrectiveAction exceptionHasCorrectiveActionListNewExceptionHasCorrectiveAction : exceptionHasCorrectiveActionListNew) { + if (!exceptionHasCorrectiveActionListOld.contains(exceptionHasCorrectiveActionListNewExceptionHasCorrectiveAction)) { + CorrectiveAction oldCorrectiveActionOfExceptionHasCorrectiveActionListNewExceptionHasCorrectiveAction = exceptionHasCorrectiveActionListNewExceptionHasCorrectiveAction.getCorrectiveAction(); + exceptionHasCorrectiveActionListNewExceptionHasCorrectiveAction.setCorrectiveAction(correctiveAction); + exceptionHasCorrectiveActionListNewExceptionHasCorrectiveAction = em.merge(exceptionHasCorrectiveActionListNewExceptionHasCorrectiveAction); + if (oldCorrectiveActionOfExceptionHasCorrectiveActionListNewExceptionHasCorrectiveAction != null && !oldCorrectiveActionOfExceptionHasCorrectiveActionListNewExceptionHasCorrectiveAction.equals(correctiveAction)) { + oldCorrectiveActionOfExceptionHasCorrectiveActionListNewExceptionHasCorrectiveAction.getExceptionHasCorrectiveActionList().remove(exceptionHasCorrectiveActionListNewExceptionHasCorrectiveAction); + oldCorrectiveActionOfExceptionHasCorrectiveActionListNewExceptionHasCorrectiveAction = em.merge(oldCorrectiveActionOfExceptionHasCorrectiveActionListNewExceptionHasCorrectiveAction); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + Integer id = correctiveAction.getId(); + if (findCorrectiveAction(id) == null) { + throw new NonexistentEntityException("The correctiveAction with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + CorrectiveAction correctiveAction; + try { + correctiveAction = em.getReference(CorrectiveAction.class, id); + correctiveAction.getId(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The correctiveAction with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List exceptionHasCorrectiveActionListOrphanCheck = correctiveAction.getExceptionHasCorrectiveActionList(); + for (ExceptionHasCorrectiveAction exceptionHasCorrectiveActionListOrphanCheckExceptionHasCorrectiveAction : exceptionHasCorrectiveActionListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This CorrectiveAction (" + correctiveAction + ") cannot be destroyed since the ExceptionHasCorrectiveAction " + exceptionHasCorrectiveActionListOrphanCheckExceptionHasCorrectiveAction + " in its exceptionHasCorrectiveActionList field has a non-nullable correctiveAction field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + List vmUserList = correctiveAction.getVmUserList(); + for (VmUser vmUserListVmUser : vmUserList) { + vmUserListVmUser.getCorrectiveActionList().remove(correctiveAction); + vmUserListVmUser = em.merge(vmUserListVmUser); + } + em.remove(correctiveAction); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findCorrectiveActionEntities() { + return findCorrectiveActionEntities(true, -1, -1); + } + + public List findCorrectiveActionEntities(int maxResults, int firstResult) { + return findCorrectiveActionEntities(false, maxResults, firstResult); + } + + private List findCorrectiveActionEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(CorrectiveAction.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public CorrectiveAction findCorrectiveAction(Integer id) { + EntityManager em = getEntityManager(); + try { + return em.find(CorrectiveAction.class, id); + } + finally { + em.close(); + } + } + + public int getCorrectiveActionCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(CorrectiveAction.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/ExecutionResultJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/ExecutionResultJpaController.java index fb65a08c..9cc7c881 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/ExecutionResultJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/ExecutionResultJpaController.java @@ -13,196 +13,196 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import com.validation.manager.core.db.ExecutionResult; -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.ExecutionStep; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import java.util.ArrayList; -import java.util.List; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class ExecutionResultJpaController implements Serializable { - - public ExecutionResultJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(ExecutionResult executionResult) { - if (executionResult.getExecutionStepList() == null) { - executionResult.setExecutionStepList(new ArrayList()); - } - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - List attachedExecutionStepList = new ArrayList(); - for (ExecutionStep executionStepListExecutionStepToAttach : executionResult.getExecutionStepList()) { - executionStepListExecutionStepToAttach = em.getReference(executionStepListExecutionStepToAttach.getClass(), executionStepListExecutionStepToAttach.getExecutionStepPK()); - attachedExecutionStepList.add(executionStepListExecutionStepToAttach); - } - executionResult.setExecutionStepList(attachedExecutionStepList); - em.persist(executionResult); - for (ExecutionStep executionStepListExecutionStep : executionResult.getExecutionStepList()) { - ExecutionResult oldResultIdOfExecutionStepListExecutionStep = executionStepListExecutionStep.getResultId(); - executionStepListExecutionStep.setResultId(executionResult); - executionStepListExecutionStep = em.merge(executionStepListExecutionStep); - if (oldResultIdOfExecutionStepListExecutionStep != null) { - oldResultIdOfExecutionStepListExecutionStep.getExecutionStepList().remove(executionStepListExecutionStep); - oldResultIdOfExecutionStepListExecutionStep = em.merge(oldResultIdOfExecutionStepListExecutionStep); - } - } - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(ExecutionResult executionResult) throws NonexistentEntityException, Exception { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - ExecutionResult persistentExecutionResult = em.find(ExecutionResult.class, executionResult.getId()); - List executionStepListOld = persistentExecutionResult.getExecutionStepList(); - List executionStepListNew = executionResult.getExecutionStepList(); - List attachedExecutionStepListNew = new ArrayList(); - for (ExecutionStep executionStepListNewExecutionStepToAttach : executionStepListNew) { - executionStepListNewExecutionStepToAttach = em.getReference(executionStepListNewExecutionStepToAttach.getClass(), executionStepListNewExecutionStepToAttach.getExecutionStepPK()); - attachedExecutionStepListNew.add(executionStepListNewExecutionStepToAttach); - } - executionStepListNew = attachedExecutionStepListNew; - executionResult.setExecutionStepList(executionStepListNew); - executionResult = em.merge(executionResult); - for (ExecutionStep executionStepListOldExecutionStep : executionStepListOld) { - if (!executionStepListNew.contains(executionStepListOldExecutionStep)) { - executionStepListOldExecutionStep.setResultId(null); - executionStepListOldExecutionStep = em.merge(executionStepListOldExecutionStep); - } - } - for (ExecutionStep executionStepListNewExecutionStep : executionStepListNew) { - if (!executionStepListOld.contains(executionStepListNewExecutionStep)) { - ExecutionResult oldResultIdOfExecutionStepListNewExecutionStep = executionStepListNewExecutionStep.getResultId(); - executionStepListNewExecutionStep.setResultId(executionResult); - executionStepListNewExecutionStep = em.merge(executionStepListNewExecutionStep); - if (oldResultIdOfExecutionStepListNewExecutionStep != null && !oldResultIdOfExecutionStepListNewExecutionStep.equals(executionResult)) { - oldResultIdOfExecutionStepListNewExecutionStep.getExecutionStepList().remove(executionStepListNewExecutionStep); - oldResultIdOfExecutionStepListNewExecutionStep = em.merge(oldResultIdOfExecutionStepListNewExecutionStep); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - Integer id = executionResult.getId(); - if (findExecutionResult(id) == null) { - throw new NonexistentEntityException("The executionResult with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(Integer id) throws NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - ExecutionResult executionResult; - try { - executionResult = em.getReference(ExecutionResult.class, id); - executionResult.getId(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The executionResult with id " + id + " no longer exists.", enfe); - } - List executionStepList = executionResult.getExecutionStepList(); - for (ExecutionStep executionStepListExecutionStep : executionStepList) { - executionStepListExecutionStep.setResultId(null); - executionStepListExecutionStep = em.merge(executionStepListExecutionStep); - } - em.remove(executionResult); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findExecutionResultEntities() { - return findExecutionResultEntities(true, -1, -1); - } - - public List findExecutionResultEntities(int maxResults, int firstResult) { - return findExecutionResultEntities(false, maxResults, firstResult); - } - - private List findExecutionResultEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(ExecutionResult.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public ExecutionResult findExecutionResult(Integer id) { - EntityManager em = getEntityManager(); - try { - return em.find(ExecutionResult.class, id); - } - finally { - em.close(); - } - } - - public int getExecutionResultCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(ExecutionResult.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import com.validation.manager.core.db.ExecutionResult; +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.ExecutionStep; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import java.util.ArrayList; +import java.util.List; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class ExecutionResultJpaController implements Serializable { + + public ExecutionResultJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(ExecutionResult executionResult) { + if (executionResult.getExecutionStepList() == null) { + executionResult.setExecutionStepList(new ArrayList<>()); + } + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + List attachedExecutionStepList = new ArrayList<>(); + for (ExecutionStep executionStepListExecutionStepToAttach : executionResult.getExecutionStepList()) { + executionStepListExecutionStepToAttach = em.getReference(executionStepListExecutionStepToAttach.getClass(), executionStepListExecutionStepToAttach.getExecutionStepPK()); + attachedExecutionStepList.add(executionStepListExecutionStepToAttach); + } + executionResult.setExecutionStepList(attachedExecutionStepList); + em.persist(executionResult); + for (ExecutionStep executionStepListExecutionStep : executionResult.getExecutionStepList()) { + ExecutionResult oldResultIdOfExecutionStepListExecutionStep = executionStepListExecutionStep.getResultId(); + executionStepListExecutionStep.setResultId(executionResult); + executionStepListExecutionStep = em.merge(executionStepListExecutionStep); + if (oldResultIdOfExecutionStepListExecutionStep != null) { + oldResultIdOfExecutionStepListExecutionStep.getExecutionStepList().remove(executionStepListExecutionStep); + oldResultIdOfExecutionStepListExecutionStep = em.merge(oldResultIdOfExecutionStepListExecutionStep); + } + } + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(ExecutionResult executionResult) throws NonexistentEntityException, Exception { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + ExecutionResult persistentExecutionResult = em.find(ExecutionResult.class, executionResult.getId()); + List executionStepListOld = persistentExecutionResult.getExecutionStepList(); + List executionStepListNew = executionResult.getExecutionStepList(); + List attachedExecutionStepListNew = new ArrayList<>(); + for (ExecutionStep executionStepListNewExecutionStepToAttach : executionStepListNew) { + executionStepListNewExecutionStepToAttach = em.getReference(executionStepListNewExecutionStepToAttach.getClass(), executionStepListNewExecutionStepToAttach.getExecutionStepPK()); + attachedExecutionStepListNew.add(executionStepListNewExecutionStepToAttach); + } + executionStepListNew = attachedExecutionStepListNew; + executionResult.setExecutionStepList(executionStepListNew); + executionResult = em.merge(executionResult); + for (ExecutionStep executionStepListOldExecutionStep : executionStepListOld) { + if (!executionStepListNew.contains(executionStepListOldExecutionStep)) { + executionStepListOldExecutionStep.setResultId(null); + executionStepListOldExecutionStep = em.merge(executionStepListOldExecutionStep); + } + } + for (ExecutionStep executionStepListNewExecutionStep : executionStepListNew) { + if (!executionStepListOld.contains(executionStepListNewExecutionStep)) { + ExecutionResult oldResultIdOfExecutionStepListNewExecutionStep = executionStepListNewExecutionStep.getResultId(); + executionStepListNewExecutionStep.setResultId(executionResult); + executionStepListNewExecutionStep = em.merge(executionStepListNewExecutionStep); + if (oldResultIdOfExecutionStepListNewExecutionStep != null && !oldResultIdOfExecutionStepListNewExecutionStep.equals(executionResult)) { + oldResultIdOfExecutionStepListNewExecutionStep.getExecutionStepList().remove(executionStepListNewExecutionStep); + oldResultIdOfExecutionStepListNewExecutionStep = em.merge(oldResultIdOfExecutionStepListNewExecutionStep); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + Integer id = executionResult.getId(); + if (findExecutionResult(id) == null) { + throw new NonexistentEntityException("The executionResult with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(Integer id) throws NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + ExecutionResult executionResult; + try { + executionResult = em.getReference(ExecutionResult.class, id); + executionResult.getId(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The executionResult with id " + id + " no longer exists.", enfe); + } + List executionStepList = executionResult.getExecutionStepList(); + for (ExecutionStep executionStepListExecutionStep : executionStepList) { + executionStepListExecutionStep.setResultId(null); + executionStepListExecutionStep = em.merge(executionStepListExecutionStep); + } + em.remove(executionResult); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findExecutionResultEntities() { + return findExecutionResultEntities(true, -1, -1); + } + + public List findExecutionResultEntities(int maxResults, int firstResult) { + return findExecutionResultEntities(false, maxResults, firstResult); + } + + private List findExecutionResultEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(ExecutionResult.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public ExecutionResult findExecutionResult(Integer id) { + EntityManager em = getEntityManager(); + try { + return em.find(ExecutionResult.class, id); + } + finally { + em.close(); + } + } + + public int getExecutionResultCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(ExecutionResult.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/ExecutionStepHasIssueJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/ExecutionStepHasIssueJpaController.java index b285713e..c0612ae2 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/ExecutionStepHasIssueJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/ExecutionStepHasIssueJpaController.java @@ -13,265 +13,265 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.ExecutionStep; -import com.validation.manager.core.db.ExecutionStepHasIssue; -import com.validation.manager.core.db.ExecutionStepHasIssuePK; -import com.validation.manager.core.db.Issue; -import com.validation.manager.core.db.VmUser; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import com.validation.manager.core.db.controller.exceptions.PreexistingEntityException; -import java.util.ArrayList; -import java.util.List; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class ExecutionStepHasIssueJpaController implements Serializable { - - public ExecutionStepHasIssueJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(ExecutionStepHasIssue executionStepHasIssue) throws PreexistingEntityException, Exception { - if (executionStepHasIssue.getExecutionStepHasIssuePK() == null) { - executionStepHasIssue.setExecutionStepHasIssuePK(new ExecutionStepHasIssuePK()); - } - if (executionStepHasIssue.getVmUserList() == null) { - executionStepHasIssue.setVmUserList(new ArrayList()); - } - executionStepHasIssue.getExecutionStepHasIssuePK().setExecutionStepStepTestCaseId(executionStepHasIssue.getExecutionStep().getExecutionStepPK().getStepTestCaseId()); - executionStepHasIssue.getExecutionStepHasIssuePK().setIssueId(executionStepHasIssue.getIssue().getIssuePK().getId()); - executionStepHasIssue.getExecutionStepHasIssuePK().setIssueIssueTypeId(executionStepHasIssue.getIssue().getIssuePK().getIssueTypeId()); - executionStepHasIssue.getExecutionStepHasIssuePK().setExecutionStepTestCaseExecutionId(executionStepHasIssue.getExecutionStep().getExecutionStepPK().getTestCaseExecutionId()); - executionStepHasIssue.getExecutionStepHasIssuePK().setExecutionStepStepId(executionStepHasIssue.getExecutionStep().getExecutionStepPK().getStepId()); - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - ExecutionStep executionStep = executionStepHasIssue.getExecutionStep(); - if (executionStep != null) { - executionStep = em.getReference(executionStep.getClass(), executionStep.getExecutionStepPK()); - executionStepHasIssue.setExecutionStep(executionStep); - } - Issue issue = executionStepHasIssue.getIssue(); - if (issue != null) { - issue = em.getReference(issue.getClass(), issue.getIssuePK()); - executionStepHasIssue.setIssue(issue); - } - List attachedVmUserList = new ArrayList(); - for (VmUser vmUserListVmUserToAttach : executionStepHasIssue.getVmUserList()) { - vmUserListVmUserToAttach = em.getReference(vmUserListVmUserToAttach.getClass(), vmUserListVmUserToAttach.getId()); - attachedVmUserList.add(vmUserListVmUserToAttach); - } - executionStepHasIssue.setVmUserList(attachedVmUserList); - em.persist(executionStepHasIssue); - if (executionStep != null) { - executionStep.getExecutionStepHasIssueList().add(executionStepHasIssue); - executionStep = em.merge(executionStep); - } - if (issue != null) { - issue.getExecutionStepHasIssueList().add(executionStepHasIssue); - issue = em.merge(issue); - } - for (VmUser vmUserListVmUser : executionStepHasIssue.getVmUserList()) { - vmUserListVmUser.getExecutionStepHasIssueList().add(executionStepHasIssue); - vmUserListVmUser = em.merge(vmUserListVmUser); - } - em.getTransaction().commit(); - } - catch (Exception ex) { - if (findExecutionStepHasIssue(executionStepHasIssue.getExecutionStepHasIssuePK()) != null) { - throw new PreexistingEntityException("ExecutionStepHasIssue " + executionStepHasIssue + " already exists.", ex); - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(ExecutionStepHasIssue executionStepHasIssue) throws NonexistentEntityException, Exception { - executionStepHasIssue.getExecutionStepHasIssuePK().setExecutionStepStepTestCaseId(executionStepHasIssue.getExecutionStep().getExecutionStepPK().getStepTestCaseId()); - executionStepHasIssue.getExecutionStepHasIssuePK().setIssueId(executionStepHasIssue.getIssue().getIssuePK().getId()); - executionStepHasIssue.getExecutionStepHasIssuePK().setIssueIssueTypeId(executionStepHasIssue.getIssue().getIssuePK().getIssueTypeId()); - executionStepHasIssue.getExecutionStepHasIssuePK().setExecutionStepTestCaseExecutionId(executionStepHasIssue.getExecutionStep().getExecutionStepPK().getTestCaseExecutionId()); - executionStepHasIssue.getExecutionStepHasIssuePK().setExecutionStepStepId(executionStepHasIssue.getExecutionStep().getExecutionStepPK().getStepId()); - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - ExecutionStepHasIssue persistentExecutionStepHasIssue = em.find(ExecutionStepHasIssue.class, executionStepHasIssue.getExecutionStepHasIssuePK()); - ExecutionStep executionStepOld = persistentExecutionStepHasIssue.getExecutionStep(); - ExecutionStep executionStepNew = executionStepHasIssue.getExecutionStep(); - Issue issueOld = persistentExecutionStepHasIssue.getIssue(); - Issue issueNew = executionStepHasIssue.getIssue(); - List vmUserListOld = persistentExecutionStepHasIssue.getVmUserList(); - List vmUserListNew = executionStepHasIssue.getVmUserList(); - if (executionStepNew != null) { - executionStepNew = em.getReference(executionStepNew.getClass(), executionStepNew.getExecutionStepPK()); - executionStepHasIssue.setExecutionStep(executionStepNew); - } - if (issueNew != null) { - issueNew = em.getReference(issueNew.getClass(), issueNew.getIssuePK()); - executionStepHasIssue.setIssue(issueNew); - } - List attachedVmUserListNew = new ArrayList(); - for (VmUser vmUserListNewVmUserToAttach : vmUserListNew) { - vmUserListNewVmUserToAttach = em.getReference(vmUserListNewVmUserToAttach.getClass(), vmUserListNewVmUserToAttach.getId()); - attachedVmUserListNew.add(vmUserListNewVmUserToAttach); - } - vmUserListNew = attachedVmUserListNew; - executionStepHasIssue.setVmUserList(vmUserListNew); - executionStepHasIssue = em.merge(executionStepHasIssue); - if (executionStepOld != null && !executionStepOld.equals(executionStepNew)) { - executionStepOld.getExecutionStepHasIssueList().remove(executionStepHasIssue); - executionStepOld = em.merge(executionStepOld); - } - if (executionStepNew != null && !executionStepNew.equals(executionStepOld)) { - executionStepNew.getExecutionStepHasIssueList().add(executionStepHasIssue); - executionStepNew = em.merge(executionStepNew); - } - if (issueOld != null && !issueOld.equals(issueNew)) { - issueOld.getExecutionStepHasIssueList().remove(executionStepHasIssue); - issueOld = em.merge(issueOld); - } - if (issueNew != null && !issueNew.equals(issueOld)) { - issueNew.getExecutionStepHasIssueList().add(executionStepHasIssue); - issueNew = em.merge(issueNew); - } - for (VmUser vmUserListOldVmUser : vmUserListOld) { - if (!vmUserListNew.contains(vmUserListOldVmUser)) { - vmUserListOldVmUser.getExecutionStepHasIssueList().remove(executionStepHasIssue); - vmUserListOldVmUser = em.merge(vmUserListOldVmUser); - } - } - for (VmUser vmUserListNewVmUser : vmUserListNew) { - if (!vmUserListOld.contains(vmUserListNewVmUser)) { - vmUserListNewVmUser.getExecutionStepHasIssueList().add(executionStepHasIssue); - vmUserListNewVmUser = em.merge(vmUserListNewVmUser); - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - ExecutionStepHasIssuePK id = executionStepHasIssue.getExecutionStepHasIssuePK(); - if (findExecutionStepHasIssue(id) == null) { - throw new NonexistentEntityException("The executionStepHasIssue with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(ExecutionStepHasIssuePK id) throws NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - ExecutionStepHasIssue executionStepHasIssue; - try { - executionStepHasIssue = em.getReference(ExecutionStepHasIssue.class, id); - executionStepHasIssue.getExecutionStepHasIssuePK(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The executionStepHasIssue with id " + id + " no longer exists.", enfe); - } - ExecutionStep executionStep = executionStepHasIssue.getExecutionStep(); - if (executionStep != null) { - executionStep.getExecutionStepHasIssueList().remove(executionStepHasIssue); - executionStep = em.merge(executionStep); - } - Issue issue = executionStepHasIssue.getIssue(); - if (issue != null) { - issue.getExecutionStepHasIssueList().remove(executionStepHasIssue); - issue = em.merge(issue); - } - List vmUserList = executionStepHasIssue.getVmUserList(); - for (VmUser vmUserListVmUser : vmUserList) { - vmUserListVmUser.getExecutionStepHasIssueList().remove(executionStepHasIssue); - vmUserListVmUser = em.merge(vmUserListVmUser); - } - em.remove(executionStepHasIssue); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findExecutionStepHasIssueEntities() { - return findExecutionStepHasIssueEntities(true, -1, -1); - } - - public List findExecutionStepHasIssueEntities(int maxResults, int firstResult) { - return findExecutionStepHasIssueEntities(false, maxResults, firstResult); - } - - private List findExecutionStepHasIssueEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(ExecutionStepHasIssue.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public ExecutionStepHasIssue findExecutionStepHasIssue(ExecutionStepHasIssuePK id) { - EntityManager em = getEntityManager(); - try { - return em.find(ExecutionStepHasIssue.class, id); - } - finally { - em.close(); - } - } - - public int getExecutionStepHasIssueCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(ExecutionStepHasIssue.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.ExecutionStep; +import com.validation.manager.core.db.ExecutionStepHasIssue; +import com.validation.manager.core.db.ExecutionStepHasIssuePK; +import com.validation.manager.core.db.Issue; +import com.validation.manager.core.db.VmUser; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import com.validation.manager.core.db.controller.exceptions.PreexistingEntityException; +import java.util.ArrayList; +import java.util.List; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class ExecutionStepHasIssueJpaController implements Serializable { + + public ExecutionStepHasIssueJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(ExecutionStepHasIssue executionStepHasIssue) throws PreexistingEntityException, Exception { + if (executionStepHasIssue.getExecutionStepHasIssuePK() == null) { + executionStepHasIssue.setExecutionStepHasIssuePK(new ExecutionStepHasIssuePK()); + } + if (executionStepHasIssue.getVmUserList() == null) { + executionStepHasIssue.setVmUserList(new ArrayList<>()); + } + executionStepHasIssue.getExecutionStepHasIssuePK().setExecutionStepStepTestCaseId(executionStepHasIssue.getExecutionStep().getExecutionStepPK().getStepTestCaseId()); + executionStepHasIssue.getExecutionStepHasIssuePK().setIssueId(executionStepHasIssue.getIssue().getIssuePK().getId()); + executionStepHasIssue.getExecutionStepHasIssuePK().setIssueIssueTypeId(executionStepHasIssue.getIssue().getIssuePK().getIssueTypeId()); + executionStepHasIssue.getExecutionStepHasIssuePK().setExecutionStepTestCaseExecutionId(executionStepHasIssue.getExecutionStep().getExecutionStepPK().getTestCaseExecutionId()); + executionStepHasIssue.getExecutionStepHasIssuePK().setExecutionStepStepId(executionStepHasIssue.getExecutionStep().getExecutionStepPK().getStepId()); + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + ExecutionStep executionStep = executionStepHasIssue.getExecutionStep(); + if (executionStep != null) { + executionStep = em.getReference(executionStep.getClass(), executionStep.getExecutionStepPK()); + executionStepHasIssue.setExecutionStep(executionStep); + } + Issue issue = executionStepHasIssue.getIssue(); + if (issue != null) { + issue = em.getReference(issue.getClass(), issue.getIssuePK()); + executionStepHasIssue.setIssue(issue); + } + List attachedVmUserList = new ArrayList<>(); + for (VmUser vmUserListVmUserToAttach : executionStepHasIssue.getVmUserList()) { + vmUserListVmUserToAttach = em.getReference(vmUserListVmUserToAttach.getClass(), vmUserListVmUserToAttach.getId()); + attachedVmUserList.add(vmUserListVmUserToAttach); + } + executionStepHasIssue.setVmUserList(attachedVmUserList); + em.persist(executionStepHasIssue); + if (executionStep != null) { + executionStep.getExecutionStepHasIssueList().add(executionStepHasIssue); + executionStep = em.merge(executionStep); + } + if (issue != null) { + issue.getExecutionStepHasIssueList().add(executionStepHasIssue); + issue = em.merge(issue); + } + for (VmUser vmUserListVmUser : executionStepHasIssue.getVmUserList()) { + vmUserListVmUser.getExecutionStepHasIssueList().add(executionStepHasIssue); + vmUserListVmUser = em.merge(vmUserListVmUser); + } + em.getTransaction().commit(); + } + catch (Exception ex) { + if (findExecutionStepHasIssue(executionStepHasIssue.getExecutionStepHasIssuePK()) != null) { + throw new PreexistingEntityException("ExecutionStepHasIssue " + executionStepHasIssue + " already exists.", ex); + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(ExecutionStepHasIssue executionStepHasIssue) throws NonexistentEntityException, Exception { + executionStepHasIssue.getExecutionStepHasIssuePK().setExecutionStepStepTestCaseId(executionStepHasIssue.getExecutionStep().getExecutionStepPK().getStepTestCaseId()); + executionStepHasIssue.getExecutionStepHasIssuePK().setIssueId(executionStepHasIssue.getIssue().getIssuePK().getId()); + executionStepHasIssue.getExecutionStepHasIssuePK().setIssueIssueTypeId(executionStepHasIssue.getIssue().getIssuePK().getIssueTypeId()); + executionStepHasIssue.getExecutionStepHasIssuePK().setExecutionStepTestCaseExecutionId(executionStepHasIssue.getExecutionStep().getExecutionStepPK().getTestCaseExecutionId()); + executionStepHasIssue.getExecutionStepHasIssuePK().setExecutionStepStepId(executionStepHasIssue.getExecutionStep().getExecutionStepPK().getStepId()); + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + ExecutionStepHasIssue persistentExecutionStepHasIssue = em.find(ExecutionStepHasIssue.class, executionStepHasIssue.getExecutionStepHasIssuePK()); + ExecutionStep executionStepOld = persistentExecutionStepHasIssue.getExecutionStep(); + ExecutionStep executionStepNew = executionStepHasIssue.getExecutionStep(); + Issue issueOld = persistentExecutionStepHasIssue.getIssue(); + Issue issueNew = executionStepHasIssue.getIssue(); + List vmUserListOld = persistentExecutionStepHasIssue.getVmUserList(); + List vmUserListNew = executionStepHasIssue.getVmUserList(); + if (executionStepNew != null) { + executionStepNew = em.getReference(executionStepNew.getClass(), executionStepNew.getExecutionStepPK()); + executionStepHasIssue.setExecutionStep(executionStepNew); + } + if (issueNew != null) { + issueNew = em.getReference(issueNew.getClass(), issueNew.getIssuePK()); + executionStepHasIssue.setIssue(issueNew); + } + List attachedVmUserListNew = new ArrayList<>(); + for (VmUser vmUserListNewVmUserToAttach : vmUserListNew) { + vmUserListNewVmUserToAttach = em.getReference(vmUserListNewVmUserToAttach.getClass(), vmUserListNewVmUserToAttach.getId()); + attachedVmUserListNew.add(vmUserListNewVmUserToAttach); + } + vmUserListNew = attachedVmUserListNew; + executionStepHasIssue.setVmUserList(vmUserListNew); + executionStepHasIssue = em.merge(executionStepHasIssue); + if (executionStepOld != null && !executionStepOld.equals(executionStepNew)) { + executionStepOld.getExecutionStepHasIssueList().remove(executionStepHasIssue); + executionStepOld = em.merge(executionStepOld); + } + if (executionStepNew != null && !executionStepNew.equals(executionStepOld)) { + executionStepNew.getExecutionStepHasIssueList().add(executionStepHasIssue); + executionStepNew = em.merge(executionStepNew); + } + if (issueOld != null && !issueOld.equals(issueNew)) { + issueOld.getExecutionStepHasIssueList().remove(executionStepHasIssue); + issueOld = em.merge(issueOld); + } + if (issueNew != null && !issueNew.equals(issueOld)) { + issueNew.getExecutionStepHasIssueList().add(executionStepHasIssue); + issueNew = em.merge(issueNew); + } + for (VmUser vmUserListOldVmUser : vmUserListOld) { + if (!vmUserListNew.contains(vmUserListOldVmUser)) { + vmUserListOldVmUser.getExecutionStepHasIssueList().remove(executionStepHasIssue); + vmUserListOldVmUser = em.merge(vmUserListOldVmUser); + } + } + for (VmUser vmUserListNewVmUser : vmUserListNew) { + if (!vmUserListOld.contains(vmUserListNewVmUser)) { + vmUserListNewVmUser.getExecutionStepHasIssueList().add(executionStepHasIssue); + vmUserListNewVmUser = em.merge(vmUserListNewVmUser); + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + ExecutionStepHasIssuePK id = executionStepHasIssue.getExecutionStepHasIssuePK(); + if (findExecutionStepHasIssue(id) == null) { + throw new NonexistentEntityException("The executionStepHasIssue with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(ExecutionStepHasIssuePK id) throws NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + ExecutionStepHasIssue executionStepHasIssue; + try { + executionStepHasIssue = em.getReference(ExecutionStepHasIssue.class, id); + executionStepHasIssue.getExecutionStepHasIssuePK(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The executionStepHasIssue with id " + id + " no longer exists.", enfe); + } + ExecutionStep executionStep = executionStepHasIssue.getExecutionStep(); + if (executionStep != null) { + executionStep.getExecutionStepHasIssueList().remove(executionStepHasIssue); + executionStep = em.merge(executionStep); + } + Issue issue = executionStepHasIssue.getIssue(); + if (issue != null) { + issue.getExecutionStepHasIssueList().remove(executionStepHasIssue); + issue = em.merge(issue); + } + List vmUserList = executionStepHasIssue.getVmUserList(); + for (VmUser vmUserListVmUser : vmUserList) { + vmUserListVmUser.getExecutionStepHasIssueList().remove(executionStepHasIssue); + vmUserListVmUser = em.merge(vmUserListVmUser); + } + em.remove(executionStepHasIssue); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findExecutionStepHasIssueEntities() { + return findExecutionStepHasIssueEntities(true, -1, -1); + } + + public List findExecutionStepHasIssueEntities(int maxResults, int firstResult) { + return findExecutionStepHasIssueEntities(false, maxResults, firstResult); + } + + private List findExecutionStepHasIssueEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(ExecutionStepHasIssue.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public ExecutionStepHasIssue findExecutionStepHasIssue(ExecutionStepHasIssuePK id) { + EntityManager em = getEntityManager(); + try { + return em.find(ExecutionStepHasIssue.class, id); + } + finally { + em.close(); + } + } + + public int getExecutionStepHasIssueCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(ExecutionStepHasIssue.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/ExecutionStepJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/ExecutionStepJpaController.java index 53b13aa6..0b924133 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/ExecutionStepJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/ExecutionStepJpaController.java @@ -13,603 +13,603 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.ExecutionResult; -import com.validation.manager.core.db.ExecutionStep; -import com.validation.manager.core.db.ReviewResult; -import com.validation.manager.core.db.VmUser; -import com.validation.manager.core.db.Step; -import com.validation.manager.core.db.TestCaseExecution; -import com.validation.manager.core.db.History; -import com.validation.manager.core.db.ExecutionStepHasAttachment; -import java.util.ArrayList; -import java.util.List; -import com.validation.manager.core.db.ExecutionStepHasIssue; -import com.validation.manager.core.db.ExecutionStepHasVmUser; -import com.validation.manager.core.db.ExecutionStepPK; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import com.validation.manager.core.db.controller.exceptions.PreexistingEntityException; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class ExecutionStepJpaController implements Serializable { - - public ExecutionStepJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(ExecutionStep executionStep) throws PreexistingEntityException, Exception { - if (executionStep.getExecutionStepPK() == null) { - executionStep.setExecutionStepPK(new ExecutionStepPK()); - } - if (executionStep.getExecutionStepHasAttachmentList() == null) { - executionStep.setExecutionStepHasAttachmentList(new ArrayList()); - } - if (executionStep.getExecutionStepHasIssueList() == null) { - executionStep.setExecutionStepHasIssueList(new ArrayList()); - } - if (executionStep.getExecutionStepHasVmUserList() == null) { - executionStep.setExecutionStepHasVmUserList(new ArrayList()); - } - if (executionStep.getHistoryList() == null) { - executionStep.setHistoryList(new ArrayList()); - } - executionStep.getExecutionStepPK().setTestCaseExecutionId(executionStep.getTestCaseExecution().getId()); - executionStep.getExecutionStepPK().setStepTestCaseId(executionStep.getStep().getStepPK().getTestCaseId()); - executionStep.getExecutionStepPK().setStepId(executionStep.getStep().getStepPK().getId()); - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - ExecutionResult resultId = executionStep.getResultId(); - if (resultId != null) { - resultId = em.getReference(resultId.getClass(), resultId.getId()); - executionStep.setResultId(resultId); - } - ReviewResult reviewResultId = executionStep.getReviewResultId(); - if (reviewResultId != null) { - reviewResultId = em.getReference(reviewResultId.getClass(), reviewResultId.getId()); - executionStep.setReviewResultId(reviewResultId); - } - VmUser assignee = executionStep.getAssignee(); - if (assignee != null) { - assignee = em.getReference(assignee.getClass(), assignee.getId()); - executionStep.setAssignee(assignee); - } - VmUser assigner = executionStep.getAssigner(); - if (assigner != null) { - assigner = em.getReference(assigner.getClass(), assigner.getId()); - executionStep.setAssigner(assigner); - } - Step step = executionStep.getStep(); - if (step != null) { - step = em.getReference(step.getClass(), step.getStepPK()); - executionStep.setStep(step); - } - TestCaseExecution testCaseExecution = executionStep.getTestCaseExecution(); - if (testCaseExecution != null) { - testCaseExecution = em.getReference(testCaseExecution.getClass(), testCaseExecution.getId()); - executionStep.setTestCaseExecution(testCaseExecution); - } - VmUser reviewer = executionStep.getReviewer(); - if (reviewer != null) { - reviewer = em.getReference(reviewer.getClass(), reviewer.getId()); - executionStep.setReviewer(reviewer); - } - History stepHistory = executionStep.getStepHistory(); - if (stepHistory != null) { - stepHistory = em.getReference(stepHistory.getClass(), stepHistory.getId()); - executionStep.setStepHistory(stepHistory); - } - List attachedExecutionStepHasAttachmentList = new ArrayList(); - for (ExecutionStepHasAttachment executionStepHasAttachmentListExecutionStepHasAttachmentToAttach : executionStep.getExecutionStepHasAttachmentList()) { - executionStepHasAttachmentListExecutionStepHasAttachmentToAttach = em.getReference(executionStepHasAttachmentListExecutionStepHasAttachmentToAttach.getClass(), executionStepHasAttachmentListExecutionStepHasAttachmentToAttach.getExecutionStepHasAttachmentPK()); - attachedExecutionStepHasAttachmentList.add(executionStepHasAttachmentListExecutionStepHasAttachmentToAttach); - } - executionStep.setExecutionStepHasAttachmentList(attachedExecutionStepHasAttachmentList); - List attachedExecutionStepHasIssueList = new ArrayList(); - for (ExecutionStepHasIssue executionStepHasIssueListExecutionStepHasIssueToAttach : executionStep.getExecutionStepHasIssueList()) { - executionStepHasIssueListExecutionStepHasIssueToAttach = em.getReference(executionStepHasIssueListExecutionStepHasIssueToAttach.getClass(), executionStepHasIssueListExecutionStepHasIssueToAttach.getExecutionStepHasIssuePK()); - attachedExecutionStepHasIssueList.add(executionStepHasIssueListExecutionStepHasIssueToAttach); - } - executionStep.setExecutionStepHasIssueList(attachedExecutionStepHasIssueList); - List attachedExecutionStepHasVmUserList = new ArrayList(); - for (ExecutionStepHasVmUser executionStepHasVmUserListExecutionStepHasVmUserToAttach : executionStep.getExecutionStepHasVmUserList()) { - executionStepHasVmUserListExecutionStepHasVmUserToAttach = em.getReference(executionStepHasVmUserListExecutionStepHasVmUserToAttach.getClass(), executionStepHasVmUserListExecutionStepHasVmUserToAttach.getExecutionStepHasVmUserPK()); - attachedExecutionStepHasVmUserList.add(executionStepHasVmUserListExecutionStepHasVmUserToAttach); - } - executionStep.setExecutionStepHasVmUserList(attachedExecutionStepHasVmUserList); - List attachedHistoryList = new ArrayList(); - for (History historyListHistoryToAttach : executionStep.getHistoryList()) { - historyListHistoryToAttach = em.getReference(historyListHistoryToAttach.getClass(), historyListHistoryToAttach.getId()); - attachedHistoryList.add(historyListHistoryToAttach); - } - executionStep.setHistoryList(attachedHistoryList); - em.persist(executionStep); - if (resultId != null) { - resultId.getExecutionStepList().add(executionStep); - resultId = em.merge(resultId); - } - if (reviewResultId != null) { - reviewResultId.getExecutionStepList().add(executionStep); - reviewResultId = em.merge(reviewResultId); - } - if (assignee != null) { - assignee.getExecutionStepList().add(executionStep); - assignee = em.merge(assignee); - } - if (assigner != null) { - assigner.getExecutionStepList().add(executionStep); - assigner = em.merge(assigner); - } - if (step != null) { - step.getExecutionStepList().add(executionStep); - step = em.merge(step); - } - if (testCaseExecution != null) { - testCaseExecution.getExecutionStepList().add(executionStep); - testCaseExecution = em.merge(testCaseExecution); - } - if (reviewer != null) { - reviewer.getExecutionStepList().add(executionStep); - reviewer = em.merge(reviewer); - } - if (stepHistory != null) { - stepHistory.getExecutionStepList().add(executionStep); - stepHistory = em.merge(stepHistory); - } - for (ExecutionStepHasAttachment executionStepHasAttachmentListExecutionStepHasAttachment : executionStep.getExecutionStepHasAttachmentList()) { - ExecutionStep oldExecutionStepOfExecutionStepHasAttachmentListExecutionStepHasAttachment = executionStepHasAttachmentListExecutionStepHasAttachment.getExecutionStep(); - executionStepHasAttachmentListExecutionStepHasAttachment.setExecutionStep(executionStep); - executionStepHasAttachmentListExecutionStepHasAttachment = em.merge(executionStepHasAttachmentListExecutionStepHasAttachment); - if (oldExecutionStepOfExecutionStepHasAttachmentListExecutionStepHasAttachment != null) { - oldExecutionStepOfExecutionStepHasAttachmentListExecutionStepHasAttachment.getExecutionStepHasAttachmentList().remove(executionStepHasAttachmentListExecutionStepHasAttachment); - oldExecutionStepOfExecutionStepHasAttachmentListExecutionStepHasAttachment = em.merge(oldExecutionStepOfExecutionStepHasAttachmentListExecutionStepHasAttachment); - } - } - for (ExecutionStepHasIssue executionStepHasIssueListExecutionStepHasIssue : executionStep.getExecutionStepHasIssueList()) { - ExecutionStep oldExecutionStepOfExecutionStepHasIssueListExecutionStepHasIssue = executionStepHasIssueListExecutionStepHasIssue.getExecutionStep(); - executionStepHasIssueListExecutionStepHasIssue.setExecutionStep(executionStep); - executionStepHasIssueListExecutionStepHasIssue = em.merge(executionStepHasIssueListExecutionStepHasIssue); - if (oldExecutionStepOfExecutionStepHasIssueListExecutionStepHasIssue != null) { - oldExecutionStepOfExecutionStepHasIssueListExecutionStepHasIssue.getExecutionStepHasIssueList().remove(executionStepHasIssueListExecutionStepHasIssue); - oldExecutionStepOfExecutionStepHasIssueListExecutionStepHasIssue = em.merge(oldExecutionStepOfExecutionStepHasIssueListExecutionStepHasIssue); - } - } - for (ExecutionStepHasVmUser executionStepHasVmUserListExecutionStepHasVmUser : executionStep.getExecutionStepHasVmUserList()) { - ExecutionStep oldExecutionStepOfExecutionStepHasVmUserListExecutionStepHasVmUser = executionStepHasVmUserListExecutionStepHasVmUser.getExecutionStep(); - executionStepHasVmUserListExecutionStepHasVmUser.setExecutionStep(executionStep); - executionStepHasVmUserListExecutionStepHasVmUser = em.merge(executionStepHasVmUserListExecutionStepHasVmUser); - if (oldExecutionStepOfExecutionStepHasVmUserListExecutionStepHasVmUser != null) { - oldExecutionStepOfExecutionStepHasVmUserListExecutionStepHasVmUser.getExecutionStepHasVmUserList().remove(executionStepHasVmUserListExecutionStepHasVmUser); - oldExecutionStepOfExecutionStepHasVmUserListExecutionStepHasVmUser = em.merge(oldExecutionStepOfExecutionStepHasVmUserListExecutionStepHasVmUser); - } - } - for (History historyListHistory : executionStep.getHistoryList()) { - historyListHistory.getExecutionStepList().add(executionStep); - historyListHistory = em.merge(historyListHistory); - } - em.getTransaction().commit(); - } - catch (Exception ex) { - if (findExecutionStep(executionStep.getExecutionStepPK()) != null) { - throw new PreexistingEntityException("ExecutionStep " + executionStep + " already exists.", ex); - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(ExecutionStep executionStep) throws IllegalOrphanException, NonexistentEntityException, Exception { - executionStep.getExecutionStepPK().setTestCaseExecutionId(executionStep.getTestCaseExecution().getId()); - executionStep.getExecutionStepPK().setStepTestCaseId(executionStep.getStep().getStepPK().getTestCaseId()); - executionStep.getExecutionStepPK().setStepId(executionStep.getStep().getStepPK().getId()); - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - ExecutionStep persistentExecutionStep = em.find(ExecutionStep.class, executionStep.getExecutionStepPK()); - ExecutionResult resultIdOld = persistentExecutionStep.getResultId(); - ExecutionResult resultIdNew = executionStep.getResultId(); - ReviewResult reviewResultIdOld = persistentExecutionStep.getReviewResultId(); - ReviewResult reviewResultIdNew = executionStep.getReviewResultId(); - VmUser assigneeOld = persistentExecutionStep.getAssignee(); - VmUser assigneeNew = executionStep.getAssignee(); - VmUser assignerOld = persistentExecutionStep.getAssigner(); - VmUser assignerNew = executionStep.getAssigner(); - Step stepOld = persistentExecutionStep.getStep(); - Step stepNew = executionStep.getStep(); - TestCaseExecution testCaseExecutionOld = persistentExecutionStep.getTestCaseExecution(); - TestCaseExecution testCaseExecutionNew = executionStep.getTestCaseExecution(); - VmUser reviewerOld = persistentExecutionStep.getReviewer(); - VmUser reviewerNew = executionStep.getReviewer(); - History stepHistoryOld = persistentExecutionStep.getStepHistory(); - History stepHistoryNew = executionStep.getStepHistory(); - List executionStepHasAttachmentListOld = persistentExecutionStep.getExecutionStepHasAttachmentList(); - List executionStepHasAttachmentListNew = executionStep.getExecutionStepHasAttachmentList(); - List executionStepHasIssueListOld = persistentExecutionStep.getExecutionStepHasIssueList(); - List executionStepHasIssueListNew = executionStep.getExecutionStepHasIssueList(); - List executionStepHasVmUserListOld = persistentExecutionStep.getExecutionStepHasVmUserList(); - List executionStepHasVmUserListNew = executionStep.getExecutionStepHasVmUserList(); - List historyListOld = persistentExecutionStep.getHistoryList(); - List historyListNew = executionStep.getHistoryList(); - List illegalOrphanMessages = null; - for (ExecutionStepHasAttachment executionStepHasAttachmentListOldExecutionStepHasAttachment : executionStepHasAttachmentListOld) { - if (!executionStepHasAttachmentListNew.contains(executionStepHasAttachmentListOldExecutionStepHasAttachment)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain ExecutionStepHasAttachment " + executionStepHasAttachmentListOldExecutionStepHasAttachment + " since its executionStep field is not nullable."); - } - } - for (ExecutionStepHasIssue executionStepHasIssueListOldExecutionStepHasIssue : executionStepHasIssueListOld) { - if (!executionStepHasIssueListNew.contains(executionStepHasIssueListOldExecutionStepHasIssue)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain ExecutionStepHasIssue " + executionStepHasIssueListOldExecutionStepHasIssue + " since its executionStep field is not nullable."); - } - } - for (ExecutionStepHasVmUser executionStepHasVmUserListOldExecutionStepHasVmUser : executionStepHasVmUserListOld) { - if (!executionStepHasVmUserListNew.contains(executionStepHasVmUserListOldExecutionStepHasVmUser)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain ExecutionStepHasVmUser " + executionStepHasVmUserListOldExecutionStepHasVmUser + " since its executionStep field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - if (resultIdNew != null) { - resultIdNew = em.getReference(resultIdNew.getClass(), resultIdNew.getId()); - executionStep.setResultId(resultIdNew); - } - if (reviewResultIdNew != null) { - reviewResultIdNew = em.getReference(reviewResultIdNew.getClass(), reviewResultIdNew.getId()); - executionStep.setReviewResultId(reviewResultIdNew); - } - if (assigneeNew != null) { - assigneeNew = em.getReference(assigneeNew.getClass(), assigneeNew.getId()); - executionStep.setAssignee(assigneeNew); - } - if (assignerNew != null) { - assignerNew = em.getReference(assignerNew.getClass(), assignerNew.getId()); - executionStep.setAssigner(assignerNew); - } - if (stepNew != null) { - stepNew = em.getReference(stepNew.getClass(), stepNew.getStepPK()); - executionStep.setStep(stepNew); - } - if (testCaseExecutionNew != null) { - testCaseExecutionNew = em.getReference(testCaseExecutionNew.getClass(), testCaseExecutionNew.getId()); - executionStep.setTestCaseExecution(testCaseExecutionNew); - } - if (reviewerNew != null) { - reviewerNew = em.getReference(reviewerNew.getClass(), reviewerNew.getId()); - executionStep.setReviewer(reviewerNew); - } - if (stepHistoryNew != null) { - stepHistoryNew = em.getReference(stepHistoryNew.getClass(), stepHistoryNew.getId()); - executionStep.setStepHistory(stepHistoryNew); - } - List attachedExecutionStepHasAttachmentListNew = new ArrayList(); - for (ExecutionStepHasAttachment executionStepHasAttachmentListNewExecutionStepHasAttachmentToAttach : executionStepHasAttachmentListNew) { - executionStepHasAttachmentListNewExecutionStepHasAttachmentToAttach = em.getReference(executionStepHasAttachmentListNewExecutionStepHasAttachmentToAttach.getClass(), executionStepHasAttachmentListNewExecutionStepHasAttachmentToAttach.getExecutionStepHasAttachmentPK()); - attachedExecutionStepHasAttachmentListNew.add(executionStepHasAttachmentListNewExecutionStepHasAttachmentToAttach); - } - executionStepHasAttachmentListNew = attachedExecutionStepHasAttachmentListNew; - executionStep.setExecutionStepHasAttachmentList(executionStepHasAttachmentListNew); - List attachedExecutionStepHasIssueListNew = new ArrayList(); - for (ExecutionStepHasIssue executionStepHasIssueListNewExecutionStepHasIssueToAttach : executionStepHasIssueListNew) { - executionStepHasIssueListNewExecutionStepHasIssueToAttach = em.getReference(executionStepHasIssueListNewExecutionStepHasIssueToAttach.getClass(), executionStepHasIssueListNewExecutionStepHasIssueToAttach.getExecutionStepHasIssuePK()); - attachedExecutionStepHasIssueListNew.add(executionStepHasIssueListNewExecutionStepHasIssueToAttach); - } - executionStepHasIssueListNew = attachedExecutionStepHasIssueListNew; - executionStep.setExecutionStepHasIssueList(executionStepHasIssueListNew); - List attachedExecutionStepHasVmUserListNew = new ArrayList(); - for (ExecutionStepHasVmUser executionStepHasVmUserListNewExecutionStepHasVmUserToAttach : executionStepHasVmUserListNew) { - executionStepHasVmUserListNewExecutionStepHasVmUserToAttach = em.getReference(executionStepHasVmUserListNewExecutionStepHasVmUserToAttach.getClass(), executionStepHasVmUserListNewExecutionStepHasVmUserToAttach.getExecutionStepHasVmUserPK()); - attachedExecutionStepHasVmUserListNew.add(executionStepHasVmUserListNewExecutionStepHasVmUserToAttach); - } - executionStepHasVmUserListNew = attachedExecutionStepHasVmUserListNew; - executionStep.setExecutionStepHasVmUserList(executionStepHasVmUserListNew); - List attachedHistoryListNew = new ArrayList(); - for (History historyListNewHistoryToAttach : historyListNew) { - historyListNewHistoryToAttach = em.getReference(historyListNewHistoryToAttach.getClass(), historyListNewHistoryToAttach.getId()); - attachedHistoryListNew.add(historyListNewHistoryToAttach); - } - historyListNew = attachedHistoryListNew; - executionStep.setHistoryList(historyListNew); - executionStep = em.merge(executionStep); - if (resultIdOld != null && !resultIdOld.equals(resultIdNew)) { - resultIdOld.getExecutionStepList().remove(executionStep); - resultIdOld = em.merge(resultIdOld); - } - if (resultIdNew != null && !resultIdNew.equals(resultIdOld)) { - resultIdNew.getExecutionStepList().add(executionStep); - resultIdNew = em.merge(resultIdNew); - } - if (reviewResultIdOld != null && !reviewResultIdOld.equals(reviewResultIdNew)) { - reviewResultIdOld.getExecutionStepList().remove(executionStep); - reviewResultIdOld = em.merge(reviewResultIdOld); - } - if (reviewResultIdNew != null && !reviewResultIdNew.equals(reviewResultIdOld)) { - reviewResultIdNew.getExecutionStepList().add(executionStep); - reviewResultIdNew = em.merge(reviewResultIdNew); - } - if (assigneeOld != null && !assigneeOld.equals(assigneeNew)) { - assigneeOld.getExecutionStepList().remove(executionStep); - assigneeOld = em.merge(assigneeOld); - } - if (assigneeNew != null && !assigneeNew.equals(assigneeOld)) { - assigneeNew.getExecutionStepList().add(executionStep); - assigneeNew = em.merge(assigneeNew); - } - if (assignerOld != null && !assignerOld.equals(assignerNew)) { - assignerOld.getExecutionStepList().remove(executionStep); - assignerOld = em.merge(assignerOld); - } - if (assignerNew != null && !assignerNew.equals(assignerOld)) { - assignerNew.getExecutionStepList().add(executionStep); - assignerNew = em.merge(assignerNew); - } - if (stepOld != null && !stepOld.equals(stepNew)) { - stepOld.getExecutionStepList().remove(executionStep); - stepOld = em.merge(stepOld); - } - if (stepNew != null && !stepNew.equals(stepOld)) { - stepNew.getExecutionStepList().add(executionStep); - stepNew = em.merge(stepNew); - } - if (testCaseExecutionOld != null && !testCaseExecutionOld.equals(testCaseExecutionNew)) { - testCaseExecutionOld.getExecutionStepList().remove(executionStep); - testCaseExecutionOld = em.merge(testCaseExecutionOld); - } - if (testCaseExecutionNew != null && !testCaseExecutionNew.equals(testCaseExecutionOld)) { - testCaseExecutionNew.getExecutionStepList().add(executionStep); - testCaseExecutionNew = em.merge(testCaseExecutionNew); - } - if (reviewerOld != null && !reviewerOld.equals(reviewerNew)) { - reviewerOld.getExecutionStepList().remove(executionStep); - reviewerOld = em.merge(reviewerOld); - } - if (reviewerNew != null && !reviewerNew.equals(reviewerOld)) { - reviewerNew.getExecutionStepList().add(executionStep); - reviewerNew = em.merge(reviewerNew); - } - if (stepHistoryOld != null && !stepHistoryOld.equals(stepHistoryNew)) { - stepHistoryOld.getExecutionStepList().remove(executionStep); - stepHistoryOld = em.merge(stepHistoryOld); - } - if (stepHistoryNew != null && !stepHistoryNew.equals(stepHistoryOld)) { - stepHistoryNew.getExecutionStepList().add(executionStep); - stepHistoryNew = em.merge(stepHistoryNew); - } - for (ExecutionStepHasAttachment executionStepHasAttachmentListNewExecutionStepHasAttachment : executionStepHasAttachmentListNew) { - if (!executionStepHasAttachmentListOld.contains(executionStepHasAttachmentListNewExecutionStepHasAttachment)) { - ExecutionStep oldExecutionStepOfExecutionStepHasAttachmentListNewExecutionStepHasAttachment = executionStepHasAttachmentListNewExecutionStepHasAttachment.getExecutionStep(); - executionStepHasAttachmentListNewExecutionStepHasAttachment.setExecutionStep(executionStep); - executionStepHasAttachmentListNewExecutionStepHasAttachment = em.merge(executionStepHasAttachmentListNewExecutionStepHasAttachment); - if (oldExecutionStepOfExecutionStepHasAttachmentListNewExecutionStepHasAttachment != null && !oldExecutionStepOfExecutionStepHasAttachmentListNewExecutionStepHasAttachment.equals(executionStep)) { - oldExecutionStepOfExecutionStepHasAttachmentListNewExecutionStepHasAttachment.getExecutionStepHasAttachmentList().remove(executionStepHasAttachmentListNewExecutionStepHasAttachment); - oldExecutionStepOfExecutionStepHasAttachmentListNewExecutionStepHasAttachment = em.merge(oldExecutionStepOfExecutionStepHasAttachmentListNewExecutionStepHasAttachment); - } - } - } - for (ExecutionStepHasIssue executionStepHasIssueListNewExecutionStepHasIssue : executionStepHasIssueListNew) { - if (!executionStepHasIssueListOld.contains(executionStepHasIssueListNewExecutionStepHasIssue)) { - ExecutionStep oldExecutionStepOfExecutionStepHasIssueListNewExecutionStepHasIssue = executionStepHasIssueListNewExecutionStepHasIssue.getExecutionStep(); - executionStepHasIssueListNewExecutionStepHasIssue.setExecutionStep(executionStep); - executionStepHasIssueListNewExecutionStepHasIssue = em.merge(executionStepHasIssueListNewExecutionStepHasIssue); - if (oldExecutionStepOfExecutionStepHasIssueListNewExecutionStepHasIssue != null && !oldExecutionStepOfExecutionStepHasIssueListNewExecutionStepHasIssue.equals(executionStep)) { - oldExecutionStepOfExecutionStepHasIssueListNewExecutionStepHasIssue.getExecutionStepHasIssueList().remove(executionStepHasIssueListNewExecutionStepHasIssue); - oldExecutionStepOfExecutionStepHasIssueListNewExecutionStepHasIssue = em.merge(oldExecutionStepOfExecutionStepHasIssueListNewExecutionStepHasIssue); - } - } - } - for (ExecutionStepHasVmUser executionStepHasVmUserListNewExecutionStepHasVmUser : executionStepHasVmUserListNew) { - if (!executionStepHasVmUserListOld.contains(executionStepHasVmUserListNewExecutionStepHasVmUser)) { - ExecutionStep oldExecutionStepOfExecutionStepHasVmUserListNewExecutionStepHasVmUser = executionStepHasVmUserListNewExecutionStepHasVmUser.getExecutionStep(); - executionStepHasVmUserListNewExecutionStepHasVmUser.setExecutionStep(executionStep); - executionStepHasVmUserListNewExecutionStepHasVmUser = em.merge(executionStepHasVmUserListNewExecutionStepHasVmUser); - if (oldExecutionStepOfExecutionStepHasVmUserListNewExecutionStepHasVmUser != null && !oldExecutionStepOfExecutionStepHasVmUserListNewExecutionStepHasVmUser.equals(executionStep)) { - oldExecutionStepOfExecutionStepHasVmUserListNewExecutionStepHasVmUser.getExecutionStepHasVmUserList().remove(executionStepHasVmUserListNewExecutionStepHasVmUser); - oldExecutionStepOfExecutionStepHasVmUserListNewExecutionStepHasVmUser = em.merge(oldExecutionStepOfExecutionStepHasVmUserListNewExecutionStepHasVmUser); - } - } - } - for (History historyListOldHistory : historyListOld) { - if (!historyListNew.contains(historyListOldHistory)) { - historyListOldHistory.getExecutionStepList().remove(executionStep); - historyListOldHistory = em.merge(historyListOldHistory); - } - } - for (History historyListNewHistory : historyListNew) { - if (!historyListOld.contains(historyListNewHistory)) { - historyListNewHistory.getExecutionStepList().add(executionStep); - historyListNewHistory = em.merge(historyListNewHistory); - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - ExecutionStepPK id = executionStep.getExecutionStepPK(); - if (findExecutionStep(id) == null) { - throw new NonexistentEntityException("The executionStep with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(ExecutionStepPK id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - ExecutionStep executionStep; - try { - executionStep = em.getReference(ExecutionStep.class, id); - executionStep.getExecutionStepPK(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The executionStep with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List executionStepHasAttachmentListOrphanCheck = executionStep.getExecutionStepHasAttachmentList(); - for (ExecutionStepHasAttachment executionStepHasAttachmentListOrphanCheckExecutionStepHasAttachment : executionStepHasAttachmentListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This ExecutionStep (" + executionStep + ") cannot be destroyed since the ExecutionStepHasAttachment " + executionStepHasAttachmentListOrphanCheckExecutionStepHasAttachment + " in its executionStepHasAttachmentList field has a non-nullable executionStep field."); - } - List executionStepHasIssueListOrphanCheck = executionStep.getExecutionStepHasIssueList(); - for (ExecutionStepHasIssue executionStepHasIssueListOrphanCheckExecutionStepHasIssue : executionStepHasIssueListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This ExecutionStep (" + executionStep + ") cannot be destroyed since the ExecutionStepHasIssue " + executionStepHasIssueListOrphanCheckExecutionStepHasIssue + " in its executionStepHasIssueList field has a non-nullable executionStep field."); - } - List executionStepHasVmUserListOrphanCheck = executionStep.getExecutionStepHasVmUserList(); - for (ExecutionStepHasVmUser executionStepHasVmUserListOrphanCheckExecutionStepHasVmUser : executionStepHasVmUserListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This ExecutionStep (" + executionStep + ") cannot be destroyed since the ExecutionStepHasVmUser " + executionStepHasVmUserListOrphanCheckExecutionStepHasVmUser + " in its executionStepHasVmUserList field has a non-nullable executionStep field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - ExecutionResult resultId = executionStep.getResultId(); - if (resultId != null) { - resultId.getExecutionStepList().remove(executionStep); - resultId = em.merge(resultId); - } - ReviewResult reviewResultId = executionStep.getReviewResultId(); - if (reviewResultId != null) { - reviewResultId.getExecutionStepList().remove(executionStep); - reviewResultId = em.merge(reviewResultId); - } - VmUser assignee = executionStep.getAssignee(); - if (assignee != null) { - assignee.getExecutionStepList().remove(executionStep); - assignee = em.merge(assignee); - } - VmUser assigner = executionStep.getAssigner(); - if (assigner != null) { - assigner.getExecutionStepList().remove(executionStep); - assigner = em.merge(assigner); - } - Step step = executionStep.getStep(); - if (step != null) { - step.getExecutionStepList().remove(executionStep); - step = em.merge(step); - } - TestCaseExecution testCaseExecution = executionStep.getTestCaseExecution(); - if (testCaseExecution != null) { - testCaseExecution.getExecutionStepList().remove(executionStep); - testCaseExecution = em.merge(testCaseExecution); - } - VmUser reviewer = executionStep.getReviewer(); - if (reviewer != null) { - reviewer.getExecutionStepList().remove(executionStep); - reviewer = em.merge(reviewer); - } - History stepHistory = executionStep.getStepHistory(); - if (stepHistory != null) { - stepHistory.getExecutionStepList().remove(executionStep); - stepHistory = em.merge(stepHistory); - } - List historyList = executionStep.getHistoryList(); - for (History historyListHistory : historyList) { - historyListHistory.getExecutionStepList().remove(executionStep); - historyListHistory = em.merge(historyListHistory); - } - em.remove(executionStep); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findExecutionStepEntities() { - return findExecutionStepEntities(true, -1, -1); - } - - public List findExecutionStepEntities(int maxResults, int firstResult) { - return findExecutionStepEntities(false, maxResults, firstResult); - } - - private List findExecutionStepEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(ExecutionStep.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public ExecutionStep findExecutionStep(ExecutionStepPK id) { - EntityManager em = getEntityManager(); - try { - return em.find(ExecutionStep.class, id); - } - finally { - em.close(); - } - } - - public int getExecutionStepCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(ExecutionStep.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.ExecutionResult; +import com.validation.manager.core.db.ExecutionStep; +import com.validation.manager.core.db.ReviewResult; +import com.validation.manager.core.db.VmUser; +import com.validation.manager.core.db.Step; +import com.validation.manager.core.db.TestCaseExecution; +import com.validation.manager.core.db.History; +import com.validation.manager.core.db.ExecutionStepHasAttachment; +import java.util.ArrayList; +import java.util.List; +import com.validation.manager.core.db.ExecutionStepHasIssue; +import com.validation.manager.core.db.ExecutionStepHasVmUser; +import com.validation.manager.core.db.ExecutionStepPK; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import com.validation.manager.core.db.controller.exceptions.PreexistingEntityException; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class ExecutionStepJpaController implements Serializable { + + public ExecutionStepJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(ExecutionStep executionStep) throws PreexistingEntityException, Exception { + if (executionStep.getExecutionStepPK() == null) { + executionStep.setExecutionStepPK(new ExecutionStepPK()); + } + if (executionStep.getExecutionStepHasAttachmentList() == null) { + executionStep.setExecutionStepHasAttachmentList(new ArrayList<>()); + } + if (executionStep.getExecutionStepHasIssueList() == null) { + executionStep.setExecutionStepHasIssueList(new ArrayList<>()); + } + if (executionStep.getExecutionStepHasVmUserList() == null) { + executionStep.setExecutionStepHasVmUserList(new ArrayList<>()); + } + if (executionStep.getHistoryList() == null) { + executionStep.setHistoryList(new ArrayList<>()); + } + executionStep.getExecutionStepPK().setTestCaseExecutionId(executionStep.getTestCaseExecution().getId()); + executionStep.getExecutionStepPK().setStepTestCaseId(executionStep.getStep().getStepPK().getTestCaseId()); + executionStep.getExecutionStepPK().setStepId(executionStep.getStep().getStepPK().getId()); + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + ExecutionResult resultId = executionStep.getResultId(); + if (resultId != null) { + resultId = em.getReference(resultId.getClass(), resultId.getId()); + executionStep.setResultId(resultId); + } + ReviewResult reviewResultId = executionStep.getReviewResultId(); + if (reviewResultId != null) { + reviewResultId = em.getReference(reviewResultId.getClass(), reviewResultId.getId()); + executionStep.setReviewResultId(reviewResultId); + } + VmUser assignee = executionStep.getAssignee(); + if (assignee != null) { + assignee = em.getReference(assignee.getClass(), assignee.getId()); + executionStep.setAssignee(assignee); + } + VmUser assigner = executionStep.getAssigner(); + if (assigner != null) { + assigner = em.getReference(assigner.getClass(), assigner.getId()); + executionStep.setAssigner(assigner); + } + Step step = executionStep.getStep(); + if (step != null) { + step = em.getReference(step.getClass(), step.getStepPK()); + executionStep.setStep(step); + } + TestCaseExecution testCaseExecution = executionStep.getTestCaseExecution(); + if (testCaseExecution != null) { + testCaseExecution = em.getReference(testCaseExecution.getClass(), testCaseExecution.getId()); + executionStep.setTestCaseExecution(testCaseExecution); + } + VmUser reviewer = executionStep.getReviewer(); + if (reviewer != null) { + reviewer = em.getReference(reviewer.getClass(), reviewer.getId()); + executionStep.setReviewer(reviewer); + } + History stepHistory = executionStep.getStepHistory(); + if (stepHistory != null) { + stepHistory = em.getReference(stepHistory.getClass(), stepHistory.getId()); + executionStep.setStepHistory(stepHistory); + } + List attachedExecutionStepHasAttachmentList = new ArrayList<>(); + for (ExecutionStepHasAttachment executionStepHasAttachmentListExecutionStepHasAttachmentToAttach : executionStep.getExecutionStepHasAttachmentList()) { + executionStepHasAttachmentListExecutionStepHasAttachmentToAttach = em.getReference(executionStepHasAttachmentListExecutionStepHasAttachmentToAttach.getClass(), executionStepHasAttachmentListExecutionStepHasAttachmentToAttach.getExecutionStepHasAttachmentPK()); + attachedExecutionStepHasAttachmentList.add(executionStepHasAttachmentListExecutionStepHasAttachmentToAttach); + } + executionStep.setExecutionStepHasAttachmentList(attachedExecutionStepHasAttachmentList); + List attachedExecutionStepHasIssueList = new ArrayList<>(); + for (ExecutionStepHasIssue executionStepHasIssueListExecutionStepHasIssueToAttach : executionStep.getExecutionStepHasIssueList()) { + executionStepHasIssueListExecutionStepHasIssueToAttach = em.getReference(executionStepHasIssueListExecutionStepHasIssueToAttach.getClass(), executionStepHasIssueListExecutionStepHasIssueToAttach.getExecutionStepHasIssuePK()); + attachedExecutionStepHasIssueList.add(executionStepHasIssueListExecutionStepHasIssueToAttach); + } + executionStep.setExecutionStepHasIssueList(attachedExecutionStepHasIssueList); + List attachedExecutionStepHasVmUserList = new ArrayList<>(); + for (ExecutionStepHasVmUser executionStepHasVmUserListExecutionStepHasVmUserToAttach : executionStep.getExecutionStepHasVmUserList()) { + executionStepHasVmUserListExecutionStepHasVmUserToAttach = em.getReference(executionStepHasVmUserListExecutionStepHasVmUserToAttach.getClass(), executionStepHasVmUserListExecutionStepHasVmUserToAttach.getExecutionStepHasVmUserPK()); + attachedExecutionStepHasVmUserList.add(executionStepHasVmUserListExecutionStepHasVmUserToAttach); + } + executionStep.setExecutionStepHasVmUserList(attachedExecutionStepHasVmUserList); + List attachedHistoryList = new ArrayList<>(); + for (History historyListHistoryToAttach : executionStep.getHistoryList()) { + historyListHistoryToAttach = em.getReference(historyListHistoryToAttach.getClass(), historyListHistoryToAttach.getId()); + attachedHistoryList.add(historyListHistoryToAttach); + } + executionStep.setHistoryList(attachedHistoryList); + em.persist(executionStep); + if (resultId != null) { + resultId.getExecutionStepList().add(executionStep); + resultId = em.merge(resultId); + } + if (reviewResultId != null) { + reviewResultId.getExecutionStepList().add(executionStep); + reviewResultId = em.merge(reviewResultId); + } + if (assignee != null) { + assignee.getExecutionStepList().add(executionStep); + assignee = em.merge(assignee); + } + if (assigner != null) { + assigner.getExecutionStepList().add(executionStep); + assigner = em.merge(assigner); + } + if (step != null) { + step.getExecutionStepList().add(executionStep); + step = em.merge(step); + } + if (testCaseExecution != null) { + testCaseExecution.getExecutionStepList().add(executionStep); + testCaseExecution = em.merge(testCaseExecution); + } + if (reviewer != null) { + reviewer.getExecutionStepList().add(executionStep); + reviewer = em.merge(reviewer); + } + if (stepHistory != null) { + stepHistory.getExecutionStepList().add(executionStep); + stepHistory = em.merge(stepHistory); + } + for (ExecutionStepHasAttachment executionStepHasAttachmentListExecutionStepHasAttachment : executionStep.getExecutionStepHasAttachmentList()) { + ExecutionStep oldExecutionStepOfExecutionStepHasAttachmentListExecutionStepHasAttachment = executionStepHasAttachmentListExecutionStepHasAttachment.getExecutionStep(); + executionStepHasAttachmentListExecutionStepHasAttachment.setExecutionStep(executionStep); + executionStepHasAttachmentListExecutionStepHasAttachment = em.merge(executionStepHasAttachmentListExecutionStepHasAttachment); + if (oldExecutionStepOfExecutionStepHasAttachmentListExecutionStepHasAttachment != null) { + oldExecutionStepOfExecutionStepHasAttachmentListExecutionStepHasAttachment.getExecutionStepHasAttachmentList().remove(executionStepHasAttachmentListExecutionStepHasAttachment); + oldExecutionStepOfExecutionStepHasAttachmentListExecutionStepHasAttachment = em.merge(oldExecutionStepOfExecutionStepHasAttachmentListExecutionStepHasAttachment); + } + } + for (ExecutionStepHasIssue executionStepHasIssueListExecutionStepHasIssue : executionStep.getExecutionStepHasIssueList()) { + ExecutionStep oldExecutionStepOfExecutionStepHasIssueListExecutionStepHasIssue = executionStepHasIssueListExecutionStepHasIssue.getExecutionStep(); + executionStepHasIssueListExecutionStepHasIssue.setExecutionStep(executionStep); + executionStepHasIssueListExecutionStepHasIssue = em.merge(executionStepHasIssueListExecutionStepHasIssue); + if (oldExecutionStepOfExecutionStepHasIssueListExecutionStepHasIssue != null) { + oldExecutionStepOfExecutionStepHasIssueListExecutionStepHasIssue.getExecutionStepHasIssueList().remove(executionStepHasIssueListExecutionStepHasIssue); + oldExecutionStepOfExecutionStepHasIssueListExecutionStepHasIssue = em.merge(oldExecutionStepOfExecutionStepHasIssueListExecutionStepHasIssue); + } + } + for (ExecutionStepHasVmUser executionStepHasVmUserListExecutionStepHasVmUser : executionStep.getExecutionStepHasVmUserList()) { + ExecutionStep oldExecutionStepOfExecutionStepHasVmUserListExecutionStepHasVmUser = executionStepHasVmUserListExecutionStepHasVmUser.getExecutionStep(); + executionStepHasVmUserListExecutionStepHasVmUser.setExecutionStep(executionStep); + executionStepHasVmUserListExecutionStepHasVmUser = em.merge(executionStepHasVmUserListExecutionStepHasVmUser); + if (oldExecutionStepOfExecutionStepHasVmUserListExecutionStepHasVmUser != null) { + oldExecutionStepOfExecutionStepHasVmUserListExecutionStepHasVmUser.getExecutionStepHasVmUserList().remove(executionStepHasVmUserListExecutionStepHasVmUser); + oldExecutionStepOfExecutionStepHasVmUserListExecutionStepHasVmUser = em.merge(oldExecutionStepOfExecutionStepHasVmUserListExecutionStepHasVmUser); + } + } + for (History historyListHistory : executionStep.getHistoryList()) { + historyListHistory.getExecutionStepList().add(executionStep); + historyListHistory = em.merge(historyListHistory); + } + em.getTransaction().commit(); + } + catch (Exception ex) { + if (findExecutionStep(executionStep.getExecutionStepPK()) != null) { + throw new PreexistingEntityException("ExecutionStep " + executionStep + " already exists.", ex); + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(ExecutionStep executionStep) throws IllegalOrphanException, NonexistentEntityException, Exception { + executionStep.getExecutionStepPK().setTestCaseExecutionId(executionStep.getTestCaseExecution().getId()); + executionStep.getExecutionStepPK().setStepTestCaseId(executionStep.getStep().getStepPK().getTestCaseId()); + executionStep.getExecutionStepPK().setStepId(executionStep.getStep().getStepPK().getId()); + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + ExecutionStep persistentExecutionStep = em.find(ExecutionStep.class, executionStep.getExecutionStepPK()); + ExecutionResult resultIdOld = persistentExecutionStep.getResultId(); + ExecutionResult resultIdNew = executionStep.getResultId(); + ReviewResult reviewResultIdOld = persistentExecutionStep.getReviewResultId(); + ReviewResult reviewResultIdNew = executionStep.getReviewResultId(); + VmUser assigneeOld = persistentExecutionStep.getAssignee(); + VmUser assigneeNew = executionStep.getAssignee(); + VmUser assignerOld = persistentExecutionStep.getAssigner(); + VmUser assignerNew = executionStep.getAssigner(); + Step stepOld = persistentExecutionStep.getStep(); + Step stepNew = executionStep.getStep(); + TestCaseExecution testCaseExecutionOld = persistentExecutionStep.getTestCaseExecution(); + TestCaseExecution testCaseExecutionNew = executionStep.getTestCaseExecution(); + VmUser reviewerOld = persistentExecutionStep.getReviewer(); + VmUser reviewerNew = executionStep.getReviewer(); + History stepHistoryOld = persistentExecutionStep.getStepHistory(); + History stepHistoryNew = executionStep.getStepHistory(); + List executionStepHasAttachmentListOld = persistentExecutionStep.getExecutionStepHasAttachmentList(); + List executionStepHasAttachmentListNew = executionStep.getExecutionStepHasAttachmentList(); + List executionStepHasIssueListOld = persistentExecutionStep.getExecutionStepHasIssueList(); + List executionStepHasIssueListNew = executionStep.getExecutionStepHasIssueList(); + List executionStepHasVmUserListOld = persistentExecutionStep.getExecutionStepHasVmUserList(); + List executionStepHasVmUserListNew = executionStep.getExecutionStepHasVmUserList(); + List historyListOld = persistentExecutionStep.getHistoryList(); + List historyListNew = executionStep.getHistoryList(); + List illegalOrphanMessages = null; + for (ExecutionStepHasAttachment executionStepHasAttachmentListOldExecutionStepHasAttachment : executionStepHasAttachmentListOld) { + if (!executionStepHasAttachmentListNew.contains(executionStepHasAttachmentListOldExecutionStepHasAttachment)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain ExecutionStepHasAttachment " + executionStepHasAttachmentListOldExecutionStepHasAttachment + " since its executionStep field is not nullable."); + } + } + for (ExecutionStepHasIssue executionStepHasIssueListOldExecutionStepHasIssue : executionStepHasIssueListOld) { + if (!executionStepHasIssueListNew.contains(executionStepHasIssueListOldExecutionStepHasIssue)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain ExecutionStepHasIssue " + executionStepHasIssueListOldExecutionStepHasIssue + " since its executionStep field is not nullable."); + } + } + for (ExecutionStepHasVmUser executionStepHasVmUserListOldExecutionStepHasVmUser : executionStepHasVmUserListOld) { + if (!executionStepHasVmUserListNew.contains(executionStepHasVmUserListOldExecutionStepHasVmUser)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain ExecutionStepHasVmUser " + executionStepHasVmUserListOldExecutionStepHasVmUser + " since its executionStep field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + if (resultIdNew != null) { + resultIdNew = em.getReference(resultIdNew.getClass(), resultIdNew.getId()); + executionStep.setResultId(resultIdNew); + } + if (reviewResultIdNew != null) { + reviewResultIdNew = em.getReference(reviewResultIdNew.getClass(), reviewResultIdNew.getId()); + executionStep.setReviewResultId(reviewResultIdNew); + } + if (assigneeNew != null) { + assigneeNew = em.getReference(assigneeNew.getClass(), assigneeNew.getId()); + executionStep.setAssignee(assigneeNew); + } + if (assignerNew != null) { + assignerNew = em.getReference(assignerNew.getClass(), assignerNew.getId()); + executionStep.setAssigner(assignerNew); + } + if (stepNew != null) { + stepNew = em.getReference(stepNew.getClass(), stepNew.getStepPK()); + executionStep.setStep(stepNew); + } + if (testCaseExecutionNew != null) { + testCaseExecutionNew = em.getReference(testCaseExecutionNew.getClass(), testCaseExecutionNew.getId()); + executionStep.setTestCaseExecution(testCaseExecutionNew); + } + if (reviewerNew != null) { + reviewerNew = em.getReference(reviewerNew.getClass(), reviewerNew.getId()); + executionStep.setReviewer(reviewerNew); + } + if (stepHistoryNew != null) { + stepHistoryNew = em.getReference(stepHistoryNew.getClass(), stepHistoryNew.getId()); + executionStep.setStepHistory(stepHistoryNew); + } + List attachedExecutionStepHasAttachmentListNew = new ArrayList<>(); + for (ExecutionStepHasAttachment executionStepHasAttachmentListNewExecutionStepHasAttachmentToAttach : executionStepHasAttachmentListNew) { + executionStepHasAttachmentListNewExecutionStepHasAttachmentToAttach = em.getReference(executionStepHasAttachmentListNewExecutionStepHasAttachmentToAttach.getClass(), executionStepHasAttachmentListNewExecutionStepHasAttachmentToAttach.getExecutionStepHasAttachmentPK()); + attachedExecutionStepHasAttachmentListNew.add(executionStepHasAttachmentListNewExecutionStepHasAttachmentToAttach); + } + executionStepHasAttachmentListNew = attachedExecutionStepHasAttachmentListNew; + executionStep.setExecutionStepHasAttachmentList(executionStepHasAttachmentListNew); + List attachedExecutionStepHasIssueListNew = new ArrayList<>(); + for (ExecutionStepHasIssue executionStepHasIssueListNewExecutionStepHasIssueToAttach : executionStepHasIssueListNew) { + executionStepHasIssueListNewExecutionStepHasIssueToAttach = em.getReference(executionStepHasIssueListNewExecutionStepHasIssueToAttach.getClass(), executionStepHasIssueListNewExecutionStepHasIssueToAttach.getExecutionStepHasIssuePK()); + attachedExecutionStepHasIssueListNew.add(executionStepHasIssueListNewExecutionStepHasIssueToAttach); + } + executionStepHasIssueListNew = attachedExecutionStepHasIssueListNew; + executionStep.setExecutionStepHasIssueList(executionStepHasIssueListNew); + List attachedExecutionStepHasVmUserListNew = new ArrayList<>(); + for (ExecutionStepHasVmUser executionStepHasVmUserListNewExecutionStepHasVmUserToAttach : executionStepHasVmUserListNew) { + executionStepHasVmUserListNewExecutionStepHasVmUserToAttach = em.getReference(executionStepHasVmUserListNewExecutionStepHasVmUserToAttach.getClass(), executionStepHasVmUserListNewExecutionStepHasVmUserToAttach.getExecutionStepHasVmUserPK()); + attachedExecutionStepHasVmUserListNew.add(executionStepHasVmUserListNewExecutionStepHasVmUserToAttach); + } + executionStepHasVmUserListNew = attachedExecutionStepHasVmUserListNew; + executionStep.setExecutionStepHasVmUserList(executionStepHasVmUserListNew); + List attachedHistoryListNew = new ArrayList<>(); + for (History historyListNewHistoryToAttach : historyListNew) { + historyListNewHistoryToAttach = em.getReference(historyListNewHistoryToAttach.getClass(), historyListNewHistoryToAttach.getId()); + attachedHistoryListNew.add(historyListNewHistoryToAttach); + } + historyListNew = attachedHistoryListNew; + executionStep.setHistoryList(historyListNew); + executionStep = em.merge(executionStep); + if (resultIdOld != null && !resultIdOld.equals(resultIdNew)) { + resultIdOld.getExecutionStepList().remove(executionStep); + resultIdOld = em.merge(resultIdOld); + } + if (resultIdNew != null && !resultIdNew.equals(resultIdOld)) { + resultIdNew.getExecutionStepList().add(executionStep); + resultIdNew = em.merge(resultIdNew); + } + if (reviewResultIdOld != null && !reviewResultIdOld.equals(reviewResultIdNew)) { + reviewResultIdOld.getExecutionStepList().remove(executionStep); + reviewResultIdOld = em.merge(reviewResultIdOld); + } + if (reviewResultIdNew != null && !reviewResultIdNew.equals(reviewResultIdOld)) { + reviewResultIdNew.getExecutionStepList().add(executionStep); + reviewResultIdNew = em.merge(reviewResultIdNew); + } + if (assigneeOld != null && !assigneeOld.equals(assigneeNew)) { + assigneeOld.getExecutionStepList().remove(executionStep); + assigneeOld = em.merge(assigneeOld); + } + if (assigneeNew != null && !assigneeNew.equals(assigneeOld)) { + assigneeNew.getExecutionStepList().add(executionStep); + assigneeNew = em.merge(assigneeNew); + } + if (assignerOld != null && !assignerOld.equals(assignerNew)) { + assignerOld.getExecutionStepList().remove(executionStep); + assignerOld = em.merge(assignerOld); + } + if (assignerNew != null && !assignerNew.equals(assignerOld)) { + assignerNew.getExecutionStepList().add(executionStep); + assignerNew = em.merge(assignerNew); + } + if (stepOld != null && !stepOld.equals(stepNew)) { + stepOld.getExecutionStepList().remove(executionStep); + stepOld = em.merge(stepOld); + } + if (stepNew != null && !stepNew.equals(stepOld)) { + stepNew.getExecutionStepList().add(executionStep); + stepNew = em.merge(stepNew); + } + if (testCaseExecutionOld != null && !testCaseExecutionOld.equals(testCaseExecutionNew)) { + testCaseExecutionOld.getExecutionStepList().remove(executionStep); + testCaseExecutionOld = em.merge(testCaseExecutionOld); + } + if (testCaseExecutionNew != null && !testCaseExecutionNew.equals(testCaseExecutionOld)) { + testCaseExecutionNew.getExecutionStepList().add(executionStep); + testCaseExecutionNew = em.merge(testCaseExecutionNew); + } + if (reviewerOld != null && !reviewerOld.equals(reviewerNew)) { + reviewerOld.getExecutionStepList().remove(executionStep); + reviewerOld = em.merge(reviewerOld); + } + if (reviewerNew != null && !reviewerNew.equals(reviewerOld)) { + reviewerNew.getExecutionStepList().add(executionStep); + reviewerNew = em.merge(reviewerNew); + } + if (stepHistoryOld != null && !stepHistoryOld.equals(stepHistoryNew)) { + stepHistoryOld.getExecutionStepList().remove(executionStep); + stepHistoryOld = em.merge(stepHistoryOld); + } + if (stepHistoryNew != null && !stepHistoryNew.equals(stepHistoryOld)) { + stepHistoryNew.getExecutionStepList().add(executionStep); + stepHistoryNew = em.merge(stepHistoryNew); + } + for (ExecutionStepHasAttachment executionStepHasAttachmentListNewExecutionStepHasAttachment : executionStepHasAttachmentListNew) { + if (!executionStepHasAttachmentListOld.contains(executionStepHasAttachmentListNewExecutionStepHasAttachment)) { + ExecutionStep oldExecutionStepOfExecutionStepHasAttachmentListNewExecutionStepHasAttachment = executionStepHasAttachmentListNewExecutionStepHasAttachment.getExecutionStep(); + executionStepHasAttachmentListNewExecutionStepHasAttachment.setExecutionStep(executionStep); + executionStepHasAttachmentListNewExecutionStepHasAttachment = em.merge(executionStepHasAttachmentListNewExecutionStepHasAttachment); + if (oldExecutionStepOfExecutionStepHasAttachmentListNewExecutionStepHasAttachment != null && !oldExecutionStepOfExecutionStepHasAttachmentListNewExecutionStepHasAttachment.equals(executionStep)) { + oldExecutionStepOfExecutionStepHasAttachmentListNewExecutionStepHasAttachment.getExecutionStepHasAttachmentList().remove(executionStepHasAttachmentListNewExecutionStepHasAttachment); + oldExecutionStepOfExecutionStepHasAttachmentListNewExecutionStepHasAttachment = em.merge(oldExecutionStepOfExecutionStepHasAttachmentListNewExecutionStepHasAttachment); + } + } + } + for (ExecutionStepHasIssue executionStepHasIssueListNewExecutionStepHasIssue : executionStepHasIssueListNew) { + if (!executionStepHasIssueListOld.contains(executionStepHasIssueListNewExecutionStepHasIssue)) { + ExecutionStep oldExecutionStepOfExecutionStepHasIssueListNewExecutionStepHasIssue = executionStepHasIssueListNewExecutionStepHasIssue.getExecutionStep(); + executionStepHasIssueListNewExecutionStepHasIssue.setExecutionStep(executionStep); + executionStepHasIssueListNewExecutionStepHasIssue = em.merge(executionStepHasIssueListNewExecutionStepHasIssue); + if (oldExecutionStepOfExecutionStepHasIssueListNewExecutionStepHasIssue != null && !oldExecutionStepOfExecutionStepHasIssueListNewExecutionStepHasIssue.equals(executionStep)) { + oldExecutionStepOfExecutionStepHasIssueListNewExecutionStepHasIssue.getExecutionStepHasIssueList().remove(executionStepHasIssueListNewExecutionStepHasIssue); + oldExecutionStepOfExecutionStepHasIssueListNewExecutionStepHasIssue = em.merge(oldExecutionStepOfExecutionStepHasIssueListNewExecutionStepHasIssue); + } + } + } + for (ExecutionStepHasVmUser executionStepHasVmUserListNewExecutionStepHasVmUser : executionStepHasVmUserListNew) { + if (!executionStepHasVmUserListOld.contains(executionStepHasVmUserListNewExecutionStepHasVmUser)) { + ExecutionStep oldExecutionStepOfExecutionStepHasVmUserListNewExecutionStepHasVmUser = executionStepHasVmUserListNewExecutionStepHasVmUser.getExecutionStep(); + executionStepHasVmUserListNewExecutionStepHasVmUser.setExecutionStep(executionStep); + executionStepHasVmUserListNewExecutionStepHasVmUser = em.merge(executionStepHasVmUserListNewExecutionStepHasVmUser); + if (oldExecutionStepOfExecutionStepHasVmUserListNewExecutionStepHasVmUser != null && !oldExecutionStepOfExecutionStepHasVmUserListNewExecutionStepHasVmUser.equals(executionStep)) { + oldExecutionStepOfExecutionStepHasVmUserListNewExecutionStepHasVmUser.getExecutionStepHasVmUserList().remove(executionStepHasVmUserListNewExecutionStepHasVmUser); + oldExecutionStepOfExecutionStepHasVmUserListNewExecutionStepHasVmUser = em.merge(oldExecutionStepOfExecutionStepHasVmUserListNewExecutionStepHasVmUser); + } + } + } + for (History historyListOldHistory : historyListOld) { + if (!historyListNew.contains(historyListOldHistory)) { + historyListOldHistory.getExecutionStepList().remove(executionStep); + historyListOldHistory = em.merge(historyListOldHistory); + } + } + for (History historyListNewHistory : historyListNew) { + if (!historyListOld.contains(historyListNewHistory)) { + historyListNewHistory.getExecutionStepList().add(executionStep); + historyListNewHistory = em.merge(historyListNewHistory); + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + ExecutionStepPK id = executionStep.getExecutionStepPK(); + if (findExecutionStep(id) == null) { + throw new NonexistentEntityException("The executionStep with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(ExecutionStepPK id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + ExecutionStep executionStep; + try { + executionStep = em.getReference(ExecutionStep.class, id); + executionStep.getExecutionStepPK(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The executionStep with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List executionStepHasAttachmentListOrphanCheck = executionStep.getExecutionStepHasAttachmentList(); + for (ExecutionStepHasAttachment executionStepHasAttachmentListOrphanCheckExecutionStepHasAttachment : executionStepHasAttachmentListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This ExecutionStep (" + executionStep + ") cannot be destroyed since the ExecutionStepHasAttachment " + executionStepHasAttachmentListOrphanCheckExecutionStepHasAttachment + " in its executionStepHasAttachmentList field has a non-nullable executionStep field."); + } + List executionStepHasIssueListOrphanCheck = executionStep.getExecutionStepHasIssueList(); + for (ExecutionStepHasIssue executionStepHasIssueListOrphanCheckExecutionStepHasIssue : executionStepHasIssueListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This ExecutionStep (" + executionStep + ") cannot be destroyed since the ExecutionStepHasIssue " + executionStepHasIssueListOrphanCheckExecutionStepHasIssue + " in its executionStepHasIssueList field has a non-nullable executionStep field."); + } + List executionStepHasVmUserListOrphanCheck = executionStep.getExecutionStepHasVmUserList(); + for (ExecutionStepHasVmUser executionStepHasVmUserListOrphanCheckExecutionStepHasVmUser : executionStepHasVmUserListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This ExecutionStep (" + executionStep + ") cannot be destroyed since the ExecutionStepHasVmUser " + executionStepHasVmUserListOrphanCheckExecutionStepHasVmUser + " in its executionStepHasVmUserList field has a non-nullable executionStep field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + ExecutionResult resultId = executionStep.getResultId(); + if (resultId != null) { + resultId.getExecutionStepList().remove(executionStep); + resultId = em.merge(resultId); + } + ReviewResult reviewResultId = executionStep.getReviewResultId(); + if (reviewResultId != null) { + reviewResultId.getExecutionStepList().remove(executionStep); + reviewResultId = em.merge(reviewResultId); + } + VmUser assignee = executionStep.getAssignee(); + if (assignee != null) { + assignee.getExecutionStepList().remove(executionStep); + assignee = em.merge(assignee); + } + VmUser assigner = executionStep.getAssigner(); + if (assigner != null) { + assigner.getExecutionStepList().remove(executionStep); + assigner = em.merge(assigner); + } + Step step = executionStep.getStep(); + if (step != null) { + step.getExecutionStepList().remove(executionStep); + step = em.merge(step); + } + TestCaseExecution testCaseExecution = executionStep.getTestCaseExecution(); + if (testCaseExecution != null) { + testCaseExecution.getExecutionStepList().remove(executionStep); + testCaseExecution = em.merge(testCaseExecution); + } + VmUser reviewer = executionStep.getReviewer(); + if (reviewer != null) { + reviewer.getExecutionStepList().remove(executionStep); + reviewer = em.merge(reviewer); + } + History stepHistory = executionStep.getStepHistory(); + if (stepHistory != null) { + stepHistory.getExecutionStepList().remove(executionStep); + stepHistory = em.merge(stepHistory); + } + List historyList = executionStep.getHistoryList(); + for (History historyListHistory : historyList) { + historyListHistory.getExecutionStepList().remove(executionStep); + historyListHistory = em.merge(historyListHistory); + } + em.remove(executionStep); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findExecutionStepEntities() { + return findExecutionStepEntities(true, -1, -1); + } + + public List findExecutionStepEntities(int maxResults, int firstResult) { + return findExecutionStepEntities(false, maxResults, firstResult); + } + + private List findExecutionStepEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(ExecutionStep.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public ExecutionStep findExecutionStep(ExecutionStepPK id) { + EntityManager em = getEntityManager(); + try { + return em.find(ExecutionStep.class, id); + } + finally { + em.close(); + } + } + + public int getExecutionStepCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(ExecutionStep.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/FailureModeJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/FailureModeJpaController.java index 43ab07c4..7298bf76 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/FailureModeJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/FailureModeJpaController.java @@ -13,186 +13,186 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import com.validation.manager.core.db.FailureMode; -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.RiskItem; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import java.util.ArrayList; -import java.util.List; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class FailureModeJpaController implements Serializable { - - public FailureModeJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(FailureMode failureMode) { - if (failureMode.getRiskItemList() == null) { - failureMode.setRiskItemList(new ArrayList()); - } - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - List attachedRiskItemList = new ArrayList(); - for (RiskItem riskItemListRiskItemToAttach : failureMode.getRiskItemList()) { - riskItemListRiskItemToAttach = em.getReference(riskItemListRiskItemToAttach.getClass(), riskItemListRiskItemToAttach.getRiskItemPK()); - attachedRiskItemList.add(riskItemListRiskItemToAttach); - } - failureMode.setRiskItemList(attachedRiskItemList); - em.persist(failureMode); - for (RiskItem riskItemListRiskItem : failureMode.getRiskItemList()) { - riskItemListRiskItem.getFailureModeList().add(failureMode); - riskItemListRiskItem = em.merge(riskItemListRiskItem); - } - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(FailureMode failureMode) throws NonexistentEntityException, Exception { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - FailureMode persistentFailureMode = em.find(FailureMode.class, failureMode.getId()); - List riskItemListOld = persistentFailureMode.getRiskItemList(); - List riskItemListNew = failureMode.getRiskItemList(); - List attachedRiskItemListNew = new ArrayList(); - for (RiskItem riskItemListNewRiskItemToAttach : riskItemListNew) { - riskItemListNewRiskItemToAttach = em.getReference(riskItemListNewRiskItemToAttach.getClass(), riskItemListNewRiskItemToAttach.getRiskItemPK()); - attachedRiskItemListNew.add(riskItemListNewRiskItemToAttach); - } - riskItemListNew = attachedRiskItemListNew; - failureMode.setRiskItemList(riskItemListNew); - failureMode = em.merge(failureMode); - for (RiskItem riskItemListOldRiskItem : riskItemListOld) { - if (!riskItemListNew.contains(riskItemListOldRiskItem)) { - riskItemListOldRiskItem.getFailureModeList().remove(failureMode); - riskItemListOldRiskItem = em.merge(riskItemListOldRiskItem); - } - } - for (RiskItem riskItemListNewRiskItem : riskItemListNew) { - if (!riskItemListOld.contains(riskItemListNewRiskItem)) { - riskItemListNewRiskItem.getFailureModeList().add(failureMode); - riskItemListNewRiskItem = em.merge(riskItemListNewRiskItem); - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - Integer id = failureMode.getId(); - if (findFailureMode(id) == null) { - throw new NonexistentEntityException("The failureMode with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(Integer id) throws NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - FailureMode failureMode; - try { - failureMode = em.getReference(FailureMode.class, id); - failureMode.getId(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The failureMode with id " + id + " no longer exists.", enfe); - } - List riskItemList = failureMode.getRiskItemList(); - for (RiskItem riskItemListRiskItem : riskItemList) { - riskItemListRiskItem.getFailureModeList().remove(failureMode); - riskItemListRiskItem = em.merge(riskItemListRiskItem); - } - em.remove(failureMode); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findFailureModeEntities() { - return findFailureModeEntities(true, -1, -1); - } - - public List findFailureModeEntities(int maxResults, int firstResult) { - return findFailureModeEntities(false, maxResults, firstResult); - } - - private List findFailureModeEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(FailureMode.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public FailureMode findFailureMode(Integer id) { - EntityManager em = getEntityManager(); - try { - return em.find(FailureMode.class, id); - } - finally { - em.close(); - } - } - - public int getFailureModeCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(FailureMode.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import com.validation.manager.core.db.FailureMode; +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.RiskItem; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import java.util.ArrayList; +import java.util.List; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class FailureModeJpaController implements Serializable { + + public FailureModeJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(FailureMode failureMode) { + if (failureMode.getRiskItemList() == null) { + failureMode.setRiskItemList(new ArrayList<>()); + } + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + List attachedRiskItemList = new ArrayList<>(); + for (RiskItem riskItemListRiskItemToAttach : failureMode.getRiskItemList()) { + riskItemListRiskItemToAttach = em.getReference(riskItemListRiskItemToAttach.getClass(), riskItemListRiskItemToAttach.getRiskItemPK()); + attachedRiskItemList.add(riskItemListRiskItemToAttach); + } + failureMode.setRiskItemList(attachedRiskItemList); + em.persist(failureMode); + for (RiskItem riskItemListRiskItem : failureMode.getRiskItemList()) { + riskItemListRiskItem.getFailureModeList().add(failureMode); + riskItemListRiskItem = em.merge(riskItemListRiskItem); + } + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(FailureMode failureMode) throws NonexistentEntityException, Exception { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + FailureMode persistentFailureMode = em.find(FailureMode.class, failureMode.getId()); + List riskItemListOld = persistentFailureMode.getRiskItemList(); + List riskItemListNew = failureMode.getRiskItemList(); + List attachedRiskItemListNew = new ArrayList<>(); + for (RiskItem riskItemListNewRiskItemToAttach : riskItemListNew) { + riskItemListNewRiskItemToAttach = em.getReference(riskItemListNewRiskItemToAttach.getClass(), riskItemListNewRiskItemToAttach.getRiskItemPK()); + attachedRiskItemListNew.add(riskItemListNewRiskItemToAttach); + } + riskItemListNew = attachedRiskItemListNew; + failureMode.setRiskItemList(riskItemListNew); + failureMode = em.merge(failureMode); + for (RiskItem riskItemListOldRiskItem : riskItemListOld) { + if (!riskItemListNew.contains(riskItemListOldRiskItem)) { + riskItemListOldRiskItem.getFailureModeList().remove(failureMode); + riskItemListOldRiskItem = em.merge(riskItemListOldRiskItem); + } + } + for (RiskItem riskItemListNewRiskItem : riskItemListNew) { + if (!riskItemListOld.contains(riskItemListNewRiskItem)) { + riskItemListNewRiskItem.getFailureModeList().add(failureMode); + riskItemListNewRiskItem = em.merge(riskItemListNewRiskItem); + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + Integer id = failureMode.getId(); + if (findFailureMode(id) == null) { + throw new NonexistentEntityException("The failureMode with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(Integer id) throws NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + FailureMode failureMode; + try { + failureMode = em.getReference(FailureMode.class, id); + failureMode.getId(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The failureMode with id " + id + " no longer exists.", enfe); + } + List riskItemList = failureMode.getRiskItemList(); + for (RiskItem riskItemListRiskItem : riskItemList) { + riskItemListRiskItem.getFailureModeList().remove(failureMode); + riskItemListRiskItem = em.merge(riskItemListRiskItem); + } + em.remove(failureMode); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findFailureModeEntities() { + return findFailureModeEntities(true, -1, -1); + } + + public List findFailureModeEntities(int maxResults, int firstResult) { + return findFailureModeEntities(false, maxResults, firstResult); + } + + private List findFailureModeEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(FailureMode.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public FailureMode findFailureMode(Integer id) { + EntityManager em = getEntityManager(); + try { + return em.find(FailureMode.class, id); + } + finally { + em.close(); + } + } + + public int getFailureModeCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(FailureMode.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/FieldTypeJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/FieldTypeJpaController.java index 899ef9b7..11f5995a 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/FieldTypeJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/FieldTypeJpaController.java @@ -13,209 +13,209 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import com.validation.manager.core.db.FieldType; -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.HistoryField; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import java.util.ArrayList; -import java.util.List; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class FieldTypeJpaController implements Serializable { - - public FieldTypeJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(FieldType fieldType) { - if (fieldType.getHistoryFieldList() == null) { - fieldType.setHistoryFieldList(new ArrayList()); - } - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - List attachedHistoryFieldList = new ArrayList(); - for (HistoryField historyFieldListHistoryFieldToAttach : fieldType.getHistoryFieldList()) { - historyFieldListHistoryFieldToAttach = em.getReference(historyFieldListHistoryFieldToAttach.getClass(), historyFieldListHistoryFieldToAttach.getHistoryFieldPK()); - attachedHistoryFieldList.add(historyFieldListHistoryFieldToAttach); - } - fieldType.setHistoryFieldList(attachedHistoryFieldList); - em.persist(fieldType); - for (HistoryField historyFieldListHistoryField : fieldType.getHistoryFieldList()) { - FieldType oldFieldTypeOfHistoryFieldListHistoryField = historyFieldListHistoryField.getFieldType(); - historyFieldListHistoryField.setFieldType(fieldType); - historyFieldListHistoryField = em.merge(historyFieldListHistoryField); - if (oldFieldTypeOfHistoryFieldListHistoryField != null) { - oldFieldTypeOfHistoryFieldListHistoryField.getHistoryFieldList().remove(historyFieldListHistoryField); - oldFieldTypeOfHistoryFieldListHistoryField = em.merge(oldFieldTypeOfHistoryFieldListHistoryField); - } - } - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(FieldType fieldType) throws IllegalOrphanException, NonexistentEntityException, Exception { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - FieldType persistentFieldType = em.find(FieldType.class, fieldType.getId()); - List historyFieldListOld = persistentFieldType.getHistoryFieldList(); - List historyFieldListNew = fieldType.getHistoryFieldList(); - List illegalOrphanMessages = null; - for (HistoryField historyFieldListOldHistoryField : historyFieldListOld) { - if (!historyFieldListNew.contains(historyFieldListOldHistoryField)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain HistoryField " + historyFieldListOldHistoryField + " since its fieldType field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - List attachedHistoryFieldListNew = new ArrayList(); - for (HistoryField historyFieldListNewHistoryFieldToAttach : historyFieldListNew) { - historyFieldListNewHistoryFieldToAttach = em.getReference(historyFieldListNewHistoryFieldToAttach.getClass(), historyFieldListNewHistoryFieldToAttach.getHistoryFieldPK()); - attachedHistoryFieldListNew.add(historyFieldListNewHistoryFieldToAttach); - } - historyFieldListNew = attachedHistoryFieldListNew; - fieldType.setHistoryFieldList(historyFieldListNew); - fieldType = em.merge(fieldType); - for (HistoryField historyFieldListNewHistoryField : historyFieldListNew) { - if (!historyFieldListOld.contains(historyFieldListNewHistoryField)) { - FieldType oldFieldTypeOfHistoryFieldListNewHistoryField = historyFieldListNewHistoryField.getFieldType(); - historyFieldListNewHistoryField.setFieldType(fieldType); - historyFieldListNewHistoryField = em.merge(historyFieldListNewHistoryField); - if (oldFieldTypeOfHistoryFieldListNewHistoryField != null && !oldFieldTypeOfHistoryFieldListNewHistoryField.equals(fieldType)) { - oldFieldTypeOfHistoryFieldListNewHistoryField.getHistoryFieldList().remove(historyFieldListNewHistoryField); - oldFieldTypeOfHistoryFieldListNewHistoryField = em.merge(oldFieldTypeOfHistoryFieldListNewHistoryField); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - Integer id = fieldType.getId(); - if (findFieldType(id) == null) { - throw new NonexistentEntityException("The fieldType with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - FieldType fieldType; - try { - fieldType = em.getReference(FieldType.class, id); - fieldType.getId(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The fieldType with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List historyFieldListOrphanCheck = fieldType.getHistoryFieldList(); - for (HistoryField historyFieldListOrphanCheckHistoryField : historyFieldListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This FieldType (" + fieldType + ") cannot be destroyed since the HistoryField " + historyFieldListOrphanCheckHistoryField + " in its historyFieldList field has a non-nullable fieldType field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - em.remove(fieldType); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findFieldTypeEntities() { - return findFieldTypeEntities(true, -1, -1); - } - - public List findFieldTypeEntities(int maxResults, int firstResult) { - return findFieldTypeEntities(false, maxResults, firstResult); - } - - private List findFieldTypeEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(FieldType.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public FieldType findFieldType(Integer id) { - EntityManager em = getEntityManager(); - try { - return em.find(FieldType.class, id); - } - finally { - em.close(); - } - } - - public int getFieldTypeCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(FieldType.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import com.validation.manager.core.db.FieldType; +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.HistoryField; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import java.util.ArrayList; +import java.util.List; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class FieldTypeJpaController implements Serializable { + + public FieldTypeJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(FieldType fieldType) { + if (fieldType.getHistoryFieldList() == null) { + fieldType.setHistoryFieldList(new ArrayList<>()); + } + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + List attachedHistoryFieldList = new ArrayList<>(); + for (HistoryField historyFieldListHistoryFieldToAttach : fieldType.getHistoryFieldList()) { + historyFieldListHistoryFieldToAttach = em.getReference(historyFieldListHistoryFieldToAttach.getClass(), historyFieldListHistoryFieldToAttach.getHistoryFieldPK()); + attachedHistoryFieldList.add(historyFieldListHistoryFieldToAttach); + } + fieldType.setHistoryFieldList(attachedHistoryFieldList); + em.persist(fieldType); + for (HistoryField historyFieldListHistoryField : fieldType.getHistoryFieldList()) { + FieldType oldFieldTypeOfHistoryFieldListHistoryField = historyFieldListHistoryField.getFieldType(); + historyFieldListHistoryField.setFieldType(fieldType); + historyFieldListHistoryField = em.merge(historyFieldListHistoryField); + if (oldFieldTypeOfHistoryFieldListHistoryField != null) { + oldFieldTypeOfHistoryFieldListHistoryField.getHistoryFieldList().remove(historyFieldListHistoryField); + oldFieldTypeOfHistoryFieldListHistoryField = em.merge(oldFieldTypeOfHistoryFieldListHistoryField); + } + } + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(FieldType fieldType) throws IllegalOrphanException, NonexistentEntityException, Exception { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + FieldType persistentFieldType = em.find(FieldType.class, fieldType.getId()); + List historyFieldListOld = persistentFieldType.getHistoryFieldList(); + List historyFieldListNew = fieldType.getHistoryFieldList(); + List illegalOrphanMessages = null; + for (HistoryField historyFieldListOldHistoryField : historyFieldListOld) { + if (!historyFieldListNew.contains(historyFieldListOldHistoryField)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain HistoryField " + historyFieldListOldHistoryField + " since its fieldType field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + List attachedHistoryFieldListNew = new ArrayList<>(); + for (HistoryField historyFieldListNewHistoryFieldToAttach : historyFieldListNew) { + historyFieldListNewHistoryFieldToAttach = em.getReference(historyFieldListNewHistoryFieldToAttach.getClass(), historyFieldListNewHistoryFieldToAttach.getHistoryFieldPK()); + attachedHistoryFieldListNew.add(historyFieldListNewHistoryFieldToAttach); + } + historyFieldListNew = attachedHistoryFieldListNew; + fieldType.setHistoryFieldList(historyFieldListNew); + fieldType = em.merge(fieldType); + for (HistoryField historyFieldListNewHistoryField : historyFieldListNew) { + if (!historyFieldListOld.contains(historyFieldListNewHistoryField)) { + FieldType oldFieldTypeOfHistoryFieldListNewHistoryField = historyFieldListNewHistoryField.getFieldType(); + historyFieldListNewHistoryField.setFieldType(fieldType); + historyFieldListNewHistoryField = em.merge(historyFieldListNewHistoryField); + if (oldFieldTypeOfHistoryFieldListNewHistoryField != null && !oldFieldTypeOfHistoryFieldListNewHistoryField.equals(fieldType)) { + oldFieldTypeOfHistoryFieldListNewHistoryField.getHistoryFieldList().remove(historyFieldListNewHistoryField); + oldFieldTypeOfHistoryFieldListNewHistoryField = em.merge(oldFieldTypeOfHistoryFieldListNewHistoryField); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + Integer id = fieldType.getId(); + if (findFieldType(id) == null) { + throw new NonexistentEntityException("The fieldType with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + FieldType fieldType; + try { + fieldType = em.getReference(FieldType.class, id); + fieldType.getId(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The fieldType with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List historyFieldListOrphanCheck = fieldType.getHistoryFieldList(); + for (HistoryField historyFieldListOrphanCheckHistoryField : historyFieldListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This FieldType (" + fieldType + ") cannot be destroyed since the HistoryField " + historyFieldListOrphanCheckHistoryField + " in its historyFieldList field has a non-nullable fieldType field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + em.remove(fieldType); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findFieldTypeEntities() { + return findFieldTypeEntities(true, -1, -1); + } + + public List findFieldTypeEntities(int maxResults, int firstResult) { + return findFieldTypeEntities(false, maxResults, firstResult); + } + + private List findFieldTypeEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(FieldType.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public FieldType findFieldType(Integer id) { + EntityManager em = getEntityManager(); + try { + return em.find(FieldType.class, id); + } + finally { + em.close(); + } + } + + public int getFieldTypeCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(FieldType.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/FmeaJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/FmeaJpaController.java index 69733618..882f8859 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/FmeaJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/FmeaJpaController.java @@ -13,326 +13,326 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.Fmea; -import com.validation.manager.core.db.RiskCategory; -import java.util.ArrayList; -import java.util.List; -import com.validation.manager.core.db.RiskItem; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class FmeaJpaController implements Serializable { - - public FmeaJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(Fmea fmea) { - if (fmea.getRiskCategoryList() == null) { - fmea.setRiskCategoryList(new ArrayList()); - } - if (fmea.getRiskItemList() == null) { - fmea.setRiskItemList(new ArrayList()); - } - if (fmea.getFmeaList() == null) { - fmea.setFmeaList(new ArrayList()); - } - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - Fmea parent = fmea.getParent(); - if (parent != null) { - parent = em.getReference(parent.getClass(), parent.getId()); - fmea.setParent(parent); - } - List attachedRiskCategoryList = new ArrayList(); - for (RiskCategory riskCategoryListRiskCategoryToAttach : fmea.getRiskCategoryList()) { - riskCategoryListRiskCategoryToAttach = em.getReference(riskCategoryListRiskCategoryToAttach.getClass(), riskCategoryListRiskCategoryToAttach.getId()); - attachedRiskCategoryList.add(riskCategoryListRiskCategoryToAttach); - } - fmea.setRiskCategoryList(attachedRiskCategoryList); - List attachedRiskItemList = new ArrayList(); - for (RiskItem riskItemListRiskItemToAttach : fmea.getRiskItemList()) { - riskItemListRiskItemToAttach = em.getReference(riskItemListRiskItemToAttach.getClass(), riskItemListRiskItemToAttach.getRiskItemPK()); - attachedRiskItemList.add(riskItemListRiskItemToAttach); - } - fmea.setRiskItemList(attachedRiskItemList); - List attachedFmeaList = new ArrayList(); - for (Fmea fmeaListFmeaToAttach : fmea.getFmeaList()) { - fmeaListFmeaToAttach = em.getReference(fmeaListFmeaToAttach.getClass(), fmeaListFmeaToAttach.getId()); - attachedFmeaList.add(fmeaListFmeaToAttach); - } - fmea.setFmeaList(attachedFmeaList); - em.persist(fmea); - if (parent != null) { - parent.getFmeaList().add(fmea); - parent = em.merge(parent); - } - for (RiskCategory riskCategoryListRiskCategory : fmea.getRiskCategoryList()) { - riskCategoryListRiskCategory.getFmeaList().add(fmea); - riskCategoryListRiskCategory = em.merge(riskCategoryListRiskCategory); - } - for (RiskItem riskItemListRiskItem : fmea.getRiskItemList()) { - Fmea oldFmeaOfRiskItemListRiskItem = riskItemListRiskItem.getFmea(); - riskItemListRiskItem.setFmea(fmea); - riskItemListRiskItem = em.merge(riskItemListRiskItem); - if (oldFmeaOfRiskItemListRiskItem != null) { - oldFmeaOfRiskItemListRiskItem.getRiskItemList().remove(riskItemListRiskItem); - oldFmeaOfRiskItemListRiskItem = em.merge(oldFmeaOfRiskItemListRiskItem); - } - } - for (Fmea fmeaListFmea : fmea.getFmeaList()) { - Fmea oldParentOfFmeaListFmea = fmeaListFmea.getParent(); - fmeaListFmea.setParent(fmea); - fmeaListFmea = em.merge(fmeaListFmea); - if (oldParentOfFmeaListFmea != null) { - oldParentOfFmeaListFmea.getFmeaList().remove(fmeaListFmea); - oldParentOfFmeaListFmea = em.merge(oldParentOfFmeaListFmea); - } - } - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(Fmea fmea) throws IllegalOrphanException, NonexistentEntityException, Exception { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - Fmea persistentFmea = em.find(Fmea.class, fmea.getId()); - Fmea parentOld = persistentFmea.getParent(); - Fmea parentNew = fmea.getParent(); - List riskCategoryListOld = persistentFmea.getRiskCategoryList(); - List riskCategoryListNew = fmea.getRiskCategoryList(); - List riskItemListOld = persistentFmea.getRiskItemList(); - List riskItemListNew = fmea.getRiskItemList(); - List fmeaListOld = persistentFmea.getFmeaList(); - List fmeaListNew = fmea.getFmeaList(); - List illegalOrphanMessages = null; - for (RiskItem riskItemListOldRiskItem : riskItemListOld) { - if (!riskItemListNew.contains(riskItemListOldRiskItem)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain RiskItem " + riskItemListOldRiskItem + " since its fmea field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - if (parentNew != null) { - parentNew = em.getReference(parentNew.getClass(), parentNew.getId()); - fmea.setParent(parentNew); - } - List attachedRiskCategoryListNew = new ArrayList(); - for (RiskCategory riskCategoryListNewRiskCategoryToAttach : riskCategoryListNew) { - riskCategoryListNewRiskCategoryToAttach = em.getReference(riskCategoryListNewRiskCategoryToAttach.getClass(), riskCategoryListNewRiskCategoryToAttach.getId()); - attachedRiskCategoryListNew.add(riskCategoryListNewRiskCategoryToAttach); - } - riskCategoryListNew = attachedRiskCategoryListNew; - fmea.setRiskCategoryList(riskCategoryListNew); - List attachedRiskItemListNew = new ArrayList(); - for (RiskItem riskItemListNewRiskItemToAttach : riskItemListNew) { - riskItemListNewRiskItemToAttach = em.getReference(riskItemListNewRiskItemToAttach.getClass(), riskItemListNewRiskItemToAttach.getRiskItemPK()); - attachedRiskItemListNew.add(riskItemListNewRiskItemToAttach); - } - riskItemListNew = attachedRiskItemListNew; - fmea.setRiskItemList(riskItemListNew); - List attachedFmeaListNew = new ArrayList(); - for (Fmea fmeaListNewFmeaToAttach : fmeaListNew) { - fmeaListNewFmeaToAttach = em.getReference(fmeaListNewFmeaToAttach.getClass(), fmeaListNewFmeaToAttach.getId()); - attachedFmeaListNew.add(fmeaListNewFmeaToAttach); - } - fmeaListNew = attachedFmeaListNew; - fmea.setFmeaList(fmeaListNew); - fmea = em.merge(fmea); - if (parentOld != null && !parentOld.equals(parentNew)) { - parentOld.getFmeaList().remove(fmea); - parentOld = em.merge(parentOld); - } - if (parentNew != null && !parentNew.equals(parentOld)) { - parentNew.getFmeaList().add(fmea); - parentNew = em.merge(parentNew); - } - for (RiskCategory riskCategoryListOldRiskCategory : riskCategoryListOld) { - if (!riskCategoryListNew.contains(riskCategoryListOldRiskCategory)) { - riskCategoryListOldRiskCategory.getFmeaList().remove(fmea); - riskCategoryListOldRiskCategory = em.merge(riskCategoryListOldRiskCategory); - } - } - for (RiskCategory riskCategoryListNewRiskCategory : riskCategoryListNew) { - if (!riskCategoryListOld.contains(riskCategoryListNewRiskCategory)) { - riskCategoryListNewRiskCategory.getFmeaList().add(fmea); - riskCategoryListNewRiskCategory = em.merge(riskCategoryListNewRiskCategory); - } - } - for (RiskItem riskItemListNewRiskItem : riskItemListNew) { - if (!riskItemListOld.contains(riskItemListNewRiskItem)) { - Fmea oldFmeaOfRiskItemListNewRiskItem = riskItemListNewRiskItem.getFmea(); - riskItemListNewRiskItem.setFmea(fmea); - riskItemListNewRiskItem = em.merge(riskItemListNewRiskItem); - if (oldFmeaOfRiskItemListNewRiskItem != null && !oldFmeaOfRiskItemListNewRiskItem.equals(fmea)) { - oldFmeaOfRiskItemListNewRiskItem.getRiskItemList().remove(riskItemListNewRiskItem); - oldFmeaOfRiskItemListNewRiskItem = em.merge(oldFmeaOfRiskItemListNewRiskItem); - } - } - } - for (Fmea fmeaListOldFmea : fmeaListOld) { - if (!fmeaListNew.contains(fmeaListOldFmea)) { - fmeaListOldFmea.setParent(null); - fmeaListOldFmea = em.merge(fmeaListOldFmea); - } - } - for (Fmea fmeaListNewFmea : fmeaListNew) { - if (!fmeaListOld.contains(fmeaListNewFmea)) { - Fmea oldParentOfFmeaListNewFmea = fmeaListNewFmea.getParent(); - fmeaListNewFmea.setParent(fmea); - fmeaListNewFmea = em.merge(fmeaListNewFmea); - if (oldParentOfFmeaListNewFmea != null && !oldParentOfFmeaListNewFmea.equals(fmea)) { - oldParentOfFmeaListNewFmea.getFmeaList().remove(fmeaListNewFmea); - oldParentOfFmeaListNewFmea = em.merge(oldParentOfFmeaListNewFmea); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - Integer id = fmea.getId(); - if (findFmea(id) == null) { - throw new NonexistentEntityException("The fmea with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - Fmea fmea; - try { - fmea = em.getReference(Fmea.class, id); - fmea.getId(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The fmea with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List riskItemListOrphanCheck = fmea.getRiskItemList(); - for (RiskItem riskItemListOrphanCheckRiskItem : riskItemListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This Fmea (" + fmea + ") cannot be destroyed since the RiskItem " + riskItemListOrphanCheckRiskItem + " in its riskItemList field has a non-nullable fmea field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - Fmea parent = fmea.getParent(); - if (parent != null) { - parent.getFmeaList().remove(fmea); - parent = em.merge(parent); - } - List riskCategoryList = fmea.getRiskCategoryList(); - for (RiskCategory riskCategoryListRiskCategory : riskCategoryList) { - riskCategoryListRiskCategory.getFmeaList().remove(fmea); - riskCategoryListRiskCategory = em.merge(riskCategoryListRiskCategory); - } - List fmeaList = fmea.getFmeaList(); - for (Fmea fmeaListFmea : fmeaList) { - fmeaListFmea.setParent(null); - fmeaListFmea = em.merge(fmeaListFmea); - } - em.remove(fmea); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findFmeaEntities() { - return findFmeaEntities(true, -1, -1); - } - - public List findFmeaEntities(int maxResults, int firstResult) { - return findFmeaEntities(false, maxResults, firstResult); - } - - private List findFmeaEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(Fmea.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public Fmea findFmea(Integer id) { - EntityManager em = getEntityManager(); - try { - return em.find(Fmea.class, id); - } - finally { - em.close(); - } - } - - public int getFmeaCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(Fmea.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.Fmea; +import com.validation.manager.core.db.RiskCategory; +import java.util.ArrayList; +import java.util.List; +import com.validation.manager.core.db.RiskItem; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class FmeaJpaController implements Serializable { + + public FmeaJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(Fmea fmea) { + if (fmea.getRiskCategoryList() == null) { + fmea.setRiskCategoryList(new ArrayList<>()); + } + if (fmea.getRiskItemList() == null) { + fmea.setRiskItemList(new ArrayList<>()); + } + if (fmea.getFmeaList() == null) { + fmea.setFmeaList(new ArrayList<>()); + } + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + Fmea parent = fmea.getParent(); + if (parent != null) { + parent = em.getReference(parent.getClass(), parent.getId()); + fmea.setParent(parent); + } + List attachedRiskCategoryList = new ArrayList<>(); + for (RiskCategory riskCategoryListRiskCategoryToAttach : fmea.getRiskCategoryList()) { + riskCategoryListRiskCategoryToAttach = em.getReference(riskCategoryListRiskCategoryToAttach.getClass(), riskCategoryListRiskCategoryToAttach.getId()); + attachedRiskCategoryList.add(riskCategoryListRiskCategoryToAttach); + } + fmea.setRiskCategoryList(attachedRiskCategoryList); + List attachedRiskItemList = new ArrayList<>(); + for (RiskItem riskItemListRiskItemToAttach : fmea.getRiskItemList()) { + riskItemListRiskItemToAttach = em.getReference(riskItemListRiskItemToAttach.getClass(), riskItemListRiskItemToAttach.getRiskItemPK()); + attachedRiskItemList.add(riskItemListRiskItemToAttach); + } + fmea.setRiskItemList(attachedRiskItemList); + List attachedFmeaList = new ArrayList<>(); + for (Fmea fmeaListFmeaToAttach : fmea.getFmeaList()) { + fmeaListFmeaToAttach = em.getReference(fmeaListFmeaToAttach.getClass(), fmeaListFmeaToAttach.getId()); + attachedFmeaList.add(fmeaListFmeaToAttach); + } + fmea.setFmeaList(attachedFmeaList); + em.persist(fmea); + if (parent != null) { + parent.getFmeaList().add(fmea); + parent = em.merge(parent); + } + for (RiskCategory riskCategoryListRiskCategory : fmea.getRiskCategoryList()) { + riskCategoryListRiskCategory.getFmeaList().add(fmea); + riskCategoryListRiskCategory = em.merge(riskCategoryListRiskCategory); + } + for (RiskItem riskItemListRiskItem : fmea.getRiskItemList()) { + Fmea oldFmeaOfRiskItemListRiskItem = riskItemListRiskItem.getFmea(); + riskItemListRiskItem.setFmea(fmea); + riskItemListRiskItem = em.merge(riskItemListRiskItem); + if (oldFmeaOfRiskItemListRiskItem != null) { + oldFmeaOfRiskItemListRiskItem.getRiskItemList().remove(riskItemListRiskItem); + oldFmeaOfRiskItemListRiskItem = em.merge(oldFmeaOfRiskItemListRiskItem); + } + } + for (Fmea fmeaListFmea : fmea.getFmeaList()) { + Fmea oldParentOfFmeaListFmea = fmeaListFmea.getParent(); + fmeaListFmea.setParent(fmea); + fmeaListFmea = em.merge(fmeaListFmea); + if (oldParentOfFmeaListFmea != null) { + oldParentOfFmeaListFmea.getFmeaList().remove(fmeaListFmea); + oldParentOfFmeaListFmea = em.merge(oldParentOfFmeaListFmea); + } + } + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(Fmea fmea) throws IllegalOrphanException, NonexistentEntityException, Exception { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + Fmea persistentFmea = em.find(Fmea.class, fmea.getId()); + Fmea parentOld = persistentFmea.getParent(); + Fmea parentNew = fmea.getParent(); + List riskCategoryListOld = persistentFmea.getRiskCategoryList(); + List riskCategoryListNew = fmea.getRiskCategoryList(); + List riskItemListOld = persistentFmea.getRiskItemList(); + List riskItemListNew = fmea.getRiskItemList(); + List fmeaListOld = persistentFmea.getFmeaList(); + List fmeaListNew = fmea.getFmeaList(); + List illegalOrphanMessages = null; + for (RiskItem riskItemListOldRiskItem : riskItemListOld) { + if (!riskItemListNew.contains(riskItemListOldRiskItem)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain RiskItem " + riskItemListOldRiskItem + " since its fmea field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + if (parentNew != null) { + parentNew = em.getReference(parentNew.getClass(), parentNew.getId()); + fmea.setParent(parentNew); + } + List attachedRiskCategoryListNew = new ArrayList<>(); + for (RiskCategory riskCategoryListNewRiskCategoryToAttach : riskCategoryListNew) { + riskCategoryListNewRiskCategoryToAttach = em.getReference(riskCategoryListNewRiskCategoryToAttach.getClass(), riskCategoryListNewRiskCategoryToAttach.getId()); + attachedRiskCategoryListNew.add(riskCategoryListNewRiskCategoryToAttach); + } + riskCategoryListNew = attachedRiskCategoryListNew; + fmea.setRiskCategoryList(riskCategoryListNew); + List attachedRiskItemListNew = new ArrayList<>(); + for (RiskItem riskItemListNewRiskItemToAttach : riskItemListNew) { + riskItemListNewRiskItemToAttach = em.getReference(riskItemListNewRiskItemToAttach.getClass(), riskItemListNewRiskItemToAttach.getRiskItemPK()); + attachedRiskItemListNew.add(riskItemListNewRiskItemToAttach); + } + riskItemListNew = attachedRiskItemListNew; + fmea.setRiskItemList(riskItemListNew); + List attachedFmeaListNew = new ArrayList<>(); + for (Fmea fmeaListNewFmeaToAttach : fmeaListNew) { + fmeaListNewFmeaToAttach = em.getReference(fmeaListNewFmeaToAttach.getClass(), fmeaListNewFmeaToAttach.getId()); + attachedFmeaListNew.add(fmeaListNewFmeaToAttach); + } + fmeaListNew = attachedFmeaListNew; + fmea.setFmeaList(fmeaListNew); + fmea = em.merge(fmea); + if (parentOld != null && !parentOld.equals(parentNew)) { + parentOld.getFmeaList().remove(fmea); + parentOld = em.merge(parentOld); + } + if (parentNew != null && !parentNew.equals(parentOld)) { + parentNew.getFmeaList().add(fmea); + parentNew = em.merge(parentNew); + } + for (RiskCategory riskCategoryListOldRiskCategory : riskCategoryListOld) { + if (!riskCategoryListNew.contains(riskCategoryListOldRiskCategory)) { + riskCategoryListOldRiskCategory.getFmeaList().remove(fmea); + riskCategoryListOldRiskCategory = em.merge(riskCategoryListOldRiskCategory); + } + } + for (RiskCategory riskCategoryListNewRiskCategory : riskCategoryListNew) { + if (!riskCategoryListOld.contains(riskCategoryListNewRiskCategory)) { + riskCategoryListNewRiskCategory.getFmeaList().add(fmea); + riskCategoryListNewRiskCategory = em.merge(riskCategoryListNewRiskCategory); + } + } + for (RiskItem riskItemListNewRiskItem : riskItemListNew) { + if (!riskItemListOld.contains(riskItemListNewRiskItem)) { + Fmea oldFmeaOfRiskItemListNewRiskItem = riskItemListNewRiskItem.getFmea(); + riskItemListNewRiskItem.setFmea(fmea); + riskItemListNewRiskItem = em.merge(riskItemListNewRiskItem); + if (oldFmeaOfRiskItemListNewRiskItem != null && !oldFmeaOfRiskItemListNewRiskItem.equals(fmea)) { + oldFmeaOfRiskItemListNewRiskItem.getRiskItemList().remove(riskItemListNewRiskItem); + oldFmeaOfRiskItemListNewRiskItem = em.merge(oldFmeaOfRiskItemListNewRiskItem); + } + } + } + for (Fmea fmeaListOldFmea : fmeaListOld) { + if (!fmeaListNew.contains(fmeaListOldFmea)) { + fmeaListOldFmea.setParent(null); + fmeaListOldFmea = em.merge(fmeaListOldFmea); + } + } + for (Fmea fmeaListNewFmea : fmeaListNew) { + if (!fmeaListOld.contains(fmeaListNewFmea)) { + Fmea oldParentOfFmeaListNewFmea = fmeaListNewFmea.getParent(); + fmeaListNewFmea.setParent(fmea); + fmeaListNewFmea = em.merge(fmeaListNewFmea); + if (oldParentOfFmeaListNewFmea != null && !oldParentOfFmeaListNewFmea.equals(fmea)) { + oldParentOfFmeaListNewFmea.getFmeaList().remove(fmeaListNewFmea); + oldParentOfFmeaListNewFmea = em.merge(oldParentOfFmeaListNewFmea); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + Integer id = fmea.getId(); + if (findFmea(id) == null) { + throw new NonexistentEntityException("The fmea with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + Fmea fmea; + try { + fmea = em.getReference(Fmea.class, id); + fmea.getId(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The fmea with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List riskItemListOrphanCheck = fmea.getRiskItemList(); + for (RiskItem riskItemListOrphanCheckRiskItem : riskItemListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This Fmea (" + fmea + ") cannot be destroyed since the RiskItem " + riskItemListOrphanCheckRiskItem + " in its riskItemList field has a non-nullable fmea field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + Fmea parent = fmea.getParent(); + if (parent != null) { + parent.getFmeaList().remove(fmea); + parent = em.merge(parent); + } + List riskCategoryList = fmea.getRiskCategoryList(); + for (RiskCategory riskCategoryListRiskCategory : riskCategoryList) { + riskCategoryListRiskCategory.getFmeaList().remove(fmea); + riskCategoryListRiskCategory = em.merge(riskCategoryListRiskCategory); + } + List fmeaList = fmea.getFmeaList(); + for (Fmea fmeaListFmea : fmeaList) { + fmeaListFmea.setParent(null); + fmeaListFmea = em.merge(fmeaListFmea); + } + em.remove(fmea); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findFmeaEntities() { + return findFmeaEntities(true, -1, -1); + } + + public List findFmeaEntities(int maxResults, int firstResult) { + return findFmeaEntities(false, maxResults, firstResult); + } + + private List findFmeaEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(Fmea.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public Fmea findFmea(Integer id) { + EntityManager em = getEntityManager(); + try { + return em.find(Fmea.class, id); + } + finally { + em.close(); + } + } + + public int getFmeaCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(Fmea.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/HazardJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/HazardJpaController.java index a0f03baf..0b28ec35 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/HazardJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/HazardJpaController.java @@ -13,186 +13,186 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import com.validation.manager.core.db.Hazard; -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.RiskItem; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import java.util.ArrayList; -import java.util.List; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class HazardJpaController implements Serializable { - - public HazardJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(Hazard hazard) { - if (hazard.getRiskItemList() == null) { - hazard.setRiskItemList(new ArrayList()); - } - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - List attachedRiskItemList = new ArrayList(); - for (RiskItem riskItemListRiskItemToAttach : hazard.getRiskItemList()) { - riskItemListRiskItemToAttach = em.getReference(riskItemListRiskItemToAttach.getClass(), riskItemListRiskItemToAttach.getRiskItemPK()); - attachedRiskItemList.add(riskItemListRiskItemToAttach); - } - hazard.setRiskItemList(attachedRiskItemList); - em.persist(hazard); - for (RiskItem riskItemListRiskItem : hazard.getRiskItemList()) { - riskItemListRiskItem.getHazardList().add(hazard); - riskItemListRiskItem = em.merge(riskItemListRiskItem); - } - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(Hazard hazard) throws NonexistentEntityException, Exception { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - Hazard persistentHazard = em.find(Hazard.class, hazard.getId()); - List riskItemListOld = persistentHazard.getRiskItemList(); - List riskItemListNew = hazard.getRiskItemList(); - List attachedRiskItemListNew = new ArrayList(); - for (RiskItem riskItemListNewRiskItemToAttach : riskItemListNew) { - riskItemListNewRiskItemToAttach = em.getReference(riskItemListNewRiskItemToAttach.getClass(), riskItemListNewRiskItemToAttach.getRiskItemPK()); - attachedRiskItemListNew.add(riskItemListNewRiskItemToAttach); - } - riskItemListNew = attachedRiskItemListNew; - hazard.setRiskItemList(riskItemListNew); - hazard = em.merge(hazard); - for (RiskItem riskItemListOldRiskItem : riskItemListOld) { - if (!riskItemListNew.contains(riskItemListOldRiskItem)) { - riskItemListOldRiskItem.getHazardList().remove(hazard); - riskItemListOldRiskItem = em.merge(riskItemListOldRiskItem); - } - } - for (RiskItem riskItemListNewRiskItem : riskItemListNew) { - if (!riskItemListOld.contains(riskItemListNewRiskItem)) { - riskItemListNewRiskItem.getHazardList().add(hazard); - riskItemListNewRiskItem = em.merge(riskItemListNewRiskItem); - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - Integer id = hazard.getId(); - if (findHazard(id) == null) { - throw new NonexistentEntityException("The hazard with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(Integer id) throws NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - Hazard hazard; - try { - hazard = em.getReference(Hazard.class, id); - hazard.getId(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The hazard with id " + id + " no longer exists.", enfe); - } - List riskItemList = hazard.getRiskItemList(); - for (RiskItem riskItemListRiskItem : riskItemList) { - riskItemListRiskItem.getHazardList().remove(hazard); - riskItemListRiskItem = em.merge(riskItemListRiskItem); - } - em.remove(hazard); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findHazardEntities() { - return findHazardEntities(true, -1, -1); - } - - public List findHazardEntities(int maxResults, int firstResult) { - return findHazardEntities(false, maxResults, firstResult); - } - - private List findHazardEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(Hazard.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public Hazard findHazard(Integer id) { - EntityManager em = getEntityManager(); - try { - return em.find(Hazard.class, id); - } - finally { - em.close(); - } - } - - public int getHazardCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(Hazard.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import com.validation.manager.core.db.Hazard; +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.RiskItem; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import java.util.ArrayList; +import java.util.List; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class HazardJpaController implements Serializable { + + public HazardJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(Hazard hazard) { + if (hazard.getRiskItemList() == null) { + hazard.setRiskItemList(new ArrayList<>()); + } + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + List attachedRiskItemList = new ArrayList<>(); + for (RiskItem riskItemListRiskItemToAttach : hazard.getRiskItemList()) { + riskItemListRiskItemToAttach = em.getReference(riskItemListRiskItemToAttach.getClass(), riskItemListRiskItemToAttach.getRiskItemPK()); + attachedRiskItemList.add(riskItemListRiskItemToAttach); + } + hazard.setRiskItemList(attachedRiskItemList); + em.persist(hazard); + for (RiskItem riskItemListRiskItem : hazard.getRiskItemList()) { + riskItemListRiskItem.getHazardList().add(hazard); + riskItemListRiskItem = em.merge(riskItemListRiskItem); + } + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(Hazard hazard) throws NonexistentEntityException, Exception { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + Hazard persistentHazard = em.find(Hazard.class, hazard.getId()); + List riskItemListOld = persistentHazard.getRiskItemList(); + List riskItemListNew = hazard.getRiskItemList(); + List attachedRiskItemListNew = new ArrayList<>(); + for (RiskItem riskItemListNewRiskItemToAttach : riskItemListNew) { + riskItemListNewRiskItemToAttach = em.getReference(riskItemListNewRiskItemToAttach.getClass(), riskItemListNewRiskItemToAttach.getRiskItemPK()); + attachedRiskItemListNew.add(riskItemListNewRiskItemToAttach); + } + riskItemListNew = attachedRiskItemListNew; + hazard.setRiskItemList(riskItemListNew); + hazard = em.merge(hazard); + for (RiskItem riskItemListOldRiskItem : riskItemListOld) { + if (!riskItemListNew.contains(riskItemListOldRiskItem)) { + riskItemListOldRiskItem.getHazardList().remove(hazard); + riskItemListOldRiskItem = em.merge(riskItemListOldRiskItem); + } + } + for (RiskItem riskItemListNewRiskItem : riskItemListNew) { + if (!riskItemListOld.contains(riskItemListNewRiskItem)) { + riskItemListNewRiskItem.getHazardList().add(hazard); + riskItemListNewRiskItem = em.merge(riskItemListNewRiskItem); + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + Integer id = hazard.getId(); + if (findHazard(id) == null) { + throw new NonexistentEntityException("The hazard with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(Integer id) throws NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + Hazard hazard; + try { + hazard = em.getReference(Hazard.class, id); + hazard.getId(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The hazard with id " + id + " no longer exists.", enfe); + } + List riskItemList = hazard.getRiskItemList(); + for (RiskItem riskItemListRiskItem : riskItemList) { + riskItemListRiskItem.getHazardList().remove(hazard); + riskItemListRiskItem = em.merge(riskItemListRiskItem); + } + em.remove(hazard); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findHazardEntities() { + return findHazardEntities(true, -1, -1); + } + + public List findHazardEntities(int maxResults, int firstResult) { + return findHazardEntities(false, maxResults, firstResult); + } + + private List findHazardEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(Hazard.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public Hazard findHazard(Integer id) { + EntityManager em = getEntityManager(); + try { + return em.find(Hazard.class, id); + } + finally { + em.close(); + } + } + + public int getHazardCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(Hazard.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/HistoryJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/HistoryJpaController.java index 8c3caa07..27ac154b 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/HistoryJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/HistoryJpaController.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,434 +13,462 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.VmUser; -import com.validation.manager.core.db.Requirement; -import com.validation.manager.core.db.Project; -import com.validation.manager.core.db.Step; -import com.validation.manager.core.db.VmSetting; -import com.validation.manager.core.db.HistoryField; -import java.util.ArrayList; -import java.util.List; -import com.validation.manager.core.db.Baseline; -import com.validation.manager.core.db.ExecutionStep; -import com.validation.manager.core.db.History; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class HistoryJpaController implements Serializable { - - public HistoryJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(History history) { - if (history.getHistoryFieldList() == null) { - history.setHistoryFieldList(new ArrayList()); - } - if (history.getBaselineList() == null) { - history.setBaselineList(new ArrayList()); - } - if (history.getExecutionStepList() == null) { - history.setExecutionStepList(new ArrayList()); - } - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - VmUser modifierId = history.getModifierId(); - if (modifierId != null) { - modifierId = em.getReference(modifierId.getClass(), modifierId.getId()); - history.setModifierId(modifierId); - } - Requirement requirementId = history.getRequirementId(); - if (requirementId != null) { - requirementId = em.getReference(requirementId.getClass(), requirementId.getId()); - history.setRequirementId(requirementId); - } - Project projectId = history.getProjectId(); - if (projectId != null) { - projectId = em.getReference(projectId.getClass(), projectId.getId()); - history.setProjectId(projectId); - } - Step step = history.getStep(); - if (step != null) { - step = em.getReference(step.getClass(), step.getStepPK()); - history.setStep(step); - } - VmSetting vmSettingId = history.getVmSettingId(); - if (vmSettingId != null) { - vmSettingId = em.getReference(vmSettingId.getClass(), vmSettingId.getId()); - history.setVmSettingId(vmSettingId); - } - List attachedHistoryFieldList = new ArrayList(); - for (HistoryField historyFieldListHistoryFieldToAttach : history.getHistoryFieldList()) { - historyFieldListHistoryFieldToAttach = em.getReference(historyFieldListHistoryFieldToAttach.getClass(), historyFieldListHistoryFieldToAttach.getHistoryFieldPK()); - attachedHistoryFieldList.add(historyFieldListHistoryFieldToAttach); - } - history.setHistoryFieldList(attachedHistoryFieldList); - List attachedBaselineList = new ArrayList(); - for (Baseline baselineListBaselineToAttach : history.getBaselineList()) { - baselineListBaselineToAttach = em.getReference(baselineListBaselineToAttach.getClass(), baselineListBaselineToAttach.getId()); - attachedBaselineList.add(baselineListBaselineToAttach); - } - history.setBaselineList(attachedBaselineList); - List attachedExecutionStepList = new ArrayList(); - for (ExecutionStep executionStepListExecutionStepToAttach : history.getExecutionStepList()) { - executionStepListExecutionStepToAttach = em.getReference(executionStepListExecutionStepToAttach.getClass(), executionStepListExecutionStepToAttach.getExecutionStepPK()); - attachedExecutionStepList.add(executionStepListExecutionStepToAttach); - } - history.setExecutionStepList(attachedExecutionStepList); - em.persist(history); - if (modifierId != null) { - modifierId.getHistoryModificationList().add(history); - modifierId = em.merge(modifierId); - } - if (requirementId != null) { - requirementId.getHistoryList().add(history); - requirementId = em.merge(requirementId); - } - if (projectId != null) { - projectId.getHistoryList().add(history); - projectId = em.merge(projectId); - } - if (step != null) { - step.getHistoryList().add(history); - step = em.merge(step); - } - if (vmSettingId != null) { - vmSettingId.getHistoryList().add(history); - vmSettingId = em.merge(vmSettingId); - } - for (HistoryField historyFieldListHistoryField : history.getHistoryFieldList()) { - History oldHistoryOfHistoryFieldListHistoryField = historyFieldListHistoryField.getHistory(); - historyFieldListHistoryField.setHistory(history); - historyFieldListHistoryField = em.merge(historyFieldListHistoryField); - if (oldHistoryOfHistoryFieldListHistoryField != null) { - oldHistoryOfHistoryFieldListHistoryField.getHistoryFieldList().remove(historyFieldListHistoryField); - oldHistoryOfHistoryFieldListHistoryField = em.merge(oldHistoryOfHistoryFieldListHistoryField); - } - } - for (Baseline baselineListBaseline : history.getBaselineList()) { - baselineListBaseline.getHistoryList().add(history); - baselineListBaseline = em.merge(baselineListBaseline); - } - for (ExecutionStep executionStepListExecutionStep : history.getExecutionStepList()) { - executionStepListExecutionStep.getHistoryList().add(history); - executionStepListExecutionStep = em.merge(executionStepListExecutionStep); - } - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(History history) throws IllegalOrphanException, NonexistentEntityException, Exception { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - History persistentHistory = em.find(History.class, history.getId()); - VmUser modifierIdOld = persistentHistory.getModifierId(); - VmUser modifierIdNew = history.getModifierId(); - Requirement requirementIdOld = persistentHistory.getRequirementId(); - Requirement requirementIdNew = history.getRequirementId(); - Project projectIdOld = persistentHistory.getProjectId(); - Project projectIdNew = history.getProjectId(); - Step stepOld = persistentHistory.getStep(); - Step stepNew = history.getStep(); - VmSetting vmSettingIdOld = persistentHistory.getVmSettingId(); - VmSetting vmSettingIdNew = history.getVmSettingId(); - List historyFieldListOld = persistentHistory.getHistoryFieldList(); - List historyFieldListNew = history.getHistoryFieldList(); - List baselineListOld = persistentHistory.getBaselineList(); - List baselineListNew = history.getBaselineList(); - List executionStepListOld = persistentHistory.getExecutionStepList(); - List executionStepListNew = history.getExecutionStepList(); - List illegalOrphanMessages = null; - for (HistoryField historyFieldListOldHistoryField : historyFieldListOld) { - if (!historyFieldListNew.contains(historyFieldListOldHistoryField)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain HistoryField " + historyFieldListOldHistoryField + " since its history field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - if (modifierIdNew != null) { - modifierIdNew = em.getReference(modifierIdNew.getClass(), modifierIdNew.getId()); - history.setModifierId(modifierIdNew); - } - if (requirementIdNew != null) { - requirementIdNew = em.getReference(requirementIdNew.getClass(), requirementIdNew.getId()); - history.setRequirementId(requirementIdNew); - } - if (projectIdNew != null) { - projectIdNew = em.getReference(projectIdNew.getClass(), projectIdNew.getId()); - history.setProjectId(projectIdNew); - } - if (stepNew != null) { - stepNew = em.getReference(stepNew.getClass(), stepNew.getStepPK()); - history.setStep(stepNew); - } - if (vmSettingIdNew != null) { - vmSettingIdNew = em.getReference(vmSettingIdNew.getClass(), vmSettingIdNew.getId()); - history.setVmSettingId(vmSettingIdNew); - } - List attachedHistoryFieldListNew = new ArrayList(); - for (HistoryField historyFieldListNewHistoryFieldToAttach : historyFieldListNew) { - historyFieldListNewHistoryFieldToAttach = em.getReference(historyFieldListNewHistoryFieldToAttach.getClass(), historyFieldListNewHistoryFieldToAttach.getHistoryFieldPK()); - attachedHistoryFieldListNew.add(historyFieldListNewHistoryFieldToAttach); - } - historyFieldListNew = attachedHistoryFieldListNew; - history.setHistoryFieldList(historyFieldListNew); - List attachedBaselineListNew = new ArrayList(); - for (Baseline baselineListNewBaselineToAttach : baselineListNew) { - baselineListNewBaselineToAttach = em.getReference(baselineListNewBaselineToAttach.getClass(), baselineListNewBaselineToAttach.getId()); - attachedBaselineListNew.add(baselineListNewBaselineToAttach); - } - baselineListNew = attachedBaselineListNew; - history.setBaselineList(baselineListNew); - List attachedExecutionStepListNew = new ArrayList(); - for (ExecutionStep executionStepListNewExecutionStepToAttach : executionStepListNew) { - executionStepListNewExecutionStepToAttach = em.getReference(executionStepListNewExecutionStepToAttach.getClass(), executionStepListNewExecutionStepToAttach.getExecutionStepPK()); - attachedExecutionStepListNew.add(executionStepListNewExecutionStepToAttach); - } - executionStepListNew = attachedExecutionStepListNew; - history.setExecutionStepList(executionStepListNew); - history = em.merge(history); - if (modifierIdOld != null && !modifierIdOld.equals(modifierIdNew)) { - modifierIdOld.getHistoryModificationList().remove(history); - modifierIdOld = em.merge(modifierIdOld); - } - if (modifierIdNew != null && !modifierIdNew.equals(modifierIdOld)) { - modifierIdNew.getHistoryModificationList().add(history); - modifierIdNew = em.merge(modifierIdNew); - } - if (requirementIdOld != null && !requirementIdOld.equals(requirementIdNew)) { - requirementIdOld.getHistoryList().remove(history); - requirementIdOld = em.merge(requirementIdOld); - } - if (requirementIdNew != null && !requirementIdNew.equals(requirementIdOld)) { - requirementIdNew.getHistoryList().add(history); - requirementIdNew = em.merge(requirementIdNew); - } - if (projectIdOld != null && !projectIdOld.equals(projectIdNew)) { - projectIdOld.getHistoryList().remove(history); - projectIdOld = em.merge(projectIdOld); - } - if (projectIdNew != null && !projectIdNew.equals(projectIdOld)) { - projectIdNew.getHistoryList().add(history); - projectIdNew = em.merge(projectIdNew); - } - if (stepOld != null && !stepOld.equals(stepNew)) { - stepOld.getHistoryList().remove(history); - stepOld = em.merge(stepOld); - } - if (stepNew != null && !stepNew.equals(stepOld)) { - stepNew.getHistoryList().add(history); - stepNew = em.merge(stepNew); - } - if (vmSettingIdOld != null && !vmSettingIdOld.equals(vmSettingIdNew)) { - vmSettingIdOld.getHistoryList().remove(history); - vmSettingIdOld = em.merge(vmSettingIdOld); - } - if (vmSettingIdNew != null && !vmSettingIdNew.equals(vmSettingIdOld)) { - vmSettingIdNew.getHistoryList().add(history); - vmSettingIdNew = em.merge(vmSettingIdNew); - } - for (HistoryField historyFieldListNewHistoryField : historyFieldListNew) { - if (!historyFieldListOld.contains(historyFieldListNewHistoryField)) { - History oldHistoryOfHistoryFieldListNewHistoryField = historyFieldListNewHistoryField.getHistory(); - historyFieldListNewHistoryField.setHistory(history); - historyFieldListNewHistoryField = em.merge(historyFieldListNewHistoryField); - if (oldHistoryOfHistoryFieldListNewHistoryField != null && !oldHistoryOfHistoryFieldListNewHistoryField.equals(history)) { - oldHistoryOfHistoryFieldListNewHistoryField.getHistoryFieldList().remove(historyFieldListNewHistoryField); - oldHistoryOfHistoryFieldListNewHistoryField = em.merge(oldHistoryOfHistoryFieldListNewHistoryField); - } - } - } - for (Baseline baselineListOldBaseline : baselineListOld) { - if (!baselineListNew.contains(baselineListOldBaseline)) { - baselineListOldBaseline.getHistoryList().remove(history); - baselineListOldBaseline = em.merge(baselineListOldBaseline); - } - } - for (Baseline baselineListNewBaseline : baselineListNew) { - if (!baselineListOld.contains(baselineListNewBaseline)) { - baselineListNewBaseline.getHistoryList().add(history); - baselineListNewBaseline = em.merge(baselineListNewBaseline); - } - } - for (ExecutionStep executionStepListOldExecutionStep : executionStepListOld) { - if (!executionStepListNew.contains(executionStepListOldExecutionStep)) { - executionStepListOldExecutionStep.getHistoryList().remove(history); - executionStepListOldExecutionStep = em.merge(executionStepListOldExecutionStep); - } - } - for (ExecutionStep executionStepListNewExecutionStep : executionStepListNew) { - if (!executionStepListOld.contains(executionStepListNewExecutionStep)) { - executionStepListNewExecutionStep.getHistoryList().add(history); - executionStepListNewExecutionStep = em.merge(executionStepListNewExecutionStep); - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - Integer id = history.getId(); - if (findHistory(id) == null) { - throw new NonexistentEntityException("The history with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - History history; - try { - history = em.getReference(History.class, id); - history.getId(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The history with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List historyFieldListOrphanCheck = history.getHistoryFieldList(); - for (HistoryField historyFieldListOrphanCheckHistoryField : historyFieldListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This History (" + history + ") cannot be destroyed since the HistoryField " + historyFieldListOrphanCheckHistoryField + " in its historyFieldList field has a non-nullable history field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - VmUser modifierId = history.getModifierId(); - if (modifierId != null) { - modifierId.getHistoryModificationList().remove(history); - modifierId = em.merge(modifierId); - } - Requirement requirementId = history.getRequirementId(); - if (requirementId != null) { - requirementId.getHistoryList().remove(history); - requirementId = em.merge(requirementId); - } - Project projectId = history.getProjectId(); - if (projectId != null) { - projectId.getHistoryList().remove(history); - projectId = em.merge(projectId); - } - Step step = history.getStep(); - if (step != null) { - step.getHistoryList().remove(history); - step = em.merge(step); - } - VmSetting vmSettingId = history.getVmSettingId(); - if (vmSettingId != null) { - vmSettingId.getHistoryList().remove(history); - vmSettingId = em.merge(vmSettingId); - } - List baselineList = history.getBaselineList(); - for (Baseline baselineListBaseline : baselineList) { - baselineListBaseline.getHistoryList().remove(history); - baselineListBaseline = em.merge(baselineListBaseline); - } - List executionStepList = history.getExecutionStepList(); - for (ExecutionStep executionStepListExecutionStep : executionStepList) { - executionStepListExecutionStep.getHistoryList().remove(history); - executionStepListExecutionStep = em.merge(executionStepListExecutionStep); - } - em.remove(history); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findHistoryEntities() { - return findHistoryEntities(true, -1, -1); - } - - public List findHistoryEntities(int maxResults, int firstResult) { - return findHistoryEntities(false, maxResults, firstResult); - } - - private List findHistoryEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(History.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public History findHistory(Integer id) { - EntityManager em = getEntityManager(); - try { - return em.find(History.class, id); - } - finally { - em.close(); - } - } - - public int getHistoryCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(History.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.VmUser; +import com.validation.manager.core.db.Requirement; +import com.validation.manager.core.db.Project; +import com.validation.manager.core.db.Step; +import com.validation.manager.core.db.VmSetting; +import com.validation.manager.core.db.HistoryField; +import java.util.ArrayList; +import java.util.List; +import com.validation.manager.core.db.Baseline; +import com.validation.manager.core.db.ExecutionStep; +import com.validation.manager.core.db.History; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class HistoryJpaController implements Serializable { + + public HistoryJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(History history) { + if (history.getHistoryFieldList() == null) { + history.setHistoryFieldList(new ArrayList<>()); + } + if (history.getBaselineList() == null) { + history.setBaselineList(new ArrayList<>()); + } + if (history.getExecutionStepList() == null) { + history.setExecutionStepList(new ArrayList<>()); + } + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + VmUser modifierId = history.getModifierId(); + if (modifierId != null) { + modifierId = em.getReference(modifierId.getClass(), modifierId.getId()); + history.setModifierId(modifierId); + } + Requirement requirementId = history.getRequirementId(); + if (requirementId != null) { + requirementId = em.getReference(requirementId.getClass(), requirementId.getId()); + history.setRequirementId(requirementId); + } + Project projectId = history.getProjectId(); + if (projectId != null) { + projectId = em.getReference(projectId.getClass(), projectId.getId()); + history.setProjectId(projectId); + } + Step step = history.getStep(); + if (step != null) { + step = em.getReference(step.getClass(), step.getStepPK()); + history.setStep(step); + } + VmSetting vmSettingId = history.getVmSettingId(); + if (vmSettingId != null) { + vmSettingId = em.getReference(vmSettingId.getClass(), vmSettingId.getId()); + history.setVmSettingId(vmSettingId); + } + VmUser vmUserId = history.getVmUserId(); + if (vmUserId != null) { + vmUserId = em.getReference(vmUserId.getClass(), vmUserId.getId()); + history.setVmUserId(vmUserId); + } + List attachedHistoryFieldList = new ArrayList<>(); + for (HistoryField historyFieldListHistoryFieldToAttach : history.getHistoryFieldList()) { + historyFieldListHistoryFieldToAttach = em.getReference(historyFieldListHistoryFieldToAttach.getClass(), historyFieldListHistoryFieldToAttach.getHistoryFieldPK()); + attachedHistoryFieldList.add(historyFieldListHistoryFieldToAttach); + } + history.setHistoryFieldList(attachedHistoryFieldList); + List attachedBaselineList = new ArrayList<>(); + for (Baseline baselineListBaselineToAttach : history.getBaselineList()) { + baselineListBaselineToAttach = em.getReference(baselineListBaselineToAttach.getClass(), baselineListBaselineToAttach.getId()); + attachedBaselineList.add(baselineListBaselineToAttach); + } + history.setBaselineList(attachedBaselineList); + List attachedExecutionStepList = new ArrayList<>(); + for (ExecutionStep executionStepListExecutionStepToAttach : history.getExecutionStepList()) { + executionStepListExecutionStepToAttach = em.getReference(executionStepListExecutionStepToAttach.getClass(), executionStepListExecutionStepToAttach.getExecutionStepPK()); + attachedExecutionStepList.add(executionStepListExecutionStepToAttach); + } + history.setExecutionStepList(attachedExecutionStepList); + em.persist(history); + if (modifierId != null) { + modifierId.getHistoryModificationList().add(history); + modifierId = em.merge(modifierId); + } + if (requirementId != null) { + requirementId.getHistoryList().add(history); + requirementId = em.merge(requirementId); + } + if (projectId != null) { + projectId.getHistoryList().add(history); + projectId = em.merge(projectId); + } + if (step != null) { + step.getHistoryList().add(history); + step = em.merge(step); + } + if (vmSettingId != null) { + vmSettingId.getHistoryList().add(history); + vmSettingId = em.merge(vmSettingId); + } + if (vmUserId != null) { + vmUserId.getHistoryModificationList().add(history); + vmUserId = em.merge(vmUserId); + } + for (HistoryField historyFieldListHistoryField : history.getHistoryFieldList()) { + History oldHistoryOfHistoryFieldListHistoryField = historyFieldListHistoryField.getHistory(); + historyFieldListHistoryField.setHistory(history); + historyFieldListHistoryField = em.merge(historyFieldListHistoryField); + if (oldHistoryOfHistoryFieldListHistoryField != null) { + oldHistoryOfHistoryFieldListHistoryField.getHistoryFieldList().remove(historyFieldListHistoryField); + oldHistoryOfHistoryFieldListHistoryField = em.merge(oldHistoryOfHistoryFieldListHistoryField); + } + } + for (Baseline baselineListBaseline : history.getBaselineList()) { + baselineListBaseline.getHistoryList().add(history); + baselineListBaseline = em.merge(baselineListBaseline); + } + for (ExecutionStep executionStepListExecutionStep : history.getExecutionStepList()) { + executionStepListExecutionStep.getHistoryList().add(history); + executionStepListExecutionStep = em.merge(executionStepListExecutionStep); + } + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(History history) throws IllegalOrphanException, NonexistentEntityException, Exception { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + History persistentHistory = em.find(History.class, history.getId()); + VmUser modifierIdOld = persistentHistory.getModifierId(); + VmUser modifierIdNew = history.getModifierId(); + Requirement requirementIdOld = persistentHistory.getRequirementId(); + Requirement requirementIdNew = history.getRequirementId(); + Project projectIdOld = persistentHistory.getProjectId(); + Project projectIdNew = history.getProjectId(); + Step stepOld = persistentHistory.getStep(); + Step stepNew = history.getStep(); + VmSetting vmSettingIdOld = persistentHistory.getVmSettingId(); + VmSetting vmSettingIdNew = history.getVmSettingId(); + VmUser vmUserIdOld = persistentHistory.getVmUserId(); + VmUser vmUserIdNew = history.getVmUserId(); + List historyFieldListOld = persistentHistory.getHistoryFieldList(); + List historyFieldListNew = history.getHistoryFieldList(); + List baselineListOld = persistentHistory.getBaselineList(); + List baselineListNew = history.getBaselineList(); + List executionStepListOld = persistentHistory.getExecutionStepList(); + List executionStepListNew = history.getExecutionStepList(); + List illegalOrphanMessages = null; + for (HistoryField historyFieldListOldHistoryField : historyFieldListOld) { + if (!historyFieldListNew.contains(historyFieldListOldHistoryField)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain HistoryField " + historyFieldListOldHistoryField + " since its history field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + if (modifierIdNew != null) { + modifierIdNew = em.getReference(modifierIdNew.getClass(), modifierIdNew.getId()); + history.setModifierId(modifierIdNew); + } + if (requirementIdNew != null) { + requirementIdNew = em.getReference(requirementIdNew.getClass(), requirementIdNew.getId()); + history.setRequirementId(requirementIdNew); + } + if (projectIdNew != null) { + projectIdNew = em.getReference(projectIdNew.getClass(), projectIdNew.getId()); + history.setProjectId(projectIdNew); + } + if (stepNew != null) { + stepNew = em.getReference(stepNew.getClass(), stepNew.getStepPK()); + history.setStep(stepNew); + } + if (vmSettingIdNew != null) { + vmSettingIdNew = em.getReference(vmSettingIdNew.getClass(), vmSettingIdNew.getId()); + history.setVmSettingId(vmSettingIdNew); + } + if (vmUserIdNew != null) { + vmUserIdNew = em.getReference(vmUserIdNew.getClass(), vmUserIdNew.getId()); + history.setVmUserId(vmUserIdNew); + } + List attachedHistoryFieldListNew = new ArrayList<>(); + for (HistoryField historyFieldListNewHistoryFieldToAttach : historyFieldListNew) { + historyFieldListNewHistoryFieldToAttach = em.getReference(historyFieldListNewHistoryFieldToAttach.getClass(), historyFieldListNewHistoryFieldToAttach.getHistoryFieldPK()); + attachedHistoryFieldListNew.add(historyFieldListNewHistoryFieldToAttach); + } + historyFieldListNew = attachedHistoryFieldListNew; + history.setHistoryFieldList(historyFieldListNew); + List attachedBaselineListNew = new ArrayList<>(); + for (Baseline baselineListNewBaselineToAttach : baselineListNew) { + baselineListNewBaselineToAttach = em.getReference(baselineListNewBaselineToAttach.getClass(), baselineListNewBaselineToAttach.getId()); + attachedBaselineListNew.add(baselineListNewBaselineToAttach); + } + baselineListNew = attachedBaselineListNew; + history.setBaselineList(baselineListNew); + List attachedExecutionStepListNew = new ArrayList<>(); + for (ExecutionStep executionStepListNewExecutionStepToAttach : executionStepListNew) { + executionStepListNewExecutionStepToAttach = em.getReference(executionStepListNewExecutionStepToAttach.getClass(), executionStepListNewExecutionStepToAttach.getExecutionStepPK()); + attachedExecutionStepListNew.add(executionStepListNewExecutionStepToAttach); + } + executionStepListNew = attachedExecutionStepListNew; + history.setExecutionStepList(executionStepListNew); + history = em.merge(history); + if (modifierIdOld != null && !modifierIdOld.equals(modifierIdNew)) { + modifierIdOld.getHistoryModificationList().remove(history); + modifierIdOld = em.merge(modifierIdOld); + } + if (modifierIdNew != null && !modifierIdNew.equals(modifierIdOld)) { + modifierIdNew.getHistoryModificationList().add(history); + modifierIdNew = em.merge(modifierIdNew); + } + if (requirementIdOld != null && !requirementIdOld.equals(requirementIdNew)) { + requirementIdOld.getHistoryList().remove(history); + requirementIdOld = em.merge(requirementIdOld); + } + if (requirementIdNew != null && !requirementIdNew.equals(requirementIdOld)) { + requirementIdNew.getHistoryList().add(history); + requirementIdNew = em.merge(requirementIdNew); + } + if (projectIdOld != null && !projectIdOld.equals(projectIdNew)) { + projectIdOld.getHistoryList().remove(history); + projectIdOld = em.merge(projectIdOld); + } + if (projectIdNew != null && !projectIdNew.equals(projectIdOld)) { + projectIdNew.getHistoryList().add(history); + projectIdNew = em.merge(projectIdNew); + } + if (stepOld != null && !stepOld.equals(stepNew)) { + stepOld.getHistoryList().remove(history); + stepOld = em.merge(stepOld); + } + if (stepNew != null && !stepNew.equals(stepOld)) { + stepNew.getHistoryList().add(history); + stepNew = em.merge(stepNew); + } + if (vmSettingIdOld != null && !vmSettingIdOld.equals(vmSettingIdNew)) { + vmSettingIdOld.getHistoryList().remove(history); + vmSettingIdOld = em.merge(vmSettingIdOld); + } + if (vmSettingIdNew != null && !vmSettingIdNew.equals(vmSettingIdOld)) { + vmSettingIdNew.getHistoryList().add(history); + vmSettingIdNew = em.merge(vmSettingIdNew); + } + if (vmUserIdOld != null && !vmUserIdOld.equals(vmUserIdNew)) { + vmUserIdOld.getHistoryModificationList().remove(history); + vmUserIdOld = em.merge(vmUserIdOld); + } + if (vmUserIdNew != null && !vmUserIdNew.equals(vmUserIdOld)) { + vmUserIdNew.getHistoryModificationList().add(history); + vmUserIdNew = em.merge(vmUserIdNew); + } + for (HistoryField historyFieldListNewHistoryField : historyFieldListNew) { + if (!historyFieldListOld.contains(historyFieldListNewHistoryField)) { + History oldHistoryOfHistoryFieldListNewHistoryField = historyFieldListNewHistoryField.getHistory(); + historyFieldListNewHistoryField.setHistory(history); + historyFieldListNewHistoryField = em.merge(historyFieldListNewHistoryField); + if (oldHistoryOfHistoryFieldListNewHistoryField != null && !oldHistoryOfHistoryFieldListNewHistoryField.equals(history)) { + oldHistoryOfHistoryFieldListNewHistoryField.getHistoryFieldList().remove(historyFieldListNewHistoryField); + oldHistoryOfHistoryFieldListNewHistoryField = em.merge(oldHistoryOfHistoryFieldListNewHistoryField); + } + } + } + for (Baseline baselineListOldBaseline : baselineListOld) { + if (!baselineListNew.contains(baselineListOldBaseline)) { + baselineListOldBaseline.getHistoryList().remove(history); + baselineListOldBaseline = em.merge(baselineListOldBaseline); + } + } + for (Baseline baselineListNewBaseline : baselineListNew) { + if (!baselineListOld.contains(baselineListNewBaseline)) { + baselineListNewBaseline.getHistoryList().add(history); + baselineListNewBaseline = em.merge(baselineListNewBaseline); + } + } + for (ExecutionStep executionStepListOldExecutionStep : executionStepListOld) { + if (!executionStepListNew.contains(executionStepListOldExecutionStep)) { + executionStepListOldExecutionStep.getHistoryList().remove(history); + executionStepListOldExecutionStep = em.merge(executionStepListOldExecutionStep); + } + } + for (ExecutionStep executionStepListNewExecutionStep : executionStepListNew) { + if (!executionStepListOld.contains(executionStepListNewExecutionStep)) { + executionStepListNewExecutionStep.getHistoryList().add(history); + executionStepListNewExecutionStep = em.merge(executionStepListNewExecutionStep); + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + Integer id = history.getId(); + if (findHistory(id) == null) { + throw new NonexistentEntityException("The history with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + History history; + try { + history = em.getReference(History.class, id); + history.getId(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The history with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List historyFieldListOrphanCheck = history.getHistoryFieldList(); + for (HistoryField historyFieldListOrphanCheckHistoryField : historyFieldListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This History (" + history + ") cannot be destroyed since the HistoryField " + historyFieldListOrphanCheckHistoryField + " in its historyFieldList field has a non-nullable history field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + VmUser modifierId = history.getModifierId(); + if (modifierId != null) { + modifierId.getHistoryModificationList().remove(history); + modifierId = em.merge(modifierId); + } + Requirement requirementId = history.getRequirementId(); + if (requirementId != null) { + requirementId.getHistoryList().remove(history); + requirementId = em.merge(requirementId); + } + Project projectId = history.getProjectId(); + if (projectId != null) { + projectId.getHistoryList().remove(history); + projectId = em.merge(projectId); + } + Step step = history.getStep(); + if (step != null) { + step.getHistoryList().remove(history); + step = em.merge(step); + } + VmSetting vmSettingId = history.getVmSettingId(); + if (vmSettingId != null) { + vmSettingId.getHistoryList().remove(history); + vmSettingId = em.merge(vmSettingId); + } + VmUser vmUserId = history.getVmUserId(); + if (vmUserId != null) { + vmUserId.getHistoryModificationList().remove(history); + vmUserId = em.merge(vmUserId); + } + List baselineList = history.getBaselineList(); + for (Baseline baselineListBaseline : baselineList) { + baselineListBaseline.getHistoryList().remove(history); + baselineListBaseline = em.merge(baselineListBaseline); + } + List executionStepList = history.getExecutionStepList(); + for (ExecutionStep executionStepListExecutionStep : executionStepList) { + executionStepListExecutionStep.getHistoryList().remove(history); + executionStepListExecutionStep = em.merge(executionStepListExecutionStep); + } + em.remove(history); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findHistoryEntities() { + return findHistoryEntities(true, -1, -1); + } + + public List findHistoryEntities(int maxResults, int firstResult) { + return findHistoryEntities(false, maxResults, firstResult); + } + + private List findHistoryEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(History.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public History findHistory(Integer id) { + EntityManager em = getEntityManager(); + try { + return em.find(History.class, id); + } + finally { + em.close(); + } + } + + public int getHistoryCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(History.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/InvestigationJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/InvestigationJpaController.java index 40d5a13b..16cf6165 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/InvestigationJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/InvestigationJpaController.java @@ -13,263 +13,263 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.UserHasInvestigation; -import java.util.ArrayList; -import java.util.List; -import com.validation.manager.core.db.ExceptionHasInvestigation; -import com.validation.manager.core.db.Investigation; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class InvestigationJpaController implements Serializable { - - public InvestigationJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(Investigation investigation) { - if (investigation.getUserHasInvestigationList() == null) { - investigation.setUserHasInvestigationList(new ArrayList()); - } - if (investigation.getExceptionHasInvestigationList() == null) { - investigation.setExceptionHasInvestigationList(new ArrayList()); - } - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - List attachedUserHasInvestigationList = new ArrayList(); - for (UserHasInvestigation userHasInvestigationListUserHasInvestigationToAttach : investigation.getUserHasInvestigationList()) { - userHasInvestigationListUserHasInvestigationToAttach = em.getReference(userHasInvestigationListUserHasInvestigationToAttach.getClass(), userHasInvestigationListUserHasInvestigationToAttach.getUserHasInvestigationPK()); - attachedUserHasInvestigationList.add(userHasInvestigationListUserHasInvestigationToAttach); - } - investigation.setUserHasInvestigationList(attachedUserHasInvestigationList); - List attachedExceptionHasInvestigationList = new ArrayList(); - for (ExceptionHasInvestigation exceptionHasInvestigationListExceptionHasInvestigationToAttach : investigation.getExceptionHasInvestigationList()) { - exceptionHasInvestigationListExceptionHasInvestigationToAttach = em.getReference(exceptionHasInvestigationListExceptionHasInvestigationToAttach.getClass(), exceptionHasInvestigationListExceptionHasInvestigationToAttach.getExceptionHasInvestigationPK()); - attachedExceptionHasInvestigationList.add(exceptionHasInvestigationListExceptionHasInvestigationToAttach); - } - investigation.setExceptionHasInvestigationList(attachedExceptionHasInvestigationList); - em.persist(investigation); - for (UserHasInvestigation userHasInvestigationListUserHasInvestigation : investigation.getUserHasInvestigationList()) { - Investigation oldInvestigationOfUserHasInvestigationListUserHasInvestigation = userHasInvestigationListUserHasInvestigation.getInvestigation(); - userHasInvestigationListUserHasInvestigation.setInvestigation(investigation); - userHasInvestigationListUserHasInvestigation = em.merge(userHasInvestigationListUserHasInvestigation); - if (oldInvestigationOfUserHasInvestigationListUserHasInvestigation != null) { - oldInvestigationOfUserHasInvestigationListUserHasInvestigation.getUserHasInvestigationList().remove(userHasInvestigationListUserHasInvestigation); - oldInvestigationOfUserHasInvestigationListUserHasInvestigation = em.merge(oldInvestigationOfUserHasInvestigationListUserHasInvestigation); - } - } - for (ExceptionHasInvestigation exceptionHasInvestigationListExceptionHasInvestigation : investigation.getExceptionHasInvestigationList()) { - Investigation oldInvestigationOfExceptionHasInvestigationListExceptionHasInvestigation = exceptionHasInvestigationListExceptionHasInvestigation.getInvestigation(); - exceptionHasInvestigationListExceptionHasInvestigation.setInvestigation(investigation); - exceptionHasInvestigationListExceptionHasInvestigation = em.merge(exceptionHasInvestigationListExceptionHasInvestigation); - if (oldInvestigationOfExceptionHasInvestigationListExceptionHasInvestigation != null) { - oldInvestigationOfExceptionHasInvestigationListExceptionHasInvestigation.getExceptionHasInvestigationList().remove(exceptionHasInvestigationListExceptionHasInvestigation); - oldInvestigationOfExceptionHasInvestigationListExceptionHasInvestigation = em.merge(oldInvestigationOfExceptionHasInvestigationListExceptionHasInvestigation); - } - } - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(Investigation investigation) throws IllegalOrphanException, NonexistentEntityException, Exception { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - Investigation persistentInvestigation = em.find(Investigation.class, investigation.getId()); - List userHasInvestigationListOld = persistentInvestigation.getUserHasInvestigationList(); - List userHasInvestigationListNew = investigation.getUserHasInvestigationList(); - List exceptionHasInvestigationListOld = persistentInvestigation.getExceptionHasInvestigationList(); - List exceptionHasInvestigationListNew = investigation.getExceptionHasInvestigationList(); - List illegalOrphanMessages = null; - for (UserHasInvestigation userHasInvestigationListOldUserHasInvestigation : userHasInvestigationListOld) { - if (!userHasInvestigationListNew.contains(userHasInvestigationListOldUserHasInvestigation)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain UserHasInvestigation " + userHasInvestigationListOldUserHasInvestigation + " since its investigation field is not nullable."); - } - } - for (ExceptionHasInvestigation exceptionHasInvestigationListOldExceptionHasInvestigation : exceptionHasInvestigationListOld) { - if (!exceptionHasInvestigationListNew.contains(exceptionHasInvestigationListOldExceptionHasInvestigation)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain ExceptionHasInvestigation " + exceptionHasInvestigationListOldExceptionHasInvestigation + " since its investigation field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - List attachedUserHasInvestigationListNew = new ArrayList(); - for (UserHasInvestigation userHasInvestigationListNewUserHasInvestigationToAttach : userHasInvestigationListNew) { - userHasInvestigationListNewUserHasInvestigationToAttach = em.getReference(userHasInvestigationListNewUserHasInvestigationToAttach.getClass(), userHasInvestigationListNewUserHasInvestigationToAttach.getUserHasInvestigationPK()); - attachedUserHasInvestigationListNew.add(userHasInvestigationListNewUserHasInvestigationToAttach); - } - userHasInvestigationListNew = attachedUserHasInvestigationListNew; - investigation.setUserHasInvestigationList(userHasInvestigationListNew); - List attachedExceptionHasInvestigationListNew = new ArrayList(); - for (ExceptionHasInvestigation exceptionHasInvestigationListNewExceptionHasInvestigationToAttach : exceptionHasInvestigationListNew) { - exceptionHasInvestigationListNewExceptionHasInvestigationToAttach = em.getReference(exceptionHasInvestigationListNewExceptionHasInvestigationToAttach.getClass(), exceptionHasInvestigationListNewExceptionHasInvestigationToAttach.getExceptionHasInvestigationPK()); - attachedExceptionHasInvestigationListNew.add(exceptionHasInvestigationListNewExceptionHasInvestigationToAttach); - } - exceptionHasInvestigationListNew = attachedExceptionHasInvestigationListNew; - investigation.setExceptionHasInvestigationList(exceptionHasInvestigationListNew); - investigation = em.merge(investigation); - for (UserHasInvestigation userHasInvestigationListNewUserHasInvestigation : userHasInvestigationListNew) { - if (!userHasInvestigationListOld.contains(userHasInvestigationListNewUserHasInvestigation)) { - Investigation oldInvestigationOfUserHasInvestigationListNewUserHasInvestigation = userHasInvestigationListNewUserHasInvestigation.getInvestigation(); - userHasInvestigationListNewUserHasInvestigation.setInvestigation(investigation); - userHasInvestigationListNewUserHasInvestigation = em.merge(userHasInvestigationListNewUserHasInvestigation); - if (oldInvestigationOfUserHasInvestigationListNewUserHasInvestigation != null && !oldInvestigationOfUserHasInvestigationListNewUserHasInvestigation.equals(investigation)) { - oldInvestigationOfUserHasInvestigationListNewUserHasInvestigation.getUserHasInvestigationList().remove(userHasInvestigationListNewUserHasInvestigation); - oldInvestigationOfUserHasInvestigationListNewUserHasInvestigation = em.merge(oldInvestigationOfUserHasInvestigationListNewUserHasInvestigation); - } - } - } - for (ExceptionHasInvestigation exceptionHasInvestigationListNewExceptionHasInvestigation : exceptionHasInvestigationListNew) { - if (!exceptionHasInvestigationListOld.contains(exceptionHasInvestigationListNewExceptionHasInvestigation)) { - Investigation oldInvestigationOfExceptionHasInvestigationListNewExceptionHasInvestigation = exceptionHasInvestigationListNewExceptionHasInvestigation.getInvestigation(); - exceptionHasInvestigationListNewExceptionHasInvestigation.setInvestigation(investigation); - exceptionHasInvestigationListNewExceptionHasInvestigation = em.merge(exceptionHasInvestigationListNewExceptionHasInvestigation); - if (oldInvestigationOfExceptionHasInvestigationListNewExceptionHasInvestigation != null && !oldInvestigationOfExceptionHasInvestigationListNewExceptionHasInvestigation.equals(investigation)) { - oldInvestigationOfExceptionHasInvestigationListNewExceptionHasInvestigation.getExceptionHasInvestigationList().remove(exceptionHasInvestigationListNewExceptionHasInvestigation); - oldInvestigationOfExceptionHasInvestigationListNewExceptionHasInvestigation = em.merge(oldInvestigationOfExceptionHasInvestigationListNewExceptionHasInvestigation); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - Integer id = investigation.getId(); - if (findInvestigation(id) == null) { - throw new NonexistentEntityException("The investigation with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - Investigation investigation; - try { - investigation = em.getReference(Investigation.class, id); - investigation.getId(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The investigation with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List userHasInvestigationListOrphanCheck = investigation.getUserHasInvestigationList(); - for (UserHasInvestigation userHasInvestigationListOrphanCheckUserHasInvestigation : userHasInvestigationListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This Investigation (" + investigation + ") cannot be destroyed since the UserHasInvestigation " + userHasInvestigationListOrphanCheckUserHasInvestigation + " in its userHasInvestigationList field has a non-nullable investigation field."); - } - List exceptionHasInvestigationListOrphanCheck = investigation.getExceptionHasInvestigationList(); - for (ExceptionHasInvestigation exceptionHasInvestigationListOrphanCheckExceptionHasInvestigation : exceptionHasInvestigationListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This Investigation (" + investigation + ") cannot be destroyed since the ExceptionHasInvestigation " + exceptionHasInvestigationListOrphanCheckExceptionHasInvestigation + " in its exceptionHasInvestigationList field has a non-nullable investigation field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - em.remove(investigation); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findInvestigationEntities() { - return findInvestigationEntities(true, -1, -1); - } - - public List findInvestigationEntities(int maxResults, int firstResult) { - return findInvestigationEntities(false, maxResults, firstResult); - } - - private List findInvestigationEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(Investigation.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public Investigation findInvestigation(Integer id) { - EntityManager em = getEntityManager(); - try { - return em.find(Investigation.class, id); - } - finally { - em.close(); - } - } - - public int getInvestigationCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(Investigation.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.UserHasInvestigation; +import java.util.ArrayList; +import java.util.List; +import com.validation.manager.core.db.ExceptionHasInvestigation; +import com.validation.manager.core.db.Investigation; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class InvestigationJpaController implements Serializable { + + public InvestigationJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(Investigation investigation) { + if (investigation.getUserHasInvestigationList() == null) { + investigation.setUserHasInvestigationList(new ArrayList<>()); + } + if (investigation.getExceptionHasInvestigationList() == null) { + investigation.setExceptionHasInvestigationList(new ArrayList<>()); + } + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + List attachedUserHasInvestigationList = new ArrayList<>(); + for (UserHasInvestigation userHasInvestigationListUserHasInvestigationToAttach : investigation.getUserHasInvestigationList()) { + userHasInvestigationListUserHasInvestigationToAttach = em.getReference(userHasInvestigationListUserHasInvestigationToAttach.getClass(), userHasInvestigationListUserHasInvestigationToAttach.getUserHasInvestigationPK()); + attachedUserHasInvestigationList.add(userHasInvestigationListUserHasInvestigationToAttach); + } + investigation.setUserHasInvestigationList(attachedUserHasInvestigationList); + List attachedExceptionHasInvestigationList = new ArrayList<>(); + for (ExceptionHasInvestigation exceptionHasInvestigationListExceptionHasInvestigationToAttach : investigation.getExceptionHasInvestigationList()) { + exceptionHasInvestigationListExceptionHasInvestigationToAttach = em.getReference(exceptionHasInvestigationListExceptionHasInvestigationToAttach.getClass(), exceptionHasInvestigationListExceptionHasInvestigationToAttach.getExceptionHasInvestigationPK()); + attachedExceptionHasInvestigationList.add(exceptionHasInvestigationListExceptionHasInvestigationToAttach); + } + investigation.setExceptionHasInvestigationList(attachedExceptionHasInvestigationList); + em.persist(investigation); + for (UserHasInvestigation userHasInvestigationListUserHasInvestigation : investigation.getUserHasInvestigationList()) { + Investigation oldInvestigationOfUserHasInvestigationListUserHasInvestigation = userHasInvestigationListUserHasInvestigation.getInvestigation(); + userHasInvestigationListUserHasInvestigation.setInvestigation(investigation); + userHasInvestigationListUserHasInvestigation = em.merge(userHasInvestigationListUserHasInvestigation); + if (oldInvestigationOfUserHasInvestigationListUserHasInvestigation != null) { + oldInvestigationOfUserHasInvestigationListUserHasInvestigation.getUserHasInvestigationList().remove(userHasInvestigationListUserHasInvestigation); + oldInvestigationOfUserHasInvestigationListUserHasInvestigation = em.merge(oldInvestigationOfUserHasInvestigationListUserHasInvestigation); + } + } + for (ExceptionHasInvestigation exceptionHasInvestigationListExceptionHasInvestigation : investigation.getExceptionHasInvestigationList()) { + Investigation oldInvestigationOfExceptionHasInvestigationListExceptionHasInvestigation = exceptionHasInvestigationListExceptionHasInvestigation.getInvestigation(); + exceptionHasInvestigationListExceptionHasInvestigation.setInvestigation(investigation); + exceptionHasInvestigationListExceptionHasInvestigation = em.merge(exceptionHasInvestigationListExceptionHasInvestigation); + if (oldInvestigationOfExceptionHasInvestigationListExceptionHasInvestigation != null) { + oldInvestigationOfExceptionHasInvestigationListExceptionHasInvestigation.getExceptionHasInvestigationList().remove(exceptionHasInvestigationListExceptionHasInvestigation); + oldInvestigationOfExceptionHasInvestigationListExceptionHasInvestigation = em.merge(oldInvestigationOfExceptionHasInvestigationListExceptionHasInvestigation); + } + } + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(Investigation investigation) throws IllegalOrphanException, NonexistentEntityException, Exception { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + Investigation persistentInvestigation = em.find(Investigation.class, investigation.getId()); + List userHasInvestigationListOld = persistentInvestigation.getUserHasInvestigationList(); + List userHasInvestigationListNew = investigation.getUserHasInvestigationList(); + List exceptionHasInvestigationListOld = persistentInvestigation.getExceptionHasInvestigationList(); + List exceptionHasInvestigationListNew = investigation.getExceptionHasInvestigationList(); + List illegalOrphanMessages = null; + for (UserHasInvestigation userHasInvestigationListOldUserHasInvestigation : userHasInvestigationListOld) { + if (!userHasInvestigationListNew.contains(userHasInvestigationListOldUserHasInvestigation)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain UserHasInvestigation " + userHasInvestigationListOldUserHasInvestigation + " since its investigation field is not nullable."); + } + } + for (ExceptionHasInvestigation exceptionHasInvestigationListOldExceptionHasInvestigation : exceptionHasInvestigationListOld) { + if (!exceptionHasInvestigationListNew.contains(exceptionHasInvestigationListOldExceptionHasInvestigation)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain ExceptionHasInvestigation " + exceptionHasInvestigationListOldExceptionHasInvestigation + " since its investigation field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + List attachedUserHasInvestigationListNew = new ArrayList<>(); + for (UserHasInvestigation userHasInvestigationListNewUserHasInvestigationToAttach : userHasInvestigationListNew) { + userHasInvestigationListNewUserHasInvestigationToAttach = em.getReference(userHasInvestigationListNewUserHasInvestigationToAttach.getClass(), userHasInvestigationListNewUserHasInvestigationToAttach.getUserHasInvestigationPK()); + attachedUserHasInvestigationListNew.add(userHasInvestigationListNewUserHasInvestigationToAttach); + } + userHasInvestigationListNew = attachedUserHasInvestigationListNew; + investigation.setUserHasInvestigationList(userHasInvestigationListNew); + List attachedExceptionHasInvestigationListNew = new ArrayList<>(); + for (ExceptionHasInvestigation exceptionHasInvestigationListNewExceptionHasInvestigationToAttach : exceptionHasInvestigationListNew) { + exceptionHasInvestigationListNewExceptionHasInvestigationToAttach = em.getReference(exceptionHasInvestigationListNewExceptionHasInvestigationToAttach.getClass(), exceptionHasInvestigationListNewExceptionHasInvestigationToAttach.getExceptionHasInvestigationPK()); + attachedExceptionHasInvestigationListNew.add(exceptionHasInvestigationListNewExceptionHasInvestigationToAttach); + } + exceptionHasInvestigationListNew = attachedExceptionHasInvestigationListNew; + investigation.setExceptionHasInvestigationList(exceptionHasInvestigationListNew); + investigation = em.merge(investigation); + for (UserHasInvestigation userHasInvestigationListNewUserHasInvestigation : userHasInvestigationListNew) { + if (!userHasInvestigationListOld.contains(userHasInvestigationListNewUserHasInvestigation)) { + Investigation oldInvestigationOfUserHasInvestigationListNewUserHasInvestigation = userHasInvestigationListNewUserHasInvestigation.getInvestigation(); + userHasInvestigationListNewUserHasInvestigation.setInvestigation(investigation); + userHasInvestigationListNewUserHasInvestigation = em.merge(userHasInvestigationListNewUserHasInvestigation); + if (oldInvestigationOfUserHasInvestigationListNewUserHasInvestigation != null && !oldInvestigationOfUserHasInvestigationListNewUserHasInvestigation.equals(investigation)) { + oldInvestigationOfUserHasInvestigationListNewUserHasInvestigation.getUserHasInvestigationList().remove(userHasInvestigationListNewUserHasInvestigation); + oldInvestigationOfUserHasInvestigationListNewUserHasInvestigation = em.merge(oldInvestigationOfUserHasInvestigationListNewUserHasInvestigation); + } + } + } + for (ExceptionHasInvestigation exceptionHasInvestigationListNewExceptionHasInvestigation : exceptionHasInvestigationListNew) { + if (!exceptionHasInvestigationListOld.contains(exceptionHasInvestigationListNewExceptionHasInvestigation)) { + Investigation oldInvestigationOfExceptionHasInvestigationListNewExceptionHasInvestigation = exceptionHasInvestigationListNewExceptionHasInvestigation.getInvestigation(); + exceptionHasInvestigationListNewExceptionHasInvestigation.setInvestigation(investigation); + exceptionHasInvestigationListNewExceptionHasInvestigation = em.merge(exceptionHasInvestigationListNewExceptionHasInvestigation); + if (oldInvestigationOfExceptionHasInvestigationListNewExceptionHasInvestigation != null && !oldInvestigationOfExceptionHasInvestigationListNewExceptionHasInvestigation.equals(investigation)) { + oldInvestigationOfExceptionHasInvestigationListNewExceptionHasInvestigation.getExceptionHasInvestigationList().remove(exceptionHasInvestigationListNewExceptionHasInvestigation); + oldInvestigationOfExceptionHasInvestigationListNewExceptionHasInvestigation = em.merge(oldInvestigationOfExceptionHasInvestigationListNewExceptionHasInvestigation); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + Integer id = investigation.getId(); + if (findInvestigation(id) == null) { + throw new NonexistentEntityException("The investigation with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + Investigation investigation; + try { + investigation = em.getReference(Investigation.class, id); + investigation.getId(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The investigation with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List userHasInvestigationListOrphanCheck = investigation.getUserHasInvestigationList(); + for (UserHasInvestigation userHasInvestigationListOrphanCheckUserHasInvestigation : userHasInvestigationListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This Investigation (" + investigation + ") cannot be destroyed since the UserHasInvestigation " + userHasInvestigationListOrphanCheckUserHasInvestigation + " in its userHasInvestigationList field has a non-nullable investigation field."); + } + List exceptionHasInvestigationListOrphanCheck = investigation.getExceptionHasInvestigationList(); + for (ExceptionHasInvestigation exceptionHasInvestigationListOrphanCheckExceptionHasInvestigation : exceptionHasInvestigationListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This Investigation (" + investigation + ") cannot be destroyed since the ExceptionHasInvestigation " + exceptionHasInvestigationListOrphanCheckExceptionHasInvestigation + " in its exceptionHasInvestigationList field has a non-nullable investigation field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + em.remove(investigation); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findInvestigationEntities() { + return findInvestigationEntities(true, -1, -1); + } + + public List findInvestigationEntities(int maxResults, int firstResult) { + return findInvestigationEntities(false, maxResults, firstResult); + } + + private List findInvestigationEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(Investigation.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public Investigation findInvestigation(Integer id) { + EntityManager em = getEntityManager(); + try { + return em.find(Investigation.class, id); + } + finally { + em.close(); + } + } + + public int getInvestigationCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(Investigation.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/IssueJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/IssueJpaController.java index 1e1a39a2..7dd13592 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/IssueJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/IssueJpaController.java @@ -13,280 +13,280 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.IssueResolution; -import com.validation.manager.core.db.IssueType; -import com.validation.manager.core.db.ExecutionStepHasIssue; -import com.validation.manager.core.db.Issue; -import com.validation.manager.core.db.IssuePK; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import com.validation.manager.core.db.controller.exceptions.PreexistingEntityException; -import java.util.ArrayList; -import java.util.List; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class IssueJpaController implements Serializable { - - public IssueJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(Issue issue) throws PreexistingEntityException, Exception { - if (issue.getIssuePK() == null) { - issue.setIssuePK(new IssuePK()); - } - if (issue.getExecutionStepHasIssueList() == null) { - issue.setExecutionStepHasIssueList(new ArrayList()); - } - issue.getIssuePK().setIssueTypeId(issue.getIssueType().getId()); - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - IssueResolution issueResolutionId = issue.getIssueResolutionId(); - if (issueResolutionId != null) { - issueResolutionId = em.getReference(issueResolutionId.getClass(), issueResolutionId.getId()); - issue.setIssueResolutionId(issueResolutionId); - } - IssueType issueType = issue.getIssueType(); - if (issueType != null) { - issueType = em.getReference(issueType.getClass(), issueType.getId()); - issue.setIssueType(issueType); - } - List attachedExecutionStepHasIssueList = new ArrayList(); - for (ExecutionStepHasIssue executionStepHasIssueListExecutionStepHasIssueToAttach : issue.getExecutionStepHasIssueList()) { - executionStepHasIssueListExecutionStepHasIssueToAttach = em.getReference(executionStepHasIssueListExecutionStepHasIssueToAttach.getClass(), executionStepHasIssueListExecutionStepHasIssueToAttach.getExecutionStepHasIssuePK()); - attachedExecutionStepHasIssueList.add(executionStepHasIssueListExecutionStepHasIssueToAttach); - } - issue.setExecutionStepHasIssueList(attachedExecutionStepHasIssueList); - em.persist(issue); - if (issueResolutionId != null) { - issueResolutionId.getIssueList().add(issue); - issueResolutionId = em.merge(issueResolutionId); - } - if (issueType != null) { - issueType.getIssueList().add(issue); - issueType = em.merge(issueType); - } - for (ExecutionStepHasIssue executionStepHasIssueListExecutionStepHasIssue : issue.getExecutionStepHasIssueList()) { - Issue oldIssueOfExecutionStepHasIssueListExecutionStepHasIssue = executionStepHasIssueListExecutionStepHasIssue.getIssue(); - executionStepHasIssueListExecutionStepHasIssue.setIssue(issue); - executionStepHasIssueListExecutionStepHasIssue = em.merge(executionStepHasIssueListExecutionStepHasIssue); - if (oldIssueOfExecutionStepHasIssueListExecutionStepHasIssue != null) { - oldIssueOfExecutionStepHasIssueListExecutionStepHasIssue.getExecutionStepHasIssueList().remove(executionStepHasIssueListExecutionStepHasIssue); - oldIssueOfExecutionStepHasIssueListExecutionStepHasIssue = em.merge(oldIssueOfExecutionStepHasIssueListExecutionStepHasIssue); - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - if (findIssue(issue.getIssuePK()) != null) { - throw new PreexistingEntityException("Issue " + issue + " already exists.", ex); - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(Issue issue) throws IllegalOrphanException, NonexistentEntityException, Exception { - issue.getIssuePK().setIssueTypeId(issue.getIssueType().getId()); - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - Issue persistentIssue = em.find(Issue.class, issue.getIssuePK()); - IssueResolution issueResolutionIdOld = persistentIssue.getIssueResolutionId(); - IssueResolution issueResolutionIdNew = issue.getIssueResolutionId(); - IssueType issueTypeOld = persistentIssue.getIssueType(); - IssueType issueTypeNew = issue.getIssueType(); - List executionStepHasIssueListOld = persistentIssue.getExecutionStepHasIssueList(); - List executionStepHasIssueListNew = issue.getExecutionStepHasIssueList(); - List illegalOrphanMessages = null; - for (ExecutionStepHasIssue executionStepHasIssueListOldExecutionStepHasIssue : executionStepHasIssueListOld) { - if (!executionStepHasIssueListNew.contains(executionStepHasIssueListOldExecutionStepHasIssue)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain ExecutionStepHasIssue " + executionStepHasIssueListOldExecutionStepHasIssue + " since its issue field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - if (issueResolutionIdNew != null) { - issueResolutionIdNew = em.getReference(issueResolutionIdNew.getClass(), issueResolutionIdNew.getId()); - issue.setIssueResolutionId(issueResolutionIdNew); - } - if (issueTypeNew != null) { - issueTypeNew = em.getReference(issueTypeNew.getClass(), issueTypeNew.getId()); - issue.setIssueType(issueTypeNew); - } - List attachedExecutionStepHasIssueListNew = new ArrayList(); - for (ExecutionStepHasIssue executionStepHasIssueListNewExecutionStepHasIssueToAttach : executionStepHasIssueListNew) { - executionStepHasIssueListNewExecutionStepHasIssueToAttach = em.getReference(executionStepHasIssueListNewExecutionStepHasIssueToAttach.getClass(), executionStepHasIssueListNewExecutionStepHasIssueToAttach.getExecutionStepHasIssuePK()); - attachedExecutionStepHasIssueListNew.add(executionStepHasIssueListNewExecutionStepHasIssueToAttach); - } - executionStepHasIssueListNew = attachedExecutionStepHasIssueListNew; - issue.setExecutionStepHasIssueList(executionStepHasIssueListNew); - issue = em.merge(issue); - if (issueResolutionIdOld != null && !issueResolutionIdOld.equals(issueResolutionIdNew)) { - issueResolutionIdOld.getIssueList().remove(issue); - issueResolutionIdOld = em.merge(issueResolutionIdOld); - } - if (issueResolutionIdNew != null && !issueResolutionIdNew.equals(issueResolutionIdOld)) { - issueResolutionIdNew.getIssueList().add(issue); - issueResolutionIdNew = em.merge(issueResolutionIdNew); - } - if (issueTypeOld != null && !issueTypeOld.equals(issueTypeNew)) { - issueTypeOld.getIssueList().remove(issue); - issueTypeOld = em.merge(issueTypeOld); - } - if (issueTypeNew != null && !issueTypeNew.equals(issueTypeOld)) { - issueTypeNew.getIssueList().add(issue); - issueTypeNew = em.merge(issueTypeNew); - } - for (ExecutionStepHasIssue executionStepHasIssueListNewExecutionStepHasIssue : executionStepHasIssueListNew) { - if (!executionStepHasIssueListOld.contains(executionStepHasIssueListNewExecutionStepHasIssue)) { - Issue oldIssueOfExecutionStepHasIssueListNewExecutionStepHasIssue = executionStepHasIssueListNewExecutionStepHasIssue.getIssue(); - executionStepHasIssueListNewExecutionStepHasIssue.setIssue(issue); - executionStepHasIssueListNewExecutionStepHasIssue = em.merge(executionStepHasIssueListNewExecutionStepHasIssue); - if (oldIssueOfExecutionStepHasIssueListNewExecutionStepHasIssue != null && !oldIssueOfExecutionStepHasIssueListNewExecutionStepHasIssue.equals(issue)) { - oldIssueOfExecutionStepHasIssueListNewExecutionStepHasIssue.getExecutionStepHasIssueList().remove(executionStepHasIssueListNewExecutionStepHasIssue); - oldIssueOfExecutionStepHasIssueListNewExecutionStepHasIssue = em.merge(oldIssueOfExecutionStepHasIssueListNewExecutionStepHasIssue); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - IssuePK id = issue.getIssuePK(); - if (findIssue(id) == null) { - throw new NonexistentEntityException("The issue with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(IssuePK id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - Issue issue; - try { - issue = em.getReference(Issue.class, id); - issue.getIssuePK(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The issue with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List executionStepHasIssueListOrphanCheck = issue.getExecutionStepHasIssueList(); - for (ExecutionStepHasIssue executionStepHasIssueListOrphanCheckExecutionStepHasIssue : executionStepHasIssueListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This Issue (" + issue + ") cannot be destroyed since the ExecutionStepHasIssue " + executionStepHasIssueListOrphanCheckExecutionStepHasIssue + " in its executionStepHasIssueList field has a non-nullable issue field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - IssueResolution issueResolutionId = issue.getIssueResolutionId(); - if (issueResolutionId != null) { - issueResolutionId.getIssueList().remove(issue); - issueResolutionId = em.merge(issueResolutionId); - } - IssueType issueType = issue.getIssueType(); - if (issueType != null) { - issueType.getIssueList().remove(issue); - issueType = em.merge(issueType); - } - em.remove(issue); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findIssueEntities() { - return findIssueEntities(true, -1, -1); - } - - public List findIssueEntities(int maxResults, int firstResult) { - return findIssueEntities(false, maxResults, firstResult); - } - - private List findIssueEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(Issue.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public Issue findIssue(IssuePK id) { - EntityManager em = getEntityManager(); - try { - return em.find(Issue.class, id); - } - finally { - em.close(); - } - } - - public int getIssueCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(Issue.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.IssueResolution; +import com.validation.manager.core.db.IssueType; +import com.validation.manager.core.db.ExecutionStepHasIssue; +import com.validation.manager.core.db.Issue; +import com.validation.manager.core.db.IssuePK; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import com.validation.manager.core.db.controller.exceptions.PreexistingEntityException; +import java.util.ArrayList; +import java.util.List; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class IssueJpaController implements Serializable { + + public IssueJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(Issue issue) throws PreexistingEntityException, Exception { + if (issue.getIssuePK() == null) { + issue.setIssuePK(new IssuePK()); + } + if (issue.getExecutionStepHasIssueList() == null) { + issue.setExecutionStepHasIssueList(new ArrayList<>()); + } + issue.getIssuePK().setIssueTypeId(issue.getIssueType().getId()); + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + IssueResolution issueResolutionId = issue.getIssueResolutionId(); + if (issueResolutionId != null) { + issueResolutionId = em.getReference(issueResolutionId.getClass(), issueResolutionId.getId()); + issue.setIssueResolutionId(issueResolutionId); + } + IssueType issueType = issue.getIssueType(); + if (issueType != null) { + issueType = em.getReference(issueType.getClass(), issueType.getId()); + issue.setIssueType(issueType); + } + List attachedExecutionStepHasIssueList = new ArrayList<>(); + for (ExecutionStepHasIssue executionStepHasIssueListExecutionStepHasIssueToAttach : issue.getExecutionStepHasIssueList()) { + executionStepHasIssueListExecutionStepHasIssueToAttach = em.getReference(executionStepHasIssueListExecutionStepHasIssueToAttach.getClass(), executionStepHasIssueListExecutionStepHasIssueToAttach.getExecutionStepHasIssuePK()); + attachedExecutionStepHasIssueList.add(executionStepHasIssueListExecutionStepHasIssueToAttach); + } + issue.setExecutionStepHasIssueList(attachedExecutionStepHasIssueList); + em.persist(issue); + if (issueResolutionId != null) { + issueResolutionId.getIssueList().add(issue); + issueResolutionId = em.merge(issueResolutionId); + } + if (issueType != null) { + issueType.getIssueList().add(issue); + issueType = em.merge(issueType); + } + for (ExecutionStepHasIssue executionStepHasIssueListExecutionStepHasIssue : issue.getExecutionStepHasIssueList()) { + Issue oldIssueOfExecutionStepHasIssueListExecutionStepHasIssue = executionStepHasIssueListExecutionStepHasIssue.getIssue(); + executionStepHasIssueListExecutionStepHasIssue.setIssue(issue); + executionStepHasIssueListExecutionStepHasIssue = em.merge(executionStepHasIssueListExecutionStepHasIssue); + if (oldIssueOfExecutionStepHasIssueListExecutionStepHasIssue != null) { + oldIssueOfExecutionStepHasIssueListExecutionStepHasIssue.getExecutionStepHasIssueList().remove(executionStepHasIssueListExecutionStepHasIssue); + oldIssueOfExecutionStepHasIssueListExecutionStepHasIssue = em.merge(oldIssueOfExecutionStepHasIssueListExecutionStepHasIssue); + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + if (findIssue(issue.getIssuePK()) != null) { + throw new PreexistingEntityException("Issue " + issue + " already exists.", ex); + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(Issue issue) throws IllegalOrphanException, NonexistentEntityException, Exception { + issue.getIssuePK().setIssueTypeId(issue.getIssueType().getId()); + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + Issue persistentIssue = em.find(Issue.class, issue.getIssuePK()); + IssueResolution issueResolutionIdOld = persistentIssue.getIssueResolutionId(); + IssueResolution issueResolutionIdNew = issue.getIssueResolutionId(); + IssueType issueTypeOld = persistentIssue.getIssueType(); + IssueType issueTypeNew = issue.getIssueType(); + List executionStepHasIssueListOld = persistentIssue.getExecutionStepHasIssueList(); + List executionStepHasIssueListNew = issue.getExecutionStepHasIssueList(); + List illegalOrphanMessages = null; + for (ExecutionStepHasIssue executionStepHasIssueListOldExecutionStepHasIssue : executionStepHasIssueListOld) { + if (!executionStepHasIssueListNew.contains(executionStepHasIssueListOldExecutionStepHasIssue)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain ExecutionStepHasIssue " + executionStepHasIssueListOldExecutionStepHasIssue + " since its issue field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + if (issueResolutionIdNew != null) { + issueResolutionIdNew = em.getReference(issueResolutionIdNew.getClass(), issueResolutionIdNew.getId()); + issue.setIssueResolutionId(issueResolutionIdNew); + } + if (issueTypeNew != null) { + issueTypeNew = em.getReference(issueTypeNew.getClass(), issueTypeNew.getId()); + issue.setIssueType(issueTypeNew); + } + List attachedExecutionStepHasIssueListNew = new ArrayList<>(); + for (ExecutionStepHasIssue executionStepHasIssueListNewExecutionStepHasIssueToAttach : executionStepHasIssueListNew) { + executionStepHasIssueListNewExecutionStepHasIssueToAttach = em.getReference(executionStepHasIssueListNewExecutionStepHasIssueToAttach.getClass(), executionStepHasIssueListNewExecutionStepHasIssueToAttach.getExecutionStepHasIssuePK()); + attachedExecutionStepHasIssueListNew.add(executionStepHasIssueListNewExecutionStepHasIssueToAttach); + } + executionStepHasIssueListNew = attachedExecutionStepHasIssueListNew; + issue.setExecutionStepHasIssueList(executionStepHasIssueListNew); + issue = em.merge(issue); + if (issueResolutionIdOld != null && !issueResolutionIdOld.equals(issueResolutionIdNew)) { + issueResolutionIdOld.getIssueList().remove(issue); + issueResolutionIdOld = em.merge(issueResolutionIdOld); + } + if (issueResolutionIdNew != null && !issueResolutionIdNew.equals(issueResolutionIdOld)) { + issueResolutionIdNew.getIssueList().add(issue); + issueResolutionIdNew = em.merge(issueResolutionIdNew); + } + if (issueTypeOld != null && !issueTypeOld.equals(issueTypeNew)) { + issueTypeOld.getIssueList().remove(issue); + issueTypeOld = em.merge(issueTypeOld); + } + if (issueTypeNew != null && !issueTypeNew.equals(issueTypeOld)) { + issueTypeNew.getIssueList().add(issue); + issueTypeNew = em.merge(issueTypeNew); + } + for (ExecutionStepHasIssue executionStepHasIssueListNewExecutionStepHasIssue : executionStepHasIssueListNew) { + if (!executionStepHasIssueListOld.contains(executionStepHasIssueListNewExecutionStepHasIssue)) { + Issue oldIssueOfExecutionStepHasIssueListNewExecutionStepHasIssue = executionStepHasIssueListNewExecutionStepHasIssue.getIssue(); + executionStepHasIssueListNewExecutionStepHasIssue.setIssue(issue); + executionStepHasIssueListNewExecutionStepHasIssue = em.merge(executionStepHasIssueListNewExecutionStepHasIssue); + if (oldIssueOfExecutionStepHasIssueListNewExecutionStepHasIssue != null && !oldIssueOfExecutionStepHasIssueListNewExecutionStepHasIssue.equals(issue)) { + oldIssueOfExecutionStepHasIssueListNewExecutionStepHasIssue.getExecutionStepHasIssueList().remove(executionStepHasIssueListNewExecutionStepHasIssue); + oldIssueOfExecutionStepHasIssueListNewExecutionStepHasIssue = em.merge(oldIssueOfExecutionStepHasIssueListNewExecutionStepHasIssue); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + IssuePK id = issue.getIssuePK(); + if (findIssue(id) == null) { + throw new NonexistentEntityException("The issue with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(IssuePK id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + Issue issue; + try { + issue = em.getReference(Issue.class, id); + issue.getIssuePK(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The issue with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List executionStepHasIssueListOrphanCheck = issue.getExecutionStepHasIssueList(); + for (ExecutionStepHasIssue executionStepHasIssueListOrphanCheckExecutionStepHasIssue : executionStepHasIssueListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This Issue (" + issue + ") cannot be destroyed since the ExecutionStepHasIssue " + executionStepHasIssueListOrphanCheckExecutionStepHasIssue + " in its executionStepHasIssueList field has a non-nullable issue field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + IssueResolution issueResolutionId = issue.getIssueResolutionId(); + if (issueResolutionId != null) { + issueResolutionId.getIssueList().remove(issue); + issueResolutionId = em.merge(issueResolutionId); + } + IssueType issueType = issue.getIssueType(); + if (issueType != null) { + issueType.getIssueList().remove(issue); + issueType = em.merge(issueType); + } + em.remove(issue); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findIssueEntities() { + return findIssueEntities(true, -1, -1); + } + + public List findIssueEntities(int maxResults, int firstResult) { + return findIssueEntities(false, maxResults, firstResult); + } + + private List findIssueEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(Issue.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public Issue findIssue(IssuePK id) { + EntityManager em = getEntityManager(); + try { + return em.find(Issue.class, id); + } + finally { + em.close(); + } + } + + public int getIssueCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(Issue.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/IssueResolutionJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/IssueResolutionJpaController.java index 261af4bf..9a959957 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/IssueResolutionJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/IssueResolutionJpaController.java @@ -13,209 +13,209 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.Issue; -import com.validation.manager.core.db.IssueResolution; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import java.util.ArrayList; -import java.util.List; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class IssueResolutionJpaController implements Serializable { - - public IssueResolutionJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(IssueResolution issueResolution) { - if (issueResolution.getIssueList() == null) { - issueResolution.setIssueList(new ArrayList()); - } - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - List attachedIssueList = new ArrayList(); - for (Issue issueListIssueToAttach : issueResolution.getIssueList()) { - issueListIssueToAttach = em.getReference(issueListIssueToAttach.getClass(), issueListIssueToAttach.getIssuePK()); - attachedIssueList.add(issueListIssueToAttach); - } - issueResolution.setIssueList(attachedIssueList); - em.persist(issueResolution); - for (Issue issueListIssue : issueResolution.getIssueList()) { - IssueResolution oldIssueResolutionIdOfIssueListIssue = issueListIssue.getIssueResolutionId(); - issueListIssue.setIssueResolutionId(issueResolution); - issueListIssue = em.merge(issueListIssue); - if (oldIssueResolutionIdOfIssueListIssue != null) { - oldIssueResolutionIdOfIssueListIssue.getIssueList().remove(issueListIssue); - oldIssueResolutionIdOfIssueListIssue = em.merge(oldIssueResolutionIdOfIssueListIssue); - } - } - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(IssueResolution issueResolution) throws IllegalOrphanException, NonexistentEntityException, Exception { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - IssueResolution persistentIssueResolution = em.find(IssueResolution.class, issueResolution.getId()); - List issueListOld = persistentIssueResolution.getIssueList(); - List issueListNew = issueResolution.getIssueList(); - List illegalOrphanMessages = null; - for (Issue issueListOldIssue : issueListOld) { - if (!issueListNew.contains(issueListOldIssue)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain Issue " + issueListOldIssue + " since its issueResolutionId field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - List attachedIssueListNew = new ArrayList(); - for (Issue issueListNewIssueToAttach : issueListNew) { - issueListNewIssueToAttach = em.getReference(issueListNewIssueToAttach.getClass(), issueListNewIssueToAttach.getIssuePK()); - attachedIssueListNew.add(issueListNewIssueToAttach); - } - issueListNew = attachedIssueListNew; - issueResolution.setIssueList(issueListNew); - issueResolution = em.merge(issueResolution); - for (Issue issueListNewIssue : issueListNew) { - if (!issueListOld.contains(issueListNewIssue)) { - IssueResolution oldIssueResolutionIdOfIssueListNewIssue = issueListNewIssue.getIssueResolutionId(); - issueListNewIssue.setIssueResolutionId(issueResolution); - issueListNewIssue = em.merge(issueListNewIssue); - if (oldIssueResolutionIdOfIssueListNewIssue != null && !oldIssueResolutionIdOfIssueListNewIssue.equals(issueResolution)) { - oldIssueResolutionIdOfIssueListNewIssue.getIssueList().remove(issueListNewIssue); - oldIssueResolutionIdOfIssueListNewIssue = em.merge(oldIssueResolutionIdOfIssueListNewIssue); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - Integer id = issueResolution.getId(); - if (findIssueResolution(id) == null) { - throw new NonexistentEntityException("The issueResolution with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - IssueResolution issueResolution; - try { - issueResolution = em.getReference(IssueResolution.class, id); - issueResolution.getId(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The issueResolution with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List issueListOrphanCheck = issueResolution.getIssueList(); - for (Issue issueListOrphanCheckIssue : issueListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This IssueResolution (" + issueResolution + ") cannot be destroyed since the Issue " + issueListOrphanCheckIssue + " in its issueList field has a non-nullable issueResolutionId field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - em.remove(issueResolution); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findIssueResolutionEntities() { - return findIssueResolutionEntities(true, -1, -1); - } - - public List findIssueResolutionEntities(int maxResults, int firstResult) { - return findIssueResolutionEntities(false, maxResults, firstResult); - } - - private List findIssueResolutionEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(IssueResolution.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public IssueResolution findIssueResolution(Integer id) { - EntityManager em = getEntityManager(); - try { - return em.find(IssueResolution.class, id); - } - finally { - em.close(); - } - } - - public int getIssueResolutionCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(IssueResolution.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.Issue; +import com.validation.manager.core.db.IssueResolution; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import java.util.ArrayList; +import java.util.List; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class IssueResolutionJpaController implements Serializable { + + public IssueResolutionJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(IssueResolution issueResolution) { + if (issueResolution.getIssueList() == null) { + issueResolution.setIssueList(new ArrayList<>()); + } + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + List attachedIssueList = new ArrayList<>(); + for (Issue issueListIssueToAttach : issueResolution.getIssueList()) { + issueListIssueToAttach = em.getReference(issueListIssueToAttach.getClass(), issueListIssueToAttach.getIssuePK()); + attachedIssueList.add(issueListIssueToAttach); + } + issueResolution.setIssueList(attachedIssueList); + em.persist(issueResolution); + for (Issue issueListIssue : issueResolution.getIssueList()) { + IssueResolution oldIssueResolutionIdOfIssueListIssue = issueListIssue.getIssueResolutionId(); + issueListIssue.setIssueResolutionId(issueResolution); + issueListIssue = em.merge(issueListIssue); + if (oldIssueResolutionIdOfIssueListIssue != null) { + oldIssueResolutionIdOfIssueListIssue.getIssueList().remove(issueListIssue); + oldIssueResolutionIdOfIssueListIssue = em.merge(oldIssueResolutionIdOfIssueListIssue); + } + } + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(IssueResolution issueResolution) throws IllegalOrphanException, NonexistentEntityException, Exception { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + IssueResolution persistentIssueResolution = em.find(IssueResolution.class, issueResolution.getId()); + List issueListOld = persistentIssueResolution.getIssueList(); + List issueListNew = issueResolution.getIssueList(); + List illegalOrphanMessages = null; + for (Issue issueListOldIssue : issueListOld) { + if (!issueListNew.contains(issueListOldIssue)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain Issue " + issueListOldIssue + " since its issueResolutionId field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + List attachedIssueListNew = new ArrayList<>(); + for (Issue issueListNewIssueToAttach : issueListNew) { + issueListNewIssueToAttach = em.getReference(issueListNewIssueToAttach.getClass(), issueListNewIssueToAttach.getIssuePK()); + attachedIssueListNew.add(issueListNewIssueToAttach); + } + issueListNew = attachedIssueListNew; + issueResolution.setIssueList(issueListNew); + issueResolution = em.merge(issueResolution); + for (Issue issueListNewIssue : issueListNew) { + if (!issueListOld.contains(issueListNewIssue)) { + IssueResolution oldIssueResolutionIdOfIssueListNewIssue = issueListNewIssue.getIssueResolutionId(); + issueListNewIssue.setIssueResolutionId(issueResolution); + issueListNewIssue = em.merge(issueListNewIssue); + if (oldIssueResolutionIdOfIssueListNewIssue != null && !oldIssueResolutionIdOfIssueListNewIssue.equals(issueResolution)) { + oldIssueResolutionIdOfIssueListNewIssue.getIssueList().remove(issueListNewIssue); + oldIssueResolutionIdOfIssueListNewIssue = em.merge(oldIssueResolutionIdOfIssueListNewIssue); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + Integer id = issueResolution.getId(); + if (findIssueResolution(id) == null) { + throw new NonexistentEntityException("The issueResolution with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + IssueResolution issueResolution; + try { + issueResolution = em.getReference(IssueResolution.class, id); + issueResolution.getId(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The issueResolution with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List issueListOrphanCheck = issueResolution.getIssueList(); + for (Issue issueListOrphanCheckIssue : issueListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This IssueResolution (" + issueResolution + ") cannot be destroyed since the Issue " + issueListOrphanCheckIssue + " in its issueList field has a non-nullable issueResolutionId field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + em.remove(issueResolution); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findIssueResolutionEntities() { + return findIssueResolutionEntities(true, -1, -1); + } + + public List findIssueResolutionEntities(int maxResults, int firstResult) { + return findIssueResolutionEntities(false, maxResults, firstResult); + } + + private List findIssueResolutionEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(IssueResolution.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public IssueResolution findIssueResolution(Integer id) { + EntityManager em = getEntityManager(); + try { + return em.find(IssueResolution.class, id); + } + finally { + em.close(); + } + } + + public int getIssueResolutionCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(IssueResolution.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/IssueTypeJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/IssueTypeJpaController.java index baadbdf6..194c050a 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/IssueTypeJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/IssueTypeJpaController.java @@ -13,209 +13,209 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.Issue; -import com.validation.manager.core.db.IssueType; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import java.util.ArrayList; -import java.util.List; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class IssueTypeJpaController implements Serializable { - - public IssueTypeJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(IssueType issueType) { - if (issueType.getIssueList() == null) { - issueType.setIssueList(new ArrayList()); - } - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - List attachedIssueList = new ArrayList(); - for (Issue issueListIssueToAttach : issueType.getIssueList()) { - issueListIssueToAttach = em.getReference(issueListIssueToAttach.getClass(), issueListIssueToAttach.getIssuePK()); - attachedIssueList.add(issueListIssueToAttach); - } - issueType.setIssueList(attachedIssueList); - em.persist(issueType); - for (Issue issueListIssue : issueType.getIssueList()) { - IssueType oldIssueTypeOfIssueListIssue = issueListIssue.getIssueType(); - issueListIssue.setIssueType(issueType); - issueListIssue = em.merge(issueListIssue); - if (oldIssueTypeOfIssueListIssue != null) { - oldIssueTypeOfIssueListIssue.getIssueList().remove(issueListIssue); - oldIssueTypeOfIssueListIssue = em.merge(oldIssueTypeOfIssueListIssue); - } - } - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(IssueType issueType) throws IllegalOrphanException, NonexistentEntityException, Exception { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - IssueType persistentIssueType = em.find(IssueType.class, issueType.getId()); - List issueListOld = persistentIssueType.getIssueList(); - List issueListNew = issueType.getIssueList(); - List illegalOrphanMessages = null; - for (Issue issueListOldIssue : issueListOld) { - if (!issueListNew.contains(issueListOldIssue)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain Issue " + issueListOldIssue + " since its issueType field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - List attachedIssueListNew = new ArrayList(); - for (Issue issueListNewIssueToAttach : issueListNew) { - issueListNewIssueToAttach = em.getReference(issueListNewIssueToAttach.getClass(), issueListNewIssueToAttach.getIssuePK()); - attachedIssueListNew.add(issueListNewIssueToAttach); - } - issueListNew = attachedIssueListNew; - issueType.setIssueList(issueListNew); - issueType = em.merge(issueType); - for (Issue issueListNewIssue : issueListNew) { - if (!issueListOld.contains(issueListNewIssue)) { - IssueType oldIssueTypeOfIssueListNewIssue = issueListNewIssue.getIssueType(); - issueListNewIssue.setIssueType(issueType); - issueListNewIssue = em.merge(issueListNewIssue); - if (oldIssueTypeOfIssueListNewIssue != null && !oldIssueTypeOfIssueListNewIssue.equals(issueType)) { - oldIssueTypeOfIssueListNewIssue.getIssueList().remove(issueListNewIssue); - oldIssueTypeOfIssueListNewIssue = em.merge(oldIssueTypeOfIssueListNewIssue); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - Integer id = issueType.getId(); - if (findIssueType(id) == null) { - throw new NonexistentEntityException("The issueType with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - IssueType issueType; - try { - issueType = em.getReference(IssueType.class, id); - issueType.getId(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The issueType with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List issueListOrphanCheck = issueType.getIssueList(); - for (Issue issueListOrphanCheckIssue : issueListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This IssueType (" + issueType + ") cannot be destroyed since the Issue " + issueListOrphanCheckIssue + " in its issueList field has a non-nullable issueType field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - em.remove(issueType); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findIssueTypeEntities() { - return findIssueTypeEntities(true, -1, -1); - } - - public List findIssueTypeEntities(int maxResults, int firstResult) { - return findIssueTypeEntities(false, maxResults, firstResult); - } - - private List findIssueTypeEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(IssueType.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public IssueType findIssueType(Integer id) { - EntityManager em = getEntityManager(); - try { - return em.find(IssueType.class, id); - } - finally { - em.close(); - } - } - - public int getIssueTypeCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(IssueType.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.Issue; +import com.validation.manager.core.db.IssueType; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import java.util.ArrayList; +import java.util.List; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class IssueTypeJpaController implements Serializable { + + public IssueTypeJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(IssueType issueType) { + if (issueType.getIssueList() == null) { + issueType.setIssueList(new ArrayList<>()); + } + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + List attachedIssueList = new ArrayList<>(); + for (Issue issueListIssueToAttach : issueType.getIssueList()) { + issueListIssueToAttach = em.getReference(issueListIssueToAttach.getClass(), issueListIssueToAttach.getIssuePK()); + attachedIssueList.add(issueListIssueToAttach); + } + issueType.setIssueList(attachedIssueList); + em.persist(issueType); + for (Issue issueListIssue : issueType.getIssueList()) { + IssueType oldIssueTypeOfIssueListIssue = issueListIssue.getIssueType(); + issueListIssue.setIssueType(issueType); + issueListIssue = em.merge(issueListIssue); + if (oldIssueTypeOfIssueListIssue != null) { + oldIssueTypeOfIssueListIssue.getIssueList().remove(issueListIssue); + oldIssueTypeOfIssueListIssue = em.merge(oldIssueTypeOfIssueListIssue); + } + } + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(IssueType issueType) throws IllegalOrphanException, NonexistentEntityException, Exception { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + IssueType persistentIssueType = em.find(IssueType.class, issueType.getId()); + List issueListOld = persistentIssueType.getIssueList(); + List issueListNew = issueType.getIssueList(); + List illegalOrphanMessages = null; + for (Issue issueListOldIssue : issueListOld) { + if (!issueListNew.contains(issueListOldIssue)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain Issue " + issueListOldIssue + " since its issueType field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + List attachedIssueListNew = new ArrayList<>(); + for (Issue issueListNewIssueToAttach : issueListNew) { + issueListNewIssueToAttach = em.getReference(issueListNewIssueToAttach.getClass(), issueListNewIssueToAttach.getIssuePK()); + attachedIssueListNew.add(issueListNewIssueToAttach); + } + issueListNew = attachedIssueListNew; + issueType.setIssueList(issueListNew); + issueType = em.merge(issueType); + for (Issue issueListNewIssue : issueListNew) { + if (!issueListOld.contains(issueListNewIssue)) { + IssueType oldIssueTypeOfIssueListNewIssue = issueListNewIssue.getIssueType(); + issueListNewIssue.setIssueType(issueType); + issueListNewIssue = em.merge(issueListNewIssue); + if (oldIssueTypeOfIssueListNewIssue != null && !oldIssueTypeOfIssueListNewIssue.equals(issueType)) { + oldIssueTypeOfIssueListNewIssue.getIssueList().remove(issueListNewIssue); + oldIssueTypeOfIssueListNewIssue = em.merge(oldIssueTypeOfIssueListNewIssue); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + Integer id = issueType.getId(); + if (findIssueType(id) == null) { + throw new NonexistentEntityException("The issueType with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + IssueType issueType; + try { + issueType = em.getReference(IssueType.class, id); + issueType.getId(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The issueType with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List issueListOrphanCheck = issueType.getIssueList(); + for (Issue issueListOrphanCheckIssue : issueListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This IssueType (" + issueType + ") cannot be destroyed since the Issue " + issueListOrphanCheckIssue + " in its issueList field has a non-nullable issueType field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + em.remove(issueType); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findIssueTypeEntities() { + return findIssueTypeEntities(true, -1, -1); + } + + public List findIssueTypeEntities(int maxResults, int firstResult) { + return findIssueTypeEntities(false, maxResults, firstResult); + } + + private List findIssueTypeEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(IssueType.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public IssueType findIssueType(Integer id) { + EntityManager em = getEntityManager(); + try { + return em.find(IssueType.class, id); + } + finally { + em.close(); + } + } + + public int getIssueTypeCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(IssueType.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/NotificationTypeJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/NotificationTypeJpaController.java index 9825606e..3efeea35 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/NotificationTypeJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/NotificationTypeJpaController.java @@ -13,209 +13,209 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.Notification; -import com.validation.manager.core.db.NotificationType; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import java.util.ArrayList; -import java.util.List; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class NotificationTypeJpaController implements Serializable { - - public NotificationTypeJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(NotificationType notificationType) { - if (notificationType.getNotificationList() == null) { - notificationType.setNotificationList(new ArrayList()); - } - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - List attachedNotificationList = new ArrayList(); - for (Notification notificationListNotificationToAttach : notificationType.getNotificationList()) { - notificationListNotificationToAttach = em.getReference(notificationListNotificationToAttach.getClass(), notificationListNotificationToAttach.getNotificationPK()); - attachedNotificationList.add(notificationListNotificationToAttach); - } - notificationType.setNotificationList(attachedNotificationList); - em.persist(notificationType); - for (Notification notificationListNotification : notificationType.getNotificationList()) { - NotificationType oldNotificationTypeOfNotificationListNotification = notificationListNotification.getNotificationType(); - notificationListNotification.setNotificationType(notificationType); - notificationListNotification = em.merge(notificationListNotification); - if (oldNotificationTypeOfNotificationListNotification != null) { - oldNotificationTypeOfNotificationListNotification.getNotificationList().remove(notificationListNotification); - oldNotificationTypeOfNotificationListNotification = em.merge(oldNotificationTypeOfNotificationListNotification); - } - } - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(NotificationType notificationType) throws IllegalOrphanException, NonexistentEntityException, Exception { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - NotificationType persistentNotificationType = em.find(NotificationType.class, notificationType.getId()); - List notificationListOld = persistentNotificationType.getNotificationList(); - List notificationListNew = notificationType.getNotificationList(); - List illegalOrphanMessages = null; - for (Notification notificationListOldNotification : notificationListOld) { - if (!notificationListNew.contains(notificationListOldNotification)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain Notification " + notificationListOldNotification + " since its notificationType field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - List attachedNotificationListNew = new ArrayList(); - for (Notification notificationListNewNotificationToAttach : notificationListNew) { - notificationListNewNotificationToAttach = em.getReference(notificationListNewNotificationToAttach.getClass(), notificationListNewNotificationToAttach.getNotificationPK()); - attachedNotificationListNew.add(notificationListNewNotificationToAttach); - } - notificationListNew = attachedNotificationListNew; - notificationType.setNotificationList(notificationListNew); - notificationType = em.merge(notificationType); - for (Notification notificationListNewNotification : notificationListNew) { - if (!notificationListOld.contains(notificationListNewNotification)) { - NotificationType oldNotificationTypeOfNotificationListNewNotification = notificationListNewNotification.getNotificationType(); - notificationListNewNotification.setNotificationType(notificationType); - notificationListNewNotification = em.merge(notificationListNewNotification); - if (oldNotificationTypeOfNotificationListNewNotification != null && !oldNotificationTypeOfNotificationListNewNotification.equals(notificationType)) { - oldNotificationTypeOfNotificationListNewNotification.getNotificationList().remove(notificationListNewNotification); - oldNotificationTypeOfNotificationListNewNotification = em.merge(oldNotificationTypeOfNotificationListNewNotification); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - Integer id = notificationType.getId(); - if (findNotificationType(id) == null) { - throw new NonexistentEntityException("The notificationType with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - NotificationType notificationType; - try { - notificationType = em.getReference(NotificationType.class, id); - notificationType.getId(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The notificationType with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List notificationListOrphanCheck = notificationType.getNotificationList(); - for (Notification notificationListOrphanCheckNotification : notificationListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This NotificationType (" + notificationType + ") cannot be destroyed since the Notification " + notificationListOrphanCheckNotification + " in its notificationList field has a non-nullable notificationType field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - em.remove(notificationType); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findNotificationTypeEntities() { - return findNotificationTypeEntities(true, -1, -1); - } - - public List findNotificationTypeEntities(int maxResults, int firstResult) { - return findNotificationTypeEntities(false, maxResults, firstResult); - } - - private List findNotificationTypeEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(NotificationType.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public NotificationType findNotificationType(Integer id) { - EntityManager em = getEntityManager(); - try { - return em.find(NotificationType.class, id); - } - finally { - em.close(); - } - } - - public int getNotificationTypeCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(NotificationType.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.Notification; +import com.validation.manager.core.db.NotificationType; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import java.util.ArrayList; +import java.util.List; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class NotificationTypeJpaController implements Serializable { + + public NotificationTypeJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(NotificationType notificationType) { + if (notificationType.getNotificationList() == null) { + notificationType.setNotificationList(new ArrayList<>()); + } + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + List attachedNotificationList = new ArrayList<>(); + for (Notification notificationListNotificationToAttach : notificationType.getNotificationList()) { + notificationListNotificationToAttach = em.getReference(notificationListNotificationToAttach.getClass(), notificationListNotificationToAttach.getNotificationPK()); + attachedNotificationList.add(notificationListNotificationToAttach); + } + notificationType.setNotificationList(attachedNotificationList); + em.persist(notificationType); + for (Notification notificationListNotification : notificationType.getNotificationList()) { + NotificationType oldNotificationTypeOfNotificationListNotification = notificationListNotification.getNotificationType(); + notificationListNotification.setNotificationType(notificationType); + notificationListNotification = em.merge(notificationListNotification); + if (oldNotificationTypeOfNotificationListNotification != null) { + oldNotificationTypeOfNotificationListNotification.getNotificationList().remove(notificationListNotification); + oldNotificationTypeOfNotificationListNotification = em.merge(oldNotificationTypeOfNotificationListNotification); + } + } + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(NotificationType notificationType) throws IllegalOrphanException, NonexistentEntityException, Exception { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + NotificationType persistentNotificationType = em.find(NotificationType.class, notificationType.getId()); + List notificationListOld = persistentNotificationType.getNotificationList(); + List notificationListNew = notificationType.getNotificationList(); + List illegalOrphanMessages = null; + for (Notification notificationListOldNotification : notificationListOld) { + if (!notificationListNew.contains(notificationListOldNotification)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain Notification " + notificationListOldNotification + " since its notificationType field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + List attachedNotificationListNew = new ArrayList<>(); + for (Notification notificationListNewNotificationToAttach : notificationListNew) { + notificationListNewNotificationToAttach = em.getReference(notificationListNewNotificationToAttach.getClass(), notificationListNewNotificationToAttach.getNotificationPK()); + attachedNotificationListNew.add(notificationListNewNotificationToAttach); + } + notificationListNew = attachedNotificationListNew; + notificationType.setNotificationList(notificationListNew); + notificationType = em.merge(notificationType); + for (Notification notificationListNewNotification : notificationListNew) { + if (!notificationListOld.contains(notificationListNewNotification)) { + NotificationType oldNotificationTypeOfNotificationListNewNotification = notificationListNewNotification.getNotificationType(); + notificationListNewNotification.setNotificationType(notificationType); + notificationListNewNotification = em.merge(notificationListNewNotification); + if (oldNotificationTypeOfNotificationListNewNotification != null && !oldNotificationTypeOfNotificationListNewNotification.equals(notificationType)) { + oldNotificationTypeOfNotificationListNewNotification.getNotificationList().remove(notificationListNewNotification); + oldNotificationTypeOfNotificationListNewNotification = em.merge(oldNotificationTypeOfNotificationListNewNotification); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + Integer id = notificationType.getId(); + if (findNotificationType(id) == null) { + throw new NonexistentEntityException("The notificationType with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + NotificationType notificationType; + try { + notificationType = em.getReference(NotificationType.class, id); + notificationType.getId(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The notificationType with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List notificationListOrphanCheck = notificationType.getNotificationList(); + for (Notification notificationListOrphanCheckNotification : notificationListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This NotificationType (" + notificationType + ") cannot be destroyed since the Notification " + notificationListOrphanCheckNotification + " in its notificationList field has a non-nullable notificationType field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + em.remove(notificationType); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findNotificationTypeEntities() { + return findNotificationTypeEntities(true, -1, -1); + } + + public List findNotificationTypeEntities(int maxResults, int firstResult) { + return findNotificationTypeEntities(false, maxResults, firstResult); + } + + private List findNotificationTypeEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(NotificationType.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public NotificationType findNotificationType(Integer id) { + EntityManager em = getEntityManager(); + try { + return em.find(NotificationType.class, id); + } + finally { + em.close(); + } + } + + public int getNotificationTypeCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(NotificationType.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/ProjectJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/ProjectJpaController.java index 4940e117..87928c3a 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/ProjectJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/ProjectJpaController.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,380 +13,380 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.Project; -import com.validation.manager.core.db.TestProject; -import java.util.ArrayList; -import java.util.List; -import com.validation.manager.core.db.RequirementSpec; -import com.validation.manager.core.db.History; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class ProjectJpaController implements Serializable { - - public ProjectJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(Project project) { - if (project.getTestProjectList() == null) { - project.setTestProjectList(new ArrayList()); - } - if (project.getProjectList() == null) { - project.setProjectList(new ArrayList()); - } - if (project.getRequirementSpecList() == null) { - project.setRequirementSpecList(new ArrayList()); - } - if (project.getHistoryList() == null) { - project.setHistoryList(new ArrayList()); - } - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - Project parentProjectId = project.getParentProjectId(); - if (parentProjectId != null) { - parentProjectId = em.getReference(parentProjectId.getClass(), parentProjectId.getId()); - project.setParentProjectId(parentProjectId); - } - List attachedTestProjectList = new ArrayList(); - for (TestProject testProjectListTestProjectToAttach : project.getTestProjectList()) { - testProjectListTestProjectToAttach = em.getReference(testProjectListTestProjectToAttach.getClass(), testProjectListTestProjectToAttach.getId()); - attachedTestProjectList.add(testProjectListTestProjectToAttach); - } - project.setTestProjectList(attachedTestProjectList); - List attachedProjectList = new ArrayList(); - for (Project projectListProjectToAttach : project.getProjectList()) { - projectListProjectToAttach = em.getReference(projectListProjectToAttach.getClass(), projectListProjectToAttach.getId()); - attachedProjectList.add(projectListProjectToAttach); - } - project.setProjectList(attachedProjectList); - List attachedRequirementSpecList = new ArrayList(); - for (RequirementSpec requirementSpecListRequirementSpecToAttach : project.getRequirementSpecList()) { - requirementSpecListRequirementSpecToAttach = em.getReference(requirementSpecListRequirementSpecToAttach.getClass(), requirementSpecListRequirementSpecToAttach.getRequirementSpecPK()); - attachedRequirementSpecList.add(requirementSpecListRequirementSpecToAttach); - } - project.setRequirementSpecList(attachedRequirementSpecList); - List attachedHistoryList = new ArrayList(); - for (History historyListHistoryToAttach : project.getHistoryList()) { - historyListHistoryToAttach = em.getReference(historyListHistoryToAttach.getClass(), historyListHistoryToAttach.getId()); - attachedHistoryList.add(historyListHistoryToAttach); - } - project.setHistoryList(attachedHistoryList); - em.persist(project); - if (parentProjectId != null) { - parentProjectId.getProjectList().add(project); - parentProjectId = em.merge(parentProjectId); - } - for (TestProject testProjectListTestProject : project.getTestProjectList()) { - testProjectListTestProject.getProjectList().add(project); - testProjectListTestProject = em.merge(testProjectListTestProject); - } - for (Project projectListProject : project.getProjectList()) { - Project oldParentProjectIdOfProjectListProject = projectListProject.getParentProjectId(); - projectListProject.setParentProjectId(project); - projectListProject = em.merge(projectListProject); - if (oldParentProjectIdOfProjectListProject != null) { - oldParentProjectIdOfProjectListProject.getProjectList().remove(projectListProject); - oldParentProjectIdOfProjectListProject = em.merge(oldParentProjectIdOfProjectListProject); - } - } - for (RequirementSpec requirementSpecListRequirementSpec : project.getRequirementSpecList()) { - Project oldProjectOfRequirementSpecListRequirementSpec = requirementSpecListRequirementSpec.getProject(); - requirementSpecListRequirementSpec.setProject(project); - requirementSpecListRequirementSpec = em.merge(requirementSpecListRequirementSpec); - if (oldProjectOfRequirementSpecListRequirementSpec != null) { - oldProjectOfRequirementSpecListRequirementSpec.getRequirementSpecList().remove(requirementSpecListRequirementSpec); - oldProjectOfRequirementSpecListRequirementSpec = em.merge(oldProjectOfRequirementSpecListRequirementSpec); - } - } - for (History historyListHistory : project.getHistoryList()) { - Project oldProjectIdOfHistoryListHistory = historyListHistory.getProjectId(); - historyListHistory.setProjectId(project); - historyListHistory = em.merge(historyListHistory); - if (oldProjectIdOfHistoryListHistory != null) { - oldProjectIdOfHistoryListHistory.getHistoryList().remove(historyListHistory); - oldProjectIdOfHistoryListHistory = em.merge(oldProjectIdOfHistoryListHistory); - } - } - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(Project project) throws IllegalOrphanException, NonexistentEntityException, Exception { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - Project persistentProject = em.find(Project.class, project.getId()); - Project parentProjectIdOld = persistentProject.getParentProjectId(); - Project parentProjectIdNew = project.getParentProjectId(); - List testProjectListOld = persistentProject.getTestProjectList(); - List testProjectListNew = project.getTestProjectList(); - List projectListOld = persistentProject.getProjectList(); - List projectListNew = project.getProjectList(); - List requirementSpecListOld = persistentProject.getRequirementSpecList(); - List requirementSpecListNew = project.getRequirementSpecList(); - List historyListOld = persistentProject.getHistoryList(); - List historyListNew = project.getHistoryList(); - List illegalOrphanMessages = null; - for (RequirementSpec requirementSpecListOldRequirementSpec : requirementSpecListOld) { - if (!requirementSpecListNew.contains(requirementSpecListOldRequirementSpec)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain RequirementSpec " + requirementSpecListOldRequirementSpec + " since its project field is not nullable."); - } - } - for (History historyListOldHistory : historyListOld) { - if (!historyListNew.contains(historyListOldHistory)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain History " + historyListOldHistory + " since its projectId field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - if (parentProjectIdNew != null) { - parentProjectIdNew = em.getReference(parentProjectIdNew.getClass(), parentProjectIdNew.getId()); - project.setParentProjectId(parentProjectIdNew); - } - List attachedTestProjectListNew = new ArrayList(); - for (TestProject testProjectListNewTestProjectToAttach : testProjectListNew) { - testProjectListNewTestProjectToAttach = em.getReference(testProjectListNewTestProjectToAttach.getClass(), testProjectListNewTestProjectToAttach.getId()); - attachedTestProjectListNew.add(testProjectListNewTestProjectToAttach); - } - testProjectListNew = attachedTestProjectListNew; - project.setTestProjectList(testProjectListNew); - List attachedProjectListNew = new ArrayList(); - for (Project projectListNewProjectToAttach : projectListNew) { - projectListNewProjectToAttach = em.getReference(projectListNewProjectToAttach.getClass(), projectListNewProjectToAttach.getId()); - attachedProjectListNew.add(projectListNewProjectToAttach); - } - projectListNew = attachedProjectListNew; - project.setProjectList(projectListNew); - List attachedRequirementSpecListNew = new ArrayList(); - for (RequirementSpec requirementSpecListNewRequirementSpecToAttach : requirementSpecListNew) { - requirementSpecListNewRequirementSpecToAttach = em.getReference(requirementSpecListNewRequirementSpecToAttach.getClass(), requirementSpecListNewRequirementSpecToAttach.getRequirementSpecPK()); - attachedRequirementSpecListNew.add(requirementSpecListNewRequirementSpecToAttach); - } - requirementSpecListNew = attachedRequirementSpecListNew; - project.setRequirementSpecList(requirementSpecListNew); - List attachedHistoryListNew = new ArrayList(); - for (History historyListNewHistoryToAttach : historyListNew) { - historyListNewHistoryToAttach = em.getReference(historyListNewHistoryToAttach.getClass(), historyListNewHistoryToAttach.getId()); - attachedHistoryListNew.add(historyListNewHistoryToAttach); - } - historyListNew = attachedHistoryListNew; - project.setHistoryList(historyListNew); - project = em.merge(project); - if (parentProjectIdOld != null && !parentProjectIdOld.equals(parentProjectIdNew)) { - parentProjectIdOld.getProjectList().remove(project); - parentProjectIdOld = em.merge(parentProjectIdOld); - } - if (parentProjectIdNew != null && !parentProjectIdNew.equals(parentProjectIdOld)) { - parentProjectIdNew.getProjectList().add(project); - parentProjectIdNew = em.merge(parentProjectIdNew); - } - for (TestProject testProjectListOldTestProject : testProjectListOld) { - if (!testProjectListNew.contains(testProjectListOldTestProject)) { - testProjectListOldTestProject.getProjectList().remove(project); - testProjectListOldTestProject = em.merge(testProjectListOldTestProject); - } - } - for (TestProject testProjectListNewTestProject : testProjectListNew) { - if (!testProjectListOld.contains(testProjectListNewTestProject)) { - testProjectListNewTestProject.getProjectList().add(project); - testProjectListNewTestProject = em.merge(testProjectListNewTestProject); - } - } - for (Project projectListOldProject : projectListOld) { - if (!projectListNew.contains(projectListOldProject)) { - projectListOldProject.setParentProjectId(null); - projectListOldProject = em.merge(projectListOldProject); - } - } - for (Project projectListNewProject : projectListNew) { - if (!projectListOld.contains(projectListNewProject)) { - Project oldParentProjectIdOfProjectListNewProject = projectListNewProject.getParentProjectId(); - projectListNewProject.setParentProjectId(project); - projectListNewProject = em.merge(projectListNewProject); - if (oldParentProjectIdOfProjectListNewProject != null && !oldParentProjectIdOfProjectListNewProject.equals(project)) { - oldParentProjectIdOfProjectListNewProject.getProjectList().remove(projectListNewProject); - oldParentProjectIdOfProjectListNewProject = em.merge(oldParentProjectIdOfProjectListNewProject); - } - } - } - for (RequirementSpec requirementSpecListNewRequirementSpec : requirementSpecListNew) { - if (!requirementSpecListOld.contains(requirementSpecListNewRequirementSpec)) { - Project oldProjectOfRequirementSpecListNewRequirementSpec = requirementSpecListNewRequirementSpec.getProject(); - requirementSpecListNewRequirementSpec.setProject(project); - requirementSpecListNewRequirementSpec = em.merge(requirementSpecListNewRequirementSpec); - if (oldProjectOfRequirementSpecListNewRequirementSpec != null && !oldProjectOfRequirementSpecListNewRequirementSpec.equals(project)) { - oldProjectOfRequirementSpecListNewRequirementSpec.getRequirementSpecList().remove(requirementSpecListNewRequirementSpec); - oldProjectOfRequirementSpecListNewRequirementSpec = em.merge(oldProjectOfRequirementSpecListNewRequirementSpec); - } - } - } - for (History historyListNewHistory : historyListNew) { - if (!historyListOld.contains(historyListNewHistory)) { - Project oldProjectIdOfHistoryListNewHistory = historyListNewHistory.getProjectId(); - historyListNewHistory.setProjectId(project); - historyListNewHistory = em.merge(historyListNewHistory); - if (oldProjectIdOfHistoryListNewHistory != null && !oldProjectIdOfHistoryListNewHistory.equals(project)) { - oldProjectIdOfHistoryListNewHistory.getHistoryList().remove(historyListNewHistory); - oldProjectIdOfHistoryListNewHistory = em.merge(oldProjectIdOfHistoryListNewHistory); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - Integer id = project.getId(); - if (findProject(id) == null) { - throw new NonexistentEntityException("The project with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - Project project; - try { - project = em.getReference(Project.class, id); - project.getId(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The project with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List requirementSpecListOrphanCheck = project.getRequirementSpecList(); - for (RequirementSpec requirementSpecListOrphanCheckRequirementSpec : requirementSpecListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This Project (" + project + ") cannot be destroyed since the RequirementSpec " + requirementSpecListOrphanCheckRequirementSpec + " in its requirementSpecList field has a non-nullable project field."); - } - List historyListOrphanCheck = project.getHistoryList(); - for (History historyListOrphanCheckHistory : historyListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This Project (" + project + ") cannot be destroyed since the History " + historyListOrphanCheckHistory + " in its historyList field has a non-nullable projectId field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - Project parentProjectId = project.getParentProjectId(); - if (parentProjectId != null) { - parentProjectId.getProjectList().remove(project); - parentProjectId = em.merge(parentProjectId); - } - List testProjectList = project.getTestProjectList(); - for (TestProject testProjectListTestProject : testProjectList) { - testProjectListTestProject.getProjectList().remove(project); - testProjectListTestProject = em.merge(testProjectListTestProject); - } - List projectList = project.getProjectList(); - for (Project projectListProject : projectList) { - projectListProject.setParentProjectId(null); - projectListProject = em.merge(projectListProject); - } - em.remove(project); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findProjectEntities() { - return findProjectEntities(true, -1, -1); - } - - public List findProjectEntities(int maxResults, int firstResult) { - return findProjectEntities(false, maxResults, firstResult); - } - - private List findProjectEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(Project.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public Project findProject(Integer id) { - EntityManager em = getEntityManager(); - try { - return em.find(Project.class, id); - } - finally { - em.close(); - } - } - - public int getProjectCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(Project.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.Project; +import com.validation.manager.core.db.TestProject; +import java.util.ArrayList; +import java.util.List; +import com.validation.manager.core.db.RequirementSpec; +import com.validation.manager.core.db.History; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class ProjectJpaController implements Serializable { + + public ProjectJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(Project project) { + if (project.getTestProjectList() == null) { + project.setTestProjectList(new ArrayList<>()); + } + if (project.getProjectList() == null) { + project.setProjectList(new ArrayList<>()); + } + if (project.getRequirementSpecList() == null) { + project.setRequirementSpecList(new ArrayList<>()); + } + if (project.getHistoryList() == null) { + project.setHistoryList(new ArrayList<>()); + } + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + Project parentProjectId = project.getParentProjectId(); + if (parentProjectId != null) { + parentProjectId = em.getReference(parentProjectId.getClass(), parentProjectId.getId()); + project.setParentProjectId(parentProjectId); + } + List attachedTestProjectList = new ArrayList<>(); + for (TestProject testProjectListTestProjectToAttach : project.getTestProjectList()) { + testProjectListTestProjectToAttach = em.getReference(testProjectListTestProjectToAttach.getClass(), testProjectListTestProjectToAttach.getId()); + attachedTestProjectList.add(testProjectListTestProjectToAttach); + } + project.setTestProjectList(attachedTestProjectList); + List attachedProjectList = new ArrayList<>(); + for (Project projectListProjectToAttach : project.getProjectList()) { + projectListProjectToAttach = em.getReference(projectListProjectToAttach.getClass(), projectListProjectToAttach.getId()); + attachedProjectList.add(projectListProjectToAttach); + } + project.setProjectList(attachedProjectList); + List attachedRequirementSpecList = new ArrayList<>(); + for (RequirementSpec requirementSpecListRequirementSpecToAttach : project.getRequirementSpecList()) { + requirementSpecListRequirementSpecToAttach = em.getReference(requirementSpecListRequirementSpecToAttach.getClass(), requirementSpecListRequirementSpecToAttach.getRequirementSpecPK()); + attachedRequirementSpecList.add(requirementSpecListRequirementSpecToAttach); + } + project.setRequirementSpecList(attachedRequirementSpecList); + List attachedHistoryList = new ArrayList<>(); + for (History historyListHistoryToAttach : project.getHistoryList()) { + historyListHistoryToAttach = em.getReference(historyListHistoryToAttach.getClass(), historyListHistoryToAttach.getId()); + attachedHistoryList.add(historyListHistoryToAttach); + } + project.setHistoryList(attachedHistoryList); + em.persist(project); + if (parentProjectId != null) { + parentProjectId.getProjectList().add(project); + parentProjectId = em.merge(parentProjectId); + } + for (TestProject testProjectListTestProject : project.getTestProjectList()) { + testProjectListTestProject.getProjectList().add(project); + testProjectListTestProject = em.merge(testProjectListTestProject); + } + for (Project projectListProject : project.getProjectList()) { + Project oldParentProjectIdOfProjectListProject = projectListProject.getParentProjectId(); + projectListProject.setParentProjectId(project); + projectListProject = em.merge(projectListProject); + if (oldParentProjectIdOfProjectListProject != null) { + oldParentProjectIdOfProjectListProject.getProjectList().remove(projectListProject); + oldParentProjectIdOfProjectListProject = em.merge(oldParentProjectIdOfProjectListProject); + } + } + for (RequirementSpec requirementSpecListRequirementSpec : project.getRequirementSpecList()) { + Project oldProjectOfRequirementSpecListRequirementSpec = requirementSpecListRequirementSpec.getProject(); + requirementSpecListRequirementSpec.setProject(project); + requirementSpecListRequirementSpec = em.merge(requirementSpecListRequirementSpec); + if (oldProjectOfRequirementSpecListRequirementSpec != null) { + oldProjectOfRequirementSpecListRequirementSpec.getRequirementSpecList().remove(requirementSpecListRequirementSpec); + oldProjectOfRequirementSpecListRequirementSpec = em.merge(oldProjectOfRequirementSpecListRequirementSpec); + } + } + for (History historyListHistory : project.getHistoryList()) { + Project oldProjectIdOfHistoryListHistory = historyListHistory.getProjectId(); + historyListHistory.setProjectId(project); + historyListHistory = em.merge(historyListHistory); + if (oldProjectIdOfHistoryListHistory != null) { + oldProjectIdOfHistoryListHistory.getHistoryList().remove(historyListHistory); + oldProjectIdOfHistoryListHistory = em.merge(oldProjectIdOfHistoryListHistory); + } + } + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(Project project) throws IllegalOrphanException, NonexistentEntityException, Exception { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + Project persistentProject = em.find(Project.class, project.getId()); + Project parentProjectIdOld = persistentProject.getParentProjectId(); + Project parentProjectIdNew = project.getParentProjectId(); + List testProjectListOld = persistentProject.getTestProjectList(); + List testProjectListNew = project.getTestProjectList(); + List projectListOld = persistentProject.getProjectList(); + List projectListNew = project.getProjectList(); + List requirementSpecListOld = persistentProject.getRequirementSpecList(); + List requirementSpecListNew = project.getRequirementSpecList(); + List historyListOld = persistentProject.getHistoryList(); + List historyListNew = project.getHistoryList(); + List illegalOrphanMessages = null; + for (RequirementSpec requirementSpecListOldRequirementSpec : requirementSpecListOld) { + if (!requirementSpecListNew.contains(requirementSpecListOldRequirementSpec)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain RequirementSpec " + requirementSpecListOldRequirementSpec + " since its project field is not nullable."); + } + } + for (History historyListOldHistory : historyListOld) { + if (!historyListNew.contains(historyListOldHistory)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain History " + historyListOldHistory + " since its projectId field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + if (parentProjectIdNew != null) { + parentProjectIdNew = em.getReference(parentProjectIdNew.getClass(), parentProjectIdNew.getId()); + project.setParentProjectId(parentProjectIdNew); + } + List attachedTestProjectListNew = new ArrayList<>(); + for (TestProject testProjectListNewTestProjectToAttach : testProjectListNew) { + testProjectListNewTestProjectToAttach = em.getReference(testProjectListNewTestProjectToAttach.getClass(), testProjectListNewTestProjectToAttach.getId()); + attachedTestProjectListNew.add(testProjectListNewTestProjectToAttach); + } + testProjectListNew = attachedTestProjectListNew; + project.setTestProjectList(testProjectListNew); + List attachedProjectListNew = new ArrayList<>(); + for (Project projectListNewProjectToAttach : projectListNew) { + projectListNewProjectToAttach = em.getReference(projectListNewProjectToAttach.getClass(), projectListNewProjectToAttach.getId()); + attachedProjectListNew.add(projectListNewProjectToAttach); + } + projectListNew = attachedProjectListNew; + project.setProjectList(projectListNew); + List attachedRequirementSpecListNew = new ArrayList<>(); + for (RequirementSpec requirementSpecListNewRequirementSpecToAttach : requirementSpecListNew) { + requirementSpecListNewRequirementSpecToAttach = em.getReference(requirementSpecListNewRequirementSpecToAttach.getClass(), requirementSpecListNewRequirementSpecToAttach.getRequirementSpecPK()); + attachedRequirementSpecListNew.add(requirementSpecListNewRequirementSpecToAttach); + } + requirementSpecListNew = attachedRequirementSpecListNew; + project.setRequirementSpecList(requirementSpecListNew); + List attachedHistoryListNew = new ArrayList<>(); + for (History historyListNewHistoryToAttach : historyListNew) { + historyListNewHistoryToAttach = em.getReference(historyListNewHistoryToAttach.getClass(), historyListNewHistoryToAttach.getId()); + attachedHistoryListNew.add(historyListNewHistoryToAttach); + } + historyListNew = attachedHistoryListNew; + project.setHistoryList(historyListNew); + project = em.merge(project); + if (parentProjectIdOld != null && !parentProjectIdOld.equals(parentProjectIdNew)) { + parentProjectIdOld.getProjectList().remove(project); + parentProjectIdOld = em.merge(parentProjectIdOld); + } + if (parentProjectIdNew != null && !parentProjectIdNew.equals(parentProjectIdOld)) { + parentProjectIdNew.getProjectList().add(project); + parentProjectIdNew = em.merge(parentProjectIdNew); + } + for (TestProject testProjectListOldTestProject : testProjectListOld) { + if (!testProjectListNew.contains(testProjectListOldTestProject)) { + testProjectListOldTestProject.getProjectList().remove(project); + testProjectListOldTestProject = em.merge(testProjectListOldTestProject); + } + } + for (TestProject testProjectListNewTestProject : testProjectListNew) { + if (!testProjectListOld.contains(testProjectListNewTestProject)) { + testProjectListNewTestProject.getProjectList().add(project); + testProjectListNewTestProject = em.merge(testProjectListNewTestProject); + } + } + for (Project projectListOldProject : projectListOld) { + if (!projectListNew.contains(projectListOldProject)) { + projectListOldProject.setParentProjectId(null); + projectListOldProject = em.merge(projectListOldProject); + } + } + for (Project projectListNewProject : projectListNew) { + if (!projectListOld.contains(projectListNewProject)) { + Project oldParentProjectIdOfProjectListNewProject = projectListNewProject.getParentProjectId(); + projectListNewProject.setParentProjectId(project); + projectListNewProject = em.merge(projectListNewProject); + if (oldParentProjectIdOfProjectListNewProject != null && !oldParentProjectIdOfProjectListNewProject.equals(project)) { + oldParentProjectIdOfProjectListNewProject.getProjectList().remove(projectListNewProject); + oldParentProjectIdOfProjectListNewProject = em.merge(oldParentProjectIdOfProjectListNewProject); + } + } + } + for (RequirementSpec requirementSpecListNewRequirementSpec : requirementSpecListNew) { + if (!requirementSpecListOld.contains(requirementSpecListNewRequirementSpec)) { + Project oldProjectOfRequirementSpecListNewRequirementSpec = requirementSpecListNewRequirementSpec.getProject(); + requirementSpecListNewRequirementSpec.setProject(project); + requirementSpecListNewRequirementSpec = em.merge(requirementSpecListNewRequirementSpec); + if (oldProjectOfRequirementSpecListNewRequirementSpec != null && !oldProjectOfRequirementSpecListNewRequirementSpec.equals(project)) { + oldProjectOfRequirementSpecListNewRequirementSpec.getRequirementSpecList().remove(requirementSpecListNewRequirementSpec); + oldProjectOfRequirementSpecListNewRequirementSpec = em.merge(oldProjectOfRequirementSpecListNewRequirementSpec); + } + } + } + for (History historyListNewHistory : historyListNew) { + if (!historyListOld.contains(historyListNewHistory)) { + Project oldProjectIdOfHistoryListNewHistory = historyListNewHistory.getProjectId(); + historyListNewHistory.setProjectId(project); + historyListNewHistory = em.merge(historyListNewHistory); + if (oldProjectIdOfHistoryListNewHistory != null && !oldProjectIdOfHistoryListNewHistory.equals(project)) { + oldProjectIdOfHistoryListNewHistory.getHistoryList().remove(historyListNewHistory); + oldProjectIdOfHistoryListNewHistory = em.merge(oldProjectIdOfHistoryListNewHistory); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + Integer id = project.getId(); + if (findProject(id) == null) { + throw new NonexistentEntityException("The project with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + Project project; + try { + project = em.getReference(Project.class, id); + project.getId(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The project with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List requirementSpecListOrphanCheck = project.getRequirementSpecList(); + for (RequirementSpec requirementSpecListOrphanCheckRequirementSpec : requirementSpecListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This Project (" + project + ") cannot be destroyed since the RequirementSpec " + requirementSpecListOrphanCheckRequirementSpec + " in its requirementSpecList field has a non-nullable project field."); + } + List historyListOrphanCheck = project.getHistoryList(); + for (History historyListOrphanCheckHistory : historyListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This Project (" + project + ") cannot be destroyed since the History " + historyListOrphanCheckHistory + " in its historyList field has a non-nullable projectId field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + Project parentProjectId = project.getParentProjectId(); + if (parentProjectId != null) { + parentProjectId.getProjectList().remove(project); + parentProjectId = em.merge(parentProjectId); + } + List testProjectList = project.getTestProjectList(); + for (TestProject testProjectListTestProject : testProjectList) { + testProjectListTestProject.getProjectList().remove(project); + testProjectListTestProject = em.merge(testProjectListTestProject); + } + List projectList = project.getProjectList(); + for (Project projectListProject : projectList) { + projectListProject.setParentProjectId(null); + projectListProject = em.merge(projectListProject); + } + em.remove(project); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findProjectEntities() { + return findProjectEntities(true, -1, -1); + } + + public List findProjectEntities(int maxResults, int firstResult) { + return findProjectEntities(false, maxResults, firstResult); + } + + private List findProjectEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(Project.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public Project findProject(Integer id) { + EntityManager em = getEntityManager(); + try { + return em.find(Project.class, id); + } + finally { + em.close(); + } + } + + public int getProjectCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(Project.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/RequirementJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/RequirementJpaController.java index c18f7889..4e95c09a 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/RequirementJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/RequirementJpaController.java @@ -13,463 +13,463 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.Requirement; -import com.validation.manager.core.db.RequirementSpecNode; -import com.validation.manager.core.db.RequirementStatus; -import com.validation.manager.core.db.RequirementType; -import java.util.ArrayList; -import java.util.List; -import com.validation.manager.core.db.Step; -import com.validation.manager.core.db.RiskControlHasRequirement; -import com.validation.manager.core.db.History; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class RequirementJpaController implements Serializable { - - public RequirementJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(Requirement requirement) { - if (requirement.getRequirementList() == null) { - requirement.setRequirementList(new ArrayList()); - } - if (requirement.getStepList() == null) { - requirement.setStepList(new ArrayList()); - } - if (requirement.getRiskControlHasRequirementList() == null) { - requirement.setRiskControlHasRequirementList(new ArrayList()); - } - if (requirement.getHistoryList() == null) { - requirement.setHistoryList(new ArrayList()); - } - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - Requirement parentRequirementId = requirement.getParentRequirementId(); - if (parentRequirementId != null) { - parentRequirementId = em.getReference(parentRequirementId.getClass(), parentRequirementId.getId()); - requirement.setParentRequirementId(parentRequirementId); - } - RequirementSpecNode requirementSpecNode = requirement.getRequirementSpecNode(); - if (requirementSpecNode != null) { - requirementSpecNode = em.getReference(requirementSpecNode.getClass(), requirementSpecNode.getRequirementSpecNodePK()); - requirement.setRequirementSpecNode(requirementSpecNode); - } - RequirementStatus requirementStatusId = requirement.getRequirementStatusId(); - if (requirementStatusId != null) { - requirementStatusId = em.getReference(requirementStatusId.getClass(), requirementStatusId.getId()); - requirement.setRequirementStatusId(requirementStatusId); - } - RequirementType requirementTypeId = requirement.getRequirementTypeId(); - if (requirementTypeId != null) { - requirementTypeId = em.getReference(requirementTypeId.getClass(), requirementTypeId.getId()); - requirement.setRequirementTypeId(requirementTypeId); - } - List attachedRequirementList = new ArrayList(); - for (Requirement requirementListRequirementToAttach : requirement.getRequirementList()) { - requirementListRequirementToAttach = em.getReference(requirementListRequirementToAttach.getClass(), requirementListRequirementToAttach.getId()); - attachedRequirementList.add(requirementListRequirementToAttach); - } - requirement.setRequirementList(attachedRequirementList); - List attachedStepList = new ArrayList(); - for (Step stepListStepToAttach : requirement.getStepList()) { - stepListStepToAttach = em.getReference(stepListStepToAttach.getClass(), stepListStepToAttach.getStepPK()); - attachedStepList.add(stepListStepToAttach); - } - requirement.setStepList(attachedStepList); - List attachedRiskControlHasRequirementList = new ArrayList(); - for (RiskControlHasRequirement riskControlHasRequirementListRiskControlHasRequirementToAttach : requirement.getRiskControlHasRequirementList()) { - riskControlHasRequirementListRiskControlHasRequirementToAttach = em.getReference(riskControlHasRequirementListRiskControlHasRequirementToAttach.getClass(), riskControlHasRequirementListRiskControlHasRequirementToAttach.getRiskControlHasRequirementPK()); - attachedRiskControlHasRequirementList.add(riskControlHasRequirementListRiskControlHasRequirementToAttach); - } - requirement.setRiskControlHasRequirementList(attachedRiskControlHasRequirementList); - List attachedHistoryList = new ArrayList(); - for (History historyListHistoryToAttach : requirement.getHistoryList()) { - historyListHistoryToAttach = em.getReference(historyListHistoryToAttach.getClass(), historyListHistoryToAttach.getId()); - attachedHistoryList.add(historyListHistoryToAttach); - } - requirement.setHistoryList(attachedHistoryList); - em.persist(requirement); - if (parentRequirementId != null) { - parentRequirementId.getRequirementList().add(requirement); - parentRequirementId = em.merge(parentRequirementId); - } - if (requirementSpecNode != null) { - requirementSpecNode.getRequirementList().add(requirement); - requirementSpecNode = em.merge(requirementSpecNode); - } - if (requirementStatusId != null) { - requirementStatusId.getRequirementList().add(requirement); - requirementStatusId = em.merge(requirementStatusId); - } - if (requirementTypeId != null) { - requirementTypeId.getRequirementList().add(requirement); - requirementTypeId = em.merge(requirementTypeId); - } - for (Requirement requirementListRequirement : requirement.getRequirementList()) { - Requirement oldParentRequirementIdOfRequirementListRequirement = requirementListRequirement.getParentRequirementId(); - requirementListRequirement.setParentRequirementId(requirement); - requirementListRequirement = em.merge(requirementListRequirement); - if (oldParentRequirementIdOfRequirementListRequirement != null) { - oldParentRequirementIdOfRequirementListRequirement.getRequirementList().remove(requirementListRequirement); - oldParentRequirementIdOfRequirementListRequirement = em.merge(oldParentRequirementIdOfRequirementListRequirement); - } - } - for (Step stepListStep : requirement.getStepList()) { - stepListStep.getRequirementList().add(requirement); - stepListStep = em.merge(stepListStep); - } - for (RiskControlHasRequirement riskControlHasRequirementListRiskControlHasRequirement : requirement.getRiskControlHasRequirementList()) { - Requirement oldRequirementOfRiskControlHasRequirementListRiskControlHasRequirement = riskControlHasRequirementListRiskControlHasRequirement.getRequirement(); - riskControlHasRequirementListRiskControlHasRequirement.setRequirement(requirement); - riskControlHasRequirementListRiskControlHasRequirement = em.merge(riskControlHasRequirementListRiskControlHasRequirement); - if (oldRequirementOfRiskControlHasRequirementListRiskControlHasRequirement != null) { - oldRequirementOfRiskControlHasRequirementListRiskControlHasRequirement.getRiskControlHasRequirementList().remove(riskControlHasRequirementListRiskControlHasRequirement); - oldRequirementOfRiskControlHasRequirementListRiskControlHasRequirement = em.merge(oldRequirementOfRiskControlHasRequirementListRiskControlHasRequirement); - } - } - for (History historyListHistory : requirement.getHistoryList()) { - Requirement oldRequirementIdOfHistoryListHistory = historyListHistory.getRequirementId(); - historyListHistory.setRequirementId(requirement); - historyListHistory = em.merge(historyListHistory); - if (oldRequirementIdOfHistoryListHistory != null) { - oldRequirementIdOfHistoryListHistory.getHistoryList().remove(historyListHistory); - oldRequirementIdOfHistoryListHistory = em.merge(oldRequirementIdOfHistoryListHistory); - } - } - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(Requirement requirement) throws IllegalOrphanException, NonexistentEntityException, Exception { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - Requirement persistentRequirement = em.find(Requirement.class, requirement.getId()); - Requirement parentRequirementIdOld = persistentRequirement.getParentRequirementId(); - Requirement parentRequirementIdNew = requirement.getParentRequirementId(); - RequirementSpecNode requirementSpecNodeOld = persistentRequirement.getRequirementSpecNode(); - RequirementSpecNode requirementSpecNodeNew = requirement.getRequirementSpecNode(); - RequirementStatus requirementStatusIdOld = persistentRequirement.getRequirementStatusId(); - RequirementStatus requirementStatusIdNew = requirement.getRequirementStatusId(); - RequirementType requirementTypeIdOld = persistentRequirement.getRequirementTypeId(); - RequirementType requirementTypeIdNew = requirement.getRequirementTypeId(); - List requirementListOld = persistentRequirement.getRequirementList(); - List requirementListNew = requirement.getRequirementList(); - List stepListOld = persistentRequirement.getStepList(); - List stepListNew = requirement.getStepList(); - List riskControlHasRequirementListOld = persistentRequirement.getRiskControlHasRequirementList(); - List riskControlHasRequirementListNew = requirement.getRiskControlHasRequirementList(); - List historyListOld = persistentRequirement.getHistoryList(); - List historyListNew = requirement.getHistoryList(); - List illegalOrphanMessages = null; - for (RiskControlHasRequirement riskControlHasRequirementListOldRiskControlHasRequirement : riskControlHasRequirementListOld) { - if (!riskControlHasRequirementListNew.contains(riskControlHasRequirementListOldRiskControlHasRequirement)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain RiskControlHasRequirement " + riskControlHasRequirementListOldRiskControlHasRequirement + " since its requirement field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - if (parentRequirementIdNew != null) { - parentRequirementIdNew = em.getReference(parentRequirementIdNew.getClass(), parentRequirementIdNew.getId()); - requirement.setParentRequirementId(parentRequirementIdNew); - } - if (requirementSpecNodeNew != null) { - requirementSpecNodeNew = em.getReference(requirementSpecNodeNew.getClass(), requirementSpecNodeNew.getRequirementSpecNodePK()); - requirement.setRequirementSpecNode(requirementSpecNodeNew); - } - if (requirementStatusIdNew != null) { - requirementStatusIdNew = em.getReference(requirementStatusIdNew.getClass(), requirementStatusIdNew.getId()); - requirement.setRequirementStatusId(requirementStatusIdNew); - } - if (requirementTypeIdNew != null) { - requirementTypeIdNew = em.getReference(requirementTypeIdNew.getClass(), requirementTypeIdNew.getId()); - requirement.setRequirementTypeId(requirementTypeIdNew); - } - List attachedRequirementListNew = new ArrayList(); - for (Requirement requirementListNewRequirementToAttach : requirementListNew) { - requirementListNewRequirementToAttach = em.getReference(requirementListNewRequirementToAttach.getClass(), requirementListNewRequirementToAttach.getId()); - attachedRequirementListNew.add(requirementListNewRequirementToAttach); - } - requirementListNew = attachedRequirementListNew; - requirement.setRequirementList(requirementListNew); - List attachedStepListNew = new ArrayList(); - for (Step stepListNewStepToAttach : stepListNew) { - stepListNewStepToAttach = em.getReference(stepListNewStepToAttach.getClass(), stepListNewStepToAttach.getStepPK()); - attachedStepListNew.add(stepListNewStepToAttach); - } - stepListNew = attachedStepListNew; - requirement.setStepList(stepListNew); - List attachedRiskControlHasRequirementListNew = new ArrayList(); - for (RiskControlHasRequirement riskControlHasRequirementListNewRiskControlHasRequirementToAttach : riskControlHasRequirementListNew) { - riskControlHasRequirementListNewRiskControlHasRequirementToAttach = em.getReference(riskControlHasRequirementListNewRiskControlHasRequirementToAttach.getClass(), riskControlHasRequirementListNewRiskControlHasRequirementToAttach.getRiskControlHasRequirementPK()); - attachedRiskControlHasRequirementListNew.add(riskControlHasRequirementListNewRiskControlHasRequirementToAttach); - } - riskControlHasRequirementListNew = attachedRiskControlHasRequirementListNew; - requirement.setRiskControlHasRequirementList(riskControlHasRequirementListNew); - List attachedHistoryListNew = new ArrayList(); - for (History historyListNewHistoryToAttach : historyListNew) { - historyListNewHistoryToAttach = em.getReference(historyListNewHistoryToAttach.getClass(), historyListNewHistoryToAttach.getId()); - attachedHistoryListNew.add(historyListNewHistoryToAttach); - } - historyListNew = attachedHistoryListNew; - requirement.setHistoryList(historyListNew); - requirement = em.merge(requirement); - if (parentRequirementIdOld != null && !parentRequirementIdOld.equals(parentRequirementIdNew)) { - parentRequirementIdOld.getRequirementList().remove(requirement); - parentRequirementIdOld = em.merge(parentRequirementIdOld); - } - if (parentRequirementIdNew != null && !parentRequirementIdNew.equals(parentRequirementIdOld)) { - parentRequirementIdNew.getRequirementList().add(requirement); - parentRequirementIdNew = em.merge(parentRequirementIdNew); - } - if (requirementSpecNodeOld != null && !requirementSpecNodeOld.equals(requirementSpecNodeNew)) { - requirementSpecNodeOld.getRequirementList().remove(requirement); - requirementSpecNodeOld = em.merge(requirementSpecNodeOld); - } - if (requirementSpecNodeNew != null && !requirementSpecNodeNew.equals(requirementSpecNodeOld)) { - requirementSpecNodeNew.getRequirementList().add(requirement); - requirementSpecNodeNew = em.merge(requirementSpecNodeNew); - } - if (requirementStatusIdOld != null && !requirementStatusIdOld.equals(requirementStatusIdNew)) { - requirementStatusIdOld.getRequirementList().remove(requirement); - requirementStatusIdOld = em.merge(requirementStatusIdOld); - } - if (requirementStatusIdNew != null && !requirementStatusIdNew.equals(requirementStatusIdOld)) { - requirementStatusIdNew.getRequirementList().add(requirement); - requirementStatusIdNew = em.merge(requirementStatusIdNew); - } - if (requirementTypeIdOld != null && !requirementTypeIdOld.equals(requirementTypeIdNew)) { - requirementTypeIdOld.getRequirementList().remove(requirement); - requirementTypeIdOld = em.merge(requirementTypeIdOld); - } - if (requirementTypeIdNew != null && !requirementTypeIdNew.equals(requirementTypeIdOld)) { - requirementTypeIdNew.getRequirementList().add(requirement); - requirementTypeIdNew = em.merge(requirementTypeIdNew); - } - for (Requirement requirementListOldRequirement : requirementListOld) { - if (!requirementListNew.contains(requirementListOldRequirement)) { - requirementListOldRequirement.setParentRequirementId(null); - requirementListOldRequirement = em.merge(requirementListOldRequirement); - } - } - for (Requirement requirementListNewRequirement : requirementListNew) { - if (!requirementListOld.contains(requirementListNewRequirement)) { - Requirement oldParentRequirementIdOfRequirementListNewRequirement = requirementListNewRequirement.getParentRequirementId(); - requirementListNewRequirement.setParentRequirementId(requirement); - requirementListNewRequirement = em.merge(requirementListNewRequirement); - if (oldParentRequirementIdOfRequirementListNewRequirement != null && !oldParentRequirementIdOfRequirementListNewRequirement.equals(requirement)) { - oldParentRequirementIdOfRequirementListNewRequirement.getRequirementList().remove(requirementListNewRequirement); - oldParentRequirementIdOfRequirementListNewRequirement = em.merge(oldParentRequirementIdOfRequirementListNewRequirement); - } - } - } - for (Step stepListOldStep : stepListOld) { - if (!stepListNew.contains(stepListOldStep)) { - stepListOldStep.getRequirementList().remove(requirement); - stepListOldStep = em.merge(stepListOldStep); - } - } - for (Step stepListNewStep : stepListNew) { - if (!stepListOld.contains(stepListNewStep)) { - stepListNewStep.getRequirementList().add(requirement); - stepListNewStep = em.merge(stepListNewStep); - } - } - for (RiskControlHasRequirement riskControlHasRequirementListNewRiskControlHasRequirement : riskControlHasRequirementListNew) { - if (!riskControlHasRequirementListOld.contains(riskControlHasRequirementListNewRiskControlHasRequirement)) { - Requirement oldRequirementOfRiskControlHasRequirementListNewRiskControlHasRequirement = riskControlHasRequirementListNewRiskControlHasRequirement.getRequirement(); - riskControlHasRequirementListNewRiskControlHasRequirement.setRequirement(requirement); - riskControlHasRequirementListNewRiskControlHasRequirement = em.merge(riskControlHasRequirementListNewRiskControlHasRequirement); - if (oldRequirementOfRiskControlHasRequirementListNewRiskControlHasRequirement != null && !oldRequirementOfRiskControlHasRequirementListNewRiskControlHasRequirement.equals(requirement)) { - oldRequirementOfRiskControlHasRequirementListNewRiskControlHasRequirement.getRiskControlHasRequirementList().remove(riskControlHasRequirementListNewRiskControlHasRequirement); - oldRequirementOfRiskControlHasRequirementListNewRiskControlHasRequirement = em.merge(oldRequirementOfRiskControlHasRequirementListNewRiskControlHasRequirement); - } - } - } - for (History historyListOldHistory : historyListOld) { - if (!historyListNew.contains(historyListOldHistory)) { - historyListOldHistory.setRequirementId(null); - historyListOldHistory = em.merge(historyListOldHistory); - } - } - for (History historyListNewHistory : historyListNew) { - if (!historyListOld.contains(historyListNewHistory)) { - Requirement oldRequirementIdOfHistoryListNewHistory = historyListNewHistory.getRequirementId(); - historyListNewHistory.setRequirementId(requirement); - historyListNewHistory = em.merge(historyListNewHistory); - if (oldRequirementIdOfHistoryListNewHistory != null && !oldRequirementIdOfHistoryListNewHistory.equals(requirement)) { - oldRequirementIdOfHistoryListNewHistory.getHistoryList().remove(historyListNewHistory); - oldRequirementIdOfHistoryListNewHistory = em.merge(oldRequirementIdOfHistoryListNewHistory); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - Integer id = requirement.getId(); - if (findRequirement(id) == null) { - throw new NonexistentEntityException("The requirement with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - Requirement requirement; - try { - requirement = em.getReference(Requirement.class, id); - requirement.getId(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The requirement with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List riskControlHasRequirementListOrphanCheck = requirement.getRiskControlHasRequirementList(); - for (RiskControlHasRequirement riskControlHasRequirementListOrphanCheckRiskControlHasRequirement : riskControlHasRequirementListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This Requirement (" + requirement + ") cannot be destroyed since the RiskControlHasRequirement " + riskControlHasRequirementListOrphanCheckRiskControlHasRequirement + " in its riskControlHasRequirementList field has a non-nullable requirement field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - Requirement parentRequirementId = requirement.getParentRequirementId(); - if (parentRequirementId != null) { - parentRequirementId.getRequirementList().remove(requirement); - parentRequirementId = em.merge(parentRequirementId); - } - RequirementSpecNode requirementSpecNode = requirement.getRequirementSpecNode(); - if (requirementSpecNode != null) { - requirementSpecNode.getRequirementList().remove(requirement); - requirementSpecNode = em.merge(requirementSpecNode); - } - RequirementStatus requirementStatusId = requirement.getRequirementStatusId(); - if (requirementStatusId != null) { - requirementStatusId.getRequirementList().remove(requirement); - requirementStatusId = em.merge(requirementStatusId); - } - RequirementType requirementTypeId = requirement.getRequirementTypeId(); - if (requirementTypeId != null) { - requirementTypeId.getRequirementList().remove(requirement); - requirementTypeId = em.merge(requirementTypeId); - } - List requirementList = requirement.getRequirementList(); - for (Requirement requirementListRequirement : requirementList) { - requirementListRequirement.setParentRequirementId(null); - requirementListRequirement = em.merge(requirementListRequirement); - } - List stepList = requirement.getStepList(); - for (Step stepListStep : stepList) { - stepListStep.getRequirementList().remove(requirement); - stepListStep = em.merge(stepListStep); - } - List historyList = requirement.getHistoryList(); - for (History historyListHistory : historyList) { - historyListHistory.setRequirementId(null); - historyListHistory = em.merge(historyListHistory); - } - em.remove(requirement); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findRequirementEntities() { - return findRequirementEntities(true, -1, -1); - } - - public List findRequirementEntities(int maxResults, int firstResult) { - return findRequirementEntities(false, maxResults, firstResult); - } - - private List findRequirementEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(Requirement.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public Requirement findRequirement(Integer id) { - EntityManager em = getEntityManager(); - try { - return em.find(Requirement.class, id); - } - finally { - em.close(); - } - } - - public int getRequirementCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(Requirement.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.Requirement; +import com.validation.manager.core.db.RequirementSpecNode; +import com.validation.manager.core.db.RequirementStatus; +import com.validation.manager.core.db.RequirementType; +import java.util.ArrayList; +import java.util.List; +import com.validation.manager.core.db.Step; +import com.validation.manager.core.db.RiskControlHasRequirement; +import com.validation.manager.core.db.History; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class RequirementJpaController implements Serializable { + + public RequirementJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(Requirement requirement) { + if (requirement.getRequirementList() == null) { + requirement.setRequirementList(new ArrayList<>()); + } + if (requirement.getStepList() == null) { + requirement.setStepList(new ArrayList<>()); + } + if (requirement.getRiskControlHasRequirementList() == null) { + requirement.setRiskControlHasRequirementList(new ArrayList<>()); + } + if (requirement.getHistoryList() == null) { + requirement.setHistoryList(new ArrayList<>()); + } + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + Requirement parentRequirementId = requirement.getParentRequirementId(); + if (parentRequirementId != null) { + parentRequirementId = em.getReference(parentRequirementId.getClass(), parentRequirementId.getId()); + requirement.setParentRequirementId(parentRequirementId); + } + RequirementSpecNode requirementSpecNode = requirement.getRequirementSpecNode(); + if (requirementSpecNode != null) { + requirementSpecNode = em.getReference(requirementSpecNode.getClass(), requirementSpecNode.getRequirementSpecNodePK()); + requirement.setRequirementSpecNode(requirementSpecNode); + } + RequirementStatus requirementStatusId = requirement.getRequirementStatusId(); + if (requirementStatusId != null) { + requirementStatusId = em.getReference(requirementStatusId.getClass(), requirementStatusId.getId()); + requirement.setRequirementStatusId(requirementStatusId); + } + RequirementType requirementTypeId = requirement.getRequirementTypeId(); + if (requirementTypeId != null) { + requirementTypeId = em.getReference(requirementTypeId.getClass(), requirementTypeId.getId()); + requirement.setRequirementTypeId(requirementTypeId); + } + List attachedRequirementList = new ArrayList<>(); + for (Requirement requirementListRequirementToAttach : requirement.getRequirementList()) { + requirementListRequirementToAttach = em.getReference(requirementListRequirementToAttach.getClass(), requirementListRequirementToAttach.getId()); + attachedRequirementList.add(requirementListRequirementToAttach); + } + requirement.setRequirementList(attachedRequirementList); + List attachedStepList = new ArrayList<>(); + for (Step stepListStepToAttach : requirement.getStepList()) { + stepListStepToAttach = em.getReference(stepListStepToAttach.getClass(), stepListStepToAttach.getStepPK()); + attachedStepList.add(stepListStepToAttach); + } + requirement.setStepList(attachedStepList); + List attachedRiskControlHasRequirementList = new ArrayList<>(); + for (RiskControlHasRequirement riskControlHasRequirementListRiskControlHasRequirementToAttach : requirement.getRiskControlHasRequirementList()) { + riskControlHasRequirementListRiskControlHasRequirementToAttach = em.getReference(riskControlHasRequirementListRiskControlHasRequirementToAttach.getClass(), riskControlHasRequirementListRiskControlHasRequirementToAttach.getRiskControlHasRequirementPK()); + attachedRiskControlHasRequirementList.add(riskControlHasRequirementListRiskControlHasRequirementToAttach); + } + requirement.setRiskControlHasRequirementList(attachedRiskControlHasRequirementList); + List attachedHistoryList = new ArrayList<>(); + for (History historyListHistoryToAttach : requirement.getHistoryList()) { + historyListHistoryToAttach = em.getReference(historyListHistoryToAttach.getClass(), historyListHistoryToAttach.getId()); + attachedHistoryList.add(historyListHistoryToAttach); + } + requirement.setHistoryList(attachedHistoryList); + em.persist(requirement); + if (parentRequirementId != null) { + parentRequirementId.getRequirementList().add(requirement); + parentRequirementId = em.merge(parentRequirementId); + } + if (requirementSpecNode != null) { + requirementSpecNode.getRequirementList().add(requirement); + requirementSpecNode = em.merge(requirementSpecNode); + } + if (requirementStatusId != null) { + requirementStatusId.getRequirementList().add(requirement); + requirementStatusId = em.merge(requirementStatusId); + } + if (requirementTypeId != null) { + requirementTypeId.getRequirementList().add(requirement); + requirementTypeId = em.merge(requirementTypeId); + } + for (Requirement requirementListRequirement : requirement.getRequirementList()) { + Requirement oldParentRequirementIdOfRequirementListRequirement = requirementListRequirement.getParentRequirementId(); + requirementListRequirement.setParentRequirementId(requirement); + requirementListRequirement = em.merge(requirementListRequirement); + if (oldParentRequirementIdOfRequirementListRequirement != null) { + oldParentRequirementIdOfRequirementListRequirement.getRequirementList().remove(requirementListRequirement); + oldParentRequirementIdOfRequirementListRequirement = em.merge(oldParentRequirementIdOfRequirementListRequirement); + } + } + for (Step stepListStep : requirement.getStepList()) { + stepListStep.getRequirementList().add(requirement); + stepListStep = em.merge(stepListStep); + } + for (RiskControlHasRequirement riskControlHasRequirementListRiskControlHasRequirement : requirement.getRiskControlHasRequirementList()) { + Requirement oldRequirementOfRiskControlHasRequirementListRiskControlHasRequirement = riskControlHasRequirementListRiskControlHasRequirement.getRequirement(); + riskControlHasRequirementListRiskControlHasRequirement.setRequirement(requirement); + riskControlHasRequirementListRiskControlHasRequirement = em.merge(riskControlHasRequirementListRiskControlHasRequirement); + if (oldRequirementOfRiskControlHasRequirementListRiskControlHasRequirement != null) { + oldRequirementOfRiskControlHasRequirementListRiskControlHasRequirement.getRiskControlHasRequirementList().remove(riskControlHasRequirementListRiskControlHasRequirement); + oldRequirementOfRiskControlHasRequirementListRiskControlHasRequirement = em.merge(oldRequirementOfRiskControlHasRequirementListRiskControlHasRequirement); + } + } + for (History historyListHistory : requirement.getHistoryList()) { + Requirement oldRequirementIdOfHistoryListHistory = historyListHistory.getRequirementId(); + historyListHistory.setRequirementId(requirement); + historyListHistory = em.merge(historyListHistory); + if (oldRequirementIdOfHistoryListHistory != null) { + oldRequirementIdOfHistoryListHistory.getHistoryList().remove(historyListHistory); + oldRequirementIdOfHistoryListHistory = em.merge(oldRequirementIdOfHistoryListHistory); + } + } + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(Requirement requirement) throws IllegalOrphanException, NonexistentEntityException, Exception { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + Requirement persistentRequirement = em.find(Requirement.class, requirement.getId()); + Requirement parentRequirementIdOld = persistentRequirement.getParentRequirementId(); + Requirement parentRequirementIdNew = requirement.getParentRequirementId(); + RequirementSpecNode requirementSpecNodeOld = persistentRequirement.getRequirementSpecNode(); + RequirementSpecNode requirementSpecNodeNew = requirement.getRequirementSpecNode(); + RequirementStatus requirementStatusIdOld = persistentRequirement.getRequirementStatusId(); + RequirementStatus requirementStatusIdNew = requirement.getRequirementStatusId(); + RequirementType requirementTypeIdOld = persistentRequirement.getRequirementTypeId(); + RequirementType requirementTypeIdNew = requirement.getRequirementTypeId(); + List requirementListOld = persistentRequirement.getRequirementList(); + List requirementListNew = requirement.getRequirementList(); + List stepListOld = persistentRequirement.getStepList(); + List stepListNew = requirement.getStepList(); + List riskControlHasRequirementListOld = persistentRequirement.getRiskControlHasRequirementList(); + List riskControlHasRequirementListNew = requirement.getRiskControlHasRequirementList(); + List historyListOld = persistentRequirement.getHistoryList(); + List historyListNew = requirement.getHistoryList(); + List illegalOrphanMessages = null; + for (RiskControlHasRequirement riskControlHasRequirementListOldRiskControlHasRequirement : riskControlHasRequirementListOld) { + if (!riskControlHasRequirementListNew.contains(riskControlHasRequirementListOldRiskControlHasRequirement)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain RiskControlHasRequirement " + riskControlHasRequirementListOldRiskControlHasRequirement + " since its requirement field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + if (parentRequirementIdNew != null) { + parentRequirementIdNew = em.getReference(parentRequirementIdNew.getClass(), parentRequirementIdNew.getId()); + requirement.setParentRequirementId(parentRequirementIdNew); + } + if (requirementSpecNodeNew != null) { + requirementSpecNodeNew = em.getReference(requirementSpecNodeNew.getClass(), requirementSpecNodeNew.getRequirementSpecNodePK()); + requirement.setRequirementSpecNode(requirementSpecNodeNew); + } + if (requirementStatusIdNew != null) { + requirementStatusIdNew = em.getReference(requirementStatusIdNew.getClass(), requirementStatusIdNew.getId()); + requirement.setRequirementStatusId(requirementStatusIdNew); + } + if (requirementTypeIdNew != null) { + requirementTypeIdNew = em.getReference(requirementTypeIdNew.getClass(), requirementTypeIdNew.getId()); + requirement.setRequirementTypeId(requirementTypeIdNew); + } + List attachedRequirementListNew = new ArrayList<>(); + for (Requirement requirementListNewRequirementToAttach : requirementListNew) { + requirementListNewRequirementToAttach = em.getReference(requirementListNewRequirementToAttach.getClass(), requirementListNewRequirementToAttach.getId()); + attachedRequirementListNew.add(requirementListNewRequirementToAttach); + } + requirementListNew = attachedRequirementListNew; + requirement.setRequirementList(requirementListNew); + List attachedStepListNew = new ArrayList<>(); + for (Step stepListNewStepToAttach : stepListNew) { + stepListNewStepToAttach = em.getReference(stepListNewStepToAttach.getClass(), stepListNewStepToAttach.getStepPK()); + attachedStepListNew.add(stepListNewStepToAttach); + } + stepListNew = attachedStepListNew; + requirement.setStepList(stepListNew); + List attachedRiskControlHasRequirementListNew = new ArrayList<>(); + for (RiskControlHasRequirement riskControlHasRequirementListNewRiskControlHasRequirementToAttach : riskControlHasRequirementListNew) { + riskControlHasRequirementListNewRiskControlHasRequirementToAttach = em.getReference(riskControlHasRequirementListNewRiskControlHasRequirementToAttach.getClass(), riskControlHasRequirementListNewRiskControlHasRequirementToAttach.getRiskControlHasRequirementPK()); + attachedRiskControlHasRequirementListNew.add(riskControlHasRequirementListNewRiskControlHasRequirementToAttach); + } + riskControlHasRequirementListNew = attachedRiskControlHasRequirementListNew; + requirement.setRiskControlHasRequirementList(riskControlHasRequirementListNew); + List attachedHistoryListNew = new ArrayList<>(); + for (History historyListNewHistoryToAttach : historyListNew) { + historyListNewHistoryToAttach = em.getReference(historyListNewHistoryToAttach.getClass(), historyListNewHistoryToAttach.getId()); + attachedHistoryListNew.add(historyListNewHistoryToAttach); + } + historyListNew = attachedHistoryListNew; + requirement.setHistoryList(historyListNew); + requirement = em.merge(requirement); + if (parentRequirementIdOld != null && !parentRequirementIdOld.equals(parentRequirementIdNew)) { + parentRequirementIdOld.getRequirementList().remove(requirement); + parentRequirementIdOld = em.merge(parentRequirementIdOld); + } + if (parentRequirementIdNew != null && !parentRequirementIdNew.equals(parentRequirementIdOld)) { + parentRequirementIdNew.getRequirementList().add(requirement); + parentRequirementIdNew = em.merge(parentRequirementIdNew); + } + if (requirementSpecNodeOld != null && !requirementSpecNodeOld.equals(requirementSpecNodeNew)) { + requirementSpecNodeOld.getRequirementList().remove(requirement); + requirementSpecNodeOld = em.merge(requirementSpecNodeOld); + } + if (requirementSpecNodeNew != null && !requirementSpecNodeNew.equals(requirementSpecNodeOld)) { + requirementSpecNodeNew.getRequirementList().add(requirement); + requirementSpecNodeNew = em.merge(requirementSpecNodeNew); + } + if (requirementStatusIdOld != null && !requirementStatusIdOld.equals(requirementStatusIdNew)) { + requirementStatusIdOld.getRequirementList().remove(requirement); + requirementStatusIdOld = em.merge(requirementStatusIdOld); + } + if (requirementStatusIdNew != null && !requirementStatusIdNew.equals(requirementStatusIdOld)) { + requirementStatusIdNew.getRequirementList().add(requirement); + requirementStatusIdNew = em.merge(requirementStatusIdNew); + } + if (requirementTypeIdOld != null && !requirementTypeIdOld.equals(requirementTypeIdNew)) { + requirementTypeIdOld.getRequirementList().remove(requirement); + requirementTypeIdOld = em.merge(requirementTypeIdOld); + } + if (requirementTypeIdNew != null && !requirementTypeIdNew.equals(requirementTypeIdOld)) { + requirementTypeIdNew.getRequirementList().add(requirement); + requirementTypeIdNew = em.merge(requirementTypeIdNew); + } + for (Requirement requirementListOldRequirement : requirementListOld) { + if (!requirementListNew.contains(requirementListOldRequirement)) { + requirementListOldRequirement.setParentRequirementId(null); + requirementListOldRequirement = em.merge(requirementListOldRequirement); + } + } + for (Requirement requirementListNewRequirement : requirementListNew) { + if (!requirementListOld.contains(requirementListNewRequirement)) { + Requirement oldParentRequirementIdOfRequirementListNewRequirement = requirementListNewRequirement.getParentRequirementId(); + requirementListNewRequirement.setParentRequirementId(requirement); + requirementListNewRequirement = em.merge(requirementListNewRequirement); + if (oldParentRequirementIdOfRequirementListNewRequirement != null && !oldParentRequirementIdOfRequirementListNewRequirement.equals(requirement)) { + oldParentRequirementIdOfRequirementListNewRequirement.getRequirementList().remove(requirementListNewRequirement); + oldParentRequirementIdOfRequirementListNewRequirement = em.merge(oldParentRequirementIdOfRequirementListNewRequirement); + } + } + } + for (Step stepListOldStep : stepListOld) { + if (!stepListNew.contains(stepListOldStep)) { + stepListOldStep.getRequirementList().remove(requirement); + stepListOldStep = em.merge(stepListOldStep); + } + } + for (Step stepListNewStep : stepListNew) { + if (!stepListOld.contains(stepListNewStep)) { + stepListNewStep.getRequirementList().add(requirement); + stepListNewStep = em.merge(stepListNewStep); + } + } + for (RiskControlHasRequirement riskControlHasRequirementListNewRiskControlHasRequirement : riskControlHasRequirementListNew) { + if (!riskControlHasRequirementListOld.contains(riskControlHasRequirementListNewRiskControlHasRequirement)) { + Requirement oldRequirementOfRiskControlHasRequirementListNewRiskControlHasRequirement = riskControlHasRequirementListNewRiskControlHasRequirement.getRequirement(); + riskControlHasRequirementListNewRiskControlHasRequirement.setRequirement(requirement); + riskControlHasRequirementListNewRiskControlHasRequirement = em.merge(riskControlHasRequirementListNewRiskControlHasRequirement); + if (oldRequirementOfRiskControlHasRequirementListNewRiskControlHasRequirement != null && !oldRequirementOfRiskControlHasRequirementListNewRiskControlHasRequirement.equals(requirement)) { + oldRequirementOfRiskControlHasRequirementListNewRiskControlHasRequirement.getRiskControlHasRequirementList().remove(riskControlHasRequirementListNewRiskControlHasRequirement); + oldRequirementOfRiskControlHasRequirementListNewRiskControlHasRequirement = em.merge(oldRequirementOfRiskControlHasRequirementListNewRiskControlHasRequirement); + } + } + } + for (History historyListOldHistory : historyListOld) { + if (!historyListNew.contains(historyListOldHistory)) { + historyListOldHistory.setRequirementId(null); + historyListOldHistory = em.merge(historyListOldHistory); + } + } + for (History historyListNewHistory : historyListNew) { + if (!historyListOld.contains(historyListNewHistory)) { + Requirement oldRequirementIdOfHistoryListNewHistory = historyListNewHistory.getRequirementId(); + historyListNewHistory.setRequirementId(requirement); + historyListNewHistory = em.merge(historyListNewHistory); + if (oldRequirementIdOfHistoryListNewHistory != null && !oldRequirementIdOfHistoryListNewHistory.equals(requirement)) { + oldRequirementIdOfHistoryListNewHistory.getHistoryList().remove(historyListNewHistory); + oldRequirementIdOfHistoryListNewHistory = em.merge(oldRequirementIdOfHistoryListNewHistory); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + Integer id = requirement.getId(); + if (findRequirement(id) == null) { + throw new NonexistentEntityException("The requirement with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + Requirement requirement; + try { + requirement = em.getReference(Requirement.class, id); + requirement.getId(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The requirement with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List riskControlHasRequirementListOrphanCheck = requirement.getRiskControlHasRequirementList(); + for (RiskControlHasRequirement riskControlHasRequirementListOrphanCheckRiskControlHasRequirement : riskControlHasRequirementListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This Requirement (" + requirement + ") cannot be destroyed since the RiskControlHasRequirement " + riskControlHasRequirementListOrphanCheckRiskControlHasRequirement + " in its riskControlHasRequirementList field has a non-nullable requirement field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + Requirement parentRequirementId = requirement.getParentRequirementId(); + if (parentRequirementId != null) { + parentRequirementId.getRequirementList().remove(requirement); + parentRequirementId = em.merge(parentRequirementId); + } + RequirementSpecNode requirementSpecNode = requirement.getRequirementSpecNode(); + if (requirementSpecNode != null) { + requirementSpecNode.getRequirementList().remove(requirement); + requirementSpecNode = em.merge(requirementSpecNode); + } + RequirementStatus requirementStatusId = requirement.getRequirementStatusId(); + if (requirementStatusId != null) { + requirementStatusId.getRequirementList().remove(requirement); + requirementStatusId = em.merge(requirementStatusId); + } + RequirementType requirementTypeId = requirement.getRequirementTypeId(); + if (requirementTypeId != null) { + requirementTypeId.getRequirementList().remove(requirement); + requirementTypeId = em.merge(requirementTypeId); + } + List requirementList = requirement.getRequirementList(); + for (Requirement requirementListRequirement : requirementList) { + requirementListRequirement.setParentRequirementId(null); + requirementListRequirement = em.merge(requirementListRequirement); + } + List stepList = requirement.getStepList(); + for (Step stepListStep : stepList) { + stepListStep.getRequirementList().remove(requirement); + stepListStep = em.merge(stepListStep); + } + List historyList = requirement.getHistoryList(); + for (History historyListHistory : historyList) { + historyListHistory.setRequirementId(null); + historyListHistory = em.merge(historyListHistory); + } + em.remove(requirement); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findRequirementEntities() { + return findRequirementEntities(true, -1, -1); + } + + public List findRequirementEntities(int maxResults, int firstResult) { + return findRequirementEntities(false, maxResults, firstResult); + } + + private List findRequirementEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(Requirement.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public Requirement findRequirement(Integer id) { + EntityManager em = getEntityManager(); + try { + return em.find(Requirement.class, id); + } + finally { + em.close(); + } + } + + public int getRequirementCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(Requirement.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/RequirementSpecJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/RequirementSpecJpaController.java index bcb1d522..47160912 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/RequirementSpecJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/RequirementSpecJpaController.java @@ -13,336 +13,336 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.Project; -import com.validation.manager.core.db.SpecLevel; -import com.validation.manager.core.db.RequirementSpecNode; -import java.util.ArrayList; -import java.util.List; -import com.validation.manager.core.db.Baseline; -import com.validation.manager.core.db.RequirementSpec; -import com.validation.manager.core.db.RequirementSpecPK; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import com.validation.manager.core.db.controller.exceptions.PreexistingEntityException; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class RequirementSpecJpaController implements Serializable { - - public RequirementSpecJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(RequirementSpec requirementSpec) throws PreexistingEntityException, Exception { - if (requirementSpec.getRequirementSpecPK() == null) { - requirementSpec.setRequirementSpecPK(new RequirementSpecPK()); - } - if (requirementSpec.getRequirementSpecNodeList() == null) { - requirementSpec.setRequirementSpecNodeList(new ArrayList()); - } - if (requirementSpec.getBaselineList() == null) { - requirementSpec.setBaselineList(new ArrayList()); - } - requirementSpec.getRequirementSpecPK().setSpecLevelId(requirementSpec.getSpecLevel().getId()); - requirementSpec.getRequirementSpecPK().setProjectId(requirementSpec.getProject().getId()); - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - Project project = requirementSpec.getProject(); - if (project != null) { - project = em.getReference(project.getClass(), project.getId()); - requirementSpec.setProject(project); - } - SpecLevel specLevel = requirementSpec.getSpecLevel(); - if (specLevel != null) { - specLevel = em.getReference(specLevel.getClass(), specLevel.getId()); - requirementSpec.setSpecLevel(specLevel); - } - List attachedRequirementSpecNodeList = new ArrayList(); - for (RequirementSpecNode requirementSpecNodeListRequirementSpecNodeToAttach : requirementSpec.getRequirementSpecNodeList()) { - requirementSpecNodeListRequirementSpecNodeToAttach = em.getReference(requirementSpecNodeListRequirementSpecNodeToAttach.getClass(), requirementSpecNodeListRequirementSpecNodeToAttach.getRequirementSpecNodePK()); - attachedRequirementSpecNodeList.add(requirementSpecNodeListRequirementSpecNodeToAttach); - } - requirementSpec.setRequirementSpecNodeList(attachedRequirementSpecNodeList); - List attachedBaselineList = new ArrayList(); - for (Baseline baselineListBaselineToAttach : requirementSpec.getBaselineList()) { - baselineListBaselineToAttach = em.getReference(baselineListBaselineToAttach.getClass(), baselineListBaselineToAttach.getId()); - attachedBaselineList.add(baselineListBaselineToAttach); - } - requirementSpec.setBaselineList(attachedBaselineList); - em.persist(requirementSpec); - if (project != null) { - project.getRequirementSpecList().add(requirementSpec); - project = em.merge(project); - } - if (specLevel != null) { - specLevel.getRequirementSpecList().add(requirementSpec); - specLevel = em.merge(specLevel); - } - for (RequirementSpecNode requirementSpecNodeListRequirementSpecNode : requirementSpec.getRequirementSpecNodeList()) { - RequirementSpec oldRequirementSpecOfRequirementSpecNodeListRequirementSpecNode = requirementSpecNodeListRequirementSpecNode.getRequirementSpec(); - requirementSpecNodeListRequirementSpecNode.setRequirementSpec(requirementSpec); - requirementSpecNodeListRequirementSpecNode = em.merge(requirementSpecNodeListRequirementSpecNode); - if (oldRequirementSpecOfRequirementSpecNodeListRequirementSpecNode != null) { - oldRequirementSpecOfRequirementSpecNodeListRequirementSpecNode.getRequirementSpecNodeList().remove(requirementSpecNodeListRequirementSpecNode); - oldRequirementSpecOfRequirementSpecNodeListRequirementSpecNode = em.merge(oldRequirementSpecOfRequirementSpecNodeListRequirementSpecNode); - } - } - for (Baseline baselineListBaseline : requirementSpec.getBaselineList()) { - RequirementSpec oldRequirementSpecOfBaselineListBaseline = baselineListBaseline.getRequirementSpec(); - baselineListBaseline.setRequirementSpec(requirementSpec); - baselineListBaseline = em.merge(baselineListBaseline); - if (oldRequirementSpecOfBaselineListBaseline != null) { - oldRequirementSpecOfBaselineListBaseline.getBaselineList().remove(baselineListBaseline); - oldRequirementSpecOfBaselineListBaseline = em.merge(oldRequirementSpecOfBaselineListBaseline); - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - if (findRequirementSpec(requirementSpec.getRequirementSpecPK()) != null) { - throw new PreexistingEntityException("RequirementSpec " + requirementSpec + " already exists.", ex); - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(RequirementSpec requirementSpec) throws IllegalOrphanException, NonexistentEntityException, Exception { - requirementSpec.getRequirementSpecPK().setSpecLevelId(requirementSpec.getSpecLevel().getId()); - requirementSpec.getRequirementSpecPK().setProjectId(requirementSpec.getProject().getId()); - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - RequirementSpec persistentRequirementSpec = em.find(RequirementSpec.class, requirementSpec.getRequirementSpecPK()); - Project projectOld = persistentRequirementSpec.getProject(); - Project projectNew = requirementSpec.getProject(); - SpecLevel specLevelOld = persistentRequirementSpec.getSpecLevel(); - SpecLevel specLevelNew = requirementSpec.getSpecLevel(); - List requirementSpecNodeListOld = persistentRequirementSpec.getRequirementSpecNodeList(); - List requirementSpecNodeListNew = requirementSpec.getRequirementSpecNodeList(); - List baselineListOld = persistentRequirementSpec.getBaselineList(); - List baselineListNew = requirementSpec.getBaselineList(); - List illegalOrphanMessages = null; - for (RequirementSpecNode requirementSpecNodeListOldRequirementSpecNode : requirementSpecNodeListOld) { - if (!requirementSpecNodeListNew.contains(requirementSpecNodeListOldRequirementSpecNode)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain RequirementSpecNode " + requirementSpecNodeListOldRequirementSpecNode + " since its requirementSpec field is not nullable."); - } - } - for (Baseline baselineListOldBaseline : baselineListOld) { - if (!baselineListNew.contains(baselineListOldBaseline)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain Baseline " + baselineListOldBaseline + " since its requirementSpec field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - if (projectNew != null) { - projectNew = em.getReference(projectNew.getClass(), projectNew.getId()); - requirementSpec.setProject(projectNew); - } - if (specLevelNew != null) { - specLevelNew = em.getReference(specLevelNew.getClass(), specLevelNew.getId()); - requirementSpec.setSpecLevel(specLevelNew); - } - List attachedRequirementSpecNodeListNew = new ArrayList(); - for (RequirementSpecNode requirementSpecNodeListNewRequirementSpecNodeToAttach : requirementSpecNodeListNew) { - requirementSpecNodeListNewRequirementSpecNodeToAttach = em.getReference(requirementSpecNodeListNewRequirementSpecNodeToAttach.getClass(), requirementSpecNodeListNewRequirementSpecNodeToAttach.getRequirementSpecNodePK()); - attachedRequirementSpecNodeListNew.add(requirementSpecNodeListNewRequirementSpecNodeToAttach); - } - requirementSpecNodeListNew = attachedRequirementSpecNodeListNew; - requirementSpec.setRequirementSpecNodeList(requirementSpecNodeListNew); - List attachedBaselineListNew = new ArrayList(); - for (Baseline baselineListNewBaselineToAttach : baselineListNew) { - baselineListNewBaselineToAttach = em.getReference(baselineListNewBaselineToAttach.getClass(), baselineListNewBaselineToAttach.getId()); - attachedBaselineListNew.add(baselineListNewBaselineToAttach); - } - baselineListNew = attachedBaselineListNew; - requirementSpec.setBaselineList(baselineListNew); - requirementSpec = em.merge(requirementSpec); - if (projectOld != null && !projectOld.equals(projectNew)) { - projectOld.getRequirementSpecList().remove(requirementSpec); - projectOld = em.merge(projectOld); - } - if (projectNew != null && !projectNew.equals(projectOld)) { - projectNew.getRequirementSpecList().add(requirementSpec); - projectNew = em.merge(projectNew); - } - if (specLevelOld != null && !specLevelOld.equals(specLevelNew)) { - specLevelOld.getRequirementSpecList().remove(requirementSpec); - specLevelOld = em.merge(specLevelOld); - } - if (specLevelNew != null && !specLevelNew.equals(specLevelOld)) { - specLevelNew.getRequirementSpecList().add(requirementSpec); - specLevelNew = em.merge(specLevelNew); - } - for (RequirementSpecNode requirementSpecNodeListNewRequirementSpecNode : requirementSpecNodeListNew) { - if (!requirementSpecNodeListOld.contains(requirementSpecNodeListNewRequirementSpecNode)) { - RequirementSpec oldRequirementSpecOfRequirementSpecNodeListNewRequirementSpecNode = requirementSpecNodeListNewRequirementSpecNode.getRequirementSpec(); - requirementSpecNodeListNewRequirementSpecNode.setRequirementSpec(requirementSpec); - requirementSpecNodeListNewRequirementSpecNode = em.merge(requirementSpecNodeListNewRequirementSpecNode); - if (oldRequirementSpecOfRequirementSpecNodeListNewRequirementSpecNode != null && !oldRequirementSpecOfRequirementSpecNodeListNewRequirementSpecNode.equals(requirementSpec)) { - oldRequirementSpecOfRequirementSpecNodeListNewRequirementSpecNode.getRequirementSpecNodeList().remove(requirementSpecNodeListNewRequirementSpecNode); - oldRequirementSpecOfRequirementSpecNodeListNewRequirementSpecNode = em.merge(oldRequirementSpecOfRequirementSpecNodeListNewRequirementSpecNode); - } - } - } - for (Baseline baselineListNewBaseline : baselineListNew) { - if (!baselineListOld.contains(baselineListNewBaseline)) { - RequirementSpec oldRequirementSpecOfBaselineListNewBaseline = baselineListNewBaseline.getRequirementSpec(); - baselineListNewBaseline.setRequirementSpec(requirementSpec); - baselineListNewBaseline = em.merge(baselineListNewBaseline); - if (oldRequirementSpecOfBaselineListNewBaseline != null && !oldRequirementSpecOfBaselineListNewBaseline.equals(requirementSpec)) { - oldRequirementSpecOfBaselineListNewBaseline.getBaselineList().remove(baselineListNewBaseline); - oldRequirementSpecOfBaselineListNewBaseline = em.merge(oldRequirementSpecOfBaselineListNewBaseline); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - RequirementSpecPK id = requirementSpec.getRequirementSpecPK(); - if (findRequirementSpec(id) == null) { - throw new NonexistentEntityException("The requirementSpec with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(RequirementSpecPK id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - RequirementSpec requirementSpec; - try { - requirementSpec = em.getReference(RequirementSpec.class, id); - requirementSpec.getRequirementSpecPK(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The requirementSpec with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List requirementSpecNodeListOrphanCheck = requirementSpec.getRequirementSpecNodeList(); - for (RequirementSpecNode requirementSpecNodeListOrphanCheckRequirementSpecNode : requirementSpecNodeListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This RequirementSpec (" + requirementSpec + ") cannot be destroyed since the RequirementSpecNode " + requirementSpecNodeListOrphanCheckRequirementSpecNode + " in its requirementSpecNodeList field has a non-nullable requirementSpec field."); - } - List baselineListOrphanCheck = requirementSpec.getBaselineList(); - for (Baseline baselineListOrphanCheckBaseline : baselineListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This RequirementSpec (" + requirementSpec + ") cannot be destroyed since the Baseline " + baselineListOrphanCheckBaseline + " in its baselineList field has a non-nullable requirementSpec field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - Project project = requirementSpec.getProject(); - if (project != null) { - project.getRequirementSpecList().remove(requirementSpec); - project = em.merge(project); - } - SpecLevel specLevel = requirementSpec.getSpecLevel(); - if (specLevel != null) { - specLevel.getRequirementSpecList().remove(requirementSpec); - specLevel = em.merge(specLevel); - } - em.remove(requirementSpec); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findRequirementSpecEntities() { - return findRequirementSpecEntities(true, -1, -1); - } - - public List findRequirementSpecEntities(int maxResults, int firstResult) { - return findRequirementSpecEntities(false, maxResults, firstResult); - } - - private List findRequirementSpecEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(RequirementSpec.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public RequirementSpec findRequirementSpec(RequirementSpecPK id) { - EntityManager em = getEntityManager(); - try { - return em.find(RequirementSpec.class, id); - } - finally { - em.close(); - } - } - - public int getRequirementSpecCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(RequirementSpec.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.Project; +import com.validation.manager.core.db.SpecLevel; +import com.validation.manager.core.db.RequirementSpecNode; +import java.util.ArrayList; +import java.util.List; +import com.validation.manager.core.db.Baseline; +import com.validation.manager.core.db.RequirementSpec; +import com.validation.manager.core.db.RequirementSpecPK; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import com.validation.manager.core.db.controller.exceptions.PreexistingEntityException; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class RequirementSpecJpaController implements Serializable { + + public RequirementSpecJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(RequirementSpec requirementSpec) throws PreexistingEntityException, Exception { + if (requirementSpec.getRequirementSpecPK() == null) { + requirementSpec.setRequirementSpecPK(new RequirementSpecPK()); + } + if (requirementSpec.getRequirementSpecNodeList() == null) { + requirementSpec.setRequirementSpecNodeList(new ArrayList<>()); + } + if (requirementSpec.getBaselineList() == null) { + requirementSpec.setBaselineList(new ArrayList<>()); + } + requirementSpec.getRequirementSpecPK().setSpecLevelId(requirementSpec.getSpecLevel().getId()); + requirementSpec.getRequirementSpecPK().setProjectId(requirementSpec.getProject().getId()); + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + Project project = requirementSpec.getProject(); + if (project != null) { + project = em.getReference(project.getClass(), project.getId()); + requirementSpec.setProject(project); + } + SpecLevel specLevel = requirementSpec.getSpecLevel(); + if (specLevel != null) { + specLevel = em.getReference(specLevel.getClass(), specLevel.getId()); + requirementSpec.setSpecLevel(specLevel); + } + List attachedRequirementSpecNodeList = new ArrayList<>(); + for (RequirementSpecNode requirementSpecNodeListRequirementSpecNodeToAttach : requirementSpec.getRequirementSpecNodeList()) { + requirementSpecNodeListRequirementSpecNodeToAttach = em.getReference(requirementSpecNodeListRequirementSpecNodeToAttach.getClass(), requirementSpecNodeListRequirementSpecNodeToAttach.getRequirementSpecNodePK()); + attachedRequirementSpecNodeList.add(requirementSpecNodeListRequirementSpecNodeToAttach); + } + requirementSpec.setRequirementSpecNodeList(attachedRequirementSpecNodeList); + List attachedBaselineList = new ArrayList<>(); + for (Baseline baselineListBaselineToAttach : requirementSpec.getBaselineList()) { + baselineListBaselineToAttach = em.getReference(baselineListBaselineToAttach.getClass(), baselineListBaselineToAttach.getId()); + attachedBaselineList.add(baselineListBaselineToAttach); + } + requirementSpec.setBaselineList(attachedBaselineList); + em.persist(requirementSpec); + if (project != null) { + project.getRequirementSpecList().add(requirementSpec); + project = em.merge(project); + } + if (specLevel != null) { + specLevel.getRequirementSpecList().add(requirementSpec); + specLevel = em.merge(specLevel); + } + for (RequirementSpecNode requirementSpecNodeListRequirementSpecNode : requirementSpec.getRequirementSpecNodeList()) { + RequirementSpec oldRequirementSpecOfRequirementSpecNodeListRequirementSpecNode = requirementSpecNodeListRequirementSpecNode.getRequirementSpec(); + requirementSpecNodeListRequirementSpecNode.setRequirementSpec(requirementSpec); + requirementSpecNodeListRequirementSpecNode = em.merge(requirementSpecNodeListRequirementSpecNode); + if (oldRequirementSpecOfRequirementSpecNodeListRequirementSpecNode != null) { + oldRequirementSpecOfRequirementSpecNodeListRequirementSpecNode.getRequirementSpecNodeList().remove(requirementSpecNodeListRequirementSpecNode); + oldRequirementSpecOfRequirementSpecNodeListRequirementSpecNode = em.merge(oldRequirementSpecOfRequirementSpecNodeListRequirementSpecNode); + } + } + for (Baseline baselineListBaseline : requirementSpec.getBaselineList()) { + RequirementSpec oldRequirementSpecOfBaselineListBaseline = baselineListBaseline.getRequirementSpec(); + baselineListBaseline.setRequirementSpec(requirementSpec); + baselineListBaseline = em.merge(baselineListBaseline); + if (oldRequirementSpecOfBaselineListBaseline != null) { + oldRequirementSpecOfBaselineListBaseline.getBaselineList().remove(baselineListBaseline); + oldRequirementSpecOfBaselineListBaseline = em.merge(oldRequirementSpecOfBaselineListBaseline); + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + if (findRequirementSpec(requirementSpec.getRequirementSpecPK()) != null) { + throw new PreexistingEntityException("RequirementSpec " + requirementSpec + " already exists.", ex); + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(RequirementSpec requirementSpec) throws IllegalOrphanException, NonexistentEntityException, Exception { + requirementSpec.getRequirementSpecPK().setSpecLevelId(requirementSpec.getSpecLevel().getId()); + requirementSpec.getRequirementSpecPK().setProjectId(requirementSpec.getProject().getId()); + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + RequirementSpec persistentRequirementSpec = em.find(RequirementSpec.class, requirementSpec.getRequirementSpecPK()); + Project projectOld = persistentRequirementSpec.getProject(); + Project projectNew = requirementSpec.getProject(); + SpecLevel specLevelOld = persistentRequirementSpec.getSpecLevel(); + SpecLevel specLevelNew = requirementSpec.getSpecLevel(); + List requirementSpecNodeListOld = persistentRequirementSpec.getRequirementSpecNodeList(); + List requirementSpecNodeListNew = requirementSpec.getRequirementSpecNodeList(); + List baselineListOld = persistentRequirementSpec.getBaselineList(); + List baselineListNew = requirementSpec.getBaselineList(); + List illegalOrphanMessages = null; + for (RequirementSpecNode requirementSpecNodeListOldRequirementSpecNode : requirementSpecNodeListOld) { + if (!requirementSpecNodeListNew.contains(requirementSpecNodeListOldRequirementSpecNode)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain RequirementSpecNode " + requirementSpecNodeListOldRequirementSpecNode + " since its requirementSpec field is not nullable."); + } + } + for (Baseline baselineListOldBaseline : baselineListOld) { + if (!baselineListNew.contains(baselineListOldBaseline)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain Baseline " + baselineListOldBaseline + " since its requirementSpec field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + if (projectNew != null) { + projectNew = em.getReference(projectNew.getClass(), projectNew.getId()); + requirementSpec.setProject(projectNew); + } + if (specLevelNew != null) { + specLevelNew = em.getReference(specLevelNew.getClass(), specLevelNew.getId()); + requirementSpec.setSpecLevel(specLevelNew); + } + List attachedRequirementSpecNodeListNew = new ArrayList<>(); + for (RequirementSpecNode requirementSpecNodeListNewRequirementSpecNodeToAttach : requirementSpecNodeListNew) { + requirementSpecNodeListNewRequirementSpecNodeToAttach = em.getReference(requirementSpecNodeListNewRequirementSpecNodeToAttach.getClass(), requirementSpecNodeListNewRequirementSpecNodeToAttach.getRequirementSpecNodePK()); + attachedRequirementSpecNodeListNew.add(requirementSpecNodeListNewRequirementSpecNodeToAttach); + } + requirementSpecNodeListNew = attachedRequirementSpecNodeListNew; + requirementSpec.setRequirementSpecNodeList(requirementSpecNodeListNew); + List attachedBaselineListNew = new ArrayList<>(); + for (Baseline baselineListNewBaselineToAttach : baselineListNew) { + baselineListNewBaselineToAttach = em.getReference(baselineListNewBaselineToAttach.getClass(), baselineListNewBaselineToAttach.getId()); + attachedBaselineListNew.add(baselineListNewBaselineToAttach); + } + baselineListNew = attachedBaselineListNew; + requirementSpec.setBaselineList(baselineListNew); + requirementSpec = em.merge(requirementSpec); + if (projectOld != null && !projectOld.equals(projectNew)) { + projectOld.getRequirementSpecList().remove(requirementSpec); + projectOld = em.merge(projectOld); + } + if (projectNew != null && !projectNew.equals(projectOld)) { + projectNew.getRequirementSpecList().add(requirementSpec); + projectNew = em.merge(projectNew); + } + if (specLevelOld != null && !specLevelOld.equals(specLevelNew)) { + specLevelOld.getRequirementSpecList().remove(requirementSpec); + specLevelOld = em.merge(specLevelOld); + } + if (specLevelNew != null && !specLevelNew.equals(specLevelOld)) { + specLevelNew.getRequirementSpecList().add(requirementSpec); + specLevelNew = em.merge(specLevelNew); + } + for (RequirementSpecNode requirementSpecNodeListNewRequirementSpecNode : requirementSpecNodeListNew) { + if (!requirementSpecNodeListOld.contains(requirementSpecNodeListNewRequirementSpecNode)) { + RequirementSpec oldRequirementSpecOfRequirementSpecNodeListNewRequirementSpecNode = requirementSpecNodeListNewRequirementSpecNode.getRequirementSpec(); + requirementSpecNodeListNewRequirementSpecNode.setRequirementSpec(requirementSpec); + requirementSpecNodeListNewRequirementSpecNode = em.merge(requirementSpecNodeListNewRequirementSpecNode); + if (oldRequirementSpecOfRequirementSpecNodeListNewRequirementSpecNode != null && !oldRequirementSpecOfRequirementSpecNodeListNewRequirementSpecNode.equals(requirementSpec)) { + oldRequirementSpecOfRequirementSpecNodeListNewRequirementSpecNode.getRequirementSpecNodeList().remove(requirementSpecNodeListNewRequirementSpecNode); + oldRequirementSpecOfRequirementSpecNodeListNewRequirementSpecNode = em.merge(oldRequirementSpecOfRequirementSpecNodeListNewRequirementSpecNode); + } + } + } + for (Baseline baselineListNewBaseline : baselineListNew) { + if (!baselineListOld.contains(baselineListNewBaseline)) { + RequirementSpec oldRequirementSpecOfBaselineListNewBaseline = baselineListNewBaseline.getRequirementSpec(); + baselineListNewBaseline.setRequirementSpec(requirementSpec); + baselineListNewBaseline = em.merge(baselineListNewBaseline); + if (oldRequirementSpecOfBaselineListNewBaseline != null && !oldRequirementSpecOfBaselineListNewBaseline.equals(requirementSpec)) { + oldRequirementSpecOfBaselineListNewBaseline.getBaselineList().remove(baselineListNewBaseline); + oldRequirementSpecOfBaselineListNewBaseline = em.merge(oldRequirementSpecOfBaselineListNewBaseline); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + RequirementSpecPK id = requirementSpec.getRequirementSpecPK(); + if (findRequirementSpec(id) == null) { + throw new NonexistentEntityException("The requirementSpec with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(RequirementSpecPK id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + RequirementSpec requirementSpec; + try { + requirementSpec = em.getReference(RequirementSpec.class, id); + requirementSpec.getRequirementSpecPK(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The requirementSpec with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List requirementSpecNodeListOrphanCheck = requirementSpec.getRequirementSpecNodeList(); + for (RequirementSpecNode requirementSpecNodeListOrphanCheckRequirementSpecNode : requirementSpecNodeListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This RequirementSpec (" + requirementSpec + ") cannot be destroyed since the RequirementSpecNode " + requirementSpecNodeListOrphanCheckRequirementSpecNode + " in its requirementSpecNodeList field has a non-nullable requirementSpec field."); + } + List baselineListOrphanCheck = requirementSpec.getBaselineList(); + for (Baseline baselineListOrphanCheckBaseline : baselineListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This RequirementSpec (" + requirementSpec + ") cannot be destroyed since the Baseline " + baselineListOrphanCheckBaseline + " in its baselineList field has a non-nullable requirementSpec field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + Project project = requirementSpec.getProject(); + if (project != null) { + project.getRequirementSpecList().remove(requirementSpec); + project = em.merge(project); + } + SpecLevel specLevel = requirementSpec.getSpecLevel(); + if (specLevel != null) { + specLevel.getRequirementSpecList().remove(requirementSpec); + specLevel = em.merge(specLevel); + } + em.remove(requirementSpec); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findRequirementSpecEntities() { + return findRequirementSpecEntities(true, -1, -1); + } + + public List findRequirementSpecEntities(int maxResults, int firstResult) { + return findRequirementSpecEntities(false, maxResults, firstResult); + } + + private List findRequirementSpecEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(RequirementSpec.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public RequirementSpec findRequirementSpec(RequirementSpecPK id) { + EntityManager em = getEntityManager(); + try { + return em.find(RequirementSpec.class, id); + } + finally { + em.close(); + } + } + + public int getRequirementSpecCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(RequirementSpec.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/RequirementSpecNodeJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/RequirementSpecNodeJpaController.java index bb85a9ad..07511bb7 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/RequirementSpecNodeJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/RequirementSpecNodeJpaController.java @@ -13,332 +13,332 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.RequirementSpec; -import com.validation.manager.core.db.RequirementSpecNode; -import java.util.ArrayList; -import java.util.List; -import com.validation.manager.core.db.Requirement; -import com.validation.manager.core.db.RequirementSpecNodePK; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import com.validation.manager.core.db.controller.exceptions.PreexistingEntityException; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class RequirementSpecNodeJpaController implements Serializable { - - public RequirementSpecNodeJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(RequirementSpecNode requirementSpecNode) throws PreexistingEntityException, Exception { - if (requirementSpecNode.getRequirementSpecNodePK() == null) { - requirementSpecNode.setRequirementSpecNodePK(new RequirementSpecNodePK()); - } - if (requirementSpecNode.getRequirementSpecNodeList() == null) { - requirementSpecNode.setRequirementSpecNodeList(new ArrayList()); - } - if (requirementSpecNode.getRequirementList() == null) { - requirementSpecNode.setRequirementList(new ArrayList()); - } - requirementSpecNode.getRequirementSpecNodePK().setRequirementSpecId(requirementSpecNode.getRequirementSpec().getRequirementSpecPK().getId()); - requirementSpecNode.getRequirementSpecNodePK().setRequirementSpecProjectId(requirementSpecNode.getRequirementSpec().getRequirementSpecPK().getProjectId()); - requirementSpecNode.getRequirementSpecNodePK().setRequirementSpecSpecLevelId(requirementSpecNode.getRequirementSpec().getRequirementSpecPK().getSpecLevelId()); - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - RequirementSpec requirementSpec = requirementSpecNode.getRequirementSpec(); - if (requirementSpec != null) { - requirementSpec = em.getReference(requirementSpec.getClass(), requirementSpec.getRequirementSpecPK()); - requirementSpecNode.setRequirementSpec(requirementSpec); - } - RequirementSpecNode requirementSpecNodeRel = requirementSpecNode.getRequirementSpecNode(); - if (requirementSpecNodeRel != null) { - requirementSpecNodeRel = em.getReference(requirementSpecNodeRel.getClass(), requirementSpecNodeRel.getRequirementSpecNodePK()); - requirementSpecNode.setRequirementSpecNode(requirementSpecNodeRel); - } - List attachedRequirementSpecNodeList = new ArrayList(); - for (RequirementSpecNode requirementSpecNodeListRequirementSpecNodeToAttach : requirementSpecNode.getRequirementSpecNodeList()) { - requirementSpecNodeListRequirementSpecNodeToAttach = em.getReference(requirementSpecNodeListRequirementSpecNodeToAttach.getClass(), requirementSpecNodeListRequirementSpecNodeToAttach.getRequirementSpecNodePK()); - attachedRequirementSpecNodeList.add(requirementSpecNodeListRequirementSpecNodeToAttach); - } - requirementSpecNode.setRequirementSpecNodeList(attachedRequirementSpecNodeList); - List attachedRequirementList = new ArrayList(); - for (Requirement requirementListRequirementToAttach : requirementSpecNode.getRequirementList()) { - requirementListRequirementToAttach = em.getReference(requirementListRequirementToAttach.getClass(), requirementListRequirementToAttach.getId()); - attachedRequirementList.add(requirementListRequirementToAttach); - } - requirementSpecNode.setRequirementList(attachedRequirementList); - em.persist(requirementSpecNode); - if (requirementSpec != null) { - requirementSpec.getRequirementSpecNodeList().add(requirementSpecNode); - requirementSpec = em.merge(requirementSpec); - } - if (requirementSpecNodeRel != null) { - requirementSpecNodeRel.getRequirementSpecNodeList().add(requirementSpecNode); - requirementSpecNodeRel = em.merge(requirementSpecNodeRel); - } - for (RequirementSpecNode requirementSpecNodeListRequirementSpecNode : requirementSpecNode.getRequirementSpecNodeList()) { - RequirementSpecNode oldRequirementSpecNodeOfRequirementSpecNodeListRequirementSpecNode = requirementSpecNodeListRequirementSpecNode.getRequirementSpecNode(); - requirementSpecNodeListRequirementSpecNode.setRequirementSpecNode(requirementSpecNode); - requirementSpecNodeListRequirementSpecNode = em.merge(requirementSpecNodeListRequirementSpecNode); - if (oldRequirementSpecNodeOfRequirementSpecNodeListRequirementSpecNode != null) { - oldRequirementSpecNodeOfRequirementSpecNodeListRequirementSpecNode.getRequirementSpecNodeList().remove(requirementSpecNodeListRequirementSpecNode); - oldRequirementSpecNodeOfRequirementSpecNodeListRequirementSpecNode = em.merge(oldRequirementSpecNodeOfRequirementSpecNodeListRequirementSpecNode); - } - } - for (Requirement requirementListRequirement : requirementSpecNode.getRequirementList()) { - RequirementSpecNode oldRequirementSpecNodeOfRequirementListRequirement = requirementListRequirement.getRequirementSpecNode(); - requirementListRequirement.setRequirementSpecNode(requirementSpecNode); - requirementListRequirement = em.merge(requirementListRequirement); - if (oldRequirementSpecNodeOfRequirementListRequirement != null) { - oldRequirementSpecNodeOfRequirementListRequirement.getRequirementList().remove(requirementListRequirement); - oldRequirementSpecNodeOfRequirementListRequirement = em.merge(oldRequirementSpecNodeOfRequirementListRequirement); - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - if (findRequirementSpecNode(requirementSpecNode.getRequirementSpecNodePK()) != null) { - throw new PreexistingEntityException("RequirementSpecNode " + requirementSpecNode + " already exists.", ex); - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(RequirementSpecNode requirementSpecNode) throws IllegalOrphanException, NonexistentEntityException, Exception { - requirementSpecNode.getRequirementSpecNodePK().setRequirementSpecId(requirementSpecNode.getRequirementSpec().getRequirementSpecPK().getId()); - requirementSpecNode.getRequirementSpecNodePK().setRequirementSpecProjectId(requirementSpecNode.getRequirementSpec().getRequirementSpecPK().getProjectId()); - requirementSpecNode.getRequirementSpecNodePK().setRequirementSpecSpecLevelId(requirementSpecNode.getRequirementSpec().getRequirementSpecPK().getSpecLevelId()); - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - RequirementSpecNode persistentRequirementSpecNode = em.find(RequirementSpecNode.class, requirementSpecNode.getRequirementSpecNodePK()); - RequirementSpec requirementSpecOld = persistentRequirementSpecNode.getRequirementSpec(); - RequirementSpec requirementSpecNew = requirementSpecNode.getRequirementSpec(); - RequirementSpecNode requirementSpecNodeRelOld = persistentRequirementSpecNode.getRequirementSpecNode(); - RequirementSpecNode requirementSpecNodeRelNew = requirementSpecNode.getRequirementSpecNode(); - List requirementSpecNodeListOld = persistentRequirementSpecNode.getRequirementSpecNodeList(); - List requirementSpecNodeListNew = requirementSpecNode.getRequirementSpecNodeList(); - List requirementListOld = persistentRequirementSpecNode.getRequirementList(); - List requirementListNew = requirementSpecNode.getRequirementList(); - List illegalOrphanMessages = null; - for (Requirement requirementListOldRequirement : requirementListOld) { - if (!requirementListNew.contains(requirementListOldRequirement)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain Requirement " + requirementListOldRequirement + " since its requirementSpecNode field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - if (requirementSpecNew != null) { - requirementSpecNew = em.getReference(requirementSpecNew.getClass(), requirementSpecNew.getRequirementSpecPK()); - requirementSpecNode.setRequirementSpec(requirementSpecNew); - } - if (requirementSpecNodeRelNew != null) { - requirementSpecNodeRelNew = em.getReference(requirementSpecNodeRelNew.getClass(), requirementSpecNodeRelNew.getRequirementSpecNodePK()); - requirementSpecNode.setRequirementSpecNode(requirementSpecNodeRelNew); - } - List attachedRequirementSpecNodeListNew = new ArrayList(); - for (RequirementSpecNode requirementSpecNodeListNewRequirementSpecNodeToAttach : requirementSpecNodeListNew) { - requirementSpecNodeListNewRequirementSpecNodeToAttach = em.getReference(requirementSpecNodeListNewRequirementSpecNodeToAttach.getClass(), requirementSpecNodeListNewRequirementSpecNodeToAttach.getRequirementSpecNodePK()); - attachedRequirementSpecNodeListNew.add(requirementSpecNodeListNewRequirementSpecNodeToAttach); - } - requirementSpecNodeListNew = attachedRequirementSpecNodeListNew; - requirementSpecNode.setRequirementSpecNodeList(requirementSpecNodeListNew); - List attachedRequirementListNew = new ArrayList(); - for (Requirement requirementListNewRequirementToAttach : requirementListNew) { - requirementListNewRequirementToAttach = em.getReference(requirementListNewRequirementToAttach.getClass(), requirementListNewRequirementToAttach.getId()); - attachedRequirementListNew.add(requirementListNewRequirementToAttach); - } - requirementListNew = attachedRequirementListNew; - requirementSpecNode.setRequirementList(requirementListNew); - requirementSpecNode = em.merge(requirementSpecNode); - if (requirementSpecOld != null && !requirementSpecOld.equals(requirementSpecNew)) { - requirementSpecOld.getRequirementSpecNodeList().remove(requirementSpecNode); - requirementSpecOld = em.merge(requirementSpecOld); - } - if (requirementSpecNew != null && !requirementSpecNew.equals(requirementSpecOld)) { - requirementSpecNew.getRequirementSpecNodeList().add(requirementSpecNode); - requirementSpecNew = em.merge(requirementSpecNew); - } - if (requirementSpecNodeRelOld != null && !requirementSpecNodeRelOld.equals(requirementSpecNodeRelNew)) { - requirementSpecNodeRelOld.getRequirementSpecNodeList().remove(requirementSpecNode); - requirementSpecNodeRelOld = em.merge(requirementSpecNodeRelOld); - } - if (requirementSpecNodeRelNew != null && !requirementSpecNodeRelNew.equals(requirementSpecNodeRelOld)) { - requirementSpecNodeRelNew.getRequirementSpecNodeList().add(requirementSpecNode); - requirementSpecNodeRelNew = em.merge(requirementSpecNodeRelNew); - } - for (RequirementSpecNode requirementSpecNodeListOldRequirementSpecNode : requirementSpecNodeListOld) { - if (!requirementSpecNodeListNew.contains(requirementSpecNodeListOldRequirementSpecNode)) { - requirementSpecNodeListOldRequirementSpecNode.setRequirementSpecNode(null); - requirementSpecNodeListOldRequirementSpecNode = em.merge(requirementSpecNodeListOldRequirementSpecNode); - } - } - for (RequirementSpecNode requirementSpecNodeListNewRequirementSpecNode : requirementSpecNodeListNew) { - if (!requirementSpecNodeListOld.contains(requirementSpecNodeListNewRequirementSpecNode)) { - RequirementSpecNode oldRequirementSpecNodeOfRequirementSpecNodeListNewRequirementSpecNode = requirementSpecNodeListNewRequirementSpecNode.getRequirementSpecNode(); - requirementSpecNodeListNewRequirementSpecNode.setRequirementSpecNode(requirementSpecNode); - requirementSpecNodeListNewRequirementSpecNode = em.merge(requirementSpecNodeListNewRequirementSpecNode); - if (oldRequirementSpecNodeOfRequirementSpecNodeListNewRequirementSpecNode != null && !oldRequirementSpecNodeOfRequirementSpecNodeListNewRequirementSpecNode.equals(requirementSpecNode)) { - oldRequirementSpecNodeOfRequirementSpecNodeListNewRequirementSpecNode.getRequirementSpecNodeList().remove(requirementSpecNodeListNewRequirementSpecNode); - oldRequirementSpecNodeOfRequirementSpecNodeListNewRequirementSpecNode = em.merge(oldRequirementSpecNodeOfRequirementSpecNodeListNewRequirementSpecNode); - } - } - } - for (Requirement requirementListNewRequirement : requirementListNew) { - if (!requirementListOld.contains(requirementListNewRequirement)) { - RequirementSpecNode oldRequirementSpecNodeOfRequirementListNewRequirement = requirementListNewRequirement.getRequirementSpecNode(); - requirementListNewRequirement.setRequirementSpecNode(requirementSpecNode); - requirementListNewRequirement = em.merge(requirementListNewRequirement); - if (oldRequirementSpecNodeOfRequirementListNewRequirement != null && !oldRequirementSpecNodeOfRequirementListNewRequirement.equals(requirementSpecNode)) { - oldRequirementSpecNodeOfRequirementListNewRequirement.getRequirementList().remove(requirementListNewRequirement); - oldRequirementSpecNodeOfRequirementListNewRequirement = em.merge(oldRequirementSpecNodeOfRequirementListNewRequirement); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - RequirementSpecNodePK id = requirementSpecNode.getRequirementSpecNodePK(); - if (findRequirementSpecNode(id) == null) { - throw new NonexistentEntityException("The requirementSpecNode with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(RequirementSpecNodePK id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - RequirementSpecNode requirementSpecNode; - try { - requirementSpecNode = em.getReference(RequirementSpecNode.class, id); - requirementSpecNode.getRequirementSpecNodePK(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The requirementSpecNode with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List requirementListOrphanCheck = requirementSpecNode.getRequirementList(); - for (Requirement requirementListOrphanCheckRequirement : requirementListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This RequirementSpecNode (" + requirementSpecNode + ") cannot be destroyed since the Requirement " + requirementListOrphanCheckRequirement + " in its requirementList field has a non-nullable requirementSpecNode field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - RequirementSpec requirementSpec = requirementSpecNode.getRequirementSpec(); - if (requirementSpec != null) { - requirementSpec.getRequirementSpecNodeList().remove(requirementSpecNode); - requirementSpec = em.merge(requirementSpec); - } - RequirementSpecNode requirementSpecNodeRel = requirementSpecNode.getRequirementSpecNode(); - if (requirementSpecNodeRel != null) { - requirementSpecNodeRel.getRequirementSpecNodeList().remove(requirementSpecNode); - requirementSpecNodeRel = em.merge(requirementSpecNodeRel); - } - List requirementSpecNodeList = requirementSpecNode.getRequirementSpecNodeList(); - for (RequirementSpecNode requirementSpecNodeListRequirementSpecNode : requirementSpecNodeList) { - requirementSpecNodeListRequirementSpecNode.setRequirementSpecNode(null); - requirementSpecNodeListRequirementSpecNode = em.merge(requirementSpecNodeListRequirementSpecNode); - } - em.remove(requirementSpecNode); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findRequirementSpecNodeEntities() { - return findRequirementSpecNodeEntities(true, -1, -1); - } - - public List findRequirementSpecNodeEntities(int maxResults, int firstResult) { - return findRequirementSpecNodeEntities(false, maxResults, firstResult); - } - - private List findRequirementSpecNodeEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(RequirementSpecNode.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public RequirementSpecNode findRequirementSpecNode(RequirementSpecNodePK id) { - EntityManager em = getEntityManager(); - try { - return em.find(RequirementSpecNode.class, id); - } - finally { - em.close(); - } - } - - public int getRequirementSpecNodeCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(RequirementSpecNode.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.RequirementSpec; +import com.validation.manager.core.db.RequirementSpecNode; +import java.util.ArrayList; +import java.util.List; +import com.validation.manager.core.db.Requirement; +import com.validation.manager.core.db.RequirementSpecNodePK; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import com.validation.manager.core.db.controller.exceptions.PreexistingEntityException; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class RequirementSpecNodeJpaController implements Serializable { + + public RequirementSpecNodeJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(RequirementSpecNode requirementSpecNode) throws PreexistingEntityException, Exception { + if (requirementSpecNode.getRequirementSpecNodePK() == null) { + requirementSpecNode.setRequirementSpecNodePK(new RequirementSpecNodePK()); + } + if (requirementSpecNode.getRequirementSpecNodeList() == null) { + requirementSpecNode.setRequirementSpecNodeList(new ArrayList<>()); + } + if (requirementSpecNode.getRequirementList() == null) { + requirementSpecNode.setRequirementList(new ArrayList<>()); + } + requirementSpecNode.getRequirementSpecNodePK().setRequirementSpecId(requirementSpecNode.getRequirementSpec().getRequirementSpecPK().getId()); + requirementSpecNode.getRequirementSpecNodePK().setRequirementSpecProjectId(requirementSpecNode.getRequirementSpec().getRequirementSpecPK().getProjectId()); + requirementSpecNode.getRequirementSpecNodePK().setRequirementSpecSpecLevelId(requirementSpecNode.getRequirementSpec().getRequirementSpecPK().getSpecLevelId()); + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + RequirementSpec requirementSpec = requirementSpecNode.getRequirementSpec(); + if (requirementSpec != null) { + requirementSpec = em.getReference(requirementSpec.getClass(), requirementSpec.getRequirementSpecPK()); + requirementSpecNode.setRequirementSpec(requirementSpec); + } + RequirementSpecNode requirementSpecNodeRel = requirementSpecNode.getRequirementSpecNode(); + if (requirementSpecNodeRel != null) { + requirementSpecNodeRel = em.getReference(requirementSpecNodeRel.getClass(), requirementSpecNodeRel.getRequirementSpecNodePK()); + requirementSpecNode.setRequirementSpecNode(requirementSpecNodeRel); + } + List attachedRequirementSpecNodeList = new ArrayList<>(); + for (RequirementSpecNode requirementSpecNodeListRequirementSpecNodeToAttach : requirementSpecNode.getRequirementSpecNodeList()) { + requirementSpecNodeListRequirementSpecNodeToAttach = em.getReference(requirementSpecNodeListRequirementSpecNodeToAttach.getClass(), requirementSpecNodeListRequirementSpecNodeToAttach.getRequirementSpecNodePK()); + attachedRequirementSpecNodeList.add(requirementSpecNodeListRequirementSpecNodeToAttach); + } + requirementSpecNode.setRequirementSpecNodeList(attachedRequirementSpecNodeList); + List attachedRequirementList = new ArrayList<>(); + for (Requirement requirementListRequirementToAttach : requirementSpecNode.getRequirementList()) { + requirementListRequirementToAttach = em.getReference(requirementListRequirementToAttach.getClass(), requirementListRequirementToAttach.getId()); + attachedRequirementList.add(requirementListRequirementToAttach); + } + requirementSpecNode.setRequirementList(attachedRequirementList); + em.persist(requirementSpecNode); + if (requirementSpec != null) { + requirementSpec.getRequirementSpecNodeList().add(requirementSpecNode); + requirementSpec = em.merge(requirementSpec); + } + if (requirementSpecNodeRel != null) { + requirementSpecNodeRel.getRequirementSpecNodeList().add(requirementSpecNode); + requirementSpecNodeRel = em.merge(requirementSpecNodeRel); + } + for (RequirementSpecNode requirementSpecNodeListRequirementSpecNode : requirementSpecNode.getRequirementSpecNodeList()) { + RequirementSpecNode oldRequirementSpecNodeOfRequirementSpecNodeListRequirementSpecNode = requirementSpecNodeListRequirementSpecNode.getRequirementSpecNode(); + requirementSpecNodeListRequirementSpecNode.setRequirementSpecNode(requirementSpecNode); + requirementSpecNodeListRequirementSpecNode = em.merge(requirementSpecNodeListRequirementSpecNode); + if (oldRequirementSpecNodeOfRequirementSpecNodeListRequirementSpecNode != null) { + oldRequirementSpecNodeOfRequirementSpecNodeListRequirementSpecNode.getRequirementSpecNodeList().remove(requirementSpecNodeListRequirementSpecNode); + oldRequirementSpecNodeOfRequirementSpecNodeListRequirementSpecNode = em.merge(oldRequirementSpecNodeOfRequirementSpecNodeListRequirementSpecNode); + } + } + for (Requirement requirementListRequirement : requirementSpecNode.getRequirementList()) { + RequirementSpecNode oldRequirementSpecNodeOfRequirementListRequirement = requirementListRequirement.getRequirementSpecNode(); + requirementListRequirement.setRequirementSpecNode(requirementSpecNode); + requirementListRequirement = em.merge(requirementListRequirement); + if (oldRequirementSpecNodeOfRequirementListRequirement != null) { + oldRequirementSpecNodeOfRequirementListRequirement.getRequirementList().remove(requirementListRequirement); + oldRequirementSpecNodeOfRequirementListRequirement = em.merge(oldRequirementSpecNodeOfRequirementListRequirement); + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + if (findRequirementSpecNode(requirementSpecNode.getRequirementSpecNodePK()) != null) { + throw new PreexistingEntityException("RequirementSpecNode " + requirementSpecNode + " already exists.", ex); + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(RequirementSpecNode requirementSpecNode) throws IllegalOrphanException, NonexistentEntityException, Exception { + requirementSpecNode.getRequirementSpecNodePK().setRequirementSpecId(requirementSpecNode.getRequirementSpec().getRequirementSpecPK().getId()); + requirementSpecNode.getRequirementSpecNodePK().setRequirementSpecProjectId(requirementSpecNode.getRequirementSpec().getRequirementSpecPK().getProjectId()); + requirementSpecNode.getRequirementSpecNodePK().setRequirementSpecSpecLevelId(requirementSpecNode.getRequirementSpec().getRequirementSpecPK().getSpecLevelId()); + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + RequirementSpecNode persistentRequirementSpecNode = em.find(RequirementSpecNode.class, requirementSpecNode.getRequirementSpecNodePK()); + RequirementSpec requirementSpecOld = persistentRequirementSpecNode.getRequirementSpec(); + RequirementSpec requirementSpecNew = requirementSpecNode.getRequirementSpec(); + RequirementSpecNode requirementSpecNodeRelOld = persistentRequirementSpecNode.getRequirementSpecNode(); + RequirementSpecNode requirementSpecNodeRelNew = requirementSpecNode.getRequirementSpecNode(); + List requirementSpecNodeListOld = persistentRequirementSpecNode.getRequirementSpecNodeList(); + List requirementSpecNodeListNew = requirementSpecNode.getRequirementSpecNodeList(); + List requirementListOld = persistentRequirementSpecNode.getRequirementList(); + List requirementListNew = requirementSpecNode.getRequirementList(); + List illegalOrphanMessages = null; + for (Requirement requirementListOldRequirement : requirementListOld) { + if (!requirementListNew.contains(requirementListOldRequirement)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain Requirement " + requirementListOldRequirement + " since its requirementSpecNode field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + if (requirementSpecNew != null) { + requirementSpecNew = em.getReference(requirementSpecNew.getClass(), requirementSpecNew.getRequirementSpecPK()); + requirementSpecNode.setRequirementSpec(requirementSpecNew); + } + if (requirementSpecNodeRelNew != null) { + requirementSpecNodeRelNew = em.getReference(requirementSpecNodeRelNew.getClass(), requirementSpecNodeRelNew.getRequirementSpecNodePK()); + requirementSpecNode.setRequirementSpecNode(requirementSpecNodeRelNew); + } + List attachedRequirementSpecNodeListNew = new ArrayList<>(); + for (RequirementSpecNode requirementSpecNodeListNewRequirementSpecNodeToAttach : requirementSpecNodeListNew) { + requirementSpecNodeListNewRequirementSpecNodeToAttach = em.getReference(requirementSpecNodeListNewRequirementSpecNodeToAttach.getClass(), requirementSpecNodeListNewRequirementSpecNodeToAttach.getRequirementSpecNodePK()); + attachedRequirementSpecNodeListNew.add(requirementSpecNodeListNewRequirementSpecNodeToAttach); + } + requirementSpecNodeListNew = attachedRequirementSpecNodeListNew; + requirementSpecNode.setRequirementSpecNodeList(requirementSpecNodeListNew); + List attachedRequirementListNew = new ArrayList<>(); + for (Requirement requirementListNewRequirementToAttach : requirementListNew) { + requirementListNewRequirementToAttach = em.getReference(requirementListNewRequirementToAttach.getClass(), requirementListNewRequirementToAttach.getId()); + attachedRequirementListNew.add(requirementListNewRequirementToAttach); + } + requirementListNew = attachedRequirementListNew; + requirementSpecNode.setRequirementList(requirementListNew); + requirementSpecNode = em.merge(requirementSpecNode); + if (requirementSpecOld != null && !requirementSpecOld.equals(requirementSpecNew)) { + requirementSpecOld.getRequirementSpecNodeList().remove(requirementSpecNode); + requirementSpecOld = em.merge(requirementSpecOld); + } + if (requirementSpecNew != null && !requirementSpecNew.equals(requirementSpecOld)) { + requirementSpecNew.getRequirementSpecNodeList().add(requirementSpecNode); + requirementSpecNew = em.merge(requirementSpecNew); + } + if (requirementSpecNodeRelOld != null && !requirementSpecNodeRelOld.equals(requirementSpecNodeRelNew)) { + requirementSpecNodeRelOld.getRequirementSpecNodeList().remove(requirementSpecNode); + requirementSpecNodeRelOld = em.merge(requirementSpecNodeRelOld); + } + if (requirementSpecNodeRelNew != null && !requirementSpecNodeRelNew.equals(requirementSpecNodeRelOld)) { + requirementSpecNodeRelNew.getRequirementSpecNodeList().add(requirementSpecNode); + requirementSpecNodeRelNew = em.merge(requirementSpecNodeRelNew); + } + for (RequirementSpecNode requirementSpecNodeListOldRequirementSpecNode : requirementSpecNodeListOld) { + if (!requirementSpecNodeListNew.contains(requirementSpecNodeListOldRequirementSpecNode)) { + requirementSpecNodeListOldRequirementSpecNode.setRequirementSpecNode(null); + requirementSpecNodeListOldRequirementSpecNode = em.merge(requirementSpecNodeListOldRequirementSpecNode); + } + } + for (RequirementSpecNode requirementSpecNodeListNewRequirementSpecNode : requirementSpecNodeListNew) { + if (!requirementSpecNodeListOld.contains(requirementSpecNodeListNewRequirementSpecNode)) { + RequirementSpecNode oldRequirementSpecNodeOfRequirementSpecNodeListNewRequirementSpecNode = requirementSpecNodeListNewRequirementSpecNode.getRequirementSpecNode(); + requirementSpecNodeListNewRequirementSpecNode.setRequirementSpecNode(requirementSpecNode); + requirementSpecNodeListNewRequirementSpecNode = em.merge(requirementSpecNodeListNewRequirementSpecNode); + if (oldRequirementSpecNodeOfRequirementSpecNodeListNewRequirementSpecNode != null && !oldRequirementSpecNodeOfRequirementSpecNodeListNewRequirementSpecNode.equals(requirementSpecNode)) { + oldRequirementSpecNodeOfRequirementSpecNodeListNewRequirementSpecNode.getRequirementSpecNodeList().remove(requirementSpecNodeListNewRequirementSpecNode); + oldRequirementSpecNodeOfRequirementSpecNodeListNewRequirementSpecNode = em.merge(oldRequirementSpecNodeOfRequirementSpecNodeListNewRequirementSpecNode); + } + } + } + for (Requirement requirementListNewRequirement : requirementListNew) { + if (!requirementListOld.contains(requirementListNewRequirement)) { + RequirementSpecNode oldRequirementSpecNodeOfRequirementListNewRequirement = requirementListNewRequirement.getRequirementSpecNode(); + requirementListNewRequirement.setRequirementSpecNode(requirementSpecNode); + requirementListNewRequirement = em.merge(requirementListNewRequirement); + if (oldRequirementSpecNodeOfRequirementListNewRequirement != null && !oldRequirementSpecNodeOfRequirementListNewRequirement.equals(requirementSpecNode)) { + oldRequirementSpecNodeOfRequirementListNewRequirement.getRequirementList().remove(requirementListNewRequirement); + oldRequirementSpecNodeOfRequirementListNewRequirement = em.merge(oldRequirementSpecNodeOfRequirementListNewRequirement); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + RequirementSpecNodePK id = requirementSpecNode.getRequirementSpecNodePK(); + if (findRequirementSpecNode(id) == null) { + throw new NonexistentEntityException("The requirementSpecNode with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(RequirementSpecNodePK id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + RequirementSpecNode requirementSpecNode; + try { + requirementSpecNode = em.getReference(RequirementSpecNode.class, id); + requirementSpecNode.getRequirementSpecNodePK(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The requirementSpecNode with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List requirementListOrphanCheck = requirementSpecNode.getRequirementList(); + for (Requirement requirementListOrphanCheckRequirement : requirementListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This RequirementSpecNode (" + requirementSpecNode + ") cannot be destroyed since the Requirement " + requirementListOrphanCheckRequirement + " in its requirementList field has a non-nullable requirementSpecNode field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + RequirementSpec requirementSpec = requirementSpecNode.getRequirementSpec(); + if (requirementSpec != null) { + requirementSpec.getRequirementSpecNodeList().remove(requirementSpecNode); + requirementSpec = em.merge(requirementSpec); + } + RequirementSpecNode requirementSpecNodeRel = requirementSpecNode.getRequirementSpecNode(); + if (requirementSpecNodeRel != null) { + requirementSpecNodeRel.getRequirementSpecNodeList().remove(requirementSpecNode); + requirementSpecNodeRel = em.merge(requirementSpecNodeRel); + } + List requirementSpecNodeList = requirementSpecNode.getRequirementSpecNodeList(); + for (RequirementSpecNode requirementSpecNodeListRequirementSpecNode : requirementSpecNodeList) { + requirementSpecNodeListRequirementSpecNode.setRequirementSpecNode(null); + requirementSpecNodeListRequirementSpecNode = em.merge(requirementSpecNodeListRequirementSpecNode); + } + em.remove(requirementSpecNode); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findRequirementSpecNodeEntities() { + return findRequirementSpecNodeEntities(true, -1, -1); + } + + public List findRequirementSpecNodeEntities(int maxResults, int firstResult) { + return findRequirementSpecNodeEntities(false, maxResults, firstResult); + } + + private List findRequirementSpecNodeEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(RequirementSpecNode.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public RequirementSpecNode findRequirementSpecNode(RequirementSpecNodePK id) { + EntityManager em = getEntityManager(); + try { + return em.find(RequirementSpecNode.class, id); + } + finally { + em.close(); + } + } + + public int getRequirementSpecNodeCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(RequirementSpecNode.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/RequirementStatusJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/RequirementStatusJpaController.java index 0c4879a9..a06633dd 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/RequirementStatusJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/RequirementStatusJpaController.java @@ -13,209 +13,209 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.Requirement; -import com.validation.manager.core.db.RequirementStatus; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import java.util.ArrayList; -import java.util.List; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class RequirementStatusJpaController implements Serializable { - - public RequirementStatusJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(RequirementStatus requirementStatus) { - if (requirementStatus.getRequirementList() == null) { - requirementStatus.setRequirementList(new ArrayList()); - } - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - List attachedRequirementList = new ArrayList(); - for (Requirement requirementListRequirementToAttach : requirementStatus.getRequirementList()) { - requirementListRequirementToAttach = em.getReference(requirementListRequirementToAttach.getClass(), requirementListRequirementToAttach.getId()); - attachedRequirementList.add(requirementListRequirementToAttach); - } - requirementStatus.setRequirementList(attachedRequirementList); - em.persist(requirementStatus); - for (Requirement requirementListRequirement : requirementStatus.getRequirementList()) { - RequirementStatus oldRequirementStatusIdOfRequirementListRequirement = requirementListRequirement.getRequirementStatusId(); - requirementListRequirement.setRequirementStatusId(requirementStatus); - requirementListRequirement = em.merge(requirementListRequirement); - if (oldRequirementStatusIdOfRequirementListRequirement != null) { - oldRequirementStatusIdOfRequirementListRequirement.getRequirementList().remove(requirementListRequirement); - oldRequirementStatusIdOfRequirementListRequirement = em.merge(oldRequirementStatusIdOfRequirementListRequirement); - } - } - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(RequirementStatus requirementStatus) throws IllegalOrphanException, NonexistentEntityException, Exception { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - RequirementStatus persistentRequirementStatus = em.find(RequirementStatus.class, requirementStatus.getId()); - List requirementListOld = persistentRequirementStatus.getRequirementList(); - List requirementListNew = requirementStatus.getRequirementList(); - List illegalOrphanMessages = null; - for (Requirement requirementListOldRequirement : requirementListOld) { - if (!requirementListNew.contains(requirementListOldRequirement)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain Requirement " + requirementListOldRequirement + " since its requirementStatusId field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - List attachedRequirementListNew = new ArrayList(); - for (Requirement requirementListNewRequirementToAttach : requirementListNew) { - requirementListNewRequirementToAttach = em.getReference(requirementListNewRequirementToAttach.getClass(), requirementListNewRequirementToAttach.getId()); - attachedRequirementListNew.add(requirementListNewRequirementToAttach); - } - requirementListNew = attachedRequirementListNew; - requirementStatus.setRequirementList(requirementListNew); - requirementStatus = em.merge(requirementStatus); - for (Requirement requirementListNewRequirement : requirementListNew) { - if (!requirementListOld.contains(requirementListNewRequirement)) { - RequirementStatus oldRequirementStatusIdOfRequirementListNewRequirement = requirementListNewRequirement.getRequirementStatusId(); - requirementListNewRequirement.setRequirementStatusId(requirementStatus); - requirementListNewRequirement = em.merge(requirementListNewRequirement); - if (oldRequirementStatusIdOfRequirementListNewRequirement != null && !oldRequirementStatusIdOfRequirementListNewRequirement.equals(requirementStatus)) { - oldRequirementStatusIdOfRequirementListNewRequirement.getRequirementList().remove(requirementListNewRequirement); - oldRequirementStatusIdOfRequirementListNewRequirement = em.merge(oldRequirementStatusIdOfRequirementListNewRequirement); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - Integer id = requirementStatus.getId(); - if (findRequirementStatus(id) == null) { - throw new NonexistentEntityException("The requirementStatus with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - RequirementStatus requirementStatus; - try { - requirementStatus = em.getReference(RequirementStatus.class, id); - requirementStatus.getId(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The requirementStatus with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List requirementListOrphanCheck = requirementStatus.getRequirementList(); - for (Requirement requirementListOrphanCheckRequirement : requirementListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This RequirementStatus (" + requirementStatus + ") cannot be destroyed since the Requirement " + requirementListOrphanCheckRequirement + " in its requirementList field has a non-nullable requirementStatusId field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - em.remove(requirementStatus); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findRequirementStatusEntities() { - return findRequirementStatusEntities(true, -1, -1); - } - - public List findRequirementStatusEntities(int maxResults, int firstResult) { - return findRequirementStatusEntities(false, maxResults, firstResult); - } - - private List findRequirementStatusEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(RequirementStatus.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public RequirementStatus findRequirementStatus(Integer id) { - EntityManager em = getEntityManager(); - try { - return em.find(RequirementStatus.class, id); - } - finally { - em.close(); - } - } - - public int getRequirementStatusCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(RequirementStatus.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.Requirement; +import com.validation.manager.core.db.RequirementStatus; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import java.util.ArrayList; +import java.util.List; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class RequirementStatusJpaController implements Serializable { + + public RequirementStatusJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(RequirementStatus requirementStatus) { + if (requirementStatus.getRequirementList() == null) { + requirementStatus.setRequirementList(new ArrayList<>()); + } + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + List attachedRequirementList = new ArrayList<>(); + for (Requirement requirementListRequirementToAttach : requirementStatus.getRequirementList()) { + requirementListRequirementToAttach = em.getReference(requirementListRequirementToAttach.getClass(), requirementListRequirementToAttach.getId()); + attachedRequirementList.add(requirementListRequirementToAttach); + } + requirementStatus.setRequirementList(attachedRequirementList); + em.persist(requirementStatus); + for (Requirement requirementListRequirement : requirementStatus.getRequirementList()) { + RequirementStatus oldRequirementStatusIdOfRequirementListRequirement = requirementListRequirement.getRequirementStatusId(); + requirementListRequirement.setRequirementStatusId(requirementStatus); + requirementListRequirement = em.merge(requirementListRequirement); + if (oldRequirementStatusIdOfRequirementListRequirement != null) { + oldRequirementStatusIdOfRequirementListRequirement.getRequirementList().remove(requirementListRequirement); + oldRequirementStatusIdOfRequirementListRequirement = em.merge(oldRequirementStatusIdOfRequirementListRequirement); + } + } + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(RequirementStatus requirementStatus) throws IllegalOrphanException, NonexistentEntityException, Exception { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + RequirementStatus persistentRequirementStatus = em.find(RequirementStatus.class, requirementStatus.getId()); + List requirementListOld = persistentRequirementStatus.getRequirementList(); + List requirementListNew = requirementStatus.getRequirementList(); + List illegalOrphanMessages = null; + for (Requirement requirementListOldRequirement : requirementListOld) { + if (!requirementListNew.contains(requirementListOldRequirement)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain Requirement " + requirementListOldRequirement + " since its requirementStatusId field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + List attachedRequirementListNew = new ArrayList<>(); + for (Requirement requirementListNewRequirementToAttach : requirementListNew) { + requirementListNewRequirementToAttach = em.getReference(requirementListNewRequirementToAttach.getClass(), requirementListNewRequirementToAttach.getId()); + attachedRequirementListNew.add(requirementListNewRequirementToAttach); + } + requirementListNew = attachedRequirementListNew; + requirementStatus.setRequirementList(requirementListNew); + requirementStatus = em.merge(requirementStatus); + for (Requirement requirementListNewRequirement : requirementListNew) { + if (!requirementListOld.contains(requirementListNewRequirement)) { + RequirementStatus oldRequirementStatusIdOfRequirementListNewRequirement = requirementListNewRequirement.getRequirementStatusId(); + requirementListNewRequirement.setRequirementStatusId(requirementStatus); + requirementListNewRequirement = em.merge(requirementListNewRequirement); + if (oldRequirementStatusIdOfRequirementListNewRequirement != null && !oldRequirementStatusIdOfRequirementListNewRequirement.equals(requirementStatus)) { + oldRequirementStatusIdOfRequirementListNewRequirement.getRequirementList().remove(requirementListNewRequirement); + oldRequirementStatusIdOfRequirementListNewRequirement = em.merge(oldRequirementStatusIdOfRequirementListNewRequirement); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + Integer id = requirementStatus.getId(); + if (findRequirementStatus(id) == null) { + throw new NonexistentEntityException("The requirementStatus with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + RequirementStatus requirementStatus; + try { + requirementStatus = em.getReference(RequirementStatus.class, id); + requirementStatus.getId(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The requirementStatus with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List requirementListOrphanCheck = requirementStatus.getRequirementList(); + for (Requirement requirementListOrphanCheckRequirement : requirementListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This RequirementStatus (" + requirementStatus + ") cannot be destroyed since the Requirement " + requirementListOrphanCheckRequirement + " in its requirementList field has a non-nullable requirementStatusId field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + em.remove(requirementStatus); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findRequirementStatusEntities() { + return findRequirementStatusEntities(true, -1, -1); + } + + public List findRequirementStatusEntities(int maxResults, int firstResult) { + return findRequirementStatusEntities(false, maxResults, firstResult); + } + + private List findRequirementStatusEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(RequirementStatus.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public RequirementStatus findRequirementStatus(Integer id) { + EntityManager em = getEntityManager(); + try { + return em.find(RequirementStatus.class, id); + } + finally { + em.close(); + } + } + + public int getRequirementStatusCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(RequirementStatus.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/RequirementTypeJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/RequirementTypeJpaController.java index fbf4cff6..d07cc7a4 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/RequirementTypeJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/RequirementTypeJpaController.java @@ -13,209 +13,209 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.Requirement; -import com.validation.manager.core.db.RequirementType; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import java.util.ArrayList; -import java.util.List; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class RequirementTypeJpaController implements Serializable { - - public RequirementTypeJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(RequirementType requirementType) { - if (requirementType.getRequirementList() == null) { - requirementType.setRequirementList(new ArrayList()); - } - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - List attachedRequirementList = new ArrayList(); - for (Requirement requirementListRequirementToAttach : requirementType.getRequirementList()) { - requirementListRequirementToAttach = em.getReference(requirementListRequirementToAttach.getClass(), requirementListRequirementToAttach.getId()); - attachedRequirementList.add(requirementListRequirementToAttach); - } - requirementType.setRequirementList(attachedRequirementList); - em.persist(requirementType); - for (Requirement requirementListRequirement : requirementType.getRequirementList()) { - RequirementType oldRequirementTypeIdOfRequirementListRequirement = requirementListRequirement.getRequirementTypeId(); - requirementListRequirement.setRequirementTypeId(requirementType); - requirementListRequirement = em.merge(requirementListRequirement); - if (oldRequirementTypeIdOfRequirementListRequirement != null) { - oldRequirementTypeIdOfRequirementListRequirement.getRequirementList().remove(requirementListRequirement); - oldRequirementTypeIdOfRequirementListRequirement = em.merge(oldRequirementTypeIdOfRequirementListRequirement); - } - } - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(RequirementType requirementType) throws IllegalOrphanException, NonexistentEntityException, Exception { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - RequirementType persistentRequirementType = em.find(RequirementType.class, requirementType.getId()); - List requirementListOld = persistentRequirementType.getRequirementList(); - List requirementListNew = requirementType.getRequirementList(); - List illegalOrphanMessages = null; - for (Requirement requirementListOldRequirement : requirementListOld) { - if (!requirementListNew.contains(requirementListOldRequirement)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain Requirement " + requirementListOldRequirement + " since its requirementTypeId field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - List attachedRequirementListNew = new ArrayList(); - for (Requirement requirementListNewRequirementToAttach : requirementListNew) { - requirementListNewRequirementToAttach = em.getReference(requirementListNewRequirementToAttach.getClass(), requirementListNewRequirementToAttach.getId()); - attachedRequirementListNew.add(requirementListNewRequirementToAttach); - } - requirementListNew = attachedRequirementListNew; - requirementType.setRequirementList(requirementListNew); - requirementType = em.merge(requirementType); - for (Requirement requirementListNewRequirement : requirementListNew) { - if (!requirementListOld.contains(requirementListNewRequirement)) { - RequirementType oldRequirementTypeIdOfRequirementListNewRequirement = requirementListNewRequirement.getRequirementTypeId(); - requirementListNewRequirement.setRequirementTypeId(requirementType); - requirementListNewRequirement = em.merge(requirementListNewRequirement); - if (oldRequirementTypeIdOfRequirementListNewRequirement != null && !oldRequirementTypeIdOfRequirementListNewRequirement.equals(requirementType)) { - oldRequirementTypeIdOfRequirementListNewRequirement.getRequirementList().remove(requirementListNewRequirement); - oldRequirementTypeIdOfRequirementListNewRequirement = em.merge(oldRequirementTypeIdOfRequirementListNewRequirement); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - Integer id = requirementType.getId(); - if (findRequirementType(id) == null) { - throw new NonexistentEntityException("The requirementType with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - RequirementType requirementType; - try { - requirementType = em.getReference(RequirementType.class, id); - requirementType.getId(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The requirementType with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List requirementListOrphanCheck = requirementType.getRequirementList(); - for (Requirement requirementListOrphanCheckRequirement : requirementListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This RequirementType (" + requirementType + ") cannot be destroyed since the Requirement " + requirementListOrphanCheckRequirement + " in its requirementList field has a non-nullable requirementTypeId field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - em.remove(requirementType); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findRequirementTypeEntities() { - return findRequirementTypeEntities(true, -1, -1); - } - - public List findRequirementTypeEntities(int maxResults, int firstResult) { - return findRequirementTypeEntities(false, maxResults, firstResult); - } - - private List findRequirementTypeEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(RequirementType.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public RequirementType findRequirementType(Integer id) { - EntityManager em = getEntityManager(); - try { - return em.find(RequirementType.class, id); - } - finally { - em.close(); - } - } - - public int getRequirementTypeCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(RequirementType.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.Requirement; +import com.validation.manager.core.db.RequirementType; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import java.util.ArrayList; +import java.util.List; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class RequirementTypeJpaController implements Serializable { + + public RequirementTypeJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(RequirementType requirementType) { + if (requirementType.getRequirementList() == null) { + requirementType.setRequirementList(new ArrayList<>()); + } + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + List attachedRequirementList = new ArrayList<>(); + for (Requirement requirementListRequirementToAttach : requirementType.getRequirementList()) { + requirementListRequirementToAttach = em.getReference(requirementListRequirementToAttach.getClass(), requirementListRequirementToAttach.getId()); + attachedRequirementList.add(requirementListRequirementToAttach); + } + requirementType.setRequirementList(attachedRequirementList); + em.persist(requirementType); + for (Requirement requirementListRequirement : requirementType.getRequirementList()) { + RequirementType oldRequirementTypeIdOfRequirementListRequirement = requirementListRequirement.getRequirementTypeId(); + requirementListRequirement.setRequirementTypeId(requirementType); + requirementListRequirement = em.merge(requirementListRequirement); + if (oldRequirementTypeIdOfRequirementListRequirement != null) { + oldRequirementTypeIdOfRequirementListRequirement.getRequirementList().remove(requirementListRequirement); + oldRequirementTypeIdOfRequirementListRequirement = em.merge(oldRequirementTypeIdOfRequirementListRequirement); + } + } + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(RequirementType requirementType) throws IllegalOrphanException, NonexistentEntityException, Exception { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + RequirementType persistentRequirementType = em.find(RequirementType.class, requirementType.getId()); + List requirementListOld = persistentRequirementType.getRequirementList(); + List requirementListNew = requirementType.getRequirementList(); + List illegalOrphanMessages = null; + for (Requirement requirementListOldRequirement : requirementListOld) { + if (!requirementListNew.contains(requirementListOldRequirement)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain Requirement " + requirementListOldRequirement + " since its requirementTypeId field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + List attachedRequirementListNew = new ArrayList<>(); + for (Requirement requirementListNewRequirementToAttach : requirementListNew) { + requirementListNewRequirementToAttach = em.getReference(requirementListNewRequirementToAttach.getClass(), requirementListNewRequirementToAttach.getId()); + attachedRequirementListNew.add(requirementListNewRequirementToAttach); + } + requirementListNew = attachedRequirementListNew; + requirementType.setRequirementList(requirementListNew); + requirementType = em.merge(requirementType); + for (Requirement requirementListNewRequirement : requirementListNew) { + if (!requirementListOld.contains(requirementListNewRequirement)) { + RequirementType oldRequirementTypeIdOfRequirementListNewRequirement = requirementListNewRequirement.getRequirementTypeId(); + requirementListNewRequirement.setRequirementTypeId(requirementType); + requirementListNewRequirement = em.merge(requirementListNewRequirement); + if (oldRequirementTypeIdOfRequirementListNewRequirement != null && !oldRequirementTypeIdOfRequirementListNewRequirement.equals(requirementType)) { + oldRequirementTypeIdOfRequirementListNewRequirement.getRequirementList().remove(requirementListNewRequirement); + oldRequirementTypeIdOfRequirementListNewRequirement = em.merge(oldRequirementTypeIdOfRequirementListNewRequirement); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + Integer id = requirementType.getId(); + if (findRequirementType(id) == null) { + throw new NonexistentEntityException("The requirementType with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + RequirementType requirementType; + try { + requirementType = em.getReference(RequirementType.class, id); + requirementType.getId(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The requirementType with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List requirementListOrphanCheck = requirementType.getRequirementList(); + for (Requirement requirementListOrphanCheckRequirement : requirementListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This RequirementType (" + requirementType + ") cannot be destroyed since the Requirement " + requirementListOrphanCheckRequirement + " in its requirementList field has a non-nullable requirementTypeId field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + em.remove(requirementType); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findRequirementTypeEntities() { + return findRequirementTypeEntities(true, -1, -1); + } + + public List findRequirementTypeEntities(int maxResults, int firstResult) { + return findRequirementTypeEntities(false, maxResults, firstResult); + } + + private List findRequirementTypeEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(RequirementType.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public RequirementType findRequirementType(Integer id) { + EntityManager em = getEntityManager(); + try { + return em.find(RequirementType.class, id); + } + finally { + em.close(); + } + } + + public int getRequirementTypeCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(RequirementType.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/ReviewResultJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/ReviewResultJpaController.java index 58a61f66..b84cf788 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/ReviewResultJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/ReviewResultJpaController.java @@ -13,196 +13,196 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.ExecutionStep; -import com.validation.manager.core.db.ReviewResult; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import java.util.ArrayList; -import java.util.List; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class ReviewResultJpaController implements Serializable { - - public ReviewResultJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(ReviewResult reviewResult) { - if (reviewResult.getExecutionStepList() == null) { - reviewResult.setExecutionStepList(new ArrayList()); - } - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - List attachedExecutionStepList = new ArrayList(); - for (ExecutionStep executionStepListExecutionStepToAttach : reviewResult.getExecutionStepList()) { - executionStepListExecutionStepToAttach = em.getReference(executionStepListExecutionStepToAttach.getClass(), executionStepListExecutionStepToAttach.getExecutionStepPK()); - attachedExecutionStepList.add(executionStepListExecutionStepToAttach); - } - reviewResult.setExecutionStepList(attachedExecutionStepList); - em.persist(reviewResult); - for (ExecutionStep executionStepListExecutionStep : reviewResult.getExecutionStepList()) { - ReviewResult oldReviewResultIdOfExecutionStepListExecutionStep = executionStepListExecutionStep.getReviewResultId(); - executionStepListExecutionStep.setReviewResultId(reviewResult); - executionStepListExecutionStep = em.merge(executionStepListExecutionStep); - if (oldReviewResultIdOfExecutionStepListExecutionStep != null) { - oldReviewResultIdOfExecutionStepListExecutionStep.getExecutionStepList().remove(executionStepListExecutionStep); - oldReviewResultIdOfExecutionStepListExecutionStep = em.merge(oldReviewResultIdOfExecutionStepListExecutionStep); - } - } - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(ReviewResult reviewResult) throws NonexistentEntityException, Exception { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - ReviewResult persistentReviewResult = em.find(ReviewResult.class, reviewResult.getId()); - List executionStepListOld = persistentReviewResult.getExecutionStepList(); - List executionStepListNew = reviewResult.getExecutionStepList(); - List attachedExecutionStepListNew = new ArrayList(); - for (ExecutionStep executionStepListNewExecutionStepToAttach : executionStepListNew) { - executionStepListNewExecutionStepToAttach = em.getReference(executionStepListNewExecutionStepToAttach.getClass(), executionStepListNewExecutionStepToAttach.getExecutionStepPK()); - attachedExecutionStepListNew.add(executionStepListNewExecutionStepToAttach); - } - executionStepListNew = attachedExecutionStepListNew; - reviewResult.setExecutionStepList(executionStepListNew); - reviewResult = em.merge(reviewResult); - for (ExecutionStep executionStepListOldExecutionStep : executionStepListOld) { - if (!executionStepListNew.contains(executionStepListOldExecutionStep)) { - executionStepListOldExecutionStep.setReviewResultId(null); - executionStepListOldExecutionStep = em.merge(executionStepListOldExecutionStep); - } - } - for (ExecutionStep executionStepListNewExecutionStep : executionStepListNew) { - if (!executionStepListOld.contains(executionStepListNewExecutionStep)) { - ReviewResult oldReviewResultIdOfExecutionStepListNewExecutionStep = executionStepListNewExecutionStep.getReviewResultId(); - executionStepListNewExecutionStep.setReviewResultId(reviewResult); - executionStepListNewExecutionStep = em.merge(executionStepListNewExecutionStep); - if (oldReviewResultIdOfExecutionStepListNewExecutionStep != null && !oldReviewResultIdOfExecutionStepListNewExecutionStep.equals(reviewResult)) { - oldReviewResultIdOfExecutionStepListNewExecutionStep.getExecutionStepList().remove(executionStepListNewExecutionStep); - oldReviewResultIdOfExecutionStepListNewExecutionStep = em.merge(oldReviewResultIdOfExecutionStepListNewExecutionStep); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - Integer id = reviewResult.getId(); - if (findReviewResult(id) == null) { - throw new NonexistentEntityException("The reviewResult with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(Integer id) throws NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - ReviewResult reviewResult; - try { - reviewResult = em.getReference(ReviewResult.class, id); - reviewResult.getId(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The reviewResult with id " + id + " no longer exists.", enfe); - } - List executionStepList = reviewResult.getExecutionStepList(); - for (ExecutionStep executionStepListExecutionStep : executionStepList) { - executionStepListExecutionStep.setReviewResultId(null); - executionStepListExecutionStep = em.merge(executionStepListExecutionStep); - } - em.remove(reviewResult); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findReviewResultEntities() { - return findReviewResultEntities(true, -1, -1); - } - - public List findReviewResultEntities(int maxResults, int firstResult) { - return findReviewResultEntities(false, maxResults, firstResult); - } - - private List findReviewResultEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(ReviewResult.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public ReviewResult findReviewResult(Integer id) { - EntityManager em = getEntityManager(); - try { - return em.find(ReviewResult.class, id); - } - finally { - em.close(); - } - } - - public int getReviewResultCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(ReviewResult.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.ExecutionStep; +import com.validation.manager.core.db.ReviewResult; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import java.util.ArrayList; +import java.util.List; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class ReviewResultJpaController implements Serializable { + + public ReviewResultJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(ReviewResult reviewResult) { + if (reviewResult.getExecutionStepList() == null) { + reviewResult.setExecutionStepList(new ArrayList<>()); + } + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + List attachedExecutionStepList = new ArrayList<>(); + for (ExecutionStep executionStepListExecutionStepToAttach : reviewResult.getExecutionStepList()) { + executionStepListExecutionStepToAttach = em.getReference(executionStepListExecutionStepToAttach.getClass(), executionStepListExecutionStepToAttach.getExecutionStepPK()); + attachedExecutionStepList.add(executionStepListExecutionStepToAttach); + } + reviewResult.setExecutionStepList(attachedExecutionStepList); + em.persist(reviewResult); + for (ExecutionStep executionStepListExecutionStep : reviewResult.getExecutionStepList()) { + ReviewResult oldReviewResultIdOfExecutionStepListExecutionStep = executionStepListExecutionStep.getReviewResultId(); + executionStepListExecutionStep.setReviewResultId(reviewResult); + executionStepListExecutionStep = em.merge(executionStepListExecutionStep); + if (oldReviewResultIdOfExecutionStepListExecutionStep != null) { + oldReviewResultIdOfExecutionStepListExecutionStep.getExecutionStepList().remove(executionStepListExecutionStep); + oldReviewResultIdOfExecutionStepListExecutionStep = em.merge(oldReviewResultIdOfExecutionStepListExecutionStep); + } + } + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(ReviewResult reviewResult) throws NonexistentEntityException, Exception { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + ReviewResult persistentReviewResult = em.find(ReviewResult.class, reviewResult.getId()); + List executionStepListOld = persistentReviewResult.getExecutionStepList(); + List executionStepListNew = reviewResult.getExecutionStepList(); + List attachedExecutionStepListNew = new ArrayList<>(); + for (ExecutionStep executionStepListNewExecutionStepToAttach : executionStepListNew) { + executionStepListNewExecutionStepToAttach = em.getReference(executionStepListNewExecutionStepToAttach.getClass(), executionStepListNewExecutionStepToAttach.getExecutionStepPK()); + attachedExecutionStepListNew.add(executionStepListNewExecutionStepToAttach); + } + executionStepListNew = attachedExecutionStepListNew; + reviewResult.setExecutionStepList(executionStepListNew); + reviewResult = em.merge(reviewResult); + for (ExecutionStep executionStepListOldExecutionStep : executionStepListOld) { + if (!executionStepListNew.contains(executionStepListOldExecutionStep)) { + executionStepListOldExecutionStep.setReviewResultId(null); + executionStepListOldExecutionStep = em.merge(executionStepListOldExecutionStep); + } + } + for (ExecutionStep executionStepListNewExecutionStep : executionStepListNew) { + if (!executionStepListOld.contains(executionStepListNewExecutionStep)) { + ReviewResult oldReviewResultIdOfExecutionStepListNewExecutionStep = executionStepListNewExecutionStep.getReviewResultId(); + executionStepListNewExecutionStep.setReviewResultId(reviewResult); + executionStepListNewExecutionStep = em.merge(executionStepListNewExecutionStep); + if (oldReviewResultIdOfExecutionStepListNewExecutionStep != null && !oldReviewResultIdOfExecutionStepListNewExecutionStep.equals(reviewResult)) { + oldReviewResultIdOfExecutionStepListNewExecutionStep.getExecutionStepList().remove(executionStepListNewExecutionStep); + oldReviewResultIdOfExecutionStepListNewExecutionStep = em.merge(oldReviewResultIdOfExecutionStepListNewExecutionStep); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + Integer id = reviewResult.getId(); + if (findReviewResult(id) == null) { + throw new NonexistentEntityException("The reviewResult with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(Integer id) throws NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + ReviewResult reviewResult; + try { + reviewResult = em.getReference(ReviewResult.class, id); + reviewResult.getId(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The reviewResult with id " + id + " no longer exists.", enfe); + } + List executionStepList = reviewResult.getExecutionStepList(); + for (ExecutionStep executionStepListExecutionStep : executionStepList) { + executionStepListExecutionStep.setReviewResultId(null); + executionStepListExecutionStep = em.merge(executionStepListExecutionStep); + } + em.remove(reviewResult); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findReviewResultEntities() { + return findReviewResultEntities(true, -1, -1); + } + + public List findReviewResultEntities(int maxResults, int firstResult) { + return findReviewResultEntities(false, maxResults, firstResult); + } + + private List findReviewResultEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(ReviewResult.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public ReviewResult findReviewResult(Integer id) { + EntityManager em = getEntityManager(); + try { + return em.find(ReviewResult.class, id); + } + finally { + em.close(); + } + } + + public int getReviewResultCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(ReviewResult.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/RiskCategoryJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/RiskCategoryJpaController.java index 0c3af823..51bdb7a9 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/RiskCategoryJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/RiskCategoryJpaController.java @@ -13,249 +13,249 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.Fmea; -import com.validation.manager.core.db.RiskCategory; -import java.util.ArrayList; -import java.util.List; -import com.validation.manager.core.db.RiskItemHasRiskCategory; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class RiskCategoryJpaController implements Serializable { - - public RiskCategoryJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(RiskCategory riskCategory) { - if (riskCategory.getFmeaList() == null) { - riskCategory.setFmeaList(new ArrayList()); - } - if (riskCategory.getRiskItemHasRiskCategoryList() == null) { - riskCategory.setRiskItemHasRiskCategoryList(new ArrayList()); - } - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - List attachedFmeaList = new ArrayList(); - for (Fmea fmeaListFmeaToAttach : riskCategory.getFmeaList()) { - fmeaListFmeaToAttach = em.getReference(fmeaListFmeaToAttach.getClass(), fmeaListFmeaToAttach.getId()); - attachedFmeaList.add(fmeaListFmeaToAttach); - } - riskCategory.setFmeaList(attachedFmeaList); - List attachedRiskItemHasRiskCategoryList = new ArrayList(); - for (RiskItemHasRiskCategory riskItemHasRiskCategoryListRiskItemHasRiskCategoryToAttach : riskCategory.getRiskItemHasRiskCategoryList()) { - riskItemHasRiskCategoryListRiskItemHasRiskCategoryToAttach = em.getReference(riskItemHasRiskCategoryListRiskItemHasRiskCategoryToAttach.getClass(), riskItemHasRiskCategoryListRiskItemHasRiskCategoryToAttach.getRiskItemHasRiskCategoryPK()); - attachedRiskItemHasRiskCategoryList.add(riskItemHasRiskCategoryListRiskItemHasRiskCategoryToAttach); - } - riskCategory.setRiskItemHasRiskCategoryList(attachedRiskItemHasRiskCategoryList); - em.persist(riskCategory); - for (Fmea fmeaListFmea : riskCategory.getFmeaList()) { - fmeaListFmea.getRiskCategoryList().add(riskCategory); - fmeaListFmea = em.merge(fmeaListFmea); - } - for (RiskItemHasRiskCategory riskItemHasRiskCategoryListRiskItemHasRiskCategory : riskCategory.getRiskItemHasRiskCategoryList()) { - RiskCategory oldRiskCategoryOfRiskItemHasRiskCategoryListRiskItemHasRiskCategory = riskItemHasRiskCategoryListRiskItemHasRiskCategory.getRiskCategory(); - riskItemHasRiskCategoryListRiskItemHasRiskCategory.setRiskCategory(riskCategory); - riskItemHasRiskCategoryListRiskItemHasRiskCategory = em.merge(riskItemHasRiskCategoryListRiskItemHasRiskCategory); - if (oldRiskCategoryOfRiskItemHasRiskCategoryListRiskItemHasRiskCategory != null) { - oldRiskCategoryOfRiskItemHasRiskCategoryListRiskItemHasRiskCategory.getRiskItemHasRiskCategoryList().remove(riskItemHasRiskCategoryListRiskItemHasRiskCategory); - oldRiskCategoryOfRiskItemHasRiskCategoryListRiskItemHasRiskCategory = em.merge(oldRiskCategoryOfRiskItemHasRiskCategoryListRiskItemHasRiskCategory); - } - } - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(RiskCategory riskCategory) throws IllegalOrphanException, NonexistentEntityException, Exception { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - RiskCategory persistentRiskCategory = em.find(RiskCategory.class, riskCategory.getId()); - List fmeaListOld = persistentRiskCategory.getFmeaList(); - List fmeaListNew = riskCategory.getFmeaList(); - List riskItemHasRiskCategoryListOld = persistentRiskCategory.getRiskItemHasRiskCategoryList(); - List riskItemHasRiskCategoryListNew = riskCategory.getRiskItemHasRiskCategoryList(); - List illegalOrphanMessages = null; - for (RiskItemHasRiskCategory riskItemHasRiskCategoryListOldRiskItemHasRiskCategory : riskItemHasRiskCategoryListOld) { - if (!riskItemHasRiskCategoryListNew.contains(riskItemHasRiskCategoryListOldRiskItemHasRiskCategory)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain RiskItemHasRiskCategory " + riskItemHasRiskCategoryListOldRiskItemHasRiskCategory + " since its riskCategory field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - List attachedFmeaListNew = new ArrayList(); - for (Fmea fmeaListNewFmeaToAttach : fmeaListNew) { - fmeaListNewFmeaToAttach = em.getReference(fmeaListNewFmeaToAttach.getClass(), fmeaListNewFmeaToAttach.getId()); - attachedFmeaListNew.add(fmeaListNewFmeaToAttach); - } - fmeaListNew = attachedFmeaListNew; - riskCategory.setFmeaList(fmeaListNew); - List attachedRiskItemHasRiskCategoryListNew = new ArrayList(); - for (RiskItemHasRiskCategory riskItemHasRiskCategoryListNewRiskItemHasRiskCategoryToAttach : riskItemHasRiskCategoryListNew) { - riskItemHasRiskCategoryListNewRiskItemHasRiskCategoryToAttach = em.getReference(riskItemHasRiskCategoryListNewRiskItemHasRiskCategoryToAttach.getClass(), riskItemHasRiskCategoryListNewRiskItemHasRiskCategoryToAttach.getRiskItemHasRiskCategoryPK()); - attachedRiskItemHasRiskCategoryListNew.add(riskItemHasRiskCategoryListNewRiskItemHasRiskCategoryToAttach); - } - riskItemHasRiskCategoryListNew = attachedRiskItemHasRiskCategoryListNew; - riskCategory.setRiskItemHasRiskCategoryList(riskItemHasRiskCategoryListNew); - riskCategory = em.merge(riskCategory); - for (Fmea fmeaListOldFmea : fmeaListOld) { - if (!fmeaListNew.contains(fmeaListOldFmea)) { - fmeaListOldFmea.getRiskCategoryList().remove(riskCategory); - fmeaListOldFmea = em.merge(fmeaListOldFmea); - } - } - for (Fmea fmeaListNewFmea : fmeaListNew) { - if (!fmeaListOld.contains(fmeaListNewFmea)) { - fmeaListNewFmea.getRiskCategoryList().add(riskCategory); - fmeaListNewFmea = em.merge(fmeaListNewFmea); - } - } - for (RiskItemHasRiskCategory riskItemHasRiskCategoryListNewRiskItemHasRiskCategory : riskItemHasRiskCategoryListNew) { - if (!riskItemHasRiskCategoryListOld.contains(riskItemHasRiskCategoryListNewRiskItemHasRiskCategory)) { - RiskCategory oldRiskCategoryOfRiskItemHasRiskCategoryListNewRiskItemHasRiskCategory = riskItemHasRiskCategoryListNewRiskItemHasRiskCategory.getRiskCategory(); - riskItemHasRiskCategoryListNewRiskItemHasRiskCategory.setRiskCategory(riskCategory); - riskItemHasRiskCategoryListNewRiskItemHasRiskCategory = em.merge(riskItemHasRiskCategoryListNewRiskItemHasRiskCategory); - if (oldRiskCategoryOfRiskItemHasRiskCategoryListNewRiskItemHasRiskCategory != null && !oldRiskCategoryOfRiskItemHasRiskCategoryListNewRiskItemHasRiskCategory.equals(riskCategory)) { - oldRiskCategoryOfRiskItemHasRiskCategoryListNewRiskItemHasRiskCategory.getRiskItemHasRiskCategoryList().remove(riskItemHasRiskCategoryListNewRiskItemHasRiskCategory); - oldRiskCategoryOfRiskItemHasRiskCategoryListNewRiskItemHasRiskCategory = em.merge(oldRiskCategoryOfRiskItemHasRiskCategoryListNewRiskItemHasRiskCategory); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - Integer id = riskCategory.getId(); - if (findRiskCategory(id) == null) { - throw new NonexistentEntityException("The riskCategory with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - RiskCategory riskCategory; - try { - riskCategory = em.getReference(RiskCategory.class, id); - riskCategory.getId(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The riskCategory with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List riskItemHasRiskCategoryListOrphanCheck = riskCategory.getRiskItemHasRiskCategoryList(); - for (RiskItemHasRiskCategory riskItemHasRiskCategoryListOrphanCheckRiskItemHasRiskCategory : riskItemHasRiskCategoryListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This RiskCategory (" + riskCategory + ") cannot be destroyed since the RiskItemHasRiskCategory " + riskItemHasRiskCategoryListOrphanCheckRiskItemHasRiskCategory + " in its riskItemHasRiskCategoryList field has a non-nullable riskCategory field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - List fmeaList = riskCategory.getFmeaList(); - for (Fmea fmeaListFmea : fmeaList) { - fmeaListFmea.getRiskCategoryList().remove(riskCategory); - fmeaListFmea = em.merge(fmeaListFmea); - } - em.remove(riskCategory); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findRiskCategoryEntities() { - return findRiskCategoryEntities(true, -1, -1); - } - - public List findRiskCategoryEntities(int maxResults, int firstResult) { - return findRiskCategoryEntities(false, maxResults, firstResult); - } - - private List findRiskCategoryEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(RiskCategory.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public RiskCategory findRiskCategory(Integer id) { - EntityManager em = getEntityManager(); - try { - return em.find(RiskCategory.class, id); - } - finally { - em.close(); - } - } - - public int getRiskCategoryCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(RiskCategory.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.Fmea; +import com.validation.manager.core.db.RiskCategory; +import java.util.ArrayList; +import java.util.List; +import com.validation.manager.core.db.RiskItemHasRiskCategory; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class RiskCategoryJpaController implements Serializable { + + public RiskCategoryJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(RiskCategory riskCategory) { + if (riskCategory.getFmeaList() == null) { + riskCategory.setFmeaList(new ArrayList<>()); + } + if (riskCategory.getRiskItemHasRiskCategoryList() == null) { + riskCategory.setRiskItemHasRiskCategoryList(new ArrayList<>()); + } + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + List attachedFmeaList = new ArrayList<>(); + for (Fmea fmeaListFmeaToAttach : riskCategory.getFmeaList()) { + fmeaListFmeaToAttach = em.getReference(fmeaListFmeaToAttach.getClass(), fmeaListFmeaToAttach.getId()); + attachedFmeaList.add(fmeaListFmeaToAttach); + } + riskCategory.setFmeaList(attachedFmeaList); + List attachedRiskItemHasRiskCategoryList = new ArrayList<>(); + for (RiskItemHasRiskCategory riskItemHasRiskCategoryListRiskItemHasRiskCategoryToAttach : riskCategory.getRiskItemHasRiskCategoryList()) { + riskItemHasRiskCategoryListRiskItemHasRiskCategoryToAttach = em.getReference(riskItemHasRiskCategoryListRiskItemHasRiskCategoryToAttach.getClass(), riskItemHasRiskCategoryListRiskItemHasRiskCategoryToAttach.getRiskItemHasRiskCategoryPK()); + attachedRiskItemHasRiskCategoryList.add(riskItemHasRiskCategoryListRiskItemHasRiskCategoryToAttach); + } + riskCategory.setRiskItemHasRiskCategoryList(attachedRiskItemHasRiskCategoryList); + em.persist(riskCategory); + for (Fmea fmeaListFmea : riskCategory.getFmeaList()) { + fmeaListFmea.getRiskCategoryList().add(riskCategory); + fmeaListFmea = em.merge(fmeaListFmea); + } + for (RiskItemHasRiskCategory riskItemHasRiskCategoryListRiskItemHasRiskCategory : riskCategory.getRiskItemHasRiskCategoryList()) { + RiskCategory oldRiskCategoryOfRiskItemHasRiskCategoryListRiskItemHasRiskCategory = riskItemHasRiskCategoryListRiskItemHasRiskCategory.getRiskCategory(); + riskItemHasRiskCategoryListRiskItemHasRiskCategory.setRiskCategory(riskCategory); + riskItemHasRiskCategoryListRiskItemHasRiskCategory = em.merge(riskItemHasRiskCategoryListRiskItemHasRiskCategory); + if (oldRiskCategoryOfRiskItemHasRiskCategoryListRiskItemHasRiskCategory != null) { + oldRiskCategoryOfRiskItemHasRiskCategoryListRiskItemHasRiskCategory.getRiskItemHasRiskCategoryList().remove(riskItemHasRiskCategoryListRiskItemHasRiskCategory); + oldRiskCategoryOfRiskItemHasRiskCategoryListRiskItemHasRiskCategory = em.merge(oldRiskCategoryOfRiskItemHasRiskCategoryListRiskItemHasRiskCategory); + } + } + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(RiskCategory riskCategory) throws IllegalOrphanException, NonexistentEntityException, Exception { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + RiskCategory persistentRiskCategory = em.find(RiskCategory.class, riskCategory.getId()); + List fmeaListOld = persistentRiskCategory.getFmeaList(); + List fmeaListNew = riskCategory.getFmeaList(); + List riskItemHasRiskCategoryListOld = persistentRiskCategory.getRiskItemHasRiskCategoryList(); + List riskItemHasRiskCategoryListNew = riskCategory.getRiskItemHasRiskCategoryList(); + List illegalOrphanMessages = null; + for (RiskItemHasRiskCategory riskItemHasRiskCategoryListOldRiskItemHasRiskCategory : riskItemHasRiskCategoryListOld) { + if (!riskItemHasRiskCategoryListNew.contains(riskItemHasRiskCategoryListOldRiskItemHasRiskCategory)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain RiskItemHasRiskCategory " + riskItemHasRiskCategoryListOldRiskItemHasRiskCategory + " since its riskCategory field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + List attachedFmeaListNew = new ArrayList<>(); + for (Fmea fmeaListNewFmeaToAttach : fmeaListNew) { + fmeaListNewFmeaToAttach = em.getReference(fmeaListNewFmeaToAttach.getClass(), fmeaListNewFmeaToAttach.getId()); + attachedFmeaListNew.add(fmeaListNewFmeaToAttach); + } + fmeaListNew = attachedFmeaListNew; + riskCategory.setFmeaList(fmeaListNew); + List attachedRiskItemHasRiskCategoryListNew = new ArrayList<>(); + for (RiskItemHasRiskCategory riskItemHasRiskCategoryListNewRiskItemHasRiskCategoryToAttach : riskItemHasRiskCategoryListNew) { + riskItemHasRiskCategoryListNewRiskItemHasRiskCategoryToAttach = em.getReference(riskItemHasRiskCategoryListNewRiskItemHasRiskCategoryToAttach.getClass(), riskItemHasRiskCategoryListNewRiskItemHasRiskCategoryToAttach.getRiskItemHasRiskCategoryPK()); + attachedRiskItemHasRiskCategoryListNew.add(riskItemHasRiskCategoryListNewRiskItemHasRiskCategoryToAttach); + } + riskItemHasRiskCategoryListNew = attachedRiskItemHasRiskCategoryListNew; + riskCategory.setRiskItemHasRiskCategoryList(riskItemHasRiskCategoryListNew); + riskCategory = em.merge(riskCategory); + for (Fmea fmeaListOldFmea : fmeaListOld) { + if (!fmeaListNew.contains(fmeaListOldFmea)) { + fmeaListOldFmea.getRiskCategoryList().remove(riskCategory); + fmeaListOldFmea = em.merge(fmeaListOldFmea); + } + } + for (Fmea fmeaListNewFmea : fmeaListNew) { + if (!fmeaListOld.contains(fmeaListNewFmea)) { + fmeaListNewFmea.getRiskCategoryList().add(riskCategory); + fmeaListNewFmea = em.merge(fmeaListNewFmea); + } + } + for (RiskItemHasRiskCategory riskItemHasRiskCategoryListNewRiskItemHasRiskCategory : riskItemHasRiskCategoryListNew) { + if (!riskItemHasRiskCategoryListOld.contains(riskItemHasRiskCategoryListNewRiskItemHasRiskCategory)) { + RiskCategory oldRiskCategoryOfRiskItemHasRiskCategoryListNewRiskItemHasRiskCategory = riskItemHasRiskCategoryListNewRiskItemHasRiskCategory.getRiskCategory(); + riskItemHasRiskCategoryListNewRiskItemHasRiskCategory.setRiskCategory(riskCategory); + riskItemHasRiskCategoryListNewRiskItemHasRiskCategory = em.merge(riskItemHasRiskCategoryListNewRiskItemHasRiskCategory); + if (oldRiskCategoryOfRiskItemHasRiskCategoryListNewRiskItemHasRiskCategory != null && !oldRiskCategoryOfRiskItemHasRiskCategoryListNewRiskItemHasRiskCategory.equals(riskCategory)) { + oldRiskCategoryOfRiskItemHasRiskCategoryListNewRiskItemHasRiskCategory.getRiskItemHasRiskCategoryList().remove(riskItemHasRiskCategoryListNewRiskItemHasRiskCategory); + oldRiskCategoryOfRiskItemHasRiskCategoryListNewRiskItemHasRiskCategory = em.merge(oldRiskCategoryOfRiskItemHasRiskCategoryListNewRiskItemHasRiskCategory); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + Integer id = riskCategory.getId(); + if (findRiskCategory(id) == null) { + throw new NonexistentEntityException("The riskCategory with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + RiskCategory riskCategory; + try { + riskCategory = em.getReference(RiskCategory.class, id); + riskCategory.getId(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The riskCategory with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List riskItemHasRiskCategoryListOrphanCheck = riskCategory.getRiskItemHasRiskCategoryList(); + for (RiskItemHasRiskCategory riskItemHasRiskCategoryListOrphanCheckRiskItemHasRiskCategory : riskItemHasRiskCategoryListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This RiskCategory (" + riskCategory + ") cannot be destroyed since the RiskItemHasRiskCategory " + riskItemHasRiskCategoryListOrphanCheckRiskItemHasRiskCategory + " in its riskItemHasRiskCategoryList field has a non-nullable riskCategory field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + List fmeaList = riskCategory.getFmeaList(); + for (Fmea fmeaListFmea : fmeaList) { + fmeaListFmea.getRiskCategoryList().remove(riskCategory); + fmeaListFmea = em.merge(fmeaListFmea); + } + em.remove(riskCategory); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findRiskCategoryEntities() { + return findRiskCategoryEntities(true, -1, -1); + } + + public List findRiskCategoryEntities(int maxResults, int firstResult) { + return findRiskCategoryEntities(false, maxResults, firstResult); + } + + private List findRiskCategoryEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(RiskCategory.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public RiskCategory findRiskCategory(Integer id) { + EntityManager em = getEntityManager(); + try { + return em.find(RiskCategory.class, id); + } + finally { + em.close(); + } + } + + public int getRiskCategoryCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(RiskCategory.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/RiskControlJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/RiskControlJpaController.java index 1313ca87..6b41812b 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/RiskControlJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/RiskControlJpaController.java @@ -13,384 +13,384 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import com.validation.manager.core.db.RiskControl; -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.RiskControlType; -import com.validation.manager.core.db.RiskItem; -import java.util.ArrayList; -import java.util.List; -import com.validation.manager.core.db.RiskControlHasTestCase; -import com.validation.manager.core.db.RiskControlHasRequirement; -import com.validation.manager.core.db.RiskControlPK; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import com.validation.manager.core.db.controller.exceptions.PreexistingEntityException; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class RiskControlJpaController implements Serializable { - - public RiskControlJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(RiskControl riskControl) throws PreexistingEntityException, Exception { - if (riskControl.getRiskControlPK() == null) { - riskControl.setRiskControlPK(new RiskControlPK()); - } - if (riskControl.getRiskItemList() == null) { - riskControl.setRiskItemList(new ArrayList()); - } - if (riskControl.getRiskItemList1() == null) { - riskControl.setRiskItemList1(new ArrayList()); - } - if (riskControl.getRiskControlHasTestCaseList() == null) { - riskControl.setRiskControlHasTestCaseList(new ArrayList()); - } - if (riskControl.getRiskControlHasRequirementList() == null) { - riskControl.setRiskControlHasRequirementList(new ArrayList()); - } - riskControl.getRiskControlPK().setRiskControlTypeId(riskControl.getRiskControlType().getId()); - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - RiskControlType riskControlType = riskControl.getRiskControlType(); - if (riskControlType != null) { - riskControlType = em.getReference(riskControlType.getClass(), riskControlType.getId()); - riskControl.setRiskControlType(riskControlType); - } - List attachedRiskItemList = new ArrayList(); - for (RiskItem riskItemListRiskItemToAttach : riskControl.getRiskItemList()) { - riskItemListRiskItemToAttach = em.getReference(riskItemListRiskItemToAttach.getClass(), riskItemListRiskItemToAttach.getRiskItemPK()); - attachedRiskItemList.add(riskItemListRiskItemToAttach); - } - riskControl.setRiskItemList(attachedRiskItemList); - List attachedRiskItemList1 = new ArrayList(); - for (RiskItem riskItemList1RiskItemToAttach : riskControl.getRiskItemList1()) { - riskItemList1RiskItemToAttach = em.getReference(riskItemList1RiskItemToAttach.getClass(), riskItemList1RiskItemToAttach.getRiskItemPK()); - attachedRiskItemList1.add(riskItemList1RiskItemToAttach); - } - riskControl.setRiskItemList1(attachedRiskItemList1); - List attachedRiskControlHasTestCaseList = new ArrayList(); - for (RiskControlHasTestCase riskControlHasTestCaseListRiskControlHasTestCaseToAttach : riskControl.getRiskControlHasTestCaseList()) { - riskControlHasTestCaseListRiskControlHasTestCaseToAttach = em.getReference(riskControlHasTestCaseListRiskControlHasTestCaseToAttach.getClass(), riskControlHasTestCaseListRiskControlHasTestCaseToAttach.getRiskControlHasTestCasePK()); - attachedRiskControlHasTestCaseList.add(riskControlHasTestCaseListRiskControlHasTestCaseToAttach); - } - riskControl.setRiskControlHasTestCaseList(attachedRiskControlHasTestCaseList); - List attachedRiskControlHasRequirementList = new ArrayList(); - for (RiskControlHasRequirement riskControlHasRequirementListRiskControlHasRequirementToAttach : riskControl.getRiskControlHasRequirementList()) { - riskControlHasRequirementListRiskControlHasRequirementToAttach = em.getReference(riskControlHasRequirementListRiskControlHasRequirementToAttach.getClass(), riskControlHasRequirementListRiskControlHasRequirementToAttach.getRiskControlHasRequirementPK()); - attachedRiskControlHasRequirementList.add(riskControlHasRequirementListRiskControlHasRequirementToAttach); - } - riskControl.setRiskControlHasRequirementList(attachedRiskControlHasRequirementList); - em.persist(riskControl); - if (riskControlType != null) { - riskControlType.getRiskControlList().add(riskControl); - riskControlType = em.merge(riskControlType); - } - for (RiskItem riskItemListRiskItem : riskControl.getRiskItemList()) { - riskItemListRiskItem.getRiskControlList().add(riskControl); - riskItemListRiskItem = em.merge(riskItemListRiskItem); - } - for (RiskItem riskItemList1RiskItem : riskControl.getRiskItemList1()) { - riskItemList1RiskItem.getRiskControlList().add(riskControl); - riskItemList1RiskItem = em.merge(riskItemList1RiskItem); - } - for (RiskControlHasTestCase riskControlHasTestCaseListRiskControlHasTestCase : riskControl.getRiskControlHasTestCaseList()) { - RiskControl oldRiskControlOfRiskControlHasTestCaseListRiskControlHasTestCase = riskControlHasTestCaseListRiskControlHasTestCase.getRiskControl(); - riskControlHasTestCaseListRiskControlHasTestCase.setRiskControl(riskControl); - riskControlHasTestCaseListRiskControlHasTestCase = em.merge(riskControlHasTestCaseListRiskControlHasTestCase); - if (oldRiskControlOfRiskControlHasTestCaseListRiskControlHasTestCase != null) { - oldRiskControlOfRiskControlHasTestCaseListRiskControlHasTestCase.getRiskControlHasTestCaseList().remove(riskControlHasTestCaseListRiskControlHasTestCase); - oldRiskControlOfRiskControlHasTestCaseListRiskControlHasTestCase = em.merge(oldRiskControlOfRiskControlHasTestCaseListRiskControlHasTestCase); - } - } - for (RiskControlHasRequirement riskControlHasRequirementListRiskControlHasRequirement : riskControl.getRiskControlHasRequirementList()) { - RiskControl oldRiskControlOfRiskControlHasRequirementListRiskControlHasRequirement = riskControlHasRequirementListRiskControlHasRequirement.getRiskControl(); - riskControlHasRequirementListRiskControlHasRequirement.setRiskControl(riskControl); - riskControlHasRequirementListRiskControlHasRequirement = em.merge(riskControlHasRequirementListRiskControlHasRequirement); - if (oldRiskControlOfRiskControlHasRequirementListRiskControlHasRequirement != null) { - oldRiskControlOfRiskControlHasRequirementListRiskControlHasRequirement.getRiskControlHasRequirementList().remove(riskControlHasRequirementListRiskControlHasRequirement); - oldRiskControlOfRiskControlHasRequirementListRiskControlHasRequirement = em.merge(oldRiskControlOfRiskControlHasRequirementListRiskControlHasRequirement); - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - if (findRiskControl(riskControl.getRiskControlPK()) != null) { - throw new PreexistingEntityException("RiskControl " + riskControl + " already exists.", ex); - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(RiskControl riskControl) throws IllegalOrphanException, NonexistentEntityException, Exception { - riskControl.getRiskControlPK().setRiskControlTypeId(riskControl.getRiskControlType().getId()); - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - RiskControl persistentRiskControl = em.find(RiskControl.class, riskControl.getRiskControlPK()); - RiskControlType riskControlTypeOld = persistentRiskControl.getRiskControlType(); - RiskControlType riskControlTypeNew = riskControl.getRiskControlType(); - List riskItemListOld = persistentRiskControl.getRiskItemList(); - List riskItemListNew = riskControl.getRiskItemList(); - List riskItemList1Old = persistentRiskControl.getRiskItemList1(); - List riskItemList1New = riskControl.getRiskItemList1(); - List riskControlHasTestCaseListOld = persistentRiskControl.getRiskControlHasTestCaseList(); - List riskControlHasTestCaseListNew = riskControl.getRiskControlHasTestCaseList(); - List riskControlHasRequirementListOld = persistentRiskControl.getRiskControlHasRequirementList(); - List riskControlHasRequirementListNew = riskControl.getRiskControlHasRequirementList(); - List illegalOrphanMessages = null; - for (RiskControlHasTestCase riskControlHasTestCaseListOldRiskControlHasTestCase : riskControlHasTestCaseListOld) { - if (!riskControlHasTestCaseListNew.contains(riskControlHasTestCaseListOldRiskControlHasTestCase)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain RiskControlHasTestCase " + riskControlHasTestCaseListOldRiskControlHasTestCase + " since its riskControl field is not nullable."); - } - } - for (RiskControlHasRequirement riskControlHasRequirementListOldRiskControlHasRequirement : riskControlHasRequirementListOld) { - if (!riskControlHasRequirementListNew.contains(riskControlHasRequirementListOldRiskControlHasRequirement)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain RiskControlHasRequirement " + riskControlHasRequirementListOldRiskControlHasRequirement + " since its riskControl field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - if (riskControlTypeNew != null) { - riskControlTypeNew = em.getReference(riskControlTypeNew.getClass(), riskControlTypeNew.getId()); - riskControl.setRiskControlType(riskControlTypeNew); - } - List attachedRiskItemListNew = new ArrayList(); - for (RiskItem riskItemListNewRiskItemToAttach : riskItemListNew) { - riskItemListNewRiskItemToAttach = em.getReference(riskItemListNewRiskItemToAttach.getClass(), riskItemListNewRiskItemToAttach.getRiskItemPK()); - attachedRiskItemListNew.add(riskItemListNewRiskItemToAttach); - } - riskItemListNew = attachedRiskItemListNew; - riskControl.setRiskItemList(riskItemListNew); - List attachedRiskItemList1New = new ArrayList(); - for (RiskItem riskItemList1NewRiskItemToAttach : riskItemList1New) { - riskItemList1NewRiskItemToAttach = em.getReference(riskItemList1NewRiskItemToAttach.getClass(), riskItemList1NewRiskItemToAttach.getRiskItemPK()); - attachedRiskItemList1New.add(riskItemList1NewRiskItemToAttach); - } - riskItemList1New = attachedRiskItemList1New; - riskControl.setRiskItemList1(riskItemList1New); - List attachedRiskControlHasTestCaseListNew = new ArrayList(); - for (RiskControlHasTestCase riskControlHasTestCaseListNewRiskControlHasTestCaseToAttach : riskControlHasTestCaseListNew) { - riskControlHasTestCaseListNewRiskControlHasTestCaseToAttach = em.getReference(riskControlHasTestCaseListNewRiskControlHasTestCaseToAttach.getClass(), riskControlHasTestCaseListNewRiskControlHasTestCaseToAttach.getRiskControlHasTestCasePK()); - attachedRiskControlHasTestCaseListNew.add(riskControlHasTestCaseListNewRiskControlHasTestCaseToAttach); - } - riskControlHasTestCaseListNew = attachedRiskControlHasTestCaseListNew; - riskControl.setRiskControlHasTestCaseList(riskControlHasTestCaseListNew); - List attachedRiskControlHasRequirementListNew = new ArrayList(); - for (RiskControlHasRequirement riskControlHasRequirementListNewRiskControlHasRequirementToAttach : riskControlHasRequirementListNew) { - riskControlHasRequirementListNewRiskControlHasRequirementToAttach = em.getReference(riskControlHasRequirementListNewRiskControlHasRequirementToAttach.getClass(), riskControlHasRequirementListNewRiskControlHasRequirementToAttach.getRiskControlHasRequirementPK()); - attachedRiskControlHasRequirementListNew.add(riskControlHasRequirementListNewRiskControlHasRequirementToAttach); - } - riskControlHasRequirementListNew = attachedRiskControlHasRequirementListNew; - riskControl.setRiskControlHasRequirementList(riskControlHasRequirementListNew); - riskControl = em.merge(riskControl); - if (riskControlTypeOld != null && !riskControlTypeOld.equals(riskControlTypeNew)) { - riskControlTypeOld.getRiskControlList().remove(riskControl); - riskControlTypeOld = em.merge(riskControlTypeOld); - } - if (riskControlTypeNew != null && !riskControlTypeNew.equals(riskControlTypeOld)) { - riskControlTypeNew.getRiskControlList().add(riskControl); - riskControlTypeNew = em.merge(riskControlTypeNew); - } - for (RiskItem riskItemListOldRiskItem : riskItemListOld) { - if (!riskItemListNew.contains(riskItemListOldRiskItem)) { - riskItemListOldRiskItem.getRiskControlList().remove(riskControl); - riskItemListOldRiskItem = em.merge(riskItemListOldRiskItem); - } - } - for (RiskItem riskItemListNewRiskItem : riskItemListNew) { - if (!riskItemListOld.contains(riskItemListNewRiskItem)) { - riskItemListNewRiskItem.getRiskControlList().add(riskControl); - riskItemListNewRiskItem = em.merge(riskItemListNewRiskItem); - } - } - for (RiskItem riskItemList1OldRiskItem : riskItemList1Old) { - if (!riskItemList1New.contains(riskItemList1OldRiskItem)) { - riskItemList1OldRiskItem.getRiskControlList().remove(riskControl); - riskItemList1OldRiskItem = em.merge(riskItemList1OldRiskItem); - } - } - for (RiskItem riskItemList1NewRiskItem : riskItemList1New) { - if (!riskItemList1Old.contains(riskItemList1NewRiskItem)) { - riskItemList1NewRiskItem.getRiskControlList().add(riskControl); - riskItemList1NewRiskItem = em.merge(riskItemList1NewRiskItem); - } - } - for (RiskControlHasTestCase riskControlHasTestCaseListNewRiskControlHasTestCase : riskControlHasTestCaseListNew) { - if (!riskControlHasTestCaseListOld.contains(riskControlHasTestCaseListNewRiskControlHasTestCase)) { - RiskControl oldRiskControlOfRiskControlHasTestCaseListNewRiskControlHasTestCase = riskControlHasTestCaseListNewRiskControlHasTestCase.getRiskControl(); - riskControlHasTestCaseListNewRiskControlHasTestCase.setRiskControl(riskControl); - riskControlHasTestCaseListNewRiskControlHasTestCase = em.merge(riskControlHasTestCaseListNewRiskControlHasTestCase); - if (oldRiskControlOfRiskControlHasTestCaseListNewRiskControlHasTestCase != null && !oldRiskControlOfRiskControlHasTestCaseListNewRiskControlHasTestCase.equals(riskControl)) { - oldRiskControlOfRiskControlHasTestCaseListNewRiskControlHasTestCase.getRiskControlHasTestCaseList().remove(riskControlHasTestCaseListNewRiskControlHasTestCase); - oldRiskControlOfRiskControlHasTestCaseListNewRiskControlHasTestCase = em.merge(oldRiskControlOfRiskControlHasTestCaseListNewRiskControlHasTestCase); - } - } - } - for (RiskControlHasRequirement riskControlHasRequirementListNewRiskControlHasRequirement : riskControlHasRequirementListNew) { - if (!riskControlHasRequirementListOld.contains(riskControlHasRequirementListNewRiskControlHasRequirement)) { - RiskControl oldRiskControlOfRiskControlHasRequirementListNewRiskControlHasRequirement = riskControlHasRequirementListNewRiskControlHasRequirement.getRiskControl(); - riskControlHasRequirementListNewRiskControlHasRequirement.setRiskControl(riskControl); - riskControlHasRequirementListNewRiskControlHasRequirement = em.merge(riskControlHasRequirementListNewRiskControlHasRequirement); - if (oldRiskControlOfRiskControlHasRequirementListNewRiskControlHasRequirement != null && !oldRiskControlOfRiskControlHasRequirementListNewRiskControlHasRequirement.equals(riskControl)) { - oldRiskControlOfRiskControlHasRequirementListNewRiskControlHasRequirement.getRiskControlHasRequirementList().remove(riskControlHasRequirementListNewRiskControlHasRequirement); - oldRiskControlOfRiskControlHasRequirementListNewRiskControlHasRequirement = em.merge(oldRiskControlOfRiskControlHasRequirementListNewRiskControlHasRequirement); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - RiskControlPK id = riskControl.getRiskControlPK(); - if (findRiskControl(id) == null) { - throw new NonexistentEntityException("The riskControl with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(RiskControlPK id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - RiskControl riskControl; - try { - riskControl = em.getReference(RiskControl.class, id); - riskControl.getRiskControlPK(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The riskControl with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List riskControlHasTestCaseListOrphanCheck = riskControl.getRiskControlHasTestCaseList(); - for (RiskControlHasTestCase riskControlHasTestCaseListOrphanCheckRiskControlHasTestCase : riskControlHasTestCaseListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This RiskControl (" + riskControl + ") cannot be destroyed since the RiskControlHasTestCase " + riskControlHasTestCaseListOrphanCheckRiskControlHasTestCase + " in its riskControlHasTestCaseList field has a non-nullable riskControl field."); - } - List riskControlHasRequirementListOrphanCheck = riskControl.getRiskControlHasRequirementList(); - for (RiskControlHasRequirement riskControlHasRequirementListOrphanCheckRiskControlHasRequirement : riskControlHasRequirementListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This RiskControl (" + riskControl + ") cannot be destroyed since the RiskControlHasRequirement " + riskControlHasRequirementListOrphanCheckRiskControlHasRequirement + " in its riskControlHasRequirementList field has a non-nullable riskControl field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - RiskControlType riskControlType = riskControl.getRiskControlType(); - if (riskControlType != null) { - riskControlType.getRiskControlList().remove(riskControl); - riskControlType = em.merge(riskControlType); - } - List riskItemList = riskControl.getRiskItemList(); - for (RiskItem riskItemListRiskItem : riskItemList) { - riskItemListRiskItem.getRiskControlList().remove(riskControl); - riskItemListRiskItem = em.merge(riskItemListRiskItem); - } - List riskItemList1 = riskControl.getRiskItemList1(); - for (RiskItem riskItemList1RiskItem : riskItemList1) { - riskItemList1RiskItem.getRiskControlList().remove(riskControl); - riskItemList1RiskItem = em.merge(riskItemList1RiskItem); - } - em.remove(riskControl); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findRiskControlEntities() { - return findRiskControlEntities(true, -1, -1); - } - - public List findRiskControlEntities(int maxResults, int firstResult) { - return findRiskControlEntities(false, maxResults, firstResult); - } - - private List findRiskControlEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(RiskControl.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public RiskControl findRiskControl(RiskControlPK id) { - EntityManager em = getEntityManager(); - try { - return em.find(RiskControl.class, id); - } - finally { - em.close(); - } - } - - public int getRiskControlCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(RiskControl.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import com.validation.manager.core.db.RiskControl; +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.RiskControlType; +import com.validation.manager.core.db.RiskItem; +import java.util.ArrayList; +import java.util.List; +import com.validation.manager.core.db.RiskControlHasTestCase; +import com.validation.manager.core.db.RiskControlHasRequirement; +import com.validation.manager.core.db.RiskControlPK; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import com.validation.manager.core.db.controller.exceptions.PreexistingEntityException; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class RiskControlJpaController implements Serializable { + + public RiskControlJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(RiskControl riskControl) throws PreexistingEntityException, Exception { + if (riskControl.getRiskControlPK() == null) { + riskControl.setRiskControlPK(new RiskControlPK()); + } + if (riskControl.getRiskItemList() == null) { + riskControl.setRiskItemList(new ArrayList<>()); + } + if (riskControl.getRiskItemList1() == null) { + riskControl.setRiskItemList1(new ArrayList<>()); + } + if (riskControl.getRiskControlHasTestCaseList() == null) { + riskControl.setRiskControlHasTestCaseList(new ArrayList<>()); + } + if (riskControl.getRiskControlHasRequirementList() == null) { + riskControl.setRiskControlHasRequirementList(new ArrayList<>()); + } + riskControl.getRiskControlPK().setRiskControlTypeId(riskControl.getRiskControlType().getId()); + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + RiskControlType riskControlType = riskControl.getRiskControlType(); + if (riskControlType != null) { + riskControlType = em.getReference(riskControlType.getClass(), riskControlType.getId()); + riskControl.setRiskControlType(riskControlType); + } + List attachedRiskItemList = new ArrayList<>(); + for (RiskItem riskItemListRiskItemToAttach : riskControl.getRiskItemList()) { + riskItemListRiskItemToAttach = em.getReference(riskItemListRiskItemToAttach.getClass(), riskItemListRiskItemToAttach.getRiskItemPK()); + attachedRiskItemList.add(riskItemListRiskItemToAttach); + } + riskControl.setRiskItemList(attachedRiskItemList); + List attachedRiskItemList1 = new ArrayList<>(); + for (RiskItem riskItemList1RiskItemToAttach : riskControl.getRiskItemList1()) { + riskItemList1RiskItemToAttach = em.getReference(riskItemList1RiskItemToAttach.getClass(), riskItemList1RiskItemToAttach.getRiskItemPK()); + attachedRiskItemList1.add(riskItemList1RiskItemToAttach); + } + riskControl.setRiskItemList1(attachedRiskItemList1); + List attachedRiskControlHasTestCaseList = new ArrayList<>(); + for (RiskControlHasTestCase riskControlHasTestCaseListRiskControlHasTestCaseToAttach : riskControl.getRiskControlHasTestCaseList()) { + riskControlHasTestCaseListRiskControlHasTestCaseToAttach = em.getReference(riskControlHasTestCaseListRiskControlHasTestCaseToAttach.getClass(), riskControlHasTestCaseListRiskControlHasTestCaseToAttach.getRiskControlHasTestCasePK()); + attachedRiskControlHasTestCaseList.add(riskControlHasTestCaseListRiskControlHasTestCaseToAttach); + } + riskControl.setRiskControlHasTestCaseList(attachedRiskControlHasTestCaseList); + List attachedRiskControlHasRequirementList = new ArrayList<>(); + for (RiskControlHasRequirement riskControlHasRequirementListRiskControlHasRequirementToAttach : riskControl.getRiskControlHasRequirementList()) { + riskControlHasRequirementListRiskControlHasRequirementToAttach = em.getReference(riskControlHasRequirementListRiskControlHasRequirementToAttach.getClass(), riskControlHasRequirementListRiskControlHasRequirementToAttach.getRiskControlHasRequirementPK()); + attachedRiskControlHasRequirementList.add(riskControlHasRequirementListRiskControlHasRequirementToAttach); + } + riskControl.setRiskControlHasRequirementList(attachedRiskControlHasRequirementList); + em.persist(riskControl); + if (riskControlType != null) { + riskControlType.getRiskControlList().add(riskControl); + riskControlType = em.merge(riskControlType); + } + for (RiskItem riskItemListRiskItem : riskControl.getRiskItemList()) { + riskItemListRiskItem.getRiskControlList().add(riskControl); + riskItemListRiskItem = em.merge(riskItemListRiskItem); + } + for (RiskItem riskItemList1RiskItem : riskControl.getRiskItemList1()) { + riskItemList1RiskItem.getRiskControlList().add(riskControl); + riskItemList1RiskItem = em.merge(riskItemList1RiskItem); + } + for (RiskControlHasTestCase riskControlHasTestCaseListRiskControlHasTestCase : riskControl.getRiskControlHasTestCaseList()) { + RiskControl oldRiskControlOfRiskControlHasTestCaseListRiskControlHasTestCase = riskControlHasTestCaseListRiskControlHasTestCase.getRiskControl(); + riskControlHasTestCaseListRiskControlHasTestCase.setRiskControl(riskControl); + riskControlHasTestCaseListRiskControlHasTestCase = em.merge(riskControlHasTestCaseListRiskControlHasTestCase); + if (oldRiskControlOfRiskControlHasTestCaseListRiskControlHasTestCase != null) { + oldRiskControlOfRiskControlHasTestCaseListRiskControlHasTestCase.getRiskControlHasTestCaseList().remove(riskControlHasTestCaseListRiskControlHasTestCase); + oldRiskControlOfRiskControlHasTestCaseListRiskControlHasTestCase = em.merge(oldRiskControlOfRiskControlHasTestCaseListRiskControlHasTestCase); + } + } + for (RiskControlHasRequirement riskControlHasRequirementListRiskControlHasRequirement : riskControl.getRiskControlHasRequirementList()) { + RiskControl oldRiskControlOfRiskControlHasRequirementListRiskControlHasRequirement = riskControlHasRequirementListRiskControlHasRequirement.getRiskControl(); + riskControlHasRequirementListRiskControlHasRequirement.setRiskControl(riskControl); + riskControlHasRequirementListRiskControlHasRequirement = em.merge(riskControlHasRequirementListRiskControlHasRequirement); + if (oldRiskControlOfRiskControlHasRequirementListRiskControlHasRequirement != null) { + oldRiskControlOfRiskControlHasRequirementListRiskControlHasRequirement.getRiskControlHasRequirementList().remove(riskControlHasRequirementListRiskControlHasRequirement); + oldRiskControlOfRiskControlHasRequirementListRiskControlHasRequirement = em.merge(oldRiskControlOfRiskControlHasRequirementListRiskControlHasRequirement); + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + if (findRiskControl(riskControl.getRiskControlPK()) != null) { + throw new PreexistingEntityException("RiskControl " + riskControl + " already exists.", ex); + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(RiskControl riskControl) throws IllegalOrphanException, NonexistentEntityException, Exception { + riskControl.getRiskControlPK().setRiskControlTypeId(riskControl.getRiskControlType().getId()); + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + RiskControl persistentRiskControl = em.find(RiskControl.class, riskControl.getRiskControlPK()); + RiskControlType riskControlTypeOld = persistentRiskControl.getRiskControlType(); + RiskControlType riskControlTypeNew = riskControl.getRiskControlType(); + List riskItemListOld = persistentRiskControl.getRiskItemList(); + List riskItemListNew = riskControl.getRiskItemList(); + List riskItemList1Old = persistentRiskControl.getRiskItemList1(); + List riskItemList1New = riskControl.getRiskItemList1(); + List riskControlHasTestCaseListOld = persistentRiskControl.getRiskControlHasTestCaseList(); + List riskControlHasTestCaseListNew = riskControl.getRiskControlHasTestCaseList(); + List riskControlHasRequirementListOld = persistentRiskControl.getRiskControlHasRequirementList(); + List riskControlHasRequirementListNew = riskControl.getRiskControlHasRequirementList(); + List illegalOrphanMessages = null; + for (RiskControlHasTestCase riskControlHasTestCaseListOldRiskControlHasTestCase : riskControlHasTestCaseListOld) { + if (!riskControlHasTestCaseListNew.contains(riskControlHasTestCaseListOldRiskControlHasTestCase)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain RiskControlHasTestCase " + riskControlHasTestCaseListOldRiskControlHasTestCase + " since its riskControl field is not nullable."); + } + } + for (RiskControlHasRequirement riskControlHasRequirementListOldRiskControlHasRequirement : riskControlHasRequirementListOld) { + if (!riskControlHasRequirementListNew.contains(riskControlHasRequirementListOldRiskControlHasRequirement)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain RiskControlHasRequirement " + riskControlHasRequirementListOldRiskControlHasRequirement + " since its riskControl field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + if (riskControlTypeNew != null) { + riskControlTypeNew = em.getReference(riskControlTypeNew.getClass(), riskControlTypeNew.getId()); + riskControl.setRiskControlType(riskControlTypeNew); + } + List attachedRiskItemListNew = new ArrayList<>(); + for (RiskItem riskItemListNewRiskItemToAttach : riskItemListNew) { + riskItemListNewRiskItemToAttach = em.getReference(riskItemListNewRiskItemToAttach.getClass(), riskItemListNewRiskItemToAttach.getRiskItemPK()); + attachedRiskItemListNew.add(riskItemListNewRiskItemToAttach); + } + riskItemListNew = attachedRiskItemListNew; + riskControl.setRiskItemList(riskItemListNew); + List attachedRiskItemList1New = new ArrayList<>(); + for (RiskItem riskItemList1NewRiskItemToAttach : riskItemList1New) { + riskItemList1NewRiskItemToAttach = em.getReference(riskItemList1NewRiskItemToAttach.getClass(), riskItemList1NewRiskItemToAttach.getRiskItemPK()); + attachedRiskItemList1New.add(riskItemList1NewRiskItemToAttach); + } + riskItemList1New = attachedRiskItemList1New; + riskControl.setRiskItemList1(riskItemList1New); + List attachedRiskControlHasTestCaseListNew = new ArrayList<>(); + for (RiskControlHasTestCase riskControlHasTestCaseListNewRiskControlHasTestCaseToAttach : riskControlHasTestCaseListNew) { + riskControlHasTestCaseListNewRiskControlHasTestCaseToAttach = em.getReference(riskControlHasTestCaseListNewRiskControlHasTestCaseToAttach.getClass(), riskControlHasTestCaseListNewRiskControlHasTestCaseToAttach.getRiskControlHasTestCasePK()); + attachedRiskControlHasTestCaseListNew.add(riskControlHasTestCaseListNewRiskControlHasTestCaseToAttach); + } + riskControlHasTestCaseListNew = attachedRiskControlHasTestCaseListNew; + riskControl.setRiskControlHasTestCaseList(riskControlHasTestCaseListNew); + List attachedRiskControlHasRequirementListNew = new ArrayList<>(); + for (RiskControlHasRequirement riskControlHasRequirementListNewRiskControlHasRequirementToAttach : riskControlHasRequirementListNew) { + riskControlHasRequirementListNewRiskControlHasRequirementToAttach = em.getReference(riskControlHasRequirementListNewRiskControlHasRequirementToAttach.getClass(), riskControlHasRequirementListNewRiskControlHasRequirementToAttach.getRiskControlHasRequirementPK()); + attachedRiskControlHasRequirementListNew.add(riskControlHasRequirementListNewRiskControlHasRequirementToAttach); + } + riskControlHasRequirementListNew = attachedRiskControlHasRequirementListNew; + riskControl.setRiskControlHasRequirementList(riskControlHasRequirementListNew); + riskControl = em.merge(riskControl); + if (riskControlTypeOld != null && !riskControlTypeOld.equals(riskControlTypeNew)) { + riskControlTypeOld.getRiskControlList().remove(riskControl); + riskControlTypeOld = em.merge(riskControlTypeOld); + } + if (riskControlTypeNew != null && !riskControlTypeNew.equals(riskControlTypeOld)) { + riskControlTypeNew.getRiskControlList().add(riskControl); + riskControlTypeNew = em.merge(riskControlTypeNew); + } + for (RiskItem riskItemListOldRiskItem : riskItemListOld) { + if (!riskItemListNew.contains(riskItemListOldRiskItem)) { + riskItemListOldRiskItem.getRiskControlList().remove(riskControl); + riskItemListOldRiskItem = em.merge(riskItemListOldRiskItem); + } + } + for (RiskItem riskItemListNewRiskItem : riskItemListNew) { + if (!riskItemListOld.contains(riskItemListNewRiskItem)) { + riskItemListNewRiskItem.getRiskControlList().add(riskControl); + riskItemListNewRiskItem = em.merge(riskItemListNewRiskItem); + } + } + for (RiskItem riskItemList1OldRiskItem : riskItemList1Old) { + if (!riskItemList1New.contains(riskItemList1OldRiskItem)) { + riskItemList1OldRiskItem.getRiskControlList().remove(riskControl); + riskItemList1OldRiskItem = em.merge(riskItemList1OldRiskItem); + } + } + for (RiskItem riskItemList1NewRiskItem : riskItemList1New) { + if (!riskItemList1Old.contains(riskItemList1NewRiskItem)) { + riskItemList1NewRiskItem.getRiskControlList().add(riskControl); + riskItemList1NewRiskItem = em.merge(riskItemList1NewRiskItem); + } + } + for (RiskControlHasTestCase riskControlHasTestCaseListNewRiskControlHasTestCase : riskControlHasTestCaseListNew) { + if (!riskControlHasTestCaseListOld.contains(riskControlHasTestCaseListNewRiskControlHasTestCase)) { + RiskControl oldRiskControlOfRiskControlHasTestCaseListNewRiskControlHasTestCase = riskControlHasTestCaseListNewRiskControlHasTestCase.getRiskControl(); + riskControlHasTestCaseListNewRiskControlHasTestCase.setRiskControl(riskControl); + riskControlHasTestCaseListNewRiskControlHasTestCase = em.merge(riskControlHasTestCaseListNewRiskControlHasTestCase); + if (oldRiskControlOfRiskControlHasTestCaseListNewRiskControlHasTestCase != null && !oldRiskControlOfRiskControlHasTestCaseListNewRiskControlHasTestCase.equals(riskControl)) { + oldRiskControlOfRiskControlHasTestCaseListNewRiskControlHasTestCase.getRiskControlHasTestCaseList().remove(riskControlHasTestCaseListNewRiskControlHasTestCase); + oldRiskControlOfRiskControlHasTestCaseListNewRiskControlHasTestCase = em.merge(oldRiskControlOfRiskControlHasTestCaseListNewRiskControlHasTestCase); + } + } + } + for (RiskControlHasRequirement riskControlHasRequirementListNewRiskControlHasRequirement : riskControlHasRequirementListNew) { + if (!riskControlHasRequirementListOld.contains(riskControlHasRequirementListNewRiskControlHasRequirement)) { + RiskControl oldRiskControlOfRiskControlHasRequirementListNewRiskControlHasRequirement = riskControlHasRequirementListNewRiskControlHasRequirement.getRiskControl(); + riskControlHasRequirementListNewRiskControlHasRequirement.setRiskControl(riskControl); + riskControlHasRequirementListNewRiskControlHasRequirement = em.merge(riskControlHasRequirementListNewRiskControlHasRequirement); + if (oldRiskControlOfRiskControlHasRequirementListNewRiskControlHasRequirement != null && !oldRiskControlOfRiskControlHasRequirementListNewRiskControlHasRequirement.equals(riskControl)) { + oldRiskControlOfRiskControlHasRequirementListNewRiskControlHasRequirement.getRiskControlHasRequirementList().remove(riskControlHasRequirementListNewRiskControlHasRequirement); + oldRiskControlOfRiskControlHasRequirementListNewRiskControlHasRequirement = em.merge(oldRiskControlOfRiskControlHasRequirementListNewRiskControlHasRequirement); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + RiskControlPK id = riskControl.getRiskControlPK(); + if (findRiskControl(id) == null) { + throw new NonexistentEntityException("The riskControl with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(RiskControlPK id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + RiskControl riskControl; + try { + riskControl = em.getReference(RiskControl.class, id); + riskControl.getRiskControlPK(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The riskControl with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List riskControlHasTestCaseListOrphanCheck = riskControl.getRiskControlHasTestCaseList(); + for (RiskControlHasTestCase riskControlHasTestCaseListOrphanCheckRiskControlHasTestCase : riskControlHasTestCaseListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This RiskControl (" + riskControl + ") cannot be destroyed since the RiskControlHasTestCase " + riskControlHasTestCaseListOrphanCheckRiskControlHasTestCase + " in its riskControlHasTestCaseList field has a non-nullable riskControl field."); + } + List riskControlHasRequirementListOrphanCheck = riskControl.getRiskControlHasRequirementList(); + for (RiskControlHasRequirement riskControlHasRequirementListOrphanCheckRiskControlHasRequirement : riskControlHasRequirementListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This RiskControl (" + riskControl + ") cannot be destroyed since the RiskControlHasRequirement " + riskControlHasRequirementListOrphanCheckRiskControlHasRequirement + " in its riskControlHasRequirementList field has a non-nullable riskControl field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + RiskControlType riskControlType = riskControl.getRiskControlType(); + if (riskControlType != null) { + riskControlType.getRiskControlList().remove(riskControl); + riskControlType = em.merge(riskControlType); + } + List riskItemList = riskControl.getRiskItemList(); + for (RiskItem riskItemListRiskItem : riskItemList) { + riskItemListRiskItem.getRiskControlList().remove(riskControl); + riskItemListRiskItem = em.merge(riskItemListRiskItem); + } + List riskItemList1 = riskControl.getRiskItemList1(); + for (RiskItem riskItemList1RiskItem : riskItemList1) { + riskItemList1RiskItem.getRiskControlList().remove(riskControl); + riskItemList1RiskItem = em.merge(riskItemList1RiskItem); + } + em.remove(riskControl); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findRiskControlEntities() { + return findRiskControlEntities(true, -1, -1); + } + + public List findRiskControlEntities(int maxResults, int firstResult) { + return findRiskControlEntities(false, maxResults, firstResult); + } + + private List findRiskControlEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(RiskControl.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public RiskControl findRiskControl(RiskControlPK id) { + EntityManager em = getEntityManager(); + try { + return em.find(RiskControl.class, id); + } + finally { + em.close(); + } + } + + public int getRiskControlCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(RiskControl.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/RiskControlTypeJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/RiskControlTypeJpaController.java index 859776db..a0b0f18e 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/RiskControlTypeJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/RiskControlTypeJpaController.java @@ -13,209 +13,209 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.RiskControl; -import com.validation.manager.core.db.RiskControlType; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import java.util.ArrayList; -import java.util.List; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class RiskControlTypeJpaController implements Serializable { - - public RiskControlTypeJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(RiskControlType riskControlType) { - if (riskControlType.getRiskControlList() == null) { - riskControlType.setRiskControlList(new ArrayList()); - } - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - List attachedRiskControlList = new ArrayList(); - for (RiskControl riskControlListRiskControlToAttach : riskControlType.getRiskControlList()) { - riskControlListRiskControlToAttach = em.getReference(riskControlListRiskControlToAttach.getClass(), riskControlListRiskControlToAttach.getRiskControlPK()); - attachedRiskControlList.add(riskControlListRiskControlToAttach); - } - riskControlType.setRiskControlList(attachedRiskControlList); - em.persist(riskControlType); - for (RiskControl riskControlListRiskControl : riskControlType.getRiskControlList()) { - RiskControlType oldRiskControlTypeOfRiskControlListRiskControl = riskControlListRiskControl.getRiskControlType(); - riskControlListRiskControl.setRiskControlType(riskControlType); - riskControlListRiskControl = em.merge(riskControlListRiskControl); - if (oldRiskControlTypeOfRiskControlListRiskControl != null) { - oldRiskControlTypeOfRiskControlListRiskControl.getRiskControlList().remove(riskControlListRiskControl); - oldRiskControlTypeOfRiskControlListRiskControl = em.merge(oldRiskControlTypeOfRiskControlListRiskControl); - } - } - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(RiskControlType riskControlType) throws IllegalOrphanException, NonexistentEntityException, Exception { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - RiskControlType persistentRiskControlType = em.find(RiskControlType.class, riskControlType.getId()); - List riskControlListOld = persistentRiskControlType.getRiskControlList(); - List riskControlListNew = riskControlType.getRiskControlList(); - List illegalOrphanMessages = null; - for (RiskControl riskControlListOldRiskControl : riskControlListOld) { - if (!riskControlListNew.contains(riskControlListOldRiskControl)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain RiskControl " + riskControlListOldRiskControl + " since its riskControlType field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - List attachedRiskControlListNew = new ArrayList(); - for (RiskControl riskControlListNewRiskControlToAttach : riskControlListNew) { - riskControlListNewRiskControlToAttach = em.getReference(riskControlListNewRiskControlToAttach.getClass(), riskControlListNewRiskControlToAttach.getRiskControlPK()); - attachedRiskControlListNew.add(riskControlListNewRiskControlToAttach); - } - riskControlListNew = attachedRiskControlListNew; - riskControlType.setRiskControlList(riskControlListNew); - riskControlType = em.merge(riskControlType); - for (RiskControl riskControlListNewRiskControl : riskControlListNew) { - if (!riskControlListOld.contains(riskControlListNewRiskControl)) { - RiskControlType oldRiskControlTypeOfRiskControlListNewRiskControl = riskControlListNewRiskControl.getRiskControlType(); - riskControlListNewRiskControl.setRiskControlType(riskControlType); - riskControlListNewRiskControl = em.merge(riskControlListNewRiskControl); - if (oldRiskControlTypeOfRiskControlListNewRiskControl != null && !oldRiskControlTypeOfRiskControlListNewRiskControl.equals(riskControlType)) { - oldRiskControlTypeOfRiskControlListNewRiskControl.getRiskControlList().remove(riskControlListNewRiskControl); - oldRiskControlTypeOfRiskControlListNewRiskControl = em.merge(oldRiskControlTypeOfRiskControlListNewRiskControl); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - Integer id = riskControlType.getId(); - if (findRiskControlType(id) == null) { - throw new NonexistentEntityException("The riskControlType with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - RiskControlType riskControlType; - try { - riskControlType = em.getReference(RiskControlType.class, id); - riskControlType.getId(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The riskControlType with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List riskControlListOrphanCheck = riskControlType.getRiskControlList(); - for (RiskControl riskControlListOrphanCheckRiskControl : riskControlListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This RiskControlType (" + riskControlType + ") cannot be destroyed since the RiskControl " + riskControlListOrphanCheckRiskControl + " in its riskControlList field has a non-nullable riskControlType field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - em.remove(riskControlType); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findRiskControlTypeEntities() { - return findRiskControlTypeEntities(true, -1, -1); - } - - public List findRiskControlTypeEntities(int maxResults, int firstResult) { - return findRiskControlTypeEntities(false, maxResults, firstResult); - } - - private List findRiskControlTypeEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(RiskControlType.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public RiskControlType findRiskControlType(Integer id) { - EntityManager em = getEntityManager(); - try { - return em.find(RiskControlType.class, id); - } - finally { - em.close(); - } - } - - public int getRiskControlTypeCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(RiskControlType.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.RiskControl; +import com.validation.manager.core.db.RiskControlType; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import java.util.ArrayList; +import java.util.List; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class RiskControlTypeJpaController implements Serializable { + + public RiskControlTypeJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(RiskControlType riskControlType) { + if (riskControlType.getRiskControlList() == null) { + riskControlType.setRiskControlList(new ArrayList<>()); + } + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + List attachedRiskControlList = new ArrayList<>(); + for (RiskControl riskControlListRiskControlToAttach : riskControlType.getRiskControlList()) { + riskControlListRiskControlToAttach = em.getReference(riskControlListRiskControlToAttach.getClass(), riskControlListRiskControlToAttach.getRiskControlPK()); + attachedRiskControlList.add(riskControlListRiskControlToAttach); + } + riskControlType.setRiskControlList(attachedRiskControlList); + em.persist(riskControlType); + for (RiskControl riskControlListRiskControl : riskControlType.getRiskControlList()) { + RiskControlType oldRiskControlTypeOfRiskControlListRiskControl = riskControlListRiskControl.getRiskControlType(); + riskControlListRiskControl.setRiskControlType(riskControlType); + riskControlListRiskControl = em.merge(riskControlListRiskControl); + if (oldRiskControlTypeOfRiskControlListRiskControl != null) { + oldRiskControlTypeOfRiskControlListRiskControl.getRiskControlList().remove(riskControlListRiskControl); + oldRiskControlTypeOfRiskControlListRiskControl = em.merge(oldRiskControlTypeOfRiskControlListRiskControl); + } + } + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(RiskControlType riskControlType) throws IllegalOrphanException, NonexistentEntityException, Exception { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + RiskControlType persistentRiskControlType = em.find(RiskControlType.class, riskControlType.getId()); + List riskControlListOld = persistentRiskControlType.getRiskControlList(); + List riskControlListNew = riskControlType.getRiskControlList(); + List illegalOrphanMessages = null; + for (RiskControl riskControlListOldRiskControl : riskControlListOld) { + if (!riskControlListNew.contains(riskControlListOldRiskControl)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain RiskControl " + riskControlListOldRiskControl + " since its riskControlType field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + List attachedRiskControlListNew = new ArrayList<>(); + for (RiskControl riskControlListNewRiskControlToAttach : riskControlListNew) { + riskControlListNewRiskControlToAttach = em.getReference(riskControlListNewRiskControlToAttach.getClass(), riskControlListNewRiskControlToAttach.getRiskControlPK()); + attachedRiskControlListNew.add(riskControlListNewRiskControlToAttach); + } + riskControlListNew = attachedRiskControlListNew; + riskControlType.setRiskControlList(riskControlListNew); + riskControlType = em.merge(riskControlType); + for (RiskControl riskControlListNewRiskControl : riskControlListNew) { + if (!riskControlListOld.contains(riskControlListNewRiskControl)) { + RiskControlType oldRiskControlTypeOfRiskControlListNewRiskControl = riskControlListNewRiskControl.getRiskControlType(); + riskControlListNewRiskControl.setRiskControlType(riskControlType); + riskControlListNewRiskControl = em.merge(riskControlListNewRiskControl); + if (oldRiskControlTypeOfRiskControlListNewRiskControl != null && !oldRiskControlTypeOfRiskControlListNewRiskControl.equals(riskControlType)) { + oldRiskControlTypeOfRiskControlListNewRiskControl.getRiskControlList().remove(riskControlListNewRiskControl); + oldRiskControlTypeOfRiskControlListNewRiskControl = em.merge(oldRiskControlTypeOfRiskControlListNewRiskControl); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + Integer id = riskControlType.getId(); + if (findRiskControlType(id) == null) { + throw new NonexistentEntityException("The riskControlType with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + RiskControlType riskControlType; + try { + riskControlType = em.getReference(RiskControlType.class, id); + riskControlType.getId(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The riskControlType with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List riskControlListOrphanCheck = riskControlType.getRiskControlList(); + for (RiskControl riskControlListOrphanCheckRiskControl : riskControlListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This RiskControlType (" + riskControlType + ") cannot be destroyed since the RiskControl " + riskControlListOrphanCheckRiskControl + " in its riskControlList field has a non-nullable riskControlType field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + em.remove(riskControlType); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findRiskControlTypeEntities() { + return findRiskControlTypeEntities(true, -1, -1); + } + + public List findRiskControlTypeEntities(int maxResults, int firstResult) { + return findRiskControlTypeEntities(false, maxResults, firstResult); + } + + private List findRiskControlTypeEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(RiskControlType.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public RiskControlType findRiskControlType(Integer id) { + EntityManager em = getEntityManager(); + try { + return em.find(RiskControlType.class, id); + } + finally { + em.close(); + } + } + + public int getRiskControlTypeCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(RiskControlType.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/RiskItemJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/RiskItemJpaController.java index 71e5fdc3..6e09afa5 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/RiskItemJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/RiskItemJpaController.java @@ -13,450 +13,450 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.Fmea; -import com.validation.manager.core.db.FailureMode; -import java.util.ArrayList; -import java.util.List; -import com.validation.manager.core.db.Hazard; -import com.validation.manager.core.db.RiskControl; -import com.validation.manager.core.db.Cause; -import com.validation.manager.core.db.RiskItem; -import com.validation.manager.core.db.RiskItemHasRiskCategory; -import com.validation.manager.core.db.RiskItemPK; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import com.validation.manager.core.db.controller.exceptions.PreexistingEntityException; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class RiskItemJpaController implements Serializable { - - public RiskItemJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(RiskItem riskItem) throws PreexistingEntityException, Exception { - if (riskItem.getRiskItemPK() == null) { - riskItem.setRiskItemPK(new RiskItemPK()); - } - if (riskItem.getFailureModeList() == null) { - riskItem.setFailureModeList(new ArrayList()); - } - if (riskItem.getHazardList() == null) { - riskItem.setHazardList(new ArrayList()); - } - if (riskItem.getRiskControlList() == null) { - riskItem.setRiskControlList(new ArrayList()); - } - if (riskItem.getRiskControlList1() == null) { - riskItem.setRiskControlList1(new ArrayList()); - } - if (riskItem.getCauseList() == null) { - riskItem.setCauseList(new ArrayList()); - } - if (riskItem.getRiskItemHasRiskCategoryList() == null) { - riskItem.setRiskItemHasRiskCategoryList(new ArrayList()); - } - riskItem.getRiskItemPK().setFMEAid(riskItem.getFmea().getId()); - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - Fmea fmea = riskItem.getFmea(); - if (fmea != null) { - fmea = em.getReference(fmea.getClass(), fmea.getId()); - riskItem.setFmea(fmea); - } - List attachedFailureModeList = new ArrayList(); - for (FailureMode failureModeListFailureModeToAttach : riskItem.getFailureModeList()) { - failureModeListFailureModeToAttach = em.getReference(failureModeListFailureModeToAttach.getClass(), failureModeListFailureModeToAttach.getId()); - attachedFailureModeList.add(failureModeListFailureModeToAttach); - } - riskItem.setFailureModeList(attachedFailureModeList); - List attachedHazardList = new ArrayList(); - for (Hazard hazardListHazardToAttach : riskItem.getHazardList()) { - hazardListHazardToAttach = em.getReference(hazardListHazardToAttach.getClass(), hazardListHazardToAttach.getId()); - attachedHazardList.add(hazardListHazardToAttach); - } - riskItem.setHazardList(attachedHazardList); - List attachedRiskControlList = new ArrayList(); - for (RiskControl riskControlListRiskControlToAttach : riskItem.getRiskControlList()) { - riskControlListRiskControlToAttach = em.getReference(riskControlListRiskControlToAttach.getClass(), riskControlListRiskControlToAttach.getRiskControlPK()); - attachedRiskControlList.add(riskControlListRiskControlToAttach); - } - riskItem.setRiskControlList(attachedRiskControlList); - List attachedRiskControlList1 = new ArrayList(); - for (RiskControl riskControlList1RiskControlToAttach : riskItem.getRiskControlList1()) { - riskControlList1RiskControlToAttach = em.getReference(riskControlList1RiskControlToAttach.getClass(), riskControlList1RiskControlToAttach.getRiskControlPK()); - attachedRiskControlList1.add(riskControlList1RiskControlToAttach); - } - riskItem.setRiskControlList1(attachedRiskControlList1); - List attachedCauseList = new ArrayList(); - for (Cause causeListCauseToAttach : riskItem.getCauseList()) { - causeListCauseToAttach = em.getReference(causeListCauseToAttach.getClass(), causeListCauseToAttach.getId()); - attachedCauseList.add(causeListCauseToAttach); - } - riskItem.setCauseList(attachedCauseList); - List attachedRiskItemHasRiskCategoryList = new ArrayList(); - for (RiskItemHasRiskCategory riskItemHasRiskCategoryListRiskItemHasRiskCategoryToAttach : riskItem.getRiskItemHasRiskCategoryList()) { - riskItemHasRiskCategoryListRiskItemHasRiskCategoryToAttach = em.getReference(riskItemHasRiskCategoryListRiskItemHasRiskCategoryToAttach.getClass(), riskItemHasRiskCategoryListRiskItemHasRiskCategoryToAttach.getRiskItemHasRiskCategoryPK()); - attachedRiskItemHasRiskCategoryList.add(riskItemHasRiskCategoryListRiskItemHasRiskCategoryToAttach); - } - riskItem.setRiskItemHasRiskCategoryList(attachedRiskItemHasRiskCategoryList); - em.persist(riskItem); - if (fmea != null) { - fmea.getRiskItemList().add(riskItem); - fmea = em.merge(fmea); - } - for (FailureMode failureModeListFailureMode : riskItem.getFailureModeList()) { - failureModeListFailureMode.getRiskItemList().add(riskItem); - failureModeListFailureMode = em.merge(failureModeListFailureMode); - } - for (Hazard hazardListHazard : riskItem.getHazardList()) { - hazardListHazard.getRiskItemList().add(riskItem); - hazardListHazard = em.merge(hazardListHazard); - } - for (RiskControl riskControlListRiskControl : riskItem.getRiskControlList()) { - riskControlListRiskControl.getRiskItemList().add(riskItem); - riskControlListRiskControl = em.merge(riskControlListRiskControl); - } - for (RiskControl riskControlList1RiskControl : riskItem.getRiskControlList1()) { - riskControlList1RiskControl.getRiskItemList1().add(riskItem); - riskControlList1RiskControl = em.merge(riskControlList1RiskControl); - } - for (Cause causeListCause : riskItem.getCauseList()) { - causeListCause.getRiskItemList().add(riskItem); - causeListCause = em.merge(causeListCause); - } - for (RiskItemHasRiskCategory riskItemHasRiskCategoryListRiskItemHasRiskCategory : riskItem.getRiskItemHasRiskCategoryList()) { - RiskItem oldRiskItemOfRiskItemHasRiskCategoryListRiskItemHasRiskCategory = riskItemHasRiskCategoryListRiskItemHasRiskCategory.getRiskItem(); - riskItemHasRiskCategoryListRiskItemHasRiskCategory.setRiskItem(riskItem); - riskItemHasRiskCategoryListRiskItemHasRiskCategory = em.merge(riskItemHasRiskCategoryListRiskItemHasRiskCategory); - if (oldRiskItemOfRiskItemHasRiskCategoryListRiskItemHasRiskCategory != null) { - oldRiskItemOfRiskItemHasRiskCategoryListRiskItemHasRiskCategory.getRiskItemHasRiskCategoryList().remove(riskItemHasRiskCategoryListRiskItemHasRiskCategory); - oldRiskItemOfRiskItemHasRiskCategoryListRiskItemHasRiskCategory = em.merge(oldRiskItemOfRiskItemHasRiskCategoryListRiskItemHasRiskCategory); - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - if (findRiskItem(riskItem.getRiskItemPK()) != null) { - throw new PreexistingEntityException("RiskItem " + riskItem + " already exists.", ex); - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(RiskItem riskItem) throws IllegalOrphanException, NonexistentEntityException, Exception { - riskItem.getRiskItemPK().setFMEAid(riskItem.getFmea().getId()); - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - RiskItem persistentRiskItem = em.find(RiskItem.class, riskItem.getRiskItemPK()); - Fmea fmeaOld = persistentRiskItem.getFmea(); - Fmea fmeaNew = riskItem.getFmea(); - List failureModeListOld = persistentRiskItem.getFailureModeList(); - List failureModeListNew = riskItem.getFailureModeList(); - List hazardListOld = persistentRiskItem.getHazardList(); - List hazardListNew = riskItem.getHazardList(); - List riskControlListOld = persistentRiskItem.getRiskControlList(); - List riskControlListNew = riskItem.getRiskControlList(); - List riskControlList1Old = persistentRiskItem.getRiskControlList1(); - List riskControlList1New = riskItem.getRiskControlList1(); - List causeListOld = persistentRiskItem.getCauseList(); - List causeListNew = riskItem.getCauseList(); - List riskItemHasRiskCategoryListOld = persistentRiskItem.getRiskItemHasRiskCategoryList(); - List riskItemHasRiskCategoryListNew = riskItem.getRiskItemHasRiskCategoryList(); - List illegalOrphanMessages = null; - for (RiskItemHasRiskCategory riskItemHasRiskCategoryListOldRiskItemHasRiskCategory : riskItemHasRiskCategoryListOld) { - if (!riskItemHasRiskCategoryListNew.contains(riskItemHasRiskCategoryListOldRiskItemHasRiskCategory)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain RiskItemHasRiskCategory " + riskItemHasRiskCategoryListOldRiskItemHasRiskCategory + " since its riskItem field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - if (fmeaNew != null) { - fmeaNew = em.getReference(fmeaNew.getClass(), fmeaNew.getId()); - riskItem.setFmea(fmeaNew); - } - List attachedFailureModeListNew = new ArrayList(); - for (FailureMode failureModeListNewFailureModeToAttach : failureModeListNew) { - failureModeListNewFailureModeToAttach = em.getReference(failureModeListNewFailureModeToAttach.getClass(), failureModeListNewFailureModeToAttach.getId()); - attachedFailureModeListNew.add(failureModeListNewFailureModeToAttach); - } - failureModeListNew = attachedFailureModeListNew; - riskItem.setFailureModeList(failureModeListNew); - List attachedHazardListNew = new ArrayList(); - for (Hazard hazardListNewHazardToAttach : hazardListNew) { - hazardListNewHazardToAttach = em.getReference(hazardListNewHazardToAttach.getClass(), hazardListNewHazardToAttach.getId()); - attachedHazardListNew.add(hazardListNewHazardToAttach); - } - hazardListNew = attachedHazardListNew; - riskItem.setHazardList(hazardListNew); - List attachedRiskControlListNew = new ArrayList(); - for (RiskControl riskControlListNewRiskControlToAttach : riskControlListNew) { - riskControlListNewRiskControlToAttach = em.getReference(riskControlListNewRiskControlToAttach.getClass(), riskControlListNewRiskControlToAttach.getRiskControlPK()); - attachedRiskControlListNew.add(riskControlListNewRiskControlToAttach); - } - riskControlListNew = attachedRiskControlListNew; - riskItem.setRiskControlList(riskControlListNew); - List attachedRiskControlList1New = new ArrayList(); - for (RiskControl riskControlList1NewRiskControlToAttach : riskControlList1New) { - riskControlList1NewRiskControlToAttach = em.getReference(riskControlList1NewRiskControlToAttach.getClass(), riskControlList1NewRiskControlToAttach.getRiskControlPK()); - attachedRiskControlList1New.add(riskControlList1NewRiskControlToAttach); - } - riskControlList1New = attachedRiskControlList1New; - riskItem.setRiskControlList1(riskControlList1New); - List attachedCauseListNew = new ArrayList(); - for (Cause causeListNewCauseToAttach : causeListNew) { - causeListNewCauseToAttach = em.getReference(causeListNewCauseToAttach.getClass(), causeListNewCauseToAttach.getId()); - attachedCauseListNew.add(causeListNewCauseToAttach); - } - causeListNew = attachedCauseListNew; - riskItem.setCauseList(causeListNew); - List attachedRiskItemHasRiskCategoryListNew = new ArrayList(); - for (RiskItemHasRiskCategory riskItemHasRiskCategoryListNewRiskItemHasRiskCategoryToAttach : riskItemHasRiskCategoryListNew) { - riskItemHasRiskCategoryListNewRiskItemHasRiskCategoryToAttach = em.getReference(riskItemHasRiskCategoryListNewRiskItemHasRiskCategoryToAttach.getClass(), riskItemHasRiskCategoryListNewRiskItemHasRiskCategoryToAttach.getRiskItemHasRiskCategoryPK()); - attachedRiskItemHasRiskCategoryListNew.add(riskItemHasRiskCategoryListNewRiskItemHasRiskCategoryToAttach); - } - riskItemHasRiskCategoryListNew = attachedRiskItemHasRiskCategoryListNew; - riskItem.setRiskItemHasRiskCategoryList(riskItemHasRiskCategoryListNew); - riskItem = em.merge(riskItem); - if (fmeaOld != null && !fmeaOld.equals(fmeaNew)) { - fmeaOld.getRiskItemList().remove(riskItem); - fmeaOld = em.merge(fmeaOld); - } - if (fmeaNew != null && !fmeaNew.equals(fmeaOld)) { - fmeaNew.getRiskItemList().add(riskItem); - fmeaNew = em.merge(fmeaNew); - } - for (FailureMode failureModeListOldFailureMode : failureModeListOld) { - if (!failureModeListNew.contains(failureModeListOldFailureMode)) { - failureModeListOldFailureMode.getRiskItemList().remove(riskItem); - failureModeListOldFailureMode = em.merge(failureModeListOldFailureMode); - } - } - for (FailureMode failureModeListNewFailureMode : failureModeListNew) { - if (!failureModeListOld.contains(failureModeListNewFailureMode)) { - failureModeListNewFailureMode.getRiskItemList().add(riskItem); - failureModeListNewFailureMode = em.merge(failureModeListNewFailureMode); - } - } - for (Hazard hazardListOldHazard : hazardListOld) { - if (!hazardListNew.contains(hazardListOldHazard)) { - hazardListOldHazard.getRiskItemList().remove(riskItem); - hazardListOldHazard = em.merge(hazardListOldHazard); - } - } - for (Hazard hazardListNewHazard : hazardListNew) { - if (!hazardListOld.contains(hazardListNewHazard)) { - hazardListNewHazard.getRiskItemList().add(riskItem); - hazardListNewHazard = em.merge(hazardListNewHazard); - } - } - for (RiskControl riskControlListOldRiskControl : riskControlListOld) { - if (!riskControlListNew.contains(riskControlListOldRiskControl)) { - riskControlListOldRiskControl.getRiskItemList().remove(riskItem); - riskControlListOldRiskControl = em.merge(riskControlListOldRiskControl); - } - } - for (RiskControl riskControlListNewRiskControl : riskControlListNew) { - if (!riskControlListOld.contains(riskControlListNewRiskControl)) { - riskControlListNewRiskControl.getRiskItemList().add(riskItem); - riskControlListNewRiskControl = em.merge(riskControlListNewRiskControl); - } - } - for (RiskControl riskControlList1OldRiskControl : riskControlList1Old) { - if (!riskControlList1New.contains(riskControlList1OldRiskControl)) { - riskControlList1OldRiskControl.getRiskItemList1().remove(riskItem); - riskControlList1OldRiskControl = em.merge(riskControlList1OldRiskControl); - } - } - for (RiskControl riskControlList1NewRiskControl : riskControlList1New) { - if (!riskControlList1Old.contains(riskControlList1NewRiskControl)) { - riskControlList1NewRiskControl.getRiskItemList1().add(riskItem); - riskControlList1NewRiskControl = em.merge(riskControlList1NewRiskControl); - } - } - for (Cause causeListOldCause : causeListOld) { - if (!causeListNew.contains(causeListOldCause)) { - causeListOldCause.getRiskItemList().remove(riskItem); - causeListOldCause = em.merge(causeListOldCause); - } - } - for (Cause causeListNewCause : causeListNew) { - if (!causeListOld.contains(causeListNewCause)) { - causeListNewCause.getRiskItemList().add(riskItem); - causeListNewCause = em.merge(causeListNewCause); - } - } - for (RiskItemHasRiskCategory riskItemHasRiskCategoryListNewRiskItemHasRiskCategory : riskItemHasRiskCategoryListNew) { - if (!riskItemHasRiskCategoryListOld.contains(riskItemHasRiskCategoryListNewRiskItemHasRiskCategory)) { - RiskItem oldRiskItemOfRiskItemHasRiskCategoryListNewRiskItemHasRiskCategory = riskItemHasRiskCategoryListNewRiskItemHasRiskCategory.getRiskItem(); - riskItemHasRiskCategoryListNewRiskItemHasRiskCategory.setRiskItem(riskItem); - riskItemHasRiskCategoryListNewRiskItemHasRiskCategory = em.merge(riskItemHasRiskCategoryListNewRiskItemHasRiskCategory); - if (oldRiskItemOfRiskItemHasRiskCategoryListNewRiskItemHasRiskCategory != null && !oldRiskItemOfRiskItemHasRiskCategoryListNewRiskItemHasRiskCategory.equals(riskItem)) { - oldRiskItemOfRiskItemHasRiskCategoryListNewRiskItemHasRiskCategory.getRiskItemHasRiskCategoryList().remove(riskItemHasRiskCategoryListNewRiskItemHasRiskCategory); - oldRiskItemOfRiskItemHasRiskCategoryListNewRiskItemHasRiskCategory = em.merge(oldRiskItemOfRiskItemHasRiskCategoryListNewRiskItemHasRiskCategory); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - RiskItemPK id = riskItem.getRiskItemPK(); - if (findRiskItem(id) == null) { - throw new NonexistentEntityException("The riskItem with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(RiskItemPK id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - RiskItem riskItem; - try { - riskItem = em.getReference(RiskItem.class, id); - riskItem.getRiskItemPK(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The riskItem with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List riskItemHasRiskCategoryListOrphanCheck = riskItem.getRiskItemHasRiskCategoryList(); - for (RiskItemHasRiskCategory riskItemHasRiskCategoryListOrphanCheckRiskItemHasRiskCategory : riskItemHasRiskCategoryListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This RiskItem (" + riskItem + ") cannot be destroyed since the RiskItemHasRiskCategory " + riskItemHasRiskCategoryListOrphanCheckRiskItemHasRiskCategory + " in its riskItemHasRiskCategoryList field has a non-nullable riskItem field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - Fmea fmea = riskItem.getFmea(); - if (fmea != null) { - fmea.getRiskItemList().remove(riskItem); - fmea = em.merge(fmea); - } - List failureModeList = riskItem.getFailureModeList(); - for (FailureMode failureModeListFailureMode : failureModeList) { - failureModeListFailureMode.getRiskItemList().remove(riskItem); - failureModeListFailureMode = em.merge(failureModeListFailureMode); - } - List hazardList = riskItem.getHazardList(); - for (Hazard hazardListHazard : hazardList) { - hazardListHazard.getRiskItemList().remove(riskItem); - hazardListHazard = em.merge(hazardListHazard); - } - List riskControlList = riskItem.getRiskControlList(); - for (RiskControl riskControlListRiskControl : riskControlList) { - riskControlListRiskControl.getRiskItemList().remove(riskItem); - riskControlListRiskControl = em.merge(riskControlListRiskControl); - } - List riskControlList1 = riskItem.getRiskControlList1(); - for (RiskControl riskControlList1RiskControl : riskControlList1) { - riskControlList1RiskControl.getRiskItemList1().remove(riskItem); - riskControlList1RiskControl = em.merge(riskControlList1RiskControl); - } - List causeList = riskItem.getCauseList(); - for (Cause causeListCause : causeList) { - causeListCause.getRiskItemList().remove(riskItem); - causeListCause = em.merge(causeListCause); - } - em.remove(riskItem); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findRiskItemEntities() { - return findRiskItemEntities(true, -1, -1); - } - - public List findRiskItemEntities(int maxResults, int firstResult) { - return findRiskItemEntities(false, maxResults, firstResult); - } - - private List findRiskItemEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(RiskItem.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public RiskItem findRiskItem(RiskItemPK id) { - EntityManager em = getEntityManager(); - try { - return em.find(RiskItem.class, id); - } - finally { - em.close(); - } - } - - public int getRiskItemCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(RiskItem.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.Fmea; +import com.validation.manager.core.db.FailureMode; +import java.util.ArrayList; +import java.util.List; +import com.validation.manager.core.db.Hazard; +import com.validation.manager.core.db.RiskControl; +import com.validation.manager.core.db.Cause; +import com.validation.manager.core.db.RiskItem; +import com.validation.manager.core.db.RiskItemHasRiskCategory; +import com.validation.manager.core.db.RiskItemPK; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import com.validation.manager.core.db.controller.exceptions.PreexistingEntityException; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class RiskItemJpaController implements Serializable { + + public RiskItemJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(RiskItem riskItem) throws PreexistingEntityException, Exception { + if (riskItem.getRiskItemPK() == null) { + riskItem.setRiskItemPK(new RiskItemPK()); + } + if (riskItem.getFailureModeList() == null) { + riskItem.setFailureModeList(new ArrayList<>()); + } + if (riskItem.getHazardList() == null) { + riskItem.setHazardList(new ArrayList<>()); + } + if (riskItem.getRiskControlList() == null) { + riskItem.setRiskControlList(new ArrayList<>()); + } + if (riskItem.getRiskControlList1() == null) { + riskItem.setRiskControlList1(new ArrayList<>()); + } + if (riskItem.getCauseList() == null) { + riskItem.setCauseList(new ArrayList<>()); + } + if (riskItem.getRiskItemHasRiskCategoryList() == null) { + riskItem.setRiskItemHasRiskCategoryList(new ArrayList<>()); + } + riskItem.getRiskItemPK().setFMEAid(riskItem.getFmea().getId()); + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + Fmea fmea = riskItem.getFmea(); + if (fmea != null) { + fmea = em.getReference(fmea.getClass(), fmea.getId()); + riskItem.setFmea(fmea); + } + List attachedFailureModeList = new ArrayList<>(); + for (FailureMode failureModeListFailureModeToAttach : riskItem.getFailureModeList()) { + failureModeListFailureModeToAttach = em.getReference(failureModeListFailureModeToAttach.getClass(), failureModeListFailureModeToAttach.getId()); + attachedFailureModeList.add(failureModeListFailureModeToAttach); + } + riskItem.setFailureModeList(attachedFailureModeList); + List attachedHazardList = new ArrayList<>(); + for (Hazard hazardListHazardToAttach : riskItem.getHazardList()) { + hazardListHazardToAttach = em.getReference(hazardListHazardToAttach.getClass(), hazardListHazardToAttach.getId()); + attachedHazardList.add(hazardListHazardToAttach); + } + riskItem.setHazardList(attachedHazardList); + List attachedRiskControlList = new ArrayList<>(); + for (RiskControl riskControlListRiskControlToAttach : riskItem.getRiskControlList()) { + riskControlListRiskControlToAttach = em.getReference(riskControlListRiskControlToAttach.getClass(), riskControlListRiskControlToAttach.getRiskControlPK()); + attachedRiskControlList.add(riskControlListRiskControlToAttach); + } + riskItem.setRiskControlList(attachedRiskControlList); + List attachedRiskControlList1 = new ArrayList<>(); + for (RiskControl riskControlList1RiskControlToAttach : riskItem.getRiskControlList1()) { + riskControlList1RiskControlToAttach = em.getReference(riskControlList1RiskControlToAttach.getClass(), riskControlList1RiskControlToAttach.getRiskControlPK()); + attachedRiskControlList1.add(riskControlList1RiskControlToAttach); + } + riskItem.setRiskControlList1(attachedRiskControlList1); + List attachedCauseList = new ArrayList<>(); + for (Cause causeListCauseToAttach : riskItem.getCauseList()) { + causeListCauseToAttach = em.getReference(causeListCauseToAttach.getClass(), causeListCauseToAttach.getId()); + attachedCauseList.add(causeListCauseToAttach); + } + riskItem.setCauseList(attachedCauseList); + List attachedRiskItemHasRiskCategoryList = new ArrayList<>(); + for (RiskItemHasRiskCategory riskItemHasRiskCategoryListRiskItemHasRiskCategoryToAttach : riskItem.getRiskItemHasRiskCategoryList()) { + riskItemHasRiskCategoryListRiskItemHasRiskCategoryToAttach = em.getReference(riskItemHasRiskCategoryListRiskItemHasRiskCategoryToAttach.getClass(), riskItemHasRiskCategoryListRiskItemHasRiskCategoryToAttach.getRiskItemHasRiskCategoryPK()); + attachedRiskItemHasRiskCategoryList.add(riskItemHasRiskCategoryListRiskItemHasRiskCategoryToAttach); + } + riskItem.setRiskItemHasRiskCategoryList(attachedRiskItemHasRiskCategoryList); + em.persist(riskItem); + if (fmea != null) { + fmea.getRiskItemList().add(riskItem); + fmea = em.merge(fmea); + } + for (FailureMode failureModeListFailureMode : riskItem.getFailureModeList()) { + failureModeListFailureMode.getRiskItemList().add(riskItem); + failureModeListFailureMode = em.merge(failureModeListFailureMode); + } + for (Hazard hazardListHazard : riskItem.getHazardList()) { + hazardListHazard.getRiskItemList().add(riskItem); + hazardListHazard = em.merge(hazardListHazard); + } + for (RiskControl riskControlListRiskControl : riskItem.getRiskControlList()) { + riskControlListRiskControl.getRiskItemList().add(riskItem); + riskControlListRiskControl = em.merge(riskControlListRiskControl); + } + for (RiskControl riskControlList1RiskControl : riskItem.getRiskControlList1()) { + riskControlList1RiskControl.getRiskItemList1().add(riskItem); + riskControlList1RiskControl = em.merge(riskControlList1RiskControl); + } + for (Cause causeListCause : riskItem.getCauseList()) { + causeListCause.getRiskItemList().add(riskItem); + causeListCause = em.merge(causeListCause); + } + for (RiskItemHasRiskCategory riskItemHasRiskCategoryListRiskItemHasRiskCategory : riskItem.getRiskItemHasRiskCategoryList()) { + RiskItem oldRiskItemOfRiskItemHasRiskCategoryListRiskItemHasRiskCategory = riskItemHasRiskCategoryListRiskItemHasRiskCategory.getRiskItem(); + riskItemHasRiskCategoryListRiskItemHasRiskCategory.setRiskItem(riskItem); + riskItemHasRiskCategoryListRiskItemHasRiskCategory = em.merge(riskItemHasRiskCategoryListRiskItemHasRiskCategory); + if (oldRiskItemOfRiskItemHasRiskCategoryListRiskItemHasRiskCategory != null) { + oldRiskItemOfRiskItemHasRiskCategoryListRiskItemHasRiskCategory.getRiskItemHasRiskCategoryList().remove(riskItemHasRiskCategoryListRiskItemHasRiskCategory); + oldRiskItemOfRiskItemHasRiskCategoryListRiskItemHasRiskCategory = em.merge(oldRiskItemOfRiskItemHasRiskCategoryListRiskItemHasRiskCategory); + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + if (findRiskItem(riskItem.getRiskItemPK()) != null) { + throw new PreexistingEntityException("RiskItem " + riskItem + " already exists.", ex); + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(RiskItem riskItem) throws IllegalOrphanException, NonexistentEntityException, Exception { + riskItem.getRiskItemPK().setFMEAid(riskItem.getFmea().getId()); + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + RiskItem persistentRiskItem = em.find(RiskItem.class, riskItem.getRiskItemPK()); + Fmea fmeaOld = persistentRiskItem.getFmea(); + Fmea fmeaNew = riskItem.getFmea(); + List failureModeListOld = persistentRiskItem.getFailureModeList(); + List failureModeListNew = riskItem.getFailureModeList(); + List hazardListOld = persistentRiskItem.getHazardList(); + List hazardListNew = riskItem.getHazardList(); + List riskControlListOld = persistentRiskItem.getRiskControlList(); + List riskControlListNew = riskItem.getRiskControlList(); + List riskControlList1Old = persistentRiskItem.getRiskControlList1(); + List riskControlList1New = riskItem.getRiskControlList1(); + List causeListOld = persistentRiskItem.getCauseList(); + List causeListNew = riskItem.getCauseList(); + List riskItemHasRiskCategoryListOld = persistentRiskItem.getRiskItemHasRiskCategoryList(); + List riskItemHasRiskCategoryListNew = riskItem.getRiskItemHasRiskCategoryList(); + List illegalOrphanMessages = null; + for (RiskItemHasRiskCategory riskItemHasRiskCategoryListOldRiskItemHasRiskCategory : riskItemHasRiskCategoryListOld) { + if (!riskItemHasRiskCategoryListNew.contains(riskItemHasRiskCategoryListOldRiskItemHasRiskCategory)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain RiskItemHasRiskCategory " + riskItemHasRiskCategoryListOldRiskItemHasRiskCategory + " since its riskItem field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + if (fmeaNew != null) { + fmeaNew = em.getReference(fmeaNew.getClass(), fmeaNew.getId()); + riskItem.setFmea(fmeaNew); + } + List attachedFailureModeListNew = new ArrayList<>(); + for (FailureMode failureModeListNewFailureModeToAttach : failureModeListNew) { + failureModeListNewFailureModeToAttach = em.getReference(failureModeListNewFailureModeToAttach.getClass(), failureModeListNewFailureModeToAttach.getId()); + attachedFailureModeListNew.add(failureModeListNewFailureModeToAttach); + } + failureModeListNew = attachedFailureModeListNew; + riskItem.setFailureModeList(failureModeListNew); + List attachedHazardListNew = new ArrayList<>(); + for (Hazard hazardListNewHazardToAttach : hazardListNew) { + hazardListNewHazardToAttach = em.getReference(hazardListNewHazardToAttach.getClass(), hazardListNewHazardToAttach.getId()); + attachedHazardListNew.add(hazardListNewHazardToAttach); + } + hazardListNew = attachedHazardListNew; + riskItem.setHazardList(hazardListNew); + List attachedRiskControlListNew = new ArrayList<>(); + for (RiskControl riskControlListNewRiskControlToAttach : riskControlListNew) { + riskControlListNewRiskControlToAttach = em.getReference(riskControlListNewRiskControlToAttach.getClass(), riskControlListNewRiskControlToAttach.getRiskControlPK()); + attachedRiskControlListNew.add(riskControlListNewRiskControlToAttach); + } + riskControlListNew = attachedRiskControlListNew; + riskItem.setRiskControlList(riskControlListNew); + List attachedRiskControlList1New = new ArrayList<>(); + for (RiskControl riskControlList1NewRiskControlToAttach : riskControlList1New) { + riskControlList1NewRiskControlToAttach = em.getReference(riskControlList1NewRiskControlToAttach.getClass(), riskControlList1NewRiskControlToAttach.getRiskControlPK()); + attachedRiskControlList1New.add(riskControlList1NewRiskControlToAttach); + } + riskControlList1New = attachedRiskControlList1New; + riskItem.setRiskControlList1(riskControlList1New); + List attachedCauseListNew = new ArrayList<>(); + for (Cause causeListNewCauseToAttach : causeListNew) { + causeListNewCauseToAttach = em.getReference(causeListNewCauseToAttach.getClass(), causeListNewCauseToAttach.getId()); + attachedCauseListNew.add(causeListNewCauseToAttach); + } + causeListNew = attachedCauseListNew; + riskItem.setCauseList(causeListNew); + List attachedRiskItemHasRiskCategoryListNew = new ArrayList<>(); + for (RiskItemHasRiskCategory riskItemHasRiskCategoryListNewRiskItemHasRiskCategoryToAttach : riskItemHasRiskCategoryListNew) { + riskItemHasRiskCategoryListNewRiskItemHasRiskCategoryToAttach = em.getReference(riskItemHasRiskCategoryListNewRiskItemHasRiskCategoryToAttach.getClass(), riskItemHasRiskCategoryListNewRiskItemHasRiskCategoryToAttach.getRiskItemHasRiskCategoryPK()); + attachedRiskItemHasRiskCategoryListNew.add(riskItemHasRiskCategoryListNewRiskItemHasRiskCategoryToAttach); + } + riskItemHasRiskCategoryListNew = attachedRiskItemHasRiskCategoryListNew; + riskItem.setRiskItemHasRiskCategoryList(riskItemHasRiskCategoryListNew); + riskItem = em.merge(riskItem); + if (fmeaOld != null && !fmeaOld.equals(fmeaNew)) { + fmeaOld.getRiskItemList().remove(riskItem); + fmeaOld = em.merge(fmeaOld); + } + if (fmeaNew != null && !fmeaNew.equals(fmeaOld)) { + fmeaNew.getRiskItemList().add(riskItem); + fmeaNew = em.merge(fmeaNew); + } + for (FailureMode failureModeListOldFailureMode : failureModeListOld) { + if (!failureModeListNew.contains(failureModeListOldFailureMode)) { + failureModeListOldFailureMode.getRiskItemList().remove(riskItem); + failureModeListOldFailureMode = em.merge(failureModeListOldFailureMode); + } + } + for (FailureMode failureModeListNewFailureMode : failureModeListNew) { + if (!failureModeListOld.contains(failureModeListNewFailureMode)) { + failureModeListNewFailureMode.getRiskItemList().add(riskItem); + failureModeListNewFailureMode = em.merge(failureModeListNewFailureMode); + } + } + for (Hazard hazardListOldHazard : hazardListOld) { + if (!hazardListNew.contains(hazardListOldHazard)) { + hazardListOldHazard.getRiskItemList().remove(riskItem); + hazardListOldHazard = em.merge(hazardListOldHazard); + } + } + for (Hazard hazardListNewHazard : hazardListNew) { + if (!hazardListOld.contains(hazardListNewHazard)) { + hazardListNewHazard.getRiskItemList().add(riskItem); + hazardListNewHazard = em.merge(hazardListNewHazard); + } + } + for (RiskControl riskControlListOldRiskControl : riskControlListOld) { + if (!riskControlListNew.contains(riskControlListOldRiskControl)) { + riskControlListOldRiskControl.getRiskItemList().remove(riskItem); + riskControlListOldRiskControl = em.merge(riskControlListOldRiskControl); + } + } + for (RiskControl riskControlListNewRiskControl : riskControlListNew) { + if (!riskControlListOld.contains(riskControlListNewRiskControl)) { + riskControlListNewRiskControl.getRiskItemList().add(riskItem); + riskControlListNewRiskControl = em.merge(riskControlListNewRiskControl); + } + } + for (RiskControl riskControlList1OldRiskControl : riskControlList1Old) { + if (!riskControlList1New.contains(riskControlList1OldRiskControl)) { + riskControlList1OldRiskControl.getRiskItemList1().remove(riskItem); + riskControlList1OldRiskControl = em.merge(riskControlList1OldRiskControl); + } + } + for (RiskControl riskControlList1NewRiskControl : riskControlList1New) { + if (!riskControlList1Old.contains(riskControlList1NewRiskControl)) { + riskControlList1NewRiskControl.getRiskItemList1().add(riskItem); + riskControlList1NewRiskControl = em.merge(riskControlList1NewRiskControl); + } + } + for (Cause causeListOldCause : causeListOld) { + if (!causeListNew.contains(causeListOldCause)) { + causeListOldCause.getRiskItemList().remove(riskItem); + causeListOldCause = em.merge(causeListOldCause); + } + } + for (Cause causeListNewCause : causeListNew) { + if (!causeListOld.contains(causeListNewCause)) { + causeListNewCause.getRiskItemList().add(riskItem); + causeListNewCause = em.merge(causeListNewCause); + } + } + for (RiskItemHasRiskCategory riskItemHasRiskCategoryListNewRiskItemHasRiskCategory : riskItemHasRiskCategoryListNew) { + if (!riskItemHasRiskCategoryListOld.contains(riskItemHasRiskCategoryListNewRiskItemHasRiskCategory)) { + RiskItem oldRiskItemOfRiskItemHasRiskCategoryListNewRiskItemHasRiskCategory = riskItemHasRiskCategoryListNewRiskItemHasRiskCategory.getRiskItem(); + riskItemHasRiskCategoryListNewRiskItemHasRiskCategory.setRiskItem(riskItem); + riskItemHasRiskCategoryListNewRiskItemHasRiskCategory = em.merge(riskItemHasRiskCategoryListNewRiskItemHasRiskCategory); + if (oldRiskItemOfRiskItemHasRiskCategoryListNewRiskItemHasRiskCategory != null && !oldRiskItemOfRiskItemHasRiskCategoryListNewRiskItemHasRiskCategory.equals(riskItem)) { + oldRiskItemOfRiskItemHasRiskCategoryListNewRiskItemHasRiskCategory.getRiskItemHasRiskCategoryList().remove(riskItemHasRiskCategoryListNewRiskItemHasRiskCategory); + oldRiskItemOfRiskItemHasRiskCategoryListNewRiskItemHasRiskCategory = em.merge(oldRiskItemOfRiskItemHasRiskCategoryListNewRiskItemHasRiskCategory); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + RiskItemPK id = riskItem.getRiskItemPK(); + if (findRiskItem(id) == null) { + throw new NonexistentEntityException("The riskItem with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(RiskItemPK id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + RiskItem riskItem; + try { + riskItem = em.getReference(RiskItem.class, id); + riskItem.getRiskItemPK(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The riskItem with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List riskItemHasRiskCategoryListOrphanCheck = riskItem.getRiskItemHasRiskCategoryList(); + for (RiskItemHasRiskCategory riskItemHasRiskCategoryListOrphanCheckRiskItemHasRiskCategory : riskItemHasRiskCategoryListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This RiskItem (" + riskItem + ") cannot be destroyed since the RiskItemHasRiskCategory " + riskItemHasRiskCategoryListOrphanCheckRiskItemHasRiskCategory + " in its riskItemHasRiskCategoryList field has a non-nullable riskItem field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + Fmea fmea = riskItem.getFmea(); + if (fmea != null) { + fmea.getRiskItemList().remove(riskItem); + fmea = em.merge(fmea); + } + List failureModeList = riskItem.getFailureModeList(); + for (FailureMode failureModeListFailureMode : failureModeList) { + failureModeListFailureMode.getRiskItemList().remove(riskItem); + failureModeListFailureMode = em.merge(failureModeListFailureMode); + } + List hazardList = riskItem.getHazardList(); + for (Hazard hazardListHazard : hazardList) { + hazardListHazard.getRiskItemList().remove(riskItem); + hazardListHazard = em.merge(hazardListHazard); + } + List riskControlList = riskItem.getRiskControlList(); + for (RiskControl riskControlListRiskControl : riskControlList) { + riskControlListRiskControl.getRiskItemList().remove(riskItem); + riskControlListRiskControl = em.merge(riskControlListRiskControl); + } + List riskControlList1 = riskItem.getRiskControlList1(); + for (RiskControl riskControlList1RiskControl : riskControlList1) { + riskControlList1RiskControl.getRiskItemList1().remove(riskItem); + riskControlList1RiskControl = em.merge(riskControlList1RiskControl); + } + List causeList = riskItem.getCauseList(); + for (Cause causeListCause : causeList) { + causeListCause.getRiskItemList().remove(riskItem); + causeListCause = em.merge(causeListCause); + } + em.remove(riskItem); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findRiskItemEntities() { + return findRiskItemEntities(true, -1, -1); + } + + public List findRiskItemEntities(int maxResults, int firstResult) { + return findRiskItemEntities(false, maxResults, firstResult); + } + + private List findRiskItemEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(RiskItem.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public RiskItem findRiskItem(RiskItemPK id) { + EntityManager em = getEntityManager(); + try { + return em.find(RiskItem.class, id); + } + finally { + em.close(); + } + } + + public int getRiskItemCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(RiskItem.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/RoleJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/RoleJpaController.java index 28bb8041..98469f13 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/RoleJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/RoleJpaController.java @@ -13,397 +13,397 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.VmUser; -import java.util.ArrayList; -import java.util.List; -import com.validation.manager.core.db.UserRight; -import com.validation.manager.core.db.UserTestProjectRole; -import com.validation.manager.core.db.UserTestPlanRole; -import com.validation.manager.core.db.ExecutionStepHasVmUser; -import com.validation.manager.core.db.Role; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class RoleJpaController implements Serializable { - - public RoleJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(Role role) { - if (role.getVmUserList() == null) { - role.setVmUserList(new ArrayList()); - } - if (role.getUserRightList() == null) { - role.setUserRightList(new ArrayList()); - } - if (role.getUserTestProjectRoleList() == null) { - role.setUserTestProjectRoleList(new ArrayList()); - } - if (role.getUserTestPlanRoleList() == null) { - role.setUserTestPlanRoleList(new ArrayList()); - } - if (role.getExecutionStepHasVmUserList() == null) { - role.setExecutionStepHasVmUserList(new ArrayList()); - } - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - List attachedVmUserList = new ArrayList(); - for (VmUser vmUserListVmUserToAttach : role.getVmUserList()) { - vmUserListVmUserToAttach = em.getReference(vmUserListVmUserToAttach.getClass(), vmUserListVmUserToAttach.getId()); - attachedVmUserList.add(vmUserListVmUserToAttach); - } - role.setVmUserList(attachedVmUserList); - List attachedUserRightList = new ArrayList(); - for (UserRight userRightListUserRightToAttach : role.getUserRightList()) { - userRightListUserRightToAttach = em.getReference(userRightListUserRightToAttach.getClass(), userRightListUserRightToAttach.getId()); - attachedUserRightList.add(userRightListUserRightToAttach); - } - role.setUserRightList(attachedUserRightList); - List attachedUserTestProjectRoleList = new ArrayList(); - for (UserTestProjectRole userTestProjectRoleListUserTestProjectRoleToAttach : role.getUserTestProjectRoleList()) { - userTestProjectRoleListUserTestProjectRoleToAttach = em.getReference(userTestProjectRoleListUserTestProjectRoleToAttach.getClass(), userTestProjectRoleListUserTestProjectRoleToAttach.getUserTestProjectRolePK()); - attachedUserTestProjectRoleList.add(userTestProjectRoleListUserTestProjectRoleToAttach); - } - role.setUserTestProjectRoleList(attachedUserTestProjectRoleList); - List attachedUserTestPlanRoleList = new ArrayList(); - for (UserTestPlanRole userTestPlanRoleListUserTestPlanRoleToAttach : role.getUserTestPlanRoleList()) { - userTestPlanRoleListUserTestPlanRoleToAttach = em.getReference(userTestPlanRoleListUserTestPlanRoleToAttach.getClass(), userTestPlanRoleListUserTestPlanRoleToAttach.getUserTestPlanRolePK()); - attachedUserTestPlanRoleList.add(userTestPlanRoleListUserTestPlanRoleToAttach); - } - role.setUserTestPlanRoleList(attachedUserTestPlanRoleList); - List attachedExecutionStepHasVmUserList = new ArrayList(); - for (ExecutionStepHasVmUser executionStepHasVmUserListExecutionStepHasVmUserToAttach : role.getExecutionStepHasVmUserList()) { - executionStepHasVmUserListExecutionStepHasVmUserToAttach = em.getReference(executionStepHasVmUserListExecutionStepHasVmUserToAttach.getClass(), executionStepHasVmUserListExecutionStepHasVmUserToAttach.getExecutionStepHasVmUserPK()); - attachedExecutionStepHasVmUserList.add(executionStepHasVmUserListExecutionStepHasVmUserToAttach); - } - role.setExecutionStepHasVmUserList(attachedExecutionStepHasVmUserList); - em.persist(role); - for (VmUser vmUserListVmUser : role.getVmUserList()) { - vmUserListVmUser.getRoleList().add(role); - vmUserListVmUser = em.merge(vmUserListVmUser); - } - for (UserRight userRightListUserRight : role.getUserRightList()) { - userRightListUserRight.getRoleList().add(role); - userRightListUserRight = em.merge(userRightListUserRight); - } - for (UserTestProjectRole userTestProjectRoleListUserTestProjectRole : role.getUserTestProjectRoleList()) { - Role oldRoleOfUserTestProjectRoleListUserTestProjectRole = userTestProjectRoleListUserTestProjectRole.getRole(); - userTestProjectRoleListUserTestProjectRole.setRole(role); - userTestProjectRoleListUserTestProjectRole = em.merge(userTestProjectRoleListUserTestProjectRole); - if (oldRoleOfUserTestProjectRoleListUserTestProjectRole != null) { - oldRoleOfUserTestProjectRoleListUserTestProjectRole.getUserTestProjectRoleList().remove(userTestProjectRoleListUserTestProjectRole); - oldRoleOfUserTestProjectRoleListUserTestProjectRole = em.merge(oldRoleOfUserTestProjectRoleListUserTestProjectRole); - } - } - for (UserTestPlanRole userTestPlanRoleListUserTestPlanRole : role.getUserTestPlanRoleList()) { - Role oldRoleOfUserTestPlanRoleListUserTestPlanRole = userTestPlanRoleListUserTestPlanRole.getRole(); - userTestPlanRoleListUserTestPlanRole.setRole(role); - userTestPlanRoleListUserTestPlanRole = em.merge(userTestPlanRoleListUserTestPlanRole); - if (oldRoleOfUserTestPlanRoleListUserTestPlanRole != null) { - oldRoleOfUserTestPlanRoleListUserTestPlanRole.getUserTestPlanRoleList().remove(userTestPlanRoleListUserTestPlanRole); - oldRoleOfUserTestPlanRoleListUserTestPlanRole = em.merge(oldRoleOfUserTestPlanRoleListUserTestPlanRole); - } - } - for (ExecutionStepHasVmUser executionStepHasVmUserListExecutionStepHasVmUser : role.getExecutionStepHasVmUserList()) { - Role oldRoleOfExecutionStepHasVmUserListExecutionStepHasVmUser = executionStepHasVmUserListExecutionStepHasVmUser.getRole(); - executionStepHasVmUserListExecutionStepHasVmUser.setRole(role); - executionStepHasVmUserListExecutionStepHasVmUser = em.merge(executionStepHasVmUserListExecutionStepHasVmUser); - if (oldRoleOfExecutionStepHasVmUserListExecutionStepHasVmUser != null) { - oldRoleOfExecutionStepHasVmUserListExecutionStepHasVmUser.getExecutionStepHasVmUserList().remove(executionStepHasVmUserListExecutionStepHasVmUser); - oldRoleOfExecutionStepHasVmUserListExecutionStepHasVmUser = em.merge(oldRoleOfExecutionStepHasVmUserListExecutionStepHasVmUser); - } - } - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(Role role) throws IllegalOrphanException, NonexistentEntityException, Exception { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - Role persistentRole = em.find(Role.class, role.getId()); - List vmUserListOld = persistentRole.getVmUserList(); - List vmUserListNew = role.getVmUserList(); - List userRightListOld = persistentRole.getUserRightList(); - List userRightListNew = role.getUserRightList(); - List userTestProjectRoleListOld = persistentRole.getUserTestProjectRoleList(); - List userTestProjectRoleListNew = role.getUserTestProjectRoleList(); - List userTestPlanRoleListOld = persistentRole.getUserTestPlanRoleList(); - List userTestPlanRoleListNew = role.getUserTestPlanRoleList(); - List executionStepHasVmUserListOld = persistentRole.getExecutionStepHasVmUserList(); - List executionStepHasVmUserListNew = role.getExecutionStepHasVmUserList(); - List illegalOrphanMessages = null; - for (UserTestProjectRole userTestProjectRoleListOldUserTestProjectRole : userTestProjectRoleListOld) { - if (!userTestProjectRoleListNew.contains(userTestProjectRoleListOldUserTestProjectRole)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain UserTestProjectRole " + userTestProjectRoleListOldUserTestProjectRole + " since its role field is not nullable."); - } - } - for (UserTestPlanRole userTestPlanRoleListOldUserTestPlanRole : userTestPlanRoleListOld) { - if (!userTestPlanRoleListNew.contains(userTestPlanRoleListOldUserTestPlanRole)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain UserTestPlanRole " + userTestPlanRoleListOldUserTestPlanRole + " since its role field is not nullable."); - } - } - for (ExecutionStepHasVmUser executionStepHasVmUserListOldExecutionStepHasVmUser : executionStepHasVmUserListOld) { - if (!executionStepHasVmUserListNew.contains(executionStepHasVmUserListOldExecutionStepHasVmUser)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain ExecutionStepHasVmUser " + executionStepHasVmUserListOldExecutionStepHasVmUser + " since its role field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - List attachedVmUserListNew = new ArrayList(); - for (VmUser vmUserListNewVmUserToAttach : vmUserListNew) { - vmUserListNewVmUserToAttach = em.getReference(vmUserListNewVmUserToAttach.getClass(), vmUserListNewVmUserToAttach.getId()); - attachedVmUserListNew.add(vmUserListNewVmUserToAttach); - } - vmUserListNew = attachedVmUserListNew; - role.setVmUserList(vmUserListNew); - List attachedUserRightListNew = new ArrayList(); - for (UserRight userRightListNewUserRightToAttach : userRightListNew) { - userRightListNewUserRightToAttach = em.getReference(userRightListNewUserRightToAttach.getClass(), userRightListNewUserRightToAttach.getId()); - attachedUserRightListNew.add(userRightListNewUserRightToAttach); - } - userRightListNew = attachedUserRightListNew; - role.setUserRightList(userRightListNew); - List attachedUserTestProjectRoleListNew = new ArrayList(); - for (UserTestProjectRole userTestProjectRoleListNewUserTestProjectRoleToAttach : userTestProjectRoleListNew) { - userTestProjectRoleListNewUserTestProjectRoleToAttach = em.getReference(userTestProjectRoleListNewUserTestProjectRoleToAttach.getClass(), userTestProjectRoleListNewUserTestProjectRoleToAttach.getUserTestProjectRolePK()); - attachedUserTestProjectRoleListNew.add(userTestProjectRoleListNewUserTestProjectRoleToAttach); - } - userTestProjectRoleListNew = attachedUserTestProjectRoleListNew; - role.setUserTestProjectRoleList(userTestProjectRoleListNew); - List attachedUserTestPlanRoleListNew = new ArrayList(); - for (UserTestPlanRole userTestPlanRoleListNewUserTestPlanRoleToAttach : userTestPlanRoleListNew) { - userTestPlanRoleListNewUserTestPlanRoleToAttach = em.getReference(userTestPlanRoleListNewUserTestPlanRoleToAttach.getClass(), userTestPlanRoleListNewUserTestPlanRoleToAttach.getUserTestPlanRolePK()); - attachedUserTestPlanRoleListNew.add(userTestPlanRoleListNewUserTestPlanRoleToAttach); - } - userTestPlanRoleListNew = attachedUserTestPlanRoleListNew; - role.setUserTestPlanRoleList(userTestPlanRoleListNew); - List attachedExecutionStepHasVmUserListNew = new ArrayList(); - for (ExecutionStepHasVmUser executionStepHasVmUserListNewExecutionStepHasVmUserToAttach : executionStepHasVmUserListNew) { - executionStepHasVmUserListNewExecutionStepHasVmUserToAttach = em.getReference(executionStepHasVmUserListNewExecutionStepHasVmUserToAttach.getClass(), executionStepHasVmUserListNewExecutionStepHasVmUserToAttach.getExecutionStepHasVmUserPK()); - attachedExecutionStepHasVmUserListNew.add(executionStepHasVmUserListNewExecutionStepHasVmUserToAttach); - } - executionStepHasVmUserListNew = attachedExecutionStepHasVmUserListNew; - role.setExecutionStepHasVmUserList(executionStepHasVmUserListNew); - role = em.merge(role); - for (VmUser vmUserListOldVmUser : vmUserListOld) { - if (!vmUserListNew.contains(vmUserListOldVmUser)) { - vmUserListOldVmUser.getRoleList().remove(role); - vmUserListOldVmUser = em.merge(vmUserListOldVmUser); - } - } - for (VmUser vmUserListNewVmUser : vmUserListNew) { - if (!vmUserListOld.contains(vmUserListNewVmUser)) { - vmUserListNewVmUser.getRoleList().add(role); - vmUserListNewVmUser = em.merge(vmUserListNewVmUser); - } - } - for (UserRight userRightListOldUserRight : userRightListOld) { - if (!userRightListNew.contains(userRightListOldUserRight)) { - userRightListOldUserRight.getRoleList().remove(role); - userRightListOldUserRight = em.merge(userRightListOldUserRight); - } - } - for (UserRight userRightListNewUserRight : userRightListNew) { - if (!userRightListOld.contains(userRightListNewUserRight)) { - userRightListNewUserRight.getRoleList().add(role); - userRightListNewUserRight = em.merge(userRightListNewUserRight); - } - } - for (UserTestProjectRole userTestProjectRoleListNewUserTestProjectRole : userTestProjectRoleListNew) { - if (!userTestProjectRoleListOld.contains(userTestProjectRoleListNewUserTestProjectRole)) { - Role oldRoleOfUserTestProjectRoleListNewUserTestProjectRole = userTestProjectRoleListNewUserTestProjectRole.getRole(); - userTestProjectRoleListNewUserTestProjectRole.setRole(role); - userTestProjectRoleListNewUserTestProjectRole = em.merge(userTestProjectRoleListNewUserTestProjectRole); - if (oldRoleOfUserTestProjectRoleListNewUserTestProjectRole != null && !oldRoleOfUserTestProjectRoleListNewUserTestProjectRole.equals(role)) { - oldRoleOfUserTestProjectRoleListNewUserTestProjectRole.getUserTestProjectRoleList().remove(userTestProjectRoleListNewUserTestProjectRole); - oldRoleOfUserTestProjectRoleListNewUserTestProjectRole = em.merge(oldRoleOfUserTestProjectRoleListNewUserTestProjectRole); - } - } - } - for (UserTestPlanRole userTestPlanRoleListNewUserTestPlanRole : userTestPlanRoleListNew) { - if (!userTestPlanRoleListOld.contains(userTestPlanRoleListNewUserTestPlanRole)) { - Role oldRoleOfUserTestPlanRoleListNewUserTestPlanRole = userTestPlanRoleListNewUserTestPlanRole.getRole(); - userTestPlanRoleListNewUserTestPlanRole.setRole(role); - userTestPlanRoleListNewUserTestPlanRole = em.merge(userTestPlanRoleListNewUserTestPlanRole); - if (oldRoleOfUserTestPlanRoleListNewUserTestPlanRole != null && !oldRoleOfUserTestPlanRoleListNewUserTestPlanRole.equals(role)) { - oldRoleOfUserTestPlanRoleListNewUserTestPlanRole.getUserTestPlanRoleList().remove(userTestPlanRoleListNewUserTestPlanRole); - oldRoleOfUserTestPlanRoleListNewUserTestPlanRole = em.merge(oldRoleOfUserTestPlanRoleListNewUserTestPlanRole); - } - } - } - for (ExecutionStepHasVmUser executionStepHasVmUserListNewExecutionStepHasVmUser : executionStepHasVmUserListNew) { - if (!executionStepHasVmUserListOld.contains(executionStepHasVmUserListNewExecutionStepHasVmUser)) { - Role oldRoleOfExecutionStepHasVmUserListNewExecutionStepHasVmUser = executionStepHasVmUserListNewExecutionStepHasVmUser.getRole(); - executionStepHasVmUserListNewExecutionStepHasVmUser.setRole(role); - executionStepHasVmUserListNewExecutionStepHasVmUser = em.merge(executionStepHasVmUserListNewExecutionStepHasVmUser); - if (oldRoleOfExecutionStepHasVmUserListNewExecutionStepHasVmUser != null && !oldRoleOfExecutionStepHasVmUserListNewExecutionStepHasVmUser.equals(role)) { - oldRoleOfExecutionStepHasVmUserListNewExecutionStepHasVmUser.getExecutionStepHasVmUserList().remove(executionStepHasVmUserListNewExecutionStepHasVmUser); - oldRoleOfExecutionStepHasVmUserListNewExecutionStepHasVmUser = em.merge(oldRoleOfExecutionStepHasVmUserListNewExecutionStepHasVmUser); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - Integer id = role.getId(); - if (findRole(id) == null) { - throw new NonexistentEntityException("The role with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - Role role; - try { - role = em.getReference(Role.class, id); - role.getId(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The role with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List userTestProjectRoleListOrphanCheck = role.getUserTestProjectRoleList(); - for (UserTestProjectRole userTestProjectRoleListOrphanCheckUserTestProjectRole : userTestProjectRoleListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This Role (" + role + ") cannot be destroyed since the UserTestProjectRole " + userTestProjectRoleListOrphanCheckUserTestProjectRole + " in its userTestProjectRoleList field has a non-nullable role field."); - } - List userTestPlanRoleListOrphanCheck = role.getUserTestPlanRoleList(); - for (UserTestPlanRole userTestPlanRoleListOrphanCheckUserTestPlanRole : userTestPlanRoleListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This Role (" + role + ") cannot be destroyed since the UserTestPlanRole " + userTestPlanRoleListOrphanCheckUserTestPlanRole + " in its userTestPlanRoleList field has a non-nullable role field."); - } - List executionStepHasVmUserListOrphanCheck = role.getExecutionStepHasVmUserList(); - for (ExecutionStepHasVmUser executionStepHasVmUserListOrphanCheckExecutionStepHasVmUser : executionStepHasVmUserListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This Role (" + role + ") cannot be destroyed since the ExecutionStepHasVmUser " + executionStepHasVmUserListOrphanCheckExecutionStepHasVmUser + " in its executionStepHasVmUserList field has a non-nullable role field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - List vmUserList = role.getVmUserList(); - for (VmUser vmUserListVmUser : vmUserList) { - vmUserListVmUser.getRoleList().remove(role); - vmUserListVmUser = em.merge(vmUserListVmUser); - } - List userRightList = role.getUserRightList(); - for (UserRight userRightListUserRight : userRightList) { - userRightListUserRight.getRoleList().remove(role); - userRightListUserRight = em.merge(userRightListUserRight); - } - em.remove(role); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findRoleEntities() { - return findRoleEntities(true, -1, -1); - } - - public List findRoleEntities(int maxResults, int firstResult) { - return findRoleEntities(false, maxResults, firstResult); - } - - private List findRoleEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(Role.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public Role findRole(Integer id) { - EntityManager em = getEntityManager(); - try { - return em.find(Role.class, id); - } - finally { - em.close(); - } - } - - public int getRoleCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(Role.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.VmUser; +import java.util.ArrayList; +import java.util.List; +import com.validation.manager.core.db.UserRight; +import com.validation.manager.core.db.UserTestProjectRole; +import com.validation.manager.core.db.UserTestPlanRole; +import com.validation.manager.core.db.ExecutionStepHasVmUser; +import com.validation.manager.core.db.Role; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class RoleJpaController implements Serializable { + + public RoleJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(Role role) { + if (role.getVmUserList() == null) { + role.setVmUserList(new ArrayList<>()); + } + if (role.getUserRightList() == null) { + role.setUserRightList(new ArrayList<>()); + } + if (role.getUserTestProjectRoleList() == null) { + role.setUserTestProjectRoleList(new ArrayList<>()); + } + if (role.getUserTestPlanRoleList() == null) { + role.setUserTestPlanRoleList(new ArrayList<>()); + } + if (role.getExecutionStepHasVmUserList() == null) { + role.setExecutionStepHasVmUserList(new ArrayList<>()); + } + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + List attachedVmUserList = new ArrayList<>(); + for (VmUser vmUserListVmUserToAttach : role.getVmUserList()) { + vmUserListVmUserToAttach = em.getReference(vmUserListVmUserToAttach.getClass(), vmUserListVmUserToAttach.getId()); + attachedVmUserList.add(vmUserListVmUserToAttach); + } + role.setVmUserList(attachedVmUserList); + List attachedUserRightList = new ArrayList<>(); + for (UserRight userRightListUserRightToAttach : role.getUserRightList()) { + userRightListUserRightToAttach = em.getReference(userRightListUserRightToAttach.getClass(), userRightListUserRightToAttach.getId()); + attachedUserRightList.add(userRightListUserRightToAttach); + } + role.setUserRightList(attachedUserRightList); + List attachedUserTestProjectRoleList = new ArrayList<>(); + for (UserTestProjectRole userTestProjectRoleListUserTestProjectRoleToAttach : role.getUserTestProjectRoleList()) { + userTestProjectRoleListUserTestProjectRoleToAttach = em.getReference(userTestProjectRoleListUserTestProjectRoleToAttach.getClass(), userTestProjectRoleListUserTestProjectRoleToAttach.getUserTestProjectRolePK()); + attachedUserTestProjectRoleList.add(userTestProjectRoleListUserTestProjectRoleToAttach); + } + role.setUserTestProjectRoleList(attachedUserTestProjectRoleList); + List attachedUserTestPlanRoleList = new ArrayList<>(); + for (UserTestPlanRole userTestPlanRoleListUserTestPlanRoleToAttach : role.getUserTestPlanRoleList()) { + userTestPlanRoleListUserTestPlanRoleToAttach = em.getReference(userTestPlanRoleListUserTestPlanRoleToAttach.getClass(), userTestPlanRoleListUserTestPlanRoleToAttach.getUserTestPlanRolePK()); + attachedUserTestPlanRoleList.add(userTestPlanRoleListUserTestPlanRoleToAttach); + } + role.setUserTestPlanRoleList(attachedUserTestPlanRoleList); + List attachedExecutionStepHasVmUserList = new ArrayList<>(); + for (ExecutionStepHasVmUser executionStepHasVmUserListExecutionStepHasVmUserToAttach : role.getExecutionStepHasVmUserList()) { + executionStepHasVmUserListExecutionStepHasVmUserToAttach = em.getReference(executionStepHasVmUserListExecutionStepHasVmUserToAttach.getClass(), executionStepHasVmUserListExecutionStepHasVmUserToAttach.getExecutionStepHasVmUserPK()); + attachedExecutionStepHasVmUserList.add(executionStepHasVmUserListExecutionStepHasVmUserToAttach); + } + role.setExecutionStepHasVmUserList(attachedExecutionStepHasVmUserList); + em.persist(role); + for (VmUser vmUserListVmUser : role.getVmUserList()) { + vmUserListVmUser.getRoleList().add(role); + vmUserListVmUser = em.merge(vmUserListVmUser); + } + for (UserRight userRightListUserRight : role.getUserRightList()) { + userRightListUserRight.getRoleList().add(role); + userRightListUserRight = em.merge(userRightListUserRight); + } + for (UserTestProjectRole userTestProjectRoleListUserTestProjectRole : role.getUserTestProjectRoleList()) { + Role oldRoleOfUserTestProjectRoleListUserTestProjectRole = userTestProjectRoleListUserTestProjectRole.getRole(); + userTestProjectRoleListUserTestProjectRole.setRole(role); + userTestProjectRoleListUserTestProjectRole = em.merge(userTestProjectRoleListUserTestProjectRole); + if (oldRoleOfUserTestProjectRoleListUserTestProjectRole != null) { + oldRoleOfUserTestProjectRoleListUserTestProjectRole.getUserTestProjectRoleList().remove(userTestProjectRoleListUserTestProjectRole); + oldRoleOfUserTestProjectRoleListUserTestProjectRole = em.merge(oldRoleOfUserTestProjectRoleListUserTestProjectRole); + } + } + for (UserTestPlanRole userTestPlanRoleListUserTestPlanRole : role.getUserTestPlanRoleList()) { + Role oldRoleOfUserTestPlanRoleListUserTestPlanRole = userTestPlanRoleListUserTestPlanRole.getRole(); + userTestPlanRoleListUserTestPlanRole.setRole(role); + userTestPlanRoleListUserTestPlanRole = em.merge(userTestPlanRoleListUserTestPlanRole); + if (oldRoleOfUserTestPlanRoleListUserTestPlanRole != null) { + oldRoleOfUserTestPlanRoleListUserTestPlanRole.getUserTestPlanRoleList().remove(userTestPlanRoleListUserTestPlanRole); + oldRoleOfUserTestPlanRoleListUserTestPlanRole = em.merge(oldRoleOfUserTestPlanRoleListUserTestPlanRole); + } + } + for (ExecutionStepHasVmUser executionStepHasVmUserListExecutionStepHasVmUser : role.getExecutionStepHasVmUserList()) { + Role oldRoleOfExecutionStepHasVmUserListExecutionStepHasVmUser = executionStepHasVmUserListExecutionStepHasVmUser.getRole(); + executionStepHasVmUserListExecutionStepHasVmUser.setRole(role); + executionStepHasVmUserListExecutionStepHasVmUser = em.merge(executionStepHasVmUserListExecutionStepHasVmUser); + if (oldRoleOfExecutionStepHasVmUserListExecutionStepHasVmUser != null) { + oldRoleOfExecutionStepHasVmUserListExecutionStepHasVmUser.getExecutionStepHasVmUserList().remove(executionStepHasVmUserListExecutionStepHasVmUser); + oldRoleOfExecutionStepHasVmUserListExecutionStepHasVmUser = em.merge(oldRoleOfExecutionStepHasVmUserListExecutionStepHasVmUser); + } + } + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(Role role) throws IllegalOrphanException, NonexistentEntityException, Exception { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + Role persistentRole = em.find(Role.class, role.getId()); + List vmUserListOld = persistentRole.getVmUserList(); + List vmUserListNew = role.getVmUserList(); + List userRightListOld = persistentRole.getUserRightList(); + List userRightListNew = role.getUserRightList(); + List userTestProjectRoleListOld = persistentRole.getUserTestProjectRoleList(); + List userTestProjectRoleListNew = role.getUserTestProjectRoleList(); + List userTestPlanRoleListOld = persistentRole.getUserTestPlanRoleList(); + List userTestPlanRoleListNew = role.getUserTestPlanRoleList(); + List executionStepHasVmUserListOld = persistentRole.getExecutionStepHasVmUserList(); + List executionStepHasVmUserListNew = role.getExecutionStepHasVmUserList(); + List illegalOrphanMessages = null; + for (UserTestProjectRole userTestProjectRoleListOldUserTestProjectRole : userTestProjectRoleListOld) { + if (!userTestProjectRoleListNew.contains(userTestProjectRoleListOldUserTestProjectRole)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain UserTestProjectRole " + userTestProjectRoleListOldUserTestProjectRole + " since its role field is not nullable."); + } + } + for (UserTestPlanRole userTestPlanRoleListOldUserTestPlanRole : userTestPlanRoleListOld) { + if (!userTestPlanRoleListNew.contains(userTestPlanRoleListOldUserTestPlanRole)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain UserTestPlanRole " + userTestPlanRoleListOldUserTestPlanRole + " since its role field is not nullable."); + } + } + for (ExecutionStepHasVmUser executionStepHasVmUserListOldExecutionStepHasVmUser : executionStepHasVmUserListOld) { + if (!executionStepHasVmUserListNew.contains(executionStepHasVmUserListOldExecutionStepHasVmUser)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain ExecutionStepHasVmUser " + executionStepHasVmUserListOldExecutionStepHasVmUser + " since its role field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + List attachedVmUserListNew = new ArrayList<>(); + for (VmUser vmUserListNewVmUserToAttach : vmUserListNew) { + vmUserListNewVmUserToAttach = em.getReference(vmUserListNewVmUserToAttach.getClass(), vmUserListNewVmUserToAttach.getId()); + attachedVmUserListNew.add(vmUserListNewVmUserToAttach); + } + vmUserListNew = attachedVmUserListNew; + role.setVmUserList(vmUserListNew); + List attachedUserRightListNew = new ArrayList<>(); + for (UserRight userRightListNewUserRightToAttach : userRightListNew) { + userRightListNewUserRightToAttach = em.getReference(userRightListNewUserRightToAttach.getClass(), userRightListNewUserRightToAttach.getId()); + attachedUserRightListNew.add(userRightListNewUserRightToAttach); + } + userRightListNew = attachedUserRightListNew; + role.setUserRightList(userRightListNew); + List attachedUserTestProjectRoleListNew = new ArrayList<>(); + for (UserTestProjectRole userTestProjectRoleListNewUserTestProjectRoleToAttach : userTestProjectRoleListNew) { + userTestProjectRoleListNewUserTestProjectRoleToAttach = em.getReference(userTestProjectRoleListNewUserTestProjectRoleToAttach.getClass(), userTestProjectRoleListNewUserTestProjectRoleToAttach.getUserTestProjectRolePK()); + attachedUserTestProjectRoleListNew.add(userTestProjectRoleListNewUserTestProjectRoleToAttach); + } + userTestProjectRoleListNew = attachedUserTestProjectRoleListNew; + role.setUserTestProjectRoleList(userTestProjectRoleListNew); + List attachedUserTestPlanRoleListNew = new ArrayList<>(); + for (UserTestPlanRole userTestPlanRoleListNewUserTestPlanRoleToAttach : userTestPlanRoleListNew) { + userTestPlanRoleListNewUserTestPlanRoleToAttach = em.getReference(userTestPlanRoleListNewUserTestPlanRoleToAttach.getClass(), userTestPlanRoleListNewUserTestPlanRoleToAttach.getUserTestPlanRolePK()); + attachedUserTestPlanRoleListNew.add(userTestPlanRoleListNewUserTestPlanRoleToAttach); + } + userTestPlanRoleListNew = attachedUserTestPlanRoleListNew; + role.setUserTestPlanRoleList(userTestPlanRoleListNew); + List attachedExecutionStepHasVmUserListNew = new ArrayList<>(); + for (ExecutionStepHasVmUser executionStepHasVmUserListNewExecutionStepHasVmUserToAttach : executionStepHasVmUserListNew) { + executionStepHasVmUserListNewExecutionStepHasVmUserToAttach = em.getReference(executionStepHasVmUserListNewExecutionStepHasVmUserToAttach.getClass(), executionStepHasVmUserListNewExecutionStepHasVmUserToAttach.getExecutionStepHasVmUserPK()); + attachedExecutionStepHasVmUserListNew.add(executionStepHasVmUserListNewExecutionStepHasVmUserToAttach); + } + executionStepHasVmUserListNew = attachedExecutionStepHasVmUserListNew; + role.setExecutionStepHasVmUserList(executionStepHasVmUserListNew); + role = em.merge(role); + for (VmUser vmUserListOldVmUser : vmUserListOld) { + if (!vmUserListNew.contains(vmUserListOldVmUser)) { + vmUserListOldVmUser.getRoleList().remove(role); + vmUserListOldVmUser = em.merge(vmUserListOldVmUser); + } + } + for (VmUser vmUserListNewVmUser : vmUserListNew) { + if (!vmUserListOld.contains(vmUserListNewVmUser)) { + vmUserListNewVmUser.getRoleList().add(role); + vmUserListNewVmUser = em.merge(vmUserListNewVmUser); + } + } + for (UserRight userRightListOldUserRight : userRightListOld) { + if (!userRightListNew.contains(userRightListOldUserRight)) { + userRightListOldUserRight.getRoleList().remove(role); + userRightListOldUserRight = em.merge(userRightListOldUserRight); + } + } + for (UserRight userRightListNewUserRight : userRightListNew) { + if (!userRightListOld.contains(userRightListNewUserRight)) { + userRightListNewUserRight.getRoleList().add(role); + userRightListNewUserRight = em.merge(userRightListNewUserRight); + } + } + for (UserTestProjectRole userTestProjectRoleListNewUserTestProjectRole : userTestProjectRoleListNew) { + if (!userTestProjectRoleListOld.contains(userTestProjectRoleListNewUserTestProjectRole)) { + Role oldRoleOfUserTestProjectRoleListNewUserTestProjectRole = userTestProjectRoleListNewUserTestProjectRole.getRole(); + userTestProjectRoleListNewUserTestProjectRole.setRole(role); + userTestProjectRoleListNewUserTestProjectRole = em.merge(userTestProjectRoleListNewUserTestProjectRole); + if (oldRoleOfUserTestProjectRoleListNewUserTestProjectRole != null && !oldRoleOfUserTestProjectRoleListNewUserTestProjectRole.equals(role)) { + oldRoleOfUserTestProjectRoleListNewUserTestProjectRole.getUserTestProjectRoleList().remove(userTestProjectRoleListNewUserTestProjectRole); + oldRoleOfUserTestProjectRoleListNewUserTestProjectRole = em.merge(oldRoleOfUserTestProjectRoleListNewUserTestProjectRole); + } + } + } + for (UserTestPlanRole userTestPlanRoleListNewUserTestPlanRole : userTestPlanRoleListNew) { + if (!userTestPlanRoleListOld.contains(userTestPlanRoleListNewUserTestPlanRole)) { + Role oldRoleOfUserTestPlanRoleListNewUserTestPlanRole = userTestPlanRoleListNewUserTestPlanRole.getRole(); + userTestPlanRoleListNewUserTestPlanRole.setRole(role); + userTestPlanRoleListNewUserTestPlanRole = em.merge(userTestPlanRoleListNewUserTestPlanRole); + if (oldRoleOfUserTestPlanRoleListNewUserTestPlanRole != null && !oldRoleOfUserTestPlanRoleListNewUserTestPlanRole.equals(role)) { + oldRoleOfUserTestPlanRoleListNewUserTestPlanRole.getUserTestPlanRoleList().remove(userTestPlanRoleListNewUserTestPlanRole); + oldRoleOfUserTestPlanRoleListNewUserTestPlanRole = em.merge(oldRoleOfUserTestPlanRoleListNewUserTestPlanRole); + } + } + } + for (ExecutionStepHasVmUser executionStepHasVmUserListNewExecutionStepHasVmUser : executionStepHasVmUserListNew) { + if (!executionStepHasVmUserListOld.contains(executionStepHasVmUserListNewExecutionStepHasVmUser)) { + Role oldRoleOfExecutionStepHasVmUserListNewExecutionStepHasVmUser = executionStepHasVmUserListNewExecutionStepHasVmUser.getRole(); + executionStepHasVmUserListNewExecutionStepHasVmUser.setRole(role); + executionStepHasVmUserListNewExecutionStepHasVmUser = em.merge(executionStepHasVmUserListNewExecutionStepHasVmUser); + if (oldRoleOfExecutionStepHasVmUserListNewExecutionStepHasVmUser != null && !oldRoleOfExecutionStepHasVmUserListNewExecutionStepHasVmUser.equals(role)) { + oldRoleOfExecutionStepHasVmUserListNewExecutionStepHasVmUser.getExecutionStepHasVmUserList().remove(executionStepHasVmUserListNewExecutionStepHasVmUser); + oldRoleOfExecutionStepHasVmUserListNewExecutionStepHasVmUser = em.merge(oldRoleOfExecutionStepHasVmUserListNewExecutionStepHasVmUser); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + Integer id = role.getId(); + if (findRole(id) == null) { + throw new NonexistentEntityException("The role with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + Role role; + try { + role = em.getReference(Role.class, id); + role.getId(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The role with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List userTestProjectRoleListOrphanCheck = role.getUserTestProjectRoleList(); + for (UserTestProjectRole userTestProjectRoleListOrphanCheckUserTestProjectRole : userTestProjectRoleListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This Role (" + role + ") cannot be destroyed since the UserTestProjectRole " + userTestProjectRoleListOrphanCheckUserTestProjectRole + " in its userTestProjectRoleList field has a non-nullable role field."); + } + List userTestPlanRoleListOrphanCheck = role.getUserTestPlanRoleList(); + for (UserTestPlanRole userTestPlanRoleListOrphanCheckUserTestPlanRole : userTestPlanRoleListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This Role (" + role + ") cannot be destroyed since the UserTestPlanRole " + userTestPlanRoleListOrphanCheckUserTestPlanRole + " in its userTestPlanRoleList field has a non-nullable role field."); + } + List executionStepHasVmUserListOrphanCheck = role.getExecutionStepHasVmUserList(); + for (ExecutionStepHasVmUser executionStepHasVmUserListOrphanCheckExecutionStepHasVmUser : executionStepHasVmUserListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This Role (" + role + ") cannot be destroyed since the ExecutionStepHasVmUser " + executionStepHasVmUserListOrphanCheckExecutionStepHasVmUser + " in its executionStepHasVmUserList field has a non-nullable role field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + List vmUserList = role.getVmUserList(); + for (VmUser vmUserListVmUser : vmUserList) { + vmUserListVmUser.getRoleList().remove(role); + vmUserListVmUser = em.merge(vmUserListVmUser); + } + List userRightList = role.getUserRightList(); + for (UserRight userRightListUserRight : userRightList) { + userRightListUserRight.getRoleList().remove(role); + userRightListUserRight = em.merge(userRightListUserRight); + } + em.remove(role); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findRoleEntities() { + return findRoleEntities(true, -1, -1); + } + + public List findRoleEntities(int maxResults, int firstResult) { + return findRoleEntities(false, maxResults, firstResult); + } + + private List findRoleEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(Role.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public Role findRole(Integer id) { + EntityManager em = getEntityManager(); + try { + return em.find(Role.class, id); + } + finally { + em.close(); + } + } + + public int getRoleCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(Role.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/RootCauseJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/RootCauseJpaController.java index 08e0e7fb..5f130858 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/RootCauseJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/RootCauseJpaController.java @@ -13,291 +13,291 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.RootCauseType; -import com.validation.manager.core.db.VmUser; -import java.util.ArrayList; -import java.util.List; -import com.validation.manager.core.db.ExceptionHasRootCause; -import com.validation.manager.core.db.RootCause; -import com.validation.manager.core.db.RootCausePK; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import com.validation.manager.core.db.controller.exceptions.PreexistingEntityException; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class RootCauseJpaController implements Serializable { - - public RootCauseJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(RootCause rootCause) throws PreexistingEntityException, Exception { - if (rootCause.getRootCausePK() == null) { - rootCause.setRootCausePK(new RootCausePK()); - } - if (rootCause.getVmUserList() == null) { - rootCause.setVmUserList(new ArrayList()); - } - if (rootCause.getExceptionHasRootCauseList() == null) { - rootCause.setExceptionHasRootCauseList(new ArrayList()); - } - rootCause.getRootCausePK().setRootCauseTypeId(rootCause.getRootCauseType().getId()); - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - RootCauseType rootCauseType = rootCause.getRootCauseType(); - if (rootCauseType != null) { - rootCauseType = em.getReference(rootCauseType.getClass(), rootCauseType.getId()); - rootCause.setRootCauseType(rootCauseType); - } - List attachedVmUserList = new ArrayList(); - for (VmUser vmUserListVmUserToAttach : rootCause.getVmUserList()) { - vmUserListVmUserToAttach = em.getReference(vmUserListVmUserToAttach.getClass(), vmUserListVmUserToAttach.getId()); - attachedVmUserList.add(vmUserListVmUserToAttach); - } - rootCause.setVmUserList(attachedVmUserList); - List attachedExceptionHasRootCauseList = new ArrayList(); - for (ExceptionHasRootCause exceptionHasRootCauseListExceptionHasRootCauseToAttach : rootCause.getExceptionHasRootCauseList()) { - exceptionHasRootCauseListExceptionHasRootCauseToAttach = em.getReference(exceptionHasRootCauseListExceptionHasRootCauseToAttach.getClass(), exceptionHasRootCauseListExceptionHasRootCauseToAttach.getExceptionHasRootCausePK()); - attachedExceptionHasRootCauseList.add(exceptionHasRootCauseListExceptionHasRootCauseToAttach); - } - rootCause.setExceptionHasRootCauseList(attachedExceptionHasRootCauseList); - em.persist(rootCause); - if (rootCauseType != null) { - rootCauseType.getRootCauseList().add(rootCause); - rootCauseType = em.merge(rootCauseType); - } - for (VmUser vmUserListVmUser : rootCause.getVmUserList()) { - vmUserListVmUser.getRootCauseList().add(rootCause); - vmUserListVmUser = em.merge(vmUserListVmUser); - } - for (ExceptionHasRootCause exceptionHasRootCauseListExceptionHasRootCause : rootCause.getExceptionHasRootCauseList()) { - RootCause oldRootCauseOfExceptionHasRootCauseListExceptionHasRootCause = exceptionHasRootCauseListExceptionHasRootCause.getRootCause(); - exceptionHasRootCauseListExceptionHasRootCause.setRootCause(rootCause); - exceptionHasRootCauseListExceptionHasRootCause = em.merge(exceptionHasRootCauseListExceptionHasRootCause); - if (oldRootCauseOfExceptionHasRootCauseListExceptionHasRootCause != null) { - oldRootCauseOfExceptionHasRootCauseListExceptionHasRootCause.getExceptionHasRootCauseList().remove(exceptionHasRootCauseListExceptionHasRootCause); - oldRootCauseOfExceptionHasRootCauseListExceptionHasRootCause = em.merge(oldRootCauseOfExceptionHasRootCauseListExceptionHasRootCause); - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - if (findRootCause(rootCause.getRootCausePK()) != null) { - throw new PreexistingEntityException("RootCause " + rootCause + " already exists.", ex); - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(RootCause rootCause) throws IllegalOrphanException, NonexistentEntityException, Exception { - rootCause.getRootCausePK().setRootCauseTypeId(rootCause.getRootCauseType().getId()); - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - RootCause persistentRootCause = em.find(RootCause.class, rootCause.getRootCausePK()); - RootCauseType rootCauseTypeOld = persistentRootCause.getRootCauseType(); - RootCauseType rootCauseTypeNew = rootCause.getRootCauseType(); - List vmUserListOld = persistentRootCause.getVmUserList(); - List vmUserListNew = rootCause.getVmUserList(); - List exceptionHasRootCauseListOld = persistentRootCause.getExceptionHasRootCauseList(); - List exceptionHasRootCauseListNew = rootCause.getExceptionHasRootCauseList(); - List illegalOrphanMessages = null; - for (ExceptionHasRootCause exceptionHasRootCauseListOldExceptionHasRootCause : exceptionHasRootCauseListOld) { - if (!exceptionHasRootCauseListNew.contains(exceptionHasRootCauseListOldExceptionHasRootCause)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain ExceptionHasRootCause " + exceptionHasRootCauseListOldExceptionHasRootCause + " since its rootCause field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - if (rootCauseTypeNew != null) { - rootCauseTypeNew = em.getReference(rootCauseTypeNew.getClass(), rootCauseTypeNew.getId()); - rootCause.setRootCauseType(rootCauseTypeNew); - } - List attachedVmUserListNew = new ArrayList(); - for (VmUser vmUserListNewVmUserToAttach : vmUserListNew) { - vmUserListNewVmUserToAttach = em.getReference(vmUserListNewVmUserToAttach.getClass(), vmUserListNewVmUserToAttach.getId()); - attachedVmUserListNew.add(vmUserListNewVmUserToAttach); - } - vmUserListNew = attachedVmUserListNew; - rootCause.setVmUserList(vmUserListNew); - List attachedExceptionHasRootCauseListNew = new ArrayList(); - for (ExceptionHasRootCause exceptionHasRootCauseListNewExceptionHasRootCauseToAttach : exceptionHasRootCauseListNew) { - exceptionHasRootCauseListNewExceptionHasRootCauseToAttach = em.getReference(exceptionHasRootCauseListNewExceptionHasRootCauseToAttach.getClass(), exceptionHasRootCauseListNewExceptionHasRootCauseToAttach.getExceptionHasRootCausePK()); - attachedExceptionHasRootCauseListNew.add(exceptionHasRootCauseListNewExceptionHasRootCauseToAttach); - } - exceptionHasRootCauseListNew = attachedExceptionHasRootCauseListNew; - rootCause.setExceptionHasRootCauseList(exceptionHasRootCauseListNew); - rootCause = em.merge(rootCause); - if (rootCauseTypeOld != null && !rootCauseTypeOld.equals(rootCauseTypeNew)) { - rootCauseTypeOld.getRootCauseList().remove(rootCause); - rootCauseTypeOld = em.merge(rootCauseTypeOld); - } - if (rootCauseTypeNew != null && !rootCauseTypeNew.equals(rootCauseTypeOld)) { - rootCauseTypeNew.getRootCauseList().add(rootCause); - rootCauseTypeNew = em.merge(rootCauseTypeNew); - } - for (VmUser vmUserListOldVmUser : vmUserListOld) { - if (!vmUserListNew.contains(vmUserListOldVmUser)) { - vmUserListOldVmUser.getRootCauseList().remove(rootCause); - vmUserListOldVmUser = em.merge(vmUserListOldVmUser); - } - } - for (VmUser vmUserListNewVmUser : vmUserListNew) { - if (!vmUserListOld.contains(vmUserListNewVmUser)) { - vmUserListNewVmUser.getRootCauseList().add(rootCause); - vmUserListNewVmUser = em.merge(vmUserListNewVmUser); - } - } - for (ExceptionHasRootCause exceptionHasRootCauseListNewExceptionHasRootCause : exceptionHasRootCauseListNew) { - if (!exceptionHasRootCauseListOld.contains(exceptionHasRootCauseListNewExceptionHasRootCause)) { - RootCause oldRootCauseOfExceptionHasRootCauseListNewExceptionHasRootCause = exceptionHasRootCauseListNewExceptionHasRootCause.getRootCause(); - exceptionHasRootCauseListNewExceptionHasRootCause.setRootCause(rootCause); - exceptionHasRootCauseListNewExceptionHasRootCause = em.merge(exceptionHasRootCauseListNewExceptionHasRootCause); - if (oldRootCauseOfExceptionHasRootCauseListNewExceptionHasRootCause != null && !oldRootCauseOfExceptionHasRootCauseListNewExceptionHasRootCause.equals(rootCause)) { - oldRootCauseOfExceptionHasRootCauseListNewExceptionHasRootCause.getExceptionHasRootCauseList().remove(exceptionHasRootCauseListNewExceptionHasRootCause); - oldRootCauseOfExceptionHasRootCauseListNewExceptionHasRootCause = em.merge(oldRootCauseOfExceptionHasRootCauseListNewExceptionHasRootCause); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - RootCausePK id = rootCause.getRootCausePK(); - if (findRootCause(id) == null) { - throw new NonexistentEntityException("The rootCause with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(RootCausePK id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - RootCause rootCause; - try { - rootCause = em.getReference(RootCause.class, id); - rootCause.getRootCausePK(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The rootCause with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List exceptionHasRootCauseListOrphanCheck = rootCause.getExceptionHasRootCauseList(); - for (ExceptionHasRootCause exceptionHasRootCauseListOrphanCheckExceptionHasRootCause : exceptionHasRootCauseListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This RootCause (" + rootCause + ") cannot be destroyed since the ExceptionHasRootCause " + exceptionHasRootCauseListOrphanCheckExceptionHasRootCause + " in its exceptionHasRootCauseList field has a non-nullable rootCause field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - RootCauseType rootCauseType = rootCause.getRootCauseType(); - if (rootCauseType != null) { - rootCauseType.getRootCauseList().remove(rootCause); - rootCauseType = em.merge(rootCauseType); - } - List vmUserList = rootCause.getVmUserList(); - for (VmUser vmUserListVmUser : vmUserList) { - vmUserListVmUser.getRootCauseList().remove(rootCause); - vmUserListVmUser = em.merge(vmUserListVmUser); - } - em.remove(rootCause); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findRootCauseEntities() { - return findRootCauseEntities(true, -1, -1); - } - - public List findRootCauseEntities(int maxResults, int firstResult) { - return findRootCauseEntities(false, maxResults, firstResult); - } - - private List findRootCauseEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(RootCause.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public RootCause findRootCause(RootCausePK id) { - EntityManager em = getEntityManager(); - try { - return em.find(RootCause.class, id); - } - finally { - em.close(); - } - } - - public int getRootCauseCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(RootCause.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.RootCauseType; +import com.validation.manager.core.db.VmUser; +import java.util.ArrayList; +import java.util.List; +import com.validation.manager.core.db.ExceptionHasRootCause; +import com.validation.manager.core.db.RootCause; +import com.validation.manager.core.db.RootCausePK; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import com.validation.manager.core.db.controller.exceptions.PreexistingEntityException; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class RootCauseJpaController implements Serializable { + + public RootCauseJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(RootCause rootCause) throws PreexistingEntityException, Exception { + if (rootCause.getRootCausePK() == null) { + rootCause.setRootCausePK(new RootCausePK()); + } + if (rootCause.getVmUserList() == null) { + rootCause.setVmUserList(new ArrayList<>()); + } + if (rootCause.getExceptionHasRootCauseList() == null) { + rootCause.setExceptionHasRootCauseList(new ArrayList<>()); + } + rootCause.getRootCausePK().setRootCauseTypeId(rootCause.getRootCauseType().getId()); + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + RootCauseType rootCauseType = rootCause.getRootCauseType(); + if (rootCauseType != null) { + rootCauseType = em.getReference(rootCauseType.getClass(), rootCauseType.getId()); + rootCause.setRootCauseType(rootCauseType); + } + List attachedVmUserList = new ArrayList<>(); + for (VmUser vmUserListVmUserToAttach : rootCause.getVmUserList()) { + vmUserListVmUserToAttach = em.getReference(vmUserListVmUserToAttach.getClass(), vmUserListVmUserToAttach.getId()); + attachedVmUserList.add(vmUserListVmUserToAttach); + } + rootCause.setVmUserList(attachedVmUserList); + List attachedExceptionHasRootCauseList = new ArrayList<>(); + for (ExceptionHasRootCause exceptionHasRootCauseListExceptionHasRootCauseToAttach : rootCause.getExceptionHasRootCauseList()) { + exceptionHasRootCauseListExceptionHasRootCauseToAttach = em.getReference(exceptionHasRootCauseListExceptionHasRootCauseToAttach.getClass(), exceptionHasRootCauseListExceptionHasRootCauseToAttach.getExceptionHasRootCausePK()); + attachedExceptionHasRootCauseList.add(exceptionHasRootCauseListExceptionHasRootCauseToAttach); + } + rootCause.setExceptionHasRootCauseList(attachedExceptionHasRootCauseList); + em.persist(rootCause); + if (rootCauseType != null) { + rootCauseType.getRootCauseList().add(rootCause); + rootCauseType = em.merge(rootCauseType); + } + for (VmUser vmUserListVmUser : rootCause.getVmUserList()) { + vmUserListVmUser.getRootCauseList().add(rootCause); + vmUserListVmUser = em.merge(vmUserListVmUser); + } + for (ExceptionHasRootCause exceptionHasRootCauseListExceptionHasRootCause : rootCause.getExceptionHasRootCauseList()) { + RootCause oldRootCauseOfExceptionHasRootCauseListExceptionHasRootCause = exceptionHasRootCauseListExceptionHasRootCause.getRootCause(); + exceptionHasRootCauseListExceptionHasRootCause.setRootCause(rootCause); + exceptionHasRootCauseListExceptionHasRootCause = em.merge(exceptionHasRootCauseListExceptionHasRootCause); + if (oldRootCauseOfExceptionHasRootCauseListExceptionHasRootCause != null) { + oldRootCauseOfExceptionHasRootCauseListExceptionHasRootCause.getExceptionHasRootCauseList().remove(exceptionHasRootCauseListExceptionHasRootCause); + oldRootCauseOfExceptionHasRootCauseListExceptionHasRootCause = em.merge(oldRootCauseOfExceptionHasRootCauseListExceptionHasRootCause); + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + if (findRootCause(rootCause.getRootCausePK()) != null) { + throw new PreexistingEntityException("RootCause " + rootCause + " already exists.", ex); + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(RootCause rootCause) throws IllegalOrphanException, NonexistentEntityException, Exception { + rootCause.getRootCausePK().setRootCauseTypeId(rootCause.getRootCauseType().getId()); + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + RootCause persistentRootCause = em.find(RootCause.class, rootCause.getRootCausePK()); + RootCauseType rootCauseTypeOld = persistentRootCause.getRootCauseType(); + RootCauseType rootCauseTypeNew = rootCause.getRootCauseType(); + List vmUserListOld = persistentRootCause.getVmUserList(); + List vmUserListNew = rootCause.getVmUserList(); + List exceptionHasRootCauseListOld = persistentRootCause.getExceptionHasRootCauseList(); + List exceptionHasRootCauseListNew = rootCause.getExceptionHasRootCauseList(); + List illegalOrphanMessages = null; + for (ExceptionHasRootCause exceptionHasRootCauseListOldExceptionHasRootCause : exceptionHasRootCauseListOld) { + if (!exceptionHasRootCauseListNew.contains(exceptionHasRootCauseListOldExceptionHasRootCause)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain ExceptionHasRootCause " + exceptionHasRootCauseListOldExceptionHasRootCause + " since its rootCause field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + if (rootCauseTypeNew != null) { + rootCauseTypeNew = em.getReference(rootCauseTypeNew.getClass(), rootCauseTypeNew.getId()); + rootCause.setRootCauseType(rootCauseTypeNew); + } + List attachedVmUserListNew = new ArrayList<>(); + for (VmUser vmUserListNewVmUserToAttach : vmUserListNew) { + vmUserListNewVmUserToAttach = em.getReference(vmUserListNewVmUserToAttach.getClass(), vmUserListNewVmUserToAttach.getId()); + attachedVmUserListNew.add(vmUserListNewVmUserToAttach); + } + vmUserListNew = attachedVmUserListNew; + rootCause.setVmUserList(vmUserListNew); + List attachedExceptionHasRootCauseListNew = new ArrayList<>(); + for (ExceptionHasRootCause exceptionHasRootCauseListNewExceptionHasRootCauseToAttach : exceptionHasRootCauseListNew) { + exceptionHasRootCauseListNewExceptionHasRootCauseToAttach = em.getReference(exceptionHasRootCauseListNewExceptionHasRootCauseToAttach.getClass(), exceptionHasRootCauseListNewExceptionHasRootCauseToAttach.getExceptionHasRootCausePK()); + attachedExceptionHasRootCauseListNew.add(exceptionHasRootCauseListNewExceptionHasRootCauseToAttach); + } + exceptionHasRootCauseListNew = attachedExceptionHasRootCauseListNew; + rootCause.setExceptionHasRootCauseList(exceptionHasRootCauseListNew); + rootCause = em.merge(rootCause); + if (rootCauseTypeOld != null && !rootCauseTypeOld.equals(rootCauseTypeNew)) { + rootCauseTypeOld.getRootCauseList().remove(rootCause); + rootCauseTypeOld = em.merge(rootCauseTypeOld); + } + if (rootCauseTypeNew != null && !rootCauseTypeNew.equals(rootCauseTypeOld)) { + rootCauseTypeNew.getRootCauseList().add(rootCause); + rootCauseTypeNew = em.merge(rootCauseTypeNew); + } + for (VmUser vmUserListOldVmUser : vmUserListOld) { + if (!vmUserListNew.contains(vmUserListOldVmUser)) { + vmUserListOldVmUser.getRootCauseList().remove(rootCause); + vmUserListOldVmUser = em.merge(vmUserListOldVmUser); + } + } + for (VmUser vmUserListNewVmUser : vmUserListNew) { + if (!vmUserListOld.contains(vmUserListNewVmUser)) { + vmUserListNewVmUser.getRootCauseList().add(rootCause); + vmUserListNewVmUser = em.merge(vmUserListNewVmUser); + } + } + for (ExceptionHasRootCause exceptionHasRootCauseListNewExceptionHasRootCause : exceptionHasRootCauseListNew) { + if (!exceptionHasRootCauseListOld.contains(exceptionHasRootCauseListNewExceptionHasRootCause)) { + RootCause oldRootCauseOfExceptionHasRootCauseListNewExceptionHasRootCause = exceptionHasRootCauseListNewExceptionHasRootCause.getRootCause(); + exceptionHasRootCauseListNewExceptionHasRootCause.setRootCause(rootCause); + exceptionHasRootCauseListNewExceptionHasRootCause = em.merge(exceptionHasRootCauseListNewExceptionHasRootCause); + if (oldRootCauseOfExceptionHasRootCauseListNewExceptionHasRootCause != null && !oldRootCauseOfExceptionHasRootCauseListNewExceptionHasRootCause.equals(rootCause)) { + oldRootCauseOfExceptionHasRootCauseListNewExceptionHasRootCause.getExceptionHasRootCauseList().remove(exceptionHasRootCauseListNewExceptionHasRootCause); + oldRootCauseOfExceptionHasRootCauseListNewExceptionHasRootCause = em.merge(oldRootCauseOfExceptionHasRootCauseListNewExceptionHasRootCause); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + RootCausePK id = rootCause.getRootCausePK(); + if (findRootCause(id) == null) { + throw new NonexistentEntityException("The rootCause with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(RootCausePK id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + RootCause rootCause; + try { + rootCause = em.getReference(RootCause.class, id); + rootCause.getRootCausePK(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The rootCause with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List exceptionHasRootCauseListOrphanCheck = rootCause.getExceptionHasRootCauseList(); + for (ExceptionHasRootCause exceptionHasRootCauseListOrphanCheckExceptionHasRootCause : exceptionHasRootCauseListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This RootCause (" + rootCause + ") cannot be destroyed since the ExceptionHasRootCause " + exceptionHasRootCauseListOrphanCheckExceptionHasRootCause + " in its exceptionHasRootCauseList field has a non-nullable rootCause field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + RootCauseType rootCauseType = rootCause.getRootCauseType(); + if (rootCauseType != null) { + rootCauseType.getRootCauseList().remove(rootCause); + rootCauseType = em.merge(rootCauseType); + } + List vmUserList = rootCause.getVmUserList(); + for (VmUser vmUserListVmUser : vmUserList) { + vmUserListVmUser.getRootCauseList().remove(rootCause); + vmUserListVmUser = em.merge(vmUserListVmUser); + } + em.remove(rootCause); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findRootCauseEntities() { + return findRootCauseEntities(true, -1, -1); + } + + public List findRootCauseEntities(int maxResults, int firstResult) { + return findRootCauseEntities(false, maxResults, firstResult); + } + + private List findRootCauseEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(RootCause.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public RootCause findRootCause(RootCausePK id) { + EntityManager em = getEntityManager(); + try { + return em.find(RootCause.class, id); + } + finally { + em.close(); + } + } + + public int getRootCauseCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(RootCause.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/RootCauseTypeJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/RootCauseTypeJpaController.java index 863498ef..d4b19ace 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/RootCauseTypeJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/RootCauseTypeJpaController.java @@ -13,209 +13,209 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.RootCause; -import com.validation.manager.core.db.RootCauseType; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import java.util.ArrayList; -import java.util.List; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class RootCauseTypeJpaController implements Serializable { - - public RootCauseTypeJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(RootCauseType rootCauseType) { - if (rootCauseType.getRootCauseList() == null) { - rootCauseType.setRootCauseList(new ArrayList()); - } - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - List attachedRootCauseList = new ArrayList(); - for (RootCause rootCauseListRootCauseToAttach : rootCauseType.getRootCauseList()) { - rootCauseListRootCauseToAttach = em.getReference(rootCauseListRootCauseToAttach.getClass(), rootCauseListRootCauseToAttach.getRootCausePK()); - attachedRootCauseList.add(rootCauseListRootCauseToAttach); - } - rootCauseType.setRootCauseList(attachedRootCauseList); - em.persist(rootCauseType); - for (RootCause rootCauseListRootCause : rootCauseType.getRootCauseList()) { - RootCauseType oldRootCauseTypeOfRootCauseListRootCause = rootCauseListRootCause.getRootCauseType(); - rootCauseListRootCause.setRootCauseType(rootCauseType); - rootCauseListRootCause = em.merge(rootCauseListRootCause); - if (oldRootCauseTypeOfRootCauseListRootCause != null) { - oldRootCauseTypeOfRootCauseListRootCause.getRootCauseList().remove(rootCauseListRootCause); - oldRootCauseTypeOfRootCauseListRootCause = em.merge(oldRootCauseTypeOfRootCauseListRootCause); - } - } - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(RootCauseType rootCauseType) throws IllegalOrphanException, NonexistentEntityException, Exception { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - RootCauseType persistentRootCauseType = em.find(RootCauseType.class, rootCauseType.getId()); - List rootCauseListOld = persistentRootCauseType.getRootCauseList(); - List rootCauseListNew = rootCauseType.getRootCauseList(); - List illegalOrphanMessages = null; - for (RootCause rootCauseListOldRootCause : rootCauseListOld) { - if (!rootCauseListNew.contains(rootCauseListOldRootCause)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain RootCause " + rootCauseListOldRootCause + " since its rootCauseType field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - List attachedRootCauseListNew = new ArrayList(); - for (RootCause rootCauseListNewRootCauseToAttach : rootCauseListNew) { - rootCauseListNewRootCauseToAttach = em.getReference(rootCauseListNewRootCauseToAttach.getClass(), rootCauseListNewRootCauseToAttach.getRootCausePK()); - attachedRootCauseListNew.add(rootCauseListNewRootCauseToAttach); - } - rootCauseListNew = attachedRootCauseListNew; - rootCauseType.setRootCauseList(rootCauseListNew); - rootCauseType = em.merge(rootCauseType); - for (RootCause rootCauseListNewRootCause : rootCauseListNew) { - if (!rootCauseListOld.contains(rootCauseListNewRootCause)) { - RootCauseType oldRootCauseTypeOfRootCauseListNewRootCause = rootCauseListNewRootCause.getRootCauseType(); - rootCauseListNewRootCause.setRootCauseType(rootCauseType); - rootCauseListNewRootCause = em.merge(rootCauseListNewRootCause); - if (oldRootCauseTypeOfRootCauseListNewRootCause != null && !oldRootCauseTypeOfRootCauseListNewRootCause.equals(rootCauseType)) { - oldRootCauseTypeOfRootCauseListNewRootCause.getRootCauseList().remove(rootCauseListNewRootCause); - oldRootCauseTypeOfRootCauseListNewRootCause = em.merge(oldRootCauseTypeOfRootCauseListNewRootCause); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - Integer id = rootCauseType.getId(); - if (findRootCauseType(id) == null) { - throw new NonexistentEntityException("The rootCauseType with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - RootCauseType rootCauseType; - try { - rootCauseType = em.getReference(RootCauseType.class, id); - rootCauseType.getId(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The rootCauseType with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List rootCauseListOrphanCheck = rootCauseType.getRootCauseList(); - for (RootCause rootCauseListOrphanCheckRootCause : rootCauseListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This RootCauseType (" + rootCauseType + ") cannot be destroyed since the RootCause " + rootCauseListOrphanCheckRootCause + " in its rootCauseList field has a non-nullable rootCauseType field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - em.remove(rootCauseType); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findRootCauseTypeEntities() { - return findRootCauseTypeEntities(true, -1, -1); - } - - public List findRootCauseTypeEntities(int maxResults, int firstResult) { - return findRootCauseTypeEntities(false, maxResults, firstResult); - } - - private List findRootCauseTypeEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(RootCauseType.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public RootCauseType findRootCauseType(Integer id) { - EntityManager em = getEntityManager(); - try { - return em.find(RootCauseType.class, id); - } - finally { - em.close(); - } - } - - public int getRootCauseTypeCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(RootCauseType.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.RootCause; +import com.validation.manager.core.db.RootCauseType; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import java.util.ArrayList; +import java.util.List; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class RootCauseTypeJpaController implements Serializable { + + public RootCauseTypeJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(RootCauseType rootCauseType) { + if (rootCauseType.getRootCauseList() == null) { + rootCauseType.setRootCauseList(new ArrayList<>()); + } + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + List attachedRootCauseList = new ArrayList<>(); + for (RootCause rootCauseListRootCauseToAttach : rootCauseType.getRootCauseList()) { + rootCauseListRootCauseToAttach = em.getReference(rootCauseListRootCauseToAttach.getClass(), rootCauseListRootCauseToAttach.getRootCausePK()); + attachedRootCauseList.add(rootCauseListRootCauseToAttach); + } + rootCauseType.setRootCauseList(attachedRootCauseList); + em.persist(rootCauseType); + for (RootCause rootCauseListRootCause : rootCauseType.getRootCauseList()) { + RootCauseType oldRootCauseTypeOfRootCauseListRootCause = rootCauseListRootCause.getRootCauseType(); + rootCauseListRootCause.setRootCauseType(rootCauseType); + rootCauseListRootCause = em.merge(rootCauseListRootCause); + if (oldRootCauseTypeOfRootCauseListRootCause != null) { + oldRootCauseTypeOfRootCauseListRootCause.getRootCauseList().remove(rootCauseListRootCause); + oldRootCauseTypeOfRootCauseListRootCause = em.merge(oldRootCauseTypeOfRootCauseListRootCause); + } + } + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(RootCauseType rootCauseType) throws IllegalOrphanException, NonexistentEntityException, Exception { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + RootCauseType persistentRootCauseType = em.find(RootCauseType.class, rootCauseType.getId()); + List rootCauseListOld = persistentRootCauseType.getRootCauseList(); + List rootCauseListNew = rootCauseType.getRootCauseList(); + List illegalOrphanMessages = null; + for (RootCause rootCauseListOldRootCause : rootCauseListOld) { + if (!rootCauseListNew.contains(rootCauseListOldRootCause)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain RootCause " + rootCauseListOldRootCause + " since its rootCauseType field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + List attachedRootCauseListNew = new ArrayList<>(); + for (RootCause rootCauseListNewRootCauseToAttach : rootCauseListNew) { + rootCauseListNewRootCauseToAttach = em.getReference(rootCauseListNewRootCauseToAttach.getClass(), rootCauseListNewRootCauseToAttach.getRootCausePK()); + attachedRootCauseListNew.add(rootCauseListNewRootCauseToAttach); + } + rootCauseListNew = attachedRootCauseListNew; + rootCauseType.setRootCauseList(rootCauseListNew); + rootCauseType = em.merge(rootCauseType); + for (RootCause rootCauseListNewRootCause : rootCauseListNew) { + if (!rootCauseListOld.contains(rootCauseListNewRootCause)) { + RootCauseType oldRootCauseTypeOfRootCauseListNewRootCause = rootCauseListNewRootCause.getRootCauseType(); + rootCauseListNewRootCause.setRootCauseType(rootCauseType); + rootCauseListNewRootCause = em.merge(rootCauseListNewRootCause); + if (oldRootCauseTypeOfRootCauseListNewRootCause != null && !oldRootCauseTypeOfRootCauseListNewRootCause.equals(rootCauseType)) { + oldRootCauseTypeOfRootCauseListNewRootCause.getRootCauseList().remove(rootCauseListNewRootCause); + oldRootCauseTypeOfRootCauseListNewRootCause = em.merge(oldRootCauseTypeOfRootCauseListNewRootCause); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + Integer id = rootCauseType.getId(); + if (findRootCauseType(id) == null) { + throw new NonexistentEntityException("The rootCauseType with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + RootCauseType rootCauseType; + try { + rootCauseType = em.getReference(RootCauseType.class, id); + rootCauseType.getId(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The rootCauseType with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List rootCauseListOrphanCheck = rootCauseType.getRootCauseList(); + for (RootCause rootCauseListOrphanCheckRootCause : rootCauseListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This RootCauseType (" + rootCauseType + ") cannot be destroyed since the RootCause " + rootCauseListOrphanCheckRootCause + " in its rootCauseList field has a non-nullable rootCauseType field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + em.remove(rootCauseType); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findRootCauseTypeEntities() { + return findRootCauseTypeEntities(true, -1, -1); + } + + public List findRootCauseTypeEntities(int maxResults, int firstResult) { + return findRootCauseTypeEntities(false, maxResults, firstResult); + } + + private List findRootCauseTypeEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(RootCauseType.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public RootCauseType findRootCauseType(Integer id) { + EntityManager em = getEntityManager(); + try { + return em.find(RootCauseType.class, id); + } + finally { + em.close(); + } + } + + public int getRootCauseTypeCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(RootCauseType.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/SpecLevelJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/SpecLevelJpaController.java index 2ba104bb..11ac0b54 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/SpecLevelJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/SpecLevelJpaController.java @@ -13,209 +13,209 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.RequirementSpec; -import com.validation.manager.core.db.SpecLevel; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import java.util.ArrayList; -import java.util.List; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class SpecLevelJpaController implements Serializable { - - public SpecLevelJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(SpecLevel specLevel) { - if (specLevel.getRequirementSpecList() == null) { - specLevel.setRequirementSpecList(new ArrayList()); - } - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - List attachedRequirementSpecList = new ArrayList(); - for (RequirementSpec requirementSpecListRequirementSpecToAttach : specLevel.getRequirementSpecList()) { - requirementSpecListRequirementSpecToAttach = em.getReference(requirementSpecListRequirementSpecToAttach.getClass(), requirementSpecListRequirementSpecToAttach.getRequirementSpecPK()); - attachedRequirementSpecList.add(requirementSpecListRequirementSpecToAttach); - } - specLevel.setRequirementSpecList(attachedRequirementSpecList); - em.persist(specLevel); - for (RequirementSpec requirementSpecListRequirementSpec : specLevel.getRequirementSpecList()) { - SpecLevel oldSpecLevelOfRequirementSpecListRequirementSpec = requirementSpecListRequirementSpec.getSpecLevel(); - requirementSpecListRequirementSpec.setSpecLevel(specLevel); - requirementSpecListRequirementSpec = em.merge(requirementSpecListRequirementSpec); - if (oldSpecLevelOfRequirementSpecListRequirementSpec != null) { - oldSpecLevelOfRequirementSpecListRequirementSpec.getRequirementSpecList().remove(requirementSpecListRequirementSpec); - oldSpecLevelOfRequirementSpecListRequirementSpec = em.merge(oldSpecLevelOfRequirementSpecListRequirementSpec); - } - } - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(SpecLevel specLevel) throws IllegalOrphanException, NonexistentEntityException, Exception { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - SpecLevel persistentSpecLevel = em.find(SpecLevel.class, specLevel.getId()); - List requirementSpecListOld = persistentSpecLevel.getRequirementSpecList(); - List requirementSpecListNew = specLevel.getRequirementSpecList(); - List illegalOrphanMessages = null; - for (RequirementSpec requirementSpecListOldRequirementSpec : requirementSpecListOld) { - if (!requirementSpecListNew.contains(requirementSpecListOldRequirementSpec)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain RequirementSpec " + requirementSpecListOldRequirementSpec + " since its specLevel field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - List attachedRequirementSpecListNew = new ArrayList(); - for (RequirementSpec requirementSpecListNewRequirementSpecToAttach : requirementSpecListNew) { - requirementSpecListNewRequirementSpecToAttach = em.getReference(requirementSpecListNewRequirementSpecToAttach.getClass(), requirementSpecListNewRequirementSpecToAttach.getRequirementSpecPK()); - attachedRequirementSpecListNew.add(requirementSpecListNewRequirementSpecToAttach); - } - requirementSpecListNew = attachedRequirementSpecListNew; - specLevel.setRequirementSpecList(requirementSpecListNew); - specLevel = em.merge(specLevel); - for (RequirementSpec requirementSpecListNewRequirementSpec : requirementSpecListNew) { - if (!requirementSpecListOld.contains(requirementSpecListNewRequirementSpec)) { - SpecLevel oldSpecLevelOfRequirementSpecListNewRequirementSpec = requirementSpecListNewRequirementSpec.getSpecLevel(); - requirementSpecListNewRequirementSpec.setSpecLevel(specLevel); - requirementSpecListNewRequirementSpec = em.merge(requirementSpecListNewRequirementSpec); - if (oldSpecLevelOfRequirementSpecListNewRequirementSpec != null && !oldSpecLevelOfRequirementSpecListNewRequirementSpec.equals(specLevel)) { - oldSpecLevelOfRequirementSpecListNewRequirementSpec.getRequirementSpecList().remove(requirementSpecListNewRequirementSpec); - oldSpecLevelOfRequirementSpecListNewRequirementSpec = em.merge(oldSpecLevelOfRequirementSpecListNewRequirementSpec); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - Integer id = specLevel.getId(); - if (findSpecLevel(id) == null) { - throw new NonexistentEntityException("The specLevel with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - SpecLevel specLevel; - try { - specLevel = em.getReference(SpecLevel.class, id); - specLevel.getId(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The specLevel with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List requirementSpecListOrphanCheck = specLevel.getRequirementSpecList(); - for (RequirementSpec requirementSpecListOrphanCheckRequirementSpec : requirementSpecListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This SpecLevel (" + specLevel + ") cannot be destroyed since the RequirementSpec " + requirementSpecListOrphanCheckRequirementSpec + " in its requirementSpecList field has a non-nullable specLevel field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - em.remove(specLevel); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findSpecLevelEntities() { - return findSpecLevelEntities(true, -1, -1); - } - - public List findSpecLevelEntities(int maxResults, int firstResult) { - return findSpecLevelEntities(false, maxResults, firstResult); - } - - private List findSpecLevelEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(SpecLevel.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public SpecLevel findSpecLevel(Integer id) { - EntityManager em = getEntityManager(); - try { - return em.find(SpecLevel.class, id); - } - finally { - em.close(); - } - } - - public int getSpecLevelCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(SpecLevel.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.RequirementSpec; +import com.validation.manager.core.db.SpecLevel; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import java.util.ArrayList; +import java.util.List; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class SpecLevelJpaController implements Serializable { + + public SpecLevelJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(SpecLevel specLevel) { + if (specLevel.getRequirementSpecList() == null) { + specLevel.setRequirementSpecList(new ArrayList<>()); + } + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + List attachedRequirementSpecList = new ArrayList<>(); + for (RequirementSpec requirementSpecListRequirementSpecToAttach : specLevel.getRequirementSpecList()) { + requirementSpecListRequirementSpecToAttach = em.getReference(requirementSpecListRequirementSpecToAttach.getClass(), requirementSpecListRequirementSpecToAttach.getRequirementSpecPK()); + attachedRequirementSpecList.add(requirementSpecListRequirementSpecToAttach); + } + specLevel.setRequirementSpecList(attachedRequirementSpecList); + em.persist(specLevel); + for (RequirementSpec requirementSpecListRequirementSpec : specLevel.getRequirementSpecList()) { + SpecLevel oldSpecLevelOfRequirementSpecListRequirementSpec = requirementSpecListRequirementSpec.getSpecLevel(); + requirementSpecListRequirementSpec.setSpecLevel(specLevel); + requirementSpecListRequirementSpec = em.merge(requirementSpecListRequirementSpec); + if (oldSpecLevelOfRequirementSpecListRequirementSpec != null) { + oldSpecLevelOfRequirementSpecListRequirementSpec.getRequirementSpecList().remove(requirementSpecListRequirementSpec); + oldSpecLevelOfRequirementSpecListRequirementSpec = em.merge(oldSpecLevelOfRequirementSpecListRequirementSpec); + } + } + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(SpecLevel specLevel) throws IllegalOrphanException, NonexistentEntityException, Exception { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + SpecLevel persistentSpecLevel = em.find(SpecLevel.class, specLevel.getId()); + List requirementSpecListOld = persistentSpecLevel.getRequirementSpecList(); + List requirementSpecListNew = specLevel.getRequirementSpecList(); + List illegalOrphanMessages = null; + for (RequirementSpec requirementSpecListOldRequirementSpec : requirementSpecListOld) { + if (!requirementSpecListNew.contains(requirementSpecListOldRequirementSpec)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain RequirementSpec " + requirementSpecListOldRequirementSpec + " since its specLevel field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + List attachedRequirementSpecListNew = new ArrayList<>(); + for (RequirementSpec requirementSpecListNewRequirementSpecToAttach : requirementSpecListNew) { + requirementSpecListNewRequirementSpecToAttach = em.getReference(requirementSpecListNewRequirementSpecToAttach.getClass(), requirementSpecListNewRequirementSpecToAttach.getRequirementSpecPK()); + attachedRequirementSpecListNew.add(requirementSpecListNewRequirementSpecToAttach); + } + requirementSpecListNew = attachedRequirementSpecListNew; + specLevel.setRequirementSpecList(requirementSpecListNew); + specLevel = em.merge(specLevel); + for (RequirementSpec requirementSpecListNewRequirementSpec : requirementSpecListNew) { + if (!requirementSpecListOld.contains(requirementSpecListNewRequirementSpec)) { + SpecLevel oldSpecLevelOfRequirementSpecListNewRequirementSpec = requirementSpecListNewRequirementSpec.getSpecLevel(); + requirementSpecListNewRequirementSpec.setSpecLevel(specLevel); + requirementSpecListNewRequirementSpec = em.merge(requirementSpecListNewRequirementSpec); + if (oldSpecLevelOfRequirementSpecListNewRequirementSpec != null && !oldSpecLevelOfRequirementSpecListNewRequirementSpec.equals(specLevel)) { + oldSpecLevelOfRequirementSpecListNewRequirementSpec.getRequirementSpecList().remove(requirementSpecListNewRequirementSpec); + oldSpecLevelOfRequirementSpecListNewRequirementSpec = em.merge(oldSpecLevelOfRequirementSpecListNewRequirementSpec); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + Integer id = specLevel.getId(); + if (findSpecLevel(id) == null) { + throw new NonexistentEntityException("The specLevel with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + SpecLevel specLevel; + try { + specLevel = em.getReference(SpecLevel.class, id); + specLevel.getId(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The specLevel with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List requirementSpecListOrphanCheck = specLevel.getRequirementSpecList(); + for (RequirementSpec requirementSpecListOrphanCheckRequirementSpec : requirementSpecListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This SpecLevel (" + specLevel + ") cannot be destroyed since the RequirementSpec " + requirementSpecListOrphanCheckRequirementSpec + " in its requirementSpecList field has a non-nullable specLevel field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + em.remove(specLevel); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findSpecLevelEntities() { + return findSpecLevelEntities(true, -1, -1); + } + + public List findSpecLevelEntities(int maxResults, int firstResult) { + return findSpecLevelEntities(false, maxResults, firstResult); + } + + private List findSpecLevelEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(SpecLevel.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public SpecLevel findSpecLevel(Integer id) { + EntityManager em = getEntityManager(); + try { + return em.find(SpecLevel.class, id); + } + finally { + em.close(); + } + } + + public int getSpecLevelCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(SpecLevel.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/StepJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/StepJpaController.java index 251fc57e..9dac0b91 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/StepJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/StepJpaController.java @@ -13,345 +13,345 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.TestCase; -import com.validation.manager.core.db.Requirement; -import java.util.ArrayList; -import java.util.List; -import com.validation.manager.core.db.ExecutionStep; -import com.validation.manager.core.db.History; -import com.validation.manager.core.db.Step; -import com.validation.manager.core.db.StepPK; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import com.validation.manager.core.db.controller.exceptions.PreexistingEntityException; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class StepJpaController implements Serializable { - - public StepJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(Step step) throws PreexistingEntityException, Exception { - if (step.getStepPK() == null) { - step.setStepPK(new StepPK()); - } - if (step.getRequirementList() == null) { - step.setRequirementList(new ArrayList()); - } - if (step.getExecutionStepList() == null) { - step.setExecutionStepList(new ArrayList()); - } - if (step.getHistoryList() == null) { - step.setHistoryList(new ArrayList()); - } - step.getStepPK().setTestCaseId(step.getTestCase().getId()); - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - TestCase testCase = step.getTestCase(); - if (testCase != null) { - testCase = em.getReference(testCase.getClass(), testCase.getId()); - step.setTestCase(testCase); - } - List attachedRequirementList = new ArrayList(); - for (Requirement requirementListRequirementToAttach : step.getRequirementList()) { - requirementListRequirementToAttach = em.getReference(requirementListRequirementToAttach.getClass(), requirementListRequirementToAttach.getId()); - attachedRequirementList.add(requirementListRequirementToAttach); - } - step.setRequirementList(attachedRequirementList); - List attachedExecutionStepList = new ArrayList(); - for (ExecutionStep executionStepListExecutionStepToAttach : step.getExecutionStepList()) { - executionStepListExecutionStepToAttach = em.getReference(executionStepListExecutionStepToAttach.getClass(), executionStepListExecutionStepToAttach.getExecutionStepPK()); - attachedExecutionStepList.add(executionStepListExecutionStepToAttach); - } - step.setExecutionStepList(attachedExecutionStepList); - List attachedHistoryList = new ArrayList(); - for (History historyListHistoryToAttach : step.getHistoryList()) { - historyListHistoryToAttach = em.getReference(historyListHistoryToAttach.getClass(), historyListHistoryToAttach.getId()); - attachedHistoryList.add(historyListHistoryToAttach); - } - step.setHistoryList(attachedHistoryList); - em.persist(step); - if (testCase != null) { - testCase.getStepList().add(step); - testCase = em.merge(testCase); - } - for (Requirement requirementListRequirement : step.getRequirementList()) { - requirementListRequirement.getStepList().add(step); - requirementListRequirement = em.merge(requirementListRequirement); - } - for (ExecutionStep executionStepListExecutionStep : step.getExecutionStepList()) { - Step oldStepOfExecutionStepListExecutionStep = executionStepListExecutionStep.getStep(); - executionStepListExecutionStep.setStep(step); - executionStepListExecutionStep = em.merge(executionStepListExecutionStep); - if (oldStepOfExecutionStepListExecutionStep != null) { - oldStepOfExecutionStepListExecutionStep.getExecutionStepList().remove(executionStepListExecutionStep); - oldStepOfExecutionStepListExecutionStep = em.merge(oldStepOfExecutionStepListExecutionStep); - } - } - for (History historyListHistory : step.getHistoryList()) { - Step oldStepOfHistoryListHistory = historyListHistory.getStep(); - historyListHistory.setStep(step); - historyListHistory = em.merge(historyListHistory); - if (oldStepOfHistoryListHistory != null) { - oldStepOfHistoryListHistory.getHistoryList().remove(historyListHistory); - oldStepOfHistoryListHistory = em.merge(oldStepOfHistoryListHistory); - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - if (findStep(step.getStepPK()) != null) { - throw new PreexistingEntityException("Step " + step + " already exists.", ex); - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(Step step) throws IllegalOrphanException, NonexistentEntityException, Exception { - step.getStepPK().setTestCaseId(step.getTestCase().getId()); - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - Step persistentStep = em.find(Step.class, step.getStepPK()); - TestCase testCaseOld = persistentStep.getTestCase(); - TestCase testCaseNew = step.getTestCase(); - List requirementListOld = persistentStep.getRequirementList(); - List requirementListNew = step.getRequirementList(); - List executionStepListOld = persistentStep.getExecutionStepList(); - List executionStepListNew = step.getExecutionStepList(); - List historyListOld = persistentStep.getHistoryList(); - List historyListNew = step.getHistoryList(); - List illegalOrphanMessages = null; - for (ExecutionStep executionStepListOldExecutionStep : executionStepListOld) { - if (!executionStepListNew.contains(executionStepListOldExecutionStep)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain ExecutionStep " + executionStepListOldExecutionStep + " since its step field is not nullable."); - } - } - for (History historyListOldHistory : historyListOld) { - if (!historyListNew.contains(historyListOldHistory)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain History " + historyListOldHistory + " since its step field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - if (testCaseNew != null) { - testCaseNew = em.getReference(testCaseNew.getClass(), testCaseNew.getId()); - step.setTestCase(testCaseNew); - } - List attachedRequirementListNew = new ArrayList(); - for (Requirement requirementListNewRequirementToAttach : requirementListNew) { - requirementListNewRequirementToAttach = em.getReference(requirementListNewRequirementToAttach.getClass(), requirementListNewRequirementToAttach.getId()); - attachedRequirementListNew.add(requirementListNewRequirementToAttach); - } - requirementListNew = attachedRequirementListNew; - step.setRequirementList(requirementListNew); - List attachedExecutionStepListNew = new ArrayList(); - for (ExecutionStep executionStepListNewExecutionStepToAttach : executionStepListNew) { - executionStepListNewExecutionStepToAttach = em.getReference(executionStepListNewExecutionStepToAttach.getClass(), executionStepListNewExecutionStepToAttach.getExecutionStepPK()); - attachedExecutionStepListNew.add(executionStepListNewExecutionStepToAttach); - } - executionStepListNew = attachedExecutionStepListNew; - step.setExecutionStepList(executionStepListNew); - List attachedHistoryListNew = new ArrayList(); - for (History historyListNewHistoryToAttach : historyListNew) { - historyListNewHistoryToAttach = em.getReference(historyListNewHistoryToAttach.getClass(), historyListNewHistoryToAttach.getId()); - attachedHistoryListNew.add(historyListNewHistoryToAttach); - } - historyListNew = attachedHistoryListNew; - step.setHistoryList(historyListNew); - step = em.merge(step); - if (testCaseOld != null && !testCaseOld.equals(testCaseNew)) { - testCaseOld.getStepList().remove(step); - testCaseOld = em.merge(testCaseOld); - } - if (testCaseNew != null && !testCaseNew.equals(testCaseOld)) { - testCaseNew.getStepList().add(step); - testCaseNew = em.merge(testCaseNew); - } - for (Requirement requirementListOldRequirement : requirementListOld) { - if (!requirementListNew.contains(requirementListOldRequirement)) { - requirementListOldRequirement.getStepList().remove(step); - requirementListOldRequirement = em.merge(requirementListOldRequirement); - } - } - for (Requirement requirementListNewRequirement : requirementListNew) { - if (!requirementListOld.contains(requirementListNewRequirement)) { - requirementListNewRequirement.getStepList().add(step); - requirementListNewRequirement = em.merge(requirementListNewRequirement); - } - } - for (ExecutionStep executionStepListNewExecutionStep : executionStepListNew) { - if (!executionStepListOld.contains(executionStepListNewExecutionStep)) { - Step oldStepOfExecutionStepListNewExecutionStep = executionStepListNewExecutionStep.getStep(); - executionStepListNewExecutionStep.setStep(step); - executionStepListNewExecutionStep = em.merge(executionStepListNewExecutionStep); - if (oldStepOfExecutionStepListNewExecutionStep != null && !oldStepOfExecutionStepListNewExecutionStep.equals(step)) { - oldStepOfExecutionStepListNewExecutionStep.getExecutionStepList().remove(executionStepListNewExecutionStep); - oldStepOfExecutionStepListNewExecutionStep = em.merge(oldStepOfExecutionStepListNewExecutionStep); - } - } - } - for (History historyListNewHistory : historyListNew) { - if (!historyListOld.contains(historyListNewHistory)) { - Step oldStepOfHistoryListNewHistory = historyListNewHistory.getStep(); - historyListNewHistory.setStep(step); - historyListNewHistory = em.merge(historyListNewHistory); - if (oldStepOfHistoryListNewHistory != null && !oldStepOfHistoryListNewHistory.equals(step)) { - oldStepOfHistoryListNewHistory.getHistoryList().remove(historyListNewHistory); - oldStepOfHistoryListNewHistory = em.merge(oldStepOfHistoryListNewHistory); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - StepPK id = step.getStepPK(); - if (findStep(id) == null) { - throw new NonexistentEntityException("The step with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(StepPK id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - Step step; - try { - step = em.getReference(Step.class, id); - step.getStepPK(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The step with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List executionStepListOrphanCheck = step.getExecutionStepList(); - for (ExecutionStep executionStepListOrphanCheckExecutionStep : executionStepListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This Step (" + step + ") cannot be destroyed since the ExecutionStep " + executionStepListOrphanCheckExecutionStep + " in its executionStepList field has a non-nullable step field."); - } - List historyListOrphanCheck = step.getHistoryList(); - for (History historyListOrphanCheckHistory : historyListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This Step (" + step + ") cannot be destroyed since the History " + historyListOrphanCheckHistory + " in its historyList field has a non-nullable step field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - TestCase testCase = step.getTestCase(); - if (testCase != null) { - testCase.getStepList().remove(step); - testCase = em.merge(testCase); - } - List requirementList = step.getRequirementList(); - for (Requirement requirementListRequirement : requirementList) { - requirementListRequirement.getStepList().remove(step); - requirementListRequirement = em.merge(requirementListRequirement); - } - em.remove(step); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findStepEntities() { - return findStepEntities(true, -1, -1); - } - - public List findStepEntities(int maxResults, int firstResult) { - return findStepEntities(false, maxResults, firstResult); - } - - private List findStepEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(Step.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public Step findStep(StepPK id) { - EntityManager em = getEntityManager(); - try { - return em.find(Step.class, id); - } - finally { - em.close(); - } - } - - public int getStepCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(Step.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.TestCase; +import com.validation.manager.core.db.Requirement; +import java.util.ArrayList; +import java.util.List; +import com.validation.manager.core.db.ExecutionStep; +import com.validation.manager.core.db.History; +import com.validation.manager.core.db.Step; +import com.validation.manager.core.db.StepPK; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import com.validation.manager.core.db.controller.exceptions.PreexistingEntityException; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class StepJpaController implements Serializable { + + public StepJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(Step step) throws PreexistingEntityException, Exception { + if (step.getStepPK() == null) { + step.setStepPK(new StepPK()); + } + if (step.getRequirementList() == null) { + step.setRequirementList(new ArrayList<>()); + } + if (step.getExecutionStepList() == null) { + step.setExecutionStepList(new ArrayList<>()); + } + if (step.getHistoryList() == null) { + step.setHistoryList(new ArrayList<>()); + } + step.getStepPK().setTestCaseId(step.getTestCase().getId()); + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + TestCase testCase = step.getTestCase(); + if (testCase != null) { + testCase = em.getReference(testCase.getClass(), testCase.getId()); + step.setTestCase(testCase); + } + List attachedRequirementList = new ArrayList<>(); + for (Requirement requirementListRequirementToAttach : step.getRequirementList()) { + requirementListRequirementToAttach = em.getReference(requirementListRequirementToAttach.getClass(), requirementListRequirementToAttach.getId()); + attachedRequirementList.add(requirementListRequirementToAttach); + } + step.setRequirementList(attachedRequirementList); + List attachedExecutionStepList = new ArrayList<>(); + for (ExecutionStep executionStepListExecutionStepToAttach : step.getExecutionStepList()) { + executionStepListExecutionStepToAttach = em.getReference(executionStepListExecutionStepToAttach.getClass(), executionStepListExecutionStepToAttach.getExecutionStepPK()); + attachedExecutionStepList.add(executionStepListExecutionStepToAttach); + } + step.setExecutionStepList(attachedExecutionStepList); + List attachedHistoryList = new ArrayList<>(); + for (History historyListHistoryToAttach : step.getHistoryList()) { + historyListHistoryToAttach = em.getReference(historyListHistoryToAttach.getClass(), historyListHistoryToAttach.getId()); + attachedHistoryList.add(historyListHistoryToAttach); + } + step.setHistoryList(attachedHistoryList); + em.persist(step); + if (testCase != null) { + testCase.getStepList().add(step); + testCase = em.merge(testCase); + } + for (Requirement requirementListRequirement : step.getRequirementList()) { + requirementListRequirement.getStepList().add(step); + requirementListRequirement = em.merge(requirementListRequirement); + } + for (ExecutionStep executionStepListExecutionStep : step.getExecutionStepList()) { + Step oldStepOfExecutionStepListExecutionStep = executionStepListExecutionStep.getStep(); + executionStepListExecutionStep.setStep(step); + executionStepListExecutionStep = em.merge(executionStepListExecutionStep); + if (oldStepOfExecutionStepListExecutionStep != null) { + oldStepOfExecutionStepListExecutionStep.getExecutionStepList().remove(executionStepListExecutionStep); + oldStepOfExecutionStepListExecutionStep = em.merge(oldStepOfExecutionStepListExecutionStep); + } + } + for (History historyListHistory : step.getHistoryList()) { + Step oldStepOfHistoryListHistory = historyListHistory.getStep(); + historyListHistory.setStep(step); + historyListHistory = em.merge(historyListHistory); + if (oldStepOfHistoryListHistory != null) { + oldStepOfHistoryListHistory.getHistoryList().remove(historyListHistory); + oldStepOfHistoryListHistory = em.merge(oldStepOfHistoryListHistory); + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + if (findStep(step.getStepPK()) != null) { + throw new PreexistingEntityException("Step " + step + " already exists.", ex); + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(Step step) throws IllegalOrphanException, NonexistentEntityException, Exception { + step.getStepPK().setTestCaseId(step.getTestCase().getId()); + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + Step persistentStep = em.find(Step.class, step.getStepPK()); + TestCase testCaseOld = persistentStep.getTestCase(); + TestCase testCaseNew = step.getTestCase(); + List requirementListOld = persistentStep.getRequirementList(); + List requirementListNew = step.getRequirementList(); + List executionStepListOld = persistentStep.getExecutionStepList(); + List executionStepListNew = step.getExecutionStepList(); + List historyListOld = persistentStep.getHistoryList(); + List historyListNew = step.getHistoryList(); + List illegalOrphanMessages = null; + for (ExecutionStep executionStepListOldExecutionStep : executionStepListOld) { + if (!executionStepListNew.contains(executionStepListOldExecutionStep)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain ExecutionStep " + executionStepListOldExecutionStep + " since its step field is not nullable."); + } + } + for (History historyListOldHistory : historyListOld) { + if (!historyListNew.contains(historyListOldHistory)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain History " + historyListOldHistory + " since its step field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + if (testCaseNew != null) { + testCaseNew = em.getReference(testCaseNew.getClass(), testCaseNew.getId()); + step.setTestCase(testCaseNew); + } + List attachedRequirementListNew = new ArrayList<>(); + for (Requirement requirementListNewRequirementToAttach : requirementListNew) { + requirementListNewRequirementToAttach = em.getReference(requirementListNewRequirementToAttach.getClass(), requirementListNewRequirementToAttach.getId()); + attachedRequirementListNew.add(requirementListNewRequirementToAttach); + } + requirementListNew = attachedRequirementListNew; + step.setRequirementList(requirementListNew); + List attachedExecutionStepListNew = new ArrayList<>(); + for (ExecutionStep executionStepListNewExecutionStepToAttach : executionStepListNew) { + executionStepListNewExecutionStepToAttach = em.getReference(executionStepListNewExecutionStepToAttach.getClass(), executionStepListNewExecutionStepToAttach.getExecutionStepPK()); + attachedExecutionStepListNew.add(executionStepListNewExecutionStepToAttach); + } + executionStepListNew = attachedExecutionStepListNew; + step.setExecutionStepList(executionStepListNew); + List attachedHistoryListNew = new ArrayList<>(); + for (History historyListNewHistoryToAttach : historyListNew) { + historyListNewHistoryToAttach = em.getReference(historyListNewHistoryToAttach.getClass(), historyListNewHistoryToAttach.getId()); + attachedHistoryListNew.add(historyListNewHistoryToAttach); + } + historyListNew = attachedHistoryListNew; + step.setHistoryList(historyListNew); + step = em.merge(step); + if (testCaseOld != null && !testCaseOld.equals(testCaseNew)) { + testCaseOld.getStepList().remove(step); + testCaseOld = em.merge(testCaseOld); + } + if (testCaseNew != null && !testCaseNew.equals(testCaseOld)) { + testCaseNew.getStepList().add(step); + testCaseNew = em.merge(testCaseNew); + } + for (Requirement requirementListOldRequirement : requirementListOld) { + if (!requirementListNew.contains(requirementListOldRequirement)) { + requirementListOldRequirement.getStepList().remove(step); + requirementListOldRequirement = em.merge(requirementListOldRequirement); + } + } + for (Requirement requirementListNewRequirement : requirementListNew) { + if (!requirementListOld.contains(requirementListNewRequirement)) { + requirementListNewRequirement.getStepList().add(step); + requirementListNewRequirement = em.merge(requirementListNewRequirement); + } + } + for (ExecutionStep executionStepListNewExecutionStep : executionStepListNew) { + if (!executionStepListOld.contains(executionStepListNewExecutionStep)) { + Step oldStepOfExecutionStepListNewExecutionStep = executionStepListNewExecutionStep.getStep(); + executionStepListNewExecutionStep.setStep(step); + executionStepListNewExecutionStep = em.merge(executionStepListNewExecutionStep); + if (oldStepOfExecutionStepListNewExecutionStep != null && !oldStepOfExecutionStepListNewExecutionStep.equals(step)) { + oldStepOfExecutionStepListNewExecutionStep.getExecutionStepList().remove(executionStepListNewExecutionStep); + oldStepOfExecutionStepListNewExecutionStep = em.merge(oldStepOfExecutionStepListNewExecutionStep); + } + } + } + for (History historyListNewHistory : historyListNew) { + if (!historyListOld.contains(historyListNewHistory)) { + Step oldStepOfHistoryListNewHistory = historyListNewHistory.getStep(); + historyListNewHistory.setStep(step); + historyListNewHistory = em.merge(historyListNewHistory); + if (oldStepOfHistoryListNewHistory != null && !oldStepOfHistoryListNewHistory.equals(step)) { + oldStepOfHistoryListNewHistory.getHistoryList().remove(historyListNewHistory); + oldStepOfHistoryListNewHistory = em.merge(oldStepOfHistoryListNewHistory); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + StepPK id = step.getStepPK(); + if (findStep(id) == null) { + throw new NonexistentEntityException("The step with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(StepPK id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + Step step; + try { + step = em.getReference(Step.class, id); + step.getStepPK(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The step with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List executionStepListOrphanCheck = step.getExecutionStepList(); + for (ExecutionStep executionStepListOrphanCheckExecutionStep : executionStepListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This Step (" + step + ") cannot be destroyed since the ExecutionStep " + executionStepListOrphanCheckExecutionStep + " in its executionStepList field has a non-nullable step field."); + } + List historyListOrphanCheck = step.getHistoryList(); + for (History historyListOrphanCheckHistory : historyListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This Step (" + step + ") cannot be destroyed since the History " + historyListOrphanCheckHistory + " in its historyList field has a non-nullable step field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + TestCase testCase = step.getTestCase(); + if (testCase != null) { + testCase.getStepList().remove(step); + testCase = em.merge(testCase); + } + List requirementList = step.getRequirementList(); + for (Requirement requirementListRequirement : requirementList) { + requirementListRequirement.getStepList().remove(step); + requirementListRequirement = em.merge(requirementListRequirement); + } + em.remove(step); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findStepEntities() { + return findStepEntities(true, -1, -1); + } + + public List findStepEntities(int maxResults, int firstResult) { + return findStepEntities(false, maxResults, firstResult); + } + + private List findStepEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(Step.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public Step findStep(StepPK id) { + EntityManager em = getEntityManager(); + try { + return em.find(Step.class, id); + } + finally { + em.close(); + } + } + + public int getStepCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(Step.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/TestCaseExecutionJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/TestCaseExecutionJpaController.java index e7156e5e..dda77abd 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/TestCaseExecutionJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/TestCaseExecutionJpaController.java @@ -13,209 +13,209 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.ExecutionStep; -import com.validation.manager.core.db.TestCaseExecution; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import java.util.ArrayList; -import java.util.List; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class TestCaseExecutionJpaController implements Serializable { - - public TestCaseExecutionJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(TestCaseExecution testCaseExecution) { - if (testCaseExecution.getExecutionStepList() == null) { - testCaseExecution.setExecutionStepList(new ArrayList()); - } - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - List attachedExecutionStepList = new ArrayList(); - for (ExecutionStep executionStepListExecutionStepToAttach : testCaseExecution.getExecutionStepList()) { - executionStepListExecutionStepToAttach = em.getReference(executionStepListExecutionStepToAttach.getClass(), executionStepListExecutionStepToAttach.getExecutionStepPK()); - attachedExecutionStepList.add(executionStepListExecutionStepToAttach); - } - testCaseExecution.setExecutionStepList(attachedExecutionStepList); - em.persist(testCaseExecution); - for (ExecutionStep executionStepListExecutionStep : testCaseExecution.getExecutionStepList()) { - TestCaseExecution oldTestCaseExecutionOfExecutionStepListExecutionStep = executionStepListExecutionStep.getTestCaseExecution(); - executionStepListExecutionStep.setTestCaseExecution(testCaseExecution); - executionStepListExecutionStep = em.merge(executionStepListExecutionStep); - if (oldTestCaseExecutionOfExecutionStepListExecutionStep != null) { - oldTestCaseExecutionOfExecutionStepListExecutionStep.getExecutionStepList().remove(executionStepListExecutionStep); - oldTestCaseExecutionOfExecutionStepListExecutionStep = em.merge(oldTestCaseExecutionOfExecutionStepListExecutionStep); - } - } - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(TestCaseExecution testCaseExecution) throws IllegalOrphanException, NonexistentEntityException, Exception { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - TestCaseExecution persistentTestCaseExecution = em.find(TestCaseExecution.class, testCaseExecution.getId()); - List executionStepListOld = persistentTestCaseExecution.getExecutionStepList(); - List executionStepListNew = testCaseExecution.getExecutionStepList(); - List illegalOrphanMessages = null; - for (ExecutionStep executionStepListOldExecutionStep : executionStepListOld) { - if (!executionStepListNew.contains(executionStepListOldExecutionStep)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain ExecutionStep " + executionStepListOldExecutionStep + " since its testCaseExecution field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - List attachedExecutionStepListNew = new ArrayList(); - for (ExecutionStep executionStepListNewExecutionStepToAttach : executionStepListNew) { - executionStepListNewExecutionStepToAttach = em.getReference(executionStepListNewExecutionStepToAttach.getClass(), executionStepListNewExecutionStepToAttach.getExecutionStepPK()); - attachedExecutionStepListNew.add(executionStepListNewExecutionStepToAttach); - } - executionStepListNew = attachedExecutionStepListNew; - testCaseExecution.setExecutionStepList(executionStepListNew); - testCaseExecution = em.merge(testCaseExecution); - for (ExecutionStep executionStepListNewExecutionStep : executionStepListNew) { - if (!executionStepListOld.contains(executionStepListNewExecutionStep)) { - TestCaseExecution oldTestCaseExecutionOfExecutionStepListNewExecutionStep = executionStepListNewExecutionStep.getTestCaseExecution(); - executionStepListNewExecutionStep.setTestCaseExecution(testCaseExecution); - executionStepListNewExecutionStep = em.merge(executionStepListNewExecutionStep); - if (oldTestCaseExecutionOfExecutionStepListNewExecutionStep != null && !oldTestCaseExecutionOfExecutionStepListNewExecutionStep.equals(testCaseExecution)) { - oldTestCaseExecutionOfExecutionStepListNewExecutionStep.getExecutionStepList().remove(executionStepListNewExecutionStep); - oldTestCaseExecutionOfExecutionStepListNewExecutionStep = em.merge(oldTestCaseExecutionOfExecutionStepListNewExecutionStep); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - Integer id = testCaseExecution.getId(); - if (findTestCaseExecution(id) == null) { - throw new NonexistentEntityException("The testCaseExecution with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - TestCaseExecution testCaseExecution; - try { - testCaseExecution = em.getReference(TestCaseExecution.class, id); - testCaseExecution.getId(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The testCaseExecution with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List executionStepListOrphanCheck = testCaseExecution.getExecutionStepList(); - for (ExecutionStep executionStepListOrphanCheckExecutionStep : executionStepListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This TestCaseExecution (" + testCaseExecution + ") cannot be destroyed since the ExecutionStep " + executionStepListOrphanCheckExecutionStep + " in its executionStepList field has a non-nullable testCaseExecution field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - em.remove(testCaseExecution); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findTestCaseExecutionEntities() { - return findTestCaseExecutionEntities(true, -1, -1); - } - - public List findTestCaseExecutionEntities(int maxResults, int firstResult) { - return findTestCaseExecutionEntities(false, maxResults, firstResult); - } - - private List findTestCaseExecutionEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(TestCaseExecution.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public TestCaseExecution findTestCaseExecution(Integer id) { - EntityManager em = getEntityManager(); - try { - return em.find(TestCaseExecution.class, id); - } - finally { - em.close(); - } - } - - public int getTestCaseExecutionCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(TestCaseExecution.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.ExecutionStep; +import com.validation.manager.core.db.TestCaseExecution; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import java.util.ArrayList; +import java.util.List; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class TestCaseExecutionJpaController implements Serializable { + + public TestCaseExecutionJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(TestCaseExecution testCaseExecution) { + if (testCaseExecution.getExecutionStepList() == null) { + testCaseExecution.setExecutionStepList(new ArrayList<>()); + } + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + List attachedExecutionStepList = new ArrayList<>(); + for (ExecutionStep executionStepListExecutionStepToAttach : testCaseExecution.getExecutionStepList()) { + executionStepListExecutionStepToAttach = em.getReference(executionStepListExecutionStepToAttach.getClass(), executionStepListExecutionStepToAttach.getExecutionStepPK()); + attachedExecutionStepList.add(executionStepListExecutionStepToAttach); + } + testCaseExecution.setExecutionStepList(attachedExecutionStepList); + em.persist(testCaseExecution); + for (ExecutionStep executionStepListExecutionStep : testCaseExecution.getExecutionStepList()) { + TestCaseExecution oldTestCaseExecutionOfExecutionStepListExecutionStep = executionStepListExecutionStep.getTestCaseExecution(); + executionStepListExecutionStep.setTestCaseExecution(testCaseExecution); + executionStepListExecutionStep = em.merge(executionStepListExecutionStep); + if (oldTestCaseExecutionOfExecutionStepListExecutionStep != null) { + oldTestCaseExecutionOfExecutionStepListExecutionStep.getExecutionStepList().remove(executionStepListExecutionStep); + oldTestCaseExecutionOfExecutionStepListExecutionStep = em.merge(oldTestCaseExecutionOfExecutionStepListExecutionStep); + } + } + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(TestCaseExecution testCaseExecution) throws IllegalOrphanException, NonexistentEntityException, Exception { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + TestCaseExecution persistentTestCaseExecution = em.find(TestCaseExecution.class, testCaseExecution.getId()); + List executionStepListOld = persistentTestCaseExecution.getExecutionStepList(); + List executionStepListNew = testCaseExecution.getExecutionStepList(); + List illegalOrphanMessages = null; + for (ExecutionStep executionStepListOldExecutionStep : executionStepListOld) { + if (!executionStepListNew.contains(executionStepListOldExecutionStep)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain ExecutionStep " + executionStepListOldExecutionStep + " since its testCaseExecution field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + List attachedExecutionStepListNew = new ArrayList<>(); + for (ExecutionStep executionStepListNewExecutionStepToAttach : executionStepListNew) { + executionStepListNewExecutionStepToAttach = em.getReference(executionStepListNewExecutionStepToAttach.getClass(), executionStepListNewExecutionStepToAttach.getExecutionStepPK()); + attachedExecutionStepListNew.add(executionStepListNewExecutionStepToAttach); + } + executionStepListNew = attachedExecutionStepListNew; + testCaseExecution.setExecutionStepList(executionStepListNew); + testCaseExecution = em.merge(testCaseExecution); + for (ExecutionStep executionStepListNewExecutionStep : executionStepListNew) { + if (!executionStepListOld.contains(executionStepListNewExecutionStep)) { + TestCaseExecution oldTestCaseExecutionOfExecutionStepListNewExecutionStep = executionStepListNewExecutionStep.getTestCaseExecution(); + executionStepListNewExecutionStep.setTestCaseExecution(testCaseExecution); + executionStepListNewExecutionStep = em.merge(executionStepListNewExecutionStep); + if (oldTestCaseExecutionOfExecutionStepListNewExecutionStep != null && !oldTestCaseExecutionOfExecutionStepListNewExecutionStep.equals(testCaseExecution)) { + oldTestCaseExecutionOfExecutionStepListNewExecutionStep.getExecutionStepList().remove(executionStepListNewExecutionStep); + oldTestCaseExecutionOfExecutionStepListNewExecutionStep = em.merge(oldTestCaseExecutionOfExecutionStepListNewExecutionStep); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + Integer id = testCaseExecution.getId(); + if (findTestCaseExecution(id) == null) { + throw new NonexistentEntityException("The testCaseExecution with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + TestCaseExecution testCaseExecution; + try { + testCaseExecution = em.getReference(TestCaseExecution.class, id); + testCaseExecution.getId(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The testCaseExecution with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List executionStepListOrphanCheck = testCaseExecution.getExecutionStepList(); + for (ExecutionStep executionStepListOrphanCheckExecutionStep : executionStepListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This TestCaseExecution (" + testCaseExecution + ") cannot be destroyed since the ExecutionStep " + executionStepListOrphanCheckExecutionStep + " in its executionStepList field has a non-nullable testCaseExecution field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + em.remove(testCaseExecution); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findTestCaseExecutionEntities() { + return findTestCaseExecutionEntities(true, -1, -1); + } + + public List findTestCaseExecutionEntities(int maxResults, int firstResult) { + return findTestCaseExecutionEntities(false, maxResults, firstResult); + } + + private List findTestCaseExecutionEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(TestCaseExecution.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public TestCaseExecution findTestCaseExecution(Integer id) { + EntityManager em = getEntityManager(); + try { + return em.find(TestCaseExecution.class, id); + } + finally { + em.close(); + } + } + + public int getTestCaseExecutionCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(TestCaseExecution.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/TestCaseJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/TestCaseJpaController.java index 47b67f17..aeeee3df 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/TestCaseJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/TestCaseJpaController.java @@ -13,303 +13,303 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.TestPlan; -import java.util.ArrayList; -import java.util.List; -import com.validation.manager.core.db.RiskControlHasTestCase; -import com.validation.manager.core.db.Step; -import com.validation.manager.core.db.TestCase; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class TestCaseJpaController implements Serializable { - - public TestCaseJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(TestCase testCase) { - if (testCase.getTestPlanList() == null) { - testCase.setTestPlanList(new ArrayList()); - } - if (testCase.getRiskControlHasTestCaseList() == null) { - testCase.setRiskControlHasTestCaseList(new ArrayList()); - } - if (testCase.getStepList() == null) { - testCase.setStepList(new ArrayList()); - } - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - List attachedTestPlanList = new ArrayList(); - for (TestPlan testPlanListTestPlanToAttach : testCase.getTestPlanList()) { - testPlanListTestPlanToAttach = em.getReference(testPlanListTestPlanToAttach.getClass(), testPlanListTestPlanToAttach.getTestPlanPK()); - attachedTestPlanList.add(testPlanListTestPlanToAttach); - } - testCase.setTestPlanList(attachedTestPlanList); - List attachedRiskControlHasTestCaseList = new ArrayList(); - for (RiskControlHasTestCase riskControlHasTestCaseListRiskControlHasTestCaseToAttach : testCase.getRiskControlHasTestCaseList()) { - riskControlHasTestCaseListRiskControlHasTestCaseToAttach = em.getReference(riskControlHasTestCaseListRiskControlHasTestCaseToAttach.getClass(), riskControlHasTestCaseListRiskControlHasTestCaseToAttach.getRiskControlHasTestCasePK()); - attachedRiskControlHasTestCaseList.add(riskControlHasTestCaseListRiskControlHasTestCaseToAttach); - } - testCase.setRiskControlHasTestCaseList(attachedRiskControlHasTestCaseList); - List attachedStepList = new ArrayList(); - for (Step stepListStepToAttach : testCase.getStepList()) { - stepListStepToAttach = em.getReference(stepListStepToAttach.getClass(), stepListStepToAttach.getStepPK()); - attachedStepList.add(stepListStepToAttach); - } - testCase.setStepList(attachedStepList); - em.persist(testCase); - for (TestPlan testPlanListTestPlan : testCase.getTestPlanList()) { - testPlanListTestPlan.getTestCaseList().add(testCase); - testPlanListTestPlan = em.merge(testPlanListTestPlan); - } - for (RiskControlHasTestCase riskControlHasTestCaseListRiskControlHasTestCase : testCase.getRiskControlHasTestCaseList()) { - TestCase oldTestCaseOfRiskControlHasTestCaseListRiskControlHasTestCase = riskControlHasTestCaseListRiskControlHasTestCase.getTestCase(); - riskControlHasTestCaseListRiskControlHasTestCase.setTestCase(testCase); - riskControlHasTestCaseListRiskControlHasTestCase = em.merge(riskControlHasTestCaseListRiskControlHasTestCase); - if (oldTestCaseOfRiskControlHasTestCaseListRiskControlHasTestCase != null) { - oldTestCaseOfRiskControlHasTestCaseListRiskControlHasTestCase.getRiskControlHasTestCaseList().remove(riskControlHasTestCaseListRiskControlHasTestCase); - oldTestCaseOfRiskControlHasTestCaseListRiskControlHasTestCase = em.merge(oldTestCaseOfRiskControlHasTestCaseListRiskControlHasTestCase); - } - } - for (Step stepListStep : testCase.getStepList()) { - TestCase oldTestCaseOfStepListStep = stepListStep.getTestCase(); - stepListStep.setTestCase(testCase); - stepListStep = em.merge(stepListStep); - if (oldTestCaseOfStepListStep != null) { - oldTestCaseOfStepListStep.getStepList().remove(stepListStep); - oldTestCaseOfStepListStep = em.merge(oldTestCaseOfStepListStep); - } - } - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(TestCase testCase) throws IllegalOrphanException, NonexistentEntityException, Exception { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - TestCase persistentTestCase = em.find(TestCase.class, testCase.getId()); - List testPlanListOld = persistentTestCase.getTestPlanList(); - List testPlanListNew = testCase.getTestPlanList(); - List riskControlHasTestCaseListOld = persistentTestCase.getRiskControlHasTestCaseList(); - List riskControlHasTestCaseListNew = testCase.getRiskControlHasTestCaseList(); - List stepListOld = persistentTestCase.getStepList(); - List stepListNew = testCase.getStepList(); - List illegalOrphanMessages = null; - for (RiskControlHasTestCase riskControlHasTestCaseListOldRiskControlHasTestCase : riskControlHasTestCaseListOld) { - if (!riskControlHasTestCaseListNew.contains(riskControlHasTestCaseListOldRiskControlHasTestCase)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain RiskControlHasTestCase " + riskControlHasTestCaseListOldRiskControlHasTestCase + " since its testCase field is not nullable."); - } - } - for (Step stepListOldStep : stepListOld) { - if (!stepListNew.contains(stepListOldStep)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain Step " + stepListOldStep + " since its testCase field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - List attachedTestPlanListNew = new ArrayList(); - for (TestPlan testPlanListNewTestPlanToAttach : testPlanListNew) { - testPlanListNewTestPlanToAttach = em.getReference(testPlanListNewTestPlanToAttach.getClass(), testPlanListNewTestPlanToAttach.getTestPlanPK()); - attachedTestPlanListNew.add(testPlanListNewTestPlanToAttach); - } - testPlanListNew = attachedTestPlanListNew; - testCase.setTestPlanList(testPlanListNew); - List attachedRiskControlHasTestCaseListNew = new ArrayList(); - for (RiskControlHasTestCase riskControlHasTestCaseListNewRiskControlHasTestCaseToAttach : riskControlHasTestCaseListNew) { - riskControlHasTestCaseListNewRiskControlHasTestCaseToAttach = em.getReference(riskControlHasTestCaseListNewRiskControlHasTestCaseToAttach.getClass(), riskControlHasTestCaseListNewRiskControlHasTestCaseToAttach.getRiskControlHasTestCasePK()); - attachedRiskControlHasTestCaseListNew.add(riskControlHasTestCaseListNewRiskControlHasTestCaseToAttach); - } - riskControlHasTestCaseListNew = attachedRiskControlHasTestCaseListNew; - testCase.setRiskControlHasTestCaseList(riskControlHasTestCaseListNew); - List attachedStepListNew = new ArrayList(); - for (Step stepListNewStepToAttach : stepListNew) { - stepListNewStepToAttach = em.getReference(stepListNewStepToAttach.getClass(), stepListNewStepToAttach.getStepPK()); - attachedStepListNew.add(stepListNewStepToAttach); - } - stepListNew = attachedStepListNew; - testCase.setStepList(stepListNew); - testCase = em.merge(testCase); - for (TestPlan testPlanListOldTestPlan : testPlanListOld) { - if (!testPlanListNew.contains(testPlanListOldTestPlan)) { - testPlanListOldTestPlan.getTestCaseList().remove(testCase); - testPlanListOldTestPlan = em.merge(testPlanListOldTestPlan); - } - } - for (TestPlan testPlanListNewTestPlan : testPlanListNew) { - if (!testPlanListOld.contains(testPlanListNewTestPlan)) { - testPlanListNewTestPlan.getTestCaseList().add(testCase); - testPlanListNewTestPlan = em.merge(testPlanListNewTestPlan); - } - } - for (RiskControlHasTestCase riskControlHasTestCaseListNewRiskControlHasTestCase : riskControlHasTestCaseListNew) { - if (!riskControlHasTestCaseListOld.contains(riskControlHasTestCaseListNewRiskControlHasTestCase)) { - TestCase oldTestCaseOfRiskControlHasTestCaseListNewRiskControlHasTestCase = riskControlHasTestCaseListNewRiskControlHasTestCase.getTestCase(); - riskControlHasTestCaseListNewRiskControlHasTestCase.setTestCase(testCase); - riskControlHasTestCaseListNewRiskControlHasTestCase = em.merge(riskControlHasTestCaseListNewRiskControlHasTestCase); - if (oldTestCaseOfRiskControlHasTestCaseListNewRiskControlHasTestCase != null && !oldTestCaseOfRiskControlHasTestCaseListNewRiskControlHasTestCase.equals(testCase)) { - oldTestCaseOfRiskControlHasTestCaseListNewRiskControlHasTestCase.getRiskControlHasTestCaseList().remove(riskControlHasTestCaseListNewRiskControlHasTestCase); - oldTestCaseOfRiskControlHasTestCaseListNewRiskControlHasTestCase = em.merge(oldTestCaseOfRiskControlHasTestCaseListNewRiskControlHasTestCase); - } - } - } - for (Step stepListNewStep : stepListNew) { - if (!stepListOld.contains(stepListNewStep)) { - TestCase oldTestCaseOfStepListNewStep = stepListNewStep.getTestCase(); - stepListNewStep.setTestCase(testCase); - stepListNewStep = em.merge(stepListNewStep); - if (oldTestCaseOfStepListNewStep != null && !oldTestCaseOfStepListNewStep.equals(testCase)) { - oldTestCaseOfStepListNewStep.getStepList().remove(stepListNewStep); - oldTestCaseOfStepListNewStep = em.merge(oldTestCaseOfStepListNewStep); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - Integer id = testCase.getId(); - if (findTestCase(id) == null) { - throw new NonexistentEntityException("The testCase with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - TestCase testCase; - try { - testCase = em.getReference(TestCase.class, id); - testCase.getId(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The testCase with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List riskControlHasTestCaseListOrphanCheck = testCase.getRiskControlHasTestCaseList(); - for (RiskControlHasTestCase riskControlHasTestCaseListOrphanCheckRiskControlHasTestCase : riskControlHasTestCaseListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This TestCase (" + testCase + ") cannot be destroyed since the RiskControlHasTestCase " + riskControlHasTestCaseListOrphanCheckRiskControlHasTestCase + " in its riskControlHasTestCaseList field has a non-nullable testCase field."); - } - List stepListOrphanCheck = testCase.getStepList(); - for (Step stepListOrphanCheckStep : stepListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This TestCase (" + testCase + ") cannot be destroyed since the Step " + stepListOrphanCheckStep + " in its stepList field has a non-nullable testCase field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - List testPlanList = testCase.getTestPlanList(); - for (TestPlan testPlanListTestPlan : testPlanList) { - testPlanListTestPlan.getTestCaseList().remove(testCase); - testPlanListTestPlan = em.merge(testPlanListTestPlan); - } - em.remove(testCase); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findTestCaseEntities() { - return findTestCaseEntities(true, -1, -1); - } - - public List findTestCaseEntities(int maxResults, int firstResult) { - return findTestCaseEntities(false, maxResults, firstResult); - } - - private List findTestCaseEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(TestCase.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public TestCase findTestCase(Integer id) { - EntityManager em = getEntityManager(); - try { - return em.find(TestCase.class, id); - } - finally { - em.close(); - } - } - - public int getTestCaseCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(TestCase.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.TestPlan; +import java.util.ArrayList; +import java.util.List; +import com.validation.manager.core.db.RiskControlHasTestCase; +import com.validation.manager.core.db.Step; +import com.validation.manager.core.db.TestCase; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class TestCaseJpaController implements Serializable { + + public TestCaseJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(TestCase testCase) { + if (testCase.getTestPlanList() == null) { + testCase.setTestPlanList(new ArrayList<>()); + } + if (testCase.getRiskControlHasTestCaseList() == null) { + testCase.setRiskControlHasTestCaseList(new ArrayList<>()); + } + if (testCase.getStepList() == null) { + testCase.setStepList(new ArrayList<>()); + } + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + List attachedTestPlanList = new ArrayList<>(); + for (TestPlan testPlanListTestPlanToAttach : testCase.getTestPlanList()) { + testPlanListTestPlanToAttach = em.getReference(testPlanListTestPlanToAttach.getClass(), testPlanListTestPlanToAttach.getTestPlanPK()); + attachedTestPlanList.add(testPlanListTestPlanToAttach); + } + testCase.setTestPlanList(attachedTestPlanList); + List attachedRiskControlHasTestCaseList = new ArrayList<>(); + for (RiskControlHasTestCase riskControlHasTestCaseListRiskControlHasTestCaseToAttach : testCase.getRiskControlHasTestCaseList()) { + riskControlHasTestCaseListRiskControlHasTestCaseToAttach = em.getReference(riskControlHasTestCaseListRiskControlHasTestCaseToAttach.getClass(), riskControlHasTestCaseListRiskControlHasTestCaseToAttach.getRiskControlHasTestCasePK()); + attachedRiskControlHasTestCaseList.add(riskControlHasTestCaseListRiskControlHasTestCaseToAttach); + } + testCase.setRiskControlHasTestCaseList(attachedRiskControlHasTestCaseList); + List attachedStepList = new ArrayList<>(); + for (Step stepListStepToAttach : testCase.getStepList()) { + stepListStepToAttach = em.getReference(stepListStepToAttach.getClass(), stepListStepToAttach.getStepPK()); + attachedStepList.add(stepListStepToAttach); + } + testCase.setStepList(attachedStepList); + em.persist(testCase); + for (TestPlan testPlanListTestPlan : testCase.getTestPlanList()) { + testPlanListTestPlan.getTestCaseList().add(testCase); + testPlanListTestPlan = em.merge(testPlanListTestPlan); + } + for (RiskControlHasTestCase riskControlHasTestCaseListRiskControlHasTestCase : testCase.getRiskControlHasTestCaseList()) { + TestCase oldTestCaseOfRiskControlHasTestCaseListRiskControlHasTestCase = riskControlHasTestCaseListRiskControlHasTestCase.getTestCase(); + riskControlHasTestCaseListRiskControlHasTestCase.setTestCase(testCase); + riskControlHasTestCaseListRiskControlHasTestCase = em.merge(riskControlHasTestCaseListRiskControlHasTestCase); + if (oldTestCaseOfRiskControlHasTestCaseListRiskControlHasTestCase != null) { + oldTestCaseOfRiskControlHasTestCaseListRiskControlHasTestCase.getRiskControlHasTestCaseList().remove(riskControlHasTestCaseListRiskControlHasTestCase); + oldTestCaseOfRiskControlHasTestCaseListRiskControlHasTestCase = em.merge(oldTestCaseOfRiskControlHasTestCaseListRiskControlHasTestCase); + } + } + for (Step stepListStep : testCase.getStepList()) { + TestCase oldTestCaseOfStepListStep = stepListStep.getTestCase(); + stepListStep.setTestCase(testCase); + stepListStep = em.merge(stepListStep); + if (oldTestCaseOfStepListStep != null) { + oldTestCaseOfStepListStep.getStepList().remove(stepListStep); + oldTestCaseOfStepListStep = em.merge(oldTestCaseOfStepListStep); + } + } + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(TestCase testCase) throws IllegalOrphanException, NonexistentEntityException, Exception { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + TestCase persistentTestCase = em.find(TestCase.class, testCase.getId()); + List testPlanListOld = persistentTestCase.getTestPlanList(); + List testPlanListNew = testCase.getTestPlanList(); + List riskControlHasTestCaseListOld = persistentTestCase.getRiskControlHasTestCaseList(); + List riskControlHasTestCaseListNew = testCase.getRiskControlHasTestCaseList(); + List stepListOld = persistentTestCase.getStepList(); + List stepListNew = testCase.getStepList(); + List illegalOrphanMessages = null; + for (RiskControlHasTestCase riskControlHasTestCaseListOldRiskControlHasTestCase : riskControlHasTestCaseListOld) { + if (!riskControlHasTestCaseListNew.contains(riskControlHasTestCaseListOldRiskControlHasTestCase)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain RiskControlHasTestCase " + riskControlHasTestCaseListOldRiskControlHasTestCase + " since its testCase field is not nullable."); + } + } + for (Step stepListOldStep : stepListOld) { + if (!stepListNew.contains(stepListOldStep)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain Step " + stepListOldStep + " since its testCase field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + List attachedTestPlanListNew = new ArrayList<>(); + for (TestPlan testPlanListNewTestPlanToAttach : testPlanListNew) { + testPlanListNewTestPlanToAttach = em.getReference(testPlanListNewTestPlanToAttach.getClass(), testPlanListNewTestPlanToAttach.getTestPlanPK()); + attachedTestPlanListNew.add(testPlanListNewTestPlanToAttach); + } + testPlanListNew = attachedTestPlanListNew; + testCase.setTestPlanList(testPlanListNew); + List attachedRiskControlHasTestCaseListNew = new ArrayList<>(); + for (RiskControlHasTestCase riskControlHasTestCaseListNewRiskControlHasTestCaseToAttach : riskControlHasTestCaseListNew) { + riskControlHasTestCaseListNewRiskControlHasTestCaseToAttach = em.getReference(riskControlHasTestCaseListNewRiskControlHasTestCaseToAttach.getClass(), riskControlHasTestCaseListNewRiskControlHasTestCaseToAttach.getRiskControlHasTestCasePK()); + attachedRiskControlHasTestCaseListNew.add(riskControlHasTestCaseListNewRiskControlHasTestCaseToAttach); + } + riskControlHasTestCaseListNew = attachedRiskControlHasTestCaseListNew; + testCase.setRiskControlHasTestCaseList(riskControlHasTestCaseListNew); + List attachedStepListNew = new ArrayList<>(); + for (Step stepListNewStepToAttach : stepListNew) { + stepListNewStepToAttach = em.getReference(stepListNewStepToAttach.getClass(), stepListNewStepToAttach.getStepPK()); + attachedStepListNew.add(stepListNewStepToAttach); + } + stepListNew = attachedStepListNew; + testCase.setStepList(stepListNew); + testCase = em.merge(testCase); + for (TestPlan testPlanListOldTestPlan : testPlanListOld) { + if (!testPlanListNew.contains(testPlanListOldTestPlan)) { + testPlanListOldTestPlan.getTestCaseList().remove(testCase); + testPlanListOldTestPlan = em.merge(testPlanListOldTestPlan); + } + } + for (TestPlan testPlanListNewTestPlan : testPlanListNew) { + if (!testPlanListOld.contains(testPlanListNewTestPlan)) { + testPlanListNewTestPlan.getTestCaseList().add(testCase); + testPlanListNewTestPlan = em.merge(testPlanListNewTestPlan); + } + } + for (RiskControlHasTestCase riskControlHasTestCaseListNewRiskControlHasTestCase : riskControlHasTestCaseListNew) { + if (!riskControlHasTestCaseListOld.contains(riskControlHasTestCaseListNewRiskControlHasTestCase)) { + TestCase oldTestCaseOfRiskControlHasTestCaseListNewRiskControlHasTestCase = riskControlHasTestCaseListNewRiskControlHasTestCase.getTestCase(); + riskControlHasTestCaseListNewRiskControlHasTestCase.setTestCase(testCase); + riskControlHasTestCaseListNewRiskControlHasTestCase = em.merge(riskControlHasTestCaseListNewRiskControlHasTestCase); + if (oldTestCaseOfRiskControlHasTestCaseListNewRiskControlHasTestCase != null && !oldTestCaseOfRiskControlHasTestCaseListNewRiskControlHasTestCase.equals(testCase)) { + oldTestCaseOfRiskControlHasTestCaseListNewRiskControlHasTestCase.getRiskControlHasTestCaseList().remove(riskControlHasTestCaseListNewRiskControlHasTestCase); + oldTestCaseOfRiskControlHasTestCaseListNewRiskControlHasTestCase = em.merge(oldTestCaseOfRiskControlHasTestCaseListNewRiskControlHasTestCase); + } + } + } + for (Step stepListNewStep : stepListNew) { + if (!stepListOld.contains(stepListNewStep)) { + TestCase oldTestCaseOfStepListNewStep = stepListNewStep.getTestCase(); + stepListNewStep.setTestCase(testCase); + stepListNewStep = em.merge(stepListNewStep); + if (oldTestCaseOfStepListNewStep != null && !oldTestCaseOfStepListNewStep.equals(testCase)) { + oldTestCaseOfStepListNewStep.getStepList().remove(stepListNewStep); + oldTestCaseOfStepListNewStep = em.merge(oldTestCaseOfStepListNewStep); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + Integer id = testCase.getId(); + if (findTestCase(id) == null) { + throw new NonexistentEntityException("The testCase with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + TestCase testCase; + try { + testCase = em.getReference(TestCase.class, id); + testCase.getId(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The testCase with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List riskControlHasTestCaseListOrphanCheck = testCase.getRiskControlHasTestCaseList(); + for (RiskControlHasTestCase riskControlHasTestCaseListOrphanCheckRiskControlHasTestCase : riskControlHasTestCaseListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This TestCase (" + testCase + ") cannot be destroyed since the RiskControlHasTestCase " + riskControlHasTestCaseListOrphanCheckRiskControlHasTestCase + " in its riskControlHasTestCaseList field has a non-nullable testCase field."); + } + List stepListOrphanCheck = testCase.getStepList(); + for (Step stepListOrphanCheckStep : stepListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This TestCase (" + testCase + ") cannot be destroyed since the Step " + stepListOrphanCheckStep + " in its stepList field has a non-nullable testCase field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + List testPlanList = testCase.getTestPlanList(); + for (TestPlan testPlanListTestPlan : testPlanList) { + testPlanListTestPlan.getTestCaseList().remove(testCase); + testPlanListTestPlan = em.merge(testPlanListTestPlan); + } + em.remove(testCase); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findTestCaseEntities() { + return findTestCaseEntities(true, -1, -1); + } + + public List findTestCaseEntities(int maxResults, int firstResult) { + return findTestCaseEntities(false, maxResults, firstResult); + } + + private List findTestCaseEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(TestCase.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public TestCase findTestCase(Integer id) { + EntityManager em = getEntityManager(); + try { + return em.find(TestCase.class, id); + } + finally { + em.close(); + } + } + + public int getTestCaseCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(TestCase.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/TestPlanJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/TestPlanJpaController.java index 764716b7..ffd165a6 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/TestPlanJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/TestPlanJpaController.java @@ -13,368 +13,368 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.TestPlan; -import com.validation.manager.core.db.TestProject; -import com.validation.manager.core.db.TestCase; -import com.validation.manager.core.db.TestPlanPK; -import java.util.ArrayList; -import java.util.List; -import com.validation.manager.core.db.UserTestPlanRole; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import com.validation.manager.core.db.controller.exceptions.PreexistingEntityException; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class TestPlanJpaController implements Serializable { - - public TestPlanJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(TestPlan testPlan) throws PreexistingEntityException, Exception { - if (testPlan.getTestPlanPK() == null) { - testPlan.setTestPlanPK(new TestPlanPK()); - } - if (testPlan.getTestCaseList() == null) { - testPlan.setTestCaseList(new ArrayList()); - } - if (testPlan.getTestPlanList() == null) { - testPlan.setTestPlanList(new ArrayList()); - } - if (testPlan.getUserTestPlanRoleList() == null) { - testPlan.setUserTestPlanRoleList(new ArrayList()); - } - testPlan.getTestPlanPK().setTestProjectId(testPlan.getTestProject().getId()); - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - TestPlan testPlanRel = testPlan.getTestPlan(); - if (testPlanRel != null) { - testPlanRel = em.getReference(testPlanRel.getClass(), testPlanRel.getTestPlanPK()); - testPlan.setTestPlan(testPlanRel); - } - TestProject testProject = testPlan.getTestProject(); - if (testProject != null) { - testProject = em.getReference(testProject.getClass(), testProject.getId()); - testPlan.setTestProject(testProject); - } - List attachedTestCaseList = new ArrayList(); - for (TestCase testCaseListTestCaseToAttach : testPlan.getTestCaseList()) { - testCaseListTestCaseToAttach = em.getReference(testCaseListTestCaseToAttach.getClass(), testCaseListTestCaseToAttach.getId()); - attachedTestCaseList.add(testCaseListTestCaseToAttach); - } - testPlan.setTestCaseList(attachedTestCaseList); - List attachedTestPlanList = new ArrayList(); - for (TestPlan testPlanListTestPlanToAttach : testPlan.getTestPlanList()) { - testPlanListTestPlanToAttach = em.getReference(testPlanListTestPlanToAttach.getClass(), testPlanListTestPlanToAttach.getTestPlanPK()); - attachedTestPlanList.add(testPlanListTestPlanToAttach); - } - testPlan.setTestPlanList(attachedTestPlanList); - List attachedUserTestPlanRoleList = new ArrayList(); - for (UserTestPlanRole userTestPlanRoleListUserTestPlanRoleToAttach : testPlan.getUserTestPlanRoleList()) { - userTestPlanRoleListUserTestPlanRoleToAttach = em.getReference(userTestPlanRoleListUserTestPlanRoleToAttach.getClass(), userTestPlanRoleListUserTestPlanRoleToAttach.getUserTestPlanRolePK()); - attachedUserTestPlanRoleList.add(userTestPlanRoleListUserTestPlanRoleToAttach); - } - testPlan.setUserTestPlanRoleList(attachedUserTestPlanRoleList); - em.persist(testPlan); - if (testPlanRel != null) { - testPlanRel.getTestPlanList().add(testPlan); - testPlanRel = em.merge(testPlanRel); - } - if (testProject != null) { - testProject.getTestPlanList().add(testPlan); - testProject = em.merge(testProject); - } - for (TestCase testCaseListTestCase : testPlan.getTestCaseList()) { - testCaseListTestCase.getTestPlanList().add(testPlan); - testCaseListTestCase = em.merge(testCaseListTestCase); - } - for (TestPlan testPlanListTestPlan : testPlan.getTestPlanList()) { - TestPlan oldTestPlanOfTestPlanListTestPlan = testPlanListTestPlan.getTestPlan(); - testPlanListTestPlan.setTestPlan(testPlan); - testPlanListTestPlan = em.merge(testPlanListTestPlan); - if (oldTestPlanOfTestPlanListTestPlan != null) { - oldTestPlanOfTestPlanListTestPlan.getTestPlanList().remove(testPlanListTestPlan); - oldTestPlanOfTestPlanListTestPlan = em.merge(oldTestPlanOfTestPlanListTestPlan); - } - } - for (UserTestPlanRole userTestPlanRoleListUserTestPlanRole : testPlan.getUserTestPlanRoleList()) { - TestPlan oldTestPlanOfUserTestPlanRoleListUserTestPlanRole = userTestPlanRoleListUserTestPlanRole.getTestPlan(); - userTestPlanRoleListUserTestPlanRole.setTestPlan(testPlan); - userTestPlanRoleListUserTestPlanRole = em.merge(userTestPlanRoleListUserTestPlanRole); - if (oldTestPlanOfUserTestPlanRoleListUserTestPlanRole != null) { - oldTestPlanOfUserTestPlanRoleListUserTestPlanRole.getUserTestPlanRoleList().remove(userTestPlanRoleListUserTestPlanRole); - oldTestPlanOfUserTestPlanRoleListUserTestPlanRole = em.merge(oldTestPlanOfUserTestPlanRoleListUserTestPlanRole); - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - if (findTestPlan(testPlan.getTestPlanPK()) != null) { - throw new PreexistingEntityException("TestPlan " + testPlan + " already exists.", ex); - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(TestPlan testPlan) throws IllegalOrphanException, NonexistentEntityException, Exception { - testPlan.getTestPlanPK().setTestProjectId(testPlan.getTestProject().getId()); - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - TestPlan persistentTestPlan = em.find(TestPlan.class, testPlan.getTestPlanPK()); - TestPlan testPlanRelOld = persistentTestPlan.getTestPlan(); - TestPlan testPlanRelNew = testPlan.getTestPlan(); - TestProject testProjectOld = persistentTestPlan.getTestProject(); - TestProject testProjectNew = testPlan.getTestProject(); - List testCaseListOld = persistentTestPlan.getTestCaseList(); - List testCaseListNew = testPlan.getTestCaseList(); - List testPlanListOld = persistentTestPlan.getTestPlanList(); - List testPlanListNew = testPlan.getTestPlanList(); - List userTestPlanRoleListOld = persistentTestPlan.getUserTestPlanRoleList(); - List userTestPlanRoleListNew = testPlan.getUserTestPlanRoleList(); - List illegalOrphanMessages = null; - for (UserTestPlanRole userTestPlanRoleListOldUserTestPlanRole : userTestPlanRoleListOld) { - if (!userTestPlanRoleListNew.contains(userTestPlanRoleListOldUserTestPlanRole)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain UserTestPlanRole " + userTestPlanRoleListOldUserTestPlanRole + " since its testPlan field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - if (testPlanRelNew != null) { - testPlanRelNew = em.getReference(testPlanRelNew.getClass(), testPlanRelNew.getTestPlanPK()); - testPlan.setTestPlan(testPlanRelNew); - } - if (testProjectNew != null) { - testProjectNew = em.getReference(testProjectNew.getClass(), testProjectNew.getId()); - testPlan.setTestProject(testProjectNew); - } - List attachedTestCaseListNew = new ArrayList(); - for (TestCase testCaseListNewTestCaseToAttach : testCaseListNew) { - testCaseListNewTestCaseToAttach = em.getReference(testCaseListNewTestCaseToAttach.getClass(), testCaseListNewTestCaseToAttach.getId()); - attachedTestCaseListNew.add(testCaseListNewTestCaseToAttach); - } - testCaseListNew = attachedTestCaseListNew; - testPlan.setTestCaseList(testCaseListNew); - List attachedTestPlanListNew = new ArrayList(); - for (TestPlan testPlanListNewTestPlanToAttach : testPlanListNew) { - testPlanListNewTestPlanToAttach = em.getReference(testPlanListNewTestPlanToAttach.getClass(), testPlanListNewTestPlanToAttach.getTestPlanPK()); - attachedTestPlanListNew.add(testPlanListNewTestPlanToAttach); - } - testPlanListNew = attachedTestPlanListNew; - testPlan.setTestPlanList(testPlanListNew); - List attachedUserTestPlanRoleListNew = new ArrayList(); - for (UserTestPlanRole userTestPlanRoleListNewUserTestPlanRoleToAttach : userTestPlanRoleListNew) { - userTestPlanRoleListNewUserTestPlanRoleToAttach = em.getReference(userTestPlanRoleListNewUserTestPlanRoleToAttach.getClass(), userTestPlanRoleListNewUserTestPlanRoleToAttach.getUserTestPlanRolePK()); - attachedUserTestPlanRoleListNew.add(userTestPlanRoleListNewUserTestPlanRoleToAttach); - } - userTestPlanRoleListNew = attachedUserTestPlanRoleListNew; - testPlan.setUserTestPlanRoleList(userTestPlanRoleListNew); - testPlan = em.merge(testPlan); - if (testPlanRelOld != null && !testPlanRelOld.equals(testPlanRelNew)) { - testPlanRelOld.getTestPlanList().remove(testPlan); - testPlanRelOld = em.merge(testPlanRelOld); - } - if (testPlanRelNew != null && !testPlanRelNew.equals(testPlanRelOld)) { - testPlanRelNew.getTestPlanList().add(testPlan); - testPlanRelNew = em.merge(testPlanRelNew); - } - if (testProjectOld != null && !testProjectOld.equals(testProjectNew)) { - testProjectOld.getTestPlanList().remove(testPlan); - testProjectOld = em.merge(testProjectOld); - } - if (testProjectNew != null && !testProjectNew.equals(testProjectOld)) { - testProjectNew.getTestPlanList().add(testPlan); - testProjectNew = em.merge(testProjectNew); - } - for (TestCase testCaseListOldTestCase : testCaseListOld) { - if (!testCaseListNew.contains(testCaseListOldTestCase)) { - testCaseListOldTestCase.getTestPlanList().remove(testPlan); - testCaseListOldTestCase = em.merge(testCaseListOldTestCase); - } - } - for (TestCase testCaseListNewTestCase : testCaseListNew) { - if (!testCaseListOld.contains(testCaseListNewTestCase)) { - testCaseListNewTestCase.getTestPlanList().add(testPlan); - testCaseListNewTestCase = em.merge(testCaseListNewTestCase); - } - } - for (TestPlan testPlanListOldTestPlan : testPlanListOld) { - if (!testPlanListNew.contains(testPlanListOldTestPlan)) { - testPlanListOldTestPlan.setTestPlan(null); - testPlanListOldTestPlan = em.merge(testPlanListOldTestPlan); - } - } - for (TestPlan testPlanListNewTestPlan : testPlanListNew) { - if (!testPlanListOld.contains(testPlanListNewTestPlan)) { - TestPlan oldTestPlanOfTestPlanListNewTestPlan = testPlanListNewTestPlan.getTestPlan(); - testPlanListNewTestPlan.setTestPlan(testPlan); - testPlanListNewTestPlan = em.merge(testPlanListNewTestPlan); - if (oldTestPlanOfTestPlanListNewTestPlan != null && !oldTestPlanOfTestPlanListNewTestPlan.equals(testPlan)) { - oldTestPlanOfTestPlanListNewTestPlan.getTestPlanList().remove(testPlanListNewTestPlan); - oldTestPlanOfTestPlanListNewTestPlan = em.merge(oldTestPlanOfTestPlanListNewTestPlan); - } - } - } - for (UserTestPlanRole userTestPlanRoleListNewUserTestPlanRole : userTestPlanRoleListNew) { - if (!userTestPlanRoleListOld.contains(userTestPlanRoleListNewUserTestPlanRole)) { - TestPlan oldTestPlanOfUserTestPlanRoleListNewUserTestPlanRole = userTestPlanRoleListNewUserTestPlanRole.getTestPlan(); - userTestPlanRoleListNewUserTestPlanRole.setTestPlan(testPlan); - userTestPlanRoleListNewUserTestPlanRole = em.merge(userTestPlanRoleListNewUserTestPlanRole); - if (oldTestPlanOfUserTestPlanRoleListNewUserTestPlanRole != null && !oldTestPlanOfUserTestPlanRoleListNewUserTestPlanRole.equals(testPlan)) { - oldTestPlanOfUserTestPlanRoleListNewUserTestPlanRole.getUserTestPlanRoleList().remove(userTestPlanRoleListNewUserTestPlanRole); - oldTestPlanOfUserTestPlanRoleListNewUserTestPlanRole = em.merge(oldTestPlanOfUserTestPlanRoleListNewUserTestPlanRole); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - TestPlanPK id = testPlan.getTestPlanPK(); - if (findTestPlan(id) == null) { - throw new NonexistentEntityException("The testPlan with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(TestPlanPK id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - TestPlan testPlan; - try { - testPlan = em.getReference(TestPlan.class, id); - testPlan.getTestPlanPK(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The testPlan with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List userTestPlanRoleListOrphanCheck = testPlan.getUserTestPlanRoleList(); - for (UserTestPlanRole userTestPlanRoleListOrphanCheckUserTestPlanRole : userTestPlanRoleListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This TestPlan (" + testPlan + ") cannot be destroyed since the UserTestPlanRole " + userTestPlanRoleListOrphanCheckUserTestPlanRole + " in its userTestPlanRoleList field has a non-nullable testPlan field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - TestPlan testPlanRel = testPlan.getTestPlan(); - if (testPlanRel != null) { - testPlanRel.getTestPlanList().remove(testPlan); - testPlanRel = em.merge(testPlanRel); - } - TestProject testProject = testPlan.getTestProject(); - if (testProject != null) { - testProject.getTestPlanList().remove(testPlan); - testProject = em.merge(testProject); - } - List testCaseList = testPlan.getTestCaseList(); - for (TestCase testCaseListTestCase : testCaseList) { - testCaseListTestCase.getTestPlanList().remove(testPlan); - testCaseListTestCase = em.merge(testCaseListTestCase); - } - List testPlanList = testPlan.getTestPlanList(); - for (TestPlan testPlanListTestPlan : testPlanList) { - testPlanListTestPlan.setTestPlan(null); - testPlanListTestPlan = em.merge(testPlanListTestPlan); - } - em.remove(testPlan); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findTestPlanEntities() { - return findTestPlanEntities(true, -1, -1); - } - - public List findTestPlanEntities(int maxResults, int firstResult) { - return findTestPlanEntities(false, maxResults, firstResult); - } - - private List findTestPlanEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(TestPlan.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public TestPlan findTestPlan(TestPlanPK id) { - EntityManager em = getEntityManager(); - try { - return em.find(TestPlan.class, id); - } - finally { - em.close(); - } - } - - public int getTestPlanCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(TestPlan.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.TestPlan; +import com.validation.manager.core.db.TestProject; +import com.validation.manager.core.db.TestCase; +import com.validation.manager.core.db.TestPlanPK; +import java.util.ArrayList; +import java.util.List; +import com.validation.manager.core.db.UserTestPlanRole; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import com.validation.manager.core.db.controller.exceptions.PreexistingEntityException; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class TestPlanJpaController implements Serializable { + + public TestPlanJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(TestPlan testPlan) throws PreexistingEntityException, Exception { + if (testPlan.getTestPlanPK() == null) { + testPlan.setTestPlanPK(new TestPlanPK()); + } + if (testPlan.getTestCaseList() == null) { + testPlan.setTestCaseList(new ArrayList<>()); + } + if (testPlan.getTestPlanList() == null) { + testPlan.setTestPlanList(new ArrayList<>()); + } + if (testPlan.getUserTestPlanRoleList() == null) { + testPlan.setUserTestPlanRoleList(new ArrayList<>()); + } + testPlan.getTestPlanPK().setTestProjectId(testPlan.getTestProject().getId()); + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + TestPlan testPlanRel = testPlan.getTestPlan(); + if (testPlanRel != null) { + testPlanRel = em.getReference(testPlanRel.getClass(), testPlanRel.getTestPlanPK()); + testPlan.setTestPlan(testPlanRel); + } + TestProject testProject = testPlan.getTestProject(); + if (testProject != null) { + testProject = em.getReference(testProject.getClass(), testProject.getId()); + testPlan.setTestProject(testProject); + } + List attachedTestCaseList = new ArrayList<>(); + for (TestCase testCaseListTestCaseToAttach : testPlan.getTestCaseList()) { + testCaseListTestCaseToAttach = em.getReference(testCaseListTestCaseToAttach.getClass(), testCaseListTestCaseToAttach.getId()); + attachedTestCaseList.add(testCaseListTestCaseToAttach); + } + testPlan.setTestCaseList(attachedTestCaseList); + List attachedTestPlanList = new ArrayList<>(); + for (TestPlan testPlanListTestPlanToAttach : testPlan.getTestPlanList()) { + testPlanListTestPlanToAttach = em.getReference(testPlanListTestPlanToAttach.getClass(), testPlanListTestPlanToAttach.getTestPlanPK()); + attachedTestPlanList.add(testPlanListTestPlanToAttach); + } + testPlan.setTestPlanList(attachedTestPlanList); + List attachedUserTestPlanRoleList = new ArrayList<>(); + for (UserTestPlanRole userTestPlanRoleListUserTestPlanRoleToAttach : testPlan.getUserTestPlanRoleList()) { + userTestPlanRoleListUserTestPlanRoleToAttach = em.getReference(userTestPlanRoleListUserTestPlanRoleToAttach.getClass(), userTestPlanRoleListUserTestPlanRoleToAttach.getUserTestPlanRolePK()); + attachedUserTestPlanRoleList.add(userTestPlanRoleListUserTestPlanRoleToAttach); + } + testPlan.setUserTestPlanRoleList(attachedUserTestPlanRoleList); + em.persist(testPlan); + if (testPlanRel != null) { + testPlanRel.getTestPlanList().add(testPlan); + testPlanRel = em.merge(testPlanRel); + } + if (testProject != null) { + testProject.getTestPlanList().add(testPlan); + testProject = em.merge(testProject); + } + for (TestCase testCaseListTestCase : testPlan.getTestCaseList()) { + testCaseListTestCase.getTestPlanList().add(testPlan); + testCaseListTestCase = em.merge(testCaseListTestCase); + } + for (TestPlan testPlanListTestPlan : testPlan.getTestPlanList()) { + TestPlan oldTestPlanOfTestPlanListTestPlan = testPlanListTestPlan.getTestPlan(); + testPlanListTestPlan.setTestPlan(testPlan); + testPlanListTestPlan = em.merge(testPlanListTestPlan); + if (oldTestPlanOfTestPlanListTestPlan != null) { + oldTestPlanOfTestPlanListTestPlan.getTestPlanList().remove(testPlanListTestPlan); + oldTestPlanOfTestPlanListTestPlan = em.merge(oldTestPlanOfTestPlanListTestPlan); + } + } + for (UserTestPlanRole userTestPlanRoleListUserTestPlanRole : testPlan.getUserTestPlanRoleList()) { + TestPlan oldTestPlanOfUserTestPlanRoleListUserTestPlanRole = userTestPlanRoleListUserTestPlanRole.getTestPlan(); + userTestPlanRoleListUserTestPlanRole.setTestPlan(testPlan); + userTestPlanRoleListUserTestPlanRole = em.merge(userTestPlanRoleListUserTestPlanRole); + if (oldTestPlanOfUserTestPlanRoleListUserTestPlanRole != null) { + oldTestPlanOfUserTestPlanRoleListUserTestPlanRole.getUserTestPlanRoleList().remove(userTestPlanRoleListUserTestPlanRole); + oldTestPlanOfUserTestPlanRoleListUserTestPlanRole = em.merge(oldTestPlanOfUserTestPlanRoleListUserTestPlanRole); + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + if (findTestPlan(testPlan.getTestPlanPK()) != null) { + throw new PreexistingEntityException("TestPlan " + testPlan + " already exists.", ex); + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(TestPlan testPlan) throws IllegalOrphanException, NonexistentEntityException, Exception { + testPlan.getTestPlanPK().setTestProjectId(testPlan.getTestProject().getId()); + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + TestPlan persistentTestPlan = em.find(TestPlan.class, testPlan.getTestPlanPK()); + TestPlan testPlanRelOld = persistentTestPlan.getTestPlan(); + TestPlan testPlanRelNew = testPlan.getTestPlan(); + TestProject testProjectOld = persistentTestPlan.getTestProject(); + TestProject testProjectNew = testPlan.getTestProject(); + List testCaseListOld = persistentTestPlan.getTestCaseList(); + List testCaseListNew = testPlan.getTestCaseList(); + List testPlanListOld = persistentTestPlan.getTestPlanList(); + List testPlanListNew = testPlan.getTestPlanList(); + List userTestPlanRoleListOld = persistentTestPlan.getUserTestPlanRoleList(); + List userTestPlanRoleListNew = testPlan.getUserTestPlanRoleList(); + List illegalOrphanMessages = null; + for (UserTestPlanRole userTestPlanRoleListOldUserTestPlanRole : userTestPlanRoleListOld) { + if (!userTestPlanRoleListNew.contains(userTestPlanRoleListOldUserTestPlanRole)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain UserTestPlanRole " + userTestPlanRoleListOldUserTestPlanRole + " since its testPlan field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + if (testPlanRelNew != null) { + testPlanRelNew = em.getReference(testPlanRelNew.getClass(), testPlanRelNew.getTestPlanPK()); + testPlan.setTestPlan(testPlanRelNew); + } + if (testProjectNew != null) { + testProjectNew = em.getReference(testProjectNew.getClass(), testProjectNew.getId()); + testPlan.setTestProject(testProjectNew); + } + List attachedTestCaseListNew = new ArrayList<>(); + for (TestCase testCaseListNewTestCaseToAttach : testCaseListNew) { + testCaseListNewTestCaseToAttach = em.getReference(testCaseListNewTestCaseToAttach.getClass(), testCaseListNewTestCaseToAttach.getId()); + attachedTestCaseListNew.add(testCaseListNewTestCaseToAttach); + } + testCaseListNew = attachedTestCaseListNew; + testPlan.setTestCaseList(testCaseListNew); + List attachedTestPlanListNew = new ArrayList<>(); + for (TestPlan testPlanListNewTestPlanToAttach : testPlanListNew) { + testPlanListNewTestPlanToAttach = em.getReference(testPlanListNewTestPlanToAttach.getClass(), testPlanListNewTestPlanToAttach.getTestPlanPK()); + attachedTestPlanListNew.add(testPlanListNewTestPlanToAttach); + } + testPlanListNew = attachedTestPlanListNew; + testPlan.setTestPlanList(testPlanListNew); + List attachedUserTestPlanRoleListNew = new ArrayList<>(); + for (UserTestPlanRole userTestPlanRoleListNewUserTestPlanRoleToAttach : userTestPlanRoleListNew) { + userTestPlanRoleListNewUserTestPlanRoleToAttach = em.getReference(userTestPlanRoleListNewUserTestPlanRoleToAttach.getClass(), userTestPlanRoleListNewUserTestPlanRoleToAttach.getUserTestPlanRolePK()); + attachedUserTestPlanRoleListNew.add(userTestPlanRoleListNewUserTestPlanRoleToAttach); + } + userTestPlanRoleListNew = attachedUserTestPlanRoleListNew; + testPlan.setUserTestPlanRoleList(userTestPlanRoleListNew); + testPlan = em.merge(testPlan); + if (testPlanRelOld != null && !testPlanRelOld.equals(testPlanRelNew)) { + testPlanRelOld.getTestPlanList().remove(testPlan); + testPlanRelOld = em.merge(testPlanRelOld); + } + if (testPlanRelNew != null && !testPlanRelNew.equals(testPlanRelOld)) { + testPlanRelNew.getTestPlanList().add(testPlan); + testPlanRelNew = em.merge(testPlanRelNew); + } + if (testProjectOld != null && !testProjectOld.equals(testProjectNew)) { + testProjectOld.getTestPlanList().remove(testPlan); + testProjectOld = em.merge(testProjectOld); + } + if (testProjectNew != null && !testProjectNew.equals(testProjectOld)) { + testProjectNew.getTestPlanList().add(testPlan); + testProjectNew = em.merge(testProjectNew); + } + for (TestCase testCaseListOldTestCase : testCaseListOld) { + if (!testCaseListNew.contains(testCaseListOldTestCase)) { + testCaseListOldTestCase.getTestPlanList().remove(testPlan); + testCaseListOldTestCase = em.merge(testCaseListOldTestCase); + } + } + for (TestCase testCaseListNewTestCase : testCaseListNew) { + if (!testCaseListOld.contains(testCaseListNewTestCase)) { + testCaseListNewTestCase.getTestPlanList().add(testPlan); + testCaseListNewTestCase = em.merge(testCaseListNewTestCase); + } + } + for (TestPlan testPlanListOldTestPlan : testPlanListOld) { + if (!testPlanListNew.contains(testPlanListOldTestPlan)) { + testPlanListOldTestPlan.setTestPlan(null); + testPlanListOldTestPlan = em.merge(testPlanListOldTestPlan); + } + } + for (TestPlan testPlanListNewTestPlan : testPlanListNew) { + if (!testPlanListOld.contains(testPlanListNewTestPlan)) { + TestPlan oldTestPlanOfTestPlanListNewTestPlan = testPlanListNewTestPlan.getTestPlan(); + testPlanListNewTestPlan.setTestPlan(testPlan); + testPlanListNewTestPlan = em.merge(testPlanListNewTestPlan); + if (oldTestPlanOfTestPlanListNewTestPlan != null && !oldTestPlanOfTestPlanListNewTestPlan.equals(testPlan)) { + oldTestPlanOfTestPlanListNewTestPlan.getTestPlanList().remove(testPlanListNewTestPlan); + oldTestPlanOfTestPlanListNewTestPlan = em.merge(oldTestPlanOfTestPlanListNewTestPlan); + } + } + } + for (UserTestPlanRole userTestPlanRoleListNewUserTestPlanRole : userTestPlanRoleListNew) { + if (!userTestPlanRoleListOld.contains(userTestPlanRoleListNewUserTestPlanRole)) { + TestPlan oldTestPlanOfUserTestPlanRoleListNewUserTestPlanRole = userTestPlanRoleListNewUserTestPlanRole.getTestPlan(); + userTestPlanRoleListNewUserTestPlanRole.setTestPlan(testPlan); + userTestPlanRoleListNewUserTestPlanRole = em.merge(userTestPlanRoleListNewUserTestPlanRole); + if (oldTestPlanOfUserTestPlanRoleListNewUserTestPlanRole != null && !oldTestPlanOfUserTestPlanRoleListNewUserTestPlanRole.equals(testPlan)) { + oldTestPlanOfUserTestPlanRoleListNewUserTestPlanRole.getUserTestPlanRoleList().remove(userTestPlanRoleListNewUserTestPlanRole); + oldTestPlanOfUserTestPlanRoleListNewUserTestPlanRole = em.merge(oldTestPlanOfUserTestPlanRoleListNewUserTestPlanRole); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + TestPlanPK id = testPlan.getTestPlanPK(); + if (findTestPlan(id) == null) { + throw new NonexistentEntityException("The testPlan with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(TestPlanPK id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + TestPlan testPlan; + try { + testPlan = em.getReference(TestPlan.class, id); + testPlan.getTestPlanPK(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The testPlan with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List userTestPlanRoleListOrphanCheck = testPlan.getUserTestPlanRoleList(); + for (UserTestPlanRole userTestPlanRoleListOrphanCheckUserTestPlanRole : userTestPlanRoleListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This TestPlan (" + testPlan + ") cannot be destroyed since the UserTestPlanRole " + userTestPlanRoleListOrphanCheckUserTestPlanRole + " in its userTestPlanRoleList field has a non-nullable testPlan field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + TestPlan testPlanRel = testPlan.getTestPlan(); + if (testPlanRel != null) { + testPlanRel.getTestPlanList().remove(testPlan); + testPlanRel = em.merge(testPlanRel); + } + TestProject testProject = testPlan.getTestProject(); + if (testProject != null) { + testProject.getTestPlanList().remove(testPlan); + testProject = em.merge(testProject); + } + List testCaseList = testPlan.getTestCaseList(); + for (TestCase testCaseListTestCase : testCaseList) { + testCaseListTestCase.getTestPlanList().remove(testPlan); + testCaseListTestCase = em.merge(testCaseListTestCase); + } + List testPlanList = testPlan.getTestPlanList(); + for (TestPlan testPlanListTestPlan : testPlanList) { + testPlanListTestPlan.setTestPlan(null); + testPlanListTestPlan = em.merge(testPlanListTestPlan); + } + em.remove(testPlan); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findTestPlanEntities() { + return findTestPlanEntities(true, -1, -1); + } + + public List findTestPlanEntities(int maxResults, int firstResult) { + return findTestPlanEntities(false, maxResults, firstResult); + } + + private List findTestPlanEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(TestPlan.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public TestPlan findTestPlan(TestPlanPK id) { + EntityManager em = getEntityManager(); + try { + return em.find(TestPlan.class, id); + } + finally { + em.close(); + } + } + + public int getTestPlanCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(TestPlan.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/TestProjectJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/TestProjectJpaController.java index aeb5ddc4..ff628e31 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/TestProjectJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/TestProjectJpaController.java @@ -13,303 +13,303 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.Project; -import java.util.ArrayList; -import java.util.List; -import com.validation.manager.core.db.UserTestProjectRole; -import com.validation.manager.core.db.TestPlan; -import com.validation.manager.core.db.TestProject; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class TestProjectJpaController implements Serializable { - - public TestProjectJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(TestProject testProject) { - if (testProject.getProjectList() == null) { - testProject.setProjectList(new ArrayList()); - } - if (testProject.getUserTestProjectRoleList() == null) { - testProject.setUserTestProjectRoleList(new ArrayList()); - } - if (testProject.getTestPlanList() == null) { - testProject.setTestPlanList(new ArrayList()); - } - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - List attachedProjectList = new ArrayList(); - for (Project projectListProjectToAttach : testProject.getProjectList()) { - projectListProjectToAttach = em.getReference(projectListProjectToAttach.getClass(), projectListProjectToAttach.getId()); - attachedProjectList.add(projectListProjectToAttach); - } - testProject.setProjectList(attachedProjectList); - List attachedUserTestProjectRoleList = new ArrayList(); - for (UserTestProjectRole userTestProjectRoleListUserTestProjectRoleToAttach : testProject.getUserTestProjectRoleList()) { - userTestProjectRoleListUserTestProjectRoleToAttach = em.getReference(userTestProjectRoleListUserTestProjectRoleToAttach.getClass(), userTestProjectRoleListUserTestProjectRoleToAttach.getUserTestProjectRolePK()); - attachedUserTestProjectRoleList.add(userTestProjectRoleListUserTestProjectRoleToAttach); - } - testProject.setUserTestProjectRoleList(attachedUserTestProjectRoleList); - List attachedTestPlanList = new ArrayList(); - for (TestPlan testPlanListTestPlanToAttach : testProject.getTestPlanList()) { - testPlanListTestPlanToAttach = em.getReference(testPlanListTestPlanToAttach.getClass(), testPlanListTestPlanToAttach.getTestPlanPK()); - attachedTestPlanList.add(testPlanListTestPlanToAttach); - } - testProject.setTestPlanList(attachedTestPlanList); - em.persist(testProject); - for (Project projectListProject : testProject.getProjectList()) { - projectListProject.getTestProjectList().add(testProject); - projectListProject = em.merge(projectListProject); - } - for (UserTestProjectRole userTestProjectRoleListUserTestProjectRole : testProject.getUserTestProjectRoleList()) { - TestProject oldTestProjectOfUserTestProjectRoleListUserTestProjectRole = userTestProjectRoleListUserTestProjectRole.getTestProject(); - userTestProjectRoleListUserTestProjectRole.setTestProject(testProject); - userTestProjectRoleListUserTestProjectRole = em.merge(userTestProjectRoleListUserTestProjectRole); - if (oldTestProjectOfUserTestProjectRoleListUserTestProjectRole != null) { - oldTestProjectOfUserTestProjectRoleListUserTestProjectRole.getUserTestProjectRoleList().remove(userTestProjectRoleListUserTestProjectRole); - oldTestProjectOfUserTestProjectRoleListUserTestProjectRole = em.merge(oldTestProjectOfUserTestProjectRoleListUserTestProjectRole); - } - } - for (TestPlan testPlanListTestPlan : testProject.getTestPlanList()) { - TestProject oldTestProjectOfTestPlanListTestPlan = testPlanListTestPlan.getTestProject(); - testPlanListTestPlan.setTestProject(testProject); - testPlanListTestPlan = em.merge(testPlanListTestPlan); - if (oldTestProjectOfTestPlanListTestPlan != null) { - oldTestProjectOfTestPlanListTestPlan.getTestPlanList().remove(testPlanListTestPlan); - oldTestProjectOfTestPlanListTestPlan = em.merge(oldTestProjectOfTestPlanListTestPlan); - } - } - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(TestProject testProject) throws IllegalOrphanException, NonexistentEntityException, Exception { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - TestProject persistentTestProject = em.find(TestProject.class, testProject.getId()); - List projectListOld = persistentTestProject.getProjectList(); - List projectListNew = testProject.getProjectList(); - List userTestProjectRoleListOld = persistentTestProject.getUserTestProjectRoleList(); - List userTestProjectRoleListNew = testProject.getUserTestProjectRoleList(); - List testPlanListOld = persistentTestProject.getTestPlanList(); - List testPlanListNew = testProject.getTestPlanList(); - List illegalOrphanMessages = null; - for (UserTestProjectRole userTestProjectRoleListOldUserTestProjectRole : userTestProjectRoleListOld) { - if (!userTestProjectRoleListNew.contains(userTestProjectRoleListOldUserTestProjectRole)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain UserTestProjectRole " + userTestProjectRoleListOldUserTestProjectRole + " since its testProject field is not nullable."); - } - } - for (TestPlan testPlanListOldTestPlan : testPlanListOld) { - if (!testPlanListNew.contains(testPlanListOldTestPlan)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain TestPlan " + testPlanListOldTestPlan + " since its testProject field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - List attachedProjectListNew = new ArrayList(); - for (Project projectListNewProjectToAttach : projectListNew) { - projectListNewProjectToAttach = em.getReference(projectListNewProjectToAttach.getClass(), projectListNewProjectToAttach.getId()); - attachedProjectListNew.add(projectListNewProjectToAttach); - } - projectListNew = attachedProjectListNew; - testProject.setProjectList(projectListNew); - List attachedUserTestProjectRoleListNew = new ArrayList(); - for (UserTestProjectRole userTestProjectRoleListNewUserTestProjectRoleToAttach : userTestProjectRoleListNew) { - userTestProjectRoleListNewUserTestProjectRoleToAttach = em.getReference(userTestProjectRoleListNewUserTestProjectRoleToAttach.getClass(), userTestProjectRoleListNewUserTestProjectRoleToAttach.getUserTestProjectRolePK()); - attachedUserTestProjectRoleListNew.add(userTestProjectRoleListNewUserTestProjectRoleToAttach); - } - userTestProjectRoleListNew = attachedUserTestProjectRoleListNew; - testProject.setUserTestProjectRoleList(userTestProjectRoleListNew); - List attachedTestPlanListNew = new ArrayList(); - for (TestPlan testPlanListNewTestPlanToAttach : testPlanListNew) { - testPlanListNewTestPlanToAttach = em.getReference(testPlanListNewTestPlanToAttach.getClass(), testPlanListNewTestPlanToAttach.getTestPlanPK()); - attachedTestPlanListNew.add(testPlanListNewTestPlanToAttach); - } - testPlanListNew = attachedTestPlanListNew; - testProject.setTestPlanList(testPlanListNew); - testProject = em.merge(testProject); - for (Project projectListOldProject : projectListOld) { - if (!projectListNew.contains(projectListOldProject)) { - projectListOldProject.getTestProjectList().remove(testProject); - projectListOldProject = em.merge(projectListOldProject); - } - } - for (Project projectListNewProject : projectListNew) { - if (!projectListOld.contains(projectListNewProject)) { - projectListNewProject.getTestProjectList().add(testProject); - projectListNewProject = em.merge(projectListNewProject); - } - } - for (UserTestProjectRole userTestProjectRoleListNewUserTestProjectRole : userTestProjectRoleListNew) { - if (!userTestProjectRoleListOld.contains(userTestProjectRoleListNewUserTestProjectRole)) { - TestProject oldTestProjectOfUserTestProjectRoleListNewUserTestProjectRole = userTestProjectRoleListNewUserTestProjectRole.getTestProject(); - userTestProjectRoleListNewUserTestProjectRole.setTestProject(testProject); - userTestProjectRoleListNewUserTestProjectRole = em.merge(userTestProjectRoleListNewUserTestProjectRole); - if (oldTestProjectOfUserTestProjectRoleListNewUserTestProjectRole != null && !oldTestProjectOfUserTestProjectRoleListNewUserTestProjectRole.equals(testProject)) { - oldTestProjectOfUserTestProjectRoleListNewUserTestProjectRole.getUserTestProjectRoleList().remove(userTestProjectRoleListNewUserTestProjectRole); - oldTestProjectOfUserTestProjectRoleListNewUserTestProjectRole = em.merge(oldTestProjectOfUserTestProjectRoleListNewUserTestProjectRole); - } - } - } - for (TestPlan testPlanListNewTestPlan : testPlanListNew) { - if (!testPlanListOld.contains(testPlanListNewTestPlan)) { - TestProject oldTestProjectOfTestPlanListNewTestPlan = testPlanListNewTestPlan.getTestProject(); - testPlanListNewTestPlan.setTestProject(testProject); - testPlanListNewTestPlan = em.merge(testPlanListNewTestPlan); - if (oldTestProjectOfTestPlanListNewTestPlan != null && !oldTestProjectOfTestPlanListNewTestPlan.equals(testProject)) { - oldTestProjectOfTestPlanListNewTestPlan.getTestPlanList().remove(testPlanListNewTestPlan); - oldTestProjectOfTestPlanListNewTestPlan = em.merge(oldTestProjectOfTestPlanListNewTestPlan); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - Integer id = testProject.getId(); - if (findTestProject(id) == null) { - throw new NonexistentEntityException("The testProject with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - TestProject testProject; - try { - testProject = em.getReference(TestProject.class, id); - testProject.getId(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The testProject with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List userTestProjectRoleListOrphanCheck = testProject.getUserTestProjectRoleList(); - for (UserTestProjectRole userTestProjectRoleListOrphanCheckUserTestProjectRole : userTestProjectRoleListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This TestProject (" + testProject + ") cannot be destroyed since the UserTestProjectRole " + userTestProjectRoleListOrphanCheckUserTestProjectRole + " in its userTestProjectRoleList field has a non-nullable testProject field."); - } - List testPlanListOrphanCheck = testProject.getTestPlanList(); - for (TestPlan testPlanListOrphanCheckTestPlan : testPlanListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This TestProject (" + testProject + ") cannot be destroyed since the TestPlan " + testPlanListOrphanCheckTestPlan + " in its testPlanList field has a non-nullable testProject field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - List projectList = testProject.getProjectList(); - for (Project projectListProject : projectList) { - projectListProject.getTestProjectList().remove(testProject); - projectListProject = em.merge(projectListProject); - } - em.remove(testProject); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findTestProjectEntities() { - return findTestProjectEntities(true, -1, -1); - } - - public List findTestProjectEntities(int maxResults, int firstResult) { - return findTestProjectEntities(false, maxResults, firstResult); - } - - private List findTestProjectEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(TestProject.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public TestProject findTestProject(Integer id) { - EntityManager em = getEntityManager(); - try { - return em.find(TestProject.class, id); - } - finally { - em.close(); - } - } - - public int getTestProjectCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(TestProject.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.Project; +import java.util.ArrayList; +import java.util.List; +import com.validation.manager.core.db.UserTestProjectRole; +import com.validation.manager.core.db.TestPlan; +import com.validation.manager.core.db.TestProject; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class TestProjectJpaController implements Serializable { + + public TestProjectJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(TestProject testProject) { + if (testProject.getProjectList() == null) { + testProject.setProjectList(new ArrayList<>()); + } + if (testProject.getUserTestProjectRoleList() == null) { + testProject.setUserTestProjectRoleList(new ArrayList<>()); + } + if (testProject.getTestPlanList() == null) { + testProject.setTestPlanList(new ArrayList<>()); + } + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + List attachedProjectList = new ArrayList<>(); + for (Project projectListProjectToAttach : testProject.getProjectList()) { + projectListProjectToAttach = em.getReference(projectListProjectToAttach.getClass(), projectListProjectToAttach.getId()); + attachedProjectList.add(projectListProjectToAttach); + } + testProject.setProjectList(attachedProjectList); + List attachedUserTestProjectRoleList = new ArrayList<>(); + for (UserTestProjectRole userTestProjectRoleListUserTestProjectRoleToAttach : testProject.getUserTestProjectRoleList()) { + userTestProjectRoleListUserTestProjectRoleToAttach = em.getReference(userTestProjectRoleListUserTestProjectRoleToAttach.getClass(), userTestProjectRoleListUserTestProjectRoleToAttach.getUserTestProjectRolePK()); + attachedUserTestProjectRoleList.add(userTestProjectRoleListUserTestProjectRoleToAttach); + } + testProject.setUserTestProjectRoleList(attachedUserTestProjectRoleList); + List attachedTestPlanList = new ArrayList<>(); + for (TestPlan testPlanListTestPlanToAttach : testProject.getTestPlanList()) { + testPlanListTestPlanToAttach = em.getReference(testPlanListTestPlanToAttach.getClass(), testPlanListTestPlanToAttach.getTestPlanPK()); + attachedTestPlanList.add(testPlanListTestPlanToAttach); + } + testProject.setTestPlanList(attachedTestPlanList); + em.persist(testProject); + for (Project projectListProject : testProject.getProjectList()) { + projectListProject.getTestProjectList().add(testProject); + projectListProject = em.merge(projectListProject); + } + for (UserTestProjectRole userTestProjectRoleListUserTestProjectRole : testProject.getUserTestProjectRoleList()) { + TestProject oldTestProjectOfUserTestProjectRoleListUserTestProjectRole = userTestProjectRoleListUserTestProjectRole.getTestProject(); + userTestProjectRoleListUserTestProjectRole.setTestProject(testProject); + userTestProjectRoleListUserTestProjectRole = em.merge(userTestProjectRoleListUserTestProjectRole); + if (oldTestProjectOfUserTestProjectRoleListUserTestProjectRole != null) { + oldTestProjectOfUserTestProjectRoleListUserTestProjectRole.getUserTestProjectRoleList().remove(userTestProjectRoleListUserTestProjectRole); + oldTestProjectOfUserTestProjectRoleListUserTestProjectRole = em.merge(oldTestProjectOfUserTestProjectRoleListUserTestProjectRole); + } + } + for (TestPlan testPlanListTestPlan : testProject.getTestPlanList()) { + TestProject oldTestProjectOfTestPlanListTestPlan = testPlanListTestPlan.getTestProject(); + testPlanListTestPlan.setTestProject(testProject); + testPlanListTestPlan = em.merge(testPlanListTestPlan); + if (oldTestProjectOfTestPlanListTestPlan != null) { + oldTestProjectOfTestPlanListTestPlan.getTestPlanList().remove(testPlanListTestPlan); + oldTestProjectOfTestPlanListTestPlan = em.merge(oldTestProjectOfTestPlanListTestPlan); + } + } + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(TestProject testProject) throws IllegalOrphanException, NonexistentEntityException, Exception { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + TestProject persistentTestProject = em.find(TestProject.class, testProject.getId()); + List projectListOld = persistentTestProject.getProjectList(); + List projectListNew = testProject.getProjectList(); + List userTestProjectRoleListOld = persistentTestProject.getUserTestProjectRoleList(); + List userTestProjectRoleListNew = testProject.getUserTestProjectRoleList(); + List testPlanListOld = persistentTestProject.getTestPlanList(); + List testPlanListNew = testProject.getTestPlanList(); + List illegalOrphanMessages = null; + for (UserTestProjectRole userTestProjectRoleListOldUserTestProjectRole : userTestProjectRoleListOld) { + if (!userTestProjectRoleListNew.contains(userTestProjectRoleListOldUserTestProjectRole)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain UserTestProjectRole " + userTestProjectRoleListOldUserTestProjectRole + " since its testProject field is not nullable."); + } + } + for (TestPlan testPlanListOldTestPlan : testPlanListOld) { + if (!testPlanListNew.contains(testPlanListOldTestPlan)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain TestPlan " + testPlanListOldTestPlan + " since its testProject field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + List attachedProjectListNew = new ArrayList<>(); + for (Project projectListNewProjectToAttach : projectListNew) { + projectListNewProjectToAttach = em.getReference(projectListNewProjectToAttach.getClass(), projectListNewProjectToAttach.getId()); + attachedProjectListNew.add(projectListNewProjectToAttach); + } + projectListNew = attachedProjectListNew; + testProject.setProjectList(projectListNew); + List attachedUserTestProjectRoleListNew = new ArrayList<>(); + for (UserTestProjectRole userTestProjectRoleListNewUserTestProjectRoleToAttach : userTestProjectRoleListNew) { + userTestProjectRoleListNewUserTestProjectRoleToAttach = em.getReference(userTestProjectRoleListNewUserTestProjectRoleToAttach.getClass(), userTestProjectRoleListNewUserTestProjectRoleToAttach.getUserTestProjectRolePK()); + attachedUserTestProjectRoleListNew.add(userTestProjectRoleListNewUserTestProjectRoleToAttach); + } + userTestProjectRoleListNew = attachedUserTestProjectRoleListNew; + testProject.setUserTestProjectRoleList(userTestProjectRoleListNew); + List attachedTestPlanListNew = new ArrayList<>(); + for (TestPlan testPlanListNewTestPlanToAttach : testPlanListNew) { + testPlanListNewTestPlanToAttach = em.getReference(testPlanListNewTestPlanToAttach.getClass(), testPlanListNewTestPlanToAttach.getTestPlanPK()); + attachedTestPlanListNew.add(testPlanListNewTestPlanToAttach); + } + testPlanListNew = attachedTestPlanListNew; + testProject.setTestPlanList(testPlanListNew); + testProject = em.merge(testProject); + for (Project projectListOldProject : projectListOld) { + if (!projectListNew.contains(projectListOldProject)) { + projectListOldProject.getTestProjectList().remove(testProject); + projectListOldProject = em.merge(projectListOldProject); + } + } + for (Project projectListNewProject : projectListNew) { + if (!projectListOld.contains(projectListNewProject)) { + projectListNewProject.getTestProjectList().add(testProject); + projectListNewProject = em.merge(projectListNewProject); + } + } + for (UserTestProjectRole userTestProjectRoleListNewUserTestProjectRole : userTestProjectRoleListNew) { + if (!userTestProjectRoleListOld.contains(userTestProjectRoleListNewUserTestProjectRole)) { + TestProject oldTestProjectOfUserTestProjectRoleListNewUserTestProjectRole = userTestProjectRoleListNewUserTestProjectRole.getTestProject(); + userTestProjectRoleListNewUserTestProjectRole.setTestProject(testProject); + userTestProjectRoleListNewUserTestProjectRole = em.merge(userTestProjectRoleListNewUserTestProjectRole); + if (oldTestProjectOfUserTestProjectRoleListNewUserTestProjectRole != null && !oldTestProjectOfUserTestProjectRoleListNewUserTestProjectRole.equals(testProject)) { + oldTestProjectOfUserTestProjectRoleListNewUserTestProjectRole.getUserTestProjectRoleList().remove(userTestProjectRoleListNewUserTestProjectRole); + oldTestProjectOfUserTestProjectRoleListNewUserTestProjectRole = em.merge(oldTestProjectOfUserTestProjectRoleListNewUserTestProjectRole); + } + } + } + for (TestPlan testPlanListNewTestPlan : testPlanListNew) { + if (!testPlanListOld.contains(testPlanListNewTestPlan)) { + TestProject oldTestProjectOfTestPlanListNewTestPlan = testPlanListNewTestPlan.getTestProject(); + testPlanListNewTestPlan.setTestProject(testProject); + testPlanListNewTestPlan = em.merge(testPlanListNewTestPlan); + if (oldTestProjectOfTestPlanListNewTestPlan != null && !oldTestProjectOfTestPlanListNewTestPlan.equals(testProject)) { + oldTestProjectOfTestPlanListNewTestPlan.getTestPlanList().remove(testPlanListNewTestPlan); + oldTestProjectOfTestPlanListNewTestPlan = em.merge(oldTestProjectOfTestPlanListNewTestPlan); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + Integer id = testProject.getId(); + if (findTestProject(id) == null) { + throw new NonexistentEntityException("The testProject with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + TestProject testProject; + try { + testProject = em.getReference(TestProject.class, id); + testProject.getId(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The testProject with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List userTestProjectRoleListOrphanCheck = testProject.getUserTestProjectRoleList(); + for (UserTestProjectRole userTestProjectRoleListOrphanCheckUserTestProjectRole : userTestProjectRoleListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This TestProject (" + testProject + ") cannot be destroyed since the UserTestProjectRole " + userTestProjectRoleListOrphanCheckUserTestProjectRole + " in its userTestProjectRoleList field has a non-nullable testProject field."); + } + List testPlanListOrphanCheck = testProject.getTestPlanList(); + for (TestPlan testPlanListOrphanCheckTestPlan : testPlanListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This TestProject (" + testProject + ") cannot be destroyed since the TestPlan " + testPlanListOrphanCheckTestPlan + " in its testPlanList field has a non-nullable testProject field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + List projectList = testProject.getProjectList(); + for (Project projectListProject : projectList) { + projectListProject.getTestProjectList().remove(testProject); + projectListProject = em.merge(projectListProject); + } + em.remove(testProject); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findTestProjectEntities() { + return findTestProjectEntities(true, -1, -1); + } + + public List findTestProjectEntities(int maxResults, int firstResult) { + return findTestProjectEntities(false, maxResults, firstResult); + } + + private List findTestProjectEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(TestProject.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public TestProject findTestProject(Integer id) { + EntityManager em = getEntityManager(); + try { + return em.find(TestProject.class, id); + } + finally { + em.close(); + } + } + + public int getTestProjectCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(TestProject.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/UserRightJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/UserRightJpaController.java index 83addca5..4eec04d6 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/UserRightJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/UserRightJpaController.java @@ -13,186 +13,186 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.Role; -import com.validation.manager.core.db.UserRight; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import java.util.ArrayList; -import java.util.List; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class UserRightJpaController implements Serializable { - - public UserRightJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(UserRight userRight) { - if (userRight.getRoleList() == null) { - userRight.setRoleList(new ArrayList()); - } - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - List attachedRoleList = new ArrayList(); - for (Role roleListRoleToAttach : userRight.getRoleList()) { - roleListRoleToAttach = em.getReference(roleListRoleToAttach.getClass(), roleListRoleToAttach.getId()); - attachedRoleList.add(roleListRoleToAttach); - } - userRight.setRoleList(attachedRoleList); - em.persist(userRight); - for (Role roleListRole : userRight.getRoleList()) { - roleListRole.getUserRightList().add(userRight); - roleListRole = em.merge(roleListRole); - } - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(UserRight userRight) throws NonexistentEntityException, Exception { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - UserRight persistentUserRight = em.find(UserRight.class, userRight.getId()); - List roleListOld = persistentUserRight.getRoleList(); - List roleListNew = userRight.getRoleList(); - List attachedRoleListNew = new ArrayList(); - for (Role roleListNewRoleToAttach : roleListNew) { - roleListNewRoleToAttach = em.getReference(roleListNewRoleToAttach.getClass(), roleListNewRoleToAttach.getId()); - attachedRoleListNew.add(roleListNewRoleToAttach); - } - roleListNew = attachedRoleListNew; - userRight.setRoleList(roleListNew); - userRight = em.merge(userRight); - for (Role roleListOldRole : roleListOld) { - if (!roleListNew.contains(roleListOldRole)) { - roleListOldRole.getUserRightList().remove(userRight); - roleListOldRole = em.merge(roleListOldRole); - } - } - for (Role roleListNewRole : roleListNew) { - if (!roleListOld.contains(roleListNewRole)) { - roleListNewRole.getUserRightList().add(userRight); - roleListNewRole = em.merge(roleListNewRole); - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - Integer id = userRight.getId(); - if (findUserRight(id) == null) { - throw new NonexistentEntityException("The userRight with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(Integer id) throws NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - UserRight userRight; - try { - userRight = em.getReference(UserRight.class, id); - userRight.getId(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The userRight with id " + id + " no longer exists.", enfe); - } - List roleList = userRight.getRoleList(); - for (Role roleListRole : roleList) { - roleListRole.getUserRightList().remove(userRight); - roleListRole = em.merge(roleListRole); - } - em.remove(userRight); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findUserRightEntities() { - return findUserRightEntities(true, -1, -1); - } - - public List findUserRightEntities(int maxResults, int firstResult) { - return findUserRightEntities(false, maxResults, firstResult); - } - - private List findUserRightEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(UserRight.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public UserRight findUserRight(Integer id) { - EntityManager em = getEntityManager(); - try { - return em.find(UserRight.class, id); - } - finally { - em.close(); - } - } - - public int getUserRightCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(UserRight.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.Role; +import com.validation.manager.core.db.UserRight; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import java.util.ArrayList; +import java.util.List; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class UserRightJpaController implements Serializable { + + public UserRightJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(UserRight userRight) { + if (userRight.getRoleList() == null) { + userRight.setRoleList(new ArrayList<>()); + } + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + List attachedRoleList = new ArrayList<>(); + for (Role roleListRoleToAttach : userRight.getRoleList()) { + roleListRoleToAttach = em.getReference(roleListRoleToAttach.getClass(), roleListRoleToAttach.getId()); + attachedRoleList.add(roleListRoleToAttach); + } + userRight.setRoleList(attachedRoleList); + em.persist(userRight); + for (Role roleListRole : userRight.getRoleList()) { + roleListRole.getUserRightList().add(userRight); + roleListRole = em.merge(roleListRole); + } + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(UserRight userRight) throws NonexistentEntityException, Exception { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + UserRight persistentUserRight = em.find(UserRight.class, userRight.getId()); + List roleListOld = persistentUserRight.getRoleList(); + List roleListNew = userRight.getRoleList(); + List attachedRoleListNew = new ArrayList<>(); + for (Role roleListNewRoleToAttach : roleListNew) { + roleListNewRoleToAttach = em.getReference(roleListNewRoleToAttach.getClass(), roleListNewRoleToAttach.getId()); + attachedRoleListNew.add(roleListNewRoleToAttach); + } + roleListNew = attachedRoleListNew; + userRight.setRoleList(roleListNew); + userRight = em.merge(userRight); + for (Role roleListOldRole : roleListOld) { + if (!roleListNew.contains(roleListOldRole)) { + roleListOldRole.getUserRightList().remove(userRight); + roleListOldRole = em.merge(roleListOldRole); + } + } + for (Role roleListNewRole : roleListNew) { + if (!roleListOld.contains(roleListNewRole)) { + roleListNewRole.getUserRightList().add(userRight); + roleListNewRole = em.merge(roleListNewRole); + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + Integer id = userRight.getId(); + if (findUserRight(id) == null) { + throw new NonexistentEntityException("The userRight with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(Integer id) throws NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + UserRight userRight; + try { + userRight = em.getReference(UserRight.class, id); + userRight.getId(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The userRight with id " + id + " no longer exists.", enfe); + } + List roleList = userRight.getRoleList(); + for (Role roleListRole : roleList) { + roleListRole.getUserRightList().remove(userRight); + roleListRole = em.merge(roleListRole); + } + em.remove(userRight); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findUserRightEntities() { + return findUserRightEntities(true, -1, -1); + } + + public List findUserRightEntities(int maxResults, int firstResult) { + return findUserRightEntities(false, maxResults, firstResult); + } + + private List findUserRightEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(UserRight.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public UserRight findUserRight(Integer id) { + EntityManager em = getEntityManager(); + try { + return em.find(UserRight.class, id); + } + finally { + em.close(); + } + } + + public int getUserRightCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(UserRight.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/UserStatusJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/UserStatusJpaController.java index 771b1c3a..ec8b3ce1 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/UserStatusJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/UserStatusJpaController.java @@ -13,209 +13,209 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import com.validation.manager.core.db.UserStatus; -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.VmUser; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import java.util.ArrayList; -import java.util.List; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class UserStatusJpaController implements Serializable { - - public UserStatusJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(UserStatus userStatus) { - if (userStatus.getVmUserList() == null) { - userStatus.setVmUserList(new ArrayList()); - } - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - List attachedVmUserList = new ArrayList(); - for (VmUser vmUserListVmUserToAttach : userStatus.getVmUserList()) { - vmUserListVmUserToAttach = em.getReference(vmUserListVmUserToAttach.getClass(), vmUserListVmUserToAttach.getId()); - attachedVmUserList.add(vmUserListVmUserToAttach); - } - userStatus.setVmUserList(attachedVmUserList); - em.persist(userStatus); - for (VmUser vmUserListVmUser : userStatus.getVmUserList()) { - UserStatus oldUserStatusIdOfVmUserListVmUser = vmUserListVmUser.getUserStatusId(); - vmUserListVmUser.setUserStatusId(userStatus); - vmUserListVmUser = em.merge(vmUserListVmUser); - if (oldUserStatusIdOfVmUserListVmUser != null) { - oldUserStatusIdOfVmUserListVmUser.getVmUserList().remove(vmUserListVmUser); - oldUserStatusIdOfVmUserListVmUser = em.merge(oldUserStatusIdOfVmUserListVmUser); - } - } - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(UserStatus userStatus) throws IllegalOrphanException, NonexistentEntityException, Exception { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - UserStatus persistentUserStatus = em.find(UserStatus.class, userStatus.getId()); - List vmUserListOld = persistentUserStatus.getVmUserList(); - List vmUserListNew = userStatus.getVmUserList(); - List illegalOrphanMessages = null; - for (VmUser vmUserListOldVmUser : vmUserListOld) { - if (!vmUserListNew.contains(vmUserListOldVmUser)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain VmUser " + vmUserListOldVmUser + " since its userStatusId field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - List attachedVmUserListNew = new ArrayList(); - for (VmUser vmUserListNewVmUserToAttach : vmUserListNew) { - vmUserListNewVmUserToAttach = em.getReference(vmUserListNewVmUserToAttach.getClass(), vmUserListNewVmUserToAttach.getId()); - attachedVmUserListNew.add(vmUserListNewVmUserToAttach); - } - vmUserListNew = attachedVmUserListNew; - userStatus.setVmUserList(vmUserListNew); - userStatus = em.merge(userStatus); - for (VmUser vmUserListNewVmUser : vmUserListNew) { - if (!vmUserListOld.contains(vmUserListNewVmUser)) { - UserStatus oldUserStatusIdOfVmUserListNewVmUser = vmUserListNewVmUser.getUserStatusId(); - vmUserListNewVmUser.setUserStatusId(userStatus); - vmUserListNewVmUser = em.merge(vmUserListNewVmUser); - if (oldUserStatusIdOfVmUserListNewVmUser != null && !oldUserStatusIdOfVmUserListNewVmUser.equals(userStatus)) { - oldUserStatusIdOfVmUserListNewVmUser.getVmUserList().remove(vmUserListNewVmUser); - oldUserStatusIdOfVmUserListNewVmUser = em.merge(oldUserStatusIdOfVmUserListNewVmUser); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - Integer id = userStatus.getId(); - if (findUserStatus(id) == null) { - throw new NonexistentEntityException("The userStatus with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - UserStatus userStatus; - try { - userStatus = em.getReference(UserStatus.class, id); - userStatus.getId(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The userStatus with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List vmUserListOrphanCheck = userStatus.getVmUserList(); - for (VmUser vmUserListOrphanCheckVmUser : vmUserListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This UserStatus (" + userStatus + ") cannot be destroyed since the VmUser " + vmUserListOrphanCheckVmUser + " in its vmUserList field has a non-nullable userStatusId field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - em.remove(userStatus); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findUserStatusEntities() { - return findUserStatusEntities(true, -1, -1); - } - - public List findUserStatusEntities(int maxResults, int firstResult) { - return findUserStatusEntities(false, maxResults, firstResult); - } - - private List findUserStatusEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(UserStatus.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public UserStatus findUserStatus(Integer id) { - EntityManager em = getEntityManager(); - try { - return em.find(UserStatus.class, id); - } - finally { - em.close(); - } - } - - public int getUserStatusCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(UserStatus.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import com.validation.manager.core.db.UserStatus; +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.VmUser; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import java.util.ArrayList; +import java.util.List; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class UserStatusJpaController implements Serializable { + + public UserStatusJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(UserStatus userStatus) { + if (userStatus.getVmUserList() == null) { + userStatus.setVmUserList(new ArrayList<>()); + } + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + List attachedVmUserList = new ArrayList<>(); + for (VmUser vmUserListVmUserToAttach : userStatus.getVmUserList()) { + vmUserListVmUserToAttach = em.getReference(vmUserListVmUserToAttach.getClass(), vmUserListVmUserToAttach.getId()); + attachedVmUserList.add(vmUserListVmUserToAttach); + } + userStatus.setVmUserList(attachedVmUserList); + em.persist(userStatus); + for (VmUser vmUserListVmUser : userStatus.getVmUserList()) { + UserStatus oldUserStatusIdOfVmUserListVmUser = vmUserListVmUser.getUserStatusId(); + vmUserListVmUser.setUserStatusId(userStatus); + vmUserListVmUser = em.merge(vmUserListVmUser); + if (oldUserStatusIdOfVmUserListVmUser != null) { + oldUserStatusIdOfVmUserListVmUser.getVmUserList().remove(vmUserListVmUser); + oldUserStatusIdOfVmUserListVmUser = em.merge(oldUserStatusIdOfVmUserListVmUser); + } + } + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(UserStatus userStatus) throws IllegalOrphanException, NonexistentEntityException, Exception { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + UserStatus persistentUserStatus = em.find(UserStatus.class, userStatus.getId()); + List vmUserListOld = persistentUserStatus.getVmUserList(); + List vmUserListNew = userStatus.getVmUserList(); + List illegalOrphanMessages = null; + for (VmUser vmUserListOldVmUser : vmUserListOld) { + if (!vmUserListNew.contains(vmUserListOldVmUser)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain VmUser " + vmUserListOldVmUser + " since its userStatusId field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + List attachedVmUserListNew = new ArrayList<>(); + for (VmUser vmUserListNewVmUserToAttach : vmUserListNew) { + vmUserListNewVmUserToAttach = em.getReference(vmUserListNewVmUserToAttach.getClass(), vmUserListNewVmUserToAttach.getId()); + attachedVmUserListNew.add(vmUserListNewVmUserToAttach); + } + vmUserListNew = attachedVmUserListNew; + userStatus.setVmUserList(vmUserListNew); + userStatus = em.merge(userStatus); + for (VmUser vmUserListNewVmUser : vmUserListNew) { + if (!vmUserListOld.contains(vmUserListNewVmUser)) { + UserStatus oldUserStatusIdOfVmUserListNewVmUser = vmUserListNewVmUser.getUserStatusId(); + vmUserListNewVmUser.setUserStatusId(userStatus); + vmUserListNewVmUser = em.merge(vmUserListNewVmUser); + if (oldUserStatusIdOfVmUserListNewVmUser != null && !oldUserStatusIdOfVmUserListNewVmUser.equals(userStatus)) { + oldUserStatusIdOfVmUserListNewVmUser.getVmUserList().remove(vmUserListNewVmUser); + oldUserStatusIdOfVmUserListNewVmUser = em.merge(oldUserStatusIdOfVmUserListNewVmUser); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + Integer id = userStatus.getId(); + if (findUserStatus(id) == null) { + throw new NonexistentEntityException("The userStatus with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + UserStatus userStatus; + try { + userStatus = em.getReference(UserStatus.class, id); + userStatus.getId(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The userStatus with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List vmUserListOrphanCheck = userStatus.getVmUserList(); + for (VmUser vmUserListOrphanCheckVmUser : vmUserListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This UserStatus (" + userStatus + ") cannot be destroyed since the VmUser " + vmUserListOrphanCheckVmUser + " in its vmUserList field has a non-nullable userStatusId field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + em.remove(userStatus); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findUserStatusEntities() { + return findUserStatusEntities(true, -1, -1); + } + + public List findUserStatusEntities(int maxResults, int firstResult) { + return findUserStatusEntities(false, maxResults, firstResult); + } + + private List findUserStatusEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(UserStatus.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public UserStatus findUserStatus(Integer id) { + EntityManager em = getEntityManager(); + try { + return em.find(UserStatus.class, id); + } + finally { + em.close(); + } + } + + public int getUserStatusCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(UserStatus.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/VmSettingJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/VmSettingJpaController.java index 9a1f195a..ae077189 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/VmSettingJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/VmSettingJpaController.java @@ -13,209 +13,209 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import java.io.Serializable; -import javax.persistence.Query; -import javax.persistence.EntityNotFoundException; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; -import com.validation.manager.core.db.History; -import com.validation.manager.core.db.VmSetting; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import java.util.ArrayList; -import java.util.List; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class VmSettingJpaController implements Serializable { - - public VmSettingJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(VmSetting vmSetting) { - if (vmSetting.getHistoryList() == null) { - vmSetting.setHistoryList(new ArrayList()); - } - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - List attachedHistoryList = new ArrayList(); - for (History historyListHistoryToAttach : vmSetting.getHistoryList()) { - historyListHistoryToAttach = em.getReference(historyListHistoryToAttach.getClass(), historyListHistoryToAttach.getId()); - attachedHistoryList.add(historyListHistoryToAttach); - } - vmSetting.setHistoryList(attachedHistoryList); - em.persist(vmSetting); - for (History historyListHistory : vmSetting.getHistoryList()) { - VmSetting oldVmSettingIdOfHistoryListHistory = historyListHistory.getVmSettingId(); - historyListHistory.setVmSettingId(vmSetting); - historyListHistory = em.merge(historyListHistory); - if (oldVmSettingIdOfHistoryListHistory != null) { - oldVmSettingIdOfHistoryListHistory.getHistoryList().remove(historyListHistory); - oldVmSettingIdOfHistoryListHistory = em.merge(oldVmSettingIdOfHistoryListHistory); - } - } - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(VmSetting vmSetting) throws IllegalOrphanException, NonexistentEntityException, Exception { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - VmSetting persistentVmSetting = em.find(VmSetting.class, vmSetting.getId()); - List historyListOld = persistentVmSetting.getHistoryList(); - List historyListNew = vmSetting.getHistoryList(); - List illegalOrphanMessages = null; - for (History historyListOldHistory : historyListOld) { - if (!historyListNew.contains(historyListOldHistory)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain History " + historyListOldHistory + " since its vmSettingId field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - List attachedHistoryListNew = new ArrayList(); - for (History historyListNewHistoryToAttach : historyListNew) { - historyListNewHistoryToAttach = em.getReference(historyListNewHistoryToAttach.getClass(), historyListNewHistoryToAttach.getId()); - attachedHistoryListNew.add(historyListNewHistoryToAttach); - } - historyListNew = attachedHistoryListNew; - vmSetting.setHistoryList(historyListNew); - vmSetting = em.merge(vmSetting); - for (History historyListNewHistory : historyListNew) { - if (!historyListOld.contains(historyListNewHistory)) { - VmSetting oldVmSettingIdOfHistoryListNewHistory = historyListNewHistory.getVmSettingId(); - historyListNewHistory.setVmSettingId(vmSetting); - historyListNewHistory = em.merge(historyListNewHistory); - if (oldVmSettingIdOfHistoryListNewHistory != null && !oldVmSettingIdOfHistoryListNewHistory.equals(vmSetting)) { - oldVmSettingIdOfHistoryListNewHistory.getHistoryList().remove(historyListNewHistory); - oldVmSettingIdOfHistoryListNewHistory = em.merge(oldVmSettingIdOfHistoryListNewHistory); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - Integer id = vmSetting.getId(); - if (findVmSetting(id) == null) { - throw new NonexistentEntityException("The vmSetting with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - VmSetting vmSetting; - try { - vmSetting = em.getReference(VmSetting.class, id); - vmSetting.getId(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The vmSetting with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List historyListOrphanCheck = vmSetting.getHistoryList(); - for (History historyListOrphanCheckHistory : historyListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This VmSetting (" + vmSetting + ") cannot be destroyed since the History " + historyListOrphanCheckHistory + " in its historyList field has a non-nullable vmSettingId field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - em.remove(vmSetting); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findVmSettingEntities() { - return findVmSettingEntities(true, -1, -1); - } - - public List findVmSettingEntities(int maxResults, int firstResult) { - return findVmSettingEntities(false, maxResults, firstResult); - } - - private List findVmSettingEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(VmSetting.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public VmSetting findVmSetting(Integer id) { - EntityManager em = getEntityManager(); - try { - return em.find(VmSetting.class, id); - } - finally { - em.close(); - } - } - - public int getVmSettingCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(VmSetting.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.History; +import com.validation.manager.core.db.VmSetting; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import java.util.ArrayList; +import java.util.List; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class VmSettingJpaController implements Serializable { + + public VmSettingJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(VmSetting vmSetting) { + if (vmSetting.getHistoryList() == null) { + vmSetting.setHistoryList(new ArrayList<>()); + } + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + List attachedHistoryList = new ArrayList<>(); + for (History historyListHistoryToAttach : vmSetting.getHistoryList()) { + historyListHistoryToAttach = em.getReference(historyListHistoryToAttach.getClass(), historyListHistoryToAttach.getId()); + attachedHistoryList.add(historyListHistoryToAttach); + } + vmSetting.setHistoryList(attachedHistoryList); + em.persist(vmSetting); + for (History historyListHistory : vmSetting.getHistoryList()) { + VmSetting oldVmSettingIdOfHistoryListHistory = historyListHistory.getVmSettingId(); + historyListHistory.setVmSettingId(vmSetting); + historyListHistory = em.merge(historyListHistory); + if (oldVmSettingIdOfHistoryListHistory != null) { + oldVmSettingIdOfHistoryListHistory.getHistoryList().remove(historyListHistory); + oldVmSettingIdOfHistoryListHistory = em.merge(oldVmSettingIdOfHistoryListHistory); + } + } + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(VmSetting vmSetting) throws IllegalOrphanException, NonexistentEntityException, Exception { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + VmSetting persistentVmSetting = em.find(VmSetting.class, vmSetting.getId()); + List historyListOld = persistentVmSetting.getHistoryList(); + List historyListNew = vmSetting.getHistoryList(); + List illegalOrphanMessages = null; + for (History historyListOldHistory : historyListOld) { + if (!historyListNew.contains(historyListOldHistory)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain History " + historyListOldHistory + " since its vmSettingId field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + List attachedHistoryListNew = new ArrayList<>(); + for (History historyListNewHistoryToAttach : historyListNew) { + historyListNewHistoryToAttach = em.getReference(historyListNewHistoryToAttach.getClass(), historyListNewHistoryToAttach.getId()); + attachedHistoryListNew.add(historyListNewHistoryToAttach); + } + historyListNew = attachedHistoryListNew; + vmSetting.setHistoryList(historyListNew); + vmSetting = em.merge(vmSetting); + for (History historyListNewHistory : historyListNew) { + if (!historyListOld.contains(historyListNewHistory)) { + VmSetting oldVmSettingIdOfHistoryListNewHistory = historyListNewHistory.getVmSettingId(); + historyListNewHistory.setVmSettingId(vmSetting); + historyListNewHistory = em.merge(historyListNewHistory); + if (oldVmSettingIdOfHistoryListNewHistory != null && !oldVmSettingIdOfHistoryListNewHistory.equals(vmSetting)) { + oldVmSettingIdOfHistoryListNewHistory.getHistoryList().remove(historyListNewHistory); + oldVmSettingIdOfHistoryListNewHistory = em.merge(oldVmSettingIdOfHistoryListNewHistory); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + Integer id = vmSetting.getId(); + if (findVmSetting(id) == null) { + throw new NonexistentEntityException("The vmSetting with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + VmSetting vmSetting; + try { + vmSetting = em.getReference(VmSetting.class, id); + vmSetting.getId(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The vmSetting with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List historyListOrphanCheck = vmSetting.getHistoryList(); + for (History historyListOrphanCheckHistory : historyListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This VmSetting (" + vmSetting + ") cannot be destroyed since the History " + historyListOrphanCheckHistory + " in its historyList field has a non-nullable vmSettingId field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + em.remove(vmSetting); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findVmSettingEntities() { + return findVmSettingEntities(true, -1, -1); + } + + public List findVmSettingEntities(int maxResults, int firstResult) { + return findVmSettingEntities(false, maxResults, firstResult); + } + + private List findVmSettingEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(VmSetting.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public VmSetting findVmSetting(Integer id) { + EntityManager em = getEntityManager(); + try { + return em.find(VmSetting.class, id); + } + finally { + em.close(); + } + } + + public int getVmSettingCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(VmSetting.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/db/controller/VmUserJpaController.java b/VM-Core/src/main/java/com/validation/manager/core/db/controller/VmUserJpaController.java index e0b7e761..ae05777e 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/db/controller/VmUserJpaController.java +++ b/VM-Core/src/main/java/com/validation/manager/core/db/controller/VmUserJpaController.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,981 +13,1034 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db.controller; - -import com.validation.manager.core.db.CorrectiveAction; -import com.validation.manager.core.db.ExecutionStep; -import com.validation.manager.core.db.ExecutionStepHasIssue; -import com.validation.manager.core.db.ExecutionStepHasVmUser; -import com.validation.manager.core.db.History; -import com.validation.manager.core.db.Notification; -import com.validation.manager.core.db.Role; -import com.validation.manager.core.db.RootCause; -import com.validation.manager.core.db.UserAssigment; -import com.validation.manager.core.db.UserHasInvestigation; -import com.validation.manager.core.db.UserModifiedRecord; -import com.validation.manager.core.db.UserStatus; -import com.validation.manager.core.db.UserTestPlanRole; -import com.validation.manager.core.db.UserTestProjectRole; -import com.validation.manager.core.db.VmUser; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import java.io.Serializable; -import java.util.ArrayList; -import java.util.List; -import javax.persistence.EntityManager; -import javax.persistence.EntityManagerFactory; -import javax.persistence.EntityNotFoundException; -import javax.persistence.Query; -import javax.persistence.criteria.CriteriaQuery; -import javax.persistence.criteria.Root; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class VmUserJpaController implements Serializable { - - public VmUserJpaController(EntityManagerFactory emf) { - this.emf = emf; - } - private EntityManagerFactory emf = null; - - public EntityManager getEntityManager() { - return emf.createEntityManager(); - } - - public void create(VmUser vmUser) { - if (vmUser.getCorrectiveActionList() == null) { - vmUser.setCorrectiveActionList(new ArrayList()); - } - if (vmUser.getRoleList() == null) { - vmUser.setRoleList(new ArrayList()); - } - if (vmUser.getRootCauseList() == null) { - vmUser.setRootCauseList(new ArrayList()); - } - if (vmUser.getExecutionStepList() == null) { - vmUser.setExecutionStepList(new ArrayList()); - } - if (vmUser.getExecutionStepList1() == null) { - vmUser.setExecutionStepList1(new ArrayList()); - } - if (vmUser.getUserTestProjectRoleList() == null) { - vmUser.setUserTestProjectRoleList(new ArrayList()); - } - if (vmUser.getUserTestPlanRoleList() == null) { - vmUser.setUserTestPlanRoleList(new ArrayList()); - } - if (vmUser.getUserModifiedRecordList() == null) { - vmUser.setUserModifiedRecordList(new ArrayList()); - } - if (vmUser.getUserHasInvestigationList() == null) { - vmUser.setUserHasInvestigationList(new ArrayList()); - } - if (vmUser.getUserAssigmentList() == null) { - vmUser.setUserAssigmentList(new ArrayList()); - } - if (vmUser.getUserAssigmentList1() == null) { - vmUser.setUserAssigmentList1(new ArrayList()); - } - if (vmUser.getExecutionStepHasIssueList() == null) { - vmUser.setExecutionStepHasIssueList(new ArrayList()); - } - if (vmUser.getExecutionStepHasVmUserList() == null) { - vmUser.setExecutionStepHasVmUserList(new ArrayList()); - } - if (vmUser.getHistoryModificationList() == null) { - vmUser.setHistoryModificationList(new ArrayList()); - } - if (vmUser.getNotificationList() == null) { - vmUser.setNotificationList(new ArrayList()); - } - if (vmUser.getNotificationList1() == null) { - vmUser.setNotificationList1(new ArrayList()); - } - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - UserStatus userStatusId = vmUser.getUserStatusId(); - if (userStatusId != null) { - userStatusId = em.getReference(userStatusId.getClass(), userStatusId.getId()); - vmUser.setUserStatusId(userStatusId); - } - List attachedCorrectiveActionList = new ArrayList(); - for (CorrectiveAction correctiveActionListCorrectiveActionToAttach : vmUser.getCorrectiveActionList()) { - correctiveActionListCorrectiveActionToAttach = em.getReference(correctiveActionListCorrectiveActionToAttach.getClass(), correctiveActionListCorrectiveActionToAttach.getId()); - attachedCorrectiveActionList.add(correctiveActionListCorrectiveActionToAttach); - } - vmUser.setCorrectiveActionList(attachedCorrectiveActionList); - List attachedRoleList = new ArrayList(); - for (Role roleListRoleToAttach : vmUser.getRoleList()) { - roleListRoleToAttach = em.getReference(roleListRoleToAttach.getClass(), roleListRoleToAttach.getId()); - attachedRoleList.add(roleListRoleToAttach); - } - vmUser.setRoleList(attachedRoleList); - List attachedRootCauseList = new ArrayList(); - for (RootCause rootCauseListRootCauseToAttach : vmUser.getRootCauseList()) { - rootCauseListRootCauseToAttach = em.getReference(rootCauseListRootCauseToAttach.getClass(), rootCauseListRootCauseToAttach.getRootCausePK()); - attachedRootCauseList.add(rootCauseListRootCauseToAttach); - } - vmUser.setRootCauseList(attachedRootCauseList); - List attachedExecutionStepList = new ArrayList(); - for (ExecutionStep executionStepListExecutionStepToAttach : vmUser.getExecutionStepList()) { - executionStepListExecutionStepToAttach = em.getReference(executionStepListExecutionStepToAttach.getClass(), executionStepListExecutionStepToAttach.getExecutionStepPK()); - attachedExecutionStepList.add(executionStepListExecutionStepToAttach); - } - vmUser.setExecutionStepList(attachedExecutionStepList); - List attachedExecutionStepList1 = new ArrayList(); - for (ExecutionStep executionStepList1ExecutionStepToAttach : vmUser.getExecutionStepList1()) { - executionStepList1ExecutionStepToAttach = em.getReference(executionStepList1ExecutionStepToAttach.getClass(), executionStepList1ExecutionStepToAttach.getExecutionStepPK()); - attachedExecutionStepList1.add(executionStepList1ExecutionStepToAttach); - } - vmUser.setExecutionStepList1(attachedExecutionStepList1); - List attachedUserTestProjectRoleList = new ArrayList(); - for (UserTestProjectRole userTestProjectRoleListUserTestProjectRoleToAttach : vmUser.getUserTestProjectRoleList()) { - userTestProjectRoleListUserTestProjectRoleToAttach = em.getReference(userTestProjectRoleListUserTestProjectRoleToAttach.getClass(), userTestProjectRoleListUserTestProjectRoleToAttach.getUserTestProjectRolePK()); - attachedUserTestProjectRoleList.add(userTestProjectRoleListUserTestProjectRoleToAttach); - } - vmUser.setUserTestProjectRoleList(attachedUserTestProjectRoleList); - List attachedUserTestPlanRoleList = new ArrayList(); - for (UserTestPlanRole userTestPlanRoleListUserTestPlanRoleToAttach : vmUser.getUserTestPlanRoleList()) { - userTestPlanRoleListUserTestPlanRoleToAttach = em.getReference(userTestPlanRoleListUserTestPlanRoleToAttach.getClass(), userTestPlanRoleListUserTestPlanRoleToAttach.getUserTestPlanRolePK()); - attachedUserTestPlanRoleList.add(userTestPlanRoleListUserTestPlanRoleToAttach); - } - vmUser.setUserTestPlanRoleList(attachedUserTestPlanRoleList); - List attachedUserModifiedRecordList = new ArrayList(); - for (UserModifiedRecord userModifiedRecordListUserModifiedRecordToAttach : vmUser.getUserModifiedRecordList()) { - userModifiedRecordListUserModifiedRecordToAttach = em.getReference(userModifiedRecordListUserModifiedRecordToAttach.getClass(), userModifiedRecordListUserModifiedRecordToAttach.getUserModifiedRecordPK()); - attachedUserModifiedRecordList.add(userModifiedRecordListUserModifiedRecordToAttach); - } - vmUser.setUserModifiedRecordList(attachedUserModifiedRecordList); - List attachedUserHasInvestigationList = new ArrayList(); - for (UserHasInvestigation userHasInvestigationListUserHasInvestigationToAttach : vmUser.getUserHasInvestigationList()) { - userHasInvestigationListUserHasInvestigationToAttach = em.getReference(userHasInvestigationListUserHasInvestigationToAttach.getClass(), userHasInvestigationListUserHasInvestigationToAttach.getUserHasInvestigationPK()); - attachedUserHasInvestigationList.add(userHasInvestigationListUserHasInvestigationToAttach); - } - vmUser.setUserHasInvestigationList(attachedUserHasInvestigationList); - List attachedUserAssigmentList = new ArrayList(); - for (UserAssigment userAssigmentListUserAssigmentToAttach : vmUser.getUserAssigmentList()) { - userAssigmentListUserAssigmentToAttach = em.getReference(userAssigmentListUserAssigmentToAttach.getClass(), userAssigmentListUserAssigmentToAttach.getUserAssigmentPK()); - attachedUserAssigmentList.add(userAssigmentListUserAssigmentToAttach); - } - vmUser.setUserAssigmentList(attachedUserAssigmentList); - List attachedUserAssigmentList1 = new ArrayList(); - for (UserAssigment userAssigmentList1UserAssigmentToAttach : vmUser.getUserAssigmentList1()) { - userAssigmentList1UserAssigmentToAttach = em.getReference(userAssigmentList1UserAssigmentToAttach.getClass(), userAssigmentList1UserAssigmentToAttach.getUserAssigmentPK()); - attachedUserAssigmentList1.add(userAssigmentList1UserAssigmentToAttach); - } - vmUser.setUserAssigmentList1(attachedUserAssigmentList1); - List attachedExecutionStepHasIssueList = new ArrayList(); - for (ExecutionStepHasIssue executionStepHasIssueListExecutionStepHasIssueToAttach : vmUser.getExecutionStepHasIssueList()) { - executionStepHasIssueListExecutionStepHasIssueToAttach = em.getReference(executionStepHasIssueListExecutionStepHasIssueToAttach.getClass(), executionStepHasIssueListExecutionStepHasIssueToAttach.getExecutionStepHasIssuePK()); - attachedExecutionStepHasIssueList.add(executionStepHasIssueListExecutionStepHasIssueToAttach); - } - vmUser.setExecutionStepHasIssueList(attachedExecutionStepHasIssueList); - List attachedExecutionStepHasVmUserList = new ArrayList(); - for (ExecutionStepHasVmUser executionStepHasVmUserListExecutionStepHasVmUserToAttach : vmUser.getExecutionStepHasVmUserList()) { - executionStepHasVmUserListExecutionStepHasVmUserToAttach = em.getReference(executionStepHasVmUserListExecutionStepHasVmUserToAttach.getClass(), executionStepHasVmUserListExecutionStepHasVmUserToAttach.getExecutionStepHasVmUserPK()); - attachedExecutionStepHasVmUserList.add(executionStepHasVmUserListExecutionStepHasVmUserToAttach); - } - vmUser.setExecutionStepHasVmUserList(attachedExecutionStepHasVmUserList); - List attachedHistoryModificationList = new ArrayList(); - for (History historyModificationListHistoryToAttach : vmUser.getHistoryModificationList()) { - historyModificationListHistoryToAttach = em.getReference(historyModificationListHistoryToAttach.getClass(), historyModificationListHistoryToAttach.getId()); - attachedHistoryModificationList.add(historyModificationListHistoryToAttach); - } - vmUser.setHistoryModificationList(attachedHistoryModificationList); - List attachedNotificationList = new ArrayList(); - for (Notification notificationListNotificationToAttach : vmUser.getNotificationList()) { - notificationListNotificationToAttach = em.getReference(notificationListNotificationToAttach.getClass(), notificationListNotificationToAttach.getNotificationPK()); - attachedNotificationList.add(notificationListNotificationToAttach); - } - vmUser.setNotificationList(attachedNotificationList); - List attachedNotificationList1 = new ArrayList(); - for (Notification notificationList1NotificationToAttach : vmUser.getNotificationList1()) { - notificationList1NotificationToAttach = em.getReference(notificationList1NotificationToAttach.getClass(), notificationList1NotificationToAttach.getNotificationPK()); - attachedNotificationList1.add(notificationList1NotificationToAttach); - } - vmUser.setNotificationList1(attachedNotificationList1); - em.persist(vmUser); - if (userStatusId != null) { - userStatusId.getVmUserList().add(vmUser); - userStatusId = em.merge(userStatusId); - } - for (CorrectiveAction correctiveActionListCorrectiveAction : vmUser.getCorrectiveActionList()) { - correctiveActionListCorrectiveAction.getVmUserList().add(vmUser); - correctiveActionListCorrectiveAction = em.merge(correctiveActionListCorrectiveAction); - } - for (Role roleListRole : vmUser.getRoleList()) { - roleListRole.getVmUserList().add(vmUser); - roleListRole = em.merge(roleListRole); - } - for (RootCause rootCauseListRootCause : vmUser.getRootCauseList()) { - rootCauseListRootCause.getVmUserList().add(vmUser); - rootCauseListRootCause = em.merge(rootCauseListRootCause); - } - for (ExecutionStep executionStepListExecutionStep : vmUser.getExecutionStepList()) { - VmUser oldAssigneeOfExecutionStepListExecutionStep = executionStepListExecutionStep.getAssignee(); - executionStepListExecutionStep.setAssignee(vmUser); - executionStepListExecutionStep = em.merge(executionStepListExecutionStep); - if (oldAssigneeOfExecutionStepListExecutionStep != null) { - oldAssigneeOfExecutionStepListExecutionStep.getExecutionStepList().remove(executionStepListExecutionStep); - oldAssigneeOfExecutionStepListExecutionStep = em.merge(oldAssigneeOfExecutionStepListExecutionStep); - } - } - for (ExecutionStep executionStepList1ExecutionStep : vmUser.getExecutionStepList1()) { - VmUser oldAssignerOfExecutionStepList1ExecutionStep = executionStepList1ExecutionStep.getAssigner(); - executionStepList1ExecutionStep.setAssigner(vmUser); - executionStepList1ExecutionStep = em.merge(executionStepList1ExecutionStep); - if (oldAssignerOfExecutionStepList1ExecutionStep != null) { - oldAssignerOfExecutionStepList1ExecutionStep.getExecutionStepList1().remove(executionStepList1ExecutionStep); - oldAssignerOfExecutionStepList1ExecutionStep = em.merge(oldAssignerOfExecutionStepList1ExecutionStep); - } - } - for (UserTestProjectRole userTestProjectRoleListUserTestProjectRole : vmUser.getUserTestProjectRoleList()) { - VmUser oldVmUserOfUserTestProjectRoleListUserTestProjectRole = userTestProjectRoleListUserTestProjectRole.getVmUser(); - userTestProjectRoleListUserTestProjectRole.setVmUser(vmUser); - userTestProjectRoleListUserTestProjectRole = em.merge(userTestProjectRoleListUserTestProjectRole); - if (oldVmUserOfUserTestProjectRoleListUserTestProjectRole != null) { - oldVmUserOfUserTestProjectRoleListUserTestProjectRole.getUserTestProjectRoleList().remove(userTestProjectRoleListUserTestProjectRole); - oldVmUserOfUserTestProjectRoleListUserTestProjectRole = em.merge(oldVmUserOfUserTestProjectRoleListUserTestProjectRole); - } - } - for (UserTestPlanRole userTestPlanRoleListUserTestPlanRole : vmUser.getUserTestPlanRoleList()) { - VmUser oldVmUserOfUserTestPlanRoleListUserTestPlanRole = userTestPlanRoleListUserTestPlanRole.getVmUser(); - userTestPlanRoleListUserTestPlanRole.setVmUser(vmUser); - userTestPlanRoleListUserTestPlanRole = em.merge(userTestPlanRoleListUserTestPlanRole); - if (oldVmUserOfUserTestPlanRoleListUserTestPlanRole != null) { - oldVmUserOfUserTestPlanRoleListUserTestPlanRole.getUserTestPlanRoleList().remove(userTestPlanRoleListUserTestPlanRole); - oldVmUserOfUserTestPlanRoleListUserTestPlanRole = em.merge(oldVmUserOfUserTestPlanRoleListUserTestPlanRole); - } - } - for (UserModifiedRecord userModifiedRecordListUserModifiedRecord : vmUser.getUserModifiedRecordList()) { - VmUser oldVmUserOfUserModifiedRecordListUserModifiedRecord = userModifiedRecordListUserModifiedRecord.getVmUser(); - userModifiedRecordListUserModifiedRecord.setVmUser(vmUser); - userModifiedRecordListUserModifiedRecord = em.merge(userModifiedRecordListUserModifiedRecord); - if (oldVmUserOfUserModifiedRecordListUserModifiedRecord != null) { - oldVmUserOfUserModifiedRecordListUserModifiedRecord.getUserModifiedRecordList().remove(userModifiedRecordListUserModifiedRecord); - oldVmUserOfUserModifiedRecordListUserModifiedRecord = em.merge(oldVmUserOfUserModifiedRecordListUserModifiedRecord); - } - } - for (UserHasInvestigation userHasInvestigationListUserHasInvestigation : vmUser.getUserHasInvestigationList()) { - VmUser oldVmUserOfUserHasInvestigationListUserHasInvestigation = userHasInvestigationListUserHasInvestigation.getVmUser(); - userHasInvestigationListUserHasInvestigation.setVmUser(vmUser); - userHasInvestigationListUserHasInvestigation = em.merge(userHasInvestigationListUserHasInvestigation); - if (oldVmUserOfUserHasInvestigationListUserHasInvestigation != null) { - oldVmUserOfUserHasInvestigationListUserHasInvestigation.getUserHasInvestigationList().remove(userHasInvestigationListUserHasInvestigation); - oldVmUserOfUserHasInvestigationListUserHasInvestigation = em.merge(oldVmUserOfUserHasInvestigationListUserHasInvestigation); - } - } - for (UserAssigment userAssigmentListUserAssigment : vmUser.getUserAssigmentList()) { - VmUser oldVmUserOfUserAssigmentListUserAssigment = userAssigmentListUserAssigment.getVmUser(); - userAssigmentListUserAssigment.setVmUser(vmUser); - userAssigmentListUserAssigment = em.merge(userAssigmentListUserAssigment); - if (oldVmUserOfUserAssigmentListUserAssigment != null) { - oldVmUserOfUserAssigmentListUserAssigment.getUserAssigmentList().remove(userAssigmentListUserAssigment); - oldVmUserOfUserAssigmentListUserAssigment = em.merge(oldVmUserOfUserAssigmentListUserAssigment); - } - } - for (UserAssigment userAssigmentList1UserAssigment : vmUser.getUserAssigmentList1()) { - VmUser oldAssigneeIdOfUserAssigmentList1UserAssigment = userAssigmentList1UserAssigment.getAssigneeId(); - userAssigmentList1UserAssigment.setAssigneeId(vmUser); - userAssigmentList1UserAssigment = em.merge(userAssigmentList1UserAssigment); - if (oldAssigneeIdOfUserAssigmentList1UserAssigment != null) { - oldAssigneeIdOfUserAssigmentList1UserAssigment.getUserAssigmentList1().remove(userAssigmentList1UserAssigment); - oldAssigneeIdOfUserAssigmentList1UserAssigment = em.merge(oldAssigneeIdOfUserAssigmentList1UserAssigment); - } - } - for (ExecutionStepHasIssue executionStepHasIssueListExecutionStepHasIssue : vmUser.getExecutionStepHasIssueList()) { - executionStepHasIssueListExecutionStepHasIssue.getVmUserList().add(vmUser); - executionStepHasIssueListExecutionStepHasIssue = em.merge(executionStepHasIssueListExecutionStepHasIssue); - } - for (ExecutionStepHasVmUser executionStepHasVmUserListExecutionStepHasVmUser : vmUser.getExecutionStepHasVmUserList()) { - VmUser oldVmUserOfExecutionStepHasVmUserListExecutionStepHasVmUser = executionStepHasVmUserListExecutionStepHasVmUser.getVmUser(); - executionStepHasVmUserListExecutionStepHasVmUser.setVmUser(vmUser); - executionStepHasVmUserListExecutionStepHasVmUser = em.merge(executionStepHasVmUserListExecutionStepHasVmUser); - if (oldVmUserOfExecutionStepHasVmUserListExecutionStepHasVmUser != null) { - oldVmUserOfExecutionStepHasVmUserListExecutionStepHasVmUser.getExecutionStepHasVmUserList().remove(executionStepHasVmUserListExecutionStepHasVmUser); - oldVmUserOfExecutionStepHasVmUserListExecutionStepHasVmUser = em.merge(oldVmUserOfExecutionStepHasVmUserListExecutionStepHasVmUser); - } - } - for (History historyModificationListHistory : vmUser.getHistoryModificationList()) { - VmUser oldModifierIdOfHistoryModificationListHistory = historyModificationListHistory.getModifierId(); - historyModificationListHistory.setModifierId(vmUser); - historyModificationListHistory = em.merge(historyModificationListHistory); - if (oldModifierIdOfHistoryModificationListHistory != null) { - oldModifierIdOfHistoryModificationListHistory.getHistoryModificationList().remove(historyModificationListHistory); - oldModifierIdOfHistoryModificationListHistory = em.merge(oldModifierIdOfHistoryModificationListHistory); - } - } - for (Notification notificationListNotification : vmUser.getNotificationList()) { - VmUser oldTargetOfNotificationListNotification = notificationListNotification.getTargetUser(); - notificationListNotification.setTargetUser(vmUser); - notificationListNotification = em.merge(notificationListNotification); - if (oldTargetOfNotificationListNotification != null) { - oldTargetOfNotificationListNotification.getNotificationList().remove(notificationListNotification); - oldTargetOfNotificationListNotification = em.merge(oldTargetOfNotificationListNotification); - } - } - for (Notification notificationList1Notification : vmUser.getNotificationList1()) { - VmUser oldAuthorOfNotificationList1Notification = notificationList1Notification.getAuthor(); - notificationList1Notification.setAuthor(vmUser); - notificationList1Notification = em.merge(notificationList1Notification); - if (oldAuthorOfNotificationList1Notification != null) { - oldAuthorOfNotificationList1Notification.getNotificationList1().remove(notificationList1Notification); - oldAuthorOfNotificationList1Notification = em.merge(oldAuthorOfNotificationList1Notification); - } - } - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void edit(VmUser vmUser) throws IllegalOrphanException, NonexistentEntityException, Exception { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - VmUser persistentVmUser = em.find(VmUser.class, vmUser.getId()); - UserStatus userStatusIdOld = persistentVmUser.getUserStatusId(); - UserStatus userStatusIdNew = vmUser.getUserStatusId(); - List correctiveActionListOld = persistentVmUser.getCorrectiveActionList(); - List correctiveActionListNew = vmUser.getCorrectiveActionList(); - List roleListOld = persistentVmUser.getRoleList(); - List roleListNew = vmUser.getRoleList(); - List rootCauseListOld = persistentVmUser.getRootCauseList(); - List rootCauseListNew = vmUser.getRootCauseList(); - List executionStepListOld = persistentVmUser.getExecutionStepList(); - List executionStepListNew = vmUser.getExecutionStepList(); - List executionStepList1Old = persistentVmUser.getExecutionStepList1(); - List executionStepList1New = vmUser.getExecutionStepList1(); - List userTestProjectRoleListOld = persistentVmUser.getUserTestProjectRoleList(); - List userTestProjectRoleListNew = vmUser.getUserTestProjectRoleList(); - List userTestPlanRoleListOld = persistentVmUser.getUserTestPlanRoleList(); - List userTestPlanRoleListNew = vmUser.getUserTestPlanRoleList(); - List userModifiedRecordListOld = persistentVmUser.getUserModifiedRecordList(); - List userModifiedRecordListNew = vmUser.getUserModifiedRecordList(); - List userHasInvestigationListOld = persistentVmUser.getUserHasInvestigationList(); - List userHasInvestigationListNew = vmUser.getUserHasInvestigationList(); - List userAssigmentListOld = persistentVmUser.getUserAssigmentList(); - List userAssigmentListNew = vmUser.getUserAssigmentList(); - List userAssigmentList1Old = persistentVmUser.getUserAssigmentList1(); - List userAssigmentList1New = vmUser.getUserAssigmentList1(); - List executionStepHasIssueListOld = persistentVmUser.getExecutionStepHasIssueList(); - List executionStepHasIssueListNew = vmUser.getExecutionStepHasIssueList(); - List executionStepHasVmUserListOld = persistentVmUser.getExecutionStepHasVmUserList(); - List executionStepHasVmUserListNew = vmUser.getExecutionStepHasVmUserList(); - List historyModificationListOld = persistentVmUser.getHistoryModificationList(); - List historyModificationListNew = vmUser.getHistoryModificationList(); - List notificationListOld = persistentVmUser.getNotificationList(); - List notificationListNew = vmUser.getNotificationList(); - List notificationList1Old = persistentVmUser.getNotificationList1(); - List notificationList1New = vmUser.getNotificationList1(); - List illegalOrphanMessages = null; - for (UserTestProjectRole userTestProjectRoleListOldUserTestProjectRole : userTestProjectRoleListOld) { - if (!userTestProjectRoleListNew.contains(userTestProjectRoleListOldUserTestProjectRole)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain UserTestProjectRole " + userTestProjectRoleListOldUserTestProjectRole + " since its vmUser field is not nullable."); - } - } - for (UserTestPlanRole userTestPlanRoleListOldUserTestPlanRole : userTestPlanRoleListOld) { - if (!userTestPlanRoleListNew.contains(userTestPlanRoleListOldUserTestPlanRole)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain UserTestPlanRole " + userTestPlanRoleListOldUserTestPlanRole + " since its vmUser field is not nullable."); - } - } - for (UserModifiedRecord userModifiedRecordListOldUserModifiedRecord : userModifiedRecordListOld) { - if (!userModifiedRecordListNew.contains(userModifiedRecordListOldUserModifiedRecord)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain UserModifiedRecord " + userModifiedRecordListOldUserModifiedRecord + " since its vmUser field is not nullable."); - } - } - for (UserHasInvestigation userHasInvestigationListOldUserHasInvestigation : userHasInvestigationListOld) { - if (!userHasInvestigationListNew.contains(userHasInvestigationListOldUserHasInvestigation)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain UserHasInvestigation " + userHasInvestigationListOldUserHasInvestigation + " since its vmUser field is not nullable."); - } - } - for (UserAssigment userAssigmentListOldUserAssigment : userAssigmentListOld) { - if (!userAssigmentListNew.contains(userAssigmentListOldUserAssigment)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain UserAssigment " + userAssigmentListOldUserAssigment + " since its vmUser field is not nullable."); - } - } - for (UserAssigment userAssigmentList1OldUserAssigment : userAssigmentList1Old) { - if (!userAssigmentList1New.contains(userAssigmentList1OldUserAssigment)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain UserAssigment " + userAssigmentList1OldUserAssigment + " since its assigneeId field is not nullable."); - } - } - for (ExecutionStepHasVmUser executionStepHasVmUserListOldExecutionStepHasVmUser : executionStepHasVmUserListOld) { - if (!executionStepHasVmUserListNew.contains(executionStepHasVmUserListOldExecutionStepHasVmUser)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain ExecutionStepHasVmUser " + executionStepHasVmUserListOldExecutionStepHasVmUser + " since its vmUser field is not nullable."); - } - } - for (History historyModificationListOldHistory : historyModificationListOld) { - if (!historyModificationListNew.contains(historyModificationListOldHistory)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain History " + historyModificationListOldHistory + " since its modifierId field is not nullable."); - } - } - for (Notification notificationListOldNotification : notificationListOld) { - if (!notificationListNew.contains(notificationListOldNotification)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain Notification " + notificationListOldNotification + " since its target field is not nullable."); - } - } - for (Notification notificationList1OldNotification : notificationList1Old) { - if (!notificationList1New.contains(notificationList1OldNotification)) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("You must retain Notification " + notificationList1OldNotification + " since its author field is not nullable."); - } - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - if (userStatusIdNew != null) { - userStatusIdNew = em.getReference(userStatusIdNew.getClass(), userStatusIdNew.getId()); - vmUser.setUserStatusId(userStatusIdNew); - } - List attachedCorrectiveActionListNew = new ArrayList(); - for (CorrectiveAction correctiveActionListNewCorrectiveActionToAttach : correctiveActionListNew) { - correctiveActionListNewCorrectiveActionToAttach = em.getReference(correctiveActionListNewCorrectiveActionToAttach.getClass(), correctiveActionListNewCorrectiveActionToAttach.getId()); - attachedCorrectiveActionListNew.add(correctiveActionListNewCorrectiveActionToAttach); - } - correctiveActionListNew = attachedCorrectiveActionListNew; - vmUser.setCorrectiveActionList(correctiveActionListNew); - List attachedRoleListNew = new ArrayList(); - for (Role roleListNewRoleToAttach : roleListNew) { - roleListNewRoleToAttach = em.getReference(roleListNewRoleToAttach.getClass(), roleListNewRoleToAttach.getId()); - attachedRoleListNew.add(roleListNewRoleToAttach); - } - roleListNew = attachedRoleListNew; - vmUser.setRoleList(roleListNew); - List attachedRootCauseListNew = new ArrayList(); - for (RootCause rootCauseListNewRootCauseToAttach : rootCauseListNew) { - rootCauseListNewRootCauseToAttach = em.getReference(rootCauseListNewRootCauseToAttach.getClass(), rootCauseListNewRootCauseToAttach.getRootCausePK()); - attachedRootCauseListNew.add(rootCauseListNewRootCauseToAttach); - } - rootCauseListNew = attachedRootCauseListNew; - vmUser.setRootCauseList(rootCauseListNew); - List attachedExecutionStepListNew = new ArrayList(); - for (ExecutionStep executionStepListNewExecutionStepToAttach : executionStepListNew) { - executionStepListNewExecutionStepToAttach = em.getReference(executionStepListNewExecutionStepToAttach.getClass(), executionStepListNewExecutionStepToAttach.getExecutionStepPK()); - attachedExecutionStepListNew.add(executionStepListNewExecutionStepToAttach); - } - executionStepListNew = attachedExecutionStepListNew; - vmUser.setExecutionStepList(executionStepListNew); - List attachedExecutionStepList1New = new ArrayList(); - for (ExecutionStep executionStepList1NewExecutionStepToAttach : executionStepList1New) { - executionStepList1NewExecutionStepToAttach = em.getReference(executionStepList1NewExecutionStepToAttach.getClass(), executionStepList1NewExecutionStepToAttach.getExecutionStepPK()); - attachedExecutionStepList1New.add(executionStepList1NewExecutionStepToAttach); - } - executionStepList1New = attachedExecutionStepList1New; - vmUser.setExecutionStepList1(executionStepList1New); - List attachedUserTestProjectRoleListNew = new ArrayList(); - for (UserTestProjectRole userTestProjectRoleListNewUserTestProjectRoleToAttach : userTestProjectRoleListNew) { - userTestProjectRoleListNewUserTestProjectRoleToAttach = em.getReference(userTestProjectRoleListNewUserTestProjectRoleToAttach.getClass(), userTestProjectRoleListNewUserTestProjectRoleToAttach.getUserTestProjectRolePK()); - attachedUserTestProjectRoleListNew.add(userTestProjectRoleListNewUserTestProjectRoleToAttach); - } - userTestProjectRoleListNew = attachedUserTestProjectRoleListNew; - vmUser.setUserTestProjectRoleList(userTestProjectRoleListNew); - List attachedUserTestPlanRoleListNew = new ArrayList(); - for (UserTestPlanRole userTestPlanRoleListNewUserTestPlanRoleToAttach : userTestPlanRoleListNew) { - userTestPlanRoleListNewUserTestPlanRoleToAttach = em.getReference(userTestPlanRoleListNewUserTestPlanRoleToAttach.getClass(), userTestPlanRoleListNewUserTestPlanRoleToAttach.getUserTestPlanRolePK()); - attachedUserTestPlanRoleListNew.add(userTestPlanRoleListNewUserTestPlanRoleToAttach); - } - userTestPlanRoleListNew = attachedUserTestPlanRoleListNew; - vmUser.setUserTestPlanRoleList(userTestPlanRoleListNew); - List attachedUserModifiedRecordListNew = new ArrayList(); - for (UserModifiedRecord userModifiedRecordListNewUserModifiedRecordToAttach : userModifiedRecordListNew) { - userModifiedRecordListNewUserModifiedRecordToAttach = em.getReference(userModifiedRecordListNewUserModifiedRecordToAttach.getClass(), userModifiedRecordListNewUserModifiedRecordToAttach.getUserModifiedRecordPK()); - attachedUserModifiedRecordListNew.add(userModifiedRecordListNewUserModifiedRecordToAttach); - } - userModifiedRecordListNew = attachedUserModifiedRecordListNew; - vmUser.setUserModifiedRecordList(userModifiedRecordListNew); - List attachedUserHasInvestigationListNew = new ArrayList(); - for (UserHasInvestigation userHasInvestigationListNewUserHasInvestigationToAttach : userHasInvestigationListNew) { - userHasInvestigationListNewUserHasInvestigationToAttach = em.getReference(userHasInvestigationListNewUserHasInvestigationToAttach.getClass(), userHasInvestigationListNewUserHasInvestigationToAttach.getUserHasInvestigationPK()); - attachedUserHasInvestigationListNew.add(userHasInvestigationListNewUserHasInvestigationToAttach); - } - userHasInvestigationListNew = attachedUserHasInvestigationListNew; - vmUser.setUserHasInvestigationList(userHasInvestigationListNew); - List attachedUserAssigmentListNew = new ArrayList(); - for (UserAssigment userAssigmentListNewUserAssigmentToAttach : userAssigmentListNew) { - userAssigmentListNewUserAssigmentToAttach = em.getReference(userAssigmentListNewUserAssigmentToAttach.getClass(), userAssigmentListNewUserAssigmentToAttach.getUserAssigmentPK()); - attachedUserAssigmentListNew.add(userAssigmentListNewUserAssigmentToAttach); - } - userAssigmentListNew = attachedUserAssigmentListNew; - vmUser.setUserAssigmentList(userAssigmentListNew); - List attachedUserAssigmentList1New = new ArrayList(); - for (UserAssigment userAssigmentList1NewUserAssigmentToAttach : userAssigmentList1New) { - userAssigmentList1NewUserAssigmentToAttach = em.getReference(userAssigmentList1NewUserAssigmentToAttach.getClass(), userAssigmentList1NewUserAssigmentToAttach.getUserAssigmentPK()); - attachedUserAssigmentList1New.add(userAssigmentList1NewUserAssigmentToAttach); - } - userAssigmentList1New = attachedUserAssigmentList1New; - vmUser.setUserAssigmentList1(userAssigmentList1New); - List attachedExecutionStepHasIssueListNew = new ArrayList(); - for (ExecutionStepHasIssue executionStepHasIssueListNewExecutionStepHasIssueToAttach : executionStepHasIssueListNew) { - executionStepHasIssueListNewExecutionStepHasIssueToAttach = em.getReference(executionStepHasIssueListNewExecutionStepHasIssueToAttach.getClass(), executionStepHasIssueListNewExecutionStepHasIssueToAttach.getExecutionStepHasIssuePK()); - attachedExecutionStepHasIssueListNew.add(executionStepHasIssueListNewExecutionStepHasIssueToAttach); - } - executionStepHasIssueListNew = attachedExecutionStepHasIssueListNew; - vmUser.setExecutionStepHasIssueList(executionStepHasIssueListNew); - List attachedExecutionStepHasVmUserListNew = new ArrayList(); - for (ExecutionStepHasVmUser executionStepHasVmUserListNewExecutionStepHasVmUserToAttach : executionStepHasVmUserListNew) { - executionStepHasVmUserListNewExecutionStepHasVmUserToAttach = em.getReference(executionStepHasVmUserListNewExecutionStepHasVmUserToAttach.getClass(), executionStepHasVmUserListNewExecutionStepHasVmUserToAttach.getExecutionStepHasVmUserPK()); - attachedExecutionStepHasVmUserListNew.add(executionStepHasVmUserListNewExecutionStepHasVmUserToAttach); - } - executionStepHasVmUserListNew = attachedExecutionStepHasVmUserListNew; - vmUser.setExecutionStepHasVmUserList(executionStepHasVmUserListNew); - List attachedHistoryModificationListNew = new ArrayList(); - for (History historyModificationListNewHistoryToAttach : historyModificationListNew) { - historyModificationListNewHistoryToAttach = em.getReference(historyModificationListNewHistoryToAttach.getClass(), historyModificationListNewHistoryToAttach.getId()); - attachedHistoryModificationListNew.add(historyModificationListNewHistoryToAttach); - } - historyModificationListNew = attachedHistoryModificationListNew; - vmUser.setHistoryModificationList(historyModificationListNew); - List attachedNotificationListNew = new ArrayList(); - for (Notification notificationListNewNotificationToAttach : notificationListNew) { - notificationListNewNotificationToAttach = em.getReference(notificationListNewNotificationToAttach.getClass(), notificationListNewNotificationToAttach.getNotificationPK()); - attachedNotificationListNew.add(notificationListNewNotificationToAttach); - } - notificationListNew = attachedNotificationListNew; - vmUser.setNotificationList(notificationListNew); - List attachedNotificationList1New = new ArrayList(); - for (Notification notificationList1NewNotificationToAttach : notificationList1New) { - notificationList1NewNotificationToAttach = em.getReference(notificationList1NewNotificationToAttach.getClass(), notificationList1NewNotificationToAttach.getNotificationPK()); - attachedNotificationList1New.add(notificationList1NewNotificationToAttach); - } - notificationList1New = attachedNotificationList1New; - vmUser.setNotificationList1(notificationList1New); - vmUser = em.merge(vmUser); - if (userStatusIdOld != null && !userStatusIdOld.equals(userStatusIdNew)) { - userStatusIdOld.getVmUserList().remove(vmUser); - userStatusIdOld = em.merge(userStatusIdOld); - } - if (userStatusIdNew != null && !userStatusIdNew.equals(userStatusIdOld)) { - userStatusIdNew.getVmUserList().add(vmUser); - userStatusIdNew = em.merge(userStatusIdNew); - } - for (CorrectiveAction correctiveActionListOldCorrectiveAction : correctiveActionListOld) { - if (!correctiveActionListNew.contains(correctiveActionListOldCorrectiveAction)) { - correctiveActionListOldCorrectiveAction.getVmUserList().remove(vmUser); - correctiveActionListOldCorrectiveAction = em.merge(correctiveActionListOldCorrectiveAction); - } - } - for (CorrectiveAction correctiveActionListNewCorrectiveAction : correctiveActionListNew) { - if (!correctiveActionListOld.contains(correctiveActionListNewCorrectiveAction)) { - correctiveActionListNewCorrectiveAction.getVmUserList().add(vmUser); - correctiveActionListNewCorrectiveAction = em.merge(correctiveActionListNewCorrectiveAction); - } - } - for (Role roleListOldRole : roleListOld) { - if (!roleListNew.contains(roleListOldRole)) { - roleListOldRole.getVmUserList().remove(vmUser); - roleListOldRole = em.merge(roleListOldRole); - } - } - for (Role roleListNewRole : roleListNew) { - if (!roleListOld.contains(roleListNewRole)) { - roleListNewRole.getVmUserList().add(vmUser); - roleListNewRole = em.merge(roleListNewRole); - } - } - for (RootCause rootCauseListOldRootCause : rootCauseListOld) { - if (!rootCauseListNew.contains(rootCauseListOldRootCause)) { - rootCauseListOldRootCause.getVmUserList().remove(vmUser); - rootCauseListOldRootCause = em.merge(rootCauseListOldRootCause); - } - } - for (RootCause rootCauseListNewRootCause : rootCauseListNew) { - if (!rootCauseListOld.contains(rootCauseListNewRootCause)) { - rootCauseListNewRootCause.getVmUserList().add(vmUser); - rootCauseListNewRootCause = em.merge(rootCauseListNewRootCause); - } - } - for (ExecutionStep executionStepListOldExecutionStep : executionStepListOld) { - if (!executionStepListNew.contains(executionStepListOldExecutionStep)) { - executionStepListOldExecutionStep.setAssignee(null); - executionStepListOldExecutionStep = em.merge(executionStepListOldExecutionStep); - } - } - for (ExecutionStep executionStepListNewExecutionStep : executionStepListNew) { - if (!executionStepListOld.contains(executionStepListNewExecutionStep)) { - VmUser oldAssigneeOfExecutionStepListNewExecutionStep = executionStepListNewExecutionStep.getAssignee(); - executionStepListNewExecutionStep.setAssignee(vmUser); - executionStepListNewExecutionStep = em.merge(executionStepListNewExecutionStep); - if (oldAssigneeOfExecutionStepListNewExecutionStep != null && !oldAssigneeOfExecutionStepListNewExecutionStep.equals(vmUser)) { - oldAssigneeOfExecutionStepListNewExecutionStep.getExecutionStepList().remove(executionStepListNewExecutionStep); - oldAssigneeOfExecutionStepListNewExecutionStep = em.merge(oldAssigneeOfExecutionStepListNewExecutionStep); - } - } - } - for (ExecutionStep executionStepList1OldExecutionStep : executionStepList1Old) { - if (!executionStepList1New.contains(executionStepList1OldExecutionStep)) { - executionStepList1OldExecutionStep.setAssigner(null); - executionStepList1OldExecutionStep = em.merge(executionStepList1OldExecutionStep); - } - } - for (ExecutionStep executionStepList1NewExecutionStep : executionStepList1New) { - if (!executionStepList1Old.contains(executionStepList1NewExecutionStep)) { - VmUser oldAssignerOfExecutionStepList1NewExecutionStep = executionStepList1NewExecutionStep.getAssigner(); - executionStepList1NewExecutionStep.setAssigner(vmUser); - executionStepList1NewExecutionStep = em.merge(executionStepList1NewExecutionStep); - if (oldAssignerOfExecutionStepList1NewExecutionStep != null && !oldAssignerOfExecutionStepList1NewExecutionStep.equals(vmUser)) { - oldAssignerOfExecutionStepList1NewExecutionStep.getExecutionStepList1().remove(executionStepList1NewExecutionStep); - oldAssignerOfExecutionStepList1NewExecutionStep = em.merge(oldAssignerOfExecutionStepList1NewExecutionStep); - } - } - } - for (UserTestProjectRole userTestProjectRoleListNewUserTestProjectRole : userTestProjectRoleListNew) { - if (!userTestProjectRoleListOld.contains(userTestProjectRoleListNewUserTestProjectRole)) { - VmUser oldVmUserOfUserTestProjectRoleListNewUserTestProjectRole = userTestProjectRoleListNewUserTestProjectRole.getVmUser(); - userTestProjectRoleListNewUserTestProjectRole.setVmUser(vmUser); - userTestProjectRoleListNewUserTestProjectRole = em.merge(userTestProjectRoleListNewUserTestProjectRole); - if (oldVmUserOfUserTestProjectRoleListNewUserTestProjectRole != null && !oldVmUserOfUserTestProjectRoleListNewUserTestProjectRole.equals(vmUser)) { - oldVmUserOfUserTestProjectRoleListNewUserTestProjectRole.getUserTestProjectRoleList().remove(userTestProjectRoleListNewUserTestProjectRole); - oldVmUserOfUserTestProjectRoleListNewUserTestProjectRole = em.merge(oldVmUserOfUserTestProjectRoleListNewUserTestProjectRole); - } - } - } - for (UserTestPlanRole userTestPlanRoleListNewUserTestPlanRole : userTestPlanRoleListNew) { - if (!userTestPlanRoleListOld.contains(userTestPlanRoleListNewUserTestPlanRole)) { - VmUser oldVmUserOfUserTestPlanRoleListNewUserTestPlanRole = userTestPlanRoleListNewUserTestPlanRole.getVmUser(); - userTestPlanRoleListNewUserTestPlanRole.setVmUser(vmUser); - userTestPlanRoleListNewUserTestPlanRole = em.merge(userTestPlanRoleListNewUserTestPlanRole); - if (oldVmUserOfUserTestPlanRoleListNewUserTestPlanRole != null && !oldVmUserOfUserTestPlanRoleListNewUserTestPlanRole.equals(vmUser)) { - oldVmUserOfUserTestPlanRoleListNewUserTestPlanRole.getUserTestPlanRoleList().remove(userTestPlanRoleListNewUserTestPlanRole); - oldVmUserOfUserTestPlanRoleListNewUserTestPlanRole = em.merge(oldVmUserOfUserTestPlanRoleListNewUserTestPlanRole); - } - } - } - for (UserModifiedRecord userModifiedRecordListNewUserModifiedRecord : userModifiedRecordListNew) { - if (!userModifiedRecordListOld.contains(userModifiedRecordListNewUserModifiedRecord)) { - VmUser oldVmUserOfUserModifiedRecordListNewUserModifiedRecord = userModifiedRecordListNewUserModifiedRecord.getVmUser(); - userModifiedRecordListNewUserModifiedRecord.setVmUser(vmUser); - userModifiedRecordListNewUserModifiedRecord = em.merge(userModifiedRecordListNewUserModifiedRecord); - if (oldVmUserOfUserModifiedRecordListNewUserModifiedRecord != null && !oldVmUserOfUserModifiedRecordListNewUserModifiedRecord.equals(vmUser)) { - oldVmUserOfUserModifiedRecordListNewUserModifiedRecord.getUserModifiedRecordList().remove(userModifiedRecordListNewUserModifiedRecord); - oldVmUserOfUserModifiedRecordListNewUserModifiedRecord = em.merge(oldVmUserOfUserModifiedRecordListNewUserModifiedRecord); - } - } - } - for (UserHasInvestigation userHasInvestigationListNewUserHasInvestigation : userHasInvestigationListNew) { - if (!userHasInvestigationListOld.contains(userHasInvestigationListNewUserHasInvestigation)) { - VmUser oldVmUserOfUserHasInvestigationListNewUserHasInvestigation = userHasInvestigationListNewUserHasInvestigation.getVmUser(); - userHasInvestigationListNewUserHasInvestigation.setVmUser(vmUser); - userHasInvestigationListNewUserHasInvestigation = em.merge(userHasInvestigationListNewUserHasInvestigation); - if (oldVmUserOfUserHasInvestigationListNewUserHasInvestigation != null && !oldVmUserOfUserHasInvestigationListNewUserHasInvestigation.equals(vmUser)) { - oldVmUserOfUserHasInvestigationListNewUserHasInvestigation.getUserHasInvestigationList().remove(userHasInvestigationListNewUserHasInvestigation); - oldVmUserOfUserHasInvestigationListNewUserHasInvestigation = em.merge(oldVmUserOfUserHasInvestigationListNewUserHasInvestigation); - } - } - } - for (UserAssigment userAssigmentListNewUserAssigment : userAssigmentListNew) { - if (!userAssigmentListOld.contains(userAssigmentListNewUserAssigment)) { - VmUser oldVmUserOfUserAssigmentListNewUserAssigment = userAssigmentListNewUserAssigment.getVmUser(); - userAssigmentListNewUserAssigment.setVmUser(vmUser); - userAssigmentListNewUserAssigment = em.merge(userAssigmentListNewUserAssigment); - if (oldVmUserOfUserAssigmentListNewUserAssigment != null && !oldVmUserOfUserAssigmentListNewUserAssigment.equals(vmUser)) { - oldVmUserOfUserAssigmentListNewUserAssigment.getUserAssigmentList().remove(userAssigmentListNewUserAssigment); - oldVmUserOfUserAssigmentListNewUserAssigment = em.merge(oldVmUserOfUserAssigmentListNewUserAssigment); - } - } - } - for (UserAssigment userAssigmentList1NewUserAssigment : userAssigmentList1New) { - if (!userAssigmentList1Old.contains(userAssigmentList1NewUserAssigment)) { - VmUser oldAssigneeIdOfUserAssigmentList1NewUserAssigment = userAssigmentList1NewUserAssigment.getAssigneeId(); - userAssigmentList1NewUserAssigment.setAssigneeId(vmUser); - userAssigmentList1NewUserAssigment = em.merge(userAssigmentList1NewUserAssigment); - if (oldAssigneeIdOfUserAssigmentList1NewUserAssigment != null && !oldAssigneeIdOfUserAssigmentList1NewUserAssigment.equals(vmUser)) { - oldAssigneeIdOfUserAssigmentList1NewUserAssigment.getUserAssigmentList1().remove(userAssigmentList1NewUserAssigment); - oldAssigneeIdOfUserAssigmentList1NewUserAssigment = em.merge(oldAssigneeIdOfUserAssigmentList1NewUserAssigment); - } - } - } - for (ExecutionStepHasIssue executionStepHasIssueListOldExecutionStepHasIssue : executionStepHasIssueListOld) { - if (!executionStepHasIssueListNew.contains(executionStepHasIssueListOldExecutionStepHasIssue)) { - executionStepHasIssueListOldExecutionStepHasIssue.getVmUserList().remove(vmUser); - executionStepHasIssueListOldExecutionStepHasIssue = em.merge(executionStepHasIssueListOldExecutionStepHasIssue); - } - } - for (ExecutionStepHasIssue executionStepHasIssueListNewExecutionStepHasIssue : executionStepHasIssueListNew) { - if (!executionStepHasIssueListOld.contains(executionStepHasIssueListNewExecutionStepHasIssue)) { - executionStepHasIssueListNewExecutionStepHasIssue.getVmUserList().add(vmUser); - executionStepHasIssueListNewExecutionStepHasIssue = em.merge(executionStepHasIssueListNewExecutionStepHasIssue); - } - } - for (ExecutionStepHasVmUser executionStepHasVmUserListNewExecutionStepHasVmUser : executionStepHasVmUserListNew) { - if (!executionStepHasVmUserListOld.contains(executionStepHasVmUserListNewExecutionStepHasVmUser)) { - VmUser oldVmUserOfExecutionStepHasVmUserListNewExecutionStepHasVmUser = executionStepHasVmUserListNewExecutionStepHasVmUser.getVmUser(); - executionStepHasVmUserListNewExecutionStepHasVmUser.setVmUser(vmUser); - executionStepHasVmUserListNewExecutionStepHasVmUser = em.merge(executionStepHasVmUserListNewExecutionStepHasVmUser); - if (oldVmUserOfExecutionStepHasVmUserListNewExecutionStepHasVmUser != null && !oldVmUserOfExecutionStepHasVmUserListNewExecutionStepHasVmUser.equals(vmUser)) { - oldVmUserOfExecutionStepHasVmUserListNewExecutionStepHasVmUser.getExecutionStepHasVmUserList().remove(executionStepHasVmUserListNewExecutionStepHasVmUser); - oldVmUserOfExecutionStepHasVmUserListNewExecutionStepHasVmUser = em.merge(oldVmUserOfExecutionStepHasVmUserListNewExecutionStepHasVmUser); - } - } - } - for (History historyModificationListNewHistory : historyModificationListNew) { - if (!historyModificationListOld.contains(historyModificationListNewHistory)) { - VmUser oldModifierIdOfHistoryModificationListNewHistory = historyModificationListNewHistory.getModifierId(); - historyModificationListNewHistory.setModifierId(vmUser); - historyModificationListNewHistory = em.merge(historyModificationListNewHistory); - if (oldModifierIdOfHistoryModificationListNewHistory != null && !oldModifierIdOfHistoryModificationListNewHistory.equals(vmUser)) { - oldModifierIdOfHistoryModificationListNewHistory.getHistoryModificationList().remove(historyModificationListNewHistory); - oldModifierIdOfHistoryModificationListNewHistory = em.merge(oldModifierIdOfHistoryModificationListNewHistory); - } - } - } - for (Notification notificationListNewNotification : notificationListNew) { - if (!notificationListOld.contains(notificationListNewNotification)) { - VmUser oldTargetOfNotificationListNewNotification = notificationListNewNotification.getTargetUser(); - notificationListNewNotification.setTargetUser(vmUser); - notificationListNewNotification = em.merge(notificationListNewNotification); - if (oldTargetOfNotificationListNewNotification != null && !oldTargetOfNotificationListNewNotification.equals(vmUser)) { - oldTargetOfNotificationListNewNotification.getNotificationList().remove(notificationListNewNotification); - oldTargetOfNotificationListNewNotification = em.merge(oldTargetOfNotificationListNewNotification); - } - } - } - for (Notification notificationList1NewNotification : notificationList1New) { - if (!notificationList1Old.contains(notificationList1NewNotification)) { - VmUser oldAuthorOfNotificationList1NewNotification = notificationList1NewNotification.getAuthor(); - notificationList1NewNotification.setAuthor(vmUser); - notificationList1NewNotification = em.merge(notificationList1NewNotification); - if (oldAuthorOfNotificationList1NewNotification != null && !oldAuthorOfNotificationList1NewNotification.equals(vmUser)) { - oldAuthorOfNotificationList1NewNotification.getNotificationList1().remove(notificationList1NewNotification); - oldAuthorOfNotificationList1NewNotification = em.merge(oldAuthorOfNotificationList1NewNotification); - } - } - } - em.getTransaction().commit(); - } - catch (Exception ex) { - String msg = ex.getLocalizedMessage(); - if (msg == null || msg.length() == 0) { - Integer id = vmUser.getId(); - if (findVmUser(id) == null) { - throw new NonexistentEntityException("The vmUser with id " + id + " no longer exists."); - } - } - throw ex; - } - finally { - if (em != null) { - em.close(); - } - } - } - - public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { - EntityManager em = null; - try { - em = getEntityManager(); - em.getTransaction().begin(); - VmUser vmUser; - try { - vmUser = em.getReference(VmUser.class, id); - vmUser.getId(); - } - catch (EntityNotFoundException enfe) { - throw new NonexistentEntityException("The vmUser with id " + id + " no longer exists.", enfe); - } - List illegalOrphanMessages = null; - List userTestProjectRoleListOrphanCheck = vmUser.getUserTestProjectRoleList(); - for (UserTestProjectRole userTestProjectRoleListOrphanCheckUserTestProjectRole : userTestProjectRoleListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This VmUser (" + vmUser + ") cannot be destroyed since the UserTestProjectRole " + userTestProjectRoleListOrphanCheckUserTestProjectRole + " in its userTestProjectRoleList field has a non-nullable vmUser field."); - } - List userTestPlanRoleListOrphanCheck = vmUser.getUserTestPlanRoleList(); - for (UserTestPlanRole userTestPlanRoleListOrphanCheckUserTestPlanRole : userTestPlanRoleListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This VmUser (" + vmUser + ") cannot be destroyed since the UserTestPlanRole " + userTestPlanRoleListOrphanCheckUserTestPlanRole + " in its userTestPlanRoleList field has a non-nullable vmUser field."); - } - List userModifiedRecordListOrphanCheck = vmUser.getUserModifiedRecordList(); - for (UserModifiedRecord userModifiedRecordListOrphanCheckUserModifiedRecord : userModifiedRecordListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This VmUser (" + vmUser + ") cannot be destroyed since the UserModifiedRecord " + userModifiedRecordListOrphanCheckUserModifiedRecord + " in its userModifiedRecordList field has a non-nullable vmUser field."); - } - List userHasInvestigationListOrphanCheck = vmUser.getUserHasInvestigationList(); - for (UserHasInvestigation userHasInvestigationListOrphanCheckUserHasInvestigation : userHasInvestigationListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This VmUser (" + vmUser + ") cannot be destroyed since the UserHasInvestigation " + userHasInvestigationListOrphanCheckUserHasInvestigation + " in its userHasInvestigationList field has a non-nullable vmUser field."); - } - List userAssigmentListOrphanCheck = vmUser.getUserAssigmentList(); - for (UserAssigment userAssigmentListOrphanCheckUserAssigment : userAssigmentListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This VmUser (" + vmUser + ") cannot be destroyed since the UserAssigment " + userAssigmentListOrphanCheckUserAssigment + " in its userAssigmentList field has a non-nullable vmUser field."); - } - List userAssigmentList1OrphanCheck = vmUser.getUserAssigmentList1(); - for (UserAssigment userAssigmentList1OrphanCheckUserAssigment : userAssigmentList1OrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This VmUser (" + vmUser + ") cannot be destroyed since the UserAssigment " + userAssigmentList1OrphanCheckUserAssigment + " in its userAssigmentList1 field has a non-nullable assigneeId field."); - } - List executionStepHasVmUserListOrphanCheck = vmUser.getExecutionStepHasVmUserList(); - for (ExecutionStepHasVmUser executionStepHasVmUserListOrphanCheckExecutionStepHasVmUser : executionStepHasVmUserListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This VmUser (" + vmUser + ") cannot be destroyed since the ExecutionStepHasVmUser " + executionStepHasVmUserListOrphanCheckExecutionStepHasVmUser + " in its executionStepHasVmUserList field has a non-nullable vmUser field."); - } - List historyModificationListOrphanCheck = vmUser.getHistoryModificationList(); - for (History historyModificationListOrphanCheckHistory : historyModificationListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This VmUser (" + vmUser + ") cannot be destroyed since the History " + historyModificationListOrphanCheckHistory + " in its historyModificationList field has a non-nullable modifierId field."); - } - List notificationListOrphanCheck = vmUser.getNotificationList(); - for (Notification notificationListOrphanCheckNotification : notificationListOrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This VmUser (" + vmUser + ") cannot be destroyed since the Notification " + notificationListOrphanCheckNotification + " in its notificationList field has a non-nullable target field."); - } - List notificationList1OrphanCheck = vmUser.getNotificationList1(); - for (Notification notificationList1OrphanCheckNotification : notificationList1OrphanCheck) { - if (illegalOrphanMessages == null) { - illegalOrphanMessages = new ArrayList(); - } - illegalOrphanMessages.add("This VmUser (" + vmUser + ") cannot be destroyed since the Notification " + notificationList1OrphanCheckNotification + " in its notificationList1 field has a non-nullable author field."); - } - if (illegalOrphanMessages != null) { - throw new IllegalOrphanException(illegalOrphanMessages); - } - UserStatus userStatusId = vmUser.getUserStatusId(); - if (userStatusId != null) { - userStatusId.getVmUserList().remove(vmUser); - userStatusId = em.merge(userStatusId); - } - List correctiveActionList = vmUser.getCorrectiveActionList(); - for (CorrectiveAction correctiveActionListCorrectiveAction : correctiveActionList) { - correctiveActionListCorrectiveAction.getVmUserList().remove(vmUser); - correctiveActionListCorrectiveAction = em.merge(correctiveActionListCorrectiveAction); - } - List roleList = vmUser.getRoleList(); - for (Role roleListRole : roleList) { - roleListRole.getVmUserList().remove(vmUser); - roleListRole = em.merge(roleListRole); - } - List rootCauseList = vmUser.getRootCauseList(); - for (RootCause rootCauseListRootCause : rootCauseList) { - rootCauseListRootCause.getVmUserList().remove(vmUser); - rootCauseListRootCause = em.merge(rootCauseListRootCause); - } - List executionStepList = vmUser.getExecutionStepList(); - for (ExecutionStep executionStepListExecutionStep : executionStepList) { - executionStepListExecutionStep.setAssignee(null); - executionStepListExecutionStep = em.merge(executionStepListExecutionStep); - } - List executionStepList1 = vmUser.getExecutionStepList1(); - for (ExecutionStep executionStepList1ExecutionStep : executionStepList1) { - executionStepList1ExecutionStep.setAssigner(null); - executionStepList1ExecutionStep = em.merge(executionStepList1ExecutionStep); - } - List executionStepHasIssueList = vmUser.getExecutionStepHasIssueList(); - for (ExecutionStepHasIssue executionStepHasIssueListExecutionStepHasIssue : executionStepHasIssueList) { - executionStepHasIssueListExecutionStepHasIssue.getVmUserList().remove(vmUser); - executionStepHasIssueListExecutionStepHasIssue = em.merge(executionStepHasIssueListExecutionStepHasIssue); - } - em.remove(vmUser); - em.getTransaction().commit(); - } - finally { - if (em != null) { - em.close(); - } - } - } - - public List findVmUserEntities() { - return findVmUserEntities(true, -1, -1); - } - - public List findVmUserEntities(int maxResults, int firstResult) { - return findVmUserEntities(false, maxResults, firstResult); - } - - private List findVmUserEntities(boolean all, int maxResults, int firstResult) { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - cq.select(cq.from(VmUser.class)); - Query q = em.createQuery(cq); - if (!all) { - q.setMaxResults(maxResults); - q.setFirstResult(firstResult); - } - return q.getResultList(); - } - finally { - em.close(); - } - } - - public VmUser findVmUser(Integer id) { - EntityManager em = getEntityManager(); - try { - return em.find(VmUser.class, id); - } - finally { - em.close(); - } - } - - public int getVmUserCount() { - EntityManager em = getEntityManager(); - try { - CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); - Root rt = cq.from(VmUser.class); - cq.select(em.getCriteriaBuilder().count(rt)); - Query q = em.createQuery(cq); - return ((Long) q.getSingleResult()).intValue(); - } - finally { - em.close(); - } - } - -} +package com.validation.manager.core.db.controller; + +import java.io.Serializable; +import javax.persistence.Query; +import javax.persistence.EntityNotFoundException; +import javax.persistence.criteria.CriteriaQuery; +import javax.persistence.criteria.Root; +import com.validation.manager.core.db.UserStatus; +import com.validation.manager.core.db.CorrectiveAction; +import java.util.ArrayList; +import java.util.List; +import com.validation.manager.core.db.Role; +import com.validation.manager.core.db.RootCause; +import com.validation.manager.core.db.ExecutionStep; +import com.validation.manager.core.db.UserTestProjectRole; +import com.validation.manager.core.db.UserTestPlanRole; +import com.validation.manager.core.db.UserModifiedRecord; +import com.validation.manager.core.db.UserHasInvestigation; +import com.validation.manager.core.db.UserAssigment; +import com.validation.manager.core.db.ExecutionStepHasIssue; +import com.validation.manager.core.db.ExecutionStepHasVmUser; +import com.validation.manager.core.db.History; +import com.validation.manager.core.db.Notification; +import com.validation.manager.core.db.VmUser; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import javax.persistence.EntityManager; +import javax.persistence.EntityManagerFactory; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class VmUserJpaController implements Serializable { + + public VmUserJpaController(EntityManagerFactory emf) { + this.emf = emf; + } + private EntityManagerFactory emf = null; + + public EntityManager getEntityManager() { + return emf.createEntityManager(); + } + + public void create(VmUser vmUser) { + if (vmUser.getCorrectiveActionList() == null) { + vmUser.setCorrectiveActionList(new ArrayList<>()); + } + if (vmUser.getRoleList() == null) { + vmUser.setRoleList(new ArrayList<>()); + } + if (vmUser.getRootCauseList() == null) { + vmUser.setRootCauseList(new ArrayList<>()); + } + if (vmUser.getExecutionStepList() == null) { + vmUser.setExecutionStepList(new ArrayList<>()); + } + if (vmUser.getExecutionStepList1() == null) { + vmUser.setExecutionStepList1(new ArrayList<>()); + } + if (vmUser.getUserTestProjectRoleList() == null) { + vmUser.setUserTestProjectRoleList(new ArrayList<>()); + } + if (vmUser.getUserTestPlanRoleList() == null) { + vmUser.setUserTestPlanRoleList(new ArrayList<>()); + } + if (vmUser.getUserModifiedRecordList() == null) { + vmUser.setUserModifiedRecordList(new ArrayList<>()); + } + if (vmUser.getUserHasInvestigationList() == null) { + vmUser.setUserHasInvestigationList(new ArrayList<>()); + } + if (vmUser.getUserAssigmentList() == null) { + vmUser.setUserAssigmentList(new ArrayList<>()); + } + if (vmUser.getUserAssigmentList1() == null) { + vmUser.setUserAssigmentList1(new ArrayList<>()); + } + if (vmUser.getExecutionStepHasIssueList() == null) { + vmUser.setExecutionStepHasIssueList(new ArrayList<>()); + } + if (vmUser.getExecutionStepHasVmUserList() == null) { + vmUser.setExecutionStepHasVmUserList(new ArrayList<>()); + } + if (vmUser.getHistoryModificationList() == null) { + vmUser.setHistoryModificationList(new ArrayList<>()); + } + if (vmUser.getNotificationList() == null) { + vmUser.setNotificationList(new ArrayList<>()); + } + if (vmUser.getNotificationList1() == null) { + vmUser.setNotificationList1(new ArrayList<>()); + } + if (vmUser.getHistoryList() == null) { + vmUser.setHistoryList(new ArrayList<>()); + } + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + UserStatus userStatusId = vmUser.getUserStatusId(); + if (userStatusId != null) { + userStatusId = em.getReference(userStatusId.getClass(), userStatusId.getId()); + vmUser.setUserStatusId(userStatusId); + } + List attachedCorrectiveActionList = new ArrayList<>(); + for (CorrectiveAction correctiveActionListCorrectiveActionToAttach : vmUser.getCorrectiveActionList()) { + correctiveActionListCorrectiveActionToAttach = em.getReference(correctiveActionListCorrectiveActionToAttach.getClass(), correctiveActionListCorrectiveActionToAttach.getId()); + attachedCorrectiveActionList.add(correctiveActionListCorrectiveActionToAttach); + } + vmUser.setCorrectiveActionList(attachedCorrectiveActionList); + List attachedRoleList = new ArrayList<>(); + for (Role roleListRoleToAttach : vmUser.getRoleList()) { + roleListRoleToAttach = em.getReference(roleListRoleToAttach.getClass(), roleListRoleToAttach.getId()); + attachedRoleList.add(roleListRoleToAttach); + } + vmUser.setRoleList(attachedRoleList); + List attachedRootCauseList = new ArrayList<>(); + for (RootCause rootCauseListRootCauseToAttach : vmUser.getRootCauseList()) { + rootCauseListRootCauseToAttach = em.getReference(rootCauseListRootCauseToAttach.getClass(), rootCauseListRootCauseToAttach.getRootCausePK()); + attachedRootCauseList.add(rootCauseListRootCauseToAttach); + } + vmUser.setRootCauseList(attachedRootCauseList); + List attachedExecutionStepList = new ArrayList<>(); + for (ExecutionStep executionStepListExecutionStepToAttach : vmUser.getExecutionStepList()) { + executionStepListExecutionStepToAttach = em.getReference(executionStepListExecutionStepToAttach.getClass(), executionStepListExecutionStepToAttach.getExecutionStepPK()); + attachedExecutionStepList.add(executionStepListExecutionStepToAttach); + } + vmUser.setExecutionStepList(attachedExecutionStepList); + List attachedExecutionStepList1 = new ArrayList<>(); + for (ExecutionStep executionStepList1ExecutionStepToAttach : vmUser.getExecutionStepList1()) { + executionStepList1ExecutionStepToAttach = em.getReference(executionStepList1ExecutionStepToAttach.getClass(), executionStepList1ExecutionStepToAttach.getExecutionStepPK()); + attachedExecutionStepList1.add(executionStepList1ExecutionStepToAttach); + } + vmUser.setExecutionStepList1(attachedExecutionStepList1); + List attachedUserTestProjectRoleList = new ArrayList<>(); + for (UserTestProjectRole userTestProjectRoleListUserTestProjectRoleToAttach : vmUser.getUserTestProjectRoleList()) { + userTestProjectRoleListUserTestProjectRoleToAttach = em.getReference(userTestProjectRoleListUserTestProjectRoleToAttach.getClass(), userTestProjectRoleListUserTestProjectRoleToAttach.getUserTestProjectRolePK()); + attachedUserTestProjectRoleList.add(userTestProjectRoleListUserTestProjectRoleToAttach); + } + vmUser.setUserTestProjectRoleList(attachedUserTestProjectRoleList); + List attachedUserTestPlanRoleList = new ArrayList<>(); + for (UserTestPlanRole userTestPlanRoleListUserTestPlanRoleToAttach : vmUser.getUserTestPlanRoleList()) { + userTestPlanRoleListUserTestPlanRoleToAttach = em.getReference(userTestPlanRoleListUserTestPlanRoleToAttach.getClass(), userTestPlanRoleListUserTestPlanRoleToAttach.getUserTestPlanRolePK()); + attachedUserTestPlanRoleList.add(userTestPlanRoleListUserTestPlanRoleToAttach); + } + vmUser.setUserTestPlanRoleList(attachedUserTestPlanRoleList); + List attachedUserModifiedRecordList = new ArrayList<>(); + for (UserModifiedRecord userModifiedRecordListUserModifiedRecordToAttach : vmUser.getUserModifiedRecordList()) { + userModifiedRecordListUserModifiedRecordToAttach = em.getReference(userModifiedRecordListUserModifiedRecordToAttach.getClass(), userModifiedRecordListUserModifiedRecordToAttach.getUserModifiedRecordPK()); + attachedUserModifiedRecordList.add(userModifiedRecordListUserModifiedRecordToAttach); + } + vmUser.setUserModifiedRecordList(attachedUserModifiedRecordList); + List attachedUserHasInvestigationList = new ArrayList<>(); + for (UserHasInvestigation userHasInvestigationListUserHasInvestigationToAttach : vmUser.getUserHasInvestigationList()) { + userHasInvestigationListUserHasInvestigationToAttach = em.getReference(userHasInvestigationListUserHasInvestigationToAttach.getClass(), userHasInvestigationListUserHasInvestigationToAttach.getUserHasInvestigationPK()); + attachedUserHasInvestigationList.add(userHasInvestigationListUserHasInvestigationToAttach); + } + vmUser.setUserHasInvestigationList(attachedUserHasInvestigationList); + List attachedUserAssigmentList = new ArrayList<>(); + for (UserAssigment userAssigmentListUserAssigmentToAttach : vmUser.getUserAssigmentList()) { + userAssigmentListUserAssigmentToAttach = em.getReference(userAssigmentListUserAssigmentToAttach.getClass(), userAssigmentListUserAssigmentToAttach.getUserAssigmentPK()); + attachedUserAssigmentList.add(userAssigmentListUserAssigmentToAttach); + } + vmUser.setUserAssigmentList(attachedUserAssigmentList); + List attachedUserAssigmentList1 = new ArrayList<>(); + for (UserAssigment userAssigmentList1UserAssigmentToAttach : vmUser.getUserAssigmentList1()) { + userAssigmentList1UserAssigmentToAttach = em.getReference(userAssigmentList1UserAssigmentToAttach.getClass(), userAssigmentList1UserAssigmentToAttach.getUserAssigmentPK()); + attachedUserAssigmentList1.add(userAssigmentList1UserAssigmentToAttach); + } + vmUser.setUserAssigmentList1(attachedUserAssigmentList1); + List attachedExecutionStepHasIssueList = new ArrayList<>(); + for (ExecutionStepHasIssue executionStepHasIssueListExecutionStepHasIssueToAttach : vmUser.getExecutionStepHasIssueList()) { + executionStepHasIssueListExecutionStepHasIssueToAttach = em.getReference(executionStepHasIssueListExecutionStepHasIssueToAttach.getClass(), executionStepHasIssueListExecutionStepHasIssueToAttach.getExecutionStepHasIssuePK()); + attachedExecutionStepHasIssueList.add(executionStepHasIssueListExecutionStepHasIssueToAttach); + } + vmUser.setExecutionStepHasIssueList(attachedExecutionStepHasIssueList); + List attachedExecutionStepHasVmUserList = new ArrayList<>(); + for (ExecutionStepHasVmUser executionStepHasVmUserListExecutionStepHasVmUserToAttach : vmUser.getExecutionStepHasVmUserList()) { + executionStepHasVmUserListExecutionStepHasVmUserToAttach = em.getReference(executionStepHasVmUserListExecutionStepHasVmUserToAttach.getClass(), executionStepHasVmUserListExecutionStepHasVmUserToAttach.getExecutionStepHasVmUserPK()); + attachedExecutionStepHasVmUserList.add(executionStepHasVmUserListExecutionStepHasVmUserToAttach); + } + vmUser.setExecutionStepHasVmUserList(attachedExecutionStepHasVmUserList); + List attachedHistoryModificationList = new ArrayList<>(); + for (History historyModificationListHistoryToAttach : vmUser.getHistoryModificationList()) { + historyModificationListHistoryToAttach = em.getReference(historyModificationListHistoryToAttach.getClass(), historyModificationListHistoryToAttach.getId()); + attachedHistoryModificationList.add(historyModificationListHistoryToAttach); + } + vmUser.setHistoryModificationList(attachedHistoryModificationList); + List attachedNotificationList = new ArrayList<>(); + for (Notification notificationListNotificationToAttach : vmUser.getNotificationList()) { + notificationListNotificationToAttach = em.getReference(notificationListNotificationToAttach.getClass(), notificationListNotificationToAttach.getNotificationPK()); + attachedNotificationList.add(notificationListNotificationToAttach); + } + vmUser.setNotificationList(attachedNotificationList); + List attachedNotificationList1 = new ArrayList<>(); + for (Notification notificationList1NotificationToAttach : vmUser.getNotificationList1()) { + notificationList1NotificationToAttach = em.getReference(notificationList1NotificationToAttach.getClass(), notificationList1NotificationToAttach.getNotificationPK()); + attachedNotificationList1.add(notificationList1NotificationToAttach); + } + vmUser.setNotificationList1(attachedNotificationList1); + List attachedHistoryList = new ArrayList<>(); + for (History historyListHistoryToAttach : vmUser.getHistoryList()) { + historyListHistoryToAttach = em.getReference(historyListHistoryToAttach.getClass(), historyListHistoryToAttach.getId()); + attachedHistoryList.add(historyListHistoryToAttach); + } + vmUser.setHistoryList(attachedHistoryList); + em.persist(vmUser); + if (userStatusId != null) { + userStatusId.getVmUserList().add(vmUser); + userStatusId = em.merge(userStatusId); + } + for (CorrectiveAction correctiveActionListCorrectiveAction : vmUser.getCorrectiveActionList()) { + correctiveActionListCorrectiveAction.getVmUserList().add(vmUser); + correctiveActionListCorrectiveAction = em.merge(correctiveActionListCorrectiveAction); + } + for (Role roleListRole : vmUser.getRoleList()) { + roleListRole.getVmUserList().add(vmUser); + roleListRole = em.merge(roleListRole); + } + for (RootCause rootCauseListRootCause : vmUser.getRootCauseList()) { + rootCauseListRootCause.getVmUserList().add(vmUser); + rootCauseListRootCause = em.merge(rootCauseListRootCause); + } + for (ExecutionStep executionStepListExecutionStep : vmUser.getExecutionStepList()) { + VmUser oldAssigneeOfExecutionStepListExecutionStep = executionStepListExecutionStep.getAssignee(); + executionStepListExecutionStep.setAssignee(vmUser); + executionStepListExecutionStep = em.merge(executionStepListExecutionStep); + if (oldAssigneeOfExecutionStepListExecutionStep != null) { + oldAssigneeOfExecutionStepListExecutionStep.getExecutionStepList().remove(executionStepListExecutionStep); + oldAssigneeOfExecutionStepListExecutionStep = em.merge(oldAssigneeOfExecutionStepListExecutionStep); + } + } + for (ExecutionStep executionStepList1ExecutionStep : vmUser.getExecutionStepList1()) { + VmUser oldAssignerOfExecutionStepList1ExecutionStep = executionStepList1ExecutionStep.getAssigner(); + executionStepList1ExecutionStep.setAssigner(vmUser); + executionStepList1ExecutionStep = em.merge(executionStepList1ExecutionStep); + if (oldAssignerOfExecutionStepList1ExecutionStep != null) { + oldAssignerOfExecutionStepList1ExecutionStep.getExecutionStepList1().remove(executionStepList1ExecutionStep); + oldAssignerOfExecutionStepList1ExecutionStep = em.merge(oldAssignerOfExecutionStepList1ExecutionStep); + } + } + for (UserTestProjectRole userTestProjectRoleListUserTestProjectRole : vmUser.getUserTestProjectRoleList()) { + VmUser oldVmUserOfUserTestProjectRoleListUserTestProjectRole = userTestProjectRoleListUserTestProjectRole.getVmUser(); + userTestProjectRoleListUserTestProjectRole.setVmUser(vmUser); + userTestProjectRoleListUserTestProjectRole = em.merge(userTestProjectRoleListUserTestProjectRole); + if (oldVmUserOfUserTestProjectRoleListUserTestProjectRole != null) { + oldVmUserOfUserTestProjectRoleListUserTestProjectRole.getUserTestProjectRoleList().remove(userTestProjectRoleListUserTestProjectRole); + oldVmUserOfUserTestProjectRoleListUserTestProjectRole = em.merge(oldVmUserOfUserTestProjectRoleListUserTestProjectRole); + } + } + for (UserTestPlanRole userTestPlanRoleListUserTestPlanRole : vmUser.getUserTestPlanRoleList()) { + VmUser oldVmUserOfUserTestPlanRoleListUserTestPlanRole = userTestPlanRoleListUserTestPlanRole.getVmUser(); + userTestPlanRoleListUserTestPlanRole.setVmUser(vmUser); + userTestPlanRoleListUserTestPlanRole = em.merge(userTestPlanRoleListUserTestPlanRole); + if (oldVmUserOfUserTestPlanRoleListUserTestPlanRole != null) { + oldVmUserOfUserTestPlanRoleListUserTestPlanRole.getUserTestPlanRoleList().remove(userTestPlanRoleListUserTestPlanRole); + oldVmUserOfUserTestPlanRoleListUserTestPlanRole = em.merge(oldVmUserOfUserTestPlanRoleListUserTestPlanRole); + } + } + for (UserModifiedRecord userModifiedRecordListUserModifiedRecord : vmUser.getUserModifiedRecordList()) { + VmUser oldVmUserOfUserModifiedRecordListUserModifiedRecord = userModifiedRecordListUserModifiedRecord.getVmUser(); + userModifiedRecordListUserModifiedRecord.setVmUser(vmUser); + userModifiedRecordListUserModifiedRecord = em.merge(userModifiedRecordListUserModifiedRecord); + if (oldVmUserOfUserModifiedRecordListUserModifiedRecord != null) { + oldVmUserOfUserModifiedRecordListUserModifiedRecord.getUserModifiedRecordList().remove(userModifiedRecordListUserModifiedRecord); + oldVmUserOfUserModifiedRecordListUserModifiedRecord = em.merge(oldVmUserOfUserModifiedRecordListUserModifiedRecord); + } + } + for (UserHasInvestigation userHasInvestigationListUserHasInvestigation : vmUser.getUserHasInvestigationList()) { + VmUser oldVmUserOfUserHasInvestigationListUserHasInvestigation = userHasInvestigationListUserHasInvestigation.getVmUser(); + userHasInvestigationListUserHasInvestigation.setVmUser(vmUser); + userHasInvestigationListUserHasInvestigation = em.merge(userHasInvestigationListUserHasInvestigation); + if (oldVmUserOfUserHasInvestigationListUserHasInvestigation != null) { + oldVmUserOfUserHasInvestigationListUserHasInvestigation.getUserHasInvestigationList().remove(userHasInvestigationListUserHasInvestigation); + oldVmUserOfUserHasInvestigationListUserHasInvestigation = em.merge(oldVmUserOfUserHasInvestigationListUserHasInvestigation); + } + } + for (UserAssigment userAssigmentListUserAssigment : vmUser.getUserAssigmentList()) { + VmUser oldVmUserOfUserAssigmentListUserAssigment = userAssigmentListUserAssigment.getVmUser(); + userAssigmentListUserAssigment.setVmUser(vmUser); + userAssigmentListUserAssigment = em.merge(userAssigmentListUserAssigment); + if (oldVmUserOfUserAssigmentListUserAssigment != null) { + oldVmUserOfUserAssigmentListUserAssigment.getUserAssigmentList().remove(userAssigmentListUserAssigment); + oldVmUserOfUserAssigmentListUserAssigment = em.merge(oldVmUserOfUserAssigmentListUserAssigment); + } + } + for (UserAssigment userAssigmentList1UserAssigment : vmUser.getUserAssigmentList1()) { + VmUser oldAssigneeIdOfUserAssigmentList1UserAssigment = userAssigmentList1UserAssigment.getAssigneeId(); + userAssigmentList1UserAssigment.setAssigneeId(vmUser); + userAssigmentList1UserAssigment = em.merge(userAssigmentList1UserAssigment); + if (oldAssigneeIdOfUserAssigmentList1UserAssigment != null) { + oldAssigneeIdOfUserAssigmentList1UserAssigment.getUserAssigmentList1().remove(userAssigmentList1UserAssigment); + oldAssigneeIdOfUserAssigmentList1UserAssigment = em.merge(oldAssigneeIdOfUserAssigmentList1UserAssigment); + } + } + for (ExecutionStepHasIssue executionStepHasIssueListExecutionStepHasIssue : vmUser.getExecutionStepHasIssueList()) { + executionStepHasIssueListExecutionStepHasIssue.getVmUserList().add(vmUser); + executionStepHasIssueListExecutionStepHasIssue = em.merge(executionStepHasIssueListExecutionStepHasIssue); + } + for (ExecutionStepHasVmUser executionStepHasVmUserListExecutionStepHasVmUser : vmUser.getExecutionStepHasVmUserList()) { + VmUser oldVmUserOfExecutionStepHasVmUserListExecutionStepHasVmUser = executionStepHasVmUserListExecutionStepHasVmUser.getVmUser(); + executionStepHasVmUserListExecutionStepHasVmUser.setVmUser(vmUser); + executionStepHasVmUserListExecutionStepHasVmUser = em.merge(executionStepHasVmUserListExecutionStepHasVmUser); + if (oldVmUserOfExecutionStepHasVmUserListExecutionStepHasVmUser != null) { + oldVmUserOfExecutionStepHasVmUserListExecutionStepHasVmUser.getExecutionStepHasVmUserList().remove(executionStepHasVmUserListExecutionStepHasVmUser); + oldVmUserOfExecutionStepHasVmUserListExecutionStepHasVmUser = em.merge(oldVmUserOfExecutionStepHasVmUserListExecutionStepHasVmUser); + } + } + for (History historyModificationListHistory : vmUser.getHistoryModificationList()) { + VmUser oldModifierIdOfHistoryModificationListHistory = historyModificationListHistory.getModifierId(); + historyModificationListHistory.setModifierId(vmUser); + historyModificationListHistory = em.merge(historyModificationListHistory); + if (oldModifierIdOfHistoryModificationListHistory != null) { + oldModifierIdOfHistoryModificationListHistory.getHistoryModificationList().remove(historyModificationListHistory); + oldModifierIdOfHistoryModificationListHistory = em.merge(oldModifierIdOfHistoryModificationListHistory); + } + } + for (Notification notificationListNotification : vmUser.getNotificationList()) { + VmUser oldTargetUserOfNotificationListNotification = notificationListNotification.getTargetUser(); + notificationListNotification.setTargetUser(vmUser); + notificationListNotification = em.merge(notificationListNotification); + if (oldTargetUserOfNotificationListNotification != null) { + oldTargetUserOfNotificationListNotification.getNotificationList().remove(notificationListNotification); + oldTargetUserOfNotificationListNotification = em.merge(oldTargetUserOfNotificationListNotification); + } + } + for (Notification notificationList1Notification : vmUser.getNotificationList1()) { + VmUser oldAuthorOfNotificationList1Notification = notificationList1Notification.getAuthor(); + notificationList1Notification.setAuthor(vmUser); + notificationList1Notification = em.merge(notificationList1Notification); + if (oldAuthorOfNotificationList1Notification != null) { + oldAuthorOfNotificationList1Notification.getNotificationList1().remove(notificationList1Notification); + oldAuthorOfNotificationList1Notification = em.merge(oldAuthorOfNotificationList1Notification); + } + } + for (History historyListHistory : vmUser.getHistoryList()) { + VmUser oldVmUserIdOfHistoryListHistory = historyListHistory.getVmUserId(); + historyListHistory.setVmUserId(vmUser); + historyListHistory = em.merge(historyListHistory); + if (oldVmUserIdOfHistoryListHistory != null) { + oldVmUserIdOfHistoryListHistory.getHistoryList().remove(historyListHistory); + oldVmUserIdOfHistoryListHistory = em.merge(oldVmUserIdOfHistoryListHistory); + } + } + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void edit(VmUser vmUser) throws IllegalOrphanException, NonexistentEntityException, Exception { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + VmUser persistentVmUser = em.find(VmUser.class, vmUser.getId()); + UserStatus userStatusIdOld = persistentVmUser.getUserStatusId(); + UserStatus userStatusIdNew = vmUser.getUserStatusId(); + List correctiveActionListOld = persistentVmUser.getCorrectiveActionList(); + List correctiveActionListNew = vmUser.getCorrectiveActionList(); + List roleListOld = persistentVmUser.getRoleList(); + List roleListNew = vmUser.getRoleList(); + List rootCauseListOld = persistentVmUser.getRootCauseList(); + List rootCauseListNew = vmUser.getRootCauseList(); + List executionStepListOld = persistentVmUser.getExecutionStepList(); + List executionStepListNew = vmUser.getExecutionStepList(); + List executionStepList1Old = persistentVmUser.getExecutionStepList1(); + List executionStepList1New = vmUser.getExecutionStepList1(); + List userTestProjectRoleListOld = persistentVmUser.getUserTestProjectRoleList(); + List userTestProjectRoleListNew = vmUser.getUserTestProjectRoleList(); + List userTestPlanRoleListOld = persistentVmUser.getUserTestPlanRoleList(); + List userTestPlanRoleListNew = vmUser.getUserTestPlanRoleList(); + List userModifiedRecordListOld = persistentVmUser.getUserModifiedRecordList(); + List userModifiedRecordListNew = vmUser.getUserModifiedRecordList(); + List userHasInvestigationListOld = persistentVmUser.getUserHasInvestigationList(); + List userHasInvestigationListNew = vmUser.getUserHasInvestigationList(); + List userAssigmentListOld = persistentVmUser.getUserAssigmentList(); + List userAssigmentListNew = vmUser.getUserAssigmentList(); + List userAssigmentList1Old = persistentVmUser.getUserAssigmentList1(); + List userAssigmentList1New = vmUser.getUserAssigmentList1(); + List executionStepHasIssueListOld = persistentVmUser.getExecutionStepHasIssueList(); + List executionStepHasIssueListNew = vmUser.getExecutionStepHasIssueList(); + List executionStepHasVmUserListOld = persistentVmUser.getExecutionStepHasVmUserList(); + List executionStepHasVmUserListNew = vmUser.getExecutionStepHasVmUserList(); + List historyModificationListOld = persistentVmUser.getHistoryModificationList(); + List historyModificationListNew = vmUser.getHistoryModificationList(); + List notificationListOld = persistentVmUser.getNotificationList(); + List notificationListNew = vmUser.getNotificationList(); + List notificationList1Old = persistentVmUser.getNotificationList1(); + List notificationList1New = vmUser.getNotificationList1(); + List historyListOld = persistentVmUser.getHistoryList(); + List historyListNew = vmUser.getHistoryList(); + List illegalOrphanMessages = null; + for (UserTestProjectRole userTestProjectRoleListOldUserTestProjectRole : userTestProjectRoleListOld) { + if (!userTestProjectRoleListNew.contains(userTestProjectRoleListOldUserTestProjectRole)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain UserTestProjectRole " + userTestProjectRoleListOldUserTestProjectRole + " since its vmUser field is not nullable."); + } + } + for (UserTestPlanRole userTestPlanRoleListOldUserTestPlanRole : userTestPlanRoleListOld) { + if (!userTestPlanRoleListNew.contains(userTestPlanRoleListOldUserTestPlanRole)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain UserTestPlanRole " + userTestPlanRoleListOldUserTestPlanRole + " since its vmUser field is not nullable."); + } + } + for (UserModifiedRecord userModifiedRecordListOldUserModifiedRecord : userModifiedRecordListOld) { + if (!userModifiedRecordListNew.contains(userModifiedRecordListOldUserModifiedRecord)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain UserModifiedRecord " + userModifiedRecordListOldUserModifiedRecord + " since its vmUser field is not nullable."); + } + } + for (UserHasInvestigation userHasInvestigationListOldUserHasInvestigation : userHasInvestigationListOld) { + if (!userHasInvestigationListNew.contains(userHasInvestigationListOldUserHasInvestigation)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain UserHasInvestigation " + userHasInvestigationListOldUserHasInvestigation + " since its vmUser field is not nullable."); + } + } + for (UserAssigment userAssigmentListOldUserAssigment : userAssigmentListOld) { + if (!userAssigmentListNew.contains(userAssigmentListOldUserAssigment)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain UserAssigment " + userAssigmentListOldUserAssigment + " since its vmUser field is not nullable."); + } + } + for (UserAssigment userAssigmentList1OldUserAssigment : userAssigmentList1Old) { + if (!userAssigmentList1New.contains(userAssigmentList1OldUserAssigment)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain UserAssigment " + userAssigmentList1OldUserAssigment + " since its assigneeId field is not nullable."); + } + } + for (ExecutionStepHasVmUser executionStepHasVmUserListOldExecutionStepHasVmUser : executionStepHasVmUserListOld) { + if (!executionStepHasVmUserListNew.contains(executionStepHasVmUserListOldExecutionStepHasVmUser)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain ExecutionStepHasVmUser " + executionStepHasVmUserListOldExecutionStepHasVmUser + " since its vmUser field is not nullable."); + } + } + for (History historyModificationListOldHistory : historyModificationListOld) { + if (!historyModificationListNew.contains(historyModificationListOldHistory)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain History " + historyModificationListOldHistory + " since its modifierId field is not nullable."); + } + } + for (Notification notificationListOldNotification : notificationListOld) { + if (!notificationListNew.contains(notificationListOldNotification)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain Notification " + notificationListOldNotification + " since its targetUser field is not nullable."); + } + } + for (Notification notificationList1OldNotification : notificationList1Old) { + if (!notificationList1New.contains(notificationList1OldNotification)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain Notification " + notificationList1OldNotification + " since its author field is not nullable."); + } + } + for (History historyListOldHistory : historyListOld) { + if (!historyListNew.contains(historyListOldHistory)) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("You must retain History " + historyListOldHistory + " since its vmUserId field is not nullable."); + } + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + if (userStatusIdNew != null) { + userStatusIdNew = em.getReference(userStatusIdNew.getClass(), userStatusIdNew.getId()); + vmUser.setUserStatusId(userStatusIdNew); + } + List attachedCorrectiveActionListNew = new ArrayList<>(); + for (CorrectiveAction correctiveActionListNewCorrectiveActionToAttach : correctiveActionListNew) { + correctiveActionListNewCorrectiveActionToAttach = em.getReference(correctiveActionListNewCorrectiveActionToAttach.getClass(), correctiveActionListNewCorrectiveActionToAttach.getId()); + attachedCorrectiveActionListNew.add(correctiveActionListNewCorrectiveActionToAttach); + } + correctiveActionListNew = attachedCorrectiveActionListNew; + vmUser.setCorrectiveActionList(correctiveActionListNew); + List attachedRoleListNew = new ArrayList<>(); + for (Role roleListNewRoleToAttach : roleListNew) { + roleListNewRoleToAttach = em.getReference(roleListNewRoleToAttach.getClass(), roleListNewRoleToAttach.getId()); + attachedRoleListNew.add(roleListNewRoleToAttach); + } + roleListNew = attachedRoleListNew; + vmUser.setRoleList(roleListNew); + List attachedRootCauseListNew = new ArrayList<>(); + for (RootCause rootCauseListNewRootCauseToAttach : rootCauseListNew) { + rootCauseListNewRootCauseToAttach = em.getReference(rootCauseListNewRootCauseToAttach.getClass(), rootCauseListNewRootCauseToAttach.getRootCausePK()); + attachedRootCauseListNew.add(rootCauseListNewRootCauseToAttach); + } + rootCauseListNew = attachedRootCauseListNew; + vmUser.setRootCauseList(rootCauseListNew); + List attachedExecutionStepListNew = new ArrayList<>(); + for (ExecutionStep executionStepListNewExecutionStepToAttach : executionStepListNew) { + executionStepListNewExecutionStepToAttach = em.getReference(executionStepListNewExecutionStepToAttach.getClass(), executionStepListNewExecutionStepToAttach.getExecutionStepPK()); + attachedExecutionStepListNew.add(executionStepListNewExecutionStepToAttach); + } + executionStepListNew = attachedExecutionStepListNew; + vmUser.setExecutionStepList(executionStepListNew); + List attachedExecutionStepList1New = new ArrayList<>(); + for (ExecutionStep executionStepList1NewExecutionStepToAttach : executionStepList1New) { + executionStepList1NewExecutionStepToAttach = em.getReference(executionStepList1NewExecutionStepToAttach.getClass(), executionStepList1NewExecutionStepToAttach.getExecutionStepPK()); + attachedExecutionStepList1New.add(executionStepList1NewExecutionStepToAttach); + } + executionStepList1New = attachedExecutionStepList1New; + vmUser.setExecutionStepList1(executionStepList1New); + List attachedUserTestProjectRoleListNew = new ArrayList<>(); + for (UserTestProjectRole userTestProjectRoleListNewUserTestProjectRoleToAttach : userTestProjectRoleListNew) { + userTestProjectRoleListNewUserTestProjectRoleToAttach = em.getReference(userTestProjectRoleListNewUserTestProjectRoleToAttach.getClass(), userTestProjectRoleListNewUserTestProjectRoleToAttach.getUserTestProjectRolePK()); + attachedUserTestProjectRoleListNew.add(userTestProjectRoleListNewUserTestProjectRoleToAttach); + } + userTestProjectRoleListNew = attachedUserTestProjectRoleListNew; + vmUser.setUserTestProjectRoleList(userTestProjectRoleListNew); + List attachedUserTestPlanRoleListNew = new ArrayList<>(); + for (UserTestPlanRole userTestPlanRoleListNewUserTestPlanRoleToAttach : userTestPlanRoleListNew) { + userTestPlanRoleListNewUserTestPlanRoleToAttach = em.getReference(userTestPlanRoleListNewUserTestPlanRoleToAttach.getClass(), userTestPlanRoleListNewUserTestPlanRoleToAttach.getUserTestPlanRolePK()); + attachedUserTestPlanRoleListNew.add(userTestPlanRoleListNewUserTestPlanRoleToAttach); + } + userTestPlanRoleListNew = attachedUserTestPlanRoleListNew; + vmUser.setUserTestPlanRoleList(userTestPlanRoleListNew); + List attachedUserModifiedRecordListNew = new ArrayList<>(); + for (UserModifiedRecord userModifiedRecordListNewUserModifiedRecordToAttach : userModifiedRecordListNew) { + userModifiedRecordListNewUserModifiedRecordToAttach = em.getReference(userModifiedRecordListNewUserModifiedRecordToAttach.getClass(), userModifiedRecordListNewUserModifiedRecordToAttach.getUserModifiedRecordPK()); + attachedUserModifiedRecordListNew.add(userModifiedRecordListNewUserModifiedRecordToAttach); + } + userModifiedRecordListNew = attachedUserModifiedRecordListNew; + vmUser.setUserModifiedRecordList(userModifiedRecordListNew); + List attachedUserHasInvestigationListNew = new ArrayList<>(); + for (UserHasInvestigation userHasInvestigationListNewUserHasInvestigationToAttach : userHasInvestigationListNew) { + userHasInvestigationListNewUserHasInvestigationToAttach = em.getReference(userHasInvestigationListNewUserHasInvestigationToAttach.getClass(), userHasInvestigationListNewUserHasInvestigationToAttach.getUserHasInvestigationPK()); + attachedUserHasInvestigationListNew.add(userHasInvestigationListNewUserHasInvestigationToAttach); + } + userHasInvestigationListNew = attachedUserHasInvestigationListNew; + vmUser.setUserHasInvestigationList(userHasInvestigationListNew); + List attachedUserAssigmentListNew = new ArrayList<>(); + for (UserAssigment userAssigmentListNewUserAssigmentToAttach : userAssigmentListNew) { + userAssigmentListNewUserAssigmentToAttach = em.getReference(userAssigmentListNewUserAssigmentToAttach.getClass(), userAssigmentListNewUserAssigmentToAttach.getUserAssigmentPK()); + attachedUserAssigmentListNew.add(userAssigmentListNewUserAssigmentToAttach); + } + userAssigmentListNew = attachedUserAssigmentListNew; + vmUser.setUserAssigmentList(userAssigmentListNew); + List attachedUserAssigmentList1New = new ArrayList<>(); + for (UserAssigment userAssigmentList1NewUserAssigmentToAttach : userAssigmentList1New) { + userAssigmentList1NewUserAssigmentToAttach = em.getReference(userAssigmentList1NewUserAssigmentToAttach.getClass(), userAssigmentList1NewUserAssigmentToAttach.getUserAssigmentPK()); + attachedUserAssigmentList1New.add(userAssigmentList1NewUserAssigmentToAttach); + } + userAssigmentList1New = attachedUserAssigmentList1New; + vmUser.setUserAssigmentList1(userAssigmentList1New); + List attachedExecutionStepHasIssueListNew = new ArrayList<>(); + for (ExecutionStepHasIssue executionStepHasIssueListNewExecutionStepHasIssueToAttach : executionStepHasIssueListNew) { + executionStepHasIssueListNewExecutionStepHasIssueToAttach = em.getReference(executionStepHasIssueListNewExecutionStepHasIssueToAttach.getClass(), executionStepHasIssueListNewExecutionStepHasIssueToAttach.getExecutionStepHasIssuePK()); + attachedExecutionStepHasIssueListNew.add(executionStepHasIssueListNewExecutionStepHasIssueToAttach); + } + executionStepHasIssueListNew = attachedExecutionStepHasIssueListNew; + vmUser.setExecutionStepHasIssueList(executionStepHasIssueListNew); + List attachedExecutionStepHasVmUserListNew = new ArrayList<>(); + for (ExecutionStepHasVmUser executionStepHasVmUserListNewExecutionStepHasVmUserToAttach : executionStepHasVmUserListNew) { + executionStepHasVmUserListNewExecutionStepHasVmUserToAttach = em.getReference(executionStepHasVmUserListNewExecutionStepHasVmUserToAttach.getClass(), executionStepHasVmUserListNewExecutionStepHasVmUserToAttach.getExecutionStepHasVmUserPK()); + attachedExecutionStepHasVmUserListNew.add(executionStepHasVmUserListNewExecutionStepHasVmUserToAttach); + } + executionStepHasVmUserListNew = attachedExecutionStepHasVmUserListNew; + vmUser.setExecutionStepHasVmUserList(executionStepHasVmUserListNew); + List attachedHistoryModificationListNew = new ArrayList<>(); + for (History historyModificationListNewHistoryToAttach : historyModificationListNew) { + historyModificationListNewHistoryToAttach = em.getReference(historyModificationListNewHistoryToAttach.getClass(), historyModificationListNewHistoryToAttach.getId()); + attachedHistoryModificationListNew.add(historyModificationListNewHistoryToAttach); + } + historyModificationListNew = attachedHistoryModificationListNew; + vmUser.setHistoryModificationList(historyModificationListNew); + List attachedNotificationListNew = new ArrayList<>(); + for (Notification notificationListNewNotificationToAttach : notificationListNew) { + notificationListNewNotificationToAttach = em.getReference(notificationListNewNotificationToAttach.getClass(), notificationListNewNotificationToAttach.getNotificationPK()); + attachedNotificationListNew.add(notificationListNewNotificationToAttach); + } + notificationListNew = attachedNotificationListNew; + vmUser.setNotificationList(notificationListNew); + List attachedNotificationList1New = new ArrayList<>(); + for (Notification notificationList1NewNotificationToAttach : notificationList1New) { + notificationList1NewNotificationToAttach = em.getReference(notificationList1NewNotificationToAttach.getClass(), notificationList1NewNotificationToAttach.getNotificationPK()); + attachedNotificationList1New.add(notificationList1NewNotificationToAttach); + } + notificationList1New = attachedNotificationList1New; + vmUser.setNotificationList1(notificationList1New); + List attachedHistoryListNew = new ArrayList<>(); + for (History historyListNewHistoryToAttach : historyListNew) { + historyListNewHistoryToAttach = em.getReference(historyListNewHistoryToAttach.getClass(), historyListNewHistoryToAttach.getId()); + attachedHistoryListNew.add(historyListNewHistoryToAttach); + } + historyListNew = attachedHistoryListNew; + vmUser.setHistoryList(historyListNew); + vmUser = em.merge(vmUser); + if (userStatusIdOld != null && !userStatusIdOld.equals(userStatusIdNew)) { + userStatusIdOld.getVmUserList().remove(vmUser); + userStatusIdOld = em.merge(userStatusIdOld); + } + if (userStatusIdNew != null && !userStatusIdNew.equals(userStatusIdOld)) { + userStatusIdNew.getVmUserList().add(vmUser); + userStatusIdNew = em.merge(userStatusIdNew); + } + for (CorrectiveAction correctiveActionListOldCorrectiveAction : correctiveActionListOld) { + if (!correctiveActionListNew.contains(correctiveActionListOldCorrectiveAction)) { + correctiveActionListOldCorrectiveAction.getVmUserList().remove(vmUser); + correctiveActionListOldCorrectiveAction = em.merge(correctiveActionListOldCorrectiveAction); + } + } + for (CorrectiveAction correctiveActionListNewCorrectiveAction : correctiveActionListNew) { + if (!correctiveActionListOld.contains(correctiveActionListNewCorrectiveAction)) { + correctiveActionListNewCorrectiveAction.getVmUserList().add(vmUser); + correctiveActionListNewCorrectiveAction = em.merge(correctiveActionListNewCorrectiveAction); + } + } + for (Role roleListOldRole : roleListOld) { + if (!roleListNew.contains(roleListOldRole)) { + roleListOldRole.getVmUserList().remove(vmUser); + roleListOldRole = em.merge(roleListOldRole); + } + } + for (Role roleListNewRole : roleListNew) { + if (!roleListOld.contains(roleListNewRole)) { + roleListNewRole.getVmUserList().add(vmUser); + roleListNewRole = em.merge(roleListNewRole); + } + } + for (RootCause rootCauseListOldRootCause : rootCauseListOld) { + if (!rootCauseListNew.contains(rootCauseListOldRootCause)) { + rootCauseListOldRootCause.getVmUserList().remove(vmUser); + rootCauseListOldRootCause = em.merge(rootCauseListOldRootCause); + } + } + for (RootCause rootCauseListNewRootCause : rootCauseListNew) { + if (!rootCauseListOld.contains(rootCauseListNewRootCause)) { + rootCauseListNewRootCause.getVmUserList().add(vmUser); + rootCauseListNewRootCause = em.merge(rootCauseListNewRootCause); + } + } + for (ExecutionStep executionStepListOldExecutionStep : executionStepListOld) { + if (!executionStepListNew.contains(executionStepListOldExecutionStep)) { + executionStepListOldExecutionStep.setAssignee(null); + executionStepListOldExecutionStep = em.merge(executionStepListOldExecutionStep); + } + } + for (ExecutionStep executionStepListNewExecutionStep : executionStepListNew) { + if (!executionStepListOld.contains(executionStepListNewExecutionStep)) { + VmUser oldAssigneeOfExecutionStepListNewExecutionStep = executionStepListNewExecutionStep.getAssignee(); + executionStepListNewExecutionStep.setAssignee(vmUser); + executionStepListNewExecutionStep = em.merge(executionStepListNewExecutionStep); + if (oldAssigneeOfExecutionStepListNewExecutionStep != null && !oldAssigneeOfExecutionStepListNewExecutionStep.equals(vmUser)) { + oldAssigneeOfExecutionStepListNewExecutionStep.getExecutionStepList().remove(executionStepListNewExecutionStep); + oldAssigneeOfExecutionStepListNewExecutionStep = em.merge(oldAssigneeOfExecutionStepListNewExecutionStep); + } + } + } + for (ExecutionStep executionStepList1OldExecutionStep : executionStepList1Old) { + if (!executionStepList1New.contains(executionStepList1OldExecutionStep)) { + executionStepList1OldExecutionStep.setAssigner(null); + executionStepList1OldExecutionStep = em.merge(executionStepList1OldExecutionStep); + } + } + for (ExecutionStep executionStepList1NewExecutionStep : executionStepList1New) { + if (!executionStepList1Old.contains(executionStepList1NewExecutionStep)) { + VmUser oldAssignerOfExecutionStepList1NewExecutionStep = executionStepList1NewExecutionStep.getAssigner(); + executionStepList1NewExecutionStep.setAssigner(vmUser); + executionStepList1NewExecutionStep = em.merge(executionStepList1NewExecutionStep); + if (oldAssignerOfExecutionStepList1NewExecutionStep != null && !oldAssignerOfExecutionStepList1NewExecutionStep.equals(vmUser)) { + oldAssignerOfExecutionStepList1NewExecutionStep.getExecutionStepList1().remove(executionStepList1NewExecutionStep); + oldAssignerOfExecutionStepList1NewExecutionStep = em.merge(oldAssignerOfExecutionStepList1NewExecutionStep); + } + } + } + for (UserTestProjectRole userTestProjectRoleListNewUserTestProjectRole : userTestProjectRoleListNew) { + if (!userTestProjectRoleListOld.contains(userTestProjectRoleListNewUserTestProjectRole)) { + VmUser oldVmUserOfUserTestProjectRoleListNewUserTestProjectRole = userTestProjectRoleListNewUserTestProjectRole.getVmUser(); + userTestProjectRoleListNewUserTestProjectRole.setVmUser(vmUser); + userTestProjectRoleListNewUserTestProjectRole = em.merge(userTestProjectRoleListNewUserTestProjectRole); + if (oldVmUserOfUserTestProjectRoleListNewUserTestProjectRole != null && !oldVmUserOfUserTestProjectRoleListNewUserTestProjectRole.equals(vmUser)) { + oldVmUserOfUserTestProjectRoleListNewUserTestProjectRole.getUserTestProjectRoleList().remove(userTestProjectRoleListNewUserTestProjectRole); + oldVmUserOfUserTestProjectRoleListNewUserTestProjectRole = em.merge(oldVmUserOfUserTestProjectRoleListNewUserTestProjectRole); + } + } + } + for (UserTestPlanRole userTestPlanRoleListNewUserTestPlanRole : userTestPlanRoleListNew) { + if (!userTestPlanRoleListOld.contains(userTestPlanRoleListNewUserTestPlanRole)) { + VmUser oldVmUserOfUserTestPlanRoleListNewUserTestPlanRole = userTestPlanRoleListNewUserTestPlanRole.getVmUser(); + userTestPlanRoleListNewUserTestPlanRole.setVmUser(vmUser); + userTestPlanRoleListNewUserTestPlanRole = em.merge(userTestPlanRoleListNewUserTestPlanRole); + if (oldVmUserOfUserTestPlanRoleListNewUserTestPlanRole != null && !oldVmUserOfUserTestPlanRoleListNewUserTestPlanRole.equals(vmUser)) { + oldVmUserOfUserTestPlanRoleListNewUserTestPlanRole.getUserTestPlanRoleList().remove(userTestPlanRoleListNewUserTestPlanRole); + oldVmUserOfUserTestPlanRoleListNewUserTestPlanRole = em.merge(oldVmUserOfUserTestPlanRoleListNewUserTestPlanRole); + } + } + } + for (UserModifiedRecord userModifiedRecordListNewUserModifiedRecord : userModifiedRecordListNew) { + if (!userModifiedRecordListOld.contains(userModifiedRecordListNewUserModifiedRecord)) { + VmUser oldVmUserOfUserModifiedRecordListNewUserModifiedRecord = userModifiedRecordListNewUserModifiedRecord.getVmUser(); + userModifiedRecordListNewUserModifiedRecord.setVmUser(vmUser); + userModifiedRecordListNewUserModifiedRecord = em.merge(userModifiedRecordListNewUserModifiedRecord); + if (oldVmUserOfUserModifiedRecordListNewUserModifiedRecord != null && !oldVmUserOfUserModifiedRecordListNewUserModifiedRecord.equals(vmUser)) { + oldVmUserOfUserModifiedRecordListNewUserModifiedRecord.getUserModifiedRecordList().remove(userModifiedRecordListNewUserModifiedRecord); + oldVmUserOfUserModifiedRecordListNewUserModifiedRecord = em.merge(oldVmUserOfUserModifiedRecordListNewUserModifiedRecord); + } + } + } + for (UserHasInvestigation userHasInvestigationListNewUserHasInvestigation : userHasInvestigationListNew) { + if (!userHasInvestigationListOld.contains(userHasInvestigationListNewUserHasInvestigation)) { + VmUser oldVmUserOfUserHasInvestigationListNewUserHasInvestigation = userHasInvestigationListNewUserHasInvestigation.getVmUser(); + userHasInvestigationListNewUserHasInvestigation.setVmUser(vmUser); + userHasInvestigationListNewUserHasInvestigation = em.merge(userHasInvestigationListNewUserHasInvestigation); + if (oldVmUserOfUserHasInvestigationListNewUserHasInvestigation != null && !oldVmUserOfUserHasInvestigationListNewUserHasInvestigation.equals(vmUser)) { + oldVmUserOfUserHasInvestigationListNewUserHasInvestigation.getUserHasInvestigationList().remove(userHasInvestigationListNewUserHasInvestigation); + oldVmUserOfUserHasInvestigationListNewUserHasInvestigation = em.merge(oldVmUserOfUserHasInvestigationListNewUserHasInvestigation); + } + } + } + for (UserAssigment userAssigmentListNewUserAssigment : userAssigmentListNew) { + if (!userAssigmentListOld.contains(userAssigmentListNewUserAssigment)) { + VmUser oldVmUserOfUserAssigmentListNewUserAssigment = userAssigmentListNewUserAssigment.getVmUser(); + userAssigmentListNewUserAssigment.setVmUser(vmUser); + userAssigmentListNewUserAssigment = em.merge(userAssigmentListNewUserAssigment); + if (oldVmUserOfUserAssigmentListNewUserAssigment != null && !oldVmUserOfUserAssigmentListNewUserAssigment.equals(vmUser)) { + oldVmUserOfUserAssigmentListNewUserAssigment.getUserAssigmentList().remove(userAssigmentListNewUserAssigment); + oldVmUserOfUserAssigmentListNewUserAssigment = em.merge(oldVmUserOfUserAssigmentListNewUserAssigment); + } + } + } + for (UserAssigment userAssigmentList1NewUserAssigment : userAssigmentList1New) { + if (!userAssigmentList1Old.contains(userAssigmentList1NewUserAssigment)) { + VmUser oldAssigneeIdOfUserAssigmentList1NewUserAssigment = userAssigmentList1NewUserAssigment.getAssigneeId(); + userAssigmentList1NewUserAssigment.setAssigneeId(vmUser); + userAssigmentList1NewUserAssigment = em.merge(userAssigmentList1NewUserAssigment); + if (oldAssigneeIdOfUserAssigmentList1NewUserAssigment != null && !oldAssigneeIdOfUserAssigmentList1NewUserAssigment.equals(vmUser)) { + oldAssigneeIdOfUserAssigmentList1NewUserAssigment.getUserAssigmentList1().remove(userAssigmentList1NewUserAssigment); + oldAssigneeIdOfUserAssigmentList1NewUserAssigment = em.merge(oldAssigneeIdOfUserAssigmentList1NewUserAssigment); + } + } + } + for (ExecutionStepHasIssue executionStepHasIssueListOldExecutionStepHasIssue : executionStepHasIssueListOld) { + if (!executionStepHasIssueListNew.contains(executionStepHasIssueListOldExecutionStepHasIssue)) { + executionStepHasIssueListOldExecutionStepHasIssue.getVmUserList().remove(vmUser); + executionStepHasIssueListOldExecutionStepHasIssue = em.merge(executionStepHasIssueListOldExecutionStepHasIssue); + } + } + for (ExecutionStepHasIssue executionStepHasIssueListNewExecutionStepHasIssue : executionStepHasIssueListNew) { + if (!executionStepHasIssueListOld.contains(executionStepHasIssueListNewExecutionStepHasIssue)) { + executionStepHasIssueListNewExecutionStepHasIssue.getVmUserList().add(vmUser); + executionStepHasIssueListNewExecutionStepHasIssue = em.merge(executionStepHasIssueListNewExecutionStepHasIssue); + } + } + for (ExecutionStepHasVmUser executionStepHasVmUserListNewExecutionStepHasVmUser : executionStepHasVmUserListNew) { + if (!executionStepHasVmUserListOld.contains(executionStepHasVmUserListNewExecutionStepHasVmUser)) { + VmUser oldVmUserOfExecutionStepHasVmUserListNewExecutionStepHasVmUser = executionStepHasVmUserListNewExecutionStepHasVmUser.getVmUser(); + executionStepHasVmUserListNewExecutionStepHasVmUser.setVmUser(vmUser); + executionStepHasVmUserListNewExecutionStepHasVmUser = em.merge(executionStepHasVmUserListNewExecutionStepHasVmUser); + if (oldVmUserOfExecutionStepHasVmUserListNewExecutionStepHasVmUser != null && !oldVmUserOfExecutionStepHasVmUserListNewExecutionStepHasVmUser.equals(vmUser)) { + oldVmUserOfExecutionStepHasVmUserListNewExecutionStepHasVmUser.getExecutionStepHasVmUserList().remove(executionStepHasVmUserListNewExecutionStepHasVmUser); + oldVmUserOfExecutionStepHasVmUserListNewExecutionStepHasVmUser = em.merge(oldVmUserOfExecutionStepHasVmUserListNewExecutionStepHasVmUser); + } + } + } + for (History historyModificationListNewHistory : historyModificationListNew) { + if (!historyModificationListOld.contains(historyModificationListNewHistory)) { + VmUser oldModifierIdOfHistoryModificationListNewHistory = historyModificationListNewHistory.getModifierId(); + historyModificationListNewHistory.setModifierId(vmUser); + historyModificationListNewHistory = em.merge(historyModificationListNewHistory); + if (oldModifierIdOfHistoryModificationListNewHistory != null && !oldModifierIdOfHistoryModificationListNewHistory.equals(vmUser)) { + oldModifierIdOfHistoryModificationListNewHistory.getHistoryModificationList().remove(historyModificationListNewHistory); + oldModifierIdOfHistoryModificationListNewHistory = em.merge(oldModifierIdOfHistoryModificationListNewHistory); + } + } + } + for (Notification notificationListNewNotification : notificationListNew) { + if (!notificationListOld.contains(notificationListNewNotification)) { + VmUser oldTargetUserOfNotificationListNewNotification = notificationListNewNotification.getTargetUser(); + notificationListNewNotification.setTargetUser(vmUser); + notificationListNewNotification = em.merge(notificationListNewNotification); + if (oldTargetUserOfNotificationListNewNotification != null && !oldTargetUserOfNotificationListNewNotification.equals(vmUser)) { + oldTargetUserOfNotificationListNewNotification.getNotificationList().remove(notificationListNewNotification); + oldTargetUserOfNotificationListNewNotification = em.merge(oldTargetUserOfNotificationListNewNotification); + } + } + } + for (Notification notificationList1NewNotification : notificationList1New) { + if (!notificationList1Old.contains(notificationList1NewNotification)) { + VmUser oldAuthorOfNotificationList1NewNotification = notificationList1NewNotification.getAuthor(); + notificationList1NewNotification.setAuthor(vmUser); + notificationList1NewNotification = em.merge(notificationList1NewNotification); + if (oldAuthorOfNotificationList1NewNotification != null && !oldAuthorOfNotificationList1NewNotification.equals(vmUser)) { + oldAuthorOfNotificationList1NewNotification.getNotificationList1().remove(notificationList1NewNotification); + oldAuthorOfNotificationList1NewNotification = em.merge(oldAuthorOfNotificationList1NewNotification); + } + } + } + for (History historyListNewHistory : historyListNew) { + if (!historyListOld.contains(historyListNewHistory)) { + VmUser oldVmUserIdOfHistoryListNewHistory = historyListNewHistory.getVmUserId(); + historyListNewHistory.setVmUserId(vmUser); + historyListNewHistory = em.merge(historyListNewHistory); + if (oldVmUserIdOfHistoryListNewHistory != null && !oldVmUserIdOfHistoryListNewHistory.equals(vmUser)) { + oldVmUserIdOfHistoryListNewHistory.getHistoryList().remove(historyListNewHistory); + oldVmUserIdOfHistoryListNewHistory = em.merge(oldVmUserIdOfHistoryListNewHistory); + } + } + } + em.getTransaction().commit(); + } + catch (Exception ex) { + String msg = ex.getLocalizedMessage(); + if (msg == null || msg.length() == 0) { + Integer id = vmUser.getId(); + if (findVmUser(id) == null) { + throw new NonexistentEntityException("The vmUser with id " + id + " no longer exists."); + } + } + throw ex; + } + finally { + if (em != null) { + em.close(); + } + } + } + + public void destroy(Integer id) throws IllegalOrphanException, NonexistentEntityException { + EntityManager em = null; + try { + em = getEntityManager(); + em.getTransaction().begin(); + VmUser vmUser; + try { + vmUser = em.getReference(VmUser.class, id); + vmUser.getId(); + } + catch (EntityNotFoundException enfe) { + throw new NonexistentEntityException("The vmUser with id " + id + " no longer exists.", enfe); + } + List illegalOrphanMessages = null; + List userTestProjectRoleListOrphanCheck = vmUser.getUserTestProjectRoleList(); + for (UserTestProjectRole userTestProjectRoleListOrphanCheckUserTestProjectRole : userTestProjectRoleListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This VmUser (" + vmUser + ") cannot be destroyed since the UserTestProjectRole " + userTestProjectRoleListOrphanCheckUserTestProjectRole + " in its userTestProjectRoleList field has a non-nullable vmUser field."); + } + List userTestPlanRoleListOrphanCheck = vmUser.getUserTestPlanRoleList(); + for (UserTestPlanRole userTestPlanRoleListOrphanCheckUserTestPlanRole : userTestPlanRoleListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This VmUser (" + vmUser + ") cannot be destroyed since the UserTestPlanRole " + userTestPlanRoleListOrphanCheckUserTestPlanRole + " in its userTestPlanRoleList field has a non-nullable vmUser field."); + } + List userModifiedRecordListOrphanCheck = vmUser.getUserModifiedRecordList(); + for (UserModifiedRecord userModifiedRecordListOrphanCheckUserModifiedRecord : userModifiedRecordListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This VmUser (" + vmUser + ") cannot be destroyed since the UserModifiedRecord " + userModifiedRecordListOrphanCheckUserModifiedRecord + " in its userModifiedRecordList field has a non-nullable vmUser field."); + } + List userHasInvestigationListOrphanCheck = vmUser.getUserHasInvestigationList(); + for (UserHasInvestigation userHasInvestigationListOrphanCheckUserHasInvestigation : userHasInvestigationListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This VmUser (" + vmUser + ") cannot be destroyed since the UserHasInvestigation " + userHasInvestigationListOrphanCheckUserHasInvestigation + " in its userHasInvestigationList field has a non-nullable vmUser field."); + } + List userAssigmentListOrphanCheck = vmUser.getUserAssigmentList(); + for (UserAssigment userAssigmentListOrphanCheckUserAssigment : userAssigmentListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This VmUser (" + vmUser + ") cannot be destroyed since the UserAssigment " + userAssigmentListOrphanCheckUserAssigment + " in its userAssigmentList field has a non-nullable vmUser field."); + } + List userAssigmentList1OrphanCheck = vmUser.getUserAssigmentList1(); + for (UserAssigment userAssigmentList1OrphanCheckUserAssigment : userAssigmentList1OrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This VmUser (" + vmUser + ") cannot be destroyed since the UserAssigment " + userAssigmentList1OrphanCheckUserAssigment + " in its userAssigmentList1 field has a non-nullable assigneeId field."); + } + List executionStepHasVmUserListOrphanCheck = vmUser.getExecutionStepHasVmUserList(); + for (ExecutionStepHasVmUser executionStepHasVmUserListOrphanCheckExecutionStepHasVmUser : executionStepHasVmUserListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This VmUser (" + vmUser + ") cannot be destroyed since the ExecutionStepHasVmUser " + executionStepHasVmUserListOrphanCheckExecutionStepHasVmUser + " in its executionStepHasVmUserList field has a non-nullable vmUser field."); + } + List historyModificationListOrphanCheck = vmUser.getHistoryModificationList(); + for (History historyModificationListOrphanCheckHistory : historyModificationListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This VmUser (" + vmUser + ") cannot be destroyed since the History " + historyModificationListOrphanCheckHistory + " in its historyModificationList field has a non-nullable modifierId field."); + } + List notificationListOrphanCheck = vmUser.getNotificationList(); + for (Notification notificationListOrphanCheckNotification : notificationListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This VmUser (" + vmUser + ") cannot be destroyed since the Notification " + notificationListOrphanCheckNotification + " in its notificationList field has a non-nullable targetUser field."); + } + List notificationList1OrphanCheck = vmUser.getNotificationList1(); + for (Notification notificationList1OrphanCheckNotification : notificationList1OrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This VmUser (" + vmUser + ") cannot be destroyed since the Notification " + notificationList1OrphanCheckNotification + " in its notificationList1 field has a non-nullable author field."); + } + List historyListOrphanCheck = vmUser.getHistoryList(); + for (History historyListOrphanCheckHistory : historyListOrphanCheck) { + if (illegalOrphanMessages == null) { + illegalOrphanMessages = new ArrayList<>(); + } + illegalOrphanMessages.add("This VmUser (" + vmUser + ") cannot be destroyed since the History " + historyListOrphanCheckHistory + " in its historyList field has a non-nullable vmUserId field."); + } + if (illegalOrphanMessages != null) { + throw new IllegalOrphanException(illegalOrphanMessages); + } + UserStatus userStatusId = vmUser.getUserStatusId(); + if (userStatusId != null) { + userStatusId.getVmUserList().remove(vmUser); + userStatusId = em.merge(userStatusId); + } + List correctiveActionList = vmUser.getCorrectiveActionList(); + for (CorrectiveAction correctiveActionListCorrectiveAction : correctiveActionList) { + correctiveActionListCorrectiveAction.getVmUserList().remove(vmUser); + correctiveActionListCorrectiveAction = em.merge(correctiveActionListCorrectiveAction); + } + List roleList = vmUser.getRoleList(); + for (Role roleListRole : roleList) { + roleListRole.getVmUserList().remove(vmUser); + roleListRole = em.merge(roleListRole); + } + List rootCauseList = vmUser.getRootCauseList(); + for (RootCause rootCauseListRootCause : rootCauseList) { + rootCauseListRootCause.getVmUserList().remove(vmUser); + rootCauseListRootCause = em.merge(rootCauseListRootCause); + } + List executionStepList = vmUser.getExecutionStepList(); + for (ExecutionStep executionStepListExecutionStep : executionStepList) { + executionStepListExecutionStep.setAssignee(null); + executionStepListExecutionStep = em.merge(executionStepListExecutionStep); + } + List executionStepList1 = vmUser.getExecutionStepList1(); + for (ExecutionStep executionStepList1ExecutionStep : executionStepList1) { + executionStepList1ExecutionStep.setAssigner(null); + executionStepList1ExecutionStep = em.merge(executionStepList1ExecutionStep); + } + List executionStepHasIssueList = vmUser.getExecutionStepHasIssueList(); + for (ExecutionStepHasIssue executionStepHasIssueListExecutionStepHasIssue : executionStepHasIssueList) { + executionStepHasIssueListExecutionStepHasIssue.getVmUserList().remove(vmUser); + executionStepHasIssueListExecutionStepHasIssue = em.merge(executionStepHasIssueListExecutionStepHasIssue); + } + em.remove(vmUser); + em.getTransaction().commit(); + } + finally { + if (em != null) { + em.close(); + } + } + } + + public List findVmUserEntities() { + return findVmUserEntities(true, -1, -1); + } + + public List findVmUserEntities(int maxResults, int firstResult) { + return findVmUserEntities(false, maxResults, firstResult); + } + + private List findVmUserEntities(boolean all, int maxResults, int firstResult) { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + cq.select(cq.from(VmUser.class)); + Query q = em.createQuery(cq); + if (!all) { + q.setMaxResults(maxResults); + q.setFirstResult(firstResult); + } + return q.getResultList(); + } + finally { + em.close(); + } + } + + public VmUser findVmUser(Integer id) { + EntityManager em = getEntityManager(); + try { + return em.find(VmUser.class, id); + } + finally { + em.close(); + } + } + + public int getVmUserCount() { + EntityManager em = getEntityManager(); + try { + CriteriaQuery cq = em.getCriteriaBuilder().createQuery(); + Root rt = cq.from(VmUser.class); + cq.select(em.getCriteriaBuilder().count(rt)); + Query q = em.createQuery(cq); + return ((Long) q.getSingleResult()).intValue(); + } + finally { + em.close(); + } + } + +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/history/Login.java b/VM-Core/src/main/java/com/validation/manager/core/history/Login.java deleted file mode 100644 index 864747e9..00000000 --- a/VM-Core/src/main/java/com/validation/manager/core/history/Login.java +++ /dev/null @@ -1,57 +0,0 @@ -/* - * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.validation.manager.core.history; - -import java.io.Serializable; -import java.util.Date; -import javax.persistence.Basic; -import javax.persistence.Column; -import javax.persistence.MappedSuperclass; -import javax.persistence.Temporal; -import javax.persistence.TemporalType; -import javax.validation.constraints.Min; -import javax.validation.constraints.NotNull; - -@MappedSuperclass -public abstract class Login implements Serializable { - - @Column(name = "attempts") - @Basic(optional = false) - @NotNull - @Min(value = 0) - private int attempts; - - @Column(name = "last_login") - @Basic(optional = false) - @Temporal(TemporalType.TIMESTAMP) - private Date lastModified; - - public int getAttempts() { - return this.attempts; - } - - public void setAttempts(int attempts) { - this.attempts = attempts; - } - - public Date getLastModified() { - return this.lastModified; - } - - public void setLastModified(Date lastModified) { - this.lastModified = lastModified; - } -} diff --git a/VM-Core/src/main/java/com/validation/manager/core/history/Versionable.java b/VM-Core/src/main/java/com/validation/manager/core/history/Versionable.java index 102189cc..20880cc5 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/history/Versionable.java +++ b/VM-Core/src/main/java/com/validation/manager/core/history/Versionable.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,374 +13,418 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.history; - -import com.validation.manager.core.EntityServer; -import com.validation.manager.core.db.FieldType; -import com.validation.manager.core.db.History; -import com.validation.manager.core.db.HistoryField; -import com.validation.manager.core.server.core.FieldTypeServer; -import com.validation.manager.core.server.core.HistoryFieldServer; -import com.validation.manager.core.server.core.HistoryServer; -import com.validation.manager.core.server.core.VMUserServer; -import java.io.Serializable; -import java.lang.reflect.Field; -import java.nio.charset.StandardCharsets; -import java.util.ArrayList; -import java.util.Date; -import java.util.List; -import java.util.Objects; -import java.util.logging.Level; -import java.util.logging.Logger; -import javax.persistence.Basic; -import javax.persistence.Column; -import javax.persistence.DiscriminatorColumn; -import javax.persistence.Inheritance; -import javax.persistence.InheritanceType; -import javax.persistence.MappedSuperclass; -import javax.persistence.Temporal; -import javax.persistence.TemporalType; -import org.apache.commons.lang3.reflect.FieldUtils; -import org.openide.util.Exceptions; - -@MappedSuperclass -@Inheritance(strategy = InheritanceType.JOINED) -@DiscriminatorColumn(name = "VERSIONABLE_TYPE") -public abstract class Versionable implements Comparable, - Serializable { - - private static final Logger LOG - = Logger.getLogger(Versionable.class.getSimpleName()); - - @Column(name = "majorVersion", insertable = false, updatable = false) - private Integer majorVersion = 0; - @Column(name = "midVersion", insertable = false, updatable = false) - private Integer midVersion = 0; - @Column(name = "minorVersion", insertable = false, updatable = false) - private Integer minorVersion = 1; - @Column(name = "reason", insertable = false, updatable = false) - private String reason; - @Column(name = "modifierId", insertable = false, updatable = false) - private int modifierId = -1; - @Column(name = "modificationTime", insertable = false, updatable = false) - @Temporal(TemporalType.TIMESTAMP) - private Date modificationTime; - @Column(name = "dirty") - @Basic(optional = false) - private boolean dirty = false; - - public int getModifierId() { - return modifierId; - } - - public void setModifierId(int modifierId) { - this.modifierId = modifierId; - } - - public Integer getMajorVersion() { - return this.majorVersion; - } - - public void setMajorVersion(Integer majorVersion) { - this.majorVersion = majorVersion; - } - - public Integer getMidVersion() { - return this.midVersion; - } - - public void setMidVersion(Integer midVersion) { - this.midVersion = midVersion; - } - - public Integer getMinorVersion() { - return this.minorVersion; - } - - public void setMinorVersion(Integer minorVersion) { - this.minorVersion = minorVersion; - } - - public String getReason() { - return this.reason; - } - - public void setReason(String reason) { - this.reason = reason; - } - - public Date getModificationTime() { - return this.modificationTime; - } - - public void setModificationTime(Date modificationTime) { - this.modificationTime = modificationTime; - } - - public boolean getDirty() { - return this.dirty; - } - - /** - * @param dirty the dirty to set - */ - public void setDirty(boolean dirty) { - this.dirty = dirty; - } - - /** - * Increase major version. - */ - public void increaseMajorVersion() { - setMajorVersion(getMajorVersion() + 1); - setMidVersion(0); - setMinorVersion(0); - try { - if (this instanceof EntityServer) { - EntityServer vs = (EntityServer) this; - //Copy the version changes - Versionable ao = (Versionable) vs.getEntity(); - ao.update(ao, this); - updateHistory(ao); - vs.write2DB(); - } else { - updateHistory(this); - } - } - catch (Exception ex) { - Exceptions.printStackTrace(ex); - } - } - - /** - * Increase major version. - */ - public void increaseMidVersion() { - setMidVersion(getMidVersion() + 1); - setMinorVersion(0); - try { - if (this instanceof EntityServer) { - EntityServer vs = (EntityServer) this; - //Copy the version changes - Versionable v = (Versionable) vs.getEntity(); - v.update(v, this); - updateHistory(v); - vs.write2DB(); - } else { - updateHistory(this); - } - } - catch (Exception ex) { - Exceptions.printStackTrace(ex); - } - } - - /** - * Increase minor is done by default when updating a record. - * - * @param target Target of the update. - * @param source Source of the update - */ - public void update(Versionable target, Versionable source) { - target.setDirty(source.getDirty()); - target.setMajorVersion(source.getMajorVersion()); - target.setMidVersion(source.getMidVersion()); - target.setMinorVersion(source.getMinorVersion()); - target.setModifierId(source.getModifierId()); - target.setReason(source.getReason()); - target.setModificationTime(source.getModificationTime()); - target.setHistoryList(source.getHistoryList()); - try { - target.updateHistory(); - } - catch (Exception ex) { - LOG.log(Level.SEVERE, ex.getLocalizedMessage(), ex); - } - } - - @Override - public String toString() { - return "Version: " + getMajorVersion() + "." + getMidVersion() + "." - + getMinorVersion(); - } - - public enum CHANGE_LEVEL { - MINOR, - MODERATE, - MAJOR - } - - /** - * Get history for this entity. - * - * @return history - */ - public abstract List getHistoryList(); - - /** - * Set history for this entity - * - * @param historyList History list to set. - */ - public abstract void setHistoryList(List historyList); - - @Override - public int compareTo(Versionable o) { - if (!Objects.equals(getMajorVersion(), - o.getMajorVersion())) { - return getMajorVersion() - o.getMajorVersion(); - }//Same major version - else if (!Objects.equals(getMidVersion(), - o.getMidVersion())) { - return getMidVersion() - o.getMidVersion(); - } //Same mid version - else if (!Objects.equals(getMinorVersion(), - o.getMinorVersion())) { - return getMinorVersion() - o.getMinorVersion(); - } - //Everything the same - return 0; - } - - /** - * Add history to this entity. - * - * @param history History to add. - */ - public void addHistory(History history) { - if (getHistoryList() == null) { - setHistoryList(new ArrayList<>()); - } - getHistoryList().add(history); - } - - public static synchronized boolean auditable(Versionable v) { - History current; - boolean result = false; - if (v.getHistoryList() != null && !v.getHistoryList().isEmpty()) { - current = v.getHistoryList().get(v.getHistoryList().size() - 1); - for (HistoryField hf : current.getHistoryFieldList()) { - try { - //Compare audit field vs. the record in history. - Object o = FieldUtils.readField(FieldUtils.getField(v.getClass(), - hf.getFieldName(), true), v); - if ((o == null && !hf.getFieldValue().equals("null")) - || (!(o instanceof byte[]) && o != null - && !o.equals(hf.getFieldValue())) - || ((o instanceof byte[]) - && !new String((byte[]) o, - StandardCharsets.UTF_8) - .equals(hf.getFieldValue()))) { - result = true; - } - } - catch (SecurityException | IllegalArgumentException | IllegalAccessException ex) { - LOG.log(Level.SEVERE, null, ex); - } - } - //As last check the version fields for changes (i.e. baselineing, etc.) - if (!result) { - result = current.getMajorVersion() < v.getMajorVersion() - || current.getMidVersion() < v.getMidVersion() - || current.getMinorVersion() < v.getMinorVersion(); - } - return result; - } - //No history so it is auditable if it has marked fields for audit. - return !FieldUtils.getFieldsListWithAnnotation(v.getClass(), - Auditable.class).isEmpty(); - } - - public void updateHistory() throws Exception { - updateHistory(this); - } - - protected void updateHistory(Versionable v) throws Exception { - //Only if an auditable field has been modified - if (auditable(v)) { - //Add history of creation - HistoryServer hs = new HistoryServer(); - if (v.getModifierId() < 0) { - try { - //By default blame system - hs.setModifierId(new VMUserServer(1).getEntity()); - } - catch (Exception ex) { - LOG.log(Level.SEVERE, null, ex); - } - } else { - hs.setModifierId(new VMUserServer(v.getModifierId()).getEntity()); - } - - if (v.getHistoryList() != null && !v.getHistoryList().isEmpty()) { - if (v.getReason() == null - || v.getReason().equals("audit.general.creation")) { - v.setReason("audit.general.modified"); - } - History last = v.getHistoryList().get(v.getHistoryList().size() - 1); - if ((v.getMajorVersion() == 0 && v.getMidVersion() == 0) // It has default values - || last.getMajorVersion() == v.getMajorVersion() // Or it has a higher mid/major version assigned. - && last.getMidVersion() == v.getMidVersion()) { - //Make it one more than latest - hs.setMajorVersion(v.getMajorVersion()); - hs.setMidVersion(v.getMidVersion()); - hs.setMinorVersion(last.getMinorVersion() + 1); - } else { - //Copy values from object as it was forced changed. - hs.setMajorVersion(v.getMajorVersion()); - hs.setMidVersion(v.getMidVersion()); - hs.setMinorVersion(v.getMinorVersion()); - } - } else { - if (v.getReason() == null) { - v.setReason("audit.general.creation"); - } - } - hs.setReason(v.getReason()); - hs.setModificationTime(v.getModificationTime() == null - ? new Date() : v.getModificationTime()); - hs.write2DB(); - //Check the fields to be placed in history - updateFields(hs, v); - } - if (v.getHistoryList() != null && v.getHistoryList().size() > 0) { - History current = v.getHistoryList().get(v.getHistoryList().size() - 1); - //Update the version the object holds - v.setMajorVersion(current.getMajorVersion()); - v.setMidVersion(current.getMidVersion()); - v.setMinorVersion(current.getMinorVersion()); - } - } - - private synchronized void updateFields(HistoryServer hs, Versionable v) - throws IllegalArgumentException, IllegalAccessException, Exception { - for (Field field : FieldUtils.getFieldsListWithAnnotation(v.getClass(), - Auditable.class)) { - Class type = field.getType(); - String name = field.getName(); - FieldType ft = FieldTypeServer.findType(type.getSimpleName()); - if (ft == null) { - FieldTypeServer fts = new FieldTypeServer(); - fts.setTypeName(type.getSimpleName()); - fts.write2DB(); - ft = fts.getEntity(); - } - HistoryFieldServer hf - = new HistoryFieldServer(ft.getId(), hs.getId()); - hf.setFieldName(name); - hf.setFieldType(ft); - hf.setHistory(hs.getEntity()); - field.setAccessible(true); - Object value = field.get(v); - if (value instanceof byte[]) { - byte[] bytes = (byte[]) value; - value = new String(bytes, StandardCharsets.UTF_8); - } - hf.setFieldValue(value == null ? "null" : value.toString()); - hf.write2DB(); - hs.getHistoryFieldList().add(hf.getEntity()); - } - hs.write2DB(); - v.addHistory(hs.getEntity()); - } -} +package com.validation.manager.core.history; + +import com.validation.manager.core.DataBaseManager; +import com.validation.manager.core.EntityServer; +import com.validation.manager.core.db.FieldType; +import com.validation.manager.core.db.History; +import com.validation.manager.core.db.HistoryField; +import com.validation.manager.core.db.VmUser; +import com.validation.manager.core.db.controller.VmUserJpaController; +import com.validation.manager.core.server.core.FieldTypeServer; +import com.validation.manager.core.server.core.HistoryFieldServer; +import com.validation.manager.core.server.core.HistoryServer; +import java.io.Serializable; +import java.lang.reflect.Field; +import java.nio.charset.StandardCharsets; +import java.util.ArrayList; +import java.util.Date; +import java.util.List; +import java.util.Objects; +import java.util.logging.Level; +import java.util.logging.Logger; +import javax.persistence.Basic; +import javax.persistence.Column; +import javax.persistence.DiscriminatorColumn; +import javax.persistence.Inheritance; +import javax.persistence.InheritanceType; +import javax.persistence.MappedSuperclass; +import javax.persistence.Temporal; +import javax.persistence.TemporalType; +import org.apache.commons.lang3.reflect.FieldUtils; +import org.openide.util.Exceptions; + +@MappedSuperclass +@Inheritance(strategy = InheritanceType.JOINED) +@DiscriminatorColumn(name = "VERSIONABLE_TYPE") +public abstract class Versionable implements Comparable, + Serializable { + + private static final Logger LOG + = Logger.getLogger(Versionable.class.getSimpleName()); + + @Column(name = "majorVersion", insertable = false, updatable = false) + private Integer majorVersion = 0; + @Column(name = "midVersion", insertable = false, updatable = false) + private Integer midVersion = 0; + @Column(name = "minorVersion", insertable = false, updatable = false) + private Integer minorVersion = 1; + @Column(name = "reason", insertable = false, updatable = false) + private String reason; + @Column(name = "modifierId", insertable = false, updatable = false) + private int modifierId = -1; + @Column(name = "modificationTime", insertable = false, updatable = false) + @Temporal(TemporalType.TIMESTAMP) + private Date modificationTime; + @Column(name = "dirty") + @Basic(optional = false) + private boolean dirty = false; + + public int getModifierId() { + return modifierId; + } + + public void setModifierId(int modifierId) { + this.modifierId = modifierId; + } + + public Integer getMajorVersion() { + return this.majorVersion; + } + + public void setMajorVersion(Integer majorVersion) { + this.majorVersion = majorVersion; + } + + public Integer getMidVersion() { + return this.midVersion; + } + + public void setMidVersion(Integer midVersion) { + this.midVersion = midVersion; + } + + public Integer getMinorVersion() { + return this.minorVersion; + } + + public void setMinorVersion(Integer minorVersion) { + this.minorVersion = minorVersion; + } + + public String getReason() { + return this.reason; + } + + public void setReason(String reason) { + this.reason = reason; + } + + public Date getModificationTime() { + return this.modificationTime; + } + + public void setModificationTime(Date modificationTime) { + this.modificationTime = modificationTime; + } + + public boolean getDirty() { + return this.dirty; + } + + /** + * @param dirty the dirty to set + */ + public void setDirty(boolean dirty) { + this.dirty = dirty; + } + + private void updateInternalHistory() throws Exception { + if (this instanceof EntityServer) { + EntityServer vs = (EntityServer) this; + //Copy the version changes + Versionable ao = (Versionable) vs.getEntity(); + ao.update(ao, this); + updateHistory(ao); + vs.write2DB(); + } else { + updateHistory(); + try { + DataBaseManager.getEntityManagerFactory().getMetamodel() + .entity(this.getClass()); + Object key = DataBaseManager.getEntityManagerFactory() + .getPersistenceUnitUtil().getIdentifier(this); + if (key != null + && DataBaseManager.getEntityManager() + .find(this.getClass(), key) != null) { + DataBaseManager.getEntityManager().merge(this); + } + } + catch (IllegalArgumentException ex) { + LOG.log(Level.SEVERE, "Ignore if this is an Unit test!", ex); + } + } + } + + /** + * Increase major version. + */ + public void increaseMajorVersion() { + try { + updateInternalHistory(); + setMajorVersion(getMajorVersion() + 1); + setMidVersion(0); + setMinorVersion(0); + updateInternalHistory(); + } + catch (Exception ex) { + Exceptions.printStackTrace(ex); + } + } + + /** + * Increase major version. + */ + public void increaseMidVersion() { + try { + updateInternalHistory(); + setMidVersion(getMidVersion() + 1); + setMinorVersion(0); + updateInternalHistory(); + } + catch (Exception ex) { + Exceptions.printStackTrace(ex); + } + } + + /** + * Increase minor is done by default when updating a record. + * + * @param target Target of the update. + * @param source Source of the update + */ + public void update(Versionable target, Versionable source) { + target.setDirty(source.getDirty()); + target.setMajorVersion(source.getMajorVersion()); + target.setMidVersion(source.getMidVersion()); + target.setMinorVersion(source.getMinorVersion()); + target.setModifierId(source.getModifierId()); + target.setReason(source.getReason()); + target.setModificationTime(source.getModificationTime()); + target.setHistoryList(source.getHistoryList()); + try { + target.updateHistory(); + } + catch (Exception ex) { + LOG.log(Level.SEVERE, ex.getLocalizedMessage(), ex); + } + } + + @Override + public String toString() { + return "Version: " + getMajorVersion() + "." + getMidVersion() + "." + + getMinorVersion(); + } + + public enum CHANGE_LEVEL { + MINOR, + MODERATE, + MAJOR + } + + /** + * Get history for this entity. + * + * @return history + */ + public abstract List getHistoryList(); + + /** + * Set history for this entity + * + * @param historyList History list to set. + */ + public abstract void setHistoryList(List historyList); + + @Override + public int compareTo(Versionable o) { + if (!Objects.equals(getMajorVersion(), + o.getMajorVersion())) { + return getMajorVersion() - o.getMajorVersion(); + }//Same major version + else if (!Objects.equals(getMidVersion(), + o.getMidVersion())) { + return getMidVersion() - o.getMidVersion(); + } //Same mid version + else if (!Objects.equals(getMinorVersion(), + o.getMinorVersion())) { + return getMinorVersion() - o.getMinorVersion(); + } + //Everything the same + return 0; + } + + /** + * Add history to this entity. + * + * @param history History to add. + */ + public void addHistory(History history) { + if (getHistoryList() == null) { + setHistoryList(new ArrayList<>()); + } + getHistoryList().add(history); + } + + public static boolean fieldMatchHistory(HistoryField hf, Object value) { + return !(value == null && !hf.getFieldValue().equals("null")) + || (!(value instanceof byte[]) && value != null + && !value.toString().equals(hf.getFieldValue())) + || ((value instanceof byte[]) + && !new String((byte[]) value, + StandardCharsets.UTF_8) + .equals(hf.getFieldValue())); + } + + public static synchronized boolean auditable(Versionable v) { + History current; + boolean result = false; + if (v.getHistoryList() != null && !v.getHistoryList().isEmpty()) { + current = v.getHistoryList().get(v.getHistoryList().size() - 1); + for (HistoryField hf : current.getHistoryFieldList()) { + try { + //Compare audit field vs. the record in history. + Object o = FieldUtils.readField(FieldUtils.getField(v.getClass(), + hf.getFieldName(), true), v); + if ((o == null && !hf.getFieldValue().equals("null")) + || (!(o instanceof byte[]) && o != null + && !o.toString().equals(hf.getFieldValue())) + || ((o instanceof byte[]) + && !new String((byte[]) o, + StandardCharsets.UTF_8) + .equals(hf.getFieldValue()))) { + result = true; + break; + } + } + catch (SecurityException | IllegalArgumentException | IllegalAccessException ex) { + LOG.log(Level.SEVERE, null, ex); + } + } + //As last check the version fields for changes (i.e. baselineing, etc.) + if (!result) { + result = current.getMajorVersion() < v.getMajorVersion() + || current.getMidVersion() < v.getMidVersion() + || current.getMinorVersion() < v.getMinorVersion(); + } + return result; + } + //No history so it is auditable if it has marked fields for audit. + return !FieldUtils.getFieldsListWithAnnotation(v.getClass(), + Auditable.class).isEmpty(); + } + + public void updateHistory() throws Exception { + updateHistory(this); + } + + protected void updateHistory(Versionable v) throws Exception { + //Only if an auditable field has been modified + if (auditable(v)) { + //Add history of creation + HistoryServer hs = new HistoryServer(); + VmUserJpaController c + = new VmUserJpaController(DataBaseManager.getEntityManagerFactory()); + if (v.getModifierId() <= 0) { + try { + //By default blame system + hs.setModifierId(c.findVmUser(1)); + } + catch (Exception ex) { + LOG.log(Level.SEVERE, null, ex); + } + } else { + hs.setModifierId(c.findVmUser(v.getModifierId())); + } + + if (v.getHistoryList() != null && !v.getHistoryList().isEmpty()) { + if (v.getReason() == null + || v.getReason().equals("audit.general.creation")) { + v.setReason("audit.general.modified"); + } + History last = v.getHistoryList().get(v.getHistoryList().size() - 1); + if ((v.getMajorVersion() == 0 && v.getMidVersion() == 0) // It has default values + || last.getMajorVersion() == v.getMajorVersion() // Or it has a higher mid/major version assigned. + && last.getMidVersion() == v.getMidVersion()) { + //Make it one more than latest + hs.setMajorVersion(v.getMajorVersion()); + hs.setMidVersion(v.getMidVersion()); + hs.setMinorVersion(last.getMinorVersion() + 1); + } else { + //Copy values from object as it was forced changed. + hs.setMajorVersion(v.getMajorVersion()); + hs.setMidVersion(v.getMidVersion()); + hs.setMinorVersion(v.getMinorVersion()); + } + } else { + if (v.getReason() == null) { + v.setReason("audit.general.creation"); + } + } + hs.setReason(v.getReason()); + hs.setModificationTime(v.getModificationTime() == null + ? new Date() : v.getModificationTime()); + hs.write2DB(); + if (v instanceof VmUser) { + VmUser temp = (VmUser) v; + if (Objects.equals(temp.getId(), hs.getModifierId().getId())) { + if (temp.getHistoryModificationList() == null) { + temp.setHistoryModificationList(new ArrayList<>()); + } + temp.getHistoryModificationList().add(hs.getEntity()); + } + } else { + if (hs.getModifierId() != null) { + VmUser temp = hs.getModifierId(); + if (temp.getHistoryModificationList() == null) { + temp.setHistoryModificationList(new ArrayList<>()); + } + temp.getHistoryModificationList().add(hs.getEntity()); + c.edit(temp); + } + } + //Check the fields to be placed in history + updateFields(hs, v); + } + if (v.getHistoryList() != null && v.getHistoryList().size() > 0) { + History current = v.getHistoryList().get(v.getHistoryList().size() - 1); + //Update the version the object holds + v.setMajorVersion(current.getMajorVersion()); + v.setMidVersion(current.getMidVersion()); + v.setMinorVersion(current.getMinorVersion()); + } + } + + private synchronized void updateFields(HistoryServer hs, Versionable v) + throws IllegalArgumentException, IllegalAccessException, Exception { + for (Field field : FieldUtils.getFieldsListWithAnnotation(v.getClass(), + Auditable.class)) { + Class type = field.getType(); + String name = field.getName(); + FieldType ft = FieldTypeServer.findType(type.getSimpleName()); + if (ft == null) { + FieldTypeServer fts = new FieldTypeServer(); + fts.setTypeName(type.getSimpleName()); + fts.write2DB(); + ft = fts.getEntity(); + } + HistoryFieldServer hf + = new HistoryFieldServer(ft.getId(), hs.getId()); + hf.setFieldName(name); + hf.setFieldType(ft); + hf.setHistory(hs.getEntity()); + field.setAccessible(true); + Object value = field.get(v); + if (value instanceof byte[]) { + byte[] bytes = (byte[]) value; + value = new String(bytes, StandardCharsets.UTF_8); + } + hf.setFieldValue(value == null ? "null" : value.toString()); + hf.write2DB(); + hs.getHistoryFieldList().add(hf.getEntity()); + } + hs.write2DB(); + v.addHistory(hs.getEntity()); + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/server/core/AttachmentServer.java b/VM-Core/src/main/java/com/validation/manager/core/server/core/AttachmentServer.java index 44196078..ff19c599 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/server/core/AttachmentServer.java +++ b/VM-Core/src/main/java/com/validation/manager/core/server/core/AttachmentServer.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,122 +13,128 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.server.core; - -import com.validation.manager.core.DataBaseManager; -import com.validation.manager.core.EntityServer; -import com.validation.manager.core.db.Attachment; -import com.validation.manager.core.db.AttachmentPK; -import com.validation.manager.core.db.controller.AttachmentJpaController; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import java.io.File; -import java.io.IOException; -import org.apache.commons.io.FileUtils; -import org.apache.commons.io.FilenameUtils; -import org.openide.util.Exceptions; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public final class AttachmentServer extends Attachment - implements EntityServer { - - public AttachmentServer(AttachmentPK attachmentPK) { - super(attachmentPK); - update(); - } - - public AttachmentServer() { - super(); - } - - @Override - public int write2DB() throws Exception { - AttachmentJpaController c - = new AttachmentJpaController(DataBaseManager.getEntityManagerFactory()); - if (getAttachmentPK() == null) { - Attachment a = new Attachment(); - update(a, this); - c.create(a); - setAttachmentPK(a.getAttachmentPK()); - update(); - } else { - Attachment a = new Attachment(); - update(a, this); - c.edit(a); - setAttachmentPK(a.getAttachmentPK()); - update(); - } - return getAttachmentPK().getId(); - } - - @Override - public Attachment getEntity() { - AttachmentJpaController c - = new AttachmentJpaController(DataBaseManager.getEntityManagerFactory()); - return c.findAttachment(getAttachmentPK()); - } - - @Override - public void update(Attachment target, Attachment source) { - target.setAttachmentPK(source.getAttachmentPK()); - target.setAttachmentType(source.getAttachmentType()); - target.setFileName(source.getFileName()); - target.setFile(source.getFile()); - target.setStringValue(source.getStringValue()); - target.setTextValue(source.getTextValue()); - target.setExecutionStepHasAttachmentList(source - .getExecutionStepHasAttachmentList()); - } - - @Override - public void update() { - update(this, getEntity()); - } - - public void addFile(File f, String fileName) { - try { - if (f != null && f.isFile() && f.exists()) { - byte[] array = FileUtils.readFileToByteArray(f); - setFile(array); - setFileName(fileName); - String ext = FilenameUtils.getExtension(getFileName()); - if (ext != null) { - //Set attachment type - setAttachmentType(AttachmentTypeServer.getTypeForExtension(ext)); - } - if (getAttachmentType() == null) { - //Set as undefined - setAttachmentType(AttachmentTypeServer.getTypeForExtension("")); - } - } - } - catch (IOException ex) { - Exceptions.printStackTrace(ex); - } - } - - public File getAttachedFile() { - File result; - try { - result = File.createTempFile("temp", "vm"); - result.deleteOnExit(); - FileUtils.writeByteArrayToFile(result, getFile()); - } - catch (IOException ex) { - Exceptions.printStackTrace(ex); - result = null; - } - return result; - } - - public static void delete(Attachment entity) - throws IllegalOrphanException, NonexistentEntityException, - Exception { - AttachmentJpaController c - = new AttachmentJpaController(DataBaseManager.getEntityManagerFactory()); - c.destroy(entity.getAttachmentPK()); - } -} +package com.validation.manager.core.server.core; + +import com.validation.manager.core.DataBaseManager; +import com.validation.manager.core.EntityServer; +import com.validation.manager.core.VMException; +import com.validation.manager.core.db.Attachment; +import com.validation.manager.core.db.AttachmentPK; +import com.validation.manager.core.db.controller.AttachmentJpaController; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import java.io.File; +import java.io.IOException; +import org.apache.commons.io.FileUtils; +import org.apache.commons.io.FilenameUtils; +import org.openide.util.Exceptions; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public final class AttachmentServer extends Attachment + implements EntityServer { + + public AttachmentServer(AttachmentPK attachmentPK) { + super(attachmentPK); + update(); + } + + public AttachmentServer() { + super(); + } + + @Override + public int write2DB() throws VMException { + try { + AttachmentJpaController c + = new AttachmentJpaController(DataBaseManager.getEntityManagerFactory()); + if (getAttachmentPK() == null) { + Attachment a = new Attachment(); + update(a, this); + c.create(a); + setAttachmentPK(a.getAttachmentPK()); + update(); + } else { + Attachment a = new Attachment(); + update(a, this); + c.edit(a); + setAttachmentPK(a.getAttachmentPK()); + update(); + } + } + catch (Exception ex) { + throw new VMException(ex); + } + return getAttachmentPK().getId(); + } + + @Override + public Attachment getEntity() { + AttachmentJpaController c + = new AttachmentJpaController(DataBaseManager.getEntityManagerFactory()); + return c.findAttachment(getAttachmentPK()); + } + + @Override + public void update(Attachment target, Attachment source) { + target.setAttachmentPK(source.getAttachmentPK()); + target.setAttachmentType(source.getAttachmentType()); + target.setFileName(source.getFileName()); + target.setFile(source.getFile()); + target.setStringValue(source.getStringValue()); + target.setTextValue(source.getTextValue()); + target.setExecutionStepHasAttachmentList(source + .getExecutionStepHasAttachmentList()); + } + + @Override + public void update() { + update(this, getEntity()); + } + + public void addFile(File f, String fileName) { + try { + if (f != null && f.isFile() && f.exists()) { + byte[] array = FileUtils.readFileToByteArray(f); + setFile(array); + setFileName(fileName); + String ext = FilenameUtils.getExtension(getFileName()); + if (ext != null) { + //Set attachment type + setAttachmentType(AttachmentTypeServer.getTypeForExtension(ext)); + } + if (getAttachmentType() == null) { + //Set as undefined + setAttachmentType(AttachmentTypeServer.getTypeForExtension("")); + } + } + } + catch (IOException ex) { + Exceptions.printStackTrace(ex); + } + } + + public File getAttachedFile() { + File result; + try { + result = File.createTempFile("temp", "vm"); + result.deleteOnExit(); + FileUtils.writeByteArrayToFile(result, getFile()); + } + catch (IOException ex) { + Exceptions.printStackTrace(ex); + result = null; + } + return result; + } + + public static void delete(Attachment entity) + throws IllegalOrphanException, NonexistentEntityException, + Exception { + AttachmentJpaController c + = new AttachmentJpaController(DataBaseManager.getEntityManagerFactory()); + c.destroy(entity.getAttachmentPK()); + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/server/core/AttachmentTypeServer.java b/VM-Core/src/main/java/com/validation/manager/core/server/core/AttachmentTypeServer.java index 855df8dc..807f0c22 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/server/core/AttachmentTypeServer.java +++ b/VM-Core/src/main/java/com/validation/manager/core/server/core/AttachmentTypeServer.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,69 +13,78 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.server.core; - -import com.validation.manager.core.DataBaseManager; -import com.validation.manager.core.EntityServer; -import com.validation.manager.core.db.AttachmentType; -import com.validation.manager.core.db.controller.AttachmentTypeJpaController; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class AttachmentTypeServer extends AttachmentType - implements EntityServer { - - private final AttachmentTypeJpaController c - = new AttachmentTypeJpaController(DataBaseManager - .getEntityManagerFactory()); - - @Override - public int write2DB() throws Exception { - if (getId() == null) { - AttachmentType at = new AttachmentType(); - update(at, this); - c.create(at); - update(this, at); - } else { - AttachmentType at = getEntity(); - update(at, this); - c.edit(at); - update(this, at); - } - return getId(); - } - - @Override - public AttachmentType getEntity() { - return c.findAttachmentType(getId()); - } - - @Override - public void update(AttachmentType target, AttachmentType source) { - target.setAttachmentList(source.getAttachmentList()); - target.setDescription(source.getDescription()); - target.setType(source.getType()); - } - - @Override - public void update() { - update(this, getEntity()); - } - - public static AttachmentType getTypeForExtension(String ext) { - AttachmentType at = null; - //Set attachment type - for (AttachmentType type - : new AttachmentTypeJpaController(DataBaseManager - .getEntityManagerFactory()) - .findAttachmentTypeEntities()) { - if (type.getType().equals(ext)) { - at = type; - break; - } - } - return at; - } -} +package com.validation.manager.core.server.core; + +import com.validation.manager.core.DataBaseManager; +import com.validation.manager.core.EntityServer; +import com.validation.manager.core.db.AttachmentType; +import com.validation.manager.core.db.controller.AttachmentTypeJpaController; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public final class AttachmentTypeServer extends AttachmentType + implements EntityServer { + + private final AttachmentTypeJpaController c + = new AttachmentTypeJpaController(DataBaseManager + .getEntityManagerFactory()); + + public AttachmentTypeServer(String type) { + super(type); + } + + public AttachmentTypeServer(int id) { + setId(id); + update(); + } + + @Override + public int write2DB() throws Exception { + if (getId() == null) { + AttachmentType at = new AttachmentType(); + update(at, this); + c.create(at); + update(this, at); + } else { + AttachmentType at = getEntity(); + update(at, this); + c.edit(at); + update(this, at); + } + return getId(); + } + + @Override + public AttachmentType getEntity() { + return c.findAttachmentType(getId()); + } + + @Override + public void update(AttachmentType target, AttachmentType source) { + target.setAttachmentList(source.getAttachmentList()); + target.setDescription(source.getDescription()); + target.setType(source.getType()); + } + + @Override + public void update() { + update(this, getEntity()); + } + + public static AttachmentType getTypeForExtension(String ext) { + AttachmentType at = null; + //Set attachment type + for (AttachmentType type + : new AttachmentTypeJpaController(DataBaseManager + .getEntityManagerFactory()) + .findAttachmentTypeEntities()) { + if (type.getType().equals(ext)) { + at = type; + break; + } + } + return at; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/server/core/ExecutionResultServer.java b/VM-Core/src/main/java/com/validation/manager/core/server/core/ExecutionResultServer.java index 3b69b1fa..d08bdbed 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/server/core/ExecutionResultServer.java +++ b/VM-Core/src/main/java/com/validation/manager/core/server/core/ExecutionResultServer.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,74 +13,83 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.server.core; - -import com.validation.manager.core.DataBaseManager; -import com.validation.manager.core.EntityServer; -import com.validation.manager.core.db.ExecutionResult; -import com.validation.manager.core.db.controller.ExecutionResultJpaController; -import java.util.List; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class ExecutionResultServer extends ExecutionResult - implements EntityServer { - - @Override - public int write2DB() throws Exception { - ExecutionResultJpaController c - = new ExecutionResultJpaController(DataBaseManager - .getEntityManagerFactory()); - if (getId() == null) { - ExecutionResult r = new ExecutionResult(); - update(r, this); - c.create(r); - setId(r.getId()); - update(); - } else { - ExecutionResult r = getEntity(); - update(r, this); - c.create(r); - setId(r.getId()); - update(); - } - return getId(); - } - - @Override - public ExecutionResult getEntity() { - return new ExecutionResultJpaController(DataBaseManager - .getEntityManagerFactory()).findExecutionResult(getId()); - } - - @Override - public void update(ExecutionResult target, ExecutionResult source) { - target.setExecutionStepList(source.getExecutionStepList()); - target.setId(source.getId()); - target.setResultName(source.getResultName()); - } - - @Override - public void update() { - update(this, getEntity()); - } - - public static ExecutionResult getResult(String result) { - PARAMETERS.clear(); - PARAMETERS.put("resultName", result); - List r = DataBaseManager.namedQuery("ExecutionResult.findByResultName", - PARAMETERS); - if (r.isEmpty()) { - return null; - } else { - return (ExecutionResult) r.get(0); - } - } - - public static List getResults() { - return new ExecutionResultJpaController(DataBaseManager - .getEntityManagerFactory()).findExecutionResultEntities(); - } -} +package com.validation.manager.core.server.core; + +import com.validation.manager.core.DataBaseManager; +import com.validation.manager.core.EntityServer; +import com.validation.manager.core.db.ExecutionResult; +import com.validation.manager.core.db.controller.ExecutionResultJpaController; +import java.util.List; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class ExecutionResultServer extends ExecutionResult + implements EntityServer { + + public ExecutionResultServer(String resultName) { + super(resultName); + } + + public ExecutionResultServer(int id) { + setId(id); + update(); + } + + @Override + public int write2DB() throws Exception { + ExecutionResultJpaController c + = new ExecutionResultJpaController(DataBaseManager + .getEntityManagerFactory()); + if (getId() == null) { + ExecutionResult r = new ExecutionResult(); + update(r, this); + c.create(r); + setId(r.getId()); + update(); + } else { + ExecutionResult r = getEntity(); + update(r, this); + c.edit(r); + setId(r.getId()); + update(); + } + return getId(); + } + + @Override + public ExecutionResult getEntity() { + return new ExecutionResultJpaController(DataBaseManager + .getEntityManagerFactory()).findExecutionResult(getId()); + } + + @Override + public void update(ExecutionResult target, ExecutionResult source) { + target.setExecutionStepList(source.getExecutionStepList()); + target.setId(source.getId()); + target.setResultName(source.getResultName()); + } + + @Override + public void update() { + update(this, getEntity()); + } + + public static ExecutionResult getResult(String result) { + PARAMETERS.clear(); + PARAMETERS.put("resultName", result); + List r = DataBaseManager.namedQuery("ExecutionResult.findByResultName", + PARAMETERS); + if (r.isEmpty()) { + return null; + } else { + return (ExecutionResult) r.get(0); + } + } + + public static List getResults() { + return new ExecutionResultJpaController(DataBaseManager + .getEntityManagerFactory()).findExecutionResultEntities(); + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/server/core/ExecutionStepServer.java b/VM-Core/src/main/java/com/validation/manager/core/server/core/ExecutionStepServer.java index 1d121528..7ee885de 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/server/core/ExecutionStepServer.java +++ b/VM-Core/src/main/java/com/validation/manager/core/server/core/ExecutionStepServer.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,170 +13,176 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.server.core; - -import com.validation.manager.core.DataBaseManager; -import com.validation.manager.core.EntityServer; -import com.validation.manager.core.db.Attachment; -import com.validation.manager.core.db.ExecutionStep; -import com.validation.manager.core.db.ExecutionStepHasAttachment; -import com.validation.manager.core.db.ExecutionStepHasIssue; -import com.validation.manager.core.db.ExecutionStepPK; -import com.validation.manager.core.db.Issue; -import com.validation.manager.core.db.VmUser; -import com.validation.manager.core.db.controller.ExecutionStepHasAttachmentJpaController; -import com.validation.manager.core.db.controller.ExecutionStepHasIssueJpaController; -import com.validation.manager.core.db.controller.ExecutionStepJpaController; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import java.util.ArrayList; -import java.util.Date; -import org.openide.util.Exceptions; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public final class ExecutionStepServer extends ExecutionStep - implements EntityServer { - - private final ExecutionStepJpaController c - = new ExecutionStepJpaController(DataBaseManager - .getEntityManagerFactory()); - - public ExecutionStepServer(ExecutionStep es) { - super(es.getExecutionStepPK()); - update(); - } - - public ExecutionStepServer(ExecutionStepPK pk) { - super(pk); - update(); - } - - @Override - public int write2DB() throws Exception { - if (getExecutionStepPK() == null) { - ExecutionStep es = new ExecutionStep(); - update(es, this); - c.create(es); - setExecutionStepPK(es.getExecutionStepPK()); - update(); - } else { - ExecutionStep es = getEntity(); - update(es, this); - c.edit(es); - update(); - } - return getExecutionStepPK().getTestCaseExecutionId(); - } - - @Override - public ExecutionStep getEntity() { - return c.findExecutionStep(getExecutionStepPK()); - } - - @Override - public void update(ExecutionStep target, ExecutionStep source) { - if (target.getExecutionStepHasAttachmentList() == null) { - target.setExecutionStepHasAttachmentList(new ArrayList<>()); - } - target.setAssignedTime(source.getAssignedTime()); - target.setComment(source.getComment()); - target.setExecutionEnd(source.getExecutionEnd()); - target.setExecutionStart(source.getExecutionStart()); - target.setExecutionStepHasAttachmentList(source - .getExecutionStepHasAttachmentList()); - target.setExecutionTime(source.getExecutionTime()); - target.setResultId(source.getResultId()); - target.setStep(source.getStep()); - target.setTestCaseExecution(source.getTestCaseExecution()); - target.setAssignee(source.getAssignee()); - target.setAssigner(source.getAssigner()); - target.setLocked(source.getLocked()); - target.setExecutionStepHasIssueList(source.getExecutionStepHasIssueList()); - target.setReviewed(source.getReviewed()); - target.setReviewDate(source.getReviewDate()); - target.setHistoryList(source.getHistoryList()); - target.setStepHistory(source.getStepHistory()); - } - - @Override - public void update() { - update(this, getEntity()); - } - - public void assignUser(VmUser assignee, VmUser assigner) { - try { - setAssignee(assignee); - setAssigner(assigner); - setAssignedTime(new Date()); - write2DB(); - } - catch (Exception ex) { - Exceptions.printStackTrace(ex); - } - } - - public void addAttachment(AttachmentServer attachment) throws Exception { - ExecutionStepHasAttachment esha = new ExecutionStepHasAttachment(); - ExecutionStepHasAttachmentJpaController controller - = new ExecutionStepHasAttachmentJpaController(DataBaseManager - .getEntityManagerFactory()); - esha.setAttachment(attachment.getEntity()); - esha.setExecutionStep(getEntity()); - esha.setCreationTime(new Date()); - controller.create(esha); - getExecutionStepHasAttachmentList().add(esha); - write2DB(); - update(); - } - - public void addIssue(IssueServer issue, VMUserServer user) throws Exception { - ExecutionStepHasIssue eshi = new ExecutionStepHasIssue(); - ExecutionStepHasIssueJpaController controller - = new ExecutionStepHasIssueJpaController(DataBaseManager - .getEntityManagerFactory()); - eshi.setIssue(issue.getEntity()); - eshi.setExecutionStep(getEntity()); - eshi.setVmUserList(new ArrayList<>()); - eshi.getVmUserList().add(user.getEntity()); - controller.create(eshi); - getExecutionStepHasIssueList().add(eshi); - write2DB(); - update(); - } - - public void removeAttachment(Attachment attachment) throws Exception { - ExecutionStepHasAttachment toRemove = null; - for (ExecutionStepHasAttachment esha : getExecutionStepHasAttachmentList()) { - if (esha.getAttachment().getAttachmentPK().getId() - == attachment.getAttachmentPK().getId()) { - toRemove = esha; - break; - } - } - if (toRemove != null) { - new ExecutionStepHasAttachmentJpaController(DataBaseManager - .getEntityManagerFactory()).destroy(toRemove - .getExecutionStepHasAttachmentPK()); - update(); - } - } - - public void removeIssue(Issue issue) throws NonexistentEntityException { - ExecutionStepHasIssue toRemove = null; - for (ExecutionStepHasIssue eshi : getExecutionStepHasIssueList()) { - if (eshi.getIssue().getIssuePK().getId() - == issue.getIssuePK().getId()) { - toRemove = eshi; - break; - } - } - if (toRemove != null) { - new ExecutionStepHasIssueJpaController(DataBaseManager - .getEntityManagerFactory()).destroy(toRemove - .getExecutionStepHasIssuePK()); - update(); - } - } -} +package com.validation.manager.core.server.core; + +import com.validation.manager.core.DataBaseManager; +import com.validation.manager.core.EntityServer; +import com.validation.manager.core.VMException; +import com.validation.manager.core.db.Attachment; +import com.validation.manager.core.db.ExecutionStep; +import com.validation.manager.core.db.ExecutionStepHasAttachment; +import com.validation.manager.core.db.ExecutionStepHasIssue; +import com.validation.manager.core.db.ExecutionStepPK; +import com.validation.manager.core.db.Issue; +import com.validation.manager.core.db.VmUser; +import com.validation.manager.core.db.controller.ExecutionStepHasAttachmentJpaController; +import com.validation.manager.core.db.controller.ExecutionStepHasIssueJpaController; +import com.validation.manager.core.db.controller.ExecutionStepJpaController; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import java.util.ArrayList; +import java.util.Date; +import org.openide.util.Exceptions; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public final class ExecutionStepServer extends ExecutionStep + implements EntityServer { + + private final ExecutionStepJpaController c + = new ExecutionStepJpaController(DataBaseManager + .getEntityManagerFactory()); + + public ExecutionStepServer(ExecutionStep es) { + super(es.getExecutionStepPK()); + update(); + } + + public ExecutionStepServer(ExecutionStepPK pk) { + super(pk); + update(); + } + + @Override + public int write2DB() throws VMException { + try { + if (getExecutionStepPK() == null) { + ExecutionStep es = new ExecutionStep(); + update(es, this); + c.create(es); + setExecutionStepPK(es.getExecutionStepPK()); + update(); + } else { + ExecutionStep es = getEntity(); + update(es, this); + c.edit(es); + update(); + } + } + catch (Exception ex) { + throw new VMException(ex); + } + return getExecutionStepPK().getTestCaseExecutionId(); + } + + @Override + public ExecutionStep getEntity() { + return c.findExecutionStep(getExecutionStepPK()); + } + + @Override + public void update(ExecutionStep target, ExecutionStep source) { + if (target.getExecutionStepHasAttachmentList() == null) { + target.setExecutionStepHasAttachmentList(new ArrayList<>()); + } + target.setAssignedTime(source.getAssignedTime()); + target.setComment(source.getComment()); + target.setExecutionEnd(source.getExecutionEnd()); + target.setExecutionStart(source.getExecutionStart()); + target.setExecutionStepHasAttachmentList(source + .getExecutionStepHasAttachmentList()); + target.setExecutionTime(source.getExecutionTime()); + target.setResultId(source.getResultId()); + target.setStep(source.getStep()); + target.setTestCaseExecution(source.getTestCaseExecution()); + target.setAssignee(source.getAssignee()); + target.setAssigner(source.getAssigner()); + target.setLocked(source.getLocked()); + target.setExecutionStepHasIssueList(source.getExecutionStepHasIssueList()); + target.setReviewed(source.getReviewed()); + target.setReviewDate(source.getReviewDate()); + target.setHistoryList(source.getHistoryList()); + target.setStepHistory(source.getStepHistory()); + } + + @Override + public void update() { + update(this, getEntity()); + } + + public void assignUser(VmUser assignee, VmUser assigner) { + try { + setAssignee(assignee); + setAssigner(assigner); + setAssignedTime(new Date()); + write2DB(); + } + catch (VMException ex) { + Exceptions.printStackTrace(ex); + } + } + + public void addAttachment(AttachmentServer attachment) throws Exception { + ExecutionStepHasAttachment esha = new ExecutionStepHasAttachment(); + ExecutionStepHasAttachmentJpaController controller + = new ExecutionStepHasAttachmentJpaController(DataBaseManager + .getEntityManagerFactory()); + esha.setAttachment(attachment.getEntity()); + esha.setExecutionStep(getEntity()); + esha.setCreationTime(new Date()); + controller.create(esha); + getExecutionStepHasAttachmentList().add(esha); + write2DB(); + update(); + } + + public void addIssue(IssueServer issue, VMUserServer user) throws Exception { + ExecutionStepHasIssue eshi = new ExecutionStepHasIssue(); + ExecutionStepHasIssueJpaController controller + = new ExecutionStepHasIssueJpaController(DataBaseManager + .getEntityManagerFactory()); + eshi.setIssue(issue.getEntity()); + eshi.setExecutionStep(getEntity()); + eshi.setVmUserList(new ArrayList<>()); + eshi.getVmUserList().add(user.getEntity()); + controller.create(eshi); + getExecutionStepHasIssueList().add(eshi); + write2DB(); + update(); + } + + public void removeAttachment(Attachment attachment) throws Exception { + ExecutionStepHasAttachment toRemove = null; + for (ExecutionStepHasAttachment esha : getExecutionStepHasAttachmentList()) { + if (esha.getAttachment().getAttachmentPK().getId() + == attachment.getAttachmentPK().getId()) { + toRemove = esha; + break; + } + } + if (toRemove != null) { + new ExecutionStepHasAttachmentJpaController(DataBaseManager + .getEntityManagerFactory()).destroy(toRemove + .getExecutionStepHasAttachmentPK()); + update(); + } + } + + public void removeIssue(Issue issue) throws NonexistentEntityException { + ExecutionStepHasIssue toRemove = null; + for (ExecutionStepHasIssue eshi : getExecutionStepHasIssueList()) { + if (eshi.getIssue().getIssuePK().getId() + == issue.getIssuePK().getId()) { + toRemove = eshi; + break; + } + } + if (toRemove != null) { + new ExecutionStepHasIssueJpaController(DataBaseManager + .getEntityManagerFactory()).destroy(toRemove + .getExecutionStepHasIssuePK()); + update(); + } + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/server/core/FieldTypeServer.java b/VM-Core/src/main/java/com/validation/manager/core/server/core/FieldTypeServer.java index 32b65c7a..1beb9600 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/server/core/FieldTypeServer.java +++ b/VM-Core/src/main/java/com/validation/manager/core/server/core/FieldTypeServer.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,61 +13,67 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.server.core; - -import com.validation.manager.core.DataBaseManager; -import com.validation.manager.core.EntityServer; -import com.validation.manager.core.db.FieldType; -import com.validation.manager.core.db.controller.FieldTypeJpaController; -import java.util.List; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class FieldTypeServer extends FieldType - implements EntityServer { - - public static FieldType findType(String simpleName) { - PARAMETERS.clear(); - PARAMETERS.put("typeName", simpleName); - List r = DataBaseManager.namedQuery("FieldType.findByTypeName", PARAMETERS); - return r.isEmpty() ? null : (FieldType) r.get(0); - } - - @Override - public int write2DB() throws Exception { - FieldTypeJpaController c = new FieldTypeJpaController(DataBaseManager - .getEntityManagerFactory()); - if (getId() == null) { - FieldType ft = new FieldType(); - update(ft, this); - c.create(ft); - update(this, ft); - } else { - FieldType ft = getEntity(); - update(ft, this); - c.edit(ft); - update(this, ft); - } - return getId(); - } - - @Override - public FieldType getEntity() { - return new FieldTypeJpaController(DataBaseManager - .getEntityManagerFactory()).findFieldType(getId()); - } - - @Override - public void update(FieldType target, FieldType source) { - target.setHistoryFieldList(source.getHistoryFieldList()); - target.setId(source.getId()); - target.setTypeName(source.getTypeName()); - } - - @Override - public void update() { - update(this, getEntity()); - } -} +package com.validation.manager.core.server.core; + +import com.validation.manager.core.DataBaseManager; +import com.validation.manager.core.EntityServer; +import com.validation.manager.core.VMException; +import com.validation.manager.core.db.FieldType; +import com.validation.manager.core.db.controller.FieldTypeJpaController; +import java.util.List; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class FieldTypeServer extends FieldType + implements EntityServer { + + public static FieldType findType(String simpleName) { + PARAMETERS.clear(); + PARAMETERS.put("typeName", simpleName); + List r = DataBaseManager.namedQuery("FieldType.findByTypeName", PARAMETERS); + return r.isEmpty() ? null : (FieldType) r.get(0); + } + + @Override + public int write2DB() throws VMException { + try { + FieldTypeJpaController c = new FieldTypeJpaController(DataBaseManager + .getEntityManagerFactory()); + if (getId() == null) { + FieldType ft = new FieldType(); + update(ft, this); + c.create(ft); + update(this, ft); + } else { + FieldType ft = getEntity(); + update(ft, this); + c.edit(ft); + update(this, ft); + } + } + catch (Exception ex) { + throw new VMException(ex); + } + return getId(); + } + + @Override + public FieldType getEntity() { + return new FieldTypeJpaController(DataBaseManager + .getEntityManagerFactory()).findFieldType(getId()); + } + + @Override + public void update(FieldType target, FieldType source) { + target.setHistoryFieldList(source.getHistoryFieldList()); + target.setId(source.getId()); + target.setTypeName(source.getTypeName()); + } + + @Override + public void update() { + update(this, getEntity()); + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/server/core/HistoryServer.java b/VM-Core/src/main/java/com/validation/manager/core/server/core/HistoryServer.java index 96a12472..75924c1b 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/server/core/HistoryServer.java +++ b/VM-Core/src/main/java/com/validation/manager/core/server/core/HistoryServer.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,97 +13,104 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.server.core; - -import com.validation.manager.core.DataBaseManager; -import com.validation.manager.core.EntityServer; -import com.validation.manager.core.db.History; -import com.validation.manager.core.db.controller.HistoryJpaController; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public final class HistoryServer extends History - implements EntityServer { - - public HistoryServer() { - super(); - } - - public HistoryServer(History history) { - super(history.getId()); - update(); - } - - @Override - public int write2DB() throws Exception { - HistoryJpaController c = new HistoryJpaController(DataBaseManager - .getEntityManagerFactory()); - if (getId() == null) { - History h = new History(); - update(h, this); - c.create(h); - update(this, h); - } else { - History h = getEntity(); - update(h, this); - c.edit(h); - update(this, h); - } - return getId(); - } - - @Override - public History getEntity() { - return new HistoryJpaController(DataBaseManager - .getEntityManagerFactory()).findHistory(getId()); - } - - @Override - public void update(History target, History source) { - target.setBaselineList(source.getBaselineList()); - target.setExecutionStepList(source.getExecutionStepList()); - target.setHistoryFieldList(source.getHistoryFieldList()); - target.setId(source.getId()); - target.setMajorVersion(source.getMajorVersion()); - target.setMidVersion(source.getMidVersion()); - target.setMinorVersion(source.getMinorVersion()); - target.setModificationTime(source.getModificationTime()); - target.setModifierId(source.getModifierId()); - target.setReason(source.getReason()); - target.setProjectId(source.getProjectId()); - target.setStep(source.getStep()); - target.setRequirementId(source.getRequirementId()); - target.setVmSettingId(source.getVmSettingId()); - } - - @Override - public void update() { - update(this, getEntity()); - } - - /** - * Do a major version of the item - */ - public void increaseMajor() { - setMajorVersion(getMajorVersion() + 1); - setMidVersion(0); - setMinorVersion(0); - } - - /** - * Do a medium version of the item - */ - public void increaseMid() { - setMidVersion(getMidVersion() + 1); - setMinorVersion(0); - } - - /** - * Do a minor version of the item - */ - public void increaseMinor() { - setMinorVersion(getMinorVersion() + 1); - } -} +package com.validation.manager.core.server.core; + +import com.validation.manager.core.DataBaseManager; +import com.validation.manager.core.EntityServer; +import com.validation.manager.core.VMException; +import com.validation.manager.core.db.History; +import com.validation.manager.core.db.controller.HistoryJpaController; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public final class HistoryServer extends History + implements EntityServer { + + public HistoryServer() { + super(); + } + + public HistoryServer(History history) { + super(history.getId()); + update(); + } + + @Override + public int write2DB() throws VMException { + try { + HistoryJpaController c = new HistoryJpaController(DataBaseManager + .getEntityManagerFactory()); + if (getId() == null) { + History h = new History(); + update(h, this); + c.create(h); + update(this, h); + } else { + History h = getEntity(); + update(h, this); + c.edit(h); + update(this, h); + } + } + catch (Exception ex) { + throw new VMException(ex); + } + return getId(); + } + + @Override + public History getEntity() { + return new HistoryJpaController(DataBaseManager + .getEntityManagerFactory()).findHistory(getId()); + } + + @Override + public void update(History target, History source) { + target.setBaselineList(source.getBaselineList()); + target.setExecutionStepList(source.getExecutionStepList()); + target.setHistoryFieldList(source.getHistoryFieldList()); + target.setId(source.getId()); + target.setMajorVersion(source.getMajorVersion()); + target.setMidVersion(source.getMidVersion()); + target.setMinorVersion(source.getMinorVersion()); + target.setModificationTime(source.getModificationTime()); + target.setModifierId(source.getModifierId()); + target.setReason(source.getReason()); + target.setProjectId(source.getProjectId()); + target.setStep(source.getStep()); + target.setRequirementId(source.getRequirementId()); + target.setVmSettingId(source.getVmSettingId()); + target.setVmUserId(source.getVmUserId()); + } + + @Override + public void update() { + update(this, getEntity()); + } + + /** + * Do a major version of the item + */ + public void increaseMajor() { + setMajorVersion(getMajorVersion() + 1); + setMidVersion(0); + setMinorVersion(0); + } + + /** + * Do a medium version of the item + */ + public void increaseMid() { + setMidVersion(getMidVersion() + 1); + setMinorVersion(0); + } + + /** + * Do a minor version of the item + */ + public void increaseMinor() { + setMinorVersion(getMinorVersion() + 1); + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/server/core/IssueTypeServer.java b/VM-Core/src/main/java/com/validation/manager/core/server/core/IssueTypeServer.java index 0fba4f70..e19a7a4d 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/server/core/IssueTypeServer.java +++ b/VM-Core/src/main/java/com/validation/manager/core/server/core/IssueTypeServer.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,71 +13,80 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.server.core; - -import com.validation.manager.core.DataBaseManager; -import com.validation.manager.core.EntityServer; -import com.validation.manager.core.db.IssueType; -import com.validation.manager.core.db.controller.IssueTypeJpaController; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class IssueTypeServer extends IssueType - implements EntityServer { - - @Override - public int write2DB() throws Exception { - if (getId() == null) { - IssueType i = new IssueType(); - update(i, this); - new IssueTypeJpaController(DataBaseManager - .getEntityManagerFactory()).create(i); - update(this, i); - } else { - IssueType i = getEntity(); - update(i, this); - new IssueTypeJpaController(DataBaseManager - .getEntityManagerFactory()).edit(i); - update(this, i); - } - return getId(); - } - - @Override - public IssueType getEntity() { - return new IssueTypeJpaController(DataBaseManager - .getEntityManagerFactory()).findIssueType(getId()); - } - - @Override - public void update(IssueType target, IssueType source) { - target.setDescription(source.getDescription()); - target.setIssueList(source.getIssueList()); - target.setTypeName(source.getTypeName()); - } - - @Override - public void update() { - update(this, getEntity()); - } - - /** - * Get an Issue Type by name. - * - * @param typename name to search for - * @return Issue Type for the specified name or null if not found. - */ - public static IssueType getType(String typename) { - IssueType result = null; - for (IssueType type : new IssueTypeJpaController(DataBaseManager - .getEntityManagerFactory()).findIssueTypeEntities()) { - if (type.getTypeName().equals(typename)) { - result = type; - break; - } - } - return result; - } -} +package com.validation.manager.core.server.core; + +import com.validation.manager.core.DataBaseManager; +import com.validation.manager.core.EntityServer; +import com.validation.manager.core.db.IssueType; +import com.validation.manager.core.db.controller.IssueTypeJpaController; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class IssueTypeServer extends IssueType + implements EntityServer { + + public IssueTypeServer(int id) { + setId(id); + update(); + } + + public IssueTypeServer(String typeName) { + super(typeName); + } + + @Override + public int write2DB() throws Exception { + if (getId() == null) { + IssueType i = new IssueType(); + update(i, this); + new IssueTypeJpaController(DataBaseManager + .getEntityManagerFactory()).create(i); + update(this, i); + } else { + IssueType i = getEntity(); + update(i, this); + new IssueTypeJpaController(DataBaseManager + .getEntityManagerFactory()).edit(i); + update(this, i); + } + return getId(); + } + + @Override + public IssueType getEntity() { + return new IssueTypeJpaController(DataBaseManager + .getEntityManagerFactory()).findIssueType(getId()); + } + + @Override + public void update(IssueType target, IssueType source) { + target.setDescription(source.getDescription()); + target.setIssueList(source.getIssueList()); + target.setTypeName(source.getTypeName()); + } + + @Override + public void update() { + update(this, getEntity()); + } + + /** + * Get an Issue Type by name. + * + * @param typename name to search for + * @return Issue Type for the specified name or null if not found. + */ + public static IssueType getType(String typename) { + IssueType result = null; + for (IssueType type : new IssueTypeJpaController(DataBaseManager + .getEntityManagerFactory()).findIssueTypeEntities()) { + if (type.getTypeName().equals(typename)) { + result = type; + break; + } + } + return result; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/server/core/NotificationServer.java b/VM-Core/src/main/java/com/validation/manager/core/server/core/NotificationServer.java index a05f1928..cd5a24a5 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/server/core/NotificationServer.java +++ b/VM-Core/src/main/java/com/validation/manager/core/server/core/NotificationServer.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,78 +13,84 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.server.core; - -import com.validation.manager.core.DataBaseManager; -import com.validation.manager.core.EntityServer; -import com.validation.manager.core.db.Notification; -import com.validation.manager.core.db.NotificationPK; -import com.validation.manager.core.db.controller.NotificationJpaController; -import java.util.Date; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class NotificationServer extends Notification - implements EntityServer { - - public NotificationServer() { - super(); - } - - public NotificationServer(Notification n) { - setNotificationPK(n.getNotificationPK()); - update(); - } - - public NotificationServer(NotificationPK pk) { - setNotificationPK(pk); - update(); - } - - @Override - public int write2DB() throws Exception { - if (getNotificationPK() == null) { - Notification n = new Notification(); - if (getCreationDate() == null) { - setCreationDate(new Date()); - } - update(n, this); - new NotificationJpaController(DataBaseManager - .getEntityManagerFactory()).create(n); - setNotificationPK(n.getNotificationPK()); - } else { - Notification n = getEntity(); - update(n, this); - new NotificationJpaController(DataBaseManager - .getEntityManagerFactory()).edit(n); - } - update(); - return getNotificationPK().getId(); - } - - @Override - public Notification getEntity() { - return new NotificationJpaController(DataBaseManager - .getEntityManagerFactory()) - .findNotification(getNotificationPK()); - } - - @Override - public void update(Notification target, Notification source) { - target.setAcknowledgeDate(source.getAcknowledgeDate()); - target.setAuthor(source.getAuthor()); - target.setContent(source.getContent()); - target.setCreationDate(source.getCreationDate()); - target.setNotificationPK(source.getNotificationPK()); - target.setNotificationType(source.getNotificationType()); - target.setTargetUser(source.getTargetUser()); - target.setArchieved(source.getArchieved()); - } - - @Override - public void update() { - update(this, getEntity()); - } -} +package com.validation.manager.core.server.core; + +import com.validation.manager.core.DataBaseManager; +import com.validation.manager.core.EntityServer; +import com.validation.manager.core.VMException; +import com.validation.manager.core.db.Notification; +import com.validation.manager.core.db.NotificationPK; +import com.validation.manager.core.db.controller.NotificationJpaController; +import java.util.Date; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public final class NotificationServer extends Notification + implements EntityServer { + + public NotificationServer() { + super(); + } + + public NotificationServer(Notification n) { + setNotificationPK(n.getNotificationPK()); + update(); + } + + public NotificationServer(NotificationPK pk) { + setNotificationPK(pk); + update(); + } + + @Override + public int write2DB() throws VMException { + try { + if (getNotificationPK() == null) { + Notification n = new Notification(); + if (getCreationDate() == null) { + setCreationDate(new Date()); + } + update(n, this); + new NotificationJpaController(DataBaseManager + .getEntityManagerFactory()).create(n); + setNotificationPK(n.getNotificationPK()); + } else { + Notification n = getEntity(); + update(n, this); + new NotificationJpaController(DataBaseManager + .getEntityManagerFactory()).edit(n); + } + update(); + } + catch (Exception ex) { + throw new VMException(ex); + } + return getNotificationPK().getId(); + } + + @Override + public Notification getEntity() { + return new NotificationJpaController(DataBaseManager + .getEntityManagerFactory()) + .findNotification(getNotificationPK()); + } + + @Override + public void update(Notification target, Notification source) { + target.setAcknowledgeDate(source.getAcknowledgeDate()); + target.setAuthor(source.getAuthor()); + target.setContent(source.getContent()); + target.setCreationDate(source.getCreationDate()); + target.setNotificationPK(source.getNotificationPK()); + target.setNotificationType(source.getNotificationType()); + target.setTargetUser(source.getTargetUser()); + target.setArchieved(source.getArchieved()); + } + + @Override + public void update() { + update(this, getEntity()); + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/server/core/ProjectServer.java b/VM-Core/src/main/java/com/validation/manager/core/server/core/ProjectServer.java index 963b9765..520d2d4e 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/server/core/ProjectServer.java +++ b/VM-Core/src/main/java/com/validation/manager/core/server/core/ProjectServer.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,153 +13,135 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.server.core; - -import static com.validation.manager.core.DataBaseManager.getEntityManagerFactory; -import com.validation.manager.core.EntityServer; -import com.validation.manager.core.VMException; -import com.validation.manager.core.db.Project; -import com.validation.manager.core.db.TestProject; -import com.validation.manager.core.db.controller.ProjectJpaController; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import java.util.ArrayList; -import java.util.List; -import java.util.logging.Level; -import static java.util.logging.Logger.getLogger; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public final class ProjectServer extends Project - implements EntityServer, VersionableServer { - - private static final long serialVersionUID = 3434510483033583117L; - - public ProjectServer(String name, String notes) { - super(name); - setNotes(notes); - setProjectList(new ArrayList<>()); - setRequirementSpecList(new ArrayList<>()); - setTestProjectList(new ArrayList<>()); - } - - public ProjectServer(int id) { - Project product = new ProjectJpaController( - getEntityManagerFactory()).findProject(id); - update((ProjectServer) this, product); - } - - public ProjectServer(Project p) { - Project product = new ProjectJpaController( - getEntityManagerFactory()).findProject(p.getId()); - update((ProjectServer) this, product); - } - - @Override - public int write2DB() throws IllegalOrphanException, - NonexistentEntityException, Exception { - Project p; - if (getId() == null) { - p = new Project(getName()); - update(p, this); - new ProjectJpaController(getEntityManagerFactory()).create(p); - setId(p.getId()); - } else { - p = getEntity(); - update(p, this); - new ProjectJpaController(getEntityManagerFactory()).edit(p); - } - return getId(); - } - - public static void deleteProject(Project p) throws VMException { - if (p.getProjectList().isEmpty()) { - try { - if (p.getRequirementSpecList().isEmpty()) { - new ProjectJpaController(getEntityManagerFactory()) - .destroy(p.getId()); - } else { - throw new VMException("Unable to delete project with Requirement Specifications!"); - } - } - catch (IllegalOrphanException | NonexistentEntityException ex) { - getLogger(ProjectServer.class.getName()).log(Level.SEVERE, null, ex); - } - } else { - throw new VMException("Unable to delete project with children!"); - } - } - - @Override - public Project getEntity() { - return new ProjectJpaController(getEntityManagerFactory()) - .findProject(getId()); - } - - @Override - public void update(Project target, Project source) { - target.setNotes(source.getNotes()); - target.setName(source.getName()); - target.setParentProjectId(source.getParentProjectId()); - target.setProjectList(source.getProjectList()); - target.setRequirementSpecList(source.getRequirementSpecList()); - target.setTestProjectList(source.getTestProjectList()); - target.setId(source.getId()); - super.update(target, source); - } - - public static List getProjects() { - return new ProjectJpaController(getEntityManagerFactory()) - .findProjectEntities(); - } - - public List getChildren() { - ArrayList children = new ArrayList<>(); - getProjects().stream().filter((p) - -> (p.getParentProjectId() != null)).filter((p) - -> (p.getParentProjectId().getId().equals(getId()))) - .forEachOrdered((p) -> { - children.add(p); - }); - return children; - } - - @Override - public void update() { - update(this, getEntity()); - } - - public void copy(Project newProject) { - update(this, newProject); - } - - /** - * Get the Test Projects for this project. - * - * @return Test projects for this project. - */ - public List getTestProjects() { - return getTestProjects(false); - } - - /** - * Get the Test Projects for this project. - * - * @param includeSubProjects true to include the sub projects as well. - * - * @return Test projects for this project. - */ - public List getTestProjects(boolean includeSubProjects) { - List tps = new ArrayList<>(); - tps.addAll(getTestProjectList()); - if (includeSubProjects) { - for (Project p : getProjectList()) { - tps.addAll(new ProjectServer(p) - .getTestProjects(includeSubProjects)); - } - } - return tps; - } -} +package com.validation.manager.core.server.core; + +import static com.validation.manager.core.DataBaseManager.getEntityManagerFactory; +import com.validation.manager.core.EntityServer; +import com.validation.manager.core.VMException; +import com.validation.manager.core.db.Project; +import com.validation.manager.core.db.TestProject; +import com.validation.manager.core.db.controller.ProjectJpaController; +import java.util.ArrayList; +import java.util.List; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public final class ProjectServer extends Project + implements EntityServer, VersionableServer { + + private static final long serialVersionUID = 3_434_510_483_033_583_117L; + + public ProjectServer(String name, String notes) { + super(name); + setNotes(notes); + setProjectList(new ArrayList<>()); + setRequirementSpecList(new ArrayList<>()); + setTestProjectList(new ArrayList<>()); + } + + public ProjectServer(int id) { + Project product = new ProjectJpaController( + getEntityManagerFactory()).findProject(id); + update((ProjectServer) this, product); + } + + public ProjectServer(Project p) { + Project product = new ProjectJpaController( + getEntityManagerFactory()).findProject(p.getId()); + update((ProjectServer) this, product); + } + + @Override + public int write2DB() throws VMException { + try { + Project p; + if (getId() == null) { + p = new Project(getName()); + update(p, this); + new ProjectJpaController(getEntityManagerFactory()).create(p); + setId(p.getId()); + } else { + p = getEntity(); + update(p, this); + new ProjectJpaController(getEntityManagerFactory()).edit(p); + } + } + catch (Exception ex) { + throw new VMException(ex); + } + return getId(); + } + + @Override + public Project getEntity() { + return new ProjectJpaController(getEntityManagerFactory()) + .findProject(getId()); + } + + @Override + public void update(Project target, Project source) { + target.setNotes(source.getNotes()); + target.setName(source.getName()); + target.setParentProjectId(source.getParentProjectId()); + target.setProjectList(source.getProjectList()); + target.setRequirementSpecList(source.getRequirementSpecList()); + target.setTestProjectList(source.getTestProjectList()); + target.setId(source.getId()); + super.update(target, source); + } + + public static List getProjects() { + return new ProjectJpaController(getEntityManagerFactory()) + .findProjectEntities(); + } + + public List getChildren() { + ArrayList children = new ArrayList<>(); + getProjects().stream().filter((p) + -> (p.getParentProjectId() != null)).filter((p) + -> (p.getParentProjectId().getId().equals(getId()))) + .forEachOrdered((p) -> { + children.add(p); + }); + return children; + } + + @Override + public void update() { + update(this, getEntity()); + } + + public void copy(Project newProject) { + update(this, newProject); + } + + /** + * Get the Test Projects for this project. + * + * @return Test projects for this project. + */ + public List getTestProjects() { + return getTestProjects(false); + } + + /** + * Get the Test Projects for this project. + * + * @param includeSubProjects true to include the sub projects as well. + * + * @return Test projects for this project. + */ + public List getTestProjects(boolean includeSubProjects) { + List tps = new ArrayList<>(); + tps.addAll(getTestProjectList()); + if (includeSubProjects) { + for (Project p : getProjectList()) { + tps.addAll(new ProjectServer(p) + .getTestProjects(includeSubProjects)); + } + } + return tps; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/server/core/RequirementStatusServer.java b/VM-Core/src/main/java/com/validation/manager/core/server/core/RequirementStatusServer.java index 81313879..963bc3fd 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/server/core/RequirementStatusServer.java +++ b/VM-Core/src/main/java/com/validation/manager/core/server/core/RequirementStatusServer.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,65 +13,69 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.server.core; - -import static com.validation.manager.core.DataBaseManager.getEntityManagerFactory; -import com.validation.manager.core.EntityServer; -import com.validation.manager.core.db.RequirementStatus; -import com.validation.manager.core.db.controller.RequirementStatusJpaController; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public final class RequirementStatusServer extends RequirementStatus - implements EntityServer { - - public RequirementStatusServer(Integer id) { - RequirementStatusJpaController controller - = new RequirementStatusJpaController( - getEntityManagerFactory()); - RequirementStatus rs = controller.findRequirementStatus(id); - if (rs != null) { - update(RequirementStatusServer.this, rs); - } - } - - @Override - public int write2DB() throws Exception { - RequirementStatus p; - RequirementStatusJpaController controller - = new RequirementStatusJpaController( - getEntityManagerFactory()); - if (getId() > 0) { - p = controller.findRequirementStatus(getId()); - update(p, this); - controller.edit(p); - } else { - p = new RequirementStatus(getStatus()); - update(p, this); - controller.create(p); - setId(p.getId()); - } - return getId(); - } - - @Override - public RequirementStatus getEntity() { - return new RequirementStatusJpaController( - getEntityManagerFactory()) - .findRequirementStatus(getId()); - } - - @Override - public void update(RequirementStatus target, RequirementStatus source) { - target.setId(source.getId()); - target.setStatus(source.getStatus()); - target.setRequirementList(source.getRequirementList()); - } - - @Override - public void update() { - update(this, getEntity()); - } -} +package com.validation.manager.core.server.core; + +import static com.validation.manager.core.DataBaseManager.getEntityManagerFactory; +import com.validation.manager.core.EntityServer; +import com.validation.manager.core.db.RequirementStatus; +import com.validation.manager.core.db.controller.RequirementStatusJpaController; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public final class RequirementStatusServer extends RequirementStatus + implements EntityServer { + + public RequirementStatusServer(Integer id) { + RequirementStatusJpaController controller + = new RequirementStatusJpaController( + getEntityManagerFactory()); + RequirementStatus rs = controller.findRequirementStatus(id); + if (rs != null) { + update(RequirementStatusServer.this, rs); + } + } + + public RequirementStatusServer(String status) { + super(status); + } + + @Override + public int write2DB() throws Exception { + RequirementStatus p; + RequirementStatusJpaController controller + = new RequirementStatusJpaController( + getEntityManagerFactory()); + if (getId() == null) { + p = new RequirementStatus(getStatus()); + update(p, this); + controller.create(p); + setId(p.getId()); + } else { + p = controller.findRequirementStatus(getId()); + update(p, this); + controller.edit(p); + } + return getId(); + } + + @Override + public RequirementStatus getEntity() { + return new RequirementStatusJpaController( + getEntityManagerFactory()) + .findRequirementStatus(getId()); + } + + @Override + public void update(RequirementStatus target, RequirementStatus source) { + target.setId(source.getId()); + target.setStatus(source.getStatus()); + target.setRequirementList(source.getRequirementList()); + } + + @Override + public void update() { + update(this, getEntity()); + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/server/core/RequirementTypeServer.java b/VM-Core/src/main/java/com/validation/manager/core/server/core/RequirementTypeServer.java index 24f80b0c..2cce6640 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/server/core/RequirementTypeServer.java +++ b/VM-Core/src/main/java/com/validation/manager/core/server/core/RequirementTypeServer.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,75 +13,77 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.server.core; - -import static com.validation.manager.core.DataBaseManager.getEntityManagerFactory; -import com.validation.manager.core.EntityServer; -import com.validation.manager.core.db.RequirementType; -import com.validation.manager.core.db.controller.RequirementTypeJpaController; -import java.util.ArrayList; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public final class RequirementTypeServer extends RequirementType - implements EntityServer { - - public RequirementTypeServer(RequirementType rt) { - RequirementType temp - = new RequirementTypeJpaController( - getEntityManagerFactory()) - .findRequirementType(rt.getId()); - update((RequirementType) this, temp); - } - - public RequirementTypeServer(String name) { - super(name); - setId(0); - setRequirementList(new ArrayList<>()); - } - - @Override - public int write2DB() throws Exception { - RequirementType rt; - if (getId() > 0) { - rt = new RequirementTypeJpaController(getEntityManagerFactory()).findRequirementType(getId()); - update(rt, this); - new RequirementTypeJpaController(getEntityManagerFactory()).edit(rt); - } else { - rt = new RequirementType(getName()); - update(rt, this); - new RequirementTypeJpaController(getEntityManagerFactory()).create(rt); - setId(rt.getId()); - } - return getId(); - } - - @Override - public RequirementType getEntity() { - return new RequirementTypeJpaController( - getEntityManagerFactory()) - .findRequirementType(getId()); - } - - @Override - public void update(RequirementType target, RequirementType source) { - target.setDescription(source.getDescription()); - target.setName(source.getName()); - target.setId(source.getId()); - target.setRequirementList(source.getRequirementList()); - target.setLevel(source.getLevel()); - } - - @Override - public void update() { - update(this, getEntity()); - } - - public static Iterable getRequirementTypes() { - return new RequirementTypeJpaController( - getEntityManagerFactory()) - .findRequirementTypeEntities(); - } -} +package com.validation.manager.core.server.core; + +import static com.validation.manager.core.DataBaseManager.getEntityManagerFactory; +import com.validation.manager.core.EntityServer; +import com.validation.manager.core.db.RequirementType; +import com.validation.manager.core.db.controller.RequirementTypeJpaController; +import java.util.ArrayList; +import java.util.List; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public final class RequirementTypeServer extends RequirementType + implements EntityServer { + + public RequirementTypeServer(RequirementType rt) { + RequirementType temp + = new RequirementTypeJpaController( + getEntityManagerFactory()) + .findRequirementType(rt.getId()); + update((RequirementType) this, temp); + } + + public RequirementTypeServer(String name) { + super(name); + setId(0); + setRequirementList(new ArrayList<>()); + } + + @Override + public int write2DB() throws Exception { + RequirementType rt; + if (getId() > 0) { + rt = new RequirementTypeJpaController(getEntityManagerFactory()).findRequirementType(getId()); + update(rt, this); + new RequirementTypeJpaController(getEntityManagerFactory()).edit(rt); + } else { + rt = new RequirementType(getName()); + update(rt, this); + new RequirementTypeJpaController(getEntityManagerFactory()).create(rt); + setId(rt.getId()); + } + update(); + return getId(); + } + + @Override + public RequirementType getEntity() { + return new RequirementTypeJpaController( + getEntityManagerFactory()) + .findRequirementType(getId()); + } + + @Override + public void update(RequirementType target, RequirementType source) { + target.setDescription(source.getDescription()); + target.setName(source.getName()); + target.setId(source.getId()); + target.setRequirementList(source.getRequirementList()); + target.setLevel(source.getLevel()); + } + + @Override + public void update() { + update(this, getEntity()); + } + + public static List getRequirementTypes() { + return new RequirementTypeJpaController( + getEntityManagerFactory()) + .findRequirementTypeEntities(); + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/server/core/ReviewResultServer.java b/VM-Core/src/main/java/com/validation/manager/core/server/core/ReviewResultServer.java index e7ad759e..e391f98c 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/server/core/ReviewResultServer.java +++ b/VM-Core/src/main/java/com/validation/manager/core/server/core/ReviewResultServer.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,69 +13,78 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.server.core; - -import com.validation.manager.core.DataBaseManager; -import com.validation.manager.core.EntityServer; -import com.validation.manager.core.db.ReviewResult; -import com.validation.manager.core.db.controller.ReviewResultJpaController; -import java.util.List; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class ReviewResultServer extends ReviewResult - implements EntityServer { - - public static ReviewResult getReview(String review) { - PARAMETERS.clear(); - PARAMETERS.put("reviewName", review); - List r = DataBaseManager.namedQuery("ReviewResult.findByReviewName", - PARAMETERS); - if (r.isEmpty()) { - return null; - } else { - return (ReviewResult) r.get(0); - } - } - - @Override - public int write2DB() throws Exception { - ReviewResultJpaController c - = new ReviewResultJpaController(DataBaseManager - .getEntityManagerFactory()); - if (getId() == null) { - ReviewResult rr = new ReviewResult(); - update(rr, this); - c.create(rr); - update(this, rr); - } else { - ReviewResult rr = getEntity(); - update(rr, this); - c.edit(rr); - update(this, rr); - } - return getId(); - } - - @Override - public ReviewResult getEntity() { - ReviewResultJpaController c - = new ReviewResultJpaController(DataBaseManager - .getEntityManagerFactory()); - return c.findReviewResult(getId()); - } - - @Override - public void update(ReviewResult target, ReviewResult source) { - target.setExecutionStepList(source.getExecutionStepList()); - target.setId(source.getId()); - target.setReviewName(source.getReviewName()); - } - - @Override - public void update() { - update(this, getEntity()); - } -} +package com.validation.manager.core.server.core; + +import com.validation.manager.core.DataBaseManager; +import com.validation.manager.core.EntityServer; +import com.validation.manager.core.db.ReviewResult; +import com.validation.manager.core.db.controller.ReviewResultJpaController; +import java.util.List; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class ReviewResultServer extends ReviewResult + implements EntityServer { + + public ReviewResultServer(int id) { + setId(id); + update(); + } + + public ReviewResultServer(String reviewName) { + super(reviewName); + } + + public static ReviewResult getReview(String review) { + PARAMETERS.clear(); + PARAMETERS.put("reviewName", review); + List r = DataBaseManager.namedQuery("ReviewResult.findByReviewName", + PARAMETERS); + if (r.isEmpty()) { + return null; + } else { + return (ReviewResult) r.get(0); + } + } + + @Override + public int write2DB() throws Exception { + ReviewResultJpaController c + = new ReviewResultJpaController(DataBaseManager + .getEntityManagerFactory()); + if (getId() == null) { + ReviewResult rr = new ReviewResult(); + update(rr, this); + c.create(rr); + update(this, rr); + } else { + ReviewResult rr = getEntity(); + update(rr, this); + c.edit(rr); + update(this, rr); + } + return getId(); + } + + @Override + public ReviewResult getEntity() { + ReviewResultJpaController c + = new ReviewResultJpaController(DataBaseManager + .getEntityManagerFactory()); + return c.findReviewResult(getId()); + } + + @Override + public void update(ReviewResult target, ReviewResult source) { + target.setExecutionStepList(source.getExecutionStepList()); + target.setId(source.getId()); + target.setReviewName(source.getReviewName()); + } + + @Override + public void update() { + update(this, getEntity()); + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/server/core/RiskControlServer.java b/VM-Core/src/main/java/com/validation/manager/core/server/core/RiskControlServer.java index 70a4e191..8d4d8a3a 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/server/core/RiskControlServer.java +++ b/VM-Core/src/main/java/com/validation/manager/core/server/core/RiskControlServer.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,97 +13,98 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.server.core; - -import static com.validation.manager.core.DataBaseManager.getEntityManagerFactory; -import com.validation.manager.core.EntityServer; -import com.validation.manager.core.db.RiskControl; -import com.validation.manager.core.db.RiskControlPK; -import com.validation.manager.core.db.controller.RiskControlJpaController; -import com.validation.manager.core.db.controller.RiskControlTypeJpaController; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import java.util.logging.Level; -import static java.util.logging.Logger.getLogger; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public final class RiskControlServer extends RiskControl - implements EntityServer { - - public RiskControlServer(RiskControlPK riskControlPK) { - super(riskControlPK); - setRiskControlType(new RiskControlTypeJpaController( - getEntityManagerFactory()).findRiskControlType( - riskControlPK.getRiskControlTypeId())); - } - - public RiskControlServer(RiskControl riskControl) { - super(riskControl.getRiskControlPK()); - setRiskControlType(new RiskControlTypeJpaController( - getEntityManagerFactory()).findRiskControlType( - riskControlPK.getRiskControlTypeId())); - } - - public RiskControlServer(int riskControlTypeId) { - super(new RiskControlPK(riskControlTypeId)); - setRiskControlType(new RiskControlTypeJpaController( - getEntityManagerFactory()).findRiskControlType(riskControlTypeId)); - } - - @Override - public int write2DB() throws NonexistentEntityException, Exception { - RiskControlJpaController controller - = new RiskControlJpaController(getEntityManagerFactory()); - if (getRiskControlPK().getId() > 0) { - RiskControl target = controller.findRiskControl(getRiskControlPK()); - update(target, this); - controller.edit(target); - } else { - RiskControl target = new RiskControl(getRiskControlPK()); - update(target, this); - controller.create(target); - setRiskControlPK(target.getRiskControlPK()); - } - return getRiskControlPK().getId(); - } - - public static boolean deleteRiskControl(RiskControl rc) { - try { - new RiskControlJpaController( - getEntityManagerFactory()) - .destroy(rc.getRiskControlPK()); - return true; - } - catch (NonexistentEntityException | IllegalOrphanException ex) { - getLogger(RiskControlServer.class.getName()).log( - Level.SEVERE, null, ex); - } - return false; - } - - @Override - public RiskControl getEntity() { - return new RiskControlJpaController( - getEntityManagerFactory()) - .findRiskControl(getRiskControlPK()); - } - - @Override - public void update(RiskControl target, RiskControl source) { - target.setRiskControlHasRequirementList(source - .getRiskControlHasRequirementList()); - target.setRiskControlHasTestCaseList(source - .getRiskControlHasTestCaseList()); - target.setRiskItemList(source.getRiskItemList()); - target.setRiskItemList1(source.getRiskItemList1()); - target.setRiskControlType(source.getRiskControlType()); - } - - @Override - public void update() { - update(this, getEntity()); - } -} +package com.validation.manager.core.server.core; + +import static com.validation.manager.core.DataBaseManager.getEntityManagerFactory; +import com.validation.manager.core.EntityServer; +import com.validation.manager.core.db.RiskControl; +import com.validation.manager.core.db.RiskControlPK; +import com.validation.manager.core.db.controller.RiskControlJpaController; +import com.validation.manager.core.db.controller.RiskControlTypeJpaController; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import java.util.logging.Level; +import static java.util.logging.Logger.getLogger; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public final class RiskControlServer extends RiskControl + implements EntityServer { + + public RiskControlServer(RiskControlPK riskControlPK) { + super(riskControlPK); + setRiskControlType(new RiskControlTypeJpaController( + getEntityManagerFactory()).findRiskControlType( + riskControlPK.getRiskControlTypeId())); + update(); + } + + public RiskControlServer(RiskControl riskControl) { + super(riskControl.getRiskControlPK()); + setRiskControlType(new RiskControlTypeJpaController( + getEntityManagerFactory()).findRiskControlType( + riskControlPK.getRiskControlTypeId())); + } + + public RiskControlServer(int riskControlTypeId) { + super(new RiskControlPK(riskControlTypeId)); + setRiskControlType(new RiskControlTypeJpaController( + getEntityManagerFactory()).findRiskControlType(riskControlTypeId)); + } + + @Override + public int write2DB() throws NonexistentEntityException, Exception { + RiskControlJpaController controller + = new RiskControlJpaController(getEntityManagerFactory()); + if (getRiskControlPK().getId() > 0) { + RiskControl target = controller.findRiskControl(getRiskControlPK()); + update(target, this); + controller.edit(target); + } else { + RiskControl target = new RiskControl(getRiskControlPK()); + update(target, this); + controller.create(target); + setRiskControlPK(target.getRiskControlPK()); + } + return getRiskControlPK().getId(); + } + + public static boolean deleteRiskControl(RiskControl rc) { + try { + new RiskControlJpaController( + getEntityManagerFactory()) + .destroy(rc.getRiskControlPK()); + return true; + } + catch (NonexistentEntityException | IllegalOrphanException ex) { + getLogger(RiskControlServer.class.getName()).log( + Level.SEVERE, null, ex); + } + return false; + } + + @Override + public RiskControl getEntity() { + return new RiskControlJpaController( + getEntityManagerFactory()) + .findRiskControl(getRiskControlPK()); + } + + @Override + public void update(RiskControl target, RiskControl source) { + target.setRiskControlHasRequirementList(source + .getRiskControlHasRequirementList()); + target.setRiskControlHasTestCaseList(source + .getRiskControlHasTestCaseList()); + target.setRiskItemList(source.getRiskItemList()); + target.setRiskItemList1(source.getRiskItemList1()); + target.setRiskControlType(source.getRiskControlType()); + } + + @Override + public void update() { + update(this, getEntity()); + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/server/core/RoleServer.java b/VM-Core/src/main/java/com/validation/manager/core/server/core/RoleServer.java index 1d55e1e2..c3609ea5 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/server/core/RoleServer.java +++ b/VM-Core/src/main/java/com/validation/manager/core/server/core/RoleServer.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,76 +13,84 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.server.core; - -import com.validation.manager.core.DataBaseManager; -import com.validation.manager.core.EntityServer; -import com.validation.manager.core.db.Role; -import com.validation.manager.core.db.controller.RoleJpaController; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public final class RoleServer extends Role implements EntityServer { - - private static final Map PARAMETERS = new HashMap<>(); - private final RoleJpaController c - = new RoleJpaController(DataBaseManager.getEntityManagerFactory()); - - public RoleServer(String description) { - super(description); - update(RoleServer.this, getRole(description)); - } - - public static Role getRole(String role) { - Role r = null; - PARAMETERS.clear(); - PARAMETERS.put("name", role); - List result = DataBaseManager.namedQuery("Role.findByName", - PARAMETERS); - if (!result.isEmpty()) { - r = (Role) result.get(0); - } - return r; - } - - @Override - public int write2DB() throws Exception { - if (getId() == null) { - Role r = new Role(); - update(r, this); - c.create(r); - update(this, r); - } else { - Role r = getEntity(); - update(r, this); - c.edit(r); - update(this, r); - } - return getId(); - } - - @Override - public void update() { - update(RoleServer.this, getEntity()); - } - - @Override - public Role getEntity() { - return getId() == null ? null : c.findRole(getId()); - } - - @Override - public void update(Role target, Role source) { - target.setDescription(source.getDescription()); - target.setId(source.getId()); - target.setRoleName(source.getRoleName()); - target.setUserRightList(source.getUserRightList()); - target.setUserTestPlanRoleList(source.getUserTestPlanRoleList()); - target.setVmUserList(source.getVmUserList()); - } -} +package com.validation.manager.core.server.core; + +import com.validation.manager.core.DataBaseManager; +import com.validation.manager.core.EntityServer; +import com.validation.manager.core.VMException; +import com.validation.manager.core.db.Role; +import com.validation.manager.core.db.controller.RoleJpaController; +import java.util.List; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public final class RoleServer extends Role implements EntityServer { + + private final RoleJpaController c + = new RoleJpaController(DataBaseManager.getEntityManagerFactory()); + + public RoleServer(int id) { + setId(id); + update(); + } + + public RoleServer(String description) { + super(description); + update(RoleServer.this, getRole(description)); + } + + public static Role getRole(String role) { + Role r = null; + PARAMETERS.clear(); + PARAMETERS.put("name", role); + List result = DataBaseManager.namedQuery("Role.findByName", + PARAMETERS); + if (!result.isEmpty()) { + r = (Role) result.get(0); + } + return r; + } + + @Override + public int write2DB() throws VMException { + try { + if (getId() == null) { + Role r = new Role(); + update(r, this); + c.create(r); + update(this, r); + } else { + Role r = getEntity(); + update(r, this); + c.edit(r); + update(this, r); + } + } + catch (Exception ex) { + throw new VMException(ex); + } + return getId(); + } + + @Override + public void update() { + update(RoleServer.this, getEntity()); + } + + @Override + public Role getEntity() { + return getId() == null ? null : c.findRole(getId()); + } + + @Override + public void update(Role target, Role source) { + target.setDescription(source.getDescription()); + target.setId(source.getId()); + target.setRoleName(source.getRoleName()); + target.setUserRightList(source.getUserRightList()); + target.setUserTestPlanRoleList(source.getUserTestPlanRoleList()); + target.setVmUserList(source.getVmUserList()); + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/server/core/TestCaseExecutionServer.java b/VM-Core/src/main/java/com/validation/manager/core/server/core/TestCaseExecutionServer.java index 504832a6..ce704eab 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/server/core/TestCaseExecutionServer.java +++ b/VM-Core/src/main/java/com/validation/manager/core/server/core/TestCaseExecutionServer.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,214 +13,214 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.server.core; - -import com.validation.manager.core.DataBaseManager; -import com.validation.manager.core.EntityServer; -import com.validation.manager.core.db.ExecutionStep; -import com.validation.manager.core.db.Project; -import com.validation.manager.core.db.TestCase; -import com.validation.manager.core.db.TestCaseExecution; -import com.validation.manager.core.db.TestPlan; -import com.validation.manager.core.db.TestProject; -import com.validation.manager.core.db.controller.ExecutionStepJpaController; -import com.validation.manager.core.db.controller.TestCaseExecutionJpaController; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import java.util.ArrayList; -import java.util.List; -import java.util.Objects; -import org.openide.util.Exceptions; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public final class TestCaseExecutionServer extends TestCaseExecution - implements EntityServer { - - public TestCaseExecutionServer(String name, String scope) { - super(name, scope); - } - - public TestCaseExecutionServer(int id) { - super.setId(id); - update(); - } - - public TestCaseExecutionServer(TestCaseExecution tce) { - super.setId(tce.getId()); - update(); - } - - public TestCaseExecutionServer() { - } - - /** - * Add a Test Case to this execution. - * - * @param tc Test Case to add - */ - public void addTestCase(TestCase tc) { - try { - ExecutionStepJpaController econtroller - = new ExecutionStepJpaController(DataBaseManager - .getEntityManagerFactory()); - tc.getStepList().forEach((s) -> { - ExecutionStep es = new ExecutionStep(getId(), - s.getStepPK().getId(), s.getStepPK().getTestCaseId()); - es.setStep(s); - es.setStepHistory(s.getHistoryList() - .get(s.getHistoryList().size() - 1)); - es.setTestCaseExecution(getEntity()); - try { - econtroller.create(es); - getExecutionStepList().add(es); - } - catch (Exception ex) { - Exceptions.printStackTrace(ex); - } - }); - write2DB(); - } - catch (Exception ex) { - Exceptions.printStackTrace(ex); - } - } - - @Override - public int write2DB() throws Exception { - TestCaseExecutionJpaController controller - = new TestCaseExecutionJpaController(DataBaseManager - .getEntityManagerFactory()); - TestCaseExecution tce; - if (getId() == null) { - //New one - tce = new TestCaseExecution(); - update(tce, this); - controller.create(tce); - setId(tce.getId()); - } else { - tce = controller.findTestCaseExecution(getId()); - update(tce, this); - controller.edit(tce); - } - update(); - return getId(); - } - - @Override - public TestCaseExecution getEntity() { - return new TestCaseExecutionJpaController(DataBaseManager - .getEntityManagerFactory()).findTestCaseExecution(getId()); - } - - @Override - public void update(TestCaseExecution target, TestCaseExecution source) { - target.setConclusion(source.getConclusion()); - target.setId(source.getId()); - target.setScope(source.getScope()); - target.setName(source.getName()); - if (target.getExecutionStepList() == null) { - target.setExecutionStepList(new ArrayList<>()); - } else { - target.getExecutionStepList().clear(); - } - if (source.getExecutionStepList() != null) { - source.getExecutionStepList().forEach((es) -> { - target.getExecutionStepList().add(es); - }); - } - } - - @Override - public void update() { - update(this, getEntity()); - } - - /** - * Add a complete Test Project to the execution. - * - * @param tp Test Project to add - */ - public void addTestProject(TestProject tp) { - tp.getTestPlanList().forEach((plan) -> { - addTestPlan(plan); - }); - } - - /** - * Add a complete Test Plan to the execution. - * - * @param plan Test Plan to add - */ - private void addTestPlan(TestPlan plan) { - plan.getTestCaseList().forEach((tc) -> { - addTestCase(tc); - }); - } - - /** - * List of Executions for the provided project. - * - * @param p project to look into. - * @return List of Executions for the provided project. - */ - public static List getExecutions(Project p) { - List results = new ArrayList<>(); - p.getTestProjectList().forEach(tp -> { - tp.getTestPlanList().forEach(plan -> { - plan.getTestCaseList().forEach(tc -> { - tc.getStepList().forEach(s -> { - s.getExecutionStepList().forEach(es -> { - results.add(es.getTestCaseExecution()); - }); - }); - }); - }); - }); - return results; - } - - public void removeTestCase(TestCase tc) throws Exception { - List toDelete = new ArrayList<>(); - getExecutionStepList().forEach(es -> { - if (Objects.equals(es.getStep().getTestCase() - .getId(), tc.getId())) { - //Same test case - toDelete.add(es); - } - }); - getExecutionStepList().removeAll(toDelete); - ExecutionStepJpaController c - = new ExecutionStepJpaController(DataBaseManager - .getEntityManagerFactory()); - toDelete.forEach(es -> { - try { - ExecutionStepServer ess = new ExecutionStepServer(es); - ess.getExecutionStepHasAttachmentList().forEach(att -> { - try { - ess.removeAttachment(att.getAttachment()); - } - catch (Exception ex) { - Exceptions.printStackTrace(ex); - } - }); - ess.getExecutionStepHasIssueList().forEach(issue -> { - try { - ess.removeIssue(issue.getIssue()); - } - catch (NonexistentEntityException ex) { - Exceptions.printStackTrace(ex); - } - }); - ess.getEntity(); - c.destroy(ess.getExecutionStepPK()); - } - catch (IllegalOrphanException | NonexistentEntityException ex) { - Exceptions.printStackTrace(ex); - } - }); - write2DB(); - } -} +package com.validation.manager.core.server.core; + +import com.validation.manager.core.DataBaseManager; +import com.validation.manager.core.EntityServer; +import com.validation.manager.core.db.ExecutionStep; +import com.validation.manager.core.db.Project; +import com.validation.manager.core.db.TestCase; +import com.validation.manager.core.db.TestCaseExecution; +import com.validation.manager.core.db.TestPlan; +import com.validation.manager.core.db.TestProject; +import com.validation.manager.core.db.controller.ExecutionStepJpaController; +import com.validation.manager.core.db.controller.TestCaseExecutionJpaController; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import java.util.ArrayList; +import java.util.List; +import java.util.Objects; +import org.openide.util.Exceptions; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public final class TestCaseExecutionServer extends TestCaseExecution + implements EntityServer { + + public TestCaseExecutionServer(String name, String scope) { + super(name, scope); + } + + public TestCaseExecutionServer(int id) { + super.setId(id); + update(); + } + + public TestCaseExecutionServer(TestCaseExecution tce) { + super.setId(tce.getId()); + update(); + } + + public TestCaseExecutionServer() { + } + + /** + * Add a Test Case to this execution. + * + * @param tc Test Case to add + */ + public void addTestCase(TestCase tc) { + try { + ExecutionStepJpaController econtroller + = new ExecutionStepJpaController(DataBaseManager + .getEntityManagerFactory()); + tc.getStepList().forEach((s) -> { + ExecutionStep es = new ExecutionStep(getId(), + s.getStepPK().getId(), s.getStepPK().getTestCaseId()); + es.setStep(s); + es.setStepHistory(s.getHistoryList() + .get(s.getHistoryList().size() - 1)); + es.setTestCaseExecution(getEntity()); + try { + econtroller.create(es); + getExecutionStepList().add(es); + } + catch (Exception ex) { + Exceptions.printStackTrace(ex); + } + }); + write2DB(); + } + catch (Exception ex) { + Exceptions.printStackTrace(ex); + } + } + + @Override + public int write2DB() throws Exception { + TestCaseExecutionJpaController controller + = new TestCaseExecutionJpaController(DataBaseManager + .getEntityManagerFactory()); + TestCaseExecution tce; + if (getId() == null) { + //New one + tce = new TestCaseExecution(); + update(tce, this); + controller.create(tce); + setId(tce.getId()); + } else { + tce = controller.findTestCaseExecution(getId()); + update(tce, this); + controller.edit(tce); + } + update(); + return getId(); + } + + @Override + public TestCaseExecution getEntity() { + return new TestCaseExecutionJpaController(DataBaseManager + .getEntityManagerFactory()).findTestCaseExecution(getId()); + } + + @Override + public void update(TestCaseExecution target, TestCaseExecution source) { + target.setConclusion(source.getConclusion()); + target.setId(source.getId()); + target.setScope(source.getScope()); + target.setName(source.getName()); + if (target.getExecutionStepList() == null) { + target.setExecutionStepList(new ArrayList<>()); + } else { + target.getExecutionStepList().clear(); + } + if (source.getExecutionStepList() != null) { + source.getExecutionStepList().forEach((es) -> { + target.getExecutionStepList().add(es); + }); + } + } + + @Override + public void update() { + update(this, getEntity()); + } + + /** + * Add a complete Test Project to the execution. + * + * @param tp Test Project to add + */ + public void addTestProject(TestProject tp) { + tp.getTestPlanList().forEach((plan) -> { + addTestPlan(plan); + }); + } + + /** + * Add a complete Test Plan to the execution. + * + * @param plan Test Plan to add + */ + private void addTestPlan(TestPlan plan) { + plan.getTestCaseList().forEach((tc) -> { + addTestCase(tc); + }); + } + + /** + * List of Executions for the provided project. + * + * @param p project to look into. + * @return List of Executions for the provided project. + */ + public static List getExecutions(Project p) { + List results = new ArrayList<>(); + p.getTestProjectList().forEach(tp -> { + tp.getTestPlanList().forEach(plan -> { + plan.getTestCaseList().forEach(tc -> { + tc.getStepList().forEach(s -> { + s.getExecutionStepList().forEach(es -> { + results.add(es.getTestCaseExecution()); + }); + }); + }); + }); + }); + return results; + } + + public void removeTestCase(TestCase tc) throws Exception { + List toDelete = new ArrayList<>(); + getExecutionStepList().forEach(es -> { + if (Objects.equals(es.getStep().getTestCase() + .getId(), tc.getId())) { + //Same test case + toDelete.add(es); + } + }); + getExecutionStepList().removeAll(toDelete); + ExecutionStepJpaController c + = new ExecutionStepJpaController(DataBaseManager + .getEntityManagerFactory()); + toDelete.forEach(es -> { + try { + ExecutionStepServer ess = new ExecutionStepServer(es); + ess.getExecutionStepHasAttachmentList().forEach(att -> { + try { + ess.removeAttachment(att.getAttachment()); + } + catch (Exception ex) { + Exceptions.printStackTrace(ex); + } + }); + ess.getExecutionStepHasIssueList().forEach(issue -> { + try { + ess.removeIssue(issue.getIssue()); + } + catch (NonexistentEntityException ex) { + Exceptions.printStackTrace(ex); + } + }); + ess.getEntity(); + c.destroy(ess.getExecutionStepPK()); + } + catch (IllegalOrphanException | NonexistentEntityException ex) { + Exceptions.printStackTrace(ex); + } + }); + write2DB(); + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/server/core/TestCaseServer.java b/VM-Core/src/main/java/com/validation/manager/core/server/core/TestCaseServer.java index ca1b5a1f..4f034766 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/server/core/TestCaseServer.java +++ b/VM-Core/src/main/java/com/validation/manager/core/server/core/TestCaseServer.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,107 +13,107 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.server.core; - -import static com.validation.manager.core.DataBaseManager.getEntityManagerFactory; -import com.validation.manager.core.EntityServer; -import com.validation.manager.core.db.Requirement; -import com.validation.manager.core.db.Step; -import com.validation.manager.core.db.TestCase; -import com.validation.manager.core.db.controller.TestCaseJpaController; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import com.validation.manager.core.db.controller.exceptions.PreexistingEntityException; -import java.util.ArrayList; -import java.util.Date; -import java.util.List; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public final class TestCaseServer extends TestCase - implements EntityServer { - - public TestCaseServer(int id) { - super(id); - update(); - } - - public TestCaseServer(TestCase tc) { - super.setId(tc.getId()); - update(); - } - - public TestCaseServer(String name, Date creationDate) { - super(name, creationDate); - } - - @Override - public int write2DB() throws IllegalOrphanException, - NonexistentEntityException, Exception { - TestCaseJpaController controller - = new TestCaseJpaController(getEntityManagerFactory()); - if (getId() != null && getId() > 0) { - TestCase temp = controller.findTestCase(getId()); - update(temp, this); - controller.edit(temp); - } else { - TestCase temp = new TestCase(getName(), getCreationDate()); - temp.setCreationDate(new Date()); - controller.create(temp); - setId(temp.getId()); - } - update(); - return getId(); - } - - @Override - public TestCase getEntity() { - return new TestCaseJpaController(getEntityManagerFactory()) - .findTestCase(getId()); - } - - @Override - public void update(TestCase target, TestCase source) { - target.setActive(source.getActive()); - target.setCreationDate(source.getCreationDate()); - target.setRiskControlHasTestCaseList(source - .getRiskControlHasTestCaseList()); - target.setStepList(source.getStepList() == null - ? new ArrayList<>() : source.getStepList()); - target.setIsOpen(source.getIsOpen()); - target.setSummary(source.getSummary()); - target.setTestPlanList(new ArrayList<>()); - target.setId(source.getId()); - target.setName(source.getName()); - target.setIsOpen(source.getIsOpen()); - } - - @Override - public void update() { - update(this, getEntity()); - } - - public Step addStep(int sequence, String text, String note, String criteria, - List requirements) - throws PreexistingEntityException, Exception { - StepServer ss = new StepServer(getEntity(), sequence, text); - int amount = getStepList().size(); - ss.setNotes(note); - ss.setExpectedResult(criteria.getBytes("UTF-8")); - if (ss.getRequirementList() == null) { - ss.setRequirementList(new ArrayList<>()); - } - ss.write2DB(); - if (requirements != null) { - requirements.forEach((req) -> { - ss.getRequirementList().add(req); - }); - } - ss.write2DB(); - update(); - assert getStepList().size() > amount; - return ss.getEntity(); - } -} +package com.validation.manager.core.server.core; + +import static com.validation.manager.core.DataBaseManager.getEntityManagerFactory; +import com.validation.manager.core.EntityServer; +import com.validation.manager.core.db.Requirement; +import com.validation.manager.core.db.Step; +import com.validation.manager.core.db.TestCase; +import com.validation.manager.core.db.controller.TestCaseJpaController; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import com.validation.manager.core.db.controller.exceptions.PreexistingEntityException; +import java.util.ArrayList; +import java.util.Date; +import java.util.List; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public final class TestCaseServer extends TestCase + implements EntityServer { + + public TestCaseServer(int id) { + super(id); + update(); + } + + public TestCaseServer(TestCase tc) { + super.setId(tc.getId()); + update(); + } + + public TestCaseServer(String name, Date creationDate) { + super(name, creationDate); + } + + @Override + public int write2DB() throws IllegalOrphanException, + NonexistentEntityException, Exception { + TestCaseJpaController controller + = new TestCaseJpaController(getEntityManagerFactory()); + if (getId() != null && getId() > 0) { + TestCase temp = controller.findTestCase(getId()); + update(temp, this); + controller.edit(temp); + } else { + TestCase temp = new TestCase(getName(), getCreationDate()); + temp.setCreationDate(new Date()); + controller.create(temp); + setId(temp.getId()); + } + update(); + return getId(); + } + + @Override + public TestCase getEntity() { + return new TestCaseJpaController(getEntityManagerFactory()) + .findTestCase(getId()); + } + + @Override + public void update(TestCase target, TestCase source) { + target.setActive(source.getActive()); + target.setCreationDate(source.getCreationDate()); + target.setRiskControlHasTestCaseList(source + .getRiskControlHasTestCaseList()); + target.setStepList(source.getStepList() == null + ? new ArrayList<>() : source.getStepList()); + target.setIsOpen(source.getIsOpen()); + target.setSummary(source.getSummary()); + target.setTestPlanList(new ArrayList<>()); + target.setId(source.getId()); + target.setName(source.getName()); + target.setIsOpen(source.getIsOpen()); + } + + @Override + public void update() { + update(this, getEntity()); + } + + public Step addStep(int sequence, String text, String note, String criteria, + List requirements) + throws PreexistingEntityException, Exception { + StepServer ss = new StepServer(getEntity(), sequence, text); + int amount = getStepList().size(); + ss.setNotes(note); + ss.setExpectedResult(criteria.getBytes("UTF-8")); + if (ss.getRequirementList() == null) { + ss.setRequirementList(new ArrayList<>()); + } + ss.write2DB(); + if (requirements != null) { + requirements.forEach((req) -> { + ss.getRequirementList().add(req); + }); + } + ss.write2DB(); + update(); + assert getStepList().size() > amount; + return ss.getEntity(); + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/server/core/TestPlanServer.java b/VM-Core/src/main/java/com/validation/manager/core/server/core/TestPlanServer.java index bc5410ca..d5901e00 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/server/core/TestPlanServer.java +++ b/VM-Core/src/main/java/com/validation/manager/core/server/core/TestPlanServer.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,134 +13,135 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.server.core; - -import static com.validation.manager.core.DataBaseManager.getEntityManagerFactory; -import com.validation.manager.core.EntityServer; -import com.validation.manager.core.db.Role; -import com.validation.manager.core.db.TestCase; -import com.validation.manager.core.db.TestPlan; -import com.validation.manager.core.db.TestProject; -import com.validation.manager.core.db.UserTestPlanRole; -import com.validation.manager.core.db.VmUser; -import com.validation.manager.core.db.controller.TestPlanJpaController; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import com.validation.manager.core.db.controller.exceptions.PreexistingEntityException; -import java.util.ArrayList; -import java.util.Objects; -import java.util.logging.Level; -import java.util.logging.Logger; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public final class TestPlanServer extends TestPlan - implements EntityServer { - - private final static Logger LOG - = Logger.getLogger(TestPlanServer.class.getName()); - - public TestPlanServer(TestPlan plan) { - super.setTestPlanPK(plan.getTestPlanPK()); - update(); - } - - public TestPlanServer(TestProject testProject, boolean active, - boolean isOpen) { - super(testProject, active, isOpen); - setTestProject(testProject); - setTestPlanList(new ArrayList<>()); - setUserTestPlanRoleList(new ArrayList<>()); - setTestCaseList(new ArrayList<>()); - } - - @Override - public int write2DB() throws IllegalOrphanException, - NonexistentEntityException, Exception { - TestPlanJpaController controller - = new TestPlanJpaController(getEntityManagerFactory()); - if (getTestPlanPK().getId() > 0) { - TestPlan temp = controller.findTestPlan(getTestPlanPK()); - update(temp, this); - controller.edit(temp); - } else { - TestPlan temp = new TestPlan(getTestProject(), getActive(), - getIsOpen()); - update(temp, this); - controller.create(temp); - setTestPlanPK(temp.getTestPlanPK()); - } - return getTestPlanPK().getId(); - } - - public static boolean deleteTestPlan(TestPlan tp) { - try { - new TestPlanJpaController(getEntityManagerFactory()) - .destroy(tp.getTestPlanPK()); - } - catch (IllegalOrphanException | NonexistentEntityException ex) { - LOG.log(Level.SEVERE, null, ex); - return false; - } - return true; - } - - public boolean addTestCase(TestCase test) { - try { - getTestCaseList().add(test); - write2DB(); - return true; - } - catch (PreexistingEntityException ex) { - LOG.log(Level.SEVERE, null, ex); - } - catch (Exception ex) { - LOG.log(Level.SEVERE, null, ex); - } - return false; - } - - @Override - public TestPlan getEntity() { - return new TestPlanJpaController(getEntityManagerFactory()) - .findTestPlan(getTestPlanPK()); - } - - @Override - public void update(TestPlan target, TestPlan source) { - target.setActive(source.getActive()); - target.setIsOpen(source.getIsOpen()); - target.setNotes(source.getNotes()); - target.setTestCaseList(source.getTestCaseList()); - target.setTestPlanList(source.getTestPlanList()); - target.setUserTestPlanRoleList(source.getUserTestPlanRoleList()); - target.setTestPlanPK(source.getTestPlanPK()); - target.setTestPlan(source.getTestPlan()); - target.setName(source.getName()); - } - - @Override - public void update() { - update(this, getEntity()); - } - - public void addUserTestPlanRole(VmUser user, Role role) throws Exception { - for (UserTestPlanRole utpr : getUserTestPlanRoleList()) { - if (utpr.getTestPlan().getTestPlanPK().equals(getTestPlanPK()) - && Objects.equals(utpr.getVmUser().getId(), user.getId()) - && Objects.equals(utpr.getRole().getId(), role.getId())) { - //We have already this role. - return; - } - } - UserTestPlanRoleServer temp = new UserTestPlanRoleServer(getEntity(), - user, role); - if (temp.getEntity() == null) { - temp.write2DB(); - } - getUserTestPlanRoleList().add(temp.getEntity()); - write2DB(); - } -} +package com.validation.manager.core.server.core; + +import static com.validation.manager.core.DataBaseManager.getEntityManagerFactory; +import com.validation.manager.core.EntityServer; +import com.validation.manager.core.VMException; +import com.validation.manager.core.db.Role; +import com.validation.manager.core.db.TestCase; +import com.validation.manager.core.db.TestPlan; +import com.validation.manager.core.db.TestProject; +import com.validation.manager.core.db.UserTestPlanRole; +import com.validation.manager.core.db.VmUser; +import com.validation.manager.core.db.controller.TestPlanJpaController; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import java.util.ArrayList; +import java.util.Objects; +import java.util.logging.Level; +import java.util.logging.Logger; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public final class TestPlanServer extends TestPlan + implements EntityServer { + + private final static Logger LOG + = Logger.getLogger(TestPlanServer.class.getName()); + + public TestPlanServer(TestPlan plan) { + super.setTestPlanPK(plan.getTestPlanPK()); + update(); + } + + public TestPlanServer(TestProject testProject, boolean active, + boolean isOpen) { + super(testProject, active, isOpen); + setTestProject(testProject); + setTestPlanList(new ArrayList<>()); + setUserTestPlanRoleList(new ArrayList<>()); + setTestCaseList(new ArrayList<>()); + } + + @Override + public int write2DB() throws VMException { + try { + TestPlanJpaController controller + = new TestPlanJpaController(getEntityManagerFactory()); + if (getTestPlanPK().getId() > 0) { + TestPlan temp = controller.findTestPlan(getTestPlanPK()); + update(temp, this); + controller.edit(temp); + } else { + TestPlan temp = new TestPlan(getTestProject(), getActive(), + getIsOpen()); + update(temp, this); + controller.create(temp); + setTestPlanPK(temp.getTestPlanPK()); + } + } + catch (Exception ex) { + throw new VMException(ex); + } + return getTestPlanPK().getId(); + } + + public static boolean deleteTestPlan(TestPlan tp) { + try { + new TestPlanJpaController(getEntityManagerFactory()) + .destroy(tp.getTestPlanPK()); + } + catch (IllegalOrphanException | NonexistentEntityException ex) { + LOG.log(Level.SEVERE, null, ex); + return false; + } + return true; + } + + public boolean addTestCase(TestCase test) { + try { + getTestCaseList().add(test); + write2DB(); + return true; + } + catch (VMException ex) { + LOG.log(Level.SEVERE, null, ex); + } + return false; + } + + @Override + public TestPlan getEntity() { + return new TestPlanJpaController(getEntityManagerFactory()) + .findTestPlan(getTestPlanPK()); + } + + @Override + public void update(TestPlan target, TestPlan source) { + target.setActive(source.getActive()); + target.setIsOpen(source.getIsOpen()); + target.setNotes(source.getNotes()); + target.setTestCaseList(source.getTestCaseList()); + target.setTestPlanList(source.getTestPlanList()); + target.setUserTestPlanRoleList(source.getUserTestPlanRoleList()); + target.setTestPlanPK(source.getTestPlanPK()); + target.setTestPlan(source.getTestPlan()); + target.setName(source.getName()); + } + + @Override + public void update() { + update(this, getEntity()); + } + + public void addUserTestPlanRole(VmUser user, Role role) throws Exception { + for (UserTestPlanRole utpr : getUserTestPlanRoleList()) { + if (utpr.getTestPlan().getTestPlanPK().equals(getTestPlanPK()) + && Objects.equals(utpr.getVmUser().getId(), user.getId()) + && Objects.equals(utpr.getRole().getId(), role.getId())) { + //We have already this role. + return; + } + } + UserTestPlanRoleServer temp = new UserTestPlanRoleServer(getEntity(), + user, role); + if (temp.getEntity() == null) { + temp.write2DB(); + } + getUserTestPlanRoleList().add(temp.getEntity()); + write2DB(); + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/server/core/TestProjectServer.java b/VM-Core/src/main/java/com/validation/manager/core/server/core/TestProjectServer.java index 5ad3ca63..6e320d78 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/server/core/TestProjectServer.java +++ b/VM-Core/src/main/java/com/validation/manager/core/server/core/TestProjectServer.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,92 +13,100 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.server.core; - -import com.validation.manager.core.DataBaseManager; -import static com.validation.manager.core.DataBaseManager.getEntityManagerFactory; -import com.validation.manager.core.EntityServer; -import com.validation.manager.core.db.Role; -import com.validation.manager.core.db.TestProject; -import com.validation.manager.core.db.UserTestProjectRole; -import com.validation.manager.core.db.VmUser; -import com.validation.manager.core.db.controller.TestProjectJpaController; -import com.validation.manager.core.db.controller.UserTestProjectRoleJpaController; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public final class TestProjectServer extends TestProject - implements EntityServer { - - public TestProjectServer(String name, boolean active) { - super(name, active); - } - - public TestProjectServer(TestProject tp) { - super.setId(tp.getId()); - update(); - } - - @Override - public int write2DB() throws IllegalOrphanException, - NonexistentEntityException, Exception { - TestProject tp; - if (getId() == null) { - tp = new TestProject(); - update(tp, this); - new TestProjectJpaController(getEntityManagerFactory()).create(tp); - setId(tp.getId()); - } else { - tp = getEntity(); - update(tp, this); - new TestProjectJpaController(getEntityManagerFactory()).edit(tp); - } - update(); - return getId(); - } - - @Override - public TestProject getEntity() { - return new TestProjectJpaController( - getEntityManagerFactory()) - .findTestProject(getId()); - } - - @Override - public void update(TestProject target, TestProject source) { - target.setActive(source.getActive()); - target.setName(source.getName()); - target.setNotes(source.getNotes()); - target.setId(source.getId()); - target.setProjectList(source.getProjectList()); - target.setTestPlanList(source.getTestPlanList()); - target.setUserTestProjectRoleList(source.getUserTestProjectRoleList()); - } - - @Override - public void update() { - update(this, getEntity()); - } - - public UserTestProjectRole addUserTestProjectRole(TestProject tp, VmUser user, Role role) - throws Exception { - UserTestProjectRole temp = new UserTestProjectRole(tp.getId(), - user.getId(), role.getId()); - temp.setVmUser(user); - temp.setRole(role); - temp.setTestProject(tp); - UserTestProjectRoleJpaController controller - = new UserTestProjectRoleJpaController(DataBaseManager - .getEntityManagerFactory()); - if (controller.findUserTestProjectRole(temp - .getUserTestProjectRolePK()) == null) { - controller.create(temp); - update(); - } - return temp; - } -} +package com.validation.manager.core.server.core; + +import com.validation.manager.core.DataBaseManager; +import static com.validation.manager.core.DataBaseManager.getEntityManagerFactory; +import com.validation.manager.core.EntityServer; +import com.validation.manager.core.VMException; +import com.validation.manager.core.db.Role; +import com.validation.manager.core.db.TestProject; +import com.validation.manager.core.db.UserTestProjectRole; +import com.validation.manager.core.db.VmUser; +import com.validation.manager.core.db.controller.TestProjectJpaController; +import com.validation.manager.core.db.controller.UserTestProjectRoleJpaController; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public final class TestProjectServer extends TestProject + implements EntityServer { + + public TestProjectServer(String name, boolean active) { + super(name, active); + } + + public TestProjectServer(int id) { + super.setId(id); + update(); + } + + public TestProjectServer(TestProject tp) { + super.setId(tp.getId()); + update(); + } + + @Override + public int write2DB() throws VMException { + try { + TestProject tp; + if (getId() == null) { + tp = new TestProject(); + update(tp, this); + new TestProjectJpaController(getEntityManagerFactory()).create(tp); + setId(tp.getId()); + } else { + tp = getEntity(); + update(tp, this); + new TestProjectJpaController(getEntityManagerFactory()).edit(tp); + } + update(); + } + catch (Exception ex) { + throw new VMException(ex); + } + return getId(); + } + + @Override + public TestProject getEntity() { + return new TestProjectJpaController( + getEntityManagerFactory()) + .findTestProject(getId()); + } + + @Override + public void update(TestProject target, TestProject source) { + target.setActive(source.getActive()); + target.setName(source.getName()); + target.setNotes(source.getNotes()); + target.setId(source.getId()); + target.setProjectList(source.getProjectList()); + target.setTestPlanList(source.getTestPlanList()); + target.setUserTestProjectRoleList(source.getUserTestProjectRoleList()); + } + + @Override + public void update() { + update(this, getEntity()); + } + + public UserTestProjectRole addUserTestProjectRole(TestProject tp, VmUser user, Role role) + throws Exception { + UserTestProjectRole temp = new UserTestProjectRole(tp.getId(), + user.getId(), role.getId()); + temp.setVmUser(user); + temp.setRole(role); + temp.setTestProject(tp); + UserTestProjectRoleJpaController controller + = new UserTestProjectRoleJpaController(DataBaseManager + .getEntityManagerFactory()); + if (controller.findUserTestProjectRole(temp + .getUserTestProjectRolePK()) == null) { + controller.create(temp); + update(); + } + return temp; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/server/core/UserTestPlanRoleServer.java b/VM-Core/src/main/java/com/validation/manager/core/server/core/UserTestPlanRoleServer.java index a26daace..2bcfa4a3 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/server/core/UserTestPlanRoleServer.java +++ b/VM-Core/src/main/java/com/validation/manager/core/server/core/UserTestPlanRoleServer.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,81 +13,87 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.server.core; - -import static com.validation.manager.core.DataBaseManager.getEntityManagerFactory; -import com.validation.manager.core.EntityServer; -import com.validation.manager.core.db.Role; -import com.validation.manager.core.db.TestPlan; -import com.validation.manager.core.db.UserTestPlanRole; -import com.validation.manager.core.db.UserTestPlanRolePK; -import com.validation.manager.core.db.VmUser; -import com.validation.manager.core.db.controller.UserTestPlanRoleJpaController; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import java.util.logging.Level; -import static java.util.logging.Logger.getLogger; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public final class UserTestPlanRoleServer extends UserTestPlanRole - implements EntityServer { - - public UserTestPlanRoleServer(TestPlan tpl, VmUser user, Role role) { - super(tpl, user, role); - } - - public UserTestPlanRoleServer(UserTestPlanRolePK pk) { - super.setUserTestPlanRolePK(pk); - update(); - } - - @Override - public int write2DB() throws NonexistentEntityException, Exception { - UserTestPlanRoleJpaController controller - = new UserTestPlanRoleJpaController(getEntityManagerFactory()); - if (controller.findUserTestPlanRole(getUserTestPlanRolePK()) == null) { - UserTestPlanRole temp = new UserTestPlanRole(getTestPlan(), getVmUser(), - getRole()); - update(temp, this); - controller.create(temp); - update(this, temp); - } - return getUserTestPlanRolePK().getTestPlanTestProjectId(); - } - - public static boolean deleteUserTestPlanRole(UserTestPlanRole utpr) { - try { - new UserTestPlanRoleJpaController( - getEntityManagerFactory()).destroy( - utpr.getUserTestPlanRolePK()); - } - catch (NonexistentEntityException ex) { - getLogger(UserTestPlanRoleServer.class.getName()) - .log(Level.SEVERE, null, ex); - return false; - } - return true; - } - - @Override - public UserTestPlanRole getEntity() { - return new UserTestPlanRoleJpaController( - getEntityManagerFactory()) - .findUserTestPlanRole(getUserTestPlanRolePK()); - } - - @Override - public void update(UserTestPlanRole target, UserTestPlanRole source) { - target.setRole(source.getRole()); - target.setTestPlan(source.getTestPlan()); - target.setVmUser(source.getVmUser()); - target.setUserTestPlanRolePK(source.getUserTestPlanRolePK()); - } - - @Override - public void update() { - update(this, getEntity()); - } -} +package com.validation.manager.core.server.core; + +import static com.validation.manager.core.DataBaseManager.getEntityManagerFactory; +import com.validation.manager.core.EntityServer; +import com.validation.manager.core.VMException; +import com.validation.manager.core.db.Role; +import com.validation.manager.core.db.TestPlan; +import com.validation.manager.core.db.UserTestPlanRole; +import com.validation.manager.core.db.UserTestPlanRolePK; +import com.validation.manager.core.db.VmUser; +import com.validation.manager.core.db.controller.UserTestPlanRoleJpaController; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import java.util.logging.Level; +import static java.util.logging.Logger.getLogger; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public final class UserTestPlanRoleServer extends UserTestPlanRole + implements EntityServer { + + public UserTestPlanRoleServer(TestPlan tpl, VmUser user, Role role) { + super(tpl, user, role); + } + + public UserTestPlanRoleServer(UserTestPlanRolePK pk) { + super.setUserTestPlanRolePK(pk); + update(); + } + + @Override + public int write2DB() throws VMException { + try { + UserTestPlanRoleJpaController controller + = new UserTestPlanRoleJpaController(getEntityManagerFactory()); + if (controller.findUserTestPlanRole(getUserTestPlanRolePK()) == null) { + UserTestPlanRole temp = new UserTestPlanRole(getTestPlan(), getVmUser(), + getRole()); + update(temp, this); + controller.create(temp); + update(this, temp); + } + } + catch (Exception ex) { + throw new VMException(ex); + } + return getUserTestPlanRolePK().getTestPlanTestProjectId(); + } + + public static boolean deleteUserTestPlanRole(UserTestPlanRole utpr) { + try { + new UserTestPlanRoleJpaController( + getEntityManagerFactory()).destroy( + utpr.getUserTestPlanRolePK()); + } + catch (NonexistentEntityException ex) { + getLogger(UserTestPlanRoleServer.class.getName()) + .log(Level.SEVERE, null, ex); + return false; + } + return true; + } + + @Override + public UserTestPlanRole getEntity() { + return new UserTestPlanRoleJpaController( + getEntityManagerFactory()) + .findUserTestPlanRole(getUserTestPlanRolePK()); + } + + @Override + public void update(UserTestPlanRole target, UserTestPlanRole source) { + target.setRole(source.getRole()); + target.setTestPlan(source.getTestPlan()); + target.setVmUser(source.getVmUser()); + target.setUserTestPlanRolePK(source.getUserTestPlanRolePK()); + } + + @Override + public void update() { + update(this, getEntity()); + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/server/core/UserTestProjectRoleServer.java b/VM-Core/src/main/java/com/validation/manager/core/server/core/UserTestProjectRoleServer.java index 0f8ba306..2152c907 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/server/core/UserTestProjectRoleServer.java +++ b/VM-Core/src/main/java/com/validation/manager/core/server/core/UserTestProjectRoleServer.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,99 +13,100 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.server.core; - -import static com.validation.manager.core.DataBaseManager.getEntityManagerFactory; -import com.validation.manager.core.EntityServer; -import com.validation.manager.core.db.UserTestProjectRole; -import com.validation.manager.core.db.controller.UserTestProjectRoleJpaController; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import com.validation.manager.core.db.controller.exceptions.PreexistingEntityException; -import java.util.logging.Level; -import static java.util.logging.Logger.getLogger; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public final class UserTestProjectRoleServer extends UserTestProjectRole - implements EntityServer { - - public UserTestProjectRoleServer(int testProjectId, int userId, int roleId) { - super(testProjectId, userId, roleId); - update(); - } - - /** - * Persist to database - * - * @throws PreexistingEntityException If entity already exists and tried to - * be re-created. - * @throws Exception If something goes wrong writing to the database. - */ - @Override - public int write2DB() throws PreexistingEntityException, Exception { - UserTestProjectRoleJpaController controller - = new UserTestProjectRoleJpaController(getEntityManagerFactory()); - if (getUserTestProjectRolePK().getRoleId() > 0 - && getUserTestProjectRolePK().getTestProjectId() > 0 - && getUserTestProjectRolePK().getUserId() > 0) { - UserTestProjectRole temp - = controller.findUserTestProjectRole(getUserTestProjectRolePK()); - temp.setRole(getRole()); - temp.setTestProject(getTestProject()); - temp.setVmUser(getVmUser()); - controller.edit(temp); - } else { - UserTestProjectRole temp = new UserTestProjectRole( - getUserTestProjectRolePK().getTestProjectId(), - getUserTestProjectRolePK().getUserId(), - getUserTestProjectRolePK().getRoleId()); - temp.setRole(getRole()); - temp.setTestProject(getTestProject()); - temp.setVmUser(getVmUser()); - controller.create(temp); - setUserTestProjectRolePK(temp.getUserTestProjectRolePK()); - } - return getUserTestProjectRolePK().getRoleId(); - } - - /** - * Delete UserTestProjectRole - * - * @param role UserTestProjectRole to delete - * @return true if successful - */ - public static boolean deleteUserTestProjectRole(UserTestProjectRole role) { - try { - new UserTestProjectRoleJpaController( - getEntityManagerFactory()).destroy( - role.getUserTestProjectRolePK()); - } - catch (NonexistentEntityException ex) { - getLogger(UserTestProjectRoleServer.class.getName()) - .log(Level.SEVERE, null, ex); - return false; - } - return true; - } - - @Override - public UserTestProjectRole getEntity() { - return new UserTestProjectRoleJpaController( - getEntityManagerFactory()) - .findUserTestProjectRole(getUserTestProjectRolePK()); - } - - @Override - public void update(UserTestProjectRole target, UserTestProjectRole source) { - target.setRole(source.getRole()); - target.setTestProject(source.getTestProject()); - target.setVmUser(source.getVmUser()); - } - - @Override - public void update() { - update(this, getEntity()); - } -} +package com.validation.manager.core.server.core; + +import static com.validation.manager.core.DataBaseManager.getEntityManagerFactory; +import com.validation.manager.core.EntityServer; +import com.validation.manager.core.VMException; +import com.validation.manager.core.db.UserTestProjectRole; +import com.validation.manager.core.db.controller.UserTestProjectRoleJpaController; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import java.util.logging.Level; +import static java.util.logging.Logger.getLogger; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public final class UserTestProjectRoleServer extends UserTestProjectRole + implements EntityServer { + + public UserTestProjectRoleServer(int testProjectId, int userId, + int roleId) throws Exception { + super(testProjectId, userId, roleId); + setTestProject(new TestProjectServer(testProjectId).getEntity()); + setRole(new RoleServer(roleId).getEntity()); + setVmUser(new VMUserServer(userId).getEntity()); + } + + /** + * Persist to database + * + * @throws VMException If something goes wrong writing to the database. + */ + @Override + public int write2DB() throws VMException { + try { + UserTestProjectRoleJpaController controller + = new UserTestProjectRoleJpaController(getEntityManagerFactory()); + UserTestProjectRole temp + = controller.findUserTestProjectRole(getUserTestProjectRolePK()); + if (temp == null) { + temp = new UserTestProjectRole(); + update(temp, this); + controller.create(temp); + setUserTestProjectRolePK(temp.getUserTestProjectRolePK()); + } else { + temp.setRole(getRole()); + temp.setTestProject(getTestProject()); + temp.setVmUser(getVmUser()); + controller.edit(temp); + } + update(); + } + catch (Exception ex) { + throw new VMException(ex); + } + return getUserTestProjectRolePK().getRoleId(); + } + + /** + * Delete UserTestProjectRole + * + * @param role UserTestProjectRole to delete + * @return true if successful + */ + public static boolean deleteUserTestProjectRole(UserTestProjectRole role) { + try { + new UserTestProjectRoleJpaController( + getEntityManagerFactory()).destroy( + role.getUserTestProjectRolePK()); + } + catch (NonexistentEntityException ex) { + getLogger(UserTestProjectRoleServer.class.getName()) + .log(Level.SEVERE, null, ex); + return false; + } + return true; + } + + @Override + public UserTestProjectRole getEntity() { + return new UserTestProjectRoleJpaController( + getEntityManagerFactory()) + .findUserTestProjectRole(getUserTestProjectRolePK()); + } + + @Override + public void update(UserTestProjectRole target, UserTestProjectRole source) { + target.setRole(source.getRole()); + target.setTestProject(source.getTestProject()); + target.setVmUser(source.getVmUser()); + target.setUserTestProjectRolePK(source.getUserTestProjectRolePK()); + } + + @Override + public void update() { + update(this, getEntity()); + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/server/core/VMUserServer.java b/VM-Core/src/main/java/com/validation/manager/core/server/core/VMUserServer.java index dcf1a370..0068e0e2 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/server/core/VMUserServer.java +++ b/VM-Core/src/main/java/com/validation/manager/core/server/core/VMUserServer.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,545 +13,461 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.server.core; - -import com.validation.manager.core.DataBaseManager; -import static com.validation.manager.core.DataBaseManager.createdQuery; -import static com.validation.manager.core.DataBaseManager.getEntityManager; -import static com.validation.manager.core.DataBaseManager.getEntityManagerFactory; -import static com.validation.manager.core.DataBaseManager.namedQuery; -import com.validation.manager.core.EntityServer; -import com.validation.manager.core.VMException; -import com.validation.manager.core.db.CorrectiveAction; -import com.validation.manager.core.db.ExecutionStep; -import com.validation.manager.core.db.History; -import com.validation.manager.core.db.Notification; -import com.validation.manager.core.db.Role; -import com.validation.manager.core.db.TestCase; -import com.validation.manager.core.db.TestCaseExecution; -import com.validation.manager.core.db.UserAssigment; -import com.validation.manager.core.db.UserHasInvestigation; -import com.validation.manager.core.db.UserModifiedRecord; -import com.validation.manager.core.db.UserTestPlanRole; -import com.validation.manager.core.db.UserTestProjectRole; -import com.validation.manager.core.db.VmUser; -import com.validation.manager.core.db.controller.CorrectiveActionJpaController; -import com.validation.manager.core.db.controller.ExecutionStepJpaController; -import com.validation.manager.core.db.controller.RoleJpaController; -import com.validation.manager.core.db.controller.UserAssigmentJpaController; -import com.validation.manager.core.db.controller.UserHasInvestigationJpaController; -import com.validation.manager.core.db.controller.UserModifiedRecordJpaController; -import com.validation.manager.core.db.controller.UserStatusJpaController; -import com.validation.manager.core.db.controller.UserTestPlanRoleJpaController; -import com.validation.manager.core.db.controller.UserTestProjectRoleJpaController; -import com.validation.manager.core.db.controller.VmUserJpaController; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import static com.validation.manager.core.server.core.VMSettingServer.getSetting; -import static com.validation.manager.core.tool.MD5.encrypt; -import static java.lang.System.currentTimeMillis; -import java.util.ArrayList; -import java.util.Calendar; -import static java.util.Calendar.getInstance; -import java.util.Date; -import java.util.List; -import static java.util.Locale.getDefault; -import java.util.logging.Level; -import static java.util.logging.Logger.getLogger; -import javax.persistence.EntityTransaction; -import org.openide.util.Exceptions; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public final class VMUserServer extends VmUser implements EntityServer { - - private static final long serialVersionUID = 1L; - private boolean hashPassword = true; - private boolean increaseAttempts = false; - private boolean change; - - public VMUserServer(VmUser vmu) { - super.setId(vmu.getId()); - update(); - //previously hashing the already hashed password - setHashPassword(false); - } - - //create user object and login - public VMUserServer(String attrUN, String attrUPW) throws Exception { - super(); - try { - List result = createdQuery( - "SELECT u FROM VmUser uu WHERE u.username='" // NOI18N - + attrUN + "' AND u.password='" + encrypt(attrUPW) - + "' AND u.userStatusId.id <> 2"); - //throw exception if no result found - if (result.isEmpty()) { - PARAMETERS.clear(); - PARAMETERS.put("username", attrUN); - result - = namedQuery("VmUser.findByUsername", - PARAMETERS); - //The username is valid but wrong password. Increase the login attempts. - if (result.size() > 0) { - increaseAttempts = true; - VmUser xcu = (VmUser) result.get(0); - setAttempts(xcu.getAttempts()); - write2DB(); - } - throw new Exception(); - } else { - VmUser vmu = (VmUser) result.get(0); - update(VMUserServer.this, vmu); - //previously hashing the already hashed password - setHashPassword(false); - int status = vmu.getUserStatusId().getId(); - if (status != 2) { - Calendar cal2 = getInstance(), - now = getInstance(); - cal2.setTime(vmu.getLastModified()); - long diffMillis = now.getTimeInMillis() - - cal2.getTimeInMillis(); - long diffDays = diffMillis / (24 * 60 * 60 * 1000); - long age = getSetting("password.aging") - .getIntVal(); - if (diffDays >= age) { - status = 4; - } else { - status = 1; - } - setAttempts(0); - } else { - setAttempts(vmu.getAttempts()); - } - setUserStatusId(new UserStatusJpaController( - getEntityManagerFactory()) - .findUserStatus(status)); - } - } - catch (Exception e) { - EntityTransaction transaction - = getEntityManager().getTransaction(); - if (transaction.isActive()) { - transaction.rollback(); - } - List result = createdQuery("SELECT u FROM VmUser u WHERE u.username='" - + attrUN + "' AND u.userStatusId.id <> 2"); - //increase number of attempts - if (!result.isEmpty()) { - VmUser vmu = (VmUser) result.get(0); - update(VMUserServer.this, vmu); - //Don't rehash the pasword! - setHashPassword(false); //Increase attempts after a unsuccessfull login. - setIncreaseAttempts(true); - setLastModified(vmu.getLastModified()); - setChange(false); - write2DB(); - } - } - } - -//create user object for data structures - public VMUserServer(int id) throws Exception { - super.setId(id); - update(); - //previously hashing the already hashed password - setHashPassword(false); - } - - public VMUserServer(String name, String password, String firstName, - String lastName, String email) throws Exception { - setId(0); - setUsername(name); - setPassword(password); - setFirstName(firstName); - setLastName(lastName); - setEmail(email); - setLocale(getDefault().toString()); - setUserStatusId(new UserStatusJpaController( - getEntityManagerFactory()).findUserStatus(1)); - setAttempts(0); - setLastModified(new java.sql.Timestamp(currentTimeMillis())); - setHashPassword(true); - } - -//create user object - public VMUserServer(String name, String password, String firstName, - String lastName, String email, int userStatusId, int attempts, - java.sql.Timestamp lastModified) throws Exception { - setUsername(name); - setPassword(password); - setFirstName(firstName); - setLastName(lastName); - setEmail(email); - setUserStatusId(new UserStatusJpaController( - getEntityManagerFactory()) - .findUserStatus(userStatusId)); - setAttempts(attempts); - setLastModified(lastModified); - setHashPassword(true); - } - - //write to db - @Override - public int write2DB() throws Exception { - Date date; - if (getUserStatusId().getId() == 4) { - //Changed from aged out to password changed. Clear status - setUserStatusId(new UserStatusJpaController( - getEntityManagerFactory()) - .findUserStatus(1)); - setAttempts(0); -// setReason("audit.user.account.aged"); - setChange(true); - } - //Increase login attempts - if (increaseAttempts) { - setAttempts(getAttempts() + 1); - increaseAttempts = false; - } - //Lock account if needed. Can't lock main admin. - if (getAttempts() - > getSetting("password.attempts").getIntVal() - && getId() > 1) { - setUserStatusId( - new UserStatusJpaController( - getEntityManagerFactory()).findUserStatus(2)); - } - VmUserJpaController controller - = new VmUserJpaController(getEntityManagerFactory()); - if (getId() > 0) { - if (isChange()) { -// setModifierId(getEntity()); - date = new Date(); - setLastModified(date); - setChange(false); - } else { - date = getLastModified(); - } - setLastModified(date); - //Sometimes password got re-hashed - String password; - if (isHashPassword()) { - password = encrypt(getPassword().replaceAll("'", "\\\\'")); - } else { - password = getPassword().replaceAll("'", "\\\\'"); - } - VmUser vmu = controller.findVmUser(getId()); - update(vmu, this); - vmu.setPassword(password); -// vmu.setReason(getReason() == null -// ? "audit.general.modified" : getReason()); -// vmu.setModificationTime(new Date()); - controller.edit(vmu); - } else { - VmUser vmu = new VmUser( - getUsername().replaceAll("'", "\\\\'"), getPassword(), - getEmail().replaceAll("'", "\\\\'"), - getFirstName().replaceAll("'", "\\\\'"), - getLastName().replaceAll("'", "\\\\'"), getLocale(), - getLastModified(), new UserStatusJpaController( - getEntityManagerFactory()) - .findUserStatus(1), getAttempts()); - update(vmu, this); - controller.create(vmu); - setId(vmu.getId()); - } - setChange(false); -// setReason(""); - return getId(); - } - -//create complete list of users - public static ArrayList getVMUsers() { - ArrayList coreUsers = new ArrayList<>(); - try { - List result = createdQuery( - "Select x from VMUser x order by x.username"); - result.forEach((o) -> { - coreUsers.add(new VMUserServer((VmUser) o)); - }); - } - catch (Exception e) { - coreUsers.clear(); - } - return coreUsers; - } - - public boolean isHashPassword() { - return hashPassword; - } - - public void setHashPassword(boolean hashPassword) { - this.hashPassword = hashPassword; - } - - public boolean isIncreaseAttempts() { - return increaseAttempts; - } - - public void setIncreaseAttempts(boolean increaseAttempts) { - this.increaseAttempts = increaseAttempts; - } - - public boolean isPasswordUsable(String newPass, boolean hash) { - boolean passwordIsUsable = true; - try { - //Now check if password is not the same as the current password - List result = createdQuery( - "Select x from VmUser x where x.id=" + getId() - + " and x.password='" - + (hash ? encrypt(newPass) : newPass) + "'"); - if (result.size() > 0) { - passwordIsUsable = false; - } else { - //Here we'll catch if the password have been used in the - //unusable period (use id in case the username was modified) - VMUserServer user = new VMUserServer(getId()); - for (History u : user.getHistoryModificationList()) { - //Now check the aging - long diff = currentTimeMillis() - - u.getModificationTime().getTime(); - if (diff / (1000 * 60 * 60 * 24) - > getSetting("password.unusable_period") - .getIntVal()) { - passwordIsUsable = false; - } - } - } - //--------------------------- - } - catch (Exception ex) { - passwordIsUsable = false; - } - return passwordIsUsable; - } - - public boolean isPasswordUsable(String newPass) { - return isPasswordUsable(newPass, true); - } - - private void setChange(boolean c) { - change = c; - } - - private boolean isChange() { - return change; - } - - public static void deleteUser(VmUser user) { - if (user != null) { - PARAMETERS.clear(); - PARAMETERS.put("id", user.getId()); - VmUser temp = (VmUser) namedQuery("VmUser.findById", - PARAMETERS).get(0); - try { - for (CorrectiveAction ca : temp.getCorrectiveActionList()) { - new CorrectiveActionJpaController( - getEntityManagerFactory()).destroy(ca.getId()); - } - for (Role r : temp.getRoleList()) { - new RoleJpaController( - getEntityManagerFactory()).destroy(r.getId()); - } - for (UserAssigment ua : temp.getUserAssigmentList()) { - new UserAssigmentJpaController( - getEntityManagerFactory()).destroy(ua.getUserAssigmentPK()); - } - for (UserAssigment ua : temp.getUserAssigmentList1()) { - new UserAssigmentJpaController( - getEntityManagerFactory()).destroy(ua.getUserAssigmentPK()); - } - for (UserHasInvestigation i : temp.getUserHasInvestigationList()) { - new UserHasInvestigationJpaController( - getEntityManagerFactory()).destroy(i.getUserHasInvestigationPK()); - } - for (UserModifiedRecord rc : temp.getUserModifiedRecordList()) { - new UserModifiedRecordJpaController( - getEntityManagerFactory()).destroy(rc.getUserModifiedRecordPK()); - } - for (UserTestPlanRole rc : temp.getUserTestPlanRoleList()) { - new UserTestPlanRoleJpaController( - getEntityManagerFactory()).destroy(rc.getUserTestPlanRolePK()); - } - for (UserTestProjectRole rc : temp.getUserTestProjectRoleList()) { - new UserTestProjectRoleJpaController( - getEntityManagerFactory()).destroy(rc.getUserTestProjectRolePK()); - } - PARAMETERS.clear(); - PARAMETERS.put("id", temp.getId()); - temp = (VmUser) namedQuery("VmUser.findById", - PARAMETERS).get(0); - new VmUserJpaController( - getEntityManagerFactory()).destroy(temp.getId()); - } - catch (NonexistentEntityException | IllegalOrphanException ex) { - getLogger(VMUserServer.class.getName()).log(Level.SEVERE, null, ex); - } - } - } - - /** - * Check user credentials. - * - * the password is already encrypted. Usually queries from within the server - * itself - * - * @param username User name - * @param password Password - * @param encrypt Password needs encrypting? - * @return true if valid - */ - public static boolean validCredentials(String username, - String password, boolean encrypt) { - try { - PARAMETERS.clear(); - PARAMETERS.put("username", username); - PARAMETERS.put("password", encrypt - ? encrypt(password.replaceAll("'", "\\\\'")) : password); - return !createdQuery("SELECT x FROM VmUser x " - + "WHERE x.username = :username and x.password = :password", - PARAMETERS).isEmpty(); - } - catch (VMException e) { - getLogger(VMUserServer.class.getName()).log(Level.SEVERE, null, e); - return false; - } - catch (Exception ex) { - getLogger(VMUserServer.class.getName()).log(Level.SEVERE, null, ex); - return false; - } - } - - public static VmUser getUser(String username, - String password, boolean encrypt) { - try { - PARAMETERS.clear(); - PARAMETERS.put("username", username); - PARAMETERS.put("password", encrypt - ? encrypt(password.replaceAll("'", "\\\\'")) : password); - if (validCredentials(username, password, encrypt)) { - return (VmUser) createdQuery("SELECT x FROM VmUser x " - + "WHERE x.username = :username and x.password = :password", - PARAMETERS).get(0); - } else { - return null; - } - } - catch (Exception ex) { - getLogger(VMUserServer.class.getName()).log(Level.SEVERE, null, ex); - return null; - - } - } - - @Override - public VmUser getEntity() { - return new VmUserJpaController( - getEntityManagerFactory()) - .findVmUser(getId()); - } - - @Override - public void update(VmUser target, VmUser source) { - target.setPassword(source.getPassword()); - target.setFirstName(source.getFirstName()); - target.setLastName(source.getLastName()); - target.setLocale(source.getLocale()); - target.setEmail(source.getEmail()); - target.setAttempts(source.getAttempts()); - target.setLastModified(source.getLastModified()); - target.setUserStatusId(source.getUserStatusId()); - target.setRoleList(source.getRoleList()); - target.setCorrectiveActionList(source.getCorrectiveActionList()); - target.setUserAssigmentList(source.getUserAssigmentList()); - target.setUserAssigmentList1(source.getUserAssigmentList1()); - target.setUserHasInvestigationList(source.getUserHasInvestigationList()); - target.setUsername(source.getUsername()); - target.setRootCauseList(source.getRootCauseList()); - target.setUserTestPlanRoleList(source.getUserTestPlanRoleList()); - target.setUserTestProjectRoleList(source.getUserTestProjectRoleList()); - target.setId(source.getId()); - if (target.getExecutionStepList() == null) { - target.setExecutionStepList(new ArrayList<>()); - } - if (source.getExecutionStepList() != null) { - target.setExecutionStepList(source.getExecutionStepList()); - } - if (target.getExecutionStepList1() == null) { - target.setExecutionStepList1(new ArrayList<>()); - } - if (source.getExecutionStepList1() != null) { - target.setExecutionStepList1(source.getExecutionStepList1()); - } - if (target.getExecutionStepHasIssueList() == null) { - target.setExecutionStepHasIssueList(new ArrayList<>()); - } - target.setExecutionStepList(source.getExecutionStepList()); - target.setExecutionStepList1(source.getExecutionStepList1()); - target.setExecutionStepHasIssueList(source.getExecutionStepHasIssueList()); - target.setNotificationList(source.getNotificationList()); - target.setNotificationList1(source.getNotificationList1()); -// super.update(target, source); - } - - @Override - public void update() { - update(this, getEntity()); - } - - public void assignTestCase(TestCaseExecution tce, TestCase tc, - VmUser assigner) { - try { - VMUserServer a = new VMUserServer(assigner); - ExecutionStepJpaController c - = new ExecutionStepJpaController(DataBaseManager - .getEntityManagerFactory()); - tc.getStepList().forEach((s) -> { - tce.getExecutionStepList().stream().filter((es) - -> (es.getStep().getStepPK().equals(s.getStepPK()))) - .forEachOrdered((es) -> { - try { - es.setAssignedTime(new Date()); - c.edit(es); - getExecutionStepList().add(es); - a.getExecutionStepList1().add(es); - } - catch (Exception ex) { - Exceptions.printStackTrace(ex); - } - }); - }); - a.write2DB(); - write2DB(); - } - catch (Exception ex) { - Exceptions.printStackTrace(ex); - } - } - - public void setAsAssigner(ExecutionStep es) throws Exception { - ExecutionStepServer ess = new ExecutionStepServer(es); - ess.setAssigner(getEntity()); - ess.write2DB(); - update(); - } - - @Override - public String toString() { - return getFirstName() + " " + getLastName(); - } - - public List getPendingNotifications() { - update(); - List pending = new ArrayList<>(); - getNotificationList().forEach(n -> { - if (n.getAcknowledgeDate() == null) { - pending.add(n); - } - }); - return pending; - } -} +package com.validation.manager.core.server.core; + +import com.validation.manager.core.DataBaseManager; +import static com.validation.manager.core.DataBaseManager.createdQuery; +import static com.validation.manager.core.DataBaseManager.getEntityManager; +import static com.validation.manager.core.DataBaseManager.getEntityManagerFactory; +import com.validation.manager.core.EntityServer; +import com.validation.manager.core.VMException; +import com.validation.manager.core.db.ExecutionStep; +import com.validation.manager.core.db.History; +import com.validation.manager.core.db.Notification; +import com.validation.manager.core.db.TestCase; +import com.validation.manager.core.db.TestCaseExecution; +import com.validation.manager.core.db.VmUser; +import com.validation.manager.core.db.controller.ExecutionStepJpaController; +import com.validation.manager.core.db.controller.UserStatusJpaController; +import com.validation.manager.core.db.controller.VmUserJpaController; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import static com.validation.manager.core.server.core.VMSettingServer.getSetting; +import static com.validation.manager.core.tool.MD5.encrypt; +import static java.lang.System.currentTimeMillis; +import java.util.ArrayList; +import java.util.Calendar; +import static java.util.Calendar.getInstance; +import java.util.Date; +import java.util.List; +import static java.util.Locale.getDefault; +import java.util.logging.Level; +import java.util.logging.Logger; +import javax.persistence.EntityTransaction; +import org.openide.util.Exceptions; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public final class VMUserServer extends VmUser implements EntityServer { + + private static final long serialVersionUID = 1L; + private boolean hashPassword = true; + private boolean increaseAttempts = false; + private static final Logger LOG + = Logger.getLogger(VMUserServer.class.getName()); + private static final String USERNAME = "username"; + private static final String PWD = "password"; + + public VMUserServer(VmUser vmu) { + super.setId(vmu.getId()); + if (getId() != null) { + update(); + } + //previously hashing the already hashed password + setHashPassword(false); + } + + //create user object and login + public VMUserServer(String attrUN, String attrUPW) throws VMException { + super(); + try { + PARAMETERS.clear(); + PARAMETERS.put(USERNAME, attrUN); + PARAMETERS.put(PWD, encrypt(attrUPW)); + List result = createdQuery( + "SELECT u FROM VmUser u WHERE u.username= :username"// NOI18N + + " AND u.password= :password AND u.userStatusId.id <> 2", + PARAMETERS); + //throw exception if no result found + if (result.isEmpty()) { + //The username is valid but wrong password. Increase the login attempts. + throw new VMException("general.login.invalid.message"); + } else { + VmUser vmu = (VmUser) result.get(0); + update(VMUserServer.this, vmu); + //previously hashing the already hashed password + setHashPassword(false); + int status = vmu.getUserStatusId().getId(); + if (status != 2) { + Calendar cal2 = getInstance(), + now = getInstance(); + History last = getHistoryList().get(getHistoryList().size() - 1); + cal2.setTime(last.getModificationTime()); + long diffMillis = now.getTimeInMillis() + - cal2.getTimeInMillis(); + long diffDays = diffMillis / (24 * 60 * 60 * 1_000); + long age = getSetting("password.aging") + .getIntVal(); + if (diffDays >= age) { + status = 4; + } else { + status = 1; + } + setAttempts(0); + } else { + setAttempts(vmu.getAttempts()); + } + setUserStatusId(new UserStatusJpaController( + getEntityManagerFactory()) + .findUserStatus(status)); + } + } + catch (VMException e) { + EntityTransaction transaction + = getEntityManager().getTransaction(); + if (transaction.isActive()) { + transaction.rollback(); + } + List result = createdQuery("SELECT u FROM VmUser u WHERE u.username='" + + attrUN + "' AND u.userStatusId.id <> 2"); + //increase number of attempts + if (!result.isEmpty()) { + VMUserServer vmu = new VMUserServer((VmUser) result.get(0)); + //Don't rehash the pasword! + vmu.setHashPassword(false); + vmu.setIncreaseAttempts(true);//Increase attempts after a unsuccessfull login. + vmu.write2DB(); + } + } + } + +//create user object for data structures + public VMUserServer(int id) throws Exception { + super.setId(id); + update(); + //previously hashing the already hashed password + setHashPassword(false); + } + + public VMUserServer(String name, String password, String firstName, + String lastName, String email) throws Exception { + setId(0); + setUsername(name); + setPassword(password); + setFirstName(firstName); + setLastName(lastName); + setEmail(email); + setLocale(getDefault().toString()); + setUserStatusId(new UserStatusJpaController( + getEntityManagerFactory()).findUserStatus(1)); + setAttempts(0); + setHashPassword(true); + } + + private void prepareToPersist() { + if (getUserStatusId() == null) { + setUserStatusId(new UserStatusJpaController( + getEntityManagerFactory()) + .findUserStatus(1)); + } + if (getUserStatusId().getId() == 4) { + //Changed from aged out to password changed. Clear status + setUserStatusId(new UserStatusJpaController( + getEntityManagerFactory()) + .findUserStatus(1)); + setAttempts(0); + setReason("audit.user.account.aged"); + } + //Increase login attempts + if (increaseAttempts) { + setAttempts(getAttempts() + 1); + increaseAttempts = false; + } + //Lock account if needed. Can't lock main admin. + if (getAttempts() + > getSetting("password.attempts").getIntVal() + && getId() > 1) { + setUserStatusId( + new UserStatusJpaController( + getEntityManagerFactory()).findUserStatus(4)); + } + } + + //write to db + @Override + public int write2DB() throws VMException { + VmUserJpaController controller + = new VmUserJpaController(getEntityManagerFactory()); + if (getId() != null && getId() > 0) { + prepareToPersist(); + try { + if (getModifierId() == 0) { + setModifierId(getEntity().getId()); + } + //Sometimes password got re-hashed + String password; + if (isHashPassword()) { + password = encrypt(getPassword().replaceAll("'", "\\\\'")); + setHashPassword(false); + } else { + password = getPassword().replaceAll("'", "\\\\'"); + } + VmUser vmu = getEntity(); + update(vmu, this); + vmu.setPassword(password); + vmu.setReason(getReason() == null + ? "audit.general.modified" : getReason()); + vmu.setModificationTime(new Date()); + vmu.updateHistory(); + controller.edit(vmu); + update(); + } + catch (NonexistentEntityException ex) { + throw new VMException(ex); + } + catch (Exception ex) { + throw new VMException(ex); + } + } else { + try { + prepareToPersist(); + String password; + if (isHashPassword()) { + password = encrypt(getPassword().replaceAll("'", "\\\\'")); + setHashPassword(false); + } else { + password = getPassword().replaceAll("'", "\\\\'"); + } + VmUser vmu = new VmUser( + getUsername().replaceAll("'", "\\\\'"), password, + getEmail().replaceAll("'", "\\\\'"), + getFirstName().replaceAll("'", "\\\\'"), + getLastName().replaceAll("'", "\\\\'"), getLocale(), + new UserStatusJpaController( + getEntityManagerFactory()) + .findUserStatus(1), getAttempts()); + vmu.updateHistory(); + controller.create(vmu); + setId(vmu.getId()); + } + catch (Exception ex) { + throw new VMException(ex); + } + } + setReason(""); + update(); + return getId(); + } + + //Create complete list of users + public static ArrayList getVMUsers() { + ArrayList coreUsers = new ArrayList<>(); + try { + List result = createdQuery( + "Select x from VmUser x order by x.username"); + result.forEach((o) -> { + coreUsers.add(new VMUserServer((VmUser) o)); + }); + } + catch (Exception e) { + coreUsers.clear(); + } + return coreUsers; + } + + public boolean isHashPassword() { + return hashPassword; + } + + public void setHashPassword(boolean hashPassword) { + this.hashPassword = hashPassword; + } + + public boolean isIncreaseAttempts() { + return increaseAttempts; + } + + public void setIncreaseAttempts(boolean increaseAttempts) { + this.increaseAttempts = increaseAttempts; + } + + public boolean isPasswordUsable(String newPass, boolean hash) { + boolean passwordIsUsable = true; + try { + //Now check if password is not the same as the current password + PARAMETERS.clear(); + PARAMETERS.put(USERNAME, getUsername()); + PARAMETERS.put(PWD, hash + ? encrypt(newPass.replaceAll("'", "\\\\'")) : newPass); + List result = createdQuery("SELECT x FROM VmUser x " + + "WHERE x.username = :username and x.password = :password", + PARAMETERS); + if (result.size() > 0) { + //Can't change to same password. + passwordIsUsable = false; + } else { + //Here we'll catch if the password have been used in the + //unusable period (use id in case the username was modified) + VMUserServer user = new VMUserServer(getId()); + for (History u : user.getHistoryList()) { + //Now check the aging + long diff = currentTimeMillis() + - u.getModificationTime().getTime(); + if (diff / (1_000 * 60 * 60 * 24) + > getSetting("password.unusable_period") + .getIntVal()) { + passwordIsUsable = false; + } + } + } + //--------------------------- + } + catch (Exception ex) { + passwordIsUsable = false; + } + return passwordIsUsable; + } + + public boolean isPasswordUsable(String newPass) { + return isPasswordUsable(newPass, true); + } + + /** + * Check user credentials. + * + * The password is already encrypted. Usually queries from within the server + * itself + * + * @param username User name + * @param password Password + * @param encrypt Password needs encrypting? + * @return true if valid + */ + protected static boolean validCredentials(String username, + String password, boolean encrypt) { + try { + PARAMETERS.clear(); + PARAMETERS.put(USERNAME, username); + PARAMETERS.put(PWD, encrypt + ? encrypt(password.replaceAll("'", "\\\\'")) : password); + return !createdQuery("SELECT x FROM VmUser x " + + "WHERE x.username = :username and x.password = :password", + PARAMETERS).isEmpty(); + } + catch (VMException e) { + LOG.log(Level.SEVERE, null, e); + return false; + } + catch (Exception ex) { + LOG.log(Level.SEVERE, null, ex); + return false; + } + } + + public static VmUser getUser(String username, + String password, boolean encrypt) { + try { + PARAMETERS.clear(); + PARAMETERS.put(USERNAME, username); + PARAMETERS.put(PWD, encrypt + ? encrypt(password.replaceAll("'", "\\\\'")) : password); + if (validCredentials(username, password, encrypt)) { + return (VmUser) createdQuery("SELECT x FROM VmUser x " + + "WHERE x.username = :username and x.password = :password", + PARAMETERS).get(0); + } else { + return null; + } + } + catch (VMException ex) { + LOG.log(Level.SEVERE, null, ex); + return null; + + } + } + + @Override + public VmUser getEntity() { + return new VmUserJpaController(getEntityManagerFactory()) + .findVmUser(getId()); + } + + @Override + public void update(VmUser target, VmUser source) { + target.setPassword(source.getPassword()); + target.setFirstName(source.getFirstName()); + target.setLastName(source.getLastName()); + target.setLocale(source.getLocale()); + target.setEmail(source.getEmail()); + target.setAttempts(source.getAttempts()); + target.setUserStatusId(source.getUserStatusId()); + target.setRoleList(source.getRoleList()); + target.setCorrectiveActionList(source.getCorrectiveActionList()); + target.setUserAssigmentList(source.getUserAssigmentList()); + target.setUserAssigmentList1(source.getUserAssigmentList1()); + target.setUserHasInvestigationList(source.getUserHasInvestigationList()); + target.setUsername(source.getUsername()); + target.setRootCauseList(source.getRootCauseList()); + target.setUserTestPlanRoleList(source.getUserTestPlanRoleList()); + target.setUserTestProjectRoleList(source.getUserTestProjectRoleList()); + target.setId(source.getId()); + target.setExecutionStepList(source.getExecutionStepList()); + target.setExecutionStepList1(source.getExecutionStepList1()); + target.setExecutionStepList(source.getExecutionStepList()); + target.setExecutionStepList1(source.getExecutionStepList1()); + target.setExecutionStepHasIssueList(source.getExecutionStepHasIssueList()); + target.setNotificationList(source.getNotificationList()); + target.setNotificationList1(source.getNotificationList1()); + target.setHistoryModificationList(source.getHistoryModificationList()); + super.update(target, source); + } + + @Override + public void update() { + update(this, getEntity()); + } + + public void assignTestCase(TestCaseExecution tce, TestCase tc, + VmUser assigner) { + try { + VMUserServer a = new VMUserServer(assigner); + ExecutionStepJpaController c + = new ExecutionStepJpaController(DataBaseManager + .getEntityManagerFactory()); + tc.getStepList().forEach((s) -> { + tce.getExecutionStepList().stream().filter((es) + -> (es.getStep().getStepPK().equals(s.getStepPK()))) + .forEachOrdered((es) -> { + try { + es.setAssignedTime(new Date()); + c.edit(es); + getExecutionStepList().add(es); + a.getExecutionStepList1().add(es); + } + catch (Exception ex) { + Exceptions.printStackTrace(ex); + } + }); + }); + a.write2DB(); + write2DB(); + } + catch (VMException ex) { + Exceptions.printStackTrace(ex); + } + } + + public void setAsAssigner(ExecutionStep es) throws Exception { + ExecutionStepServer ess = new ExecutionStepServer(es); + ess.setAssigner(getEntity()); + ess.write2DB(); + update(); + } + + @Override + public String toString() { + return getFirstName() + " " + getLastName(); + } + + public List getPendingNotifications() { + update(); + List pending = new ArrayList<>(); + getNotificationList().forEach(n -> { + if (n.getAcknowledgeDate() == null) { + pending.add(n); + } + }); + return pending; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/server/fmea/CauseServer.java b/VM-Core/src/main/java/com/validation/manager/core/server/fmea/CauseServer.java index 3c0beb7b..0e97a3ed 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/server/fmea/CauseServer.java +++ b/VM-Core/src/main/java/com/validation/manager/core/server/fmea/CauseServer.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,67 +13,73 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.server.fmea; - -import static com.validation.manager.core.DataBaseManager.getEntityManagerFactory; -import com.validation.manager.core.EntityServer; -import com.validation.manager.core.db.Cause; -import com.validation.manager.core.db.controller.CauseJpaController; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class CauseServer extends Cause implements EntityServer { - - public CauseServer(String name, String description) { - super(name, description); - setId(0); - } - - @Override - public int write2DB() throws NonexistentEntityException, Exception { - if (getId() > 0) { - Cause c = new CauseJpaController( - getEntityManagerFactory()) - .findCause(getId()); - update(c, this); - new CauseJpaController( - getEntityManagerFactory()).edit(c); - } else { - Cause c = new Cause(); - update(c, this); - new CauseJpaController( - getEntityManagerFactory()).create(c); - setId(c.getId()); - } - return getId(); - } - - public static boolean deleteCause(Cause c) throws NonexistentEntityException { - new CauseJpaController( - getEntityManagerFactory()).destroy(c.getId()); - return true; - } - - @Override - public Cause getEntity() { - return new CauseJpaController( - getEntityManagerFactory()).findCause(getId()); - } - - @Override - public void update(Cause target, Cause source) { - target.setDescription(source.getDescription()); - target.setName(source.getName()); - if (source.getRiskItemList() != null) { - target.setRiskItemList(source.getRiskItemList()); - } - } - - @Override - public void update() { - update(this, getEntity()); - } -} +package com.validation.manager.core.server.fmea; + +import static com.validation.manager.core.DataBaseManager.getEntityManagerFactory; +import com.validation.manager.core.EntityServer; +import com.validation.manager.core.VMException; +import com.validation.manager.core.db.Cause; +import com.validation.manager.core.db.controller.CauseJpaController; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public final class CauseServer extends Cause implements EntityServer { + + public CauseServer(String name, String description) { + super(name, description); + setId(0); + } + + @Override + public int write2DB() throws VMException { + try { + if (getId() > 0) { + Cause c = new CauseJpaController( + getEntityManagerFactory()) + .findCause(getId()); + update(c, this); + new CauseJpaController( + getEntityManagerFactory()).edit(c); + } else { + Cause c = new Cause(); + update(c, this); + new CauseJpaController( + getEntityManagerFactory()).create(c); + setId(c.getId()); + } + } + catch (Exception ex) { + throw new VMException(ex); + } + return getId(); + } + + public static boolean deleteCause(Cause c) throws NonexistentEntityException { + new CauseJpaController( + getEntityManagerFactory()).destroy(c.getId()); + return true; + } + + @Override + public Cause getEntity() { + return new CauseJpaController( + getEntityManagerFactory()).findCause(getId()); + } + + @Override + public void update(Cause target, Cause source) { + target.setDescription(source.getDescription()); + target.setName(source.getName()); + if (source.getRiskItemList() != null) { + target.setRiskItemList(source.getRiskItemList()); + } + } + + @Override + public void update() { + update(this, getEntity()); + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/spi/email/EmailManager.java b/VM-Core/src/main/java/com/validation/manager/core/spi/email/EmailManager.java new file mode 100644 index 00000000..929b6c93 --- /dev/null +++ b/VM-Core/src/main/java/com/validation/manager/core/spi/email/EmailManager.java @@ -0,0 +1,94 @@ +/* + * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.validation.manager.core.spi.email; + +import com.validation.manager.core.api.email.IEmailManager; +import com.validation.manager.core.server.core.VMSettingServer; +import java.util.Date; +import java.util.Properties; +import javax.mail.Message; +import javax.mail.MessagingException; +import javax.mail.PasswordAuthentication; +import javax.mail.Session; +import javax.mail.Transport; +import javax.mail.internet.InternetAddress; +import javax.mail.internet.MimeMessage; +import org.openide.util.lookup.ServiceProvider; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@ServiceProvider(service = IEmailManager.class) +public class EmailManager implements IEmailManager { + + @Override + public void sendEmail(String to, String cc, String from, + String subject, String bodyText) throws MessagingException { + Properties props = new Properties(); + props.put("mail.smtp.host", + VMSettingServer.getSetting("mail.smtp.host").getStringVal()); + props.put("mail.smtp.auth", VMSettingServer.getSetting("mail.smtp.auth") + .getBoolVal().toString()); + props.put("mail.debug", "true"); + props.put("mail.smtp.starttls.enable", + VMSettingServer.getSetting("mail.smtp.starttls.enable") + .getBoolVal().toString()); + props.put("mail.smtp.port", "" + + VMSettingServer.getSetting("mail.smtp.port").getIntVal()); + props.put("mail.smtp.socketFactory.port", "" + + VMSettingServer.getSetting("mail.smtp.socketFactory.port").getIntVal()); + props.put("mail.smtp.socketFactory.class", + VMSettingServer.getSetting("mail.smtp.socketFactory.class") + .getStringVal()); + props.put("mail.smtp.socketFactory.fallback", + VMSettingServer.getSetting("mail.smtp.socketFactory.fallback") + .getBoolVal().toString()); + Session mailSession; + String username = VMSettingServer.getSetting("mail.auth.username") + .getStringVal(); + String password = VMSettingServer.getSetting("mail.auth.password") + .getStringVal(); + if (username != null) { + mailSession = Session.getInstance(props, new javax.mail.Authenticator() { + + @Override + protected PasswordAuthentication getPasswordAuthentication() { + return new PasswordAuthentication(username, password); + } + }); + } else { + mailSession = Session.getInstance(props); + } + mailSession.setDebug(true); // Enable the debug mode + + Message email = new MimeMessage(mailSession); + //--[ Set the FROM, TO, DATE and SUBJECT fields + email.setFrom(new InternetAddress(from)); + email.setRecipients(Message.RecipientType.TO, + InternetAddress.parse(to)); + email.setSentDate(new Date()); + email.setSubject(subject); + if (cc != null && !cc.isEmpty()) { + email.setRecipients(Message.RecipientType.CC, + InternetAddress.parse(cc)); + } + //--[ Create the body of the mail + email.setText(bodyText); + //--[ Ask the Transport class to send our mail message + Transport.send(email); + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/spi/internationalization/DefaultInternationalizationProvider.java b/VM-Core/src/main/java/com/validation/manager/core/spi/internationalization/DefaultInternationalizationProvider.java index 33e3d212..c534969f 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/spi/internationalization/DefaultInternationalizationProvider.java +++ b/VM-Core/src/main/java/com/validation/manager/core/spi/internationalization/DefaultInternationalizationProvider.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,63 +13,66 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.spi.internationalization; - -import com.validation.manager.core.api.internationalization.InternationalizationProvider; -import com.validation.manager.core.api.internationalization.LocaleListener; -import java.io.UnsupportedEncodingException; -import java.util.Locale; -import java.util.ResourceBundle; -import java.util.logging.Level; -import java.util.logging.Logger; -import org.openide.util.Lookup; -import org.openide.util.lookup.ServiceProvider; -import org.openide.util.lookup.ServiceProviders; - -@ServiceProviders({ - @ServiceProvider(service = InternationalizationProvider.class, position = 1) - ,@ServiceProvider(service = LocaleListener.class)}) -public class DefaultInternationalizationProvider - implements InternationalizationProvider { - - private ResourceBundle RB = ResourceBundle.getBundle( - "com.validation.manager.resources.VMMessages", Locale.getDefault()); - private static final Logger LOG - = Logger.getLogger(DefaultInternationalizationProvider.class - .getSimpleName()); - - @Override - public String translate(String mess) { - try { - if (RB.containsKey(mess)) { - return RB.containsKey(mess) ? new String(RB.getString(mess) - .getBytes("ISO-8859-1"), "UTF-8") : mess; - } else { - //Try to search on any other provider - for (InternationalizationProvider i - : Lookup.getDefault() - .lookupAll(InternationalizationProvider.class)) { - if (!(i instanceof DefaultInternationalizationProvider) - && i.getResourceBundle().containsKey(mess)) { - return i.translate(mess); - } - } - } - } - catch (UnsupportedEncodingException ex) { - LOG.log(Level.SEVERE, null, ex); - } - return mess; - } - - @Override - public void setlocale(Locale locale) { - RB = ResourceBundle.getBundle( - "com.validation.manager.resources.VMMessages", locale); - } - - @Override - public ResourceBundle getResourceBundle() { - return RB; - } -} +package com.validation.manager.core.spi.internationalization; + +import com.vaadin.ui.UI; +import com.validation.manager.core.VMUI; +import com.validation.manager.core.api.internationalization.InternationalizationProvider; +import com.validation.manager.core.server.core.VMUserServer; +import java.io.UnsupportedEncodingException; +import java.util.Locale; +import java.util.ResourceBundle; +import java.util.logging.Level; +import java.util.logging.Logger; +import org.openide.util.Lookup; +import org.openide.util.lookup.ServiceProvider; + +@ServiceProvider(service = InternationalizationProvider.class, position = 1) +public class DefaultInternationalizationProvider + implements InternationalizationProvider { + + private static final Logger LOG + = Logger.getLogger(DefaultInternationalizationProvider.class + .getSimpleName()); + + @Override + public String translate(String mess) { + VMUI ui = (VMUI) UI.getCurrent(); + VMUserServer user = ui == null ? null : ui.getUser(); + return translate(mess, user == null ? Locale.getDefault() + : new Locale(user.getLocale())); + } + + @Override + public ResourceBundle getResourceBundle() { + return ResourceBundle.getBundle( + "com.validation.manager.resources.VMMessages"); + } + + @Override + public String translate(String mess, Locale locale) { + try { + ResourceBundle bundle = ResourceBundle.getBundle( + "com.validation.manager.resources.VMMessages", locale); + if (bundle.containsKey(mess)) { + return bundle.containsKey(mess) + ? new String(bundle.getString(mess) + .getBytes("ISO-8859-1"), "UTF-8") : mess; + } else { + //Try to search on any other provider + for (InternationalizationProvider i + : Lookup.getDefault() + .lookupAll(InternationalizationProvider.class)) { + if (!(i instanceof DefaultInternationalizationProvider) + && i.getResourceBundle().containsKey(mess)) { + return i.translate(mess); + } + } + } + } + catch (UnsupportedEncodingException ex) { + LOG.log(Level.SEVERE, null, ex); + } + return mess; + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/tool/MD5.java b/VM-Core/src/main/java/com/validation/manager/core/tool/MD5.java index 9f9b26cb..90f70f0d 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/tool/MD5.java +++ b/VM-Core/src/main/java/com/validation/manager/core/tool/MD5.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,45 +13,47 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.tool; - -import static java.lang.Integer.toHexString; -import java.security.MessageDigest; -import static java.security.MessageDigest.getInstance; -import java.security.NoSuchAlgorithmException; - -/** - * - * @author Javier A. Ortiz - */ -public class MD5 { - - private static String md5val = ""; - private static MessageDigest algorithm = null; - - private MD5() { - } - - public static String encrypt(String text) throws Exception { - try { - algorithm = getInstance("MD5"); - } catch (NoSuchAlgorithmException nsae) { - throw new Exception("Cannot find digest algorithm"); - } - byte[] defaultBytes = text.getBytes(); - algorithm.reset(); - algorithm.update(defaultBytes); - byte messageDigest[] = algorithm.digest(); - StringBuilder hexString = new StringBuilder(); - - for (int i = 0; i < messageDigest.length; i++) { - String hex = toHexString(0xFF & messageDigest[i]); - if (hex.length() == 1) { - hexString.append('0'); - } - hexString.append(hex); - } - md5val = hexString.toString(); - return md5val; - } -} +package com.validation.manager.core.tool; + +import com.validation.manager.core.VMException; +import static java.lang.Integer.toHexString; +import java.security.MessageDigest; +import static java.security.MessageDigest.getInstance; +import java.security.NoSuchAlgorithmException; + +/** + * + * @author Javier A. Ortiz + */ +public class MD5 { + + private static String md5val = ""; + private static MessageDigest algorithm = null; + + private MD5() { + } + + public static String encrypt(String text) throws VMException { + try { + algorithm = getInstance("MD5"); + } + catch (NoSuchAlgorithmException nsae) { + throw new VMException("Cannot find digest algorithm"); + } + byte[] defaultBytes = text.getBytes(); + algorithm.reset(); + algorithm.update(defaultBytes); + byte messageDigest[] = algorithm.digest(); + StringBuilder hexString = new StringBuilder(); + + for (int i = 0; i < messageDigest.length; i++) { + String hex = toHexString(0xFF & messageDigest[i]); + if (hex.length() == 1) { + hexString.append('0'); + } + hexString.append(hex); + } + md5val = hexString.toString(); + return md5val; + } +} diff --git a/VM-Core/src/main/resources/com/validation/manager/resources/VMMessages.properties b/VM-Core/src/main/resources/com/validation/manager/resources/VMMessages.properties index c2536ccf..b30c2289 100755 --- a/VM-Core/src/main/resources/com/validation/manager/resources/VMMessages.properties +++ b/VM-Core/src/main/resources/com/validation/manager/resources/VMMessages.properties @@ -1,12 +1,19 @@ add.attachment=Add Attachment -add.comment=Add comment +add.comment=Add Comment add.details=Add Details +add.user=Add User admin.desc=Administrator admin.tab.name=Administrator assign.test.case=Assign Test Case(s) assign.test.case.execution=Assign Test Case Execution attach.file=Attach File attachment.present=There are attachment present in the execution. +available.roles=Available Roles +current.roles=Current Roles +guest.desc=Guest +none.desc=None +reserved.desc=Reserved +requirement.manager.desc=Requirement Manager #Audit audit.coregroup.change=Core group changed\! audit.corenode.change=Core node changed\! @@ -54,7 +61,6 @@ date.format=Date Format #Delete delete.error=Unable to delete\! -delete.error\!=Unable to delete\! delete.execution=Delete Execution delete.with.issues.message=There are attachment(s), issue(s) and/or comment(s) present in the execution. delete.with.issues.title=Want to delete even with identified issues? @@ -103,15 +109,26 @@ general.assignment.date=Assignment Date general.attachment=Attachments general.audit.menu=Audit Trail Menu general.cancel=Cancel -general.comclusion=Conclusion +general.conclusion=Conclusion +general.configuration=Configuration general.comment=Comment general.comments=Comments general.conclusion=Conclusion general.create=Create general.creation.date=Created on +general.delete=Delete general.description=Description general.edit=Edit general.email=Email +general.email.enable=Email Enabled +general.email.from=From +general.email.to=To +general.email.send=Send +general.email.subject=Subject +general.email.message=Message +general.email.settings=Email Settings +general.email.settings.test=Test Email Settings +general.email.settings.test.success=Success! general.error.record.creation=Error creating record\! general.error.record.update=Error updating record\! general.execute=Execute @@ -141,6 +158,7 @@ general.notification=Notification general.notifications=Notifications general.obsolete=Obsolete general.open=Open +general.output=Output general.parent=Parent general.password=Password general.project=Project @@ -192,6 +210,7 @@ issue.invalid=Invalid issue.not.reproduceable=Not Reproducible issue.present=There are issues present in the execution. issue.type=Issue Type +issue.resolution=Issue Resolution leader.desc=Lead Tester linked.requirement=Linked Requirements lock.test.case.message=Locked test cases are committed and can no longer be modified.\\nIt would be equivalent to documenting in paper. @@ -245,7 +264,7 @@ message.requirement.import.missing.column=Not enough columns in data source (%c) message.requirement.import.success=Requirement import completed\! message.requirement.import.verify=Please review the requirements to be imported. message.requirement.status=Status -message.requirement.type=Requirement Type +requirement.type=Requirement Type message.section.dnd.invalid=Invalid to move section to this location\! message.spec.level=Specification Level message.step.create=Create Step @@ -277,6 +296,7 @@ notification.type=Notification Type notification.author=Author notification.mark.unread=Mark as Unread notification.archive=Archive Notification +notification.new=You received a new notification! modification.date=Modification Date observation.desc=Observation to be evaluated diff --git a/VM-Core/src/main/resources/com/validation/manager/resources/VMMessages_es.properties b/VM-Core/src/main/resources/com/validation/manager/resources/VMMessages_es.properties index 93b02cfc..f0feab70 100755 --- a/VM-Core/src/main/resources/com/validation/manager/resources/VMMessages_es.properties +++ b/VM-Core/src/main/resources/com/validation/manager/resources/VMMessages_es.properties @@ -68,7 +68,6 @@ message.requirement.import.invalid.product = Producto inválido provisto. message.requirement.import.file.null = Archivo para importar es nulo message.requirement.import.file.invalid = Archivo para importar no existe message.requirement.import.verify = Por favor revise los requicitos a importar. -message.requirement.type = Tipo de Requicito message.requirement.import.success = Importe de requicitos completado\! message.requirement.dnd.invalid = Mover requicitos a este lugar es inválido\! message.requirement.status = Estado @@ -183,6 +182,7 @@ issue.invalid = Inválido # Baseline baseline.creation = Creación de Línea de Base add.attachment = Añadir Archivo +# Fuzzy add.comment = Añadir comentario add.details = Añadir Detalles assign.test.case = Asignar Prueba(s) @@ -212,7 +212,6 @@ create.test.suite = Crear Grupo de Pruebas creation.time = Fecha de Creación # Delete delete.error = Fue imposible de eliminar\! -delete.error\! = \nFue imposible de eliminar\! delete.execution = Eliminar Ejecución delete.with.issues.message = Hay archivo(s), reporte(s) de problema y/o comentario(s) presentes en la ejecución. delete.with.issues.title = Quiere eliminar aún con los problemas identificados? @@ -246,7 +245,6 @@ general.active = Activo general.amount = Cantidad general.assignee = Usuario Asignado general.attachment = Archivos -general.comclusion = Conclusión general.comment = Comentario general.comments = Comentarios general.conclusion = Conclusión @@ -371,4 +369,26 @@ notification.mark.unread = Marcar como no leído notification.archive = Archivar Notificación general.archived = Archivado general.no = No -general.yes = Si \ No newline at end of file +general.yes = Si +general.email.enable = Correo Electrónico Activado +general.email.from = De +general.email.to = Hacia +general.email.send = Enviar +general.email.subject = Título +general.email.message = Mensaje +general.email.settings = Configuración de Correo Electrónico +general.email.settings.test = Probar Configuraciones de Correo Electrónico +general.email.settings.test.success = Exito +general.output = Salida +notification.new = Has recibido una nueva notificación\! +add.user = Añadir usuario +available.roles = Roles Disponibles +current.roles = Roles Actuales +guest.desc = Invitado +none.desc = Ninguno +reserved.desc = Reservado +requirement.manager.desc = Manejador de Requicitos +general.configuration = Configuración +general.delete = Eliminar +issue.resolution = Resolución del Problema +requirement.type = Tipo de Requicito \ No newline at end of file diff --git a/VM-Core/src/main/resources/com/validation/manager/resources/VMMessages_fr_FR.properties b/VM-Core/src/main/resources/com/validation/manager/resources/VMMessages_fr_FR.properties index ba21db36..c5e7e80c 100755 --- a/VM-Core/src/main/resources/com/validation/manager/resources/VMMessages_fr_FR.properties +++ b/VM-Core/src/main/resources/com/validation/manager/resources/VMMessages_fr_FR.properties @@ -52,7 +52,6 @@ creation.time=Creation Time #Delete delete.error=Unable to delete\! -delete.error\!=Unable to delete\! delete.execution=Delete Execution delete.with.issues.message=There are attachment(s), issue(s) and/or comment(s) present in the execution. delete.with.issues.title=Want to delete even with identified issues? @@ -100,7 +99,7 @@ general.assignment.date=Assignment Date general.attachment=Attachments general.audit.menu=Audit Trail Menu general.cancel=Cancel -general.comclusion=Conclusion +general.conclusion=Conclusion general.comment=Comment general.comments=Comments general.conclusion=Conclusion @@ -233,7 +232,7 @@ message.requirement.import.missing.column=Not enough columns in data source (%c) message.requirement.import.success=Requirement import completed\! message.requirement.import.verify=Please review the requirements to be imported. message.requirement.status=Status -message.requirement.type=Requirement Type +requirement.type=Requirement Type message.section.dnd.invalid=Invalid to move section to this location\! message.spec.level=Specification Level message.step.create=Create Step diff --git a/VM-Core/src/main/resources/com/validation/manager/resources/VMMessages_zh_CN.properties b/VM-Core/src/main/resources/com/validation/manager/resources/VMMessages_zh_CN.properties index ba21db36..c5e7e80c 100755 --- a/VM-Core/src/main/resources/com/validation/manager/resources/VMMessages_zh_CN.properties +++ b/VM-Core/src/main/resources/com/validation/manager/resources/VMMessages_zh_CN.properties @@ -52,7 +52,6 @@ creation.time=Creation Time #Delete delete.error=Unable to delete\! -delete.error\!=Unable to delete\! delete.execution=Delete Execution delete.with.issues.message=There are attachment(s), issue(s) and/or comment(s) present in the execution. delete.with.issues.title=Want to delete even with identified issues? @@ -100,7 +99,7 @@ general.assignment.date=Assignment Date general.attachment=Attachments general.audit.menu=Audit Trail Menu general.cancel=Cancel -general.comclusion=Conclusion +general.conclusion=Conclusion general.comment=Comment general.comments=Comments general.conclusion=Conclusion @@ -233,7 +232,7 @@ message.requirement.import.missing.column=Not enough columns in data source (%c) message.requirement.import.success=Requirement import completed\! message.requirement.import.verify=Please review the requirements to be imported. message.requirement.status=Status -message.requirement.type=Requirement Type +requirement.type=Requirement Type message.section.dnd.invalid=Invalid to move section to this location\! message.spec.level=Specification Level message.step.create=Create Step diff --git a/VM-Core/src/main/resources/db/migration/V1_4__New_Setings.sql b/VM-Core/src/main/resources/db/migration/V1_4__New_Setings.sql new file mode 100644 index 00000000..1765c2fb --- /dev/null +++ b/VM-Core/src/main/resources/db/migration/V1_4__New_Setings.sql @@ -0,0 +1,14 @@ +/*Add settings*/ +INSERT INTO `vm_setting` (`id`, `setting`, `bool_val`, `int_val`, `long_val`, `string_val`) VALUES (13, 'mail.smtp.host', 0, 0, '0', 'smtp.gmail.com'); +INSERT INTO `vm_setting` (`id`, `setting`, `bool_val`, `int_val`, `long_val`, `string_val`) VALUES (14, 'mail.smtp.socketFactory.class', 0, 0, '0', 'javax.net.ssl.SSLSocketFactory'); +INSERT INTO `vm_setting` (`id`, `setting`, `bool_val`, `int_val`, `long_val`, `string_val`) VALUES (15, 'mail.smtp.socketFactory.fallback', 0, 0, '0', NULL);/*False*/ +INSERT INTO `vm_setting` (`id`, `setting`, `bool_val`, `int_val`, `long_val`, `string_val`) VALUES (16, 'mail.smtp.port', 0, 465, '0', NULL);/*Gmail as default*/ +INSERT INTO `vm_setting` (`id`, `setting`, `bool_val`, `int_val`, `long_val`, `string_val`) VALUES (17, 'mail.smtp.socketFactory.port', 0, 465, '0', NULL); +INSERT INTO `vm_setting` (`id`, `setting`, `bool_val`, `int_val`, `long_val`, `string_val`) VALUES (18, 'mail.smtp.auth', 1, 0, '0', NULL); +INSERT INTO `vm_setting` (`id`, `setting`, `bool_val`, `int_val`, `long_val`, `string_val`) VALUES (19, 'mail.smtp.quitwait', 0, 0, '0', NULL);/*False*/ +INSERT INTO `vm_setting` (`id`, `setting`, `bool_val`, `int_val`, `long_val`, `string_val`) VALUES (20, 'mail.smtp.starttls.enable', 1, 0, '0', NULL); +INSERT INTO `vm_setting` (`id`, `setting`, `bool_val`, `int_val`, `long_val`, `string_val`) VALUES (21, 'mail.auth.username', 1, 0, '0', NULL); +INSERT INTO `vm_setting` (`id`, `setting`, `bool_val`, `int_val`, `long_val`, `string_val`) VALUES (22, 'mail.auth.password', 1, 0, '0', NULL); +INSERT INTO `vm_setting` (`id`, `setting`, `bool_val`, `int_val`, `long_val`, `string_val`) VALUES (23, 'mail.enable', 0, 0, '0', NULL); +/*Fix typos*/ +UPDATE `role` set description = 'reserved.desc' where id in (1,2); \ No newline at end of file diff --git a/VM-Core/src/test/java/com/validation/manager/core/api/email/IEmailManagerTest.java b/VM-Core/src/test/java/com/validation/manager/core/api/email/IEmailManagerTest.java new file mode 100644 index 00000000..3a47fd54 --- /dev/null +++ b/VM-Core/src/test/java/com/validation/manager/core/api/email/IEmailManagerTest.java @@ -0,0 +1,79 @@ +/* + * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.validation.manager.core.api.email; + +import com.validation.manager.test.AbstractVMTestCase; +import de.saly.javamail.mock2.MockMailbox; +import java.util.Arrays; +import javax.mail.Message; +import org.junit.Test; +import org.openide.util.Lookup; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class IEmailManagerTest extends AbstractVMTestCase { + + /** + * Test of sendEmail method, of class IEmailManager. + * + * @throws java.lang.Exception + */ + @Test + public void testSendEmail() throws Exception { + System.out.println("sendEmail"); + String to = "target@test.com"; + String cc = "cc@test.com"; + String from = "from@test.com"; + String subject = "Sample Email"; + String bodyText = "Hello World!"; + //Setup mock email server + MockMailbox toMailbox = MockMailbox.get(to); + MockMailbox ccMailbox = MockMailbox.get(cc); + MockMailbox fromMailbox = MockMailbox.get(from); + assertEquals(0, toMailbox.getInbox().getMessageCount()); + assertEquals(0, ccMailbox.getInbox().getMessageCount()); + assertEquals(0, fromMailbox.getInbox().getMessageCount()); + IEmailManager instance = Lookup.getDefault().lookup(IEmailManager.class); + instance.sendEmail(to, cc, from, subject, bodyText); + assertEquals(1, toMailbox.getInbox().getMessageCount()); + for (Message m : toMailbox.getInbox().getMessages()) { + System.out.println(m.getMessageNumber()); + System.out.println("From: " + Arrays.toString(m.getFrom())); + assertEquals(1, m.getFrom().length); + assertEquals(from, m.getFrom()[0].toString()); + System.out.println("Sent: " + m.getSentDate()); + System.out.println(m.getSubject()); + assertEquals(subject, m.getSubject()); + System.out.println(m.getContent()); + assertEquals(bodyText, m.getContent()); + } + assertEquals(1, ccMailbox.getInbox().getMessageCount()); + for (Message m : ccMailbox.getInbox().getMessages()) { + System.out.println(m.getMessageNumber()); + System.out.println("From: " + Arrays.toString(m.getFrom())); + assertEquals(1, m.getFrom().length); + assertEquals(from, m.getFrom()[0].toString()); + System.out.println("Sent: " + m.getSentDate()); + System.out.println(m.getSubject()); + assertEquals(subject, m.getSubject()); + System.out.println(m.getContent()); + assertEquals(bodyText, m.getContent()); + } + assertEquals(0, fromMailbox.getInbox().getMessageCount()); + } +} diff --git a/VM-Core/src/test/java/com/validation/manager/core/api/internationalization/InternationalizationProviderTest.java b/VM-Core/src/test/java/com/validation/manager/core/api/internationalization/InternationalizationProviderTest.java new file mode 100644 index 00000000..4f9e90bf --- /dev/null +++ b/VM-Core/src/test/java/com/validation/manager/core/api/internationalization/InternationalizationProviderTest.java @@ -0,0 +1,65 @@ +/* + * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.validation.manager.core.api.internationalization; + +import java.util.Locale; +import static junit.framework.TestCase.*; +import org.junit.Test; +import org.openide.util.Lookup; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class InternationalizationProviderTest { + + /** + * Test of translate method, of class InternationalizationProvider. + */ + @Test + public void testTranslate_String() { + System.out.println("translate"); + String mess = "general.active"; + InternationalizationProvider instance + = Lookup.getDefault().lookup(InternationalizationProvider.class); + assertNotNull(instance.translate(mess)); + } + + /** + * Test of translate method, of class InternationalizationProvider. + */ + @Test + public void testTranslate_String_Locale() { + System.out.println("translate"); + String mess = "general.active"; + Locale l = new Locale("es"); + InternationalizationProvider instance + = Lookup.getDefault().lookup(InternationalizationProvider.class); + assertNotNull(instance.translate(mess, l)); + assertNotSame(instance.translate(mess), instance.translate(mess, l)); + } + + /** + * Test of getResourceBundle method, of class InternationalizationProvider. + */ + @Test + public void testGetResourceBundle() { + System.out.println("getResourceBundle"); + InternationalizationProvider instance + = Lookup.getDefault().lookup(InternationalizationProvider.class); + assertNotNull(instance.getResourceBundle()); + } +} diff --git a/VM-Core/src/test/java/com/validation/manager/core/db/ProjectTest.java b/VM-Core/src/test/java/com/validation/manager/core/db/ProjectTest.java index 45820285..52caed5a 100755 --- a/VM-Core/src/test/java/com/validation/manager/core/db/ProjectTest.java +++ b/VM-Core/src/test/java/com/validation/manager/core/db/ProjectTest.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,119 +13,110 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import static com.validation.manager.core.DataBaseManager.getEntityManagerFactory; -import com.validation.manager.core.VMException; -import com.validation.manager.core.db.controller.ProjectJpaController; -import com.validation.manager.core.server.core.ProjectServer; -import static com.validation.manager.core.server.core.ProjectServer.deleteProject; -import com.validation.manager.core.server.core.StepServer; -import com.validation.manager.core.server.core.TestCaseServer; -import com.validation.manager.core.tool.Tool; -import com.validation.manager.test.AbstractVMTestCase; -import static com.validation.manager.test.TestHelper.addRequirementToStep; -import static com.validation.manager.test.TestHelper.addStep; -import static com.validation.manager.test.TestHelper.addTestCaseToPlan; -import static com.validation.manager.test.TestHelper.createProject; -import static com.validation.manager.test.TestHelper.createRequirement; -import static com.validation.manager.test.TestHelper.createRequirementSpec; -import static com.validation.manager.test.TestHelper.createRequirementSpecNode; -import static com.validation.manager.test.TestHelper.createTestCase; -import static com.validation.manager.test.TestHelper.createTestPlan; -import static com.validation.manager.test.TestHelper.createTestProject; -import java.text.MessageFormat; -import java.util.logging.Level; -import java.util.logging.Logger; -import static java.util.logging.Logger.getLogger; -import static junit.framework.TestCase.assertEquals; -import org.junit.After; -import org.junit.Test; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class ProjectTest extends AbstractVMTestCase { - - private Project p; - private static final Logger LOG - = getLogger(ProjectTest.class.getName()); - - @After - public void clear() { - if (p != null) { - try { - deleteProject(p); - } - catch (VMException ex) { - LOG.log(Level.SEVERE, null, ex); - } - } - } - - /** - * Test of toString method, of class Project. - */ - @Test - public void testCreateAndDestroy() { - try { - p = createProject("New Project", "Notes"); - assertEquals(0, Tool.extractRequirements(p).size()); - ProjectServer project = new ProjectServer(p); - project.setNotes("Notes 2"); - project.write2DB(); - Project temp = new ProjectJpaController( - getEntityManagerFactory()) - .findProject(project.getId()); - assertTrue(temp.getNotes().equals(project.getNotes())); - //Create requirements - LOG.info("Create Requirement Spec"); - RequirementSpec rss = null; - try { - rss = createRequirementSpec("Test", "Test", - project, 1); - } - catch (Exception ex) { - LOG.log(Level.SEVERE, null, ex); - fail(); - } - LOG.info("Create Requirement Spec Node"); - RequirementSpecNode rsns = null; - try { - rsns = createRequirementSpecNode( - rss, "Test", "Test", "Test"); - } - catch (Exception ex) { - LOG.log(Level.SEVERE, null, ex); - fail(); - } - Requirement r = createRequirement("SRS-SW-0001", - "Sample requirement", rsns.getRequirementSpecNodePK(), - "Notes", 1, 1); - //Create Test Case - TestCase tc = createTestCase("Dummy", "Summary"); - //Add steps - for (int i = 1; i < 6; i++) { - LOG.info(MessageFormat.format("Adding step: {0}", i)); - tc = addStep(tc, i, "Step " + i, "Note " + i, "Result " + i); - Step step = tc.getStepList().get(i - 1); - addRequirementToStep(step, r); - new TestCaseServer(tc).write2DB(); - assertEquals(1, new StepServer(step).getRequirementList().size()); - } - //Create test Project - TestProject tp = createTestProject("Test Project"); - //Create test plan - TestPlan plan = createTestPlan(tp, "Notes", true, true); - //Add test to plan - addTestCaseToPlan(plan, tc); - project.write2DB(); - assertEquals(1, Tool.extractRequirements(project.getEntity()).size()); - } - catch (Exception ex) { - LOG.log(Level.SEVERE, null, ex); - fail(); - } - } -} +package com.validation.manager.core.db; + +import com.validation.manager.core.DataBaseManager; +import static com.validation.manager.core.DataBaseManager.getEntityManagerFactory; +import com.validation.manager.core.db.controller.ProjectJpaController; +import com.validation.manager.core.db.controller.TestPlanJpaController; +import com.validation.manager.core.server.core.ProjectServer; +import com.validation.manager.core.server.core.StepServer; +import com.validation.manager.core.server.core.TestCaseServer; +import com.validation.manager.core.server.core.TestPlanServer; +import com.validation.manager.core.tool.Tool; +import com.validation.manager.test.AbstractVMTestCase; +import static com.validation.manager.test.TestHelper.addRequirementToStep; +import static com.validation.manager.test.TestHelper.addStep; +import static com.validation.manager.test.TestHelper.addTestCaseToPlan; +import static com.validation.manager.test.TestHelper.createProject; +import static com.validation.manager.test.TestHelper.createRequirement; +import static com.validation.manager.test.TestHelper.createRequirementSpec; +import static com.validation.manager.test.TestHelper.createRequirementSpecNode; +import static com.validation.manager.test.TestHelper.createTestCase; +import static com.validation.manager.test.TestHelper.createTestPlan; +import static com.validation.manager.test.TestHelper.createTestProject; +import java.text.MessageFormat; +import java.util.logging.Level; +import java.util.logging.Logger; +import static java.util.logging.Logger.getLogger; +import static junit.framework.TestCase.assertEquals; +import org.junit.Test; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class ProjectTest extends AbstractVMTestCase { + + private Project p; + private static final Logger LOG + = getLogger(ProjectTest.class.getName()); + + /** + * Test of toString method, of class Project. + */ + @Test + public void testCreateAndDestroy() { + try { + p = createProject("New Project", "Notes"); + assertEquals(0, Tool.extractRequirements(p).size()); + ProjectServer project = new ProjectServer(p); + project.setNotes("Notes 2"); + project.write2DB(); + Project temp = new ProjectJpaController( + getEntityManagerFactory()) + .findProject(project.getId()); + assertTrue(temp.getNotes().equals(project.getNotes())); + //Create requirements + LOG.info("Create Requirement Spec"); + RequirementSpec rss = null; + try { + rss = createRequirementSpec("Test", "Test", + project, 1); + } + catch (Exception ex) { + LOG.log(Level.SEVERE, null, ex); + fail(); + } + LOG.info("Create Requirement Spec Node"); + RequirementSpecNode rsns; + try { + rsns = createRequirementSpecNode( + rss, "Test", "Test", "Test"); + Requirement r = createRequirement("SRS-SW-0001", + "Sample requirement", rsns.getRequirementSpecNodePK(), + "Notes", 1, 1); + //Create Test Case + TestCase tc = createTestCase("Dummy", "Summary"); + //Add steps + for (int i = 1; i < 6; i++) { + LOG.info(MessageFormat.format("Adding step: {0}", i)); + tc = addStep(tc, i, "Step " + i, "Note " + i, "Result " + i); + Step step = tc.getStepList().get(i - 1); + addRequirementToStep(step, r); + new TestCaseServer(tc).write2DB(); + assertEquals(1, new StepServer(step).getRequirementList().size()); + } + //Create test Project + TestProject tp = createTestProject("Test Project"); + //Create test plan + TestPlan plan = createTestPlan(tp, "Notes", true, true); + //Add test to plan + addTestCaseToPlan(plan, tc); + project.write2DB(); + assertEquals(1, Tool.extractRequirements(project.getEntity()).size()); + TestPlanServer.deleteTestPlan(plan); + assertNull(new TestPlanJpaController(DataBaseManager + .getEntityManagerFactory()).findTestPlan(plan.getTestPlanPK())); + } + catch (Exception ex) { + LOG.log(Level.SEVERE, null, ex); + fail(); + } + } + catch (Exception ex) { + LOG.log(Level.SEVERE, null, ex); + fail(); + } + } +} diff --git a/VM-Core/src/test/java/com/validation/manager/core/db/RequirementHierarchyTest.java b/VM-Core/src/test/java/com/validation/manager/core/db/RequirementHierarchyTest.java index a65b802d..3e6f1ac0 100755 --- a/VM-Core/src/test/java/com/validation/manager/core/db/RequirementHierarchyTest.java +++ b/VM-Core/src/test/java/com/validation/manager/core/db/RequirementHierarchyTest.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,175 +13,180 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import static com.validation.manager.core.DataBaseManager.getEntityManagerFactory; -import com.validation.manager.core.db.controller.RequirementJpaController; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import com.validation.manager.core.server.core.ProjectServer; -import com.validation.manager.core.server.core.RequirementServer; -import com.validation.manager.core.server.core.RequirementSpecNodeServer; -import com.validation.manager.core.server.core.RequirementSpecServer; -import com.validation.manager.core.server.core.SpecLevelServer; -import com.validation.manager.test.AbstractVMTestCase; -import com.validation.manager.test.TestHelper; -import static com.validation.manager.test.TestHelper.createRequirement; -import static com.validation.manager.test.TestHelper.createRequirementSpecNode; -import java.util.ArrayList; -import java.util.List; -import java.util.logging.Level; -import java.util.logging.Logger; -import static java.util.logging.Logger.getLogger; -import org.junit.Test; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class RequirementHierarchyTest extends AbstractVMTestCase { - - private static final Logger LOG - = getLogger(RequirementHierarchyTest.class.getName()); - private ProjectServer project; - - @Test - public void testHierarchy() { - System.out.println("Test Requirement Hierarchy"); - System.out.println("Create Project"); - project = new ProjectServer("Test product", "Project Notes"); - try { - project.write2DB(); - } catch (IllegalOrphanException ex) { - LOG.log(Level.SEVERE, null, ex); - fail(); - } catch (NonexistentEntityException ex) { - LOG.log(Level.SEVERE, null, ex); - fail(); - } catch (Exception ex) { - LOG.log(Level.SEVERE, null, ex); - fail(); - } - System.out.println("Create Requirement Spec"); - RequirementSpec rss = null; - try { - rss = TestHelper.createRequirementSpec("Test", "Test", - project, 1); - } catch (Exception ex) { - LOG.log(Level.SEVERE, null, ex); - fail(); - } - System.out.println("Create Requirement Spec Node"); - RequirementSpecNode rsns = null; - try { - rsns = createRequirementSpecNode( - rss, "Test", "Test", "Test"); - } catch (Exception ex) { - LOG.log(Level.SEVERE, null, ex); - fail(); - } - System.out.println("Create Requirements"); - List requirements = new ArrayList<>(); - int requirementAmount = 15; - for (int i = 0; i < requirementAmount; i++) { - try { - Requirement reqs - = createRequirement("SRS-SW-00" + i, - "Description " + i, - rsns.getRequirementSpecNodePK(), - "Notes " + i, 2, 1); - requirements.add(new RequirementJpaController( - getEntityManagerFactory()) - .findRequirement(reqs.getId())); - } catch (Exception ex) { - LOG.log(Level.SEVERE, null, ex); - fail(); - } - } - System.out.println("Done!"); - System.out.println("Create Requirement Spec Levels"); - SpecLevelServer userSpecLevel = createSpecLevel("User Requirement"); - SpecLevelServer functionalSpecLevel - = createSpecLevel("Functional Requirement"); - SpecLevelServer unitSpecLevel = createSpecLevel("Unit Requirement"); - System.out.println("Done!"); - System.out.println("Create Requirement Specs"); - RequirementSpecServer productSpec = createRequirementSpec( - "Project Spec", userSpecLevel); - RequirementSpecServer archSpec = createRequirementSpec( - "Architectural Spec", functionalSpecLevel); - RequirementSpecServer swSpec = createRequirementSpec( - "Software Spec", unitSpecLevel); - System.out.println("Done!"); - System.out.println("Adding requirements to spec nodes"); - try { - RequirementSpecNodeServer n1 - = productSpec.addSpecNode("Node 1", "description", "scope"); - requirements.subList(0, 5).forEach((r) -> { - n1.getRequirementList().add(r); - }); - n1.write2DB(); - assertEquals(1, productSpec.getRequirementSpecNodeList().size()); - RequirementSpecNodeServer n2 - = archSpec.addSpecNode("Node 2", "description", "scope"); - requirements.subList(5, 10).forEach((r) -> { - n2.getRequirementList().add(r); - }); - n2.write2DB(); - assertEquals(1, archSpec.getRequirementSpecNodeList().size()); - RequirementSpecNodeServer n3 - = swSpec.addSpecNode("Node 3", "description", "scope"); - requirements.subList(10, 15).forEach((r) -> { - n3.getRequirementList().add(r); - }); - n3.write2DB(); - assertEquals(1, swSpec.getRequirementSpecNodeList().size()); - } catch (Exception ex) { - LOG.log(Level.SEVERE, null, ex); - fail(); - } - System.out.println("Done!"); - System.out.println("Adding requirements to requirements"); - int count = 0; - for (Requirement req : requirements) { - try { - req.getRequirementList().add(requirements.get(requirementAmount - count - 1)); - new RequirementServer(req).write2DB(); - count++; - } catch (Exception ex) { - LOG.log(Level.SEVERE, null, ex); - fail(); - } - } - System.out.println("Done!"); - } - - private SpecLevelServer createSpecLevel(String name) { - SpecLevelServer sl = new SpecLevelServer(name, name + " Level"); - try { - assertTrue(sl.write2DB() > 0); - } catch (IllegalOrphanException ex) { - LOG.log(Level.SEVERE, null, ex); - fail(); - } catch (NonexistentEntityException ex) { - LOG.log(Level.SEVERE, null, ex); - fail(); - } catch (Exception ex) { - LOG.log(Level.SEVERE, null, ex); - fail(); - } - return sl; - } - - private RequirementSpecServer createRequirementSpec(String name, SpecLevelServer sl) { - RequirementSpecServer rss = new RequirementSpecServer(name, - "description", project.getId(), sl.getId()); - try { - rss.write2DB(); - } catch (Exception ex) { - LOG.log(Level.SEVERE, null, ex); - fail(); - } - return rss; - } -} +package com.validation.manager.core.db; + +import static com.validation.manager.core.DataBaseManager.getEntityManagerFactory; +import com.validation.manager.core.VMException; +import com.validation.manager.core.db.controller.RequirementJpaController; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import com.validation.manager.core.server.core.ProjectServer; +import com.validation.manager.core.server.core.RequirementServer; +import com.validation.manager.core.server.core.RequirementSpecNodeServer; +import com.validation.manager.core.server.core.RequirementSpecServer; +import com.validation.manager.core.server.core.SpecLevelServer; +import com.validation.manager.test.AbstractVMTestCase; +import com.validation.manager.test.TestHelper; +import static com.validation.manager.test.TestHelper.createRequirement; +import static com.validation.manager.test.TestHelper.createRequirementSpecNode; +import java.util.ArrayList; +import java.util.List; +import java.util.logging.Level; +import java.util.logging.Logger; +import static java.util.logging.Logger.getLogger; +import org.junit.Test; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class RequirementHierarchyTest extends AbstractVMTestCase { + + private static final Logger LOG + = getLogger(RequirementHierarchyTest.class.getName()); + private ProjectServer project; + + @Test + public void testHierarchy() { + System.out.println("Test Requirement Hierarchy"); + System.out.println("Create Project"); + project = new ProjectServer("Test product", "Project Notes"); + try { + project.write2DB(); + } + catch (VMException ex) { + LOG.log(Level.SEVERE, null, ex); + fail(); + } + System.out.println("Create Requirement Spec"); + RequirementSpec rss = null; + try { + rss = TestHelper.createRequirementSpec("Test", "Test", + project, 1); + } + catch (Exception ex) { + LOG.log(Level.SEVERE, null, ex); + fail(); + } + System.out.println("Create Requirement Spec Node"); + RequirementSpecNode rsns = null; + try { + rsns = createRequirementSpecNode( + rss, "Test", "Test", "Test"); + } + catch (Exception ex) { + LOG.log(Level.SEVERE, null, ex); + fail(); + } + System.out.println("Create Requirements"); + List requirements = new ArrayList<>(); + int requirementAmount = 15; + for (int i = 0; i < requirementAmount; i++) { + try { + Requirement reqs + = createRequirement("SRS-SW-00" + i, + "Description " + i, + rsns.getRequirementSpecNodePK(), + "Notes " + i, 2, 1); + requirements.add(new RequirementJpaController( + getEntityManagerFactory()) + .findRequirement(reqs.getId())); + } + catch (Exception ex) { + LOG.log(Level.SEVERE, null, ex); + fail(); + } + } + System.out.println("Done!"); + System.out.println("Create Requirement Spec Levels"); + SpecLevelServer userSpecLevel = createSpecLevel("User Requirement"); + SpecLevelServer functionalSpecLevel + = createSpecLevel("Functional Requirement"); + SpecLevelServer unitSpecLevel = createSpecLevel("Unit Requirement"); + System.out.println("Done!"); + System.out.println("Create Requirement Specs"); + RequirementSpecServer productSpec = createRequirementSpec( + "Project Spec", userSpecLevel); + RequirementSpecServer archSpec = createRequirementSpec( + "Architectural Spec", functionalSpecLevel); + RequirementSpecServer swSpec = createRequirementSpec( + "Software Spec", unitSpecLevel); + System.out.println("Done!"); + System.out.println("Adding requirements to spec nodes"); + try { + RequirementSpecNodeServer n1 + = productSpec.addSpecNode("Node 1", "description", "scope"); + requirements.subList(0, 5).forEach((r) -> { + n1.getRequirementList().add(r); + }); + n1.write2DB(); + assertEquals(1, productSpec.getRequirementSpecNodeList().size()); + RequirementSpecNodeServer n2 + = archSpec.addSpecNode("Node 2", "description", "scope"); + requirements.subList(5, 10).forEach((r) -> { + n2.getRequirementList().add(r); + }); + n2.write2DB(); + assertEquals(1, archSpec.getRequirementSpecNodeList().size()); + RequirementSpecNodeServer n3 + = swSpec.addSpecNode("Node 3", "description", "scope"); + requirements.subList(10, 15).forEach((r) -> { + n3.getRequirementList().add(r); + }); + n3.write2DB(); + assertEquals(1, swSpec.getRequirementSpecNodeList().size()); + } + catch (Exception ex) { + LOG.log(Level.SEVERE, null, ex); + fail(); + } + System.out.println("Done!"); + System.out.println("Adding requirements to requirements"); + int count = 0; + for (Requirement req : requirements) { + try { + req.getRequirementList().add(requirements.get(requirementAmount - count - 1)); + new RequirementServer(req).write2DB(); + count++; + } + catch (Exception ex) { + LOG.log(Level.SEVERE, null, ex); + fail(); + } + } + System.out.println("Done!"); + } + + private SpecLevelServer createSpecLevel(String name) { + SpecLevelServer sl = new SpecLevelServer(name, name + " Level"); + try { + assertTrue(sl.write2DB() > 0); + } + catch (IllegalOrphanException ex) { + LOG.log(Level.SEVERE, null, ex); + fail(); + } + catch (NonexistentEntityException ex) { + LOG.log(Level.SEVERE, null, ex); + fail(); + } + catch (Exception ex) { + LOG.log(Level.SEVERE, null, ex); + fail(); + } + return sl; + } + + private RequirementSpecServer createRequirementSpec(String name, SpecLevelServer sl) { + RequirementSpecServer rss = new RequirementSpecServer(name, + "description", project.getId(), sl.getId()); + try { + rss.write2DB(); + } + catch (Exception ex) { + LOG.log(Level.SEVERE, null, ex); + fail(); + } + return rss; + } +} diff --git a/VM-Core/src/test/java/com/validation/manager/core/db/UserTest.java b/VM-Core/src/test/java/com/validation/manager/core/db/UserTest.java index c90d9e84..f70f626c 100755 --- a/VM-Core/src/test/java/com/validation/manager/core/db/UserTest.java +++ b/VM-Core/src/test/java/com/validation/manager/core/db/UserTest.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,57 +13,56 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.db; - -import static com.validation.manager.core.DataBaseManager.getEntityManagerFactory; -import static com.validation.manager.core.DataBaseManager.namedQuery; -import com.validation.manager.core.db.controller.UserStatusJpaController; -import com.validation.manager.core.db.controller.VmUserJpaController; -import static com.validation.manager.core.tool.MD5.encrypt; -import com.validation.manager.test.AbstractVMTestCase; -import java.util.Date; -import java.util.logging.Level; -import static java.util.logging.Logger.getLogger; -import org.junit.Test; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class UserTest extends AbstractVMTestCase { - - @Test - @SuppressWarnings({"unchecked"}) - public void testCreateAndDeleteUser() { - try { - getLogger(UserTest.class.getSimpleName()).log(Level.INFO, - "Available users: {0}", - new VmUserJpaController(getEntityManagerFactory()) - .getVmUserCount()); - getLogger(UserTest.class.getSimpleName()).log(Level.INFO, - "Create an user"); - VmUser u = new VmUser("test", - encrypt("password"), "test@test.com", - "first", "last", "en", new Date(), - new UserStatusJpaController(getEntityManagerFactory()) - .findUserStatus(1), 0); - u.setUserStatusId(new UserStatusJpaController( - getEntityManagerFactory()).findUserStatus(1)); - new VmUserJpaController(getEntityManagerFactory()).create(u); - parameters.clear(); - parameters.put("username", "test"); - result = namedQuery("VmUser.findByUsername", parameters); - assertTrue(result.size() > 0); - u = (VmUser) result.get(0); - getLogger(UserTest.class.getSimpleName()).log(Level.INFO, - "Delete an user"); - new VmUserJpaController(getEntityManagerFactory()) - .destroy(u.getId()); - result = namedQuery("VmUser.findByUsername", parameters); - assertTrue(result.isEmpty()); - } - catch (Exception e) { - fail(e.getMessage()); - } - } -} +package com.validation.manager.core.db; + +import static com.validation.manager.core.DataBaseManager.getEntityManagerFactory; +import static com.validation.manager.core.DataBaseManager.namedQuery; +import com.validation.manager.core.db.controller.UserStatusJpaController; +import com.validation.manager.core.db.controller.VmUserJpaController; +import static com.validation.manager.core.tool.MD5.encrypt; +import com.validation.manager.test.AbstractVMTestCase; +import java.util.logging.Level; +import static java.util.logging.Logger.getLogger; +import org.junit.Test; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class UserTest extends AbstractVMTestCase { + + @Test + @SuppressWarnings({"unchecked"}) + public void testCreateAndDeleteUser() { + try { + getLogger(UserTest.class.getSimpleName()).log(Level.INFO, + "Available users: {0}", + new VmUserJpaController(getEntityManagerFactory()) + .getVmUserCount()); + getLogger(UserTest.class.getSimpleName()).log(Level.INFO, + "Create an user"); + VmUser u = new VmUser("test", + encrypt("password"), "test@test.com", + "first", "last", "en", + new UserStatusJpaController(getEntityManagerFactory()) + .findUserStatus(1), 0); + u.setUserStatusId(new UserStatusJpaController( + getEntityManagerFactory()).findUserStatus(1)); + new VmUserJpaController(getEntityManagerFactory()).create(u); + parameters.clear(); + parameters.put("username", "test"); + result = namedQuery("VmUser.findByUsername", parameters); + assertTrue(result.size() > 0); + u = (VmUser) result.get(0); + getLogger(UserTest.class.getSimpleName()).log(Level.INFO, + "Delete an user"); + new VmUserJpaController(getEntityManagerFactory()) + .destroy(u.getId()); + result = namedQuery("VmUser.findByUsername", parameters); + assertTrue(result.isEmpty()); + } + catch (Exception e) { + fail(e.getMessage()); + } + } +} diff --git a/VM-Core/src/test/java/com/validation/manager/core/history/VersionableTest.java b/VM-Core/src/test/java/com/validation/manager/core/history/VersionableTest.java new file mode 100644 index 00000000..bd07119c --- /dev/null +++ b/VM-Core/src/test/java/com/validation/manager/core/history/VersionableTest.java @@ -0,0 +1,289 @@ +/* + * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.validation.manager.core.history; + +import com.validation.manager.core.DataBaseManager; +import com.validation.manager.core.DemoBuilder; +import com.validation.manager.core.db.History; +import com.validation.manager.core.db.controller.HistoryJpaController; +import com.validation.manager.test.AbstractVMTestCase; +import java.lang.reflect.Field; +import java.util.ArrayList; +import java.util.List; +import javax.persistence.EntityManager; +import javax.persistence.metamodel.EntityType; +import static junit.framework.TestCase.assertEquals; +import org.apache.commons.lang3.reflect.FieldUtils; +import org.junit.Test; +import org.openide.util.Exceptions; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class VersionableTest extends AbstractVMTestCase { + + /** + * Test of increaseMajorVersion method, of class Versionable. + */ + @Test + public void testIncreaseMajorVersion() { + System.out.println("increaseMajorVersion"); + Versionable instance = new VersionableImpl(); + assertEquals(0, (int) instance.getMajorVersion()); + assertEquals(0, (int) instance.getMidVersion()); + assertEquals(1, (int) instance.getMinorVersion()); + instance.increaseMajorVersion(); + assertEquals(1, (int) instance.getMajorVersion()); + assertEquals(0, (int) instance.getMidVersion()); + assertEquals(0, (int) instance.getMinorVersion()); + assertEquals(2, instance.getHistoryList().size()); + checkHistory(instance); + } + + /** + * Test of increaseMidVersion method, of class Versionable. + */ + @Test + public void testIncreaseMidVersion() { + System.out.println("increaseMidVersion"); + Versionable instance = new VersionableImpl(); + assertEquals(0, (int) instance.getMajorVersion()); + assertEquals(0, (int) instance.getMidVersion()); + assertEquals(1, (int) instance.getMinorVersion()); + instance.increaseMidVersion(); + assertEquals(0, (int) instance.getMajorVersion()); + assertEquals(1, (int) instance.getMidVersion()); + assertEquals(0, (int) instance.getMinorVersion()); + assertEquals(2, instance.getHistoryList().size()); + checkHistory(instance); + } + + /** + * Test of toString method, of class Versionable. + */ + @Test + public void testToString() { + System.out.println("toString"); + Versionable instance = new VersionableImpl(); + String r = instance.toString(); + assertEquals("Version: " + instance.getMajorVersion() + + "." + instance.getMidVersion() + "." + + instance.getMinorVersion(), instance.toString()); + instance.increaseMajorVersion(); + assertEquals("Version: " + instance.getMajorVersion() + + "." + instance.getMidVersion() + "." + + instance.getMinorVersion(), instance.toString()); + instance.increaseMidVersion(); + assertEquals("Version: " + instance.getMajorVersion() + + "." + instance.getMidVersion() + "." + + instance.getMinorVersion(), instance.toString()); + } + + /** + * Test of compareTo method, of class Versionable. + */ + @Test + public void testCompareTo() { + System.out.println("compareTo"); + Versionable instance = new VersionableImpl(); + assertEquals(0, instance.compareTo(new VersionableImpl())); + instance.increaseMidVersion(); + assertEquals(1, instance.compareTo(new VersionableImpl())); + Versionable instance2 = new VersionableImpl(); + instance2.increaseMajorVersion(); + assertEquals(-1, instance.compareTo(instance2)); + } + + /** + * Test of auditable method, of class Versionable. + */ + @Test + public void testAuditable() { + try { + System.out.println("auditable"); + VersionableImpl v = new VersionableImpl(); + assertEquals(true, Versionable.auditable(v)); + v.updateHistory(); + assertEquals(1, v.getHistoryList().size()); + assertEquals(false, Versionable.auditable(v)); + v.setField1(2); + v.updateHistory(); + assertEquals(1, v.getHistoryList().size()); + assertEquals(false, Versionable.auditable(v)); + v.setField2("new value"); + assertEquals(true, Versionable.auditable(v)); + v.updateHistory(); + assertEquals(2, v.getHistoryList().size()); + } + catch (Exception ex) { + Exceptions.printStackTrace(ex); + fail(); + } + } + + @Test + public void testVersioning() { + try { + DemoBuilder.buildDemoProject(); + EntityManager em = DataBaseManager.getEntityManager(); + //Populate with demo classes. + for (EntityType entity : em.getMetamodel().getEntities()) { + if (Versionable.class.isAssignableFrom(entity.getJavaType())) { + final String className = entity.getName(); + System.out.println("Testing class: " + className); + //Make sure they have at least one auditable field. + List fields = FieldUtils + .getFieldsListWithAnnotation(entity.getJavaType(), + Auditable.class); + assertEquals(false, fields.isEmpty()); + //Get one from the demo data + Versionable v = (Versionable) DataBaseManager.createdQuery("Select a from " + + entity.getJavaType().getSimpleName() + + " a").get(0); + assertNotNull(v); + v.updateHistory(); + int count = v.getHistoryList().size(); + for (Field f : fields) { + //Now pick one of the Auditable fields + assertEquals(count, v.getHistoryList().size()); + History history = v.getHistoryList().get(v + .getHistoryList().size() - 1); + assertEquals(count == 1 ? "audit.general.creation" + : "audit.general.modified", history.getReason()); + assertEquals(0, history.getMajorVersion()); + assertEquals(0, history.getMidVersion()); + assertEquals(count++, history.getMinorVersion()); + assertEquals(1, (int) history.getModifierId().getId()); + assertNotNull(history.getModificationTime()); + assertTrue(checkHistory(v)); + assertFalse(Versionable.auditable(v)); + System.out.println("Changing field: " + + f.getName() + " Type: " + + f.getType().getSimpleName()); + f.setAccessible(true); + if (f.getType() == Integer.class) { + Integer current = (Integer) f.get(v); + Integer newValue = current + 1; + showChange(current, newValue); + f.set(v, newValue); + } else if (f.getType() == String.class) { + String current = (String) f.get(v); + String newValue = current + 1; + showChange(current, newValue); + f.set(v, newValue); + } else if (f.getType() == byte[].class) { + byte[] current = (byte[]) f.get(v); + byte[] append = "1".getBytes(); + byte[] newValue = new byte[current.length + append.length]; + showChange(current, newValue); + f.set(v, newValue); + } else if (f.getType() == Boolean.class) { + Boolean current = (Boolean) f.get(v); + Boolean newValue = !current; + showChange(current, newValue); + f.set(v, newValue); + } else { + fail("Unexpected field type: " + + f.getType().getSimpleName()); + } + assertTrue(Versionable.auditable(v)); + v.updateHistory(); + assertEquals(count, v.getHistoryList().size()); + history = v.getHistoryList().get(v.getHistoryList().size() - 1); + assertEquals(0, history.getMajorVersion()); + assertEquals(0, history.getMidVersion()); + assertEquals(count, history.getMinorVersion()); + assertEquals(1, (int) history.getModifierId().getId()); + assertEquals("audit.general.modified", history.getReason()); + assertNotNull(history.getModificationTime()); + assertTrue(checkHistory(v)); + assertFalse(Versionable.auditable(v)); + int total = new HistoryJpaController(DataBaseManager + .getEntityManagerFactory()).getHistoryCount(); + //Test for issue #25 https://github.com/javydreamercsw/validation-manager/issues/25 + + v = (Versionable) DataBaseManager.getEntityManager().find(entity.getJavaType(), + DataBaseManager.getEntityManagerFactory() + .getPersistenceUnitUtil().getIdentifier(v)); + assertTrue(checkHistory(v)); + assertEquals(total, new HistoryJpaController(DataBaseManager + .getEntityManagerFactory()).getHistoryCount()); + assertEquals(count, v.getHistoryList().size()); + } + } + } + } + catch (Exception ex) { + Exceptions.printStackTrace(ex); + fail(); + } + } + + private void showChange(Object current, Object newValue) { + System.out.println("Changing int value from: " + + current + " to: " + + newValue); + } + + public class VersionableImpl extends Versionable { + + private List history = new ArrayList<>(); + + private int field1; + + @Auditable + private String field2; + + @Override + public List getHistoryList() { + return history; + } + + @Override + public void setHistoryList(List historyList) { + this.history = historyList; + } + + /** + * @return the field1 + */ + public int getField1() { + return field1; + } + + /** + * @param field1 the field1 to set + */ + public void setField1(int field1) { + this.field1 = field1; + } + + /** + * @return the field2 + */ + public String getField2() { + return field2; + } + + /** + * @param field2 the field2 to set + */ + public void setField2(String field2) { + this.field2 = field2; + } + } +} diff --git a/VM-Core/src/test/java/com/validation/manager/core/server/core/AttachmentTypeServerTest.java b/VM-Core/src/test/java/com/validation/manager/core/server/core/AttachmentTypeServerTest.java new file mode 100644 index 00000000..1367279c --- /dev/null +++ b/VM-Core/src/test/java/com/validation/manager/core/server/core/AttachmentTypeServerTest.java @@ -0,0 +1,52 @@ +/* + * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.validation.manager.core.server.core; + +import com.validation.manager.test.AbstractVMTestCase; +import org.junit.Test; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class AttachmentTypeServerTest extends AbstractVMTestCase { + + /** + * Test of write2DB method, of class AttachmentTypeServer. + * + * @throws java.lang.Exception + */ + @Test + public void testWrite2DB() throws Exception { + System.out.println("write2DB"); + AttachmentTypeServer instance = new AttachmentTypeServer(1); + instance.setType("Type2"); + instance.setDescription("Desc2"); + instance.write2DB(); + assertEquals("Type2", instance.getEntity().getType()); + assertEquals("Desc2", instance.getEntity().getDescription()); + } + + /** + * Test of getTypeForExtension method, of class AttachmentTypeServer. + */ + @Test + public void testGetTypeForExtension() { + System.out.println("getTypeForExtension"); + assertNotNull(AttachmentTypeServer.getTypeForExtension("txt")); + assertNull(AttachmentTypeServer.getTypeForExtension("dummy")); + } +} diff --git a/VM-Core/src/test/java/com/validation/manager/core/server/core/ExecutionResultServerTest.java b/VM-Core/src/test/java/com/validation/manager/core/server/core/ExecutionResultServerTest.java new file mode 100644 index 00000000..ef69233b --- /dev/null +++ b/VM-Core/src/test/java/com/validation/manager/core/server/core/ExecutionResultServerTest.java @@ -0,0 +1,63 @@ +/* + * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.validation.manager.core.server.core; + +import com.validation.manager.core.DataBaseManager; +import com.validation.manager.core.db.controller.ExecutionResultJpaController; +import com.validation.manager.test.AbstractVMTestCase; +import org.junit.Test; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class ExecutionResultServerTest extends AbstractVMTestCase { + + /** + * Test of write2DB method, of class ExecutionResultServer. + * + * @throws java.lang.Exception + */ + @Test + public void testWrite2DB() throws Exception { + System.out.println("write2DB"); + ExecutionResultServer instance = new ExecutionResultServer(1); + instance.setResultName("test"); + instance.write2DB(); + assertEquals("test", instance.getEntity().getResultName()); + } + + /** + * Test of getResult method, of class ExecutionResultServer. + */ + @Test + public void testGetResult() { + System.out.println("getResult"); + assertNotNull(ExecutionResultServer.getResult("result.pass")); + assertNull(ExecutionResultServer.getResult("result.dummy")); + } + + /** + * Test of getResults method, of class ExecutionResultServer. + */ + @Test + public void testGetResults() { + System.out.println("getResults"); + assertEquals(new ExecutionResultJpaController(DataBaseManager + .getEntityManagerFactory()).getExecutionResultCount(), + ExecutionResultServer.getResults().size()); + } +} diff --git a/VM-Core/src/test/java/com/validation/manager/core/server/core/IssueTypeServerTest.java b/VM-Core/src/test/java/com/validation/manager/core/server/core/IssueTypeServerTest.java new file mode 100644 index 00000000..653d9733 --- /dev/null +++ b/VM-Core/src/test/java/com/validation/manager/core/server/core/IssueTypeServerTest.java @@ -0,0 +1,52 @@ +/* + * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.validation.manager.core.server.core; + +import com.validation.manager.test.AbstractVMTestCase; +import org.junit.Test; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class IssueTypeServerTest extends AbstractVMTestCase { + + /** + * Test of write2DB method, of class IssueTypeServer. + * + * @throws java.lang.Exception + */ + @Test + public void testWrite2DB() throws Exception { + System.out.println("write2DB"); + IssueTypeServer instance = new IssueTypeServer(1); + instance.setTypeName("test"); + instance.setDescription("desc"); + instance.write2DB(); + assertEquals("test", instance.getEntity().getTypeName()); + assertEquals("desc", instance.getEntity().getDescription()); + } + + /** + * Test of getType method, of class IssueTypeServer. + */ + @Test + public void testGetType() { + System.out.println("getType"); + assertNotNull(IssueTypeServer.getType("bug.name")); + assertNull(IssueTypeServer.getType("dummy")); + } +} diff --git a/VM-Core/src/test/java/com/validation/manager/core/server/core/NotificationServerTest.java b/VM-Core/src/test/java/com/validation/manager/core/server/core/NotificationServerTest.java index 7c753cb8..72685e34 100644 --- a/VM-Core/src/test/java/com/validation/manager/core/server/core/NotificationServerTest.java +++ b/VM-Core/src/test/java/com/validation/manager/core/server/core/NotificationServerTest.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,52 +13,60 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.server.core; - -import com.validation.manager.test.AbstractVMTestCase; -import java.util.Date; -import org.junit.Test; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class NotificationServerTest extends AbstractVMTestCase { - - /** - * Test of write2DB method, of class NotificationServer. - * - * @throws java.lang.Exception - */ - @Test - public void testWrite2DB() throws Exception { - System.out.println("write2DB"); - VMUserServer author = new VMUserServer(1); - VMUserServer target = new VMUserServer(2); - NotificationServer instance = new NotificationServer(); - instance.setAuthor(author.getEntity()); - instance.setContent("Hello there!"); - instance.setCreationDate(new Date()); - instance.setNotificationType(NotificationTypeServer - .getType("notification.test.pending")); - instance.setTargetUser(target.getEntity()); - assertEquals(0, author.getNotificationList().size()); - assertEquals(0, target.getNotificationList().size()); - assertEquals(0, author.getNotificationList1().size()); - assertEquals(0, target.getNotificationList1().size()); - instance.write2DB(); - author.update(); - target.update(); - assertEquals(0, author.getNotificationList().size()); - assertEquals(1, target.getNotificationList().size()); - assertEquals(1, author.getNotificationList1().size()); - assertEquals(0, target.getNotificationList1().size()); - assertEquals(0, author.getPendingNotifications().size()); - assertEquals(1, target.getPendingNotifications().size()); - NotificationServer ns = new NotificationServer(target - .getNotificationList().get(0)); - ns.setAcknowledgeDate(new Date()); - ns.write2DB(); - assertEquals(0, target.getPendingNotifications().size()); - } -} +package com.validation.manager.core.server.core; + +import com.validation.manager.test.AbstractVMTestCase; +import java.util.Date; +import org.junit.Test; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class NotificationServerTest extends AbstractVMTestCase { + + /** + * Test of write2DB method, of class NotificationServer. + * + * @throws java.lang.Exception + */ + @Test + public void testWrite2DB() throws Exception { + System.out.println("write2DB"); + VMUserServer author = new VMUserServer(1); + VMUserServer target = new VMUserServer(2); + NotificationServer instance = new NotificationServer(); + instance.setAuthor(author.getEntity()); + instance.setContent("Hello there!"); + instance.setCreationDate(new Date()); + instance.setNotificationType(NotificationTypeServer + .getType("notification.test.pending")); + instance.setTargetUser(target.getEntity()); + assertEquals(0, author.getNotificationList().size()); + assertEquals(0, target.getNotificationList().size()); + assertEquals(0, author.getNotificationList1().size()); + assertEquals(0, target.getNotificationList1().size()); + instance.write2DB(); + author.update(); + target.update(); + assertEquals(0, author.getNotificationList().size()); + assertEquals(1, target.getNotificationList().size()); + assertEquals(1, author.getNotificationList1().size()); + assertEquals(0, target.getNotificationList1().size()); + assertEquals(0, author.getPendingNotifications().size()); + assertEquals(1, target.getPendingNotifications().size()); + NotificationServer ns = new NotificationServer(target + .getNotificationList().get(0)); + ns.setAcknowledgeDate(new Date()); + ns.write2DB(); + assertEquals(0, target.getPendingNotifications().size()); + NotificationServer instance2 = new NotificationServer(); + instance2.setAuthor(author.getEntity()); + instance2.setContent("Hello there!"); + instance2.setCreationDate(new Date()); + instance2.setNotificationType(NotificationTypeServer + .getType("notification.test.pending")); + instance2.setTargetUser(target.getEntity()); + instance2.write2DB(); + } +} diff --git a/VM-Core/src/test/java/com/validation/manager/core/server/core/ProjectServerTest.java b/VM-Core/src/test/java/com/validation/manager/core/server/core/ProjectServerTest.java index 2acc3e88..dda0d483 100644 --- a/VM-Core/src/test/java/com/validation/manager/core/server/core/ProjectServerTest.java +++ b/VM-Core/src/test/java/com/validation/manager/core/server/core/ProjectServerTest.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,159 +13,92 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.server.core; - -import com.validation.manager.core.DataBaseManager; -import com.validation.manager.core.VMException; -import com.validation.manager.core.db.Project; -import com.validation.manager.core.db.Requirement; -import com.validation.manager.core.db.RequirementSpec; -import com.validation.manager.core.db.RequirementSpecNode; -import com.validation.manager.core.db.controller.ProjectJpaController; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import com.validation.manager.core.tool.Tool; -import com.validation.manager.test.AbstractVMTestCase; -import com.validation.manager.test.TestHelper; -import java.util.logging.Level; -import java.util.logging.Logger; -import static junit.framework.TestCase.assertTrue; -import static junit.framework.TestCase.fail; -import org.junit.Test; -import org.openide.util.Exceptions; -import static org.openide.util.Exceptions.printStackTrace; - -/** - * - * @author jortiz00 - */ -public class ProjectServerTest extends AbstractVMTestCase { - - private Project p; - private static final Logger LOG - = Logger.getLogger(ProjectServerTest.class.getSimpleName()); - - @Override - protected void postSetUp() { - try { - RequirementSpec rss = null; - p = TestHelper.createProject("New Project", "Notes"); - ProjectServer project = new ProjectServer(p); - project.setNotes("Notes 2"); - project.write2DB(); - assertTrue(new ProjectJpaController( - DataBaseManager.getEntityManagerFactory()) - .findProject(project.getId()).getNotes().equals(project.getNotes())); - //Create requirements - System.out.println("Create Requirement Spec"); - try { - rss = TestHelper.createRequirementSpec("Test", "Test", - project, 1); - } - catch (Exception ex) { - LOG.log(Level.SEVERE, null, ex); - fail(); - } - System.out.println("Create Requirement Spec Node"); - try { - TestHelper.createRequirementSpecNode( - rss, "Test", "Test", "Test"); - } - catch (Exception ex) { - LOG.log(Level.SEVERE, null, ex); - fail(); - } - } - catch (NonexistentEntityException ex) { - Exceptions.printStackTrace(ex); - } - catch (Exception ex) { - Exceptions.printStackTrace(ex); - } - } - - /** - * Test of create and deleteProject method, of class ProjectServer. - */ - @Test - public void testCreateAndDeleteProject() { - try { - System.out.println("Create a project"); - Project root = TestHelper.createProject("Test", "Notes"); - System.out.println("Add a sub project"); - Project sub = TestHelper.addProject(root, "Sub", "Notes"); - System.out.println("Create Spec for main project."); - //No errors, nothing dependent - try { - ProjectServer.deleteProject(sub); - } - catch (VMException ex) { - printStackTrace(ex); - fail(); - } - assertTrue(Tool.extractRequirements(root).isEmpty()); - RequirementSpec mainSpec - = TestHelper.createRequirementSpec("Spec", "Desc", root, 1); - assertTrue(!root.getRequirementSpecList().isEmpty()); - assertEquals(0, Tool.extractRequirements(root).size()); - sub = TestHelper.addProject(root, "Sub", "Notes"); - System.out.println("Create Spec for sub project."); - RequirementSpec spec = TestHelper.createRequirementSpec("Spec 2", - "Desc", sub, 1); - RequirementSpecNode node = TestHelper.createRequirementSpecNode(mainSpec, - "Requirement Doc", "Desc", "Scope"); - Requirement req1 = TestHelper.createRequirement("REQ-001", "Desc", - node.getRequirementSpecNodePK(), "Notes", 1, 1); - assertEquals(1, Tool.extractRequirements(root).size()); - Requirement req2 = TestHelper.createRequirement("REQ-002", "Desc", - node.getRequirementSpecNodePK(), "Notes", 1, 1); - assertEquals(2, Tool.extractRequirements(root).size()); - TestHelper.addChildToRequirement(req1, req2); - try { - ProjectServer.deleteProject(sub); - } - catch (VMException ex) { - //Expected failure - System.out.println("Expected failure!"); - } - RequirementSpecServer.deleteRequirementSpec(spec); - try { - ProjectServer.deleteProject(new ProjectServer(sub).getEntity()); - } - catch (VMException ex) { - printStackTrace(ex); - fail(); - } - } - catch (Exception ex) { - printStackTrace(ex); - fail(); - } - } - - @Test - public void testExtractTestProjects() { - try { - System.out.println("Add Test Project"); - TestHelper.addTestProjectToProject(TestHelper - .createTestProject("Test"), p); - for (int i = 0; i < 5; i++) { - Project sub = TestHelper.addProject(p, "Sub #" + i, - "Notes #" + i); - TestHelper.addTestProjectToProject(TestHelper - .createTestProject("Test"), sub); - } - ProjectServer ps = new ProjectServer(p); - assertEquals(1, ps.getTestProjects(false).size()); - assertEquals(1 + ps.getProjectList().size(), - ps.getTestProjects(true).size()); - } - catch (NonexistentEntityException ex) { - Exceptions.printStackTrace(ex); - fail(); - } - catch (Exception ex) { - Exceptions.printStackTrace(ex); - fail(); - } - } -} +package com.validation.manager.core.server.core; + +import com.validation.manager.core.DataBaseManager; +import com.validation.manager.core.VMException; +import com.validation.manager.core.db.Project; +import com.validation.manager.core.db.RequirementSpec; +import com.validation.manager.core.db.controller.ProjectJpaController; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import com.validation.manager.test.AbstractVMTestCase; +import com.validation.manager.test.TestHelper; +import java.util.logging.Level; +import java.util.logging.Logger; +import static junit.framework.TestCase.assertTrue; +import static junit.framework.TestCase.fail; +import org.junit.Test; + +/** + * + * @author jortiz00 + */ +public class ProjectServerTest extends AbstractVMTestCase { + + private Project p; + private static final Logger LOG + = Logger.getLogger(ProjectServerTest.class.getSimpleName()); + + @Override + protected void postSetUp() { + try { + RequirementSpec rss = null; + p = TestHelper.createProject("New Project", "Notes"); + ProjectServer project = new ProjectServer(p); + project.setNotes("Notes 2"); + project.write2DB(); + assertTrue(new ProjectJpaController( + DataBaseManager.getEntityManagerFactory()) + .findProject(project.getId()).getNotes().equals(project.getNotes())); + //Create requirements + System.out.println("Create Requirement Spec"); + try { + rss = TestHelper.createRequirementSpec("Test", "Test", + project, 1); + } + catch (Exception ex) { + LOG.log(Level.SEVERE, null, ex); + fail(); + } + System.out.println("Create Requirement Spec Node"); + try { + TestHelper.createRequirementSpecNode( + rss, "Test", "Test", "Test"); + } + catch (Exception ex) { + LOG.log(Level.SEVERE, null, ex); + fail(); + } + } + catch (VMException ex) { + LOG.log(Level.SEVERE, null, ex); + } + } + + @Test + public void testExtractTestProjects() { + try { + System.out.println("Add Test Project"); + TestHelper.addTestProjectToProject(TestHelper + .createTestProject("Test"), p); + for (int i = 0; i < 5; i++) { + Project sub = TestHelper.addProject(p, "Sub #" + i, + "Notes #" + i); + TestHelper.addTestProjectToProject(TestHelper + .createTestProject("Test"), sub); + } + ProjectServer ps = new ProjectServer(p); + assertEquals(1, ps.getTestProjects(false).size()); + assertEquals(1 + ps.getProjectList().size(), + ps.getTestProjects(true).size()); + } + catch (NonexistentEntityException ex) { + LOG.log(Level.SEVERE, null, ex); + fail(); + } + catch (Exception ex) { + LOG.log(Level.SEVERE, null, ex); + fail(); + } + } +} diff --git a/VM-Core/src/test/java/com/validation/manager/core/server/core/RequirementServerTest.java b/VM-Core/src/test/java/com/validation/manager/core/server/core/RequirementServerTest.java index 38b8e36e..aa5dab43 100644 --- a/VM-Core/src/test/java/com/validation/manager/core/server/core/RequirementServerTest.java +++ b/VM-Core/src/test/java/com/validation/manager/core/server/core/RequirementServerTest.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,390 +13,313 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.server.core; - -import com.validation.manager.core.DataBaseManager; -import com.validation.manager.core.db.History; -import com.validation.manager.core.db.Project; -import com.validation.manager.core.db.Requirement; -import com.validation.manager.core.db.RequirementSpec; -import com.validation.manager.core.db.RequirementSpecNode; -import com.validation.manager.core.db.Step; -import com.validation.manager.core.db.TestCase; -import com.validation.manager.core.db.TestPlan; -import com.validation.manager.core.db.TestProject; -import com.validation.manager.core.db.VmUser; -import com.validation.manager.core.db.controller.HistoryJpaController; -import com.validation.manager.core.db.controller.ProjectJpaController; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import com.validation.manager.test.AbstractVMTestCase; -import com.validation.manager.test.TestHelper; -import java.util.logging.Level; -import java.util.logging.Logger; -import static java.util.logging.Logger.getLogger; -import org.junit.Test; -import org.openide.util.Exceptions; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class RequirementServerTest extends AbstractVMTestCase { - - private static final Logger LOG - = getLogger(RequirementServerTest.class.getName()); - private Project p; - private RequirementSpecNode rsn; - - @Override - protected void postSetUp() { - try { - RequirementSpec rss = null; - p = TestHelper.createProject("New Project", "Notes"); - ProjectServer project = new ProjectServer(p); - project.setNotes("Notes 2"); - project.write2DB(); - assertTrue(new ProjectJpaController( - DataBaseManager.getEntityManagerFactory()) - .findProject(project.getId()).getNotes().equals(project.getNotes())); - //Create requirements - System.out.println("Create Requirement Spec"); - try { - rss = TestHelper.createRequirementSpec("Test", "Test", - project, 1); - } - catch (Exception ex) { - LOG.log(Level.SEVERE, null, ex); - fail(); - } - System.out.println("Create Requirement Spec Node"); - try { - rsn = TestHelper.createRequirementSpecNode( - rss, "Test", "Test", "Test"); - } - catch (Exception ex) { - LOG.log(Level.SEVERE, null, ex); - fail(); - } - } - catch (NonexistentEntityException ex) { - Exceptions.printStackTrace(ex); - } - catch (Exception ex) { - Exceptions.printStackTrace(ex); - } - } - - /** - * Test of update method, of class RequirementServer. - */ - @Test - public void testUpdate() { - try { - System.out.println("update"); - Requirement source = TestHelper.createRequirement("SRS-SW-0001", - "Sample requirement", rsn.getRequirementSpecNodePK(), - "Notes", 1, 1); - RequirementServer instance = new RequirementServer(source); - assertEquals(1, instance.getHistoryList().size()); - int count = 1; - for (History h : instance.getHistoryList()) { - assertEquals(0, h.getMajorVersion()); - assertEquals(0, h.getMidVersion()); - assertEquals(count, h.getMinorVersion()); - count++; - } - Requirement target = new Requirement(); - instance.update(target, source); - assertEquals(instance.getUniqueId(), target.getUniqueId()); - assertEquals(instance.getDescription(), target.getDescription()); - assertEquals(instance.getNotes(), target.getNotes()); - assertEquals(instance.getRequirementTypeId().getId(), - target.getRequirementTypeId().getId()); - assertEquals(instance.getRequirementStatusId().getId(), - target.getRequirementStatusId().getId()); - assertEquals(instance.getHistoryList().size(), - target.getHistoryList().size()); - } - catch (Exception ex) { - LOG.log(Level.SEVERE, null, ex); - fail(); - } - } - - /** - * Test of isDuplicate method, of class RequirementServer. - */ - @Test - public void testIsDuplicate() { - try { - System.out.println("isDuplicate"); - Requirement source = TestHelper.createRequirement("SRS-SW-0001", - "Sample requirement", rsn.getRequirementSpecNodePK(), - "Notes", 1, 1); - Requirement source2 = TestHelper.createRequirement("SRS-SW-0002", - "Sample requirement", rsn.getRequirementSpecNodePK(), - "Notes", 1, 1); - assertEquals(false, RequirementServer.isDuplicate(source)); - assertEquals(false, RequirementServer.isDuplicate(source2)); - Requirement source3 = TestHelper.createRequirement("SRS-SW-0002", - "Sample requirement", rsn.getRequirementSpecNodePK(), - "Notes", 1, 1); - assertEquals(true, RequirementServer.isDuplicate(source3)); - } - catch (Exception ex) { - LOG.log(Level.SEVERE, null, ex); - fail(); - } - } - - /** - * Test of getTestCoverage method, of class RequirementServer. - */ - @Test - public void testGetTestCoverage() { - try { - System.out.println("getTestCoverage"); - Requirement req = TestHelper.createRequirement("SRS-SW-0001", - "Sample requirement", rsn.getRequirementSpecNodePK(), - "Notes", 1, 1); - Requirement req2 = TestHelper.createRequirement("SRS-SW-0002", - "Sample requirement", rsn.getRequirementSpecNodePK(), - "Notes", 1, 1); - Requirement req3 = TestHelper.createRequirement("SRS-SW-0003", - "Sample requirement", rsn.getRequirementSpecNodePK(), - "Notes", 1, 1); - Requirement req4 = TestHelper.createRequirement("SRS-SW-0004", - "Sample requirement", rsn.getRequirementSpecNodePK(), - "Notes", 1, 1); - Requirement userReq = TestHelper.createRequirement("PS-SW-0001", - "Sample User requirement", rsn.getRequirementSpecNodePK(), - "Notes", 1, 1); - RequirementServer rs = new RequirementServer(req); - assertEquals(0, rs.getTestCoverage()); - //Create Test Case - TestCase tc = TestHelper.createTestCase("Dummy", "Summary"); - //Add steps - int i = 1; - for (; i < 6; i++) { - LOG.log(Level.INFO, "Adding step: {0}", i); - tc = TestHelper.addStep(tc, i, "Step " + i, "Note " + i, "Result " + i); - Step step = tc.getStepList().get(i - 1); - TestHelper.addRequirementToStep(step, req); - new TestCaseServer(tc).write2DB(); - assertEquals(1, new StepServer(step).getRequirementList().size()); - } - LOG.log(Level.INFO, "Adding step: {0}", i); - tc = TestHelper.addStep(tc, i, "Step " + i, "Note " + i, "Result " + i); - Step step = tc.getStepList().get(i - 1); - TestHelper.addRequirementToStep(step, req3); - new TestCaseServer(tc).write2DB(); - //Create test Project - TestProject tp = TestHelper.createTestProject("Test Project"); - //Create test plan - TestPlan plan = TestHelper.createTestPlan(tp, "Notes", true, true); - //Add test to plan - TestHelper.addTestCaseToPlan(plan, tc); - rs.update(); - assertEquals(100, rs.getTestCoverage()); - //Add a related requirement - rs.addChildRequirement(req3); - assertEquals(100, rs.getTestCoverage()); - rs.addChildRequirement(req2); - assertEquals(50, rs.getTestCoverage()); - rs.addChildRequirement(req4); - assertEquals(33, rs.getTestCoverage()); - //Add related requirements to test coverage - RequirementServer ur = new RequirementServer(userReq); - assertEquals(0, ur.getTestCoverage()); - ur.addChildRequirement(req); - assertEquals(33, ur.getTestCoverage()); - } - catch (Exception ex) { - LOG.log(Level.SEVERE, null, ex); - fail(); - } - } - - /** - * Test of getChildrenRequirement method, of class RequirementServer. - */ - @Test - public void testChildAndParentRequirements() { - try { - System.out.println("Child And Parent Requirements"); - Requirement req = TestHelper.createRequirement("SRS-SW-0001", - "Sample requirement", rsn.getRequirementSpecNodePK(), - "Notes", 1, 1); - Requirement req2 = TestHelper.createRequirement("SRS-SW-0002", - "Sample requirement", rsn.getRequirementSpecNodePK(), - "Notes", 1, 1); - assertTrue(req.getRequirementList().isEmpty()); - //Add a child - RequirementServer rs = new RequirementServer(req); - //Add a version to the requirement - DataBaseManager.setVersioningEnabled(true); - rs.setDescription("Modified requirement"); - rs.write2DB(); - rs.addChildRequirement(req2); - RequirementServer rs2 = new RequirementServer(req2); - //Should have one children now - assertEquals(1, rs.getEntity().getRequirementList().size()); - //No parents - assertNull(rs.getEntity().getParentRequirementId()); - //One parent - assertNotNull(rs2.getEntity().getParentRequirementId()); - //No children - assertEquals(0, rs2.getEntity().getRequirementList().size()); - } - catch (Exception ex) { - LOG.log(Level.SEVERE, null, ex); - fail(); - } - } - - /** - * Test of requirement coverage with versioning method, of class - * RequirementServer. - */ - @Test - public void testRequirementCoverage() { - try { - System.out.println("Requirement Coverage and Versioning"); - //Enable versioning - DataBaseManager.setVersioningEnabled(true); - Requirement req = TestHelper.createRequirement("SRS-SW-0001", - "Description", rsn.getRequirementSpecNodePK(), "Notes", 1, 1); - RequirementServer rs = new RequirementServer(req); - //Add a test case covering this test case - TestProject tp = TestHelper.createTestProject("Test Project"); - TestHelper.addTestProjectToProject(tp, p); - TestPlan plan = TestHelper.createTestPlan(tp, "Plan", true, true); - TestCase tc = TestHelper.createTestCase("TC #1", - "Summary"); - TestHelper.addTestCaseToPlan(plan, tc); - TestCase step = TestHelper.addStep(tc, 1, "Test", "Test", "Result "); - rs.getStepList().add(step.getStepList().get(0)); - rs.write2DB(); - assertEquals(1, rs.getStepList().size()); - assertEquals(100, rs.getTestCoverage()); - //Update version and remove test coverage - rs.setDescription("New version"); - rs.getStepList().clear(); - rs.write2DB(); - assertEquals(0, rs.getStepList().size()); - rs.update(); - assertEquals(0, rs.getTestCoverage()); - rs.setDescription("New version 2"); - StepServer ss = new StepServer(step.getStepList().get(0)); - ss.removeRequirement(req); - ss.write2DB(); - ss.addRequirement(rs.getEntity()); - rs.update(); - rs.write2DB(); - assertEquals(1, rs.getStepList().size()); - assertEquals(100, rs.getTestCoverage()); - //Add a parent requirement - Requirement r = TestHelper.createRequirement("PS-0001", - "Description", rsn.getRequirementSpecNodePK(), - "Notes", 1, 1); - RequirementServer parent = new RequirementServer(r); - parent.addChildRequirement(req); - parent.write2DB(); - assertEquals(100, parent.getTestCoverage()); - assertEquals(100, rs.getTestCoverage()); - //Version parent - parent.setDescription("Version 2"); - parent.write2DB(); - assertEquals(100, parent.getTestCoverage()); - assertEquals(100, rs.getTestCoverage()); - } - catch (Exception ex) { - Exceptions.printStackTrace(ex); - fail(); - } - } - - @Test - public void testVersioning() { - try { - Requirement req = TestHelper.createRequirement("SRS-SW-0001", - "Description", rsn.getRequirementSpecNodePK(), - "Notes", 1, 1); - RequirementServer rs = new RequirementServer(req); - int historyCount = 1; - assertEquals(historyCount++, rs.getHistoryList().size()); - History history = rs.getHistoryList().get(rs - .getHistoryList().size() - 1); - assertEquals(0, history.getMajorVersion()); - assertEquals(0, history.getMidVersion()); - assertEquals(1, history.getMinorVersion()); - assertEquals(1, (int) history.getModifierId().getId()); - assertEquals("audit.general.creation", history.getReason()); - assertNotNull(history.getModificationTime()); - assertTrue(checkHistory(rs)); - rs.setDescription("desc 2"); - rs.write2DB(); - assertEquals(historyCount++, rs.getHistoryList().size()); - history = rs.getHistoryList().get(rs.getHistoryList().size() - 1); - assertEquals(0, history.getMajorVersion()); - assertEquals(0, history.getMidVersion()); - assertEquals(2, history.getMinorVersion()); - assertEquals(1, (int) history.getModifierId().getId()); - assertEquals("audit.general.modified", history.getReason()); - assertNotNull(history.getModificationTime()); - assertTrue(checkHistory(rs)); - rs.setDescription("desc 3"); - VmUser test = TestHelper.createUser("Test", "pass", "email", - "first", "last"); - rs.setModifierId(test.getId()); - rs.setReason("Test"); - rs.write2DB(); - assertEquals(historyCount++, rs.getHistoryList().size()); - history = rs.getHistoryList().get(rs.getHistoryList().size() - 1); - assertEquals(0, history.getMajorVersion()); - assertEquals(0, history.getMidVersion()); - assertEquals(3, history.getMinorVersion()); - assertEquals((int) test.getId(), (int) history.getModifierId().getId()); - assertEquals("Test", history.getReason()); - assertNotNull(history.getModificationTime()); - assertTrue(checkHistory(rs)); - rs.increaseMidVersion(); - assertEquals(historyCount++, rs.getHistoryList().size()); - history = rs.getHistoryList().get(rs.getHistoryList().size() - 1); - assertEquals(0, history.getMajorVersion()); - assertEquals(1, history.getMidVersion()); - assertEquals(0, history.getMinorVersion()); - //TODO: Handle mid and major changes on system - //assertEquals(1, (int) history.getModifierId().getId()); - //assertEquals("tbd", history.getReason()); - assertNotNull(history.getModificationTime()); - assertTrue(checkHistory(rs)); - rs.increaseMajorVersion(); - assertEquals(historyCount, rs.getHistoryList().size()); - history = rs.getHistoryList().get(rs.getHistoryList().size() - 1); - assertEquals(1, history.getMajorVersion()); - assertEquals(0, history.getMidVersion()); - assertEquals(0, history.getMinorVersion()); - //TODO: Handle mid and major changes on system - //assertEquals(1, (int) history.getModifierId().getId()); - //assertEquals("tbd", history.getReason()); - assertNotNull(history.getModificationTime()); - assertTrue(checkHistory(rs)); - int total = new HistoryJpaController(DataBaseManager - .getEntityManagerFactory()).getHistoryCount(); - //Test for issue #25 - //Disconnet to the database - DataBaseManager.close(); - //Reconnect - rs.update(); - assertEquals(total, new HistoryJpaController(DataBaseManager - .getEntityManagerFactory()).getHistoryCount()); - assertEquals(historyCount, rs.getHistoryList().size()); - } - catch (Exception ex) { - Exceptions.printStackTrace(ex); - fail(); - } - } -} +package com.validation.manager.core.server.core; + +import com.validation.manager.core.DataBaseManager; +import com.validation.manager.core.VMException; +import com.validation.manager.core.db.History; +import com.validation.manager.core.db.Project; +import com.validation.manager.core.db.Requirement; +import com.validation.manager.core.db.RequirementSpec; +import com.validation.manager.core.db.RequirementSpecNode; +import com.validation.manager.core.db.Step; +import com.validation.manager.core.db.TestCase; +import com.validation.manager.core.db.TestPlan; +import com.validation.manager.core.db.TestProject; +import com.validation.manager.core.db.controller.ProjectJpaController; +import com.validation.manager.test.AbstractVMTestCase; +import com.validation.manager.test.TestHelper; +import java.util.logging.Level; +import java.util.logging.Logger; +import static java.util.logging.Logger.getLogger; +import org.junit.Test; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class RequirementServerTest extends AbstractVMTestCase { + + private static final Logger LOG + = getLogger(RequirementServerTest.class.getName()); + private Project p; + private RequirementSpecNode rsn; + private RequirementSpec rss; + + @Override + protected void postSetUp() { + try { + p = TestHelper.createProject("New Project", "Notes"); + ProjectServer project = new ProjectServer(p); + project.setNotes("Notes 2"); + project.write2DB(); + assertTrue(new ProjectJpaController( + DataBaseManager.getEntityManagerFactory()) + .findProject(project.getId()).getNotes().equals(project.getNotes())); + //Create requirements + System.out.println("Create Requirement Spec"); + try { + rss = TestHelper.createRequirementSpec("Test", "Test", + project, 1); + } + catch (Exception ex) { + LOG.log(Level.SEVERE, null, ex); + fail(); + } + System.out.println("Create Requirement Spec Node"); + try { + rsn = TestHelper.createRequirementSpecNode( + rss, "Test", "Test", "Test"); + } + catch (Exception ex) { + LOG.log(Level.SEVERE, null, ex); + fail(); + } + } + catch (VMException ex) { + LOG.log(Level.SEVERE, null, ex); + } + } + + /** + * Test of update method, of class RequirementServer. + */ + @Test + public void testUpdate() { + try { + System.out.println("update"); + Requirement source = TestHelper.createRequirement("SRS-SW-0001", + "Sample requirement", rsn.getRequirementSpecNodePK(), + "Notes", 1, 1); + RequirementServer instance = new RequirementServer(source); + assertEquals(1, instance.getHistoryList().size()); + int count = 1; + for (History h : instance.getHistoryList()) { + assertEquals(0, h.getMajorVersion()); + assertEquals(0, h.getMidVersion()); + assertEquals(count, h.getMinorVersion()); + count++; + } + Requirement target = new Requirement(); + instance.update(target, source); + assertEquals(instance.getUniqueId(), target.getUniqueId()); + assertEquals(instance.getDescription(), target.getDescription()); + assertEquals(instance.getNotes(), target.getNotes()); + assertEquals(instance.getRequirementTypeId().getId(), + target.getRequirementTypeId().getId()); + assertEquals(instance.getRequirementStatusId().getId(), + target.getRequirementStatusId().getId()); + assertEquals(instance.getHistoryList().size(), + target.getHistoryList().size()); + } + catch (Exception ex) { + LOG.log(Level.SEVERE, null, ex); + fail(); + } + } + + /** + * Test of isDuplicate method, of class RequirementServer. + */ + @Test + public void testIsDuplicate() { + try { + System.out.println("isDuplicate"); + Requirement source = TestHelper.createRequirement("SRS-SW-0001", + "Sample requirement", rsn.getRequirementSpecNodePK(), + "Notes", 1, 1); + Requirement source2 = TestHelper.createRequirement("SRS-SW-0002", + "Sample requirement", rsn.getRequirementSpecNodePK(), + "Notes", 1, 1); + assertEquals(false, RequirementServer.isDuplicate(source)); + assertEquals(false, RequirementServer.isDuplicate(source2)); + Requirement source3 = TestHelper.createRequirement("SRS-SW-0002", + "Sample requirement", rsn.getRequirementSpecNodePK(), + "Notes", 1, 1); + assertEquals(true, RequirementServer.isDuplicate(source3)); + } + catch (Exception ex) { + LOG.log(Level.SEVERE, null, ex); + fail(); + } + } + + /** + * Test of getTestCoverage method, of class RequirementServer. + */ + @Test + public void testGetTestCoverage() { + try { + System.out.println("getTestCoverage"); + Requirement req = TestHelper.createRequirement("SRS-SW-0001", + "Sample requirement", rsn.getRequirementSpecNodePK(), + "Notes", 1, 1); + Requirement req2 = TestHelper.createRequirement("SRS-SW-0002", + "Sample requirement", rsn.getRequirementSpecNodePK(), + "Notes", 1, 1); + Requirement req3 = TestHelper.createRequirement("SRS-SW-0003", + "Sample requirement", rsn.getRequirementSpecNodePK(), + "Notes", 1, 1); + Requirement req4 = TestHelper.createRequirement("SRS-SW-0004", + "Sample requirement", rsn.getRequirementSpecNodePK(), + "Notes", 1, 1); + Requirement userReq = TestHelper.createRequirement("PS-SW-0001", + "Sample User requirement", rsn.getRequirementSpecNodePK(), + "Notes", 1, 1); + RequirementServer rs = new RequirementServer(req); + assertEquals(0, rs.getTestCoverage()); + //Create Test Case + TestCase tc = TestHelper.createTestCase("Dummy", "Summary"); + //Add steps + int i = 1; + for (; i < 6; i++) { + LOG.log(Level.INFO, "Adding step: {0}", i); + tc = TestHelper.addStep(tc, i, "Step " + i, "Note " + i, "Result " + i); + Step step = tc.getStepList().get(i - 1); + TestHelper.addRequirementToStep(step, req); + new TestCaseServer(tc).write2DB(); + assertEquals(1, new StepServer(step).getRequirementList().size()); + } + LOG.log(Level.INFO, "Adding step: {0}", i); + tc = TestHelper.addStep(tc, i, "Step " + i, "Note " + i, "Result " + i); + Step step = tc.getStepList().get(i - 1); + TestHelper.addRequirementToStep(step, req3); + new TestCaseServer(tc).write2DB(); + //Create test Project + TestProject tp = TestHelper.createTestProject("Test Project"); + //Create test plan + TestPlan plan = TestHelper.createTestPlan(tp, "Notes", true, true); + //Add test to plan + TestHelper.addTestCaseToPlan(plan, tc); + rs.update(); + assertEquals(100, rs.getTestCoverage()); + //Add a related requirement + rs.addChildRequirement(req3); + assertEquals(100, rs.getTestCoverage()); + rs.addChildRequirement(req2); + assertEquals(50, rs.getTestCoverage()); + rs.addChildRequirement(req4); + assertEquals(33, rs.getTestCoverage()); + //Add related requirements to test coverage + RequirementServer ur = new RequirementServer(userReq); + assertEquals(0, ur.getTestCoverage()); + ur.addChildRequirement(req); + assertEquals(33, ur.getTestCoverage()); + } + catch (Exception ex) { + LOG.log(Level.SEVERE, null, ex); + fail(); + } + } + + /** + * Test of getChildrenRequirement method, of class RequirementServer. + */ + @Test + public void testChildAndParentRequirements() { + try { + System.out.println("Child And Parent Requirements"); + Requirement req = TestHelper.createRequirement("SRS-SW-0001", + "Sample requirement", rsn.getRequirementSpecNodePK(), + "Notes", 1, 1); + Requirement req2 = TestHelper.createRequirement("SRS-SW-0002", + "Sample requirement", rsn.getRequirementSpecNodePK(), + "Notes", 1, 1); + assertTrue(req.getRequirementList().isEmpty()); + //Add a child + RequirementServer rs = new RequirementServer(req); + //Add a version to the requirement + DataBaseManager.setVersioningEnabled(true); + rs.setDescription("Modified requirement"); + rs.write2DB(); + rs.addChildRequirement(req2); + RequirementServer rs2 = new RequirementServer(req2); + //Should have one children now + assertEquals(1, rs.getEntity().getRequirementList().size()); + //No parents + assertNull(rs.getEntity().getParentRequirementId()); + //One parent + assertNotNull(rs2.getEntity().getParentRequirementId()); + //No children + assertEquals(0, rs2.getEntity().getRequirementList().size()); + } + catch (Exception ex) { + LOG.log(Level.SEVERE, null, ex); + fail(); + } + } + + @Test + public void testGetRequirements() throws Exception { + assertEquals(0, RequirementSpecServer.getRequirements(rss).size()); + TestHelper.createRequirement("SRS-SW-0001", + "Sample requirement", rsn.getRequirementSpecNodePK(), + "Notes", 1, 1); + TestHelper.createRequirement("SRS-SW-0002", + "Sample requirement", rsn.getRequirementSpecNodePK(), + "Notes", 1, 1); + assertEquals(2, RequirementSpecServer.getRequirements(rss).size()); + } + + /** + * Test of requirement coverage with versioning method, of class + * RequirementServer. + */ + @Test + public void testRequirementCoverage() { + try { + System.out.println("Requirement Coverage and Versioning"); + //Enable versioning + DataBaseManager.setVersioningEnabled(true); + Requirement req = TestHelper.createRequirement("SRS-SW-0001", + "Description", rsn.getRequirementSpecNodePK(), "Notes", 1, 1); + RequirementServer rs = new RequirementServer(req); + //Add a test case covering this test case + TestProject tp = TestHelper.createTestProject("Test Project"); + TestHelper.addTestProjectToProject(tp, p); + TestPlan plan = TestHelper.createTestPlan(tp, "Plan", true, true); + TestCase tc = TestHelper.createTestCase("TC #1", + "Summary"); + TestHelper.addTestCaseToPlan(plan, tc); + TestCase step = TestHelper.addStep(tc, 1, "Test", "Test", "Result "); + rs.getStepList().add(step.getStepList().get(0)); + rs.write2DB(); + assertEquals(1, rs.getStepList().size()); + assertEquals(100, rs.getTestCoverage()); + //Update version and remove test coverage + rs.setDescription("New version"); + rs.getStepList().clear(); + rs.write2DB(); + assertEquals(0, rs.getStepList().size()); + rs.update(); + assertEquals(0, rs.getTestCoverage()); + rs.setDescription("New version 2"); + StepServer ss = new StepServer(step.getStepList().get(0)); + ss.removeRequirement(req); + ss.write2DB(); + ss.addRequirement(rs.getEntity()); + rs.update(); + rs.write2DB(); + assertEquals(1, rs.getStepList().size()); + assertEquals(100, rs.getTestCoverage()); + //Add a parent requirement + Requirement r = TestHelper.createRequirement("PS-0001", + "Description", rsn.getRequirementSpecNodePK(), + "Notes", 1, 1); + RequirementServer parent = new RequirementServer(r); + parent.addChildRequirement(req); + parent.write2DB(); + assertEquals(100, parent.getTestCoverage()); + assertEquals(100, rs.getTestCoverage()); + //Version parent + parent.setDescription("Version 2"); + parent.write2DB(); + assertEquals(100, parent.getTestCoverage()); + assertEquals(100, rs.getTestCoverage()); + } + catch (Exception ex) { + LOG.log(Level.SEVERE, null, ex); + fail(); + } + } +} diff --git a/VM-Core/src/main/java/com/validation/manager/core/tool/Timer.java b/VM-Core/src/test/java/com/validation/manager/core/server/core/RequirementStatusServerTest.java similarity index 50% rename from VM-Core/src/main/java/com/validation/manager/core/tool/Timer.java rename to VM-Core/src/test/java/com/validation/manager/core/server/core/RequirementStatusServerTest.java index d55690d1..30692cef 100644 --- a/VM-Core/src/main/java/com/validation/manager/core/tool/Timer.java +++ b/VM-Core/src/test/java/com/validation/manager/core/server/core/RequirementStatusServerTest.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,34 +13,28 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.tool; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class Timer { - - private long start, end; - - public Timer() { - reset(); - } - - public void stop() { - end = System.nanoTime(); - } - - public final void reset() { - start = System.nanoTime(); - } - - public String elapsedTime() { - long timeelapsed = (end - start); - long milliseconds = timeelapsed / 1000; - long seconds = (timeelapsed / 1000) % 60; - long minutes = (timeelapsed / 60000) % 60; - return " (" + minutes + ":" + seconds - + ":" + milliseconds + ")"; - } -} +package com.validation.manager.core.server.core; + +import com.validation.manager.test.AbstractVMTestCase; +import org.junit.Test; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class RequirementStatusServerTest extends AbstractVMTestCase { + + /** + * Test of write2DB method, of class RequirementStatusServer. + * + * @throws java.lang.Exception + */ + @Test + public void testWrite2DB() throws Exception { + System.out.println("write2DB"); + RequirementStatusServer instance = new RequirementStatusServer("test"); + instance.write2DB(); + assertEquals(instance.getStatus(), instance.getEntity().getStatus()); + assertTrue(instance.getId() > 0); + } +} diff --git a/VM-Core/src/test/java/com/validation/manager/core/server/core/RequirementTypeServerTest.java b/VM-Core/src/test/java/com/validation/manager/core/server/core/RequirementTypeServerTest.java new file mode 100644 index 00000000..3e43cdbf --- /dev/null +++ b/VM-Core/src/test/java/com/validation/manager/core/server/core/RequirementTypeServerTest.java @@ -0,0 +1,52 @@ +/* + * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.validation.manager.core.server.core; + +import com.validation.manager.core.DataBaseManager; +import com.validation.manager.core.db.controller.RequirementTypeJpaController; +import com.validation.manager.test.AbstractVMTestCase; +import org.junit.Test; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class RequirementTypeServerTest extends AbstractVMTestCase { + + /** + * Test of write2DB method, of class RequirementTypeServer. + * + * @throws java.lang.Exception + */ + @Test + public void testWrite2DB() throws Exception { + System.out.println("write2DB"); + RequirementTypeServer instance = new RequirementTypeServer("test"); + instance.write2DB(); + assertEquals(instance.getName(), instance.getEntity().getName()); + } + + /** + * Test of getRequirementTypes method, of class RequirementTypeServer. + */ + @Test + public void testGetRequirementTypes() { + System.out.println("getRequirementTypes"); + assertEquals(new RequirementTypeJpaController(DataBaseManager + .getEntityManagerFactory()).getRequirementTypeCount(), + RequirementTypeServer.getRequirementTypes().size()); + } +} diff --git a/VM-Core/src/test/java/com/validation/manager/core/server/core/ReviewResultServerTest.java b/VM-Core/src/test/java/com/validation/manager/core/server/core/ReviewResultServerTest.java new file mode 100644 index 00000000..6952a830 --- /dev/null +++ b/VM-Core/src/test/java/com/validation/manager/core/server/core/ReviewResultServerTest.java @@ -0,0 +1,51 @@ +/* + * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.validation.manager.core.server.core; + +import com.validation.manager.test.AbstractVMTestCase; +import org.junit.Test; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class ReviewResultServerTest extends AbstractVMTestCase { + + /** + * Test of getReview method, of class ReviewResultServer. + */ + @Test + public void testGetReview() { + System.out.println("getReview"); + assertNotNull(ReviewResultServer.getReview("result.pass")); + assertNull(ReviewResultServer.getReview("result.dummy")); + } + + /** + * Test of write2DB method, of class ReviewResultServer. + * + * @throws java.lang.Exception + */ + @Test + public void testWrite2DB() throws Exception { + System.out.println("write2DB"); + ReviewResultServer instance = new ReviewResultServer(1); + instance.setReviewName("test"); + instance.write2DB(); + assertEquals(instance.getReviewName(), + instance.getEntity().getReviewName()); + } +} diff --git a/VM-Core/src/test/java/com/validation/manager/core/server/core/RoleServerTest.java b/VM-Core/src/test/java/com/validation/manager/core/server/core/RoleServerTest.java new file mode 100644 index 00000000..d7612dd3 --- /dev/null +++ b/VM-Core/src/test/java/com/validation/manager/core/server/core/RoleServerTest.java @@ -0,0 +1,50 @@ +/* + * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.validation.manager.core.server.core; + +import com.validation.manager.test.AbstractVMTestCase; +import org.junit.Test; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class RoleServerTest extends AbstractVMTestCase { + + /** + * Test of getRole method, of class RoleServer. + */ + @Test + public void testGetRole() { + System.out.println("getRole"); + assertNotNull(RoleServer.getRole("admin")); + assertNull(RoleServer.getRole("dummy")); + } + + /** + * Test of write2DB method, of class RoleServer. + * + * @throws java.lang.Exception + */ + @Test + public void testWrite2DB() throws Exception { + System.out.println("write2DB"); + RoleServer instance = new RoleServer(1); + instance.setRoleName("test"); + instance.write2DB(); + assertEquals(instance.getRoleName(), instance.getEntity().getRoleName()); + } +} diff --git a/VM-Core/src/test/java/com/validation/manager/core/server/core/UserTestProjectRoleServerTest.java b/VM-Core/src/test/java/com/validation/manager/core/server/core/UserTestProjectRoleServerTest.java new file mode 100644 index 00000000..c0be1f2e --- /dev/null +++ b/VM-Core/src/test/java/com/validation/manager/core/server/core/UserTestProjectRoleServerTest.java @@ -0,0 +1,69 @@ +/* + * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.validation.manager.core.server.core; + +import com.validation.manager.core.DataBaseManager; +import com.validation.manager.core.db.TestProject; +import com.validation.manager.core.db.controller.UserTestProjectRoleJpaController; +import com.validation.manager.test.AbstractVMTestCase; +import com.validation.manager.test.TestHelper; +import org.junit.Test; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class UserTestProjectRoleServerTest extends AbstractVMTestCase { + + /** + * Test of write2DB method, of class UserTestProjectRoleServer. + * + * @throws java.lang.Exception + */ + @Test + public void testWrite2DB() throws Exception { + System.out.println("write2DB"); + createTestUsers(); + TestProject tp = TestHelper.createTestProject("Test"); + UserTestProjectRoleServer instance + = new UserTestProjectRoleServer(tp.getId(), leader.getId(), 1); + instance.write2DB(); + assertEquals(instance.getEntity().getVmUser().getId(), leader.getId()); + assertEquals(instance.getEntity().getTestProject().getId(), tp.getId()); + } + + /** + * Test of deleteUserTestProjectRole method, of class + * UserTestProjectRoleServer. + * + * @throws java.lang.Exception + */ + @Test + public void testDelete() throws Exception { + System.out.println("write2DB"); + createTestUsers(); + TestProject tp = TestHelper.createTestProject("Test"); + UserTestProjectRoleServer instance + = new UserTestProjectRoleServer(tp.getId(), leader.getId(), 1); + instance.write2DB(); + assertEquals(instance.getEntity().getVmUser().getId(), leader.getId()); + assertEquals(instance.getEntity().getTestProject().getId(), tp.getId()); + UserTestProjectRoleServer.deleteUserTestProjectRole(instance.getEntity()); + assertNull(new UserTestProjectRoleJpaController(DataBaseManager + .getEntityManagerFactory()) + .findUserTestProjectRole(instance.getUserTestProjectRolePK())); + } +} diff --git a/VM-Core/src/test/java/com/validation/manager/core/server/core/VMUserServerTest.java b/VM-Core/src/test/java/com/validation/manager/core/server/core/VMUserServerTest.java new file mode 100644 index 00000000..7ea84d9b --- /dev/null +++ b/VM-Core/src/test/java/com/validation/manager/core/server/core/VMUserServerTest.java @@ -0,0 +1,264 @@ +/* + * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.validation.manager.core.server.core; + +import com.validation.manager.core.VMException; +import com.validation.manager.core.tool.MD5; +import com.validation.manager.test.AbstractVMTestCase; +import java.util.Date; +import org.junit.Test; +import org.openide.util.Exceptions; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class VMUserServerTest extends AbstractVMTestCase { + + /** + * Test of write2DB method, of class VMUserServer. + * + * @throws java.lang.Exception + */ + @Test + public void testWrite2DB() throws Exception { + System.out.println("write2DB"); + String user = "test"; + String pw = "test"; + String name = "Test"; + String lastname = "User"; + String email = "test.user@test.com"; + VMUserServer instance = new VMUserServer(user, pw, name, lastname, email); + instance.write2DB(); + assertTrue(instance.getId() > 0); + assertEquals(instance.getId(), instance.getEntity().getId()); + assertEquals(user, instance.getEntity().getUsername()); + assertEquals(MD5.encrypt(pw), instance.getEntity().getPassword()); + assertEquals(name, instance.getEntity().getFirstName()); + assertEquals(lastname, instance.getEntity().getLastName()); + assertEquals(email, instance.getEntity().getEmail()); + assertEquals(1, instance.getHistoryList().size()); + assertEquals(1, instance.getEntity().getHistoryList().size()); + email = "test2@test.com"; + instance.setEmail(email); + instance.write2DB(); + int modifiedAmount = instance.getHistoryModificationList().size(); + assertEquals(instance.getId(), instance.getEntity().getId()); + assertEquals(user, instance.getEntity().getUsername()); + assertEquals(MD5.encrypt(pw), instance.getEntity().getPassword()); + assertEquals(name, instance.getEntity().getFirstName()); + assertEquals(lastname, instance.getEntity().getLastName()); + assertEquals(email, instance.getEntity().getEmail()); + assertEquals(2, instance.getHistoryList().size()); + assertEquals(2, instance.getEntity().getHistoryList().size()); + VMUserServer instance2 = new VMUserServer(user + 2, pw + 2, name + 2, + lastname + 2, email + 2); + instance2.write2DB(); + assertEquals(instance2.getId(), instance2.getEntity().getId()); + assertEquals(user + 2, instance2.getEntity().getUsername()); + assertEquals(MD5.encrypt(pw + 2), instance2.getEntity().getPassword()); + assertEquals(name + 2, instance2.getEntity().getFirstName()); + assertEquals(lastname + 2, instance2.getEntity().getLastName()); + assertEquals(email + 2, instance2.getEntity().getEmail()); + assertEquals(1, instance2.getHistoryList().size()); + assertEquals(1, instance2.getEntity().getHistoryList().size()); + instance2.setEmail(email + 3); + instance2.setModifierId(instance.getId()); + instance2.write2DB(); + assertEquals(instance2.getId(), instance2.getEntity().getId()); + assertEquals(user + 2, instance2.getEntity().getUsername()); + assertEquals(MD5.encrypt(pw + 2), instance2.getEntity().getPassword()); + assertEquals(name + 2, instance2.getEntity().getFirstName()); + assertEquals(lastname + 2, instance2.getEntity().getLastName()); + assertEquals(email + 3, instance2.getEntity().getEmail()); + assertEquals(2, instance2.getHistoryList().size()); + assertEquals(2, instance2.getEntity().getHistoryList().size()); + instance.update(); + assertEquals(modifiedAmount + 1, + instance.getHistoryModificationList().size()); + } + + /** + * Test of getVMUsers method, of class VMUserServer. + */ + @Test + public void testGetVMUsers() { + System.out.println("getVMUsers"); + assertTrue(!VMUserServer.getVMUsers().isEmpty()); + } + + /** + * Test of isPasswordUsable method, of class VMUserServer. + * + * @throws java.lang.Exception + */ + @Test + public void testIsPasswordUsable_String_boolean() throws Exception { + System.out.println("isPasswordUsable"); + String newPass = "test2"; + String user = "test"; + String pw = "test"; + String name = "Test"; + String lastname = "User"; + String email = "test.user@test.com"; + VMUserServer instance = new VMUserServer(user, pw, name, + lastname, email); + instance.write2DB(); + assertEquals(false, instance.isPasswordUsable(pw)); + assertEquals(true, instance.isPasswordUsable(newPass)); + } + + /** + * Test of validCredentials method, of class VMUserServer. + * + */ + @Test + public void testValidCredentials() { + System.out.println("validCredentials"); + String user = "test"; + String pw = "test"; + String name = "Test"; + String lastname = "User"; + String email = "test.user@test.com"; + VMUserServer instance; + try { + instance = new VMUserServer(user, pw, name, + lastname, email); + instance.write2DB(); + assertEquals(1, (int) instance.getEntity().getUserStatusId().getId()); + assertEquals(true, VMUserServer.validCredentials(user, pw, true)); + assertEquals(false, VMUserServer.validCredentials(user, pw + 1, true)); + assertEquals(false, VMUserServer.validCredentials(user + 1, pw + 1, + true)); + assertEquals(false, VMUserServer.validCredentials(user + 1, pw, true)); + assertEquals(true, VMUserServer.validCredentials(user, MD5.encrypt(pw), + false)); + assertEquals(false, VMUserServer.validCredentials(user, + MD5.encrypt(pw) + 1, false)); + try { + assertNotNull(new VMUserServer(user, pw)); + } + catch (VMException ex) { + Exceptions.printStackTrace(ex); + fail(); + } + int attempts = 0; + try { + assertEquals(attempts, instance.getAttempts()); + new VMUserServer(user, pw + 1); + instance.update(); + assertEquals(++attempts, instance.getEntity().getAttempts()); + } + catch (VMException ex) { + Exceptions.printStackTrace(ex); + fail(); + } + try { + new VMUserServer(user + 1, pw + 1); + //Wrong user name so can't be linked with account + instance.update(); + assertEquals(attempts, instance.getEntity().getAttempts()); + } + catch (VMException ex) { + Exceptions.printStackTrace(ex); + fail(); + } + try { + new VMUserServer(user + 1, pw); + //Wrong user name so can't be linked with account + instance.update(); + assertEquals(attempts, instance.getEntity().getAttempts()); + } + catch (VMException ex) { + Exceptions.printStackTrace(ex); + fail(); + } + //Lock the account + try { + for (int i = attempts; i < VMSettingServer + .getSetting("password.attempts").getIntVal(); i++) { + System.out.println("Attempts: " + attempts); + new VMUserServer(user, pw + 1); + instance.update(); + assertEquals(++attempts, instance.getEntity().getAttempts()); + assertEquals(1, (int) instance.getEntity().getUserStatusId().getId()); + } + new VMUserServer(user, pw + 1); + instance.update(); + assertEquals(++attempts, instance.getEntity().getAttempts()); + assertEquals(4, (int) instance.getEntity().getUserStatusId().getId()); + } + catch (VMException ex) { + Exceptions.printStackTrace(ex); + fail(); + } + } + catch (Exception ex) { + Exceptions.printStackTrace(ex); + fail(); + } + } + + /** + * Test of getPendingNotifications method, of class VMUserServer. + * + * @throws java.lang.Exception + */ + @Test + public void testGetPendingNotifications() throws Exception { + System.out.println("getPendingNotifications"); + String user = "test"; + String pw = "test"; + String name = "Test"; + String lastname = "User"; + String email = "test.user@test.com"; + VMUserServer instance = new VMUserServer(user, pw, name, + lastname, email); + instance.write2DB(); + assertEquals(0, instance.getPendingNotifications().size()); + NotificationServer ns = new NotificationServer(); + ns.setAuthor(new VMUserServer(1).getEntity()); + ns.setContent("Hello there!"); + ns.setCreationDate(new Date()); + ns.setNotificationType(NotificationTypeServer + .getType("notification.test.pending")); + ns.setTargetUser(instance.getEntity()); + ns.write2DB(); + assertEquals(1, instance.getPendingNotifications().size()); + ns.setAcknowledgeDate(new Date()); + ns.write2DB(); + assertEquals(0, instance.getPendingNotifications().size()); + } + + /** + * Test of getUser method, of class VMUserServer. + * + * @throws java.lang.Exception + */ + @Test + public void testGetUser() throws Exception { + System.out.println("getUser"); + String username = "test"; + String password = "test"; + String name = "Test"; + String lastname = "User"; + String email = "test.user@test.com"; + VMUserServer instance = new VMUserServer(username, password, name, + lastname, email); + instance.write2DB(); + assertNotNull(VMUserServer.getUser(username, password, true)); + } +} diff --git a/VM-Core/src/test/java/com/validation/manager/core/server/core/VersionListenerIT.java b/VM-Core/src/test/java/com/validation/manager/core/server/core/VersionListenerIT.java deleted file mode 100644 index 2c8a6c9e..00000000 --- a/VM-Core/src/test/java/com/validation/manager/core/server/core/VersionListenerIT.java +++ /dev/null @@ -1,82 +0,0 @@ -/* - * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.validation.manager.core.server.core; - -import com.validation.manager.core.DataBaseManager; -import com.validation.manager.core.db.Requirement; -import com.validation.manager.core.db.controller.RequirementJpaController; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import com.validation.manager.test.AbstractVMTestCase; -import static junit.framework.TestCase.*; -import org.junit.Test; -import org.openide.util.Exceptions; - -/** - * - * @author Javier Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class VersionListenerIT extends AbstractVMTestCase { - - /** - * Test of onChange method, of class VersionListener. - */ - @Test - public void testOnChange() { - System.out.println("onChange"); - DataBaseManager.setVersioningEnabled(true); - int count = 0; - int max = 10; - Requirement entity = new Requirement("SRS0001", "Description " - + (++count)); - RequirementJpaController controller - = new RequirementJpaController(DataBaseManager - .getEntityManagerFactory()); - assertEquals(0, controller.findRequirementEntities().size()); - controller.create(entity); - assertEquals(count, controller.findRequirementEntities().size()); - for (int i = 0; i < max; i++) { - try { - System.out.println("Modification: " + (i + 1)); - entity.setDescription("Description " + (++count)); - controller.edit(entity); - } - catch (NonexistentEntityException ex) { - Exceptions.printStackTrace(ex); - fail(); - } - catch (Exception ex) { - Exceptions.printStackTrace(ex); - fail(); - } - } - assertEquals(max + 1, controller.getRequirementCount()); - Requirement prev = null; - int x = 0; -// for (Requirement r : controller.findRequirementEntities()) { -// assertNotNull(r.getModificationTime()); -// assertNotNull(r.getDescription()); -// assertEquals(x == 0, r.isDirty()); -// if (x > 0) { -// //First one is the oldest one (version 0.0.max+1) -// if (prev != null) { -// assertTrue(r.compareTo(prev) > 0); -// } -// prev = r; -// } -// x++; -// } - } -} diff --git a/VM-Core/src/test/java/com/validation/manager/core/tool/ToolTest.java b/VM-Core/src/test/java/com/validation/manager/core/tool/ToolTest.java new file mode 100644 index 00000000..0187141a --- /dev/null +++ b/VM-Core/src/test/java/com/validation/manager/core/tool/ToolTest.java @@ -0,0 +1,100 @@ +/* + * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.validation.manager.core.tool; + +import com.validation.manager.core.server.core.TestCaseExecutionServer; +import com.validation.manager.core.server.core.TestCaseServer; +import com.validation.manager.test.AbstractVMTestCase; +import java.util.ArrayList; +import java.util.Date; +import java.util.List; +import javax.swing.ImageIcon; +import static junit.framework.TestCase.*; +import org.junit.Test; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class ToolTest extends AbstractVMTestCase { + + /** + * Test of createImageIcon method, of class Tool. + */ + @Test + public void testCreateImageIcon_String_String() { + System.out.println("createImageIcon"); + String path = "/com/validation/manager/resources/icons/VMSmall.png"; + String description = "Test"; + ImageIcon result = Tool.createImageIcon(path, description); + assertNotNull(result); + } + + /** + * Test of createImageIcon method, of class Tool. + */ + @Test + public void testCreateImageIcon_3args() { + System.out.println("createImageIcon"); + String path = "/com/validation/manager/resources/icons/VMSmall.png"; + String description = "Test"; + ImageIcon result = Tool.createImageIcon(path, description, Tool.class); + assertNotNull(result); + } + + /** + * Test of removeDuplicates method, of class Tool. + */ + @Test + public void testRemoveDuplicates() { + System.out.println("removeDuplicates"); + List list = new ArrayList<>(); + list.add(1); + list.add(2); + list.add(2); + list.add(2); + list.add(2); + list.add(3); + Tool.removeDuplicates(list); + assertEquals(3, list.size()); + } + + /** + * Test of extractTCE method, of class Tool. + * + * @throws java.lang.Exception + */ + @Test + public void testExtractTCE() throws Exception { + System.out.println("extractTCE"); + TestCaseExecutionServer tce = new TestCaseExecutionServer("Test Name", + "Test Scope"); + TestCaseServer tc = new TestCaseServer("Test Case", new Date()); + tc.write2DB(); + tce.addTestCase(tc); + tce.write2DB(); + String key = "tce-" + tce.getId() + "-" + tc.getId(); + TCEExtraction r = Tool.extractTCE(key); + assertEquals(tce.getId(), r.getTestCaseExecution().getId()); + try { + Tool.extractTCE(key + 1); + fail(); + } + catch (Exception ex) { + //Expected + } + } +} diff --git a/VM-Core/src/test/java/com/validation/manager/core/tool/table/extractor/TableExtractorTest.java b/VM-Core/src/test/java/com/validation/manager/core/tool/table/extractor/TableExtractorTest.java index 62979467..baa4c9bc 100644 --- a/VM-Core/src/test/java/com/validation/manager/core/tool/table/extractor/TableExtractorTest.java +++ b/VM-Core/src/test/java/com/validation/manager/core/tool/table/extractor/TableExtractorTest.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,77 +13,92 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.core.tool.table.extractor; - -import java.io.File; -import static java.lang.System.getProperty; -import java.util.List; -import javax.swing.table.DefaultTableModel; -import org.junit.Test; -import static org.junit.Assert.*; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class TableExtractorTest { - - /** - * Test of extractTables method, of class TableExtractor. - * - * @throws java.lang.Exception - */ - @Test - public void testExtractTables() throws Exception { - System.out.println("extractTables"); - String name = TableExtractorTest.class.getCanonicalName(); - name = name.substring(0, name.lastIndexOf(".")); - name = name.replace(".", getProperty("file.separator")); - File file = new File(getProperty("user.dir") - + getProperty("file.separator") + "src" - + getProperty("file.separator") + "test" - + getProperty("file.separator") + "java" - + getProperty("file.separator") - + name - + getProperty("file.separator") + "Tables.docx"); - assert file.exists(); - TableExtractor te = new TableExtractor(file); - List tables = te.extractTables(); - assertEquals(2, tables.size()); - for (DefaultTableModel model : tables) { - //Has header - assertEquals(4, model.getRowCount()); - assertEquals(5, model.getColumnCount()); - } - file = new File(getProperty("user.dir") - + getProperty("file.separator") + "src" - + getProperty("file.separator") + "test" - + getProperty("file.separator") + "java" - + getProperty("file.separator") - + name - + getProperty("file.separator") + "Tables.xls"); - assert file.exists(); - te = new TableExtractor(file); - tables = te.extractTables(); - assertEquals(1, tables.size()); - for (DefaultTableModel model : tables) { - assertEquals(3, model.getRowCount()); - assertEquals(3, model.getColumnCount()); - } - file = new File(getProperty("user.dir") - + getProperty("file.separator") + "src" - + getProperty("file.separator") + "test" - + getProperty("file.separator") + "java" - + getProperty("file.separator") - + name - + getProperty("file.separator") + "Tables.xlsx"); - assert file.exists(); - te = new TableExtractor(file); - tables = te.extractTables(); - assertEquals(1, tables.size()); - for (DefaultTableModel model : tables) { - assertEquals(3, model.getRowCount()); - assertEquals(3, model.getColumnCount()); - } - } -} +package com.validation.manager.core.tool.table.extractor; + +import java.io.File; +import static java.lang.System.getProperty; +import java.util.List; +import javax.swing.table.DefaultTableModel; +import static org.junit.Assert.*; +import org.junit.Test; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class TableExtractorTest { + + /** + * Test of extractTables method, of class TableExtractor. + * + * @throws java.lang.Exception + */ + @Test + public void testExtractTables() throws Exception { + System.out.println("extractTables"); + String name = TableExtractorTest.class.getCanonicalName(); + name = name.substring(0, name.lastIndexOf(".")); + name = name.replace(".", getProperty("file.separator")); + File file = new File(getProperty("user.dir") + + getProperty("file.separator") + "src" + + getProperty("file.separator") + "test" + + getProperty("file.separator") + "java" + + getProperty("file.separator") + + name + + getProperty("file.separator") + "Tables.docx"); + assert file.exists(); + TableExtractor te = new TableExtractor(file); + List tables = te.extractTables(); + assertEquals(2, tables.size()); + for (DefaultTableModel model : tables) { + //Has header + assertEquals(4, model.getRowCount()); + assertEquals(5, model.getColumnCount()); + } + file = new File(getProperty("user.dir") + + getProperty("file.separator") + "src" + + getProperty("file.separator") + "test" + + getProperty("file.separator") + "java" + + getProperty("file.separator") + + name + + getProperty("file.separator") + "Tables.xls"); + assert file.exists(); + te = new TableExtractor(file); + tables = te.extractTables(); + assertEquals(1, tables.size()); + for (DefaultTableModel model : tables) { + assertEquals(3, model.getRowCount()); + assertEquals(3, model.getColumnCount()); + } + file = new File(getProperty("user.dir") + + getProperty("file.separator") + "src" + + getProperty("file.separator") + "test" + + getProperty("file.separator") + "java" + + getProperty("file.separator") + + name + + getProperty("file.separator") + "Tables.xlsx"); + assert file.exists(); + te = new TableExtractor(file); + tables = te.extractTables(); + assertEquals(1, tables.size()); + for (DefaultTableModel model : tables) { + assertEquals(3, model.getRowCount()); + assertEquals(3, model.getColumnCount()); + } + file = new File(getProperty("user.dir") + + getProperty("file.separator") + "src" + + getProperty("file.separator") + "test" + + getProperty("file.separator") + "java" + + getProperty("file.separator") + + name + + getProperty("file.separator") + "Tables.xlsm"); + assert file.exists(); + te = new TableExtractor(file); + tables = te.extractTables(); + assertEquals(1, tables.size()); + for (DefaultTableModel model : tables) { + assertEquals(3, model.getRowCount()); + assertEquals(3, model.getColumnCount()); + } + } +} diff --git a/VM-Core/src/test/java/com/validation/manager/core/tool/table/extractor/Tables.xlsm b/VM-Core/src/test/java/com/validation/manager/core/tool/table/extractor/Tables.xlsm new file mode 100644 index 0000000000000000000000000000000000000000..e72a00a6a5dd60beb19158b4c9cad79a229db678 GIT binary patch literal 8873 zcmeHMWmHvbx8AVnZjen%gLF!#bayGW>1I>X8|jp81PM`)kdT&8LO?=7y1P5&ZvDP< zJ%{5R_x`$nzO(iiYmGg|nscppz0Wh}Gv`!O1R@XskN_wE0Du}m?RTK<0|x*^A_4&T z02FvbDJMq=*b(wX%i9_3X3Xa0U{95g0MGaW01vzWpW{FH3-oEtsI+qswD2F0r_5%Q z1x9d&wuLMfCWK?FO>)-`)+npC9h~MQ=f0ANm&@m$Y8croF5VfZBYvcw#=MgttW_J~{+jHJ={TG<4m6dGU49+as;O zUEdrn1|i!N6{pHT&Pn!>60e%FmgUxdpoaAQxbj_WTCqB@8X0wYH61ov+oz!e!D`P- z$MhQ$&i(S^X2lL%Ze&H_vmx^b7gwwiJhFU%4h3M2ca7b!d2iwVi^tGnC4t7Exalz8 z!2@!it@x^rjt%39P^l;ta@-(n!tF)Vxs@p zQ2PsKYqU9NPGCS(f>9D3#@Q#XV0$-qwjbwzxcVPV&_69bI^l~-2M5NdJ-H^S<*Q9c zIh4G@MkTpMYAuQnw7ZlwF)wMw&rY8Kp$g_xL#JzB#0+P5S8cQ?$;{YQIvN-yD!I*k z#%;aIa&@p@nBBLsA?PBFB{S8XnYDl7RgjcvHh%T0Dk_S!A?cdNjE7v60R3RwweUHI zdatSVP~yE;;OV3lkAALQ4fm%EJ$_>u|^y-U)oqQ>$3{GN+QVrrg zYTN(68pamtkA@L*l5n$>aZ09&%D!vP)a5xDmNjE` zfc`rKIkz@^Gl!wV2^MFuVbFjf=+D@R*7)q$&VkdUyD6sEl8S(AEkP@%ZJ4a6T|zM6 z*hEbfOa4s-7%&&34v&|bbGmS_y*=@Hv{GZ4xHR!mF+@0$2`(E%eIi;omsuCappdm@ z;0)#|I7WzlTXoe4w%cClN&`y3?`Rl2eZrpKy+Wro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HXz zyZerC&I#GD_qU`V4Ih+T%5csh=OYt8KB(010!cYfoNuU=*(SbNRuo+C3TjvbGt7k; zjnmt|5cc{`+;Dcl;|nj+oVI+FRqoHDd3Zj3^7|Ij5m9xyDGb1Vu(*l)X8@Z!xq|;e zFbul?K713DVFLt$XJ>NL)Q6%j(@Dby^2}(P@Im7DQ91{zo=k;zR@$G%*|{LFg(g;0 z6NVSwSc-lTewee{+ddV@=S_z%4aM=M@}_gGR~mHVJL~G^PLXemRFH(8nhf%Yh(*=s zHx2K31WBwjY6`05 zy|+Ovo8jw$1Wi(}YuHEw=Sk2QB@BY)#rNaJpltoQp_ap%DfKff;~O}2Ux=E>JvOs@ zgcdv+F>BTFJ60IZPrmP#lx(h5%@QIfeS&Jf4f>`~TxXvceEJrCugzhzBeM+sO{*w4 z+9&^M9wPVY?2iBQ;Iy5%mYfpToH@ZW9nCU7oM&t8!?lwxhj_+w7H&ycl6V)i$EZEs zX^-#)X`S4o@dLCci4Nl{kLAcYx>tr v|H}{nU?T+p?&kfw)_)DNf41Hu`;+w_L03%?5r#AX0OQ9G2G%gjAOHRf{D}fG literal 0 HcmV?d00001 diff --git a/VM-Core/src/test/java/com/validation/manager/test/AbstractVMTestCase.java b/VM-Core/src/test/java/com/validation/manager/test/AbstractVMTestCase.java index b677a25d..ae7f3bb4 100755 --- a/VM-Core/src/test/java/com/validation/manager/test/AbstractVMTestCase.java +++ b/VM-Core/src/test/java/com/validation/manager/test/AbstractVMTestCase.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,203 +13,195 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.test; - -import com.validation.manager.core.DBState; -import com.validation.manager.core.DataBaseManager; -import com.validation.manager.core.history.Auditable; -import com.validation.manager.core.db.History; -import com.validation.manager.core.db.HistoryField; -import com.validation.manager.core.db.VmUser; -import com.validation.manager.core.db.controller.VmUserJpaController; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import com.validation.manager.core.history.Versionable; -import com.validation.manager.core.server.core.VMUserServer; -import static com.validation.manager.core.tool.MD5.encrypt; -import static com.validation.manager.test.TestHelper.deleteUser; -import static java.lang.Class.forName; -import java.lang.reflect.Field; -import java.sql.Connection; -import java.sql.SQLException; -import java.sql.Statement; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; -import java.util.logging.Level; -import java.util.logging.Logger; -import javax.sql.DataSource; -import junit.framework.TestCase; -import org.apache.commons.lang3.reflect.FieldUtils; -import org.h2.jdbcx.JdbcDataSource; -import org.junit.After; -import org.junit.Before; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public abstract class AbstractVMTestCase extends TestCase { - - protected VmUser designer, tester, leader; - /** - * Parameters for queries. - */ - protected HashMap parameters = new HashMap<>(); - /** - * Query results. - */ - protected List result; - public static boolean deleteDatabase = true; - private static final Logger LOG - = Logger.getLogger(AbstractVMTestCase.class.getSimpleName()); - - @Before - @Override - protected void setUp() throws Exception { - LOG.info("Setting up database!"); - DataBaseManager.setPersistenceUnitName("TestVMPU"); - assertEquals(DBState.VALID, DataBaseManager.getState()); - postSetUp(); - LOG.info("Done!"); - } - - @After - @Override - protected void tearDown() throws Exception { - LOG.info("Deleting database!"); - deleteTestUsers(); - Connection conn = null; - Statement stmt = null; - try { - Map properties - = DataBaseManager.getEntityManagerFactory() - .getProperties(); - DataSource ds = new JdbcDataSource(); - ((JdbcDataSource) ds).setPassword((String) properties - .get("javax.persistence.jdbc.password")); - ((JdbcDataSource) ds).setUser((String) properties - .get("javax.persistence.jdbc.user")); - ((JdbcDataSource) ds).setURL((String) properties - .get("javax.persistence.jdbc.url")); - //Load the H2 driver - forName("org.h2.Driver"); - conn = ds.getConnection(); - stmt = conn.createStatement(); - stmt.executeUpdate("DROP ALL OBJECTS DELETE FILES"); - } - catch (SQLException | ClassNotFoundException ex) { - LOG.log(Level.SEVERE, - null, ex); - } - finally { - try { - if (stmt != null) { - stmt.close(); - } - } - catch (SQLException ex) { - fail(); - } - try { - if (conn != null) { - conn.close(); - } - } - catch (SQLException ex) { - fail(); - } - } - DataBaseManager.close(); - postTearDown(); - LOG.info("Done!"); - } - - protected void createTestUsers() { - try { - VMUserServer temp = new VMUserServer("test1", - "password", "test@test.com", "first", "last"); - temp.write2DB(); - designer = new VmUserJpaController(DataBaseManager - .getEntityManagerFactory()) - .findVmUser(temp.getId()); - temp = new VMUserServer("test2", - "password", "test@test.com", "first", "last"); - temp.write2DB(); - tester = new VmUserJpaController(DataBaseManager - .getEntityManagerFactory()) - .findVmUser(temp.getId()); - temp = new VMUserServer("test3", - encrypt("password"), "test@test.com", "first", "last"); - temp.write2DB(); - leader = new VmUserJpaController(DataBaseManager - .getEntityManagerFactory()) - .findVmUser(temp.getId()); - LOG.log(Level.INFO, "Done!"); - } - catch (Exception ex) { - LOG.log(Level.SEVERE, null, ex); - } - } - - /** - * Code to be performed after set up. - */ - protected void postSetUp() { - - } - - /** - * Code to be performed after set teardown. - */ - protected void postTearDown() { - - } - - protected void deleteTestUsers() { - try { - deleteUser(designer); - deleteUser(tester); - deleteUser(leader); - designer = null; - tester = null; - leader = null; - } - catch (IllegalOrphanException | NonexistentEntityException ex) { - LOG.log(Level.SEVERE, null, ex); - } - } - - public List getAuditableFields(Versionable v) { - List r = new ArrayList<>(); - FieldUtils.getFieldsListWithAnnotation(v.getClass(), Auditable.class) - .stream().filter((field) - -> (field.isAnnotationPresent(Auditable.class))) - .forEachOrdered((field) -> { - r.add(field); - }); - return r; - } - - public boolean checkHistory(Versionable v) { - History current = v.getHistoryList().get(v.getHistoryList().size() - 1); - List af = getAuditableFields(v); - assertEquals(af.size(), current.getHistoryFieldList().size()); - assertTrue(af.size() > 0); - for (HistoryField hf : current.getHistoryFieldList()) { - try { - //Compare audit field vs. the record in history. - Object o = FieldUtils.readField(FieldUtils.getField(v.getClass(), - hf.getFieldName(), true), v); - if (!o.toString().equals(hf.getFieldValue())) { - return false; - } - } - catch (SecurityException | IllegalArgumentException | IllegalAccessException ex) { - LOG.log(Level.SEVERE, null, ex); - } - } - return true; - } -} +package com.validation.manager.test; + +import com.validation.manager.core.DBState; +import com.validation.manager.core.DataBaseManager; +import com.validation.manager.core.db.History; +import com.validation.manager.core.db.HistoryField; +import com.validation.manager.core.db.VmUser; +import com.validation.manager.core.db.controller.VmUserJpaController; +import com.validation.manager.core.history.Auditable; +import com.validation.manager.core.history.Versionable; +import com.validation.manager.core.server.core.VMUserServer; +import static com.validation.manager.core.tool.MD5.encrypt; +import static java.lang.Class.forName; +import java.lang.reflect.Field; +import java.sql.Connection; +import java.sql.SQLException; +import java.sql.Statement; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.logging.Level; +import java.util.logging.Logger; +import javax.sql.DataSource; +import junit.framework.TestCase; +import org.apache.commons.lang3.reflect.FieldUtils; +import org.h2.jdbcx.JdbcDataSource; +import org.junit.After; +import org.junit.Before; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public abstract class AbstractVMTestCase extends TestCase { + + protected VmUser designer, tester, leader; + /** + * Parameters for queries. + */ + protected HashMap parameters = new HashMap<>(); + /** + * Query results. + */ + protected List result; + public static boolean deleteDatabase = true; + private static final Logger LOG + = Logger.getLogger(AbstractVMTestCase.class.getSimpleName()); + + @Before + @Override + protected void setUp() throws Exception { + LOG.info("Setting up database!"); + DataBaseManager.setPersistenceUnitName("TestVMPU"); + assertEquals(DBState.VALID, DataBaseManager.getState()); + postSetUp(); + LOG.info("Done!"); + } + + @After + @Override + protected void tearDown() throws Exception { + LOG.info("Deleting database!"); + deleteTestUsers(); + Connection conn = null; + Statement stmt = null; + try { + Map properties + = DataBaseManager.getEntityManagerFactory() + .getProperties(); + DataSource ds = new JdbcDataSource(); + ((JdbcDataSource) ds).setPassword((String) properties + .get("javax.persistence.jdbc.password")); + ((JdbcDataSource) ds).setUser((String) properties + .get("javax.persistence.jdbc.user")); + ((JdbcDataSource) ds).setURL((String) properties + .get("javax.persistence.jdbc.url")); + //Load the H2 driver + forName("org.h2.Driver"); + conn = ds.getConnection(); + stmt = conn.createStatement(); + stmt.executeUpdate("DROP ALL OBJECTS DELETE FILES"); + } + catch (SQLException | ClassNotFoundException ex) { + LOG.log(Level.SEVERE, + null, ex); + } + finally { + try { + if (stmt != null) { + stmt.close(); + } + } + catch (SQLException ex) { + fail(); + } + try { + if (conn != null) { + conn.close(); + } + } + catch (SQLException ex) { + fail(); + } + } + DataBaseManager.close(); + postTearDown(); + LOG.info("Done!"); + } + + protected void createTestUsers() { + try { + VMUserServer temp = new VMUserServer("test1", + "password", "test@test.com", "first", "last"); + temp.write2DB(); + designer = new VmUserJpaController(DataBaseManager + .getEntityManagerFactory()) + .findVmUser(temp.getId()); + temp = new VMUserServer("test2", + "password", "test@test.com", "first", "last"); + temp.write2DB(); + tester = new VmUserJpaController(DataBaseManager + .getEntityManagerFactory()) + .findVmUser(temp.getId()); + temp = new VMUserServer("test3", + encrypt("password"), "test@test.com", "first", "last"); + temp.write2DB(); + leader = new VmUserJpaController(DataBaseManager + .getEntityManagerFactory()) + .findVmUser(temp.getId()); + LOG.log(Level.INFO, "Done!"); + } + catch (Exception ex) { + LOG.log(Level.SEVERE, null, ex); + } + } + + /** + * Code to be performed after set up. + */ + protected void postSetUp() { + + } + + /** + * Code to be performed after set teardown. + */ + protected void postTearDown() { + + } + + protected void deleteTestUsers() { + designer = null; + tester = null; + leader = null; + } + + public List getAuditableFields(Versionable v) { + List r = new ArrayList<>(); + FieldUtils.getFieldsListWithAnnotation(v.getClass(), Auditable.class) + .stream().filter((field) + -> (field.isAnnotationPresent(Auditable.class))) + .forEachOrdered((field) -> { + r.add(field); + }); + return r; + } + + public boolean checkHistory(Versionable v) { + History current = v.getHistoryList().get(v.getHistoryList().size() - 1); + List af = getAuditableFields(v); + assertEquals(af.size(), current.getHistoryFieldList().size()); + assertTrue(af.size() > 0); + for (HistoryField hf : current.getHistoryFieldList()) { + try { + //Compare audit field vs. the record in history. + Object o = FieldUtils.readField(FieldUtils.getField(v.getClass(), + hf.getFieldName(), true), v); + if (!Versionable.fieldMatchHistory(hf, o)) { + return false; + } + } + catch (SecurityException | IllegalArgumentException | IllegalAccessException ex) { + LOG.log(Level.SEVERE, null, ex); + } + } + v.getHistoryList().forEach(h -> { + LOG.info(h.toString()); + }); + return true; + } +} diff --git a/VM-Core/src/test/java/com/validation/manager/test/TestHelper.java b/VM-Core/src/test/java/com/validation/manager/test/TestHelper.java index 695c2a5e..67712e52 100755 --- a/VM-Core/src/test/java/com/validation/manager/test/TestHelper.java +++ b/VM-Core/src/test/java/com/validation/manager/test/TestHelper.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,223 +13,200 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package com.validation.manager.test; - -import static com.validation.manager.core.DataBaseManager.getEntityManagerFactory; -import com.validation.manager.core.VMException; -import com.validation.manager.core.db.Project; -import com.validation.manager.core.db.Requirement; -import com.validation.manager.core.db.RequirementSpec; -import com.validation.manager.core.db.RequirementSpecNode; -import com.validation.manager.core.db.RequirementSpecNodePK; -import com.validation.manager.core.db.Step; -import com.validation.manager.core.db.TestCase; -import com.validation.manager.core.db.TestPlan; -import com.validation.manager.core.db.TestProject; -import com.validation.manager.core.db.VmUser; -import com.validation.manager.core.db.controller.ProjectJpaController; -import com.validation.manager.core.db.controller.RequirementJpaController; -import com.validation.manager.core.db.controller.UserStatusJpaController; -import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import com.validation.manager.core.db.controller.exceptions.PreexistingEntityException; -import com.validation.manager.core.server.core.ProjectServer; -import com.validation.manager.core.server.core.RequirementServer; -import com.validation.manager.core.server.core.RequirementSpecNodeServer; -import com.validation.manager.core.server.core.RequirementSpecServer; -import com.validation.manager.core.server.core.StepServer; -import com.validation.manager.core.server.core.TestCaseServer; -import com.validation.manager.core.server.core.TestPlanServer; -import com.validation.manager.core.server.core.TestProjectServer; -import com.validation.manager.core.server.core.VMUserServer; -import java.util.ArrayList; -import java.util.Date; -import java.util.logging.Level; -import java.util.logging.Logger; -import static org.junit.Assert.assertEquals; -import static org.junit.Assert.assertTrue; -import static org.junit.Assert.fail; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class TestHelper { - - private static final Logger LOG - = Logger.getLogger(TestHelper.class.getName()); - - public static VmUser createUser(String name, String pass, String email, - String first, String last) throws Exception { - VMUserServer temp = new VMUserServer(name, - pass, first, last, email); - temp.setUserStatusId(new UserStatusJpaController( - getEntityManagerFactory()).findUserStatus(1)); - temp.write2DB(); - return temp.getEntity(); - } - - public static void deleteUser(VmUser user) throws NonexistentEntityException, - IllegalOrphanException { - if (user != null) { - VMUserServer.deleteUser(user); - } - } - - public static Project createProject(String name, String notes) { - ProjectServer ps = new ProjectServer(name, notes); - try { - ps.write2DB(); - } - catch (IllegalOrphanException ex) { - LOG.log(Level.SEVERE, null, ex); - fail(); - } - catch (NonexistentEntityException ex) { - LOG.log(Level.SEVERE, null, ex); - fail(); - } - catch (Exception ex) { - LOG.log(Level.SEVERE, null, ex); - fail(); - } - assertTrue(ps.getEntity() != null); - return ps.getEntity(); - } - - public static void destroyProject(Project p) throws IllegalOrphanException, - NonexistentEntityException, VMException { - ProjectServer.deleteProject(p); - assertTrue(new ProjectJpaController( - getEntityManagerFactory()).findProject(p.getId()) == null); - } - - public static TestCase createTestCase(String name, String summary) - throws PreexistingEntityException, Exception { - TestCaseServer tc = new TestCaseServer(name, new Date()); - tc.setRiskControlHasTestCaseList(new ArrayList<>()); - tc.setActive(true); - tc.setIsOpen(true); - tc.setSummary(summary.getBytes()); - tc.write2DB(); - return tc.getEntity(); - } - - public static Requirement createRequirement(String id, String desc, - RequirementSpecNodePK p, String notes, int requirementType, - int requirementStatus) throws Exception { - RequirementServer req = new RequirementServer(id, desc, p, notes, - requirementType, requirementStatus); - req.write2DB(); - assert req.getEntity().getRequirementSpecNode() != null; - return req.getEntity(); - } - - public static void destroyRequirement(Requirement r) - throws NonexistentEntityException { - try { - RequirementServer.deleteRequirement(r); - assertTrue(new RequirementJpaController( - getEntityManagerFactory()) - .findRequirement(r.getId()) == null); - } - catch (IllegalOrphanException ex) { - LOG.log(Level.SEVERE, null, ex); - fail(); - } - } - - public static TestCase addStep(TestCase tc, int sequence, - String text, String note, String result) throws PreexistingEntityException, - Exception { - TestCaseServer tcs = new TestCaseServer(tc.getId()); - int amount = tcs.getStepList().size(); - tcs.addStep(sequence, text, note, note, null); - assertEquals(amount + 1, tcs.getStepList().size()); - return tcs.getEntity(); - } - - public static TestProject createTestProject(String name) - throws IllegalOrphanException, NonexistentEntityException, - Exception { - TestProjectServer tps = new TestProjectServer("Test Project", true); - tps.write2DB(); - return tps.getEntity(); - } - - public static TestPlan createTestPlan(TestProject tp, String notes, - boolean active, boolean open) throws PreexistingEntityException, - Exception { - TestPlanServer plan = new TestPlanServer(tp, active, open); - plan.setNotes(notes); - plan.setTestProject(tp); - plan.write2DB(); - tp.getTestPlanList().add(plan.getEntity()); - return plan.getEntity(); - } - - public static void addTestCaseToPlan(TestPlan plan, TestCase testCase) - throws PreexistingEntityException, Exception { - int testInPlan = plan.getTestCaseList().size(); - TestPlanServer tps = new TestPlanServer(plan); - tps.getTestCaseList().add(testCase); - tps.write2DB(); - tps.update(plan, tps); - testCase.getTestPlanList().add(plan); - assertTrue(plan.getTestCaseList().size() > testInPlan); - } - - public static RequirementSpec createRequirementSpec(String name, - String description, Project project, int specLevelId) - throws Exception { - RequirementSpecServer rss = new RequirementSpecServer(name, description, - project.getId(), specLevelId); - rss.write2DB(); - project.getRequirementSpecList().add(rss.getEntity()); - new ProjectServer(project).write2DB(); - return rss.getEntity(); - } - - public static RequirementSpecNode createRequirementSpecNode( - RequirementSpec rss, String name, String description, String scope) - throws Exception { - RequirementSpecNodeServer rsns = new RequirementSpecNodeServer(rss, - name, description, scope); - rsns.write2DB(); - return rsns.getEntity(); - } - - public static void addTestProjectToProject(TestProject tp, Project project) - throws IllegalOrphanException, NonexistentEntityException, - Exception { - ProjectServer ps = new ProjectServer(project); - int current = ps.getTestProjectList().size(); - ps.getTestProjectList().add(tp); - ps.write2DB(); - assertTrue(ps.getEntity().getTestProjectList().size() > current); - tp.getProjectList().add(project); - } - - public static void addRequirementToStep(Step step, Requirement req) - throws Exception { - StepServer ss = new StepServer(step); - ss.addRequirement(req); - ss.write2DB(); - } - - public static Project addProject(Project root, String name, String notes) - throws NonexistentEntityException, Exception { - Project sub = createProject(name, notes); - ProjectServer ps = new ProjectServer(root); - ps.getProjectList().add(sub); - ps.write2DB(); - return new ProjectServer(sub).getEntity(); - } - - public static Requirement addChildToRequirement(Requirement parent, - Requirement child) throws Exception { - RequirementServer rs = new RequirementServer(parent); - rs.addChildRequirement(child); - return rs.getEntity(); - } -} +package com.validation.manager.test; + +import static com.validation.manager.core.DataBaseManager.getEntityManagerFactory; +import com.validation.manager.core.VMException; +import com.validation.manager.core.db.Project; +import com.validation.manager.core.db.Requirement; +import com.validation.manager.core.db.RequirementSpec; +import com.validation.manager.core.db.RequirementSpecNode; +import com.validation.manager.core.db.RequirementSpecNodePK; +import com.validation.manager.core.db.Step; +import com.validation.manager.core.db.TestCase; +import com.validation.manager.core.db.TestPlan; +import com.validation.manager.core.db.TestProject; +import com.validation.manager.core.db.VmUser; +import com.validation.manager.core.db.controller.RequirementJpaController; +import com.validation.manager.core.db.controller.UserStatusJpaController; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import com.validation.manager.core.db.controller.exceptions.PreexistingEntityException; +import com.validation.manager.core.server.core.ProjectServer; +import com.validation.manager.core.server.core.RequirementServer; +import com.validation.manager.core.server.core.RequirementSpecNodeServer; +import com.validation.manager.core.server.core.RequirementSpecServer; +import com.validation.manager.core.server.core.StepServer; +import com.validation.manager.core.server.core.TestCaseServer; +import com.validation.manager.core.server.core.TestPlanServer; +import com.validation.manager.core.server.core.TestProjectServer; +import com.validation.manager.core.server.core.VMUserServer; +import java.util.ArrayList; +import java.util.Date; +import java.util.logging.Level; +import java.util.logging.Logger; +import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertTrue; +import static org.junit.Assert.fail; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class TestHelper { + + private static final Logger LOG + = Logger.getLogger(TestHelper.class.getName()); + + public static VmUser createUser(String name, String pass, String email, + String first, String last) throws Exception { + VMUserServer temp = new VMUserServer(name, + pass, first, last, email); + temp.setUserStatusId(new UserStatusJpaController( + getEntityManagerFactory()).findUserStatus(1)); + temp.write2DB(); + return temp.getEntity(); + } + + public static Project createProject(String name, String notes) { + ProjectServer ps = new ProjectServer(name, notes); + try { + ps.write2DB(); + } + catch (VMException ex) { + LOG.log(Level.SEVERE, null, ex); + fail(); + } + assertTrue(ps.getEntity() != null); + return ps.getEntity(); + } + + public static TestCase createTestCase(String name, String summary) + throws PreexistingEntityException, Exception { + TestCaseServer tc = new TestCaseServer(name, new Date()); + tc.setRiskControlHasTestCaseList(new ArrayList<>()); + tc.setActive(true); + tc.setIsOpen(true); + tc.setSummary(summary.getBytes()); + tc.write2DB(); + return tc.getEntity(); + } + + public static Requirement createRequirement(String id, String desc, + RequirementSpecNodePK p, String notes, int requirementType, + int requirementStatus) throws Exception { + RequirementServer req = new RequirementServer(id, desc, p, notes, + requirementType, requirementStatus); + req.write2DB(); + assert req.getEntity().getRequirementSpecNode() != null; + return req.getEntity(); + } + + public static void destroyRequirement(Requirement r) + throws NonexistentEntityException { + try { + RequirementServer.deleteRequirement(r); + assertTrue(new RequirementJpaController( + getEntityManagerFactory()) + .findRequirement(r.getId()) == null); + } + catch (IllegalOrphanException ex) { + LOG.log(Level.SEVERE, null, ex); + fail(); + } + } + + public static TestCase addStep(TestCase tc, int sequence, + String text, String note, String result) throws PreexistingEntityException, + Exception { + TestCaseServer tcs = new TestCaseServer(tc.getId()); + int amount = tcs.getStepList().size(); + tcs.addStep(sequence, text, note, note, null); + assertEquals(amount + 1, tcs.getStepList().size()); + return tcs.getEntity(); + } + + public static TestProject createTestProject(String name) + throws IllegalOrphanException, NonexistentEntityException, + Exception { + TestProjectServer tps = new TestProjectServer("Test Project", true); + tps.write2DB(); + return tps.getEntity(); + } + + public static TestPlan createTestPlan(TestProject tp, String notes, + boolean active, boolean open) throws PreexistingEntityException, + Exception { + TestPlanServer plan = new TestPlanServer(tp, active, open); + plan.setNotes(notes); + plan.setTestProject(tp); + plan.write2DB(); + tp.getTestPlanList().add(plan.getEntity()); + return plan.getEntity(); + } + + public static void addTestCaseToPlan(TestPlan plan, TestCase testCase) + throws PreexistingEntityException, Exception { + int testInPlan = plan.getTestCaseList().size(); + TestPlanServer tps = new TestPlanServer(plan); + tps.getTestCaseList().add(testCase); + tps.write2DB(); + tps.update(plan, tps); + testCase.getTestPlanList().add(plan); + assertTrue(plan.getTestCaseList().size() > testInPlan); + } + + public static RequirementSpec createRequirementSpec(String name, + String description, Project project, int specLevelId) + throws Exception { + RequirementSpecServer rss = new RequirementSpecServer(name, description, + project.getId(), specLevelId); + rss.write2DB(); + project.getRequirementSpecList().add(rss.getEntity()); + new ProjectServer(project).write2DB(); + return rss.getEntity(); + } + + public static RequirementSpecNode createRequirementSpecNode( + RequirementSpec rss, String name, String description, String scope) + throws Exception { + RequirementSpecNodeServer rsns = new RequirementSpecNodeServer(rss, + name, description, scope); + rsns.write2DB(); + return rsns.getEntity(); + } + + public static void addTestProjectToProject(TestProject tp, Project project) + throws IllegalOrphanException, NonexistentEntityException, + Exception { + ProjectServer ps = new ProjectServer(project); + int current = ps.getTestProjectList().size(); + ps.getTestProjectList().add(tp); + ps.write2DB(); + assertTrue(ps.getEntity().getTestProjectList().size() > current); + tp.getProjectList().add(project); + } + + public static void addRequirementToStep(Step step, Requirement req) + throws Exception { + StepServer ss = new StepServer(step); + ss.addRequirement(req); + ss.write2DB(); + } + + public static Project addProject(Project root, String name, String notes) + throws NonexistentEntityException, Exception { + Project sub = createProject(name, notes); + ProjectServer ps = new ProjectServer(root); + ps.getProjectList().add(sub); + ps.write2DB(); + return new ProjectServer(sub).getEntity(); + } + + public static Requirement addChildToRequirement(Requirement parent, + Requirement child) throws Exception { + RequirementServer rs = new RequirementServer(parent); + rs.addChildRequirement(child); + return rs.getEntity(); + } +} diff --git a/Validation-Manager-Web/pom.xml b/Validation-Manager-Web/pom.xml index b1968668..ba06e2c3 100644 --- a/Validation-Manager-Web/pom.xml +++ b/Validation-Manager-Web/pom.xml @@ -4,7 +4,7 @@ Validation-Manager net.sourceforge.javydreamercsw - 0.3.2 + 0.3.3 Validation-Manager-Web @@ -112,6 +112,11 @@ jodconverter-core 4.0.0-RELEASE + + org.apache.poi + poi-scratchpad + ${poi.version} + com.vaadin @@ -136,18 +141,13 @@ pl.pdfviewer pdfviewer - 1.3.1 + 1.3.2 org.vaadin.addons imageviewer 0.6.0.v8 - - org.apache.poi - poi-scratchpad - ${poi.version} - de.steinwedel.vaadin.addon messagebox diff --git a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/LoginDialog.java b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/LoginDialog.java index b3260abe..94d59fd1 100644 --- a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/LoginDialog.java +++ b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/LoginDialog.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,141 +13,191 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package net.sourceforge.javydreamercsw.validation.manager.web; - -import com.vaadin.data.validator.StringLengthValidator; -import com.vaadin.event.Action; -import com.vaadin.event.Action.Handler; -import com.vaadin.event.ShortcutAction; -import com.vaadin.server.Page; -import com.vaadin.ui.Alignment; -import com.vaadin.ui.Button; -import com.vaadin.ui.Button.ClickEvent; -import com.vaadin.ui.FormLayout; -import com.vaadin.ui.HorizontalLayout; -import com.vaadin.ui.Notification; -import com.vaadin.ui.PasswordField; -import com.vaadin.ui.TextField; -import com.validation.manager.core.api.internationalization.InternationalizationProvider; -import com.validation.manager.core.db.VmUser; -import com.validation.manager.core.server.core.VMUserServer; -import org.openide.util.Lookup; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@SuppressWarnings("serial") -public final class LoginDialog extends VMWindow { - - private final ShortcutAction enterKey - = new ShortcutAction(Lookup.getDefault() - .lookup(InternationalizationProvider.class) - .translate("general.login"), - ShortcutAction.KeyCode.ENTER, null); - - private final TextField name = new TextField(Lookup.getDefault() - .lookup(InternationalizationProvider.class) - .translate("general.username")); - private final PasswordField password = new PasswordField(Lookup.getDefault() - .lookup(InternationalizationProvider.class) - .translate("general.password")); - - private final Button loginButton = new Button(Lookup.getDefault() - .lookup(InternationalizationProvider.class) - .translate("general.login"), - (ClickEvent event) -> { - tryToLogIn(); - }); - - private final Button cancelButton = new Button(Lookup.getDefault() - .lookup(InternationalizationProvider.class) - .translate("general.cancel"), - (ClickEvent event) -> { - LoginDialog.this.close(); - }); - - public LoginDialog(ValidationManagerUI menu) { - super(menu, Lookup.getDefault() - .lookup(InternationalizationProvider.class) - .translate("general.login")); - init(); - } - - public void init() { - //Layout - FormLayout layout = new FormLayout(); - setContent(layout); - HorizontalLayout hlayout = new HorizontalLayout(); - hlayout.addComponent(loginButton); - hlayout.addComponent(cancelButton); - layout.addComponent(name); - layout.addComponent(password); - name.focus(); - StringLengthValidator nameVal = new StringLengthValidator( - Lookup.getDefault() - .lookup(InternationalizationProvider.class). - translate("password.length.message")); - nameVal.setMinLength(5); - name.addValidator(nameVal); - name.setImmediate(true); - StringLengthValidator passVal = new StringLengthValidator( - Lookup.getDefault() - .lookup(InternationalizationProvider.class). - translate("password.empty.message")); - passVal.setMinLength(3); - password.addValidator(passVal); - password.setImmediate(true); - layout.addComponent(hlayout); - layout.setComponentAlignment(name, Alignment.TOP_LEFT); - layout.setComponentAlignment(password, Alignment.MIDDLE_LEFT); - layout.setComponentAlignment(hlayout, Alignment.BOTTOM_LEFT); - layout.setSpacing(true); - layout.setMargin(true); - - // Keyboard navigation - enter key is a shortcut to login - addActionHandler(new Handler() { - @Override - public Action[] getActions(Object target, Object sender) { - return new Action[]{enterKey}; - } - - @Override - public void handleAction(Action action, Object sender, - Object target) { - tryToLogIn(); - } - }); - } - - private void tryToLogIn() { - if (VMUserServer.validCredentials(name.getValue(), - password.getValue(), true)) { - VmUser user - = VMUserServer.getUser(name.getValue(), - password.getValue(), true); - if (menu != null) { - menu.setUser(new VMUserServer(user)); - } - close(); - } else { - if (menu != null) { - menu.setUser(null); - } - new Notification(Lookup.getDefault() - .lookup(InternationalizationProvider.class). - translate("general.login.invalid.title"), - Lookup.getDefault() - .lookup(InternationalizationProvider.class). - translate("general.login.invalid.message"), - Notification.Type.WARNING_MESSAGE, true) - .show(Page.getCurrent()); - password.setValue(""); - } - } - - public void clear() { - name.clear(); - password.clear(); - } -} +package net.sourceforge.javydreamercsw.validation.manager.web; + +import com.vaadin.data.validator.StringLengthValidator; +import com.vaadin.event.Action; +import com.vaadin.event.Action.Handler; +import com.vaadin.event.ShortcutAction; +import com.vaadin.server.Page; +import com.vaadin.ui.Alignment; +import com.vaadin.ui.Button; +import com.vaadin.ui.Button.ClickEvent; +import com.vaadin.ui.FormLayout; +import com.vaadin.ui.HorizontalLayout; +import com.vaadin.ui.Notification; +import com.vaadin.ui.PasswordField; +import com.vaadin.ui.TextField; +import com.vaadin.ui.UI; +import com.validation.manager.core.VMException; +import com.validation.manager.core.VMUI; +import com.validation.manager.core.api.internationalization.InternationalizationProvider; +import com.validation.manager.core.server.core.VMUserServer; +import java.util.logging.Level; +import java.util.logging.Logger; +import org.openide.util.Lookup; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@SuppressWarnings("serial") +public final class LoginDialog extends VMWindow { + + private static final InternationalizationProvider TRANSLATOR + = Lookup.getDefault().lookup(InternationalizationProvider.class); + private static final Logger LOG + = Logger.getLogger(LoginDialog.class.getSimpleName()); + private final ShortcutAction enterKey + = new ShortcutAction(Lookup.getDefault() + .lookup(InternationalizationProvider.class) + .translate("general.login"), + ShortcutAction.KeyCode.ENTER, null); + + private final TextField name = new TextField(Lookup.getDefault() + .lookup(InternationalizationProvider.class) + .translate("general.username")); + private final PasswordField password = new PasswordField(Lookup.getDefault() + .lookup(InternationalizationProvider.class) + .translate("general.password")); + + private final Button loginButton = new Button(Lookup.getDefault() + .lookup(InternationalizationProvider.class) + .translate("general.login"), + (ClickEvent event) -> { + tryToLogIn(); + }); + + private final Button cancelButton = new Button(Lookup.getDefault() + .lookup(InternationalizationProvider.class) + .translate("general.cancel"), + (ClickEvent event) -> { + LoginDialog.this.close(); + }); + + public LoginDialog(ValidationManagerUI menu) { + super(menu, Lookup.getDefault() + .lookup(InternationalizationProvider.class) + .translate("general.login")); + init(); + } + + public void init() { + //Layout + FormLayout layout = new FormLayout(); + setContent(layout); + HorizontalLayout hlayout = new HorizontalLayout(); + hlayout.addComponent(loginButton); + hlayout.addComponent(cancelButton); + layout.addComponent(name); + layout.addComponent(password); + name.focus(); + StringLengthValidator nameVal = new StringLengthValidator( + Lookup.getDefault() + .lookup(InternationalizationProvider.class). + translate("password.length.message")); + nameVal.setMinLength(5); + name.addValidator(nameVal); + name.setImmediate(true); + StringLengthValidator passVal = new StringLengthValidator( + Lookup.getDefault() + .lookup(InternationalizationProvider.class). + translate("password.empty.message")); + passVal.setMinLength(3); + password.addValidator(passVal); + password.setImmediate(true); + layout.addComponent(hlayout); + layout.setComponentAlignment(name, Alignment.TOP_LEFT); + layout.setComponentAlignment(password, Alignment.MIDDLE_LEFT); + layout.setComponentAlignment(hlayout, Alignment.BOTTOM_LEFT); + layout.setSpacing(true); + layout.setMargin(true); + + // Keyboard navigation - enter key is a shortcut to login + addActionHandler(new Handler() { + @Override + public Action[] getActions(Object target, Object sender) { + return new Action[]{enterKey}; + } + + @Override + public void handleAction(Action action, Object sender, + Object target) { + tryToLogIn(); + } + }); + } + + private void tryToLogIn() { + try { + //Throws exception if credentials are wrong. + VMUserServer user = new VMUserServer(name.getValue(), + password.getValue()); + if (menu != null) { + switch (user.getUserStatusId().getId()) { + case 1: + //Everything OK + menu.setUser(user); + break; + case 2: + //TODO: Inactive. Right now no special behavior + menu.setUser(user); + break; + case 3: + //Locked + new Notification(Lookup.getDefault() + .lookup(InternationalizationProvider.class). + translate("audit.user.account.lock"), + Lookup.getDefault() + .lookup(InternationalizationProvider.class). + translate("menu.connection.error.user"), + Notification.Type.ERROR_MESSAGE, true) + .show(Page.getCurrent()); + break; + case 4: + //Password Aged + new Notification(Lookup.getDefault() + .lookup(InternationalizationProvider.class). + translate("user.status.aged"), + Lookup.getDefault() + .lookup(InternationalizationProvider.class). + translate("user.status.aged"), + Notification.Type.WARNING_MESSAGE, true) + .show(Page.getCurrent()); + menu.setUser(user); + //Open the profile page + ((VMUI) UI.getCurrent()).showTab("message.admin.userProfile"); + break; + default: + LOG.log(Level.SEVERE, "Unexpected User Status: {0}", + user.getUserStatusId().getId()); + Notification.show("Unexpected User Status", + "Unexpected User Status: " + + user.getUserStatusId().getId() + + "\n" + TRANSLATOR.translate("message.db.error"), + Notification.Type.ERROR_MESSAGE); + break; + } + } + close(); + } catch (VMException ex) { + if (menu != null) { + menu.setUser(null); + } + new Notification(Lookup.getDefault() + .lookup(InternationalizationProvider.class). + translate("general.login.invalid.title"), + Lookup.getDefault() + .lookup(InternationalizationProvider.class). + translate("general.login.invalid.message"), + Notification.Type.WARNING_MESSAGE, true) + .show(Page.getCurrent()); + password.setValue(""); + } + } + + public void clear() { + name.clear(); + password.clear(); + } +} diff --git a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/ValidationManagerUI.java b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/ValidationManagerUI.java index 43af4eb7..0263ef77 100644 --- a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/ValidationManagerUI.java +++ b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/ValidationManagerUI.java @@ -164,9 +164,10 @@ import java.util.logging.Level; import java.util.logging.Logger; import javax.servlet.annotation.WebServlet; +import net.sourceforge.javydreamercsw.validation.manager.web.component.ByteToStringConverter; import net.sourceforge.javydreamercsw.validation.manager.web.dashboard.ExecutionDashboard; +import net.sourceforge.javydreamercsw.validation.manager.web.demo.DemoProvider; import net.sourceforge.javydreamercsw.validation.manager.web.importer.FileUploader; -import net.sourceforge.javydreamercsw.validation.manager.web.provider.DemoProvider; import net.sourceforge.javydreamercsw.validation.manager.web.provider.DesignerScreenProvider; import net.sourceforge.javydreamercsw.validation.manager.web.traceability.TraceMatrix; import net.sourceforge.javydreamercsw.validation.manager.web.wizard.assign.AssignUserStep; @@ -257,7 +258,7 @@ public void setUser(VMUserServer user) { user.setLocale(l.getLanguage()); try { user.write2DB(); - } catch (Exception ex) { + } catch (VMException ex) { LOG.log(Level.SEVERE, null, ex); } } else { @@ -529,7 +530,7 @@ public void wizardCancelled(WizardCancelledEvent event) { ess.getHistoryList().add(history.get(r)); }); ess.write2DB(); - } catch (Exception ex) { + } catch (VMException ex) { LOG.log(Level.SEVERE, null, ex); } }); @@ -1983,16 +1984,18 @@ private Component getMenu() { gl.addComponent(new Label(TRANSLATOR.translate("general.version") + ": " + getVersion()), 2, 2); if (getUser() != null) { + getUser().update(); //Logout button Button logout = new Button(TRANSLATOR.translate("general.logout")); logout.addClickListener((Button.ClickEvent event) -> { try { + user.update(); user.write2DB(); user = null; main = null; setLocale(Locale.ENGLISH); updateScreen(); - } catch (Exception ex) { + } catch (VMException ex) { LOG.log(Level.SEVERE, null, ex); } }); @@ -2818,8 +2821,7 @@ private Grid getHistoryTable(String title, String... fields) { Grid grid = new Grid(title); BeanItemContainer histories - = new BeanItemContainer<>(History.class - ); + = new BeanItemContainer<>(History.class); GeneratedPropertyContainer wrapperCont = new GeneratedPropertyContainer(histories); histories.addAll(historyItems); diff --git a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/admin/AdminScreenProvider.java b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/admin/AdminScreenProvider.java index cd99cc8c..e8785470 100644 --- a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/admin/AdminScreenProvider.java +++ b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/admin/AdminScreenProvider.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,151 +13,565 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package net.sourceforge.javydreamercsw.validation.manager.web.admin; - -import com.vaadin.data.Property; -import com.vaadin.data.fieldgroup.BeanFieldGroup; -import com.vaadin.data.fieldgroup.FieldGroup; -import com.vaadin.ui.Button; -import com.vaadin.ui.Component; -import com.vaadin.ui.Field; -import com.vaadin.ui.FormLayout; -import com.vaadin.ui.HorizontalLayout; -import com.vaadin.ui.HorizontalSplitPanel; -import com.vaadin.ui.Notification; -import com.vaadin.ui.Panel; -import com.vaadin.ui.TabSheet; -import com.vaadin.ui.TextArea; -import com.vaadin.ui.TextField; -import com.vaadin.ui.Tree; -import com.vaadin.ui.VerticalLayout; -import com.vaadin.ui.themes.ValoTheme; -import com.validation.manager.core.IMainContentProvider; -import com.validation.manager.core.api.internationalization.InternationalizationProvider; -import com.validation.manager.core.db.VmSetting; -import com.validation.manager.core.server.core.VMSettingServer; -import java.util.logging.Level; -import java.util.logging.Logger; -import net.sourceforge.javydreamercsw.validation.manager.web.ValidationManagerUI; -import net.sourceforge.javydreamercsw.validation.manager.web.provider.AbstractProvider; -import org.openide.util.Lookup; -import org.openide.util.lookup.ServiceProvider; - -@ServiceProvider(service = IMainContentProvider.class, position = 4) -public class AdminScreenProvider extends AbstractProvider { - - private static final Logger LOG - = Logger.getLogger(IMainContentProvider.class.getSimpleName()); - - @Override - public Component getContent() { - TabSheet adminSheet = new TabSheet(); - VerticalLayout layout = new VerticalLayout(); - //Build setting tab - VerticalLayout sl = new VerticalLayout(); - HorizontalSplitPanel split = new HorizontalSplitPanel(); - sl.addComponent(split); - //Build left side - Tree sTree = new Tree(Lookup.getDefault().lookup(InternationalizationProvider.class) - .translate("general.settings")); - adminSheet.addTab(sl, Lookup.getDefault().lookup(InternationalizationProvider.class) - .translate("general.settings")); - VMSettingServer.getSettings().stream().map((s) -> { - sTree.addItem(s); - sTree.setChildrenAllowed(s, false); - return s; - }).forEachOrdered((s) -> { - sTree.setItemCaption(s, Lookup.getDefault().lookup(InternationalizationProvider.class) - .translate(s.getSetting())); - }); - split.setFirstComponent(sTree); - layout.addComponent(adminSheet); - sTree.addValueChangeListener((Property.ValueChangeEvent event) -> { - if (sTree.getValue() instanceof VmSetting) { - split.setSecondComponent( - displaySetting((VmSetting) sTree.getValue())); - } - }); - layout.setId(getComponentCaption()); - return layout; - } - - @Override - public String getComponentCaption() { - return "admin.tab.name"; - } - - @Override - public boolean shouldDisplay() { - return ValidationManagerUI.getInstance().getUser() != null - && ValidationManagerUI.getInstance() - .checkRight("system.configuration"); - } - - private Component displaySetting(VmSetting s) { - Panel form = new Panel(Lookup.getDefault().lookup(InternationalizationProvider.class) - .translate("setting.detail")); - FormLayout layout = new FormLayout(); - form.setContent(layout); - form.addStyleName(ValoTheme.FORMLAYOUT_LIGHT); - BeanFieldGroup binder = new BeanFieldGroup(s.getClass()); - binder.setItemDataSource(s); - Field id = (TextField) binder.buildAndBind(Lookup.getDefault().lookup(InternationalizationProvider.class) - .translate("general.setting"), "setting"); - layout.addComponent(id); - Field bool = binder.buildAndBind(Lookup.getDefault().lookup(InternationalizationProvider.class) - .translate("bool.value"), "boolVal"); - bool.setSizeFull(); - layout.addComponent(bool); - Field integerVal = binder.buildAndBind(Lookup.getDefault().lookup(InternationalizationProvider.class) - .translate("int.value"), "intVal"); - integerVal.setSizeFull(); - layout.addComponent(integerVal); - Field longVal = binder.buildAndBind(Lookup.getDefault().lookup(InternationalizationProvider.class) - .translate("long.val"), "longVal"); - longVal.setSizeFull(); - layout.addComponent(longVal); - Field stringVal = binder.buildAndBind(Lookup.getDefault().lookup(InternationalizationProvider.class) - .translate("string.val"), "stringVal", - TextArea.class); - stringVal.setStyleName(ValoTheme.TEXTAREA_LARGE); - stringVal.setSizeFull(); - layout.addComponent(stringVal); - Button cancel = new Button(Lookup.getDefault().lookup(InternationalizationProvider.class) - .translate("general.cancel")); - cancel.addClickListener((Button.ClickEvent event) -> { - binder.discard(); - }); - //Editing existing one - Button update = new Button(Lookup.getDefault().lookup(InternationalizationProvider.class) - .translate("general.update")); - update.addClickListener((Button.ClickEvent event) -> { - try { - binder.commit(); - displaySetting(s); - } catch (FieldGroup.CommitException ex) { - LOG.log(Level.SEVERE, null, ex); - Notification.show(Lookup.getDefault().lookup(InternationalizationProvider.class) - .translate("general.error.record.update"), - ex.getLocalizedMessage(), - Notification.Type.ERROR_MESSAGE); - } - }); - boolean blocked = !s.getSetting().startsWith("version."); - if (blocked) { - HorizontalLayout hl = new HorizontalLayout(); - hl.addComponent(update); - hl.addComponent(cancel); - layout.addComponent(hl); - } - binder.setBuffered(true); - binder.setReadOnly(false); - binder.bindMemberFields(form); - //The version settigns are not modifiable from the GUI - binder.setEnabled(blocked); - //Id is always blocked. - id.setEnabled(false); - form.setSizeFull(); - return form; - } -} +package net.sourceforge.javydreamercsw.validation.manager.web.admin; + +import com.vaadin.data.Property; +import com.vaadin.data.fieldgroup.BeanFieldGroup; +import com.vaadin.data.fieldgroup.FieldGroup; +import com.vaadin.data.util.BeanItemContainer; +import com.vaadin.icons.VaadinIcons; +import com.vaadin.server.Sizeable; +import com.vaadin.shared.ui.grid.HeightMode; +import com.vaadin.ui.Button; +import com.vaadin.ui.ComboBox; +import com.vaadin.ui.Component; +import com.vaadin.ui.Field; +import com.vaadin.ui.FormLayout; +import com.vaadin.ui.Grid; +import com.vaadin.ui.Grid.SelectionMode; +import com.vaadin.ui.Grid.SingleSelectionModel; +import com.vaadin.ui.HorizontalLayout; +import com.vaadin.ui.HorizontalSplitPanel; +import com.vaadin.ui.Notification; +import com.vaadin.ui.Panel; +import com.vaadin.ui.TabSheet; +import com.vaadin.ui.TextArea; +import com.vaadin.ui.TextField; +import com.vaadin.ui.Tree; +import com.vaadin.ui.UI; +import com.vaadin.ui.VerticalLayout; +import com.vaadin.ui.themes.ValoTheme; +import com.validation.manager.core.DataBaseManager; +import com.validation.manager.core.IMainContentProvider; +import com.validation.manager.core.VMUI; +import com.validation.manager.core.api.email.IEmailManager; +import com.validation.manager.core.db.IssueResolution; +import com.validation.manager.core.db.IssueType; +import com.validation.manager.core.db.RequirementType; +import com.validation.manager.core.db.VmSetting; +import com.validation.manager.core.db.VmUser; +import com.validation.manager.core.db.controller.IssueResolutionJpaController; +import com.validation.manager.core.db.controller.IssueTypeJpaController; +import com.validation.manager.core.db.controller.RequirementTypeJpaController; +import com.validation.manager.core.db.controller.exceptions.IllegalOrphanException; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import com.validation.manager.core.server.core.VMSettingServer; +import com.validation.manager.core.server.core.VMUserServer; +import java.io.PrintWriter; +import java.io.StringWriter; +import java.util.Objects; +import java.util.logging.Level; +import java.util.logging.Logger; +import net.sourceforge.javydreamercsw.validation.manager.web.VMWindow; +import net.sourceforge.javydreamercsw.validation.manager.web.ValidationManagerUI; +import net.sourceforge.javydreamercsw.validation.manager.web.component.IssueResolutionComponent; +import net.sourceforge.javydreamercsw.validation.manager.web.component.IssueTypeComponent; +import net.sourceforge.javydreamercsw.validation.manager.web.component.RequirementTypeComponent; +import net.sourceforge.javydreamercsw.validation.manager.web.component.TranslationConverter; +import net.sourceforge.javydreamercsw.validation.manager.web.component.UserComponent; +import net.sourceforge.javydreamercsw.validation.manager.web.provider.AbstractProvider; +import org.openide.util.Lookup; +import org.openide.util.lookup.ServiceProvider; + +@ServiceProvider(service = IMainContentProvider.class, position = 4) +public class AdminScreenProvider extends AbstractProvider { + + private static final Logger LOG + = Logger.getLogger(IMainContentProvider.class.getSimpleName()); + private final TabSheet adminSheet = new TabSheet(); + private final String ISSUE_TYPE = "issue.type", + ISSUE_RESOLUTION = "issue.resolution", + REQUIREMENT_TYPE = "requirement.type", + DESC = "description", + DELETE_ERROR = "delete.error", + NAME = "name"; + + @Override + public Component getContent() { + VerticalLayout layout = new VerticalLayout(); + adminSheet.removeAllComponents(); + //Build left side + //Build setting tab + adminSheet.addTab(getSettingTab(), TRANSLATOR + .translate("general.settings")); + //Build email setting tab + adminSheet.addTab(getEmailSettingTab(), TRANSLATOR + .translate("general.email.settings")); + //Build user management tab + adminSheet.addTab(getUserManagementTab(), TRANSLATOR + .translate("menu.user")); + //Build configurable items management tab + adminSheet.addTab(getConfigurableTab(), TRANSLATOR + .translate("general.configuration")); + layout.addComponent(adminSheet); + layout.setId(getComponentCaption()); + return layout; + } + + @Override + public void update() { + adminSheet.removeAllComponents(); + adminSheet.addTab(getSettingTab(), TRANSLATOR + .translate("general.settings")); + //Build email setting tab + adminSheet.addTab(getEmailSettingTab(), TRANSLATOR + .translate("general.email.settings")); + //Build user management tab + adminSheet.addTab(getUserManagementTab(), TRANSLATOR + .translate("menu.user")); + //Build configurable items management tab + adminSheet.addTab(getConfigurableTab(), TRANSLATOR + .translate("general.configuration")); + super.update(); + } + + @Override + public String getComponentCaption() { + return "admin.tab.name"; + } + + @Override + public boolean shouldDisplay() { + return ValidationManagerUI.getInstance().getUser() != null + && ValidationManagerUI.getInstance() + .checkRight("system.configuration"); + } + + private Component displaySetting(VmSetting s) { + return displaySetting(s, false); + } + + private Component displaySetting(VmSetting s, boolean edit) { + Panel form = new Panel(TRANSLATOR + .translate("setting.detail")); + FormLayout layout = new FormLayout(); + form.setContent(layout); + form.addStyleName(ValoTheme.FORMLAYOUT_LIGHT); + BeanFieldGroup binder = new BeanFieldGroup(s.getClass()); + binder.setItemDataSource(s); + Field id = (TextField) binder.buildAndBind(TRANSLATOR + .translate("general.setting"), "setting"); + layout.addComponent(id); + Field bool = binder.buildAndBind(TRANSLATOR + .translate("bool.value"), "boolVal"); + bool.setSizeFull(); + layout.addComponent(bool); + Field integerVal = binder.buildAndBind(TRANSLATOR + .translate("int.value"), "intVal"); + integerVal.setSizeFull(); + layout.addComponent(integerVal); + Field longVal = binder.buildAndBind(TRANSLATOR + .translate("long.val"), "longVal"); + longVal.setSizeFull(); + layout.addComponent(longVal); + Field stringVal = binder.buildAndBind(TRANSLATOR + .translate("string.val"), "stringVal", + TextArea.class); + stringVal.setSizeFull(); + layout.addComponent(stringVal); + Button cancel = new Button(TRANSLATOR + .translate("general.cancel")); + cancel.addClickListener((Button.ClickEvent event) -> { + binder.discard(); + }); + //Editing existing one + Button update = new Button(TRANSLATOR + .translate("general.update")); + update.addClickListener((Button.ClickEvent event) -> { + try { + binder.commit(); + displaySetting(s); + } catch (FieldGroup.CommitException ex) { + LOG.log(Level.SEVERE, null, ex); + Notification.show(TRANSLATOR + .translate("general.error.record.update"), + ex.getLocalizedMessage(), + Notification.Type.ERROR_MESSAGE); + } + }); + boolean blocked = !s.getSetting().startsWith("version."); + if (blocked) { + HorizontalLayout hl = new HorizontalLayout(); + hl.addComponent(update); + hl.addComponent(cancel); + layout.addComponent(hl); + } + binder.setBuffered(true); + binder.setReadOnly(edit); + binder.bindMemberFields(form); + //The version settigns are not modifiable from the GUI + binder.setEnabled(blocked); + //Id is always blocked. + id.setEnabled(false); + form.setSizeFull(); + return form; + } + + private Component getEmailSettingTab() { + VerticalLayout s2 = new VerticalLayout(); + HorizontalSplitPanel split2 = new HorizontalSplitPanel(); + s2.addComponent(split2); + Tree sTree2 = new Tree(TRANSLATOR + .translate("general.email.settings")); + sTree2.addValueChangeListener((Property.ValueChangeEvent event) -> { + if (sTree2.getValue() instanceof VmSetting) { + VmSetting vmSetting = (VmSetting) sTree2.getValue(); + split2.setSecondComponent( + displaySetting(vmSetting, + !vmSetting.getSetting().equals("mail.enable"))); + } + }); + split2.setFirstComponent(sTree2); + VMSettingServer.getSettings().forEach(s -> { + if (s.getSetting().startsWith("mail")) { + sTree2.addItem(s); + sTree2.setChildrenAllowed(s, false); + sTree2.setItemCaption(s, TRANSLATOR + .translate(s.getSetting())); + } + }); + Button testEmail = new Button(TRANSLATOR + .translate("general.email.settings.test"), + listener -> { + //Show a window to test email settings + VMWindow w = new VMWindow(TRANSLATOR + .translate("general.email.settings.test")); + w.setModal(true); + VerticalLayout vl = new VerticalLayout(); + TextField to = new TextField(TRANSLATOR.translate("general.email.to")); + TextField from = new TextField(TRANSLATOR.translate("general.email.from")); + TextField subject = new TextField(TRANSLATOR.translate("general.email.subject")); + TextArea mess = new TextArea(TRANSLATOR.translate("general.email.message")); + mess.setSizeFull(); + TextArea output = new TextArea(TRANSLATOR.translate("general.output")); + output.setReadOnly(true); + output.setSizeFull(); + Button send = new Button(TRANSLATOR.translate("general.email.send"), + l -> { + try { + Lookup.getDefault().lookup(IEmailManager.class) + .sendEmail(to.getValue(), null, + from.getValue(), + subject.getValue(), + mess.getValue()); + output.setValue(TRANSLATOR.translate("general.email.settings.test.success")); + //Successful, update the enable setting. + VMSettingServer enable = new VMSettingServer("mail.enable"); + enable.setBoolVal(true); + enable.write2DB(); + } catch (Exception ex) { + LOG.log(Level.SEVERE, null, ex); + StringWriter sw = new StringWriter(); + ex.printStackTrace(new PrintWriter(sw)); + output.setReadOnly(false); + output.setValue(sw.toString()); + output.setReadOnly(true); + } + }); + vl.addComponent(to); + vl.addComponent(from); + vl.addComponent(subject); + vl.addComponent(mess); + vl.addComponent(send); + vl.addComponent(output); + w.setContent(vl); + w.setHeight(75, Sizeable.Unit.PERCENTAGE); + w.setWidth(75, Sizeable.Unit.PERCENTAGE); + ValidationManagerUI.getInstance().addWindow(w); + }); + s2.addComponent(testEmail); + return s2; + } + + private Component getSettingTab() { + VerticalLayout sl = new VerticalLayout(); + HorizontalSplitPanel split1 = new HorizontalSplitPanel(); + sl.addComponent(split1); + Tree sTree = new Tree(TRANSLATOR + .translate("general.settings")); + split1.setFirstComponent(sTree); + sTree.addValueChangeListener((Property.ValueChangeEvent event) -> { + if (sTree.getValue() instanceof VmSetting) { + split1.setSecondComponent( + displaySetting((VmSetting) sTree.getValue())); + } + }); + VMSettingServer.getSettings().forEach(s -> { + if (!s.getSetting().startsWith("mail")) { + sTree.addItem(s); + sTree.setChildrenAllowed(s, false); + sTree.setItemCaption(s, TRANSLATOR + .translate(s.getSetting())); + } + }); + return sl; + } + + private Component getUserManagementTab() { + VerticalLayout vl = new VerticalLayout(); + HorizontalSplitPanel split = new HorizontalSplitPanel(); + vl.addComponent(split); + //Create left side + Tree users = new Tree(); + //Menu + VerticalLayout main = new VerticalLayout(); + main.addComponent(users); + HorizontalLayout hl = new HorizontalLayout(); + Button addUser = new Button(TRANSLATOR.translate("add.user")); + addUser.addClickListener(listener -> { + VmUser user = new VmUser(); + split.setSecondComponent(new UserComponent(user, true)); + }); + hl.addComponent(addUser); + main.addComponent(hl); + split.setFirstComponent(main); + VMUserServer.getVMUsers().forEach(user -> { + if (!Objects.equals(user.getId(), + ((VMUI) UI.getCurrent()).getUser().getId())) { + users.addItem(user.getEntity()); + users.setItemCaption(user.getEntity(), user.toString()); + users.setItemIcon(user.getEntity(), VaadinIcons.USER); + users.setChildrenAllowed(user.getEntity(), false); + } + }); + users.addValueChangeListener((Property.ValueChangeEvent event) -> { + VmUser user = (VmUser) users.getValue(); + split.setSecondComponent(new UserComponent(user, true)); + }); + vl.setSizeFull(); + return vl; + } + + private Component getConfigurableTab() { + VerticalLayout vl = new VerticalLayout(); + ComboBox options = new ComboBox(); + options.addItem(ISSUE_TYPE); + options.setItemCaption(ISSUE_TYPE, + TRANSLATOR.translate(ISSUE_TYPE)); + options.addItem(ISSUE_RESOLUTION); + options.setItemCaption(ISSUE_RESOLUTION, + TRANSLATOR.translate(ISSUE_RESOLUTION)); + options.addItem(REQUIREMENT_TYPE); + options.setItemCaption(REQUIREMENT_TYPE, + TRANSLATOR.translate(REQUIREMENT_TYPE)); + options.setTextInputAllowed(false); + options.addValueChangeListener((Property.ValueChangeEvent event) -> { + Component nextComp = null; + if (options.getValue() != null) { + switch ((String) options.getValue()) { + case ISSUE_TYPE: + nextComp = displayIssueTypes(); + break; + case ISSUE_RESOLUTION: + nextComp = displayIssueResolutions(); + break; + case REQUIREMENT_TYPE: + nextComp = displayRequirementTypes(); + break; + default: + //Do nothing + } + } + if (nextComp != null) { + vl.removeAllComponents(); + vl.addComponent(options); + vl.addComponent(nextComp); + } + }); + vl.addComponent(options); + vl.setSizeFull(); + return vl; + } + + private Component displayIssueTypes() { + VerticalLayout vl = new VerticalLayout(); + Grid grid = new Grid(TRANSLATOR.translate(ISSUE_TYPE)); + BeanItemContainer types + = new BeanItemContainer<>(IssueType.class); + types.addAll(new IssueTypeJpaController(DataBaseManager + .getEntityManagerFactory()) + .findIssueTypeEntities()); + grid.setContainerDataSource(types); + grid.setSelectionMode(SelectionMode.SINGLE); + grid.setColumns("typeName", DESC); + Grid.Column name = grid.getColumn("typeName"); + name.setHeaderCaption(TRANSLATOR.translate("general.name")); + name.setConverter(new TranslationConverter()); + Grid.Column desc = grid.getColumn(DESC); + desc.setHeaderCaption(TRANSLATOR.translate("general.description")); + desc.setConverter(new TranslationConverter()); + grid.setSizeFull(); + vl.addComponent(grid); + grid.setHeightMode(HeightMode.ROW); + grid.setHeightByRows(types.size() > 5 ? 5 : types.size()); + //Menu + HorizontalLayout hl = new HorizontalLayout(); + Button add = new Button(TRANSLATOR.translate("general.create")); + add.addClickListener(listener -> { + VMWindow w = new VMWindow(); + w.setContent(new IssueTypeComponent(new IssueType(), true)); + w.setModal(true); + ((VMUI) UI.getCurrent()).addWindow(w); + w.addCloseListener(l -> { + ((VMUI) UI.getCurrent()).updateScreen(); + }); + }); + hl.addComponent(add); + Button delete = new Button(TRANSLATOR.translate("general.delete")); + delete.setEnabled(false); + delete.addClickListener(listener -> { + IssueType selected = (IssueType) ((SingleSelectionModel) grid. + getSelectionModel()).getSelectedRow(); + if (selected != null && selected.getId() >= 1000) { + try { + new IssueTypeJpaController(DataBaseManager + .getEntityManagerFactory()) + .destroy(selected.getId()); + ((VMUI) UI.getCurrent()).updateScreen(); + } catch (IllegalOrphanException | NonexistentEntityException ex) { + LOG.log(Level.SEVERE, null, ex); + Notification.show(TRANSLATOR.translate(DELETE_ERROR), + TRANSLATOR.translate(DELETE_ERROR), + Notification.Type.ERROR_MESSAGE); + } + } + }); + hl.addComponent(delete); + vl.addComponent(hl); + grid.addSelectionListener(event -> { // Java 8 + // Get selection from the selection model + IssueType selected = (IssueType) ((SingleSelectionModel) grid. + getSelectionModel()).getSelectedRow(); + //Only delete custom ones. + delete.setEnabled(selected != null && selected.getId() >= 1000); + }); + return vl; + } + + private Component displayIssueResolutions() { + VerticalLayout vl = new VerticalLayout(); + Grid grid = new Grid(TRANSLATOR.translate(ISSUE_RESOLUTION)); + BeanItemContainer types + = new BeanItemContainer<>(IssueResolution.class); + types.addAll(new IssueResolutionJpaController(DataBaseManager + .getEntityManagerFactory()) + .findIssueResolutionEntities()); + grid.setContainerDataSource(types); + grid.setSelectionMode(SelectionMode.SINGLE); + grid.setColumns(NAME); + Grid.Column name = grid.getColumn(NAME); + name.setHeaderCaption(TRANSLATOR.translate("general.name")); + name.setConverter(new TranslationConverter()); + grid.setSizeFull(); + vl.addComponent(grid); + grid.setHeightMode(HeightMode.ROW); + grid.setHeightByRows(types.size() > 5 ? 5 : types.size()); + //Menu + HorizontalLayout hl = new HorizontalLayout(); + Button add = new Button(TRANSLATOR.translate("general.create")); + add.addClickListener(listener -> { + VMWindow w = new VMWindow(); + w.setContent(new IssueResolutionComponent(new IssueResolution(), true)); + w.setModal(true); + ((VMUI) UI.getCurrent()).addWindow(w); + w.addCloseListener(l -> { + ((VMUI) UI.getCurrent()).updateScreen(); + }); + }); + hl.addComponent(add); + Button delete = new Button(TRANSLATOR.translate("general.delete")); + delete.setEnabled(false); + delete.addClickListener(listener -> { + IssueResolution selected = (IssueResolution) ((SingleSelectionModel) grid. + getSelectionModel()).getSelectedRow(); + if (selected != null && selected.getId() >= 1000) { + try { + new IssueResolutionJpaController(DataBaseManager + .getEntityManagerFactory()) + .destroy(selected.getId()); + ((VMUI) UI.getCurrent()).updateScreen(); + } catch (IllegalOrphanException | NonexistentEntityException ex) { + LOG.log(Level.SEVERE, null, ex); + Notification.show(TRANSLATOR.translate(DELETE_ERROR), + TRANSLATOR.translate(DELETE_ERROR), + Notification.Type.ERROR_MESSAGE); + } + } + }); + hl.addComponent(delete); + vl.addComponent(hl); + grid.addSelectionListener(event -> { // Java 8 + // Get selection from the selection model + IssueResolution selected = (IssueResolution) ((SingleSelectionModel) grid. + getSelectionModel()).getSelectedRow(); + //Only delete custom ones. + delete.setEnabled(selected != null && selected.getId() >= 1000); + }); + return vl; + } + + private Component displayRequirementTypes() { + VerticalLayout vl = new VerticalLayout(); + Grid grid = new Grid(TRANSLATOR.translate(REQUIREMENT_TYPE)); + BeanItemContainer types + = new BeanItemContainer<>(RequirementType.class); + types.addAll(new RequirementTypeJpaController(DataBaseManager + .getEntityManagerFactory()) + .findRequirementTypeEntities()); + grid.setContainerDataSource(types); + grid.setSelectionMode(SelectionMode.SINGLE); + grid.setColumns(NAME, DESC); + Grid.Column name = grid.getColumn(NAME); + name.setHeaderCaption(TRANSLATOR.translate("general.name")); + name.setConverter(new TranslationConverter()); + Grid.Column desc = grid.getColumn(DESC); + desc.setHeaderCaption(TRANSLATOR.translate("general.description")); + desc.setConverter(new TranslationConverter()); + grid.setSizeFull(); + vl.addComponent(grid); + grid.setHeightMode(HeightMode.ROW); + grid.setHeightByRows(types.size() > 5 ? 5 : types.size()); + //Menu + HorizontalLayout hl = new HorizontalLayout(); + Button add = new Button(TRANSLATOR.translate("general.create")); + add.addClickListener(listener -> { + VMWindow w = new VMWindow(); + w.setContent(new RequirementTypeComponent(new RequirementType(), true)); + w.setModal(true); + ((VMUI) UI.getCurrent()).addWindow(w); + w.addCloseListener(l -> { + ((VMUI) UI.getCurrent()).updateScreen(); + }); + }); + hl.addComponent(add); + Button delete = new Button(TRANSLATOR.translate("general.delete")); + delete.setEnabled(false); + delete.addClickListener(listener -> { + RequirementType selected = (RequirementType) ((SingleSelectionModel) grid. + getSelectionModel()).getSelectedRow(); + if (selected != null && selected.getId() >= 1000) { + try { + new RequirementTypeJpaController(DataBaseManager + .getEntityManagerFactory()) + .destroy(selected.getId()); + ((VMUI) UI.getCurrent()).updateScreen(); + } catch (IllegalOrphanException | NonexistentEntityException ex) { + LOG.log(Level.SEVERE, null, ex); + Notification.show(TRANSLATOR.translate(DELETE_ERROR), + TRANSLATOR.translate(DELETE_ERROR), + Notification.Type.ERROR_MESSAGE); + } + } + }); + hl.addComponent(delete); + vl.addComponent(hl); + grid.addSelectionListener(event -> { // Java 8 + // Get selection from the selection model + RequirementType selected = (RequirementType) ((SingleSelectionModel) grid. + getSelectionModel()).getSelectedRow(); + //Only delete custom ones. + delete.setEnabled(selected != null && selected.getId() >= 1000); + }); + return vl; + } +} diff --git a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/ByteToStringConverter.java b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/ByteToStringConverter.java similarity index 93% rename from Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/ByteToStringConverter.java rename to Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/ByteToStringConverter.java index 6f43a582..f4893775 100644 --- a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/ByteToStringConverter.java +++ b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/ByteToStringConverter.java @@ -13,54 +13,54 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package net.sourceforge.javydreamercsw.validation.manager.web; - -import com.vaadin.data.util.converter.Converter; -import java.io.UnsupportedEncodingException; -import java.nio.charset.StandardCharsets; -import java.util.Locale; -import java.util.logging.Level; -import java.util.logging.Logger; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class ByteToStringConverter implements Converter { - - private static final Logger LOG - = Logger.getLogger(ByteToStringConverter.class.getSimpleName()); - - @Override - public byte[] convertToModel(String value, - Class targetType, Locale locale) - throws ConversionException { - try { - String result = value; - if (value == null) { - result = "null"; - } - return result.getBytes("UTF-8"); - } catch (UnsupportedEncodingException ex) { - LOG.log(Level.SEVERE, null, ex); - } - return null; - } - - @Override - public String convertToPresentation(byte[] value, - Class targetType, Locale locale) - throws ConversionException { - return value == null ? "null" : new String(value, StandardCharsets.UTF_8); - } - - @Override - public Class getModelType() { - return byte[].class; - } - - @Override - public Class getPresentationType() { - return String.class; - } -} +package net.sourceforge.javydreamercsw.validation.manager.web.component; + +import com.vaadin.data.util.converter.Converter; +import java.io.UnsupportedEncodingException; +import java.nio.charset.StandardCharsets; +import java.util.Locale; +import java.util.logging.Level; +import java.util.logging.Logger; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class ByteToStringConverter implements Converter { + + private static final Logger LOG + = Logger.getLogger(ByteToStringConverter.class.getSimpleName()); + + @Override + public byte[] convertToModel(String value, + Class targetType, Locale locale) + throws ConversionException { + try { + String result = value; + if (value == null) { + result = "null"; + } + return result.getBytes("UTF-8"); + } catch (UnsupportedEncodingException ex) { + LOG.log(Level.SEVERE, null, ex); + } + return null; + } + + @Override + public String convertToPresentation(byte[] value, + Class targetType, Locale locale) + throws ConversionException { + return value == null ? "null" : new String(value, StandardCharsets.UTF_8); + } + + @Override + public Class getModelType() { + return byte[].class; + } + + @Override + public Class getPresentationType() { + return String.class; + } +} diff --git a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/IssueResolutionComponent.java b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/IssueResolutionComponent.java new file mode 100644 index 00000000..a35f0a15 --- /dev/null +++ b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/IssueResolutionComponent.java @@ -0,0 +1,127 @@ +/* + * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package net.sourceforge.javydreamercsw.validation.manager.web.component; + +import com.vaadin.data.fieldgroup.BeanFieldGroup; +import com.vaadin.data.fieldgroup.FieldGroup; +import com.vaadin.ui.Button; +import com.vaadin.ui.Component; +import com.vaadin.ui.Field; +import com.vaadin.ui.FormLayout; +import com.vaadin.ui.HorizontalLayout; +import com.vaadin.ui.Panel; +import com.vaadin.ui.UI; +import com.vaadin.ui.themes.ValoTheme; +import com.validation.manager.core.DataBaseManager; +import com.validation.manager.core.VMUI; +import com.validation.manager.core.api.internationalization.InternationalizationProvider; +import com.validation.manager.core.db.IssueResolution; +import com.validation.manager.core.db.controller.IssueResolutionJpaController; +import java.util.logging.Level; +import java.util.logging.Logger; +import org.openide.util.Lookup; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public final class IssueResolutionComponent extends Panel { + + private final IssueResolution ir; + private boolean edit = false; + private static final InternationalizationProvider TRANSLATOR + = Lookup.getDefault().lookup(InternationalizationProvider.class); + private static final Logger LOG + = Logger.getLogger(IssueResolutionComponent.class.getSimpleName()); + + public IssueResolutionComponent(IssueResolution ir, boolean edit) { + setCaption(TRANSLATOR.translate("issue.resolution")); + this.ir = ir; + this.edit = edit; + init(); + } + + public IssueResolutionComponent(IssueResolution ir, Component content, + boolean edit) { + super(content); + setCaption(TRANSLATOR.translate("issue.resolution")); + this.ir = ir; + this.edit = edit; + init(); + } + + public IssueResolutionComponent(IssueResolution ir, String caption, + boolean edit) { + super(caption); + this.ir = ir; + this.edit = edit; + init(); + } + + public IssueResolutionComponent(IssueResolution ir, String caption, + Component content, boolean edit) { + super(caption, content); + this.ir = ir; + this.edit = edit; + init(); + } + + private void init() { + FormLayout layout = new FormLayout(); + setContent(layout); + addStyleName(ValoTheme.FORMLAYOUT_LIGHT); + BeanFieldGroup binder = new BeanFieldGroup(ir.getClass()); + binder.setItemDataSource(ir); + Field name = binder.buildAndBind(TRANSLATOR + .translate("general.name"), "name"); + layout.addComponent(name); + if (edit) { + Button update = new Button(ir.getId() == null + ? TRANSLATOR. + translate("general.create") + : TRANSLATOR. + translate("general.update")); + update.addClickListener((Button.ClickEvent event) -> { + IssueResolutionJpaController c + = new IssueResolutionJpaController(DataBaseManager. + getEntityManagerFactory()); + if (ir.getId() == null) { + ir.setName((String) name.getValue()); + c.create(ir); + } else { + try { + binder.commit(); + } catch (FieldGroup.CommitException ex) { + LOG.log(Level.SEVERE, null, ex); + } + } + }); + Button cancel = new Button(Lookup.getDefault() + .lookup(InternationalizationProvider.class). + translate("general.cancel")); + cancel.addClickListener((Button.ClickEvent event) -> { + binder.discard(); + ((VMUI) UI.getCurrent()).updateScreen(); + }); + binder.setReadOnly(!edit); + binder.setBuffered(true); + HorizontalLayout hl = new HorizontalLayout(); + hl.addComponent(update); + hl.addComponent(cancel); + layout.addComponent(hl); + } + } +} diff --git a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/IssueTypeComponent.java b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/IssueTypeComponent.java new file mode 100644 index 00000000..1cf08b34 --- /dev/null +++ b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/IssueTypeComponent.java @@ -0,0 +1,124 @@ +/* + * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package net.sourceforge.javydreamercsw.validation.manager.web.component; + +import com.vaadin.data.fieldgroup.BeanFieldGroup; +import com.vaadin.data.fieldgroup.FieldGroup; +import com.vaadin.ui.Button; +import com.vaadin.ui.Field; +import com.vaadin.ui.FormLayout; +import com.vaadin.ui.HorizontalLayout; +import com.vaadin.ui.Panel; +import com.vaadin.ui.UI; +import com.vaadin.ui.themes.ValoTheme; +import com.validation.manager.core.DataBaseManager; +import com.validation.manager.core.VMUI; +import com.validation.manager.core.api.internationalization.InternationalizationProvider; +import com.validation.manager.core.db.IssueType; +import com.validation.manager.core.db.controller.IssueTypeJpaController; +import java.util.logging.Level; +import java.util.logging.Logger; +import org.openide.util.Lookup; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public final class IssueTypeComponent extends Panel { + + private final IssueType it; + private boolean edit = false; + private static final InternationalizationProvider TRANSLATOR + = Lookup.getDefault().lookup(InternationalizationProvider.class); + private static final Logger LOG + = Logger.getLogger(IssueTypeComponent.class.getSimpleName()); + + public IssueTypeComponent(IssueType it, boolean edit) { + setCaption(TRANSLATOR.translate("issue.type")); + this.it = it; + this.edit = edit; + init(); + } + + public IssueTypeComponent(IssueType it, String caption, boolean edit) { + super(caption); + this.it = it; + this.edit = edit; + init(); + } + + public IssueTypeComponent(IssueType it) { + setCaption(TRANSLATOR.translate("issue.type")); + this.it = it; + init(); + } + + public IssueTypeComponent(IssueType it, String caption) { + super(caption); + this.it = it; + init(); + } + + private void init() { + FormLayout layout = new FormLayout(); + setContent(layout); + addStyleName(ValoTheme.FORMLAYOUT_LIGHT); + BeanFieldGroup binder = new BeanFieldGroup(it.getClass()); + binder.setItemDataSource(it); + Field name = binder.buildAndBind(TRANSLATOR + .translate("general.name"), "typeName"); + layout.addComponent(name); + Field desc = binder.buildAndBind(TRANSLATOR + .translate("general.description"), "description"); + layout.addComponent(desc); + if (edit) { + Button update = new Button(it.getId() == null + ? TRANSLATOR. + translate("general.create") + : TRANSLATOR. + translate("general.update")); + update.addClickListener((Button.ClickEvent event) -> { + IssueTypeJpaController c + = new IssueTypeJpaController(DataBaseManager. + getEntityManagerFactory()); + if (it.getId() == null) { + it.setDescription((String) desc.getValue()); + it.setTypeName((String) name.getValue()); + c.create(it); + } else { + try { + binder.commit(); + } catch (FieldGroup.CommitException ex) { + LOG.log(Level.SEVERE, null, ex); + } + } + }); + Button cancel = new Button(Lookup.getDefault() + .lookup(InternationalizationProvider.class). + translate("general.cancel")); + cancel.addClickListener((Button.ClickEvent event) -> { + binder.discard(); + ((VMUI) UI.getCurrent()).updateScreen(); + }); + binder.setReadOnly(!edit); + binder.setBuffered(true); + HorizontalLayout hl = new HorizontalLayout(); + hl.addComponent(update); + hl.addComponent(cancel); + layout.addComponent(hl); + } + } +} diff --git a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/RequirementTypeComponent.java b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/RequirementTypeComponent.java new file mode 100644 index 00000000..99523d9e --- /dev/null +++ b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/RequirementTypeComponent.java @@ -0,0 +1,131 @@ +/* + * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package net.sourceforge.javydreamercsw.validation.manager.web.component; + +import com.vaadin.data.fieldgroup.BeanFieldGroup; +import com.vaadin.data.fieldgroup.FieldGroup; +import com.vaadin.ui.Button; +import com.vaadin.ui.Component; +import com.vaadin.ui.Field; +import com.vaadin.ui.FormLayout; +import com.vaadin.ui.HorizontalLayout; +import com.vaadin.ui.Panel; +import com.vaadin.ui.UI; +import com.vaadin.ui.themes.ValoTheme; +import com.validation.manager.core.DataBaseManager; +import com.validation.manager.core.VMUI; +import com.validation.manager.core.api.internationalization.InternationalizationProvider; +import com.validation.manager.core.db.RequirementType; +import com.validation.manager.core.db.controller.RequirementTypeJpaController; +import java.util.logging.Level; +import java.util.logging.Logger; +import org.openide.util.Lookup; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public final class RequirementTypeComponent extends Panel { + + private final RequirementType rt; + private boolean edit = false; + private static final InternationalizationProvider TRANSLATOR + = Lookup.getDefault().lookup(InternationalizationProvider.class); + private static final Logger LOG + = Logger.getLogger(RequirementTypeComponent.class.getSimpleName()); + + public RequirementTypeComponent(RequirementType rt, boolean edit) { + setCaption(TRANSLATOR.translate("issue.resolution")); + this.rt = rt; + this.edit = edit; + init(); + } + + public RequirementTypeComponent(RequirementType rt, Component content, + boolean edit) { + super(content); + setCaption(TRANSLATOR.translate("issue.resolution")); + this.rt = rt; + this.edit = edit; + init(); + } + + public RequirementTypeComponent(RequirementType rt, String caption, + boolean edit) { + super(caption); + this.rt = rt; + this.edit = edit; + init(); + } + + public RequirementTypeComponent(RequirementType rt, String caption, + Component content, boolean edit) { + super(caption, content); + this.rt = rt; + this.edit = edit; + init(); + } + + private void init() { + FormLayout layout = new FormLayout(); + setContent(layout); + addStyleName(ValoTheme.FORMLAYOUT_LIGHT); + BeanFieldGroup binder = new BeanFieldGroup(rt.getClass()); + binder.setItemDataSource(rt); + Field name = binder.buildAndBind(TRANSLATOR + .translate("general.name"), "name"); + layout.addComponent(name); + Field desc = binder.buildAndBind(TRANSLATOR + .translate("general.description"), "description"); + layout.addComponent(desc); + if (edit) { + Button update = new Button(rt.getId() == null + ? TRANSLATOR. + translate("general.create") + : TRANSLATOR. + translate("general.update")); + update.addClickListener((Button.ClickEvent event) -> { + RequirementTypeJpaController c + = new RequirementTypeJpaController(DataBaseManager. + getEntityManagerFactory()); + if (rt.getId() == null) { + rt.setName((String) name.getValue()); + rt.setDescription((String) desc.getValue()); + c.create(rt); + } else { + try { + binder.commit(); + } catch (FieldGroup.CommitException ex) { + LOG.log(Level.SEVERE, null, ex); + } + } + }); + Button cancel = new Button(Lookup.getDefault() + .lookup(InternationalizationProvider.class). + translate("general.cancel")); + cancel.addClickListener((Button.ClickEvent event) -> { + binder.discard(); + ((VMUI) UI.getCurrent()).updateScreen(); + }); + binder.setReadOnly(!edit); + binder.setBuffered(true); + HorizontalLayout hl = new HorizontalLayout(); + hl.addComponent(update); + hl.addComponent(cancel); + layout.addComponent(hl); + } + } +} diff --git a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/TranslationConverter.java b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/TranslationConverter.java new file mode 100644 index 00000000..f53b992f --- /dev/null +++ b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/TranslationConverter.java @@ -0,0 +1,55 @@ +/* + * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package net.sourceforge.javydreamercsw.validation.manager.web.component; + +import com.vaadin.data.util.converter.Converter; +import com.validation.manager.core.api.internationalization.InternationalizationProvider; +import java.util.Locale; +import org.openide.util.Lookup; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class TranslationConverter implements Converter { + + private static final InternationalizationProvider TRANSLATOR + = Lookup.getDefault().lookup(InternationalizationProvider.class); + + @Override + public String convertToModel(String value, + Class targetType, Locale locale) + throws ConversionException { + return value; + } + + @Override + public String convertToPresentation(String value, + Class targetType, Locale locale) + throws ConversionException { + return TRANSLATOR.translate(value); + } + + @Override + public Class getModelType() { + return String.class; + } + + @Override + public Class getPresentationType() { + return String.class; + } +} diff --git a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/TreeTableCheckBox.java b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/TreeTableCheckBox.java similarity index 95% rename from Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/TreeTableCheckBox.java rename to Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/TreeTableCheckBox.java index db88c1a4..f1ceb69a 100644 --- a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/TreeTableCheckBox.java +++ b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/TreeTableCheckBox.java @@ -13,90 +13,90 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package net.sourceforge.javydreamercsw.validation.manager.web; - -import com.vaadin.data.Item; -import com.vaadin.sebastian.indeterminatecheckbox.IndeterminateCheckBox; -import com.vaadin.ui.TreeTable; -import java.util.Objects; -import java.util.logging.Level; -import java.util.logging.Logger; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public final class TreeTableCheckBox extends IndeterminateCheckBox { - - private final TreeTable tt; - private final static Logger LOG - = Logger.getLogger(TreeTableCheckBox.class.getSimpleName()); - private final Object objectId; - - public TreeTableCheckBox(TreeTable tt, Object objectId) { - this.tt = tt; - this.objectId = objectId; - initialize(); - } - - public TreeTableCheckBox(TreeTable tt, String caption, Object objectId) { - super(caption); - this.tt = tt; - this.objectId = objectId; - initialize(); - } - - public TreeTableCheckBox(TreeTable tt, String caption, - boolean initialState, Object objectId) { - super(caption, initialState); - this.tt = tt; - this.objectId = objectId; - initialize(); - } - - private void initialize() { - setUserCanToggleIndeterminate(false); - } - - @Override - protected void setInternalValue(Boolean value) { - if (tt != null - && value != null - && !Objects.equals(value, getState().value)) { - if (tt.hasChildren(getObjectId()) - && getState().value != null) { - //Switching from false to true. Select all children - tt.getChildren(getObjectId()).forEach((o) -> { - Item item = tt.getItem(o); - Object val = item.getItemProperty("Name").getValue(); - if (val instanceof TreeTableCheckBox) { - TreeTableCheckBox ttcb = (TreeTableCheckBox) val; - ttcb.setValue(value); - } - }); - } - Object parentId = tt.getParent(getObjectId()); - if (!value && parentId != null) { - //Switching from true to false. Mark parent as undeterminated - TreeTableCheckBox parent - = ((TreeTableCheckBox) tt.getItem(parentId) - .getItemProperty("Name").getValue()); - if (parent.getValue() != null && parent.getValue()) { - LOG.log(Level.INFO, "Setting {0} to undetermined.", - parentId); - parent.setValue(null); - } else { - LOG.info("Parent not selected!"); - } - } - } - super.setInternalValue(value); - } - - /** - * @return the objectId - */ - public Object getObjectId() { - return objectId; - } -} +package net.sourceforge.javydreamercsw.validation.manager.web.component; + +import com.vaadin.data.Item; +import com.vaadin.sebastian.indeterminatecheckbox.IndeterminateCheckBox; +import com.vaadin.ui.TreeTable; +import java.util.Objects; +import java.util.logging.Level; +import java.util.logging.Logger; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public final class TreeTableCheckBox extends IndeterminateCheckBox { + + private final TreeTable tt; + private final static Logger LOG + = Logger.getLogger(TreeTableCheckBox.class.getSimpleName()); + private final Object objectId; + + public TreeTableCheckBox(TreeTable tt, Object objectId) { + this.tt = tt; + this.objectId = objectId; + initialize(); + } + + public TreeTableCheckBox(TreeTable tt, String caption, Object objectId) { + super(caption); + this.tt = tt; + this.objectId = objectId; + initialize(); + } + + public TreeTableCheckBox(TreeTable tt, String caption, + boolean initialState, Object objectId) { + super(caption, initialState); + this.tt = tt; + this.objectId = objectId; + initialize(); + } + + private void initialize() { + setUserCanToggleIndeterminate(false); + } + + @Override + protected void setInternalValue(Boolean value) { + if (tt != null + && value != null + && !Objects.equals(value, getState().value)) { + if (tt.hasChildren(getObjectId()) + && getState().value != null) { + //Switching from false to true. Select all children + tt.getChildren(getObjectId()).forEach((o) -> { + Item item = tt.getItem(o); + Object val = item.getItemProperty("Name").getValue(); + if (val instanceof TreeTableCheckBox) { + TreeTableCheckBox ttcb = (TreeTableCheckBox) val; + ttcb.setValue(value); + } + }); + } + Object parentId = tt.getParent(getObjectId()); + if (!value && parentId != null) { + //Switching from true to false. Mark parent as undeterminated + TreeTableCheckBox parent + = ((TreeTableCheckBox) tt.getItem(parentId) + .getItemProperty("Name").getValue()); + if (parent.getValue() != null && parent.getValue()) { + LOG.log(Level.INFO, "Setting {0} to undetermined.", + parentId); + parent.setValue(null); + } else { + LOG.info("Parent not selected!"); + } + } + } + super.setInternalValue(value); + } + + /** + * @return the objectId + */ + public Object getObjectId() { + return objectId; + } +} diff --git a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/UserComponent.java b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/UserComponent.java new file mode 100644 index 00000000..6934e8df --- /dev/null +++ b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/UserComponent.java @@ -0,0 +1,302 @@ +/* + * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package net.sourceforge.javydreamercsw.validation.manager.web.component; + +import com.vaadin.data.fieldgroup.BeanFieldGroup; +import com.vaadin.data.util.BeanItemContainer; +import com.vaadin.event.FieldEvents; +import com.vaadin.event.FieldEvents.TextChangeListener; +import com.vaadin.icons.VaadinIcons; +import com.vaadin.ui.Alignment; +import com.vaadin.ui.Button; +import com.vaadin.ui.ComboBox; +import com.vaadin.ui.Field; +import com.vaadin.ui.FormLayout; +import com.vaadin.ui.HorizontalLayout; +import com.vaadin.ui.Label; +import com.vaadin.ui.Notification; +import com.vaadin.ui.Panel; +import com.vaadin.ui.PasswordField; +import com.vaadin.ui.Table; +import com.vaadin.ui.TextField; +import com.vaadin.ui.TwinColSelect; +import com.vaadin.ui.UI; +import com.vaadin.ui.VerticalLayout; +import com.vaadin.ui.themes.ValoTheme; +import com.validation.manager.core.DataBaseManager; +import com.validation.manager.core.VMException; +import com.validation.manager.core.VMUI; +import com.validation.manager.core.api.internationalization.InternationalizationProvider; +import com.validation.manager.core.db.Role; +import com.validation.manager.core.db.VmUser; +import com.validation.manager.core.db.controller.RoleJpaController; +import com.validation.manager.core.db.controller.UserStatusJpaController; +import com.validation.manager.core.server.core.VMUserServer; +import com.validation.manager.core.tool.MD5; +import de.steinwedel.messagebox.ButtonOption; +import de.steinwedel.messagebox.MessageBox; +import java.util.ArrayList; +import java.util.Collections; +import java.util.List; +import java.util.Locale; +import java.util.Set; +import java.util.logging.Level; +import java.util.logging.Logger; +import net.sourceforge.javydreamercsw.validation.manager.web.ValidationManagerUI; +import org.openide.util.Exceptions; +import org.openide.util.Lookup; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class UserComponent extends Panel { + + private final VmUser user; + private static final Logger LOG + = Logger.getLogger(UserComponent.class.getSimpleName()); + private static final InternationalizationProvider TRANSLATOR + = Lookup.getDefault().lookup(InternationalizationProvider.class); + private boolean edit = false; + + public UserComponent(VmUser user, boolean edit) { + this.user = user; + this.edit = edit; + init(); + } + + public UserComponent(VmUser user, String caption, boolean edit) { + super(caption); + this.user = user; + this.edit = edit; + init(); + } + + private void init() { + FormLayout layout = new FormLayout(); + setContent(layout); + addStyleName(ValoTheme.FORMLAYOUT_LIGHT); + BeanFieldGroup binder = new BeanFieldGroup(user.getClass()); + binder.setItemDataSource(user); + Field fn = binder.buildAndBind(TRANSLATOR. + translate("general.first.name"), + "firstName", TextField.class); + layout.addComponent(fn); + Field ln = binder.buildAndBind(TRANSLATOR. + translate("general.last.name"), + "lastName", TextField.class); + layout.addComponent(ln); + Field username = binder.buildAndBind(TRANSLATOR. + translate("general.username"), + "username", TextField.class); + layout.addComponent(username); + PasswordField pw = (PasswordField) binder.buildAndBind( + TRANSLATOR. + translate("general.password"), + "password", PasswordField.class); + PasswordChangeListener listener = new PasswordChangeListener(); + pw.addTextChangeListener(listener); + pw.setConverter(new UserPasswordConverter()); + layout.addComponent(pw); + Field email = binder.buildAndBind(TRANSLATOR. + translate("general.email"), + "email", TextField.class); + layout.addComponent(email); + ComboBox locale = new ComboBox(TRANSLATOR. + translate("general.locale")); + locale.setTextInputAllowed(false); + ValidationManagerUI.getAvailableLocales().forEach(l -> { + locale.addItem(l.toString()); + }); + if (user.getLocale() != null) { + locale.setValue(user.getLocale()); + } + binder.bind(locale, "locale"); + layout.addComponent(locale); + //Status + ComboBox status = new ComboBox(TRANSLATOR. + translate("general.status")); + new UserStatusJpaController(DataBaseManager.getEntityManagerFactory()) + .findUserStatusEntities().forEach(us -> { + status.addItem(us); + status.setItemCaption(us, + TRANSLATOR.translate(us.getStatus())); + }); + binder.bind(status, "userStatusId"); + status.setTextInputAllowed(false); + layout.addComponent(status); + //Roles + if (edit && ((VMUI) UI.getCurrent()).checkRight("system.configuration")) { + List list = new RoleJpaController(DataBaseManager + .getEntityManagerFactory()) + .findRoleEntities(); + Collections.sort(list, (Role r1, Role r2) + -> TRANSLATOR.translate(r1.getRoleName()) + .compareTo(TRANSLATOR + .translate(r2.getRoleName()))); + BeanItemContainer roleContainer + = new BeanItemContainer<>(Role.class, list); + TwinColSelect roles + = new TwinColSelect(TRANSLATOR.translate("general.role")); + roles.setContainerDataSource(roleContainer); + roles.setRows(5); + roles.setLeftColumnCaption(TRANSLATOR.translate("available.roles")); + roles.setRightColumnCaption(TRANSLATOR.translate("current.roles")); + list.forEach(r -> { + roles.setItemCaption(r, TRANSLATOR.translate(r.getDescription())); + }); + if (user.getRoleList() != null) { + user.getRoleList().forEach(r -> { + roles.select(r); + }); + } + roles.addValueChangeListener(event -> { + Set selected + = (Set) event.getProperty().getValue(); + if (user.getRoleList() == null) { + user.setRoleList(new ArrayList<>()); + } + user.getRoleList().clear(); + selected.forEach(r -> { + user.getRoleList().add(r); + }); + }); + layout.addComponent(roles); + } else { + if (!user.getRoleList().isEmpty()) { + Table roles = new Table(TRANSLATOR.translate("general.role")); + user.getRoleList().forEach(role -> { + roles.addItem(role); + roles.setItemCaption(role, + TRANSLATOR.translate(role.getRoleName())); + roles.setItemIcon(role, VaadinIcons.USER_STAR); + }); + layout.addComponent(roles); + } + } + Button update = new Button(user.getId() == null + ? TRANSLATOR. + translate("general.create") + : TRANSLATOR. + translate("general.update")); + update.addClickListener((Button.ClickEvent event) -> { + try { + VMUserServer us; + String password = (String) pw.getValue(); + if (user.getId() == null) { + us = new VMUserServer((String) username.getValue(), + password, + (String) fn.getValue(), + (String) ln.getValue(), + (String) email.getValue()); + } else { + us = new VMUserServer(user); + us.setFirstName((String) fn.getValue()); + us.setLastName((String) ln.getValue()); + us.setEmail((String) email.getValue()); + us.setUsername((String) username.getValue()); + } + us.setLocale((String) locale.getValue()); + if (listener.isChanged() + && !password.equals(user.getPassword())) { + //Different password. Prompt for confirmation + MessageBox mb = MessageBox.create(); + VerticalLayout vl = new VerticalLayout(); + Label l = new Label(TRANSLATOR. + translate("password.confirm.pw.message")); + vl.addComponent(l); + PasswordField np = new PasswordField(Lookup.getDefault() + .lookup(InternationalizationProvider.class) + .translate("general.password")); + vl.addComponent(np); + mb.asModal(true) + .withCaption(Lookup.getDefault() + .lookup(InternationalizationProvider.class). + translate("password.confirm.pw")) + .withMessage(vl) + .withButtonAlignment(Alignment.MIDDLE_CENTER) + .withOkButton(() -> { + try { + if (password.equals(MD5.encrypt(np.getValue()))) { + us.setHashPassword(true); + us.setPassword(np.getValue()); + us.write2DB(); + Notification.show(TRANSLATOR. + translate("audit.user.account.password.change"), + Notification.Type.ASSISTIVE_NOTIFICATION); + ((VMUI) UI.getCurrent()).updateScreen(); + } else { + Notification.show(TRANSLATOR. + translate("password.does.not.match"), + Notification.Type.WARNING_MESSAGE); + } + mb.close(); + } catch (VMException ex) { + Exceptions.printStackTrace(ex); + } + }, ButtonOption.focus(), + ButtonOption.closeOnClick(false), + ButtonOption.icon(VaadinIcons.CHECK)) + .withCancelButton( + ButtonOption.icon(VaadinIcons.CLOSE) + ).getWindow().setIcon(ValidationManagerUI.SMALL_APP_ICON); + mb.open(); + } else { + us.write2DB(); + } + ((VMUI) UI.getCurrent()).getUser().update(); + ((VMUI) UI.getCurrent()).setLocale(new Locale(us.getLocale())); + ((VMUI) UI.getCurrent()).updateScreen(); + } catch (Exception ex) { + LOG.log(Level.SEVERE, null, ex); + Notification.show(TRANSLATOR. + translate("general.error.record.update"), + ex.getLocalizedMessage(), + Notification.Type.ERROR_MESSAGE); + } + }); + Button cancel = new Button(Lookup.getDefault() + .lookup(InternationalizationProvider.class). + translate("general.cancel")); + cancel.addClickListener((Button.ClickEvent event) -> { + binder.discard(); + ((VMUI) UI.getCurrent()).updateScreen(); + }); + binder.setReadOnly(!edit); + binder.setBuffered(true); + HorizontalLayout hl = new HorizontalLayout(); + hl.addComponent(update); + hl.addComponent(cancel); + layout.addComponent(hl); + } + + private class PasswordChangeListener implements TextChangeListener { + + private boolean changed = false; + + @Override + public void textChange(FieldEvents.TextChangeEvent event) { + changed = true; + } + + /** + * @return the changed + */ + public boolean isChanged() { + return changed; + } + } +} diff --git a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/profile/UserPasswordConverter.java b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/UserPasswordConverter.java similarity index 83% rename from Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/profile/UserPasswordConverter.java rename to Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/UserPasswordConverter.java index 5e120135..724716c3 100644 --- a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/profile/UserPasswordConverter.java +++ b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/UserPasswordConverter.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,48 +13,46 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package net.sourceforge.javydreamercsw.validation.manager.web.profile; - -import com.vaadin.data.util.converter.Converter; -import com.validation.manager.core.tool.MD5; -import java.util.Locale; -import org.openide.util.Exceptions; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class UserPasswordConverter implements Converter { - - private String pw; - - @Override - public String convertToModel(String value, - Class targetType, Locale locale) - throws ConversionException { - pw = value; - return pw; - } - - @Override - public String convertToPresentation(String value, - Class targetType, Locale locale) - throws ConversionException { - try { - return MD5.encrypt(value); - } catch (Exception ex) { - Exceptions.printStackTrace(ex); - } - return ""; - } - - @Override - public Class getModelType() { - return String.class; - } - - @Override - public Class getPresentationType() { - return String.class; - } -} +package net.sourceforge.javydreamercsw.validation.manager.web.component; + +import com.vaadin.data.util.converter.Converter; +import com.validation.manager.core.VMException; +import com.validation.manager.core.tool.MD5; +import java.util.Locale; +import org.openide.util.Exceptions; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class UserPasswordConverter implements Converter { + + @Override + public String convertToModel(String value, + Class targetType, Locale locale) + throws ConversionException { + return value; + } + + @Override + public String convertToPresentation(String value, + Class targetType, Locale locale) + throws ConversionException { + try { + return value == null ? "" : MD5.encrypt(value); + } catch (VMException ex) { + Exceptions.printStackTrace(ex); + } + return ""; + } + + @Override + public Class getModelType() { + return String.class; + } + + @Override + public Class getPresentationType() { + return String.class; + } +} diff --git a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/UserStatusConverter.java b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/UserStatusConverter.java new file mode 100644 index 00000000..dbd4791f --- /dev/null +++ b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/UserStatusConverter.java @@ -0,0 +1,67 @@ +/* + * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package net.sourceforge.javydreamercsw.validation.manager.web.component; + +import com.vaadin.data.util.converter.Converter; +import com.validation.manager.core.DataBaseManager; +import com.validation.manager.core.api.internationalization.InternationalizationProvider; +import com.validation.manager.core.db.UserStatus; +import com.validation.manager.core.db.controller.UserStatusJpaController; +import java.util.Locale; +import org.openide.util.Lookup; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class UserStatusConverter implements Converter { + + private static final InternationalizationProvider TRANSLATOR + = Lookup.getDefault().lookup(InternationalizationProvider.class); + + @Override + public UserStatus convertToModel(String value, + Class targetType, + Locale locale) throws Converter.ConversionException { + UserStatus status = null; + for (UserStatus us + : new UserStatusJpaController(DataBaseManager + .getEntityManagerFactory()).findUserStatusEntities()) { + if (TRANSLATOR.translate(us.getStatus()).equals(value)) { + status = us; + break; + } + } + return status; + } + + @Override + public String convertToPresentation(UserStatus value, + Class targetType, + Locale locale) throws Converter.ConversionException { + return value == null ? "" : TRANSLATOR.translate(value.getStatus()); + } + + @Override + public Class getModelType() { + return UserStatus.class; + } + + @Override + public Class getPresentationType() { + return String.class; + } +} diff --git a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/UserToStringConverter.java b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/UserToStringConverter.java similarity index 92% rename from Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/UserToStringConverter.java rename to Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/UserToStringConverter.java index b6ddeed3..7dbf2bc5 100644 --- a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/UserToStringConverter.java +++ b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/component/UserToStringConverter.java @@ -13,41 +13,41 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package net.sourceforge.javydreamercsw.validation.manager.web; - -import com.vaadin.data.util.converter.Converter; -import com.validation.manager.core.db.VmUser; -import com.validation.manager.core.server.core.VMUserServer; -import java.util.Locale; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class UserToStringConverter implements Converter { - - private VmUser user; - - @Override - public Class getModelType() { - return VmUser.class; - } - - @Override - public Class getPresentationType() { - return String.class; - } - - @Override - public VmUser convertToModel(String value, - Class targetType, Locale locale) throws ConversionException { - return user; - } - - @Override - public String convertToPresentation(VmUser value, - Class targetType, Locale locale) throws ConversionException { - user = value; - return new VMUserServer(value).toString(); - } -} +package net.sourceforge.javydreamercsw.validation.manager.web.component; + +import com.vaadin.data.util.converter.Converter; +import com.validation.manager.core.db.VmUser; +import com.validation.manager.core.server.core.VMUserServer; +import java.util.Locale; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class UserToStringConverter implements Converter { + + private VmUser user; + + @Override + public Class getModelType() { + return VmUser.class; + } + + @Override + public Class getPresentationType() { + return String.class; + } + + @Override + public VmUser convertToModel(String value, + Class targetType, Locale locale) throws ConversionException { + return user; + } + + @Override + public String convertToPresentation(VmUser value, + Class targetType, Locale locale) throws ConversionException { + user = value; + return new VMUserServer(value).toString(); + } +} diff --git a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/provider/DemoProvider.java b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/demo/DemoProvider.java similarity index 79% rename from Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/provider/DemoProvider.java rename to Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/demo/DemoProvider.java index 02d70eaa..49a3835e 100644 --- a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/provider/DemoProvider.java +++ b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/demo/DemoProvider.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,91 +13,92 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package net.sourceforge.javydreamercsw.validation.manager.web.provider; - -import com.vaadin.shared.ui.label.ContentMode; -import com.vaadin.ui.Component; -import com.vaadin.ui.Label; -import com.vaadin.ui.VerticalLayout; -import com.validation.manager.core.DataBaseManager; -import com.validation.manager.core.IMainContentProvider; -import com.validation.manager.core.api.internationalization.InternationalizationProvider; -import com.validation.manager.core.db.controller.VmUserJpaController; -import com.validation.manager.core.tool.MD5; -import java.util.logging.Level; -import java.util.logging.Logger; -import org.openide.util.Lookup; -import org.openide.util.lookup.ServiceProvider; - -@ServiceProvider(service = IMainContentProvider.class) -public class DemoProvider extends AbstractProvider { - - private static final Logger LOG - = Logger.getLogger(DemoProvider.class.getSimpleName()); - private VerticalLayout layout; - - @Override - public Component getContent() { - if (layout == null) { - layout = new VerticalLayout(); - update(); - } - return layout; - } - - @Override - public void update() { - layout.removeAllComponents(); - VmUserJpaController controller - = new VmUserJpaController(DataBaseManager - .getEntityManagerFactory()); - layout.addComponent(new Label("

demo.tab.title

", - ContentMode.HTML)); - Label l = new Label(); - l.setId("demo.tab.message"); - layout.addComponent(l); - StringBuilder sb = new StringBuilder("
    "); - controller.findVmUserEntities().stream().filter((u) - -> (u.getId() < 1000)).forEachOrdered((u) -> { - try { - //Default accounts - if (u.getPassword() != null - && u.getPassword().equals(MD5 - .encrypt(u.getUsername()))) { - sb.append("
  • ") - .append("general.username") - .append(": ") - .append(u.getUsername()).append(", ") - .append("general.password") - .append(": ") - .append(u.getUsername()) - .append(" ") - .append("general.role") - .append(": ") - .append(Lookup.getDefault() - .lookup(InternationalizationProvider.class) - .translate(u.getRoleList().get(0) - .getDescription())) - .append("
  • "); - } - } catch (Exception ex) { - LOG.log(Level.SEVERE, null, ex); - } - }); - sb.append("
"); - layout.addComponent(new Label(sb.toString(), - ContentMode.HTML)); - layout.setId(getComponentCaption()); - super.update(); - } - - @Override - public String getComponentCaption() { - return "demo.tab.name"; - } - - @Override - public boolean shouldDisplay() { - return DataBaseManager.isDemo(); - } -} +package net.sourceforge.javydreamercsw.validation.manager.web.demo; + +import com.vaadin.shared.ui.label.ContentMode; +import com.vaadin.ui.Component; +import com.vaadin.ui.Label; +import com.vaadin.ui.VerticalLayout; +import com.validation.manager.core.DataBaseManager; +import com.validation.manager.core.IMainContentProvider; +import com.validation.manager.core.VMException; +import com.validation.manager.core.db.controller.VmUserJpaController; +import com.validation.manager.core.tool.MD5; +import java.util.logging.Level; +import java.util.logging.Logger; +import net.sourceforge.javydreamercsw.validation.manager.web.provider.AbstractProvider; +import org.openide.util.lookup.ServiceProvider; + +@ServiceProvider(service = IMainContentProvider.class) +public class DemoProvider extends AbstractProvider { + + private static final Logger LOG + = Logger.getLogger(DemoProvider.class.getSimpleName()); + private VerticalLayout layout; + + @Override + public Component getContent() { + if (layout == null) { + layout = new VerticalLayout(); + update(); + } + return layout; + } + + @Override + public void update() { + layout.removeAllComponents(); + VmUserJpaController controller + = new VmUserJpaController(DataBaseManager + .getEntityManagerFactory()); + layout.addComponent(new Label("

" + + TRANSLATOR.translate("demo.tab.title") + "

", + ContentMode.HTML)); + Label l = new Label(); + l.setId("demo.tab.message"); + layout.addComponent(l); + StringBuilder sb = new StringBuilder("
    "); + controller.findVmUserEntities().stream().filter((u) + -> (u.getId() < 1000)).forEachOrdered((u) -> { + try { + //Default accounts + if (u.getPassword() != null + && u.getPassword().equals(MD5 + .encrypt(u.getUsername()))) { + sb.append("
  • ") + .append(TRANSLATOR.translate("general.username")) + .append(": ") + .append(u.getUsername()) + .append(", ") + .append(TRANSLATOR.translate("general.password")) + .append(": ") + .append(u.getUsername()) + .append(" ") + .append(TRANSLATOR.translate("general.role")) + .append(": ") + .append(TRANSLATOR + .translate(u.getRoleList().get(0) + .getDescription())) + .append("
  • "); + } + } catch (VMException ex) { + LOG.log(Level.SEVERE, null, ex); + } + }); + sb.append("
"); + layout.addComponent(new Label(sb.toString(), + ContentMode.HTML)); + layout.setId(getComponentCaption()); + super.update(); + } + + @Override + public String getComponentCaption() { + return "demo.tab.name"; + } + + @Override + public boolean shouldDisplay() { + return DataBaseManager.isDemo(); + } +} diff --git a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/execution/ExecutionWizardStep.java b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/execution/ExecutionWizardStep.java index 7f672082..aa8fa979 100644 --- a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/execution/ExecutionWizardStep.java +++ b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/execution/ExecutionWizardStep.java @@ -13,748 +13,748 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package net.sourceforge.javydreamercsw.validation.manager.web.execution; - -import com.vaadin.data.fieldgroup.BeanFieldGroup; -import com.vaadin.event.FieldEvents.TextChangeEvent; -import com.vaadin.icons.VaadinIcons; -import com.vaadin.server.Resource; -import com.vaadin.server.Sizeable; -import com.vaadin.shared.ui.datefield.Resolution; -import com.vaadin.ui.Alignment; -import com.vaadin.ui.Button; -import com.vaadin.ui.ComboBox; -import com.vaadin.ui.Component; -import com.vaadin.ui.DateField; -import com.vaadin.ui.Field; -import com.vaadin.ui.FormLayout; -import com.vaadin.ui.HorizontalLayout; -import com.vaadin.ui.Label; -import com.vaadin.ui.Notification; -import com.vaadin.ui.Panel; -import com.vaadin.ui.TextArea; -import com.vaadin.ui.TextField; -import com.vaadin.ui.VerticalLayout; -import com.vaadin.ui.Window; -import com.vaadin.ui.themes.ValoTheme; -import com.validation.manager.core.DataBaseManager; -import com.validation.manager.core.api.internationalization.InternationalizationProvider; -import com.validation.manager.core.db.AttachmentType; -import com.validation.manager.core.db.ExecutionResult; -import com.validation.manager.core.db.ExecutionStep; -import com.validation.manager.core.db.ExecutionStepHasAttachment; -import com.validation.manager.core.db.ExecutionStepHasIssue; -import com.validation.manager.core.db.ReviewResult; -import com.validation.manager.core.db.controller.ExecutionResultJpaController; -import com.validation.manager.core.db.controller.IssueTypeJpaController; -import com.validation.manager.core.db.controller.ReviewResultJpaController; -import com.validation.manager.core.server.core.AttachmentServer; -import com.validation.manager.core.server.core.AttachmentTypeServer; -import com.validation.manager.core.server.core.ExecutionResultServer; -import com.validation.manager.core.server.core.ExecutionStepServer; -import com.validation.manager.core.server.core.IssueServer; -import com.validation.manager.core.server.core.IssueTypeServer; -import com.validation.manager.core.server.core.ReviewResultServer; -import com.validation.manager.core.server.core.VMSettingServer; -import de.steinwedel.messagebox.ButtonOption; -import de.steinwedel.messagebox.ButtonType; -import de.steinwedel.messagebox.MessageBox; -import java.io.File; -import java.io.IOException; -import java.util.ArrayList; -import java.util.Date; -import java.util.Objects; -import java.util.logging.Level; -import java.util.logging.Logger; -import net.sourceforge.javydreamercsw.validation.manager.web.ByteToStringConverter; -import net.sourceforge.javydreamercsw.validation.manager.web.VMWindow; -import net.sourceforge.javydreamercsw.validation.manager.web.ValidationManagerUI; -import net.sourceforge.javydreamercsw.validation.manager.web.file.IFileDisplay; -import net.sourceforge.javydreamercsw.validation.manager.web.file.PDFDisplay; -import org.jodconverter.OfficeDocumentConverter; -import org.jodconverter.office.DefaultOfficeManagerBuilder; -import org.jodconverter.office.OfficeException; -import org.jodconverter.office.OfficeManager; -import org.openide.util.Lookup; -import org.vaadin.easyuploads.MultiFileUpload; -import org.vaadin.teemu.wizards.Wizard; -import org.vaadin.teemu.wizards.WizardStep; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class ExecutionWizardStep implements WizardStep { - - private final Wizard w; - private final ExecutionStepServer step; - private final ComboBox result = new ComboBox("general.result"); - private final ComboBox review = new ComboBox("quality.review"); - private final ComboBox issueType = new ComboBox("issue.type"); - private Button attach; - private Button bug; - private Button comment; - private DateField start; - private DateField end; - private DateField reviewDate; - private static final Logger LOG - = Logger.getLogger(ExecutionWizardStep.class.getSimpleName()); - private boolean reviewer = false; - - public ExecutionWizardStep(Wizard w, ExecutionStep step, - boolean reviewer) { - this.reviewer = reviewer; - this.w = w; - this.step = new ExecutionStepServer(step); - issueType.setSizeFull(); - issueType.setReadOnly(false); - issueType.setRequired(true); - issueType.setRequiredError("missing.type"); - IssueTypeJpaController it - = new IssueTypeJpaController(DataBaseManager - .getEntityManagerFactory()); - it.findIssueTypeEntities().forEach(type -> { - String item = Lookup.getDefault().lookup(InternationalizationProvider.class) - .translate(type.getTypeName()); - issueType.addItem(type.getTypeName()); - issueType.setItemCaption(type.getTypeName(), item); - switch (type.getId()) { - case 1: - issueType.setItemIcon(type.getTypeName(), VaadinIcons.BUG); - break; - case 2: - issueType.setItemIcon(type.getTypeName(), VaadinIcons.EYE); - break; - case 3: - issueType.setItemIcon(type.getTypeName(), VaadinIcons.QUESTION); - break; - } - }); - result.setReadOnly(false); - result.setRequired(true); - result.setRequiredError("missing.result"); - result.setTextInputAllowed(false); - review.setReadOnly(false); - review.setRequired(true); - review.setRequiredError("missing.reviiew.result"); - review.setTextInputAllowed(false); - ReviewResultJpaController c2 - = new ReviewResultJpaController(DataBaseManager - .getEntityManagerFactory()); - c2.findReviewResultEntities().forEach(r -> { - String item = Lookup.getDefault().lookup(InternationalizationProvider.class) - .translate(r.getReviewName()); - review.addItem(r.getReviewName()); - review.setItemCaption(r.getReviewName(), item); - Resource icon; - switch (r.getId()) { - case 1: - icon = VaadinIcons.CHECK; - break; - case 2: - icon = VaadinIcons.CLOSE; - break; - default: - icon = VaadinIcons.CLOCK; - break; - } - review.setItemIcon(r.getReviewName(), icon); - }); - ExecutionResultJpaController c - = new ExecutionResultJpaController(DataBaseManager - .getEntityManagerFactory()); - c.findExecutionResultEntities().forEach(r -> { - String item = Lookup.getDefault().lookup(InternationalizationProvider.class) - .translate(r.getResultName()); - result.addItem(r.getResultName()); - result.setItemCaption(r.getResultName(), item); - Resource icon; - switch (r.getId()) { - case 1: - icon = VaadinIcons.CHECK; - break; - case 2: - icon = VaadinIcons.CLOSE; - break; - case 3: - icon = VaadinIcons.PAUSE; - break; - default: - icon = VaadinIcons.CLOCK; - break; - } - result.setItemIcon(r.getResultName(), icon); - }); - } - - @Override - public String getCaption() { - return getStep().getStep().getTestCase().getName() + " Step:" - + getStep().getStep().getStepSequence(); - } - - @Override - public Component getContent() { - getStep().update(); - Panel form = new Panel("step.detail"); - if (getStep().getExecutionStart() == null) { - //Set the start date. - getStep().setExecutionStart(new Date()); - } - FormLayout layout = new FormLayout(); - form.setContent(layout); - form.addStyleName(ValoTheme.FORMLAYOUT_LIGHT); - BeanFieldGroup binder = new BeanFieldGroup(getStep().getStep().getClass()); - binder.setItemDataSource(getStep().getStep()); - TextArea text = new TextArea("general.text"); - text.setConverter(new ByteToStringConverter()); - binder.bind(text, "text"); - text.setSizeFull(); - layout.addComponent(text); - Field notes = binder.buildAndBind("general.notes", "notes", - TextArea.class); - notes.setSizeFull(); - layout.addComponent(notes); - if (getStep().getExecutionStart() != null) { - start = new DateField("start.date"); - start.setResolution(Resolution.SECOND); - start.setDateFormat(VMSettingServer.getSetting("date.format") - .getStringVal()); - start.setValue(getStep().getExecutionStart()); - start.setReadOnly(true); - layout.addComponent(start); - } - if (getStep().getExecutionEnd() != null) { - end = new DateField(Lookup.getDefault().lookup(InternationalizationProvider.class) - .translate("end.date")); - end.setDateFormat(VMSettingServer.getSetting("date.format") - .getStringVal()); - end.setResolution(Resolution.SECOND); - end.setValue(getStep().getExecutionEnd()); - end.setReadOnly(true); - layout.addComponent(end); - } - binder.setReadOnly(true); - //Space to record result - if (getStep().getResultId() != null) { - result.setValue(getStep().getResultId().getResultName()); - } - layout.addComponent(result); - if (reviewer) {//Space to record review - if (getStep().getReviewResultId() != null) { - review.setValue(getStep().getReviewResultId().getReviewName()); - } - layout.addComponent(review); - } - //Add Reviewer name - if (getStep().getReviewer() != null) { - TextField reviewerField = new TextField(Lookup.getDefault() - .lookup(InternationalizationProvider.class) - .translate("general.reviewer")); - reviewerField.setValue(getStep().getReviewer().getFirstName() + " " - + getStep().getReviewer().getLastName()); - reviewerField.setReadOnly(true); - layout.addComponent(reviewerField); - } - if (getStep().getReviewDate() != null) { - reviewDate = new DateField(Lookup.getDefault() - .lookup(InternationalizationProvider.class) - .translate("review.date")); - reviewDate.setDateFormat(VMSettingServer.getSetting("date.format") - .getStringVal()); - reviewDate.setResolution(Resolution.SECOND); - reviewDate.setValue(getStep().getReviewDate()); - reviewDate.setReadOnly(true); - layout.addComponent(reviewDate); - } - if (VMSettingServer.getSetting("show.expected.result").getBoolVal()) { - TextArea expectedResult = new TextArea("expected.result"); - expectedResult.setConverter(new ByteToStringConverter()); - binder.bind(expectedResult, "expectedResult"); - expectedResult.setSizeFull(); - layout.addComponent(expectedResult); - } - //Add the Attachments - HorizontalLayout attachments = new HorizontalLayout(); - attachments.setCaption("general.attachment"); - HorizontalLayout comments = new HorizontalLayout(); - comments.setCaption("general.comments"); - HorizontalLayout issues = new HorizontalLayout(); - issues.setCaption("general.issue"); - int commentCounter = 0; - int issueCounter = 0; - for (ExecutionStepHasIssue ei : getStep().getExecutionStepHasIssueList()) { - issueCounter++; - Button a = new Button("Issue #" + issueCounter); - a.setIcon(VaadinIcons.BUG); - a.addClickListener((Button.ClickEvent event) -> { - displayIssue(new IssueServer(ei.getIssue())); - }); - a.setEnabled(!step.getLocked()); - issues.addComponent(a); - } - for (ExecutionStepHasAttachment attachment - : getStep().getExecutionStepHasAttachmentList()) { - switch (attachment.getAttachment().getAttachmentType().getType()) { - case "comment": { - //Comments go in a different section - commentCounter++; - Button a = new Button("Comment #" + commentCounter); - a.setIcon(VaadinIcons.CLIPBOARD_TEXT); - a.addClickListener((Button.ClickEvent event) -> { - if (!step.getLocked()) { - //Prompt if user wants this removed - MessageBox mb = getDeletionPrompt(attachment); - mb.open(); - } else { - displayComment(new AttachmentServer(attachment - .getAttachment().getAttachmentPK())); - } - }); - a.setEnabled(!step.getLocked()); - comments.addComponent(a); - break; - } - default: { - Button a = new Button(attachment.getAttachment().getFileName()); - a.setEnabled(!step.getLocked()); - a.setIcon(VaadinIcons.PAPERCLIP); - a.addClickListener((Button.ClickEvent event) -> { - if (!step.getLocked()) { - //Prompt if user wants this removed - MessageBox mb = getDeletionPrompt(attachment); - mb.open(); - } else { - displayAttachment( - new AttachmentServer(attachment.getAttachment() - .getAttachmentPK())); - } - }); - attachments.addComponent(a); - break; - } - } - } - if (attachments.getComponentCount() > 0) { - layout.addComponent(attachments); - } - if (comments.getComponentCount() > 0) { - layout.addComponent(comments); - } - if (issues.getComponentCount() > 0) { - layout.addComponent(issues); - } - //Add the menu - HorizontalLayout hl = new HorizontalLayout(); - attach = new Button("add.attachment"); - attach.setIcon(VaadinIcons.PAPERCLIP); - attach.addClickListener((Button.ClickEvent event) -> { - //Show dialog to upload file. - Window dialog = new VMWindow("attach.file"); - VerticalLayout vl = new VerticalLayout(); - MultiFileUpload multiFileUpload = new MultiFileUpload() { - @Override - protected void handleFile(File file, String fileName, - String mimeType, long length) { - try { - LOG.log(Level.FINE, "Received file {1} at: {0}", - new Object[]{file.getAbsolutePath(), fileName}); - //Process the file - //Create the attachment - AttachmentServer a = new AttachmentServer(); - a.addFile(file, fileName); - //Overwrite the default file name set in addFile. It'll be a temporary file name - a.setFileName(fileName); - a.write2DB(); - //Now add it to this Execution Step - if (getStep().getExecutionStepHasAttachmentList() == null) { - getStep().setExecutionStepHasAttachmentList(new ArrayList<>()); - } - getStep().addAttachment(a); - getStep().write2DB(); - w.updateCurrentStep(); - } catch (Exception ex) { - LOG.log(Level.SEVERE, "Error creating attachment!", ex); - } - } - }; - multiFileUpload.setCaption("select.files.attach"); - vl.addComponent(multiFileUpload); - dialog.setContent(vl); - dialog.setHeight(25, Sizeable.Unit.PERCENTAGE); - dialog.setWidth(25, Sizeable.Unit.PERCENTAGE); - dialog.center(); - ValidationManagerUI.getInstance().addWindow(dialog); - }); - hl.addComponent(attach); - bug = new Button("create.issue"); - bug.setIcon(VaadinIcons.BUG); - bug.addClickListener((Button.ClickEvent event) -> { - displayIssue(new IssueServer()); - }); - hl.addComponent(bug); - comment = new Button("add.comment"); - comment.setIcon(VaadinIcons.CLIPBOARD_TEXT); - comment.addClickListener((Button.ClickEvent event) -> { - AttachmentServer as = new AttachmentServer(); - //Get comment type - AttachmentType type = AttachmentTypeServer - .getTypeForExtension("comment"); - as.setAttachmentType(type); - displayComment(as); - }); - hl.addComponent(comment); - step.update(); - attach.setEnabled(!step.getLocked()); - bug.setEnabled(!step.getLocked()); - comment.setEnabled(!step.getLocked()); - result.setEnabled(!step.getLocked()); - layout.addComponent(hl); - return layout; - } - - private void displayIssue(IssueServer is) { - Panel form = new Panel("general.issue"); - FormLayout layout = new FormLayout(); - form.setContent(layout); - if (is.getIssuePK() == null) { - //Set creation date - is.setCreationTime(new Date()); - } - BeanFieldGroup binder = new BeanFieldGroup(is.getClass()); - binder.setItemDataSource(is); - Field title = binder.buildAndBind("general.summary", "title", - TextField.class); - title.setSizeFull(); - layout.addComponent(title); - Field desc = binder.buildAndBind("general.description", "description", - TextArea.class); - desc.setSizeFull(); - layout.addComponent(desc); - DateField creation = (DateField) binder.buildAndBind("creation.time", - "creationTime", - DateField.class); - creation.setReadOnly(true); - creation.setDateFormat(VMSettingServer.getSetting("date.format") - .getStringVal()); - creation.setResolution(Resolution.SECOND); - layout.addComponent(creation); - //Add the result - layout.addComponent(issueType); - if (is.getIssueType() != null) { - issueType.setValue(is.getIssueType().getTypeName()); - } else { - //Set it as observation - issueType.setValue("observation.name"); - } - //Lock if being created - issueType.setReadOnly(is.getIssueType() == null); - MessageBox mb = MessageBox.create(); - mb.setData(is); - mb.asModal(true) - .withMessage(layout) - .withButtonAlignment(Alignment.MIDDLE_CENTER) - .withOkButton(() -> { - try { - //Create the attachment - IssueServer issue = (IssueServer) mb.getData(); - issue.setDescription(((TextArea) desc).getValue().trim()); - issue.setIssueType(IssueTypeServer.getType((String) issueType.getValue())); - issue.setCreationTime(creation.getValue()); - issue.setTitle((String) title.getValue()); - boolean toAdd = issue.getIssuePK() == null; - issue.write2DB(); - if (toAdd) { - //Now add it to this Execution Step - if (getStep().getExecutionStepHasIssueList() == null) { - getStep().setExecutionStepHasIssueList(new ArrayList<>()); - } - getStep().addIssue(issue, ValidationManagerUI - .getInstance().getUser()); - getStep().write2DB(); - } - w.updateCurrentStep(); - } catch (Exception ex) { - LOG.log(Level.SEVERE, null, ex); - } - }, ButtonOption.focus(), - ButtonOption.icon(VaadinIcons.CHECK), - ButtonOption.disable()) - .withCancelButton(ButtonOption.icon(VaadinIcons.CLOSE)); - mb.getWindow().setCaption("issue.detail"); - mb.getWindow().setIcon(ValidationManagerUI.SMALL_APP_ICON); - ((TextArea) desc).addTextChangeListener((TextChangeEvent event1) -> { - //Enable if there is a description change. - mb.getButton(ButtonType.OK) - .setEnabled(!step.getLocked() - && !event1.getText().trim().isEmpty()); - }); - ((TextField) title).addTextChangeListener((TextChangeEvent event1) -> { - //Enable if there is a title change. - mb.getButton(ButtonType.OK) - .setEnabled(!step.getLocked() - && !event1.getText().trim().isEmpty()); - }); - mb.open(); - } - - private void displayComment(AttachmentServer as) { - Panel form = new Panel("general.comment"); - FormLayout layout = new FormLayout(); - form.setContent(layout); - BeanFieldGroup binder = new BeanFieldGroup(as.getClass()); - binder.setItemDataSource(as); - Field desc = binder.buildAndBind("general.text", "textValue", - TextArea.class); - desc.setSizeFull(); - layout.addComponent(desc); - MessageBox mb = MessageBox.create(); - mb.setData(as); - mb.asModal(true) - .withMessage(desc) - .withButtonAlignment(Alignment.MIDDLE_CENTER) - .withOkButton(() -> { - try { - //Create the attachment - AttachmentServer a = (AttachmentServer) mb.getData(); - a.setTextValue(((TextArea) desc).getValue().trim()); - boolean toAdd = a.getAttachmentPK() == null; - a.write2DB(); - if (toAdd) { - //Now add it to this Execution Step - if (getStep().getExecutionStepHasAttachmentList() == null) { - getStep().setExecutionStepHasAttachmentList(new ArrayList<>()); - } - getStep().addAttachment(a); - getStep().write2DB(); - } - w.updateCurrentStep(); - } catch (Exception ex) { - LOG.log(Level.SEVERE, null, ex); - } - }, ButtonOption.focus(), - ButtonOption.icon(VaadinIcons.CHECK), - ButtonOption.disable()) - .withCancelButton(ButtonOption.icon(VaadinIcons.CLOSE)); - mb.getWindow().setCaption("enter.comment"); - mb.getWindow().setIcon(ValidationManagerUI.SMALL_APP_ICON); - ((TextArea) desc).addTextChangeListener((TextChangeEvent event1) -> { - //Enable only when there is a comment. - mb.getButton(ButtonType.OK) - .setEnabled(!step.getLocked() - && !event1.getText().trim().isEmpty()); - }); - mb.open(); - } - - @Override - public boolean onAdvance() { - //Can only proceed after the current step is executed and documented. - String answer = ((String) result.getValue()); - String answer2 = ((String) review.getValue()); - if (answer == null) { - Notification.show("unable.to.proceed", - result.getRequiredError(), - Notification.Type.WARNING_MESSAGE); - } else if (reviewer && answer2 == null) { - Notification.show("unable.to.proceed", - review.getRequiredError(), - Notification.Type.WARNING_MESSAGE); - } else { - try { - //Save the result - ExecutionResult newResult = ExecutionResultServer - .getResult(answer); - ReviewResult newReview = ReviewResultServer.getReview(answer2); - getStep().setExecutionStart(start.getValue()); - if (getStep().getResultId() == null - || !Objects.equals(step.getResultId().getId(), - newResult.getId())) { - getStep().setResultId(newResult); - //Set end date to null to reflect update - getStep().setExecutionEnd(null); - } - if (getStep().getReviewResultId() == null - || !Objects.equals(step.getReviewResultId().getId(), - newReview.getId())) { - getStep().setReviewResultId(newReview); - //Set end date to null to reflect update - getStep().setReviewer(ValidationManagerUI.getInstance().getUser()); - } - if (getStep().getExecutionEnd() == null) { - getStep().setExecutionEnd(new Date()); - } - if (reviewer && getStep().getReviewDate() == null) { - getStep().setReviewDate(new Date()); - } - } catch (Exception ex) { - LOG.log(Level.SEVERE, null, ex); - } - } - boolean validAnswer = result.getValue() != null - && !((String) result.getValue()).trim().isEmpty(); - boolean validReview = review.getValue() != null - && !((String) review.getValue()).trim().isEmpty(); - return reviewer ? validReview && validAnswer : validAnswer; - } - - @Override - public boolean onBack() { - return getStep().getStep().getStepSequence() > 1; - } - - /** - * @return the step - */ - public ExecutionStepServer getStep() { - return step; - } - - public static boolean getPDFRendering(File source, File dest) - throws IllegalStateException { - OfficeManager officeManager = null; - try { - File home = new File(VMSettingServer.getSetting("openoffice.home") - .getStringVal()); - int port = VMSettingServer - .getSetting("openoffice.port").getIntVal(); - if (!home.isDirectory() || !home.exists()) { - LOG.log(Level.WARNING, - "Unable to find OpenOffice and/or LibreOffice " - + "installation at: {0}", home); - Notification.show("unable.to.render.pdf.title", - "unable.to.render.pdf.message", - Notification.Type.ERROR_MESSAGE); - return false; - } - if (port <= 0) { - LOG.log(Level.WARNING, - "Unable to find OpenOffice and/or LibreOffice " - + "installation at port: {0}", port); - Notification.show("unable.to.render.pdf.title", - "unable.to.render.pdf.port", - Notification.Type.ERROR_MESSAGE); - return false; - } - // Connect to an OpenOffice.org instance running on available port - try { - officeManager = new DefaultOfficeManagerBuilder() - .setPortNumber(port) - .setOfficeHome(home) - .build(); - officeManager.start(); - - OfficeDocumentConverter converter - = new OfficeDocumentConverter(officeManager); - converter.convert(source, dest); - // close the connection - officeManager.stop(); - return true; - } catch (IllegalStateException ise) { - //Looks like OpenOffice or LibreOffice is not installed - LOG.log(Level.WARNING, - "Unable to find OpenOffice and/or LibreOffice " - + "installation.", ise); - } - } catch (OfficeException e) { - if (officeManager != null) { - try { - officeManager.stop(); - } catch (OfficeException ex) { - LOG.log(Level.SEVERE, null, ex); - } - } - LOG.log(Level.SEVERE, null, e); - } - return false; - } - - private void displayAttachment(AttachmentServer attachment) { - String name = attachment.getFileName(); - byte[] bytes = attachment.getFile(); - boolean ableToDisplay = false; - try { - for (IFileDisplay fd : Lookup.getDefault() - .lookupAll(IFileDisplay.class)) { - if (fd.supportFile(new File(name))) { - ValidationManagerUI.getInstance() - .addWindow(fd.getViewer(fd.loadFile(name, - bytes))); - ableToDisplay = true; - break; - } - } - if (!ableToDisplay) { - //Convert file to pfd - PDFDisplay pdf = new PDFDisplay(); - File source = pdf.loadFile(name, bytes); - File dest = new File(System.getProperty("java.io.tmpdir") - + System.getProperty("file.separator") - + name.substring(0, name.lastIndexOf(".")) - + ".pdf"); - getPDFRendering(source, dest); - if (dest.exists()) { - ValidationManagerUI.getInstance().addWindow(pdf.getViewer(dest)); - ableToDisplay = true; - } - } - } catch (IOException ex) { - LOG.log(Level.SEVERE, - "Error loading attachment file: " - + name, ex); - } - if (!ableToDisplay) { - Notification.show("unable.to.render.pdf.title", - "unable.to.render.pdf.message", - Notification.Type.ERROR_MESSAGE); - } - } - - private MessageBox getDeletionPrompt(Object data) { - MessageBox mb = MessageBox.createQuestion(); - mb.setData(data); - mb.asModal(true) - .withMessage(new Label("remove.item.title")) - .withButtonAlignment(Alignment.MIDDLE_CENTER) - .withYesButton(() -> { - try { - if (mb.getData() instanceof ExecutionStepHasAttachment) { - getStep().removeAttachment(new AttachmentServer( - ((ExecutionStepHasAttachment) mb.getData()) - .getAttachment().getAttachmentPK())); - } - if (mb.getData() instanceof ExecutionStepHasIssue) { - getStep().removeIssue(new IssueServer( - ((ExecutionStepHasIssue) mb.getData()) - .getIssue())); - } - getStep().write2DB(); - getStep().update(); - w.updateCurrentStep(); - } catch (Exception ex) { - LOG.log(Level.SEVERE, null, ex); - } - }, ButtonOption.focus(), - ButtonOption.icon(VaadinIcons.CHECK)) - .withNoButton(() -> { - if (mb.getData() instanceof ExecutionStepHasAttachment) { - ExecutionStepHasAttachment esha = (ExecutionStepHasAttachment) mb.getData(); - if (esha.getAttachment().getAttachmentType().getType().equals("comment")) { - displayComment(new AttachmentServer(esha - .getAttachment().getAttachmentPK())); - } else { - displayAttachment(new AttachmentServer(esha - .getAttachment().getAttachmentPK())); - } - } - if (mb.getData() instanceof ExecutionStepHasIssue) { - ExecutionStepHasIssue eshi = (ExecutionStepHasIssue) mb.getData(); - displayIssue(new IssueServer(eshi.getIssue())); - } - }, - ButtonOption.icon(VaadinIcons.CLOSE)); - mb.getWindow().setCaption("issue.details"); - mb.getWindow().setIcon(ValidationManagerUI.SMALL_APP_ICON); - return mb; - } -} +package net.sourceforge.javydreamercsw.validation.manager.web.execution; + +import com.vaadin.data.fieldgroup.BeanFieldGroup; +import com.vaadin.event.FieldEvents.TextChangeEvent; +import com.vaadin.icons.VaadinIcons; +import com.vaadin.server.Resource; +import com.vaadin.server.Sizeable; +import com.vaadin.shared.ui.datefield.Resolution; +import com.vaadin.ui.Alignment; +import com.vaadin.ui.Button; +import com.vaadin.ui.ComboBox; +import com.vaadin.ui.Component; +import com.vaadin.ui.DateField; +import com.vaadin.ui.Field; +import com.vaadin.ui.FormLayout; +import com.vaadin.ui.HorizontalLayout; +import com.vaadin.ui.Label; +import com.vaadin.ui.Notification; +import com.vaadin.ui.Panel; +import com.vaadin.ui.TextArea; +import com.vaadin.ui.TextField; +import com.vaadin.ui.VerticalLayout; +import com.vaadin.ui.Window; +import com.vaadin.ui.themes.ValoTheme; +import com.validation.manager.core.DataBaseManager; +import com.validation.manager.core.api.internationalization.InternationalizationProvider; +import com.validation.manager.core.db.AttachmentType; +import com.validation.manager.core.db.ExecutionResult; +import com.validation.manager.core.db.ExecutionStep; +import com.validation.manager.core.db.ExecutionStepHasAttachment; +import com.validation.manager.core.db.ExecutionStepHasIssue; +import com.validation.manager.core.db.ReviewResult; +import com.validation.manager.core.db.controller.ExecutionResultJpaController; +import com.validation.manager.core.db.controller.IssueTypeJpaController; +import com.validation.manager.core.db.controller.ReviewResultJpaController; +import com.validation.manager.core.server.core.AttachmentServer; +import com.validation.manager.core.server.core.AttachmentTypeServer; +import com.validation.manager.core.server.core.ExecutionResultServer; +import com.validation.manager.core.server.core.ExecutionStepServer; +import com.validation.manager.core.server.core.IssueServer; +import com.validation.manager.core.server.core.IssueTypeServer; +import com.validation.manager.core.server.core.ReviewResultServer; +import com.validation.manager.core.server.core.VMSettingServer; +import de.steinwedel.messagebox.ButtonOption; +import de.steinwedel.messagebox.ButtonType; +import de.steinwedel.messagebox.MessageBox; +import java.io.File; +import java.io.IOException; +import java.util.ArrayList; +import java.util.Date; +import java.util.Objects; +import java.util.logging.Level; +import java.util.logging.Logger; +import net.sourceforge.javydreamercsw.validation.manager.web.component.ByteToStringConverter; +import net.sourceforge.javydreamercsw.validation.manager.web.VMWindow; +import net.sourceforge.javydreamercsw.validation.manager.web.ValidationManagerUI; +import net.sourceforge.javydreamercsw.validation.manager.web.file.IFileDisplay; +import net.sourceforge.javydreamercsw.validation.manager.web.file.PDFDisplay; +import org.jodconverter.OfficeDocumentConverter; +import org.jodconverter.office.DefaultOfficeManagerBuilder; +import org.jodconverter.office.OfficeException; +import org.jodconverter.office.OfficeManager; +import org.openide.util.Lookup; +import org.vaadin.easyuploads.MultiFileUpload; +import org.vaadin.teemu.wizards.Wizard; +import org.vaadin.teemu.wizards.WizardStep; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class ExecutionWizardStep implements WizardStep { + + private final Wizard w; + private final ExecutionStepServer step; + private final ComboBox result = new ComboBox("general.result"); + private final ComboBox review = new ComboBox("quality.review"); + private final ComboBox issueType = new ComboBox("issue.type"); + private Button attach; + private Button bug; + private Button comment; + private DateField start; + private DateField end; + private DateField reviewDate; + private static final Logger LOG + = Logger.getLogger(ExecutionWizardStep.class.getSimpleName()); + private boolean reviewer = false; + + public ExecutionWizardStep(Wizard w, ExecutionStep step, + boolean reviewer) { + this.reviewer = reviewer; + this.w = w; + this.step = new ExecutionStepServer(step); + issueType.setSizeFull(); + issueType.setReadOnly(false); + issueType.setRequired(true); + issueType.setRequiredError("missing.type"); + IssueTypeJpaController it + = new IssueTypeJpaController(DataBaseManager + .getEntityManagerFactory()); + it.findIssueTypeEntities().forEach(type -> { + String item = Lookup.getDefault().lookup(InternationalizationProvider.class) + .translate(type.getTypeName()); + issueType.addItem(type.getTypeName()); + issueType.setItemCaption(type.getTypeName(), item); + switch (type.getId()) { + case 1: + issueType.setItemIcon(type.getTypeName(), VaadinIcons.BUG); + break; + case 2: + issueType.setItemIcon(type.getTypeName(), VaadinIcons.EYE); + break; + case 3: + issueType.setItemIcon(type.getTypeName(), VaadinIcons.QUESTION); + break; + } + }); + result.setReadOnly(false); + result.setRequired(true); + result.setRequiredError("missing.result"); + result.setTextInputAllowed(false); + review.setReadOnly(false); + review.setRequired(true); + review.setRequiredError("missing.reviiew.result"); + review.setTextInputAllowed(false); + ReviewResultJpaController c2 + = new ReviewResultJpaController(DataBaseManager + .getEntityManagerFactory()); + c2.findReviewResultEntities().forEach(r -> { + String item = Lookup.getDefault().lookup(InternationalizationProvider.class) + .translate(r.getReviewName()); + review.addItem(r.getReviewName()); + review.setItemCaption(r.getReviewName(), item); + Resource icon; + switch (r.getId()) { + case 1: + icon = VaadinIcons.CHECK; + break; + case 2: + icon = VaadinIcons.CLOSE; + break; + default: + icon = VaadinIcons.CLOCK; + break; + } + review.setItemIcon(r.getReviewName(), icon); + }); + ExecutionResultJpaController c + = new ExecutionResultJpaController(DataBaseManager + .getEntityManagerFactory()); + c.findExecutionResultEntities().forEach(r -> { + String item = Lookup.getDefault().lookup(InternationalizationProvider.class) + .translate(r.getResultName()); + result.addItem(r.getResultName()); + result.setItemCaption(r.getResultName(), item); + Resource icon; + switch (r.getId()) { + case 1: + icon = VaadinIcons.CHECK; + break; + case 2: + icon = VaadinIcons.CLOSE; + break; + case 3: + icon = VaadinIcons.PAUSE; + break; + default: + icon = VaadinIcons.CLOCK; + break; + } + result.setItemIcon(r.getResultName(), icon); + }); + } + + @Override + public String getCaption() { + return getStep().getStep().getTestCase().getName() + " Step:" + + getStep().getStep().getStepSequence(); + } + + @Override + public Component getContent() { + getStep().update(); + Panel form = new Panel("step.detail"); + if (getStep().getExecutionStart() == null) { + //Set the start date. + getStep().setExecutionStart(new Date()); + } + FormLayout layout = new FormLayout(); + form.setContent(layout); + form.addStyleName(ValoTheme.FORMLAYOUT_LIGHT); + BeanFieldGroup binder = new BeanFieldGroup(getStep().getStep().getClass()); + binder.setItemDataSource(getStep().getStep()); + TextArea text = new TextArea("general.text"); + text.setConverter(new ByteToStringConverter()); + binder.bind(text, "text"); + text.setSizeFull(); + layout.addComponent(text); + Field notes = binder.buildAndBind("general.notes", "notes", + TextArea.class); + notes.setSizeFull(); + layout.addComponent(notes); + if (getStep().getExecutionStart() != null) { + start = new DateField("start.date"); + start.setResolution(Resolution.SECOND); + start.setDateFormat(VMSettingServer.getSetting("date.format") + .getStringVal()); + start.setValue(getStep().getExecutionStart()); + start.setReadOnly(true); + layout.addComponent(start); + } + if (getStep().getExecutionEnd() != null) { + end = new DateField(Lookup.getDefault().lookup(InternationalizationProvider.class) + .translate("end.date")); + end.setDateFormat(VMSettingServer.getSetting("date.format") + .getStringVal()); + end.setResolution(Resolution.SECOND); + end.setValue(getStep().getExecutionEnd()); + end.setReadOnly(true); + layout.addComponent(end); + } + binder.setReadOnly(true); + //Space to record result + if (getStep().getResultId() != null) { + result.setValue(getStep().getResultId().getResultName()); + } + layout.addComponent(result); + if (reviewer) {//Space to record review + if (getStep().getReviewResultId() != null) { + review.setValue(getStep().getReviewResultId().getReviewName()); + } + layout.addComponent(review); + } + //Add Reviewer name + if (getStep().getReviewer() != null) { + TextField reviewerField = new TextField(Lookup.getDefault() + .lookup(InternationalizationProvider.class) + .translate("general.reviewer")); + reviewerField.setValue(getStep().getReviewer().getFirstName() + " " + + getStep().getReviewer().getLastName()); + reviewerField.setReadOnly(true); + layout.addComponent(reviewerField); + } + if (getStep().getReviewDate() != null) { + reviewDate = new DateField(Lookup.getDefault() + .lookup(InternationalizationProvider.class) + .translate("review.date")); + reviewDate.setDateFormat(VMSettingServer.getSetting("date.format") + .getStringVal()); + reviewDate.setResolution(Resolution.SECOND); + reviewDate.setValue(getStep().getReviewDate()); + reviewDate.setReadOnly(true); + layout.addComponent(reviewDate); + } + if (VMSettingServer.getSetting("show.expected.result").getBoolVal()) { + TextArea expectedResult = new TextArea("expected.result"); + expectedResult.setConverter(new ByteToStringConverter()); + binder.bind(expectedResult, "expectedResult"); + expectedResult.setSizeFull(); + layout.addComponent(expectedResult); + } + //Add the Attachments + HorizontalLayout attachments = new HorizontalLayout(); + attachments.setCaption("general.attachment"); + HorizontalLayout comments = new HorizontalLayout(); + comments.setCaption("general.comments"); + HorizontalLayout issues = new HorizontalLayout(); + issues.setCaption("general.issue"); + int commentCounter = 0; + int issueCounter = 0; + for (ExecutionStepHasIssue ei : getStep().getExecutionStepHasIssueList()) { + issueCounter++; + Button a = new Button("Issue #" + issueCounter); + a.setIcon(VaadinIcons.BUG); + a.addClickListener((Button.ClickEvent event) -> { + displayIssue(new IssueServer(ei.getIssue())); + }); + a.setEnabled(!step.getLocked()); + issues.addComponent(a); + } + for (ExecutionStepHasAttachment attachment + : getStep().getExecutionStepHasAttachmentList()) { + switch (attachment.getAttachment().getAttachmentType().getType()) { + case "comment": { + //Comments go in a different section + commentCounter++; + Button a = new Button("Comment #" + commentCounter); + a.setIcon(VaadinIcons.CLIPBOARD_TEXT); + a.addClickListener((Button.ClickEvent event) -> { + if (!step.getLocked()) { + //Prompt if user wants this removed + MessageBox mb = getDeletionPrompt(attachment); + mb.open(); + } else { + displayComment(new AttachmentServer(attachment + .getAttachment().getAttachmentPK())); + } + }); + a.setEnabled(!step.getLocked()); + comments.addComponent(a); + break; + } + default: { + Button a = new Button(attachment.getAttachment().getFileName()); + a.setEnabled(!step.getLocked()); + a.setIcon(VaadinIcons.PAPERCLIP); + a.addClickListener((Button.ClickEvent event) -> { + if (!step.getLocked()) { + //Prompt if user wants this removed + MessageBox mb = getDeletionPrompt(attachment); + mb.open(); + } else { + displayAttachment( + new AttachmentServer(attachment.getAttachment() + .getAttachmentPK())); + } + }); + attachments.addComponent(a); + break; + } + } + } + if (attachments.getComponentCount() > 0) { + layout.addComponent(attachments); + } + if (comments.getComponentCount() > 0) { + layout.addComponent(comments); + } + if (issues.getComponentCount() > 0) { + layout.addComponent(issues); + } + //Add the menu + HorizontalLayout hl = new HorizontalLayout(); + attach = new Button("add.attachment"); + attach.setIcon(VaadinIcons.PAPERCLIP); + attach.addClickListener((Button.ClickEvent event) -> { + //Show dialog to upload file. + Window dialog = new VMWindow("attach.file"); + VerticalLayout vl = new VerticalLayout(); + MultiFileUpload multiFileUpload = new MultiFileUpload() { + @Override + protected void handleFile(File file, String fileName, + String mimeType, long length) { + try { + LOG.log(Level.FINE, "Received file {1} at: {0}", + new Object[]{file.getAbsolutePath(), fileName}); + //Process the file + //Create the attachment + AttachmentServer a = new AttachmentServer(); + a.addFile(file, fileName); + //Overwrite the default file name set in addFile. It'll be a temporary file name + a.setFileName(fileName); + a.write2DB(); + //Now add it to this Execution Step + if (getStep().getExecutionStepHasAttachmentList() == null) { + getStep().setExecutionStepHasAttachmentList(new ArrayList<>()); + } + getStep().addAttachment(a); + getStep().write2DB(); + w.updateCurrentStep(); + } catch (Exception ex) { + LOG.log(Level.SEVERE, "Error creating attachment!", ex); + } + } + }; + multiFileUpload.setCaption("select.files.attach"); + vl.addComponent(multiFileUpload); + dialog.setContent(vl); + dialog.setHeight(25, Sizeable.Unit.PERCENTAGE); + dialog.setWidth(25, Sizeable.Unit.PERCENTAGE); + dialog.center(); + ValidationManagerUI.getInstance().addWindow(dialog); + }); + hl.addComponent(attach); + bug = new Button("create.issue"); + bug.setIcon(VaadinIcons.BUG); + bug.addClickListener((Button.ClickEvent event) -> { + displayIssue(new IssueServer()); + }); + hl.addComponent(bug); + comment = new Button("add.comment"); + comment.setIcon(VaadinIcons.CLIPBOARD_TEXT); + comment.addClickListener((Button.ClickEvent event) -> { + AttachmentServer as = new AttachmentServer(); + //Get comment type + AttachmentType type = AttachmentTypeServer + .getTypeForExtension("comment"); + as.setAttachmentType(type); + displayComment(as); + }); + hl.addComponent(comment); + step.update(); + attach.setEnabled(!step.getLocked()); + bug.setEnabled(!step.getLocked()); + comment.setEnabled(!step.getLocked()); + result.setEnabled(!step.getLocked()); + layout.addComponent(hl); + return layout; + } + + private void displayIssue(IssueServer is) { + Panel form = new Panel("general.issue"); + FormLayout layout = new FormLayout(); + form.setContent(layout); + if (is.getIssuePK() == null) { + //Set creation date + is.setCreationTime(new Date()); + } + BeanFieldGroup binder = new BeanFieldGroup(is.getClass()); + binder.setItemDataSource(is); + Field title = binder.buildAndBind("general.summary", "title", + TextField.class); + title.setSizeFull(); + layout.addComponent(title); + Field desc = binder.buildAndBind("general.description", "description", + TextArea.class); + desc.setSizeFull(); + layout.addComponent(desc); + DateField creation = (DateField) binder.buildAndBind("creation.time", + "creationTime", + DateField.class); + creation.setReadOnly(true); + creation.setDateFormat(VMSettingServer.getSetting("date.format") + .getStringVal()); + creation.setResolution(Resolution.SECOND); + layout.addComponent(creation); + //Add the result + layout.addComponent(issueType); + if (is.getIssueType() != null) { + issueType.setValue(is.getIssueType().getTypeName()); + } else { + //Set it as observation + issueType.setValue("observation.name"); + } + //Lock if being created + issueType.setReadOnly(is.getIssueType() == null); + MessageBox mb = MessageBox.create(); + mb.setData(is); + mb.asModal(true) + .withMessage(layout) + .withButtonAlignment(Alignment.MIDDLE_CENTER) + .withOkButton(() -> { + try { + //Create the attachment + IssueServer issue = (IssueServer) mb.getData(); + issue.setDescription(((TextArea) desc).getValue().trim()); + issue.setIssueType(IssueTypeServer.getType((String) issueType.getValue())); + issue.setCreationTime(creation.getValue()); + issue.setTitle((String) title.getValue()); + boolean toAdd = issue.getIssuePK() == null; + issue.write2DB(); + if (toAdd) { + //Now add it to this Execution Step + if (getStep().getExecutionStepHasIssueList() == null) { + getStep().setExecutionStepHasIssueList(new ArrayList<>()); + } + getStep().addIssue(issue, ValidationManagerUI + .getInstance().getUser()); + getStep().write2DB(); + } + w.updateCurrentStep(); + } catch (Exception ex) { + LOG.log(Level.SEVERE, null, ex); + } + }, ButtonOption.focus(), + ButtonOption.icon(VaadinIcons.CHECK), + ButtonOption.disable()) + .withCancelButton(ButtonOption.icon(VaadinIcons.CLOSE)); + mb.getWindow().setCaption("issue.detail"); + mb.getWindow().setIcon(ValidationManagerUI.SMALL_APP_ICON); + ((TextArea) desc).addTextChangeListener((TextChangeEvent event1) -> { + //Enable if there is a description change. + mb.getButton(ButtonType.OK) + .setEnabled(!step.getLocked() + && !event1.getText().trim().isEmpty()); + }); + ((TextField) title).addTextChangeListener((TextChangeEvent event1) -> { + //Enable if there is a title change. + mb.getButton(ButtonType.OK) + .setEnabled(!step.getLocked() + && !event1.getText().trim().isEmpty()); + }); + mb.open(); + } + + private void displayComment(AttachmentServer as) { + Panel form = new Panel("general.comment"); + FormLayout layout = new FormLayout(); + form.setContent(layout); + BeanFieldGroup binder = new BeanFieldGroup(as.getClass()); + binder.setItemDataSource(as); + Field desc = binder.buildAndBind("general.text", "textValue", + TextArea.class); + desc.setSizeFull(); + layout.addComponent(desc); + MessageBox mb = MessageBox.create(); + mb.setData(as); + mb.asModal(true) + .withMessage(desc) + .withButtonAlignment(Alignment.MIDDLE_CENTER) + .withOkButton(() -> { + try { + //Create the attachment + AttachmentServer a = (AttachmentServer) mb.getData(); + a.setTextValue(((TextArea) desc).getValue().trim()); + boolean toAdd = a.getAttachmentPK() == null; + a.write2DB(); + if (toAdd) { + //Now add it to this Execution Step + if (getStep().getExecutionStepHasAttachmentList() == null) { + getStep().setExecutionStepHasAttachmentList(new ArrayList<>()); + } + getStep().addAttachment(a); + getStep().write2DB(); + } + w.updateCurrentStep(); + } catch (Exception ex) { + LOG.log(Level.SEVERE, null, ex); + } + }, ButtonOption.focus(), + ButtonOption.icon(VaadinIcons.CHECK), + ButtonOption.disable()) + .withCancelButton(ButtonOption.icon(VaadinIcons.CLOSE)); + mb.getWindow().setCaption("enter.comment"); + mb.getWindow().setIcon(ValidationManagerUI.SMALL_APP_ICON); + ((TextArea) desc).addTextChangeListener((TextChangeEvent event1) -> { + //Enable only when there is a comment. + mb.getButton(ButtonType.OK) + .setEnabled(!step.getLocked() + && !event1.getText().trim().isEmpty()); + }); + mb.open(); + } + + @Override + public boolean onAdvance() { + //Can only proceed after the current step is executed and documented. + String answer = ((String) result.getValue()); + String answer2 = ((String) review.getValue()); + if (answer == null) { + Notification.show("unable.to.proceed", + result.getRequiredError(), + Notification.Type.WARNING_MESSAGE); + } else if (reviewer && answer2 == null) { + Notification.show("unable.to.proceed", + review.getRequiredError(), + Notification.Type.WARNING_MESSAGE); + } else { + try { + //Save the result + ExecutionResult newResult = ExecutionResultServer + .getResult(answer); + ReviewResult newReview = ReviewResultServer.getReview(answer2); + getStep().setExecutionStart(start.getValue()); + if (getStep().getResultId() == null + || !Objects.equals(step.getResultId().getId(), + newResult.getId())) { + getStep().setResultId(newResult); + //Set end date to null to reflect update + getStep().setExecutionEnd(null); + } + if (getStep().getReviewResultId() == null + || !Objects.equals(step.getReviewResultId().getId(), + newReview.getId())) { + getStep().setReviewResultId(newReview); + //Set end date to null to reflect update + getStep().setReviewer(ValidationManagerUI.getInstance().getUser()); + } + if (getStep().getExecutionEnd() == null) { + getStep().setExecutionEnd(new Date()); + } + if (reviewer && getStep().getReviewDate() == null) { + getStep().setReviewDate(new Date()); + } + } catch (Exception ex) { + LOG.log(Level.SEVERE, null, ex); + } + } + boolean validAnswer = result.getValue() != null + && !((String) result.getValue()).trim().isEmpty(); + boolean validReview = review.getValue() != null + && !((String) review.getValue()).trim().isEmpty(); + return reviewer ? validReview && validAnswer : validAnswer; + } + + @Override + public boolean onBack() { + return getStep().getStep().getStepSequence() > 1; + } + + /** + * @return the step + */ + public ExecutionStepServer getStep() { + return step; + } + + public static boolean getPDFRendering(File source, File dest) + throws IllegalStateException { + OfficeManager officeManager = null; + try { + File home = new File(VMSettingServer.getSetting("openoffice.home") + .getStringVal()); + int port = VMSettingServer + .getSetting("openoffice.port").getIntVal(); + if (!home.isDirectory() || !home.exists()) { + LOG.log(Level.WARNING, + "Unable to find OpenOffice and/or LibreOffice " + + "installation at: {0}", home); + Notification.show("unable.to.render.pdf.title", + "unable.to.render.pdf.message", + Notification.Type.ERROR_MESSAGE); + return false; + } + if (port <= 0) { + LOG.log(Level.WARNING, + "Unable to find OpenOffice and/or LibreOffice " + + "installation at port: {0}", port); + Notification.show("unable.to.render.pdf.title", + "unable.to.render.pdf.port", + Notification.Type.ERROR_MESSAGE); + return false; + } + // Connect to an OpenOffice.org instance running on available port + try { + officeManager = new DefaultOfficeManagerBuilder() + .setPortNumber(port) + .setOfficeHome(home) + .build(); + officeManager.start(); + + OfficeDocumentConverter converter + = new OfficeDocumentConverter(officeManager); + converter.convert(source, dest); + // close the connection + officeManager.stop(); + return true; + } catch (IllegalStateException ise) { + //Looks like OpenOffice or LibreOffice is not installed + LOG.log(Level.WARNING, + "Unable to find OpenOffice and/or LibreOffice " + + "installation.", ise); + } + } catch (OfficeException e) { + if (officeManager != null) { + try { + officeManager.stop(); + } catch (OfficeException ex) { + LOG.log(Level.SEVERE, null, ex); + } + } + LOG.log(Level.SEVERE, null, e); + } + return false; + } + + private void displayAttachment(AttachmentServer attachment) { + String name = attachment.getFileName(); + byte[] bytes = attachment.getFile(); + boolean ableToDisplay = false; + try { + for (IFileDisplay fd : Lookup.getDefault() + .lookupAll(IFileDisplay.class)) { + if (fd.supportFile(new File(name))) { + ValidationManagerUI.getInstance() + .addWindow(fd.getViewer(fd.loadFile(name, + bytes))); + ableToDisplay = true; + break; + } + } + if (!ableToDisplay) { + //Convert file to pfd + PDFDisplay pdf = new PDFDisplay(); + File source = pdf.loadFile(name, bytes); + File dest = new File(System.getProperty("java.io.tmpdir") + + System.getProperty("file.separator") + + name.substring(0, name.lastIndexOf(".")) + + ".pdf"); + getPDFRendering(source, dest); + if (dest.exists()) { + ValidationManagerUI.getInstance().addWindow(pdf.getViewer(dest)); + ableToDisplay = true; + } + } + } catch (IOException ex) { + LOG.log(Level.SEVERE, + "Error loading attachment file: " + + name, ex); + } + if (!ableToDisplay) { + Notification.show("unable.to.render.pdf.title", + "unable.to.render.pdf.message", + Notification.Type.ERROR_MESSAGE); + } + } + + private MessageBox getDeletionPrompt(Object data) { + MessageBox mb = MessageBox.createQuestion(); + mb.setData(data); + mb.asModal(true) + .withMessage(new Label("remove.item.title")) + .withButtonAlignment(Alignment.MIDDLE_CENTER) + .withYesButton(() -> { + try { + if (mb.getData() instanceof ExecutionStepHasAttachment) { + getStep().removeAttachment(new AttachmentServer( + ((ExecutionStepHasAttachment) mb.getData()) + .getAttachment().getAttachmentPK())); + } + if (mb.getData() instanceof ExecutionStepHasIssue) { + getStep().removeIssue(new IssueServer( + ((ExecutionStepHasIssue) mb.getData()) + .getIssue())); + } + getStep().write2DB(); + getStep().update(); + w.updateCurrentStep(); + } catch (Exception ex) { + LOG.log(Level.SEVERE, null, ex); + } + }, ButtonOption.focus(), + ButtonOption.icon(VaadinIcons.CHECK)) + .withNoButton(() -> { + if (mb.getData() instanceof ExecutionStepHasAttachment) { + ExecutionStepHasAttachment esha = (ExecutionStepHasAttachment) mb.getData(); + if (esha.getAttachment().getAttachmentType().getType().equals("comment")) { + displayComment(new AttachmentServer(esha + .getAttachment().getAttachmentPK())); + } else { + displayAttachment(new AttachmentServer(esha + .getAttachment().getAttachmentPK())); + } + } + if (mb.getData() instanceof ExecutionStepHasIssue) { + ExecutionStepHasIssue eshi = (ExecutionStepHasIssue) mb.getData(); + displayIssue(new IssueServer(eshi.getIssue())); + } + }, + ButtonOption.icon(VaadinIcons.CLOSE)); + mb.getWindow().setCaption("issue.details"); + mb.getWindow().setIcon(ValidationManagerUI.SMALL_APP_ICON); + return mb; + } +} diff --git a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/notification/NotificationManager.java b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/notification/NotificationManager.java index 2111d16b..f755a55c 100644 --- a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/notification/NotificationManager.java +++ b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/notification/NotificationManager.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,39 +13,61 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package net.sourceforge.javydreamercsw.validation.manager.web.notification; - -import com.validation.manager.core.api.notification.INotificationManager; -import com.validation.manager.core.api.notification.NotificationTypes; -import com.validation.manager.core.db.VmUser; -import com.validation.manager.core.server.core.NotificationServer; -import com.validation.manager.core.server.core.NotificationTypeServer; -import java.util.Date; -import org.openide.util.lookup.ServiceProvider; - -@ServiceProvider(service = INotificationManager.class) -public class NotificationManager implements INotificationManager { - - @Override - public void addNotification(String message, NotificationTypes type, - VmUser target, VmUser author) throws Exception { - NotificationServer ns = new NotificationServer(); - ns.setAuthor(author); - ns.setTargetUser(target); - ns.setContent(message); - ns.setCreationDate(new Date()); - String selected; - switch (type) { - case TEST: - selected = "notification.test.pending"; - break; - case REVIEW: - selected = "notification.review.pending"; - break; - default: - selected = "general.notification"; - } - ns.setNotificationType(NotificationTypeServer.getType(selected)); - ns.write2DB(); - } -} +package net.sourceforge.javydreamercsw.validation.manager.web.notification; + +import com.validation.manager.core.api.email.IEmailManager; +import com.validation.manager.core.api.internationalization.InternationalizationProvider; +import com.validation.manager.core.api.notification.INotificationManager; +import com.validation.manager.core.api.notification.NotificationTypes; +import com.validation.manager.core.db.VmUser; +import com.validation.manager.core.server.core.NotificationServer; +import com.validation.manager.core.server.core.NotificationTypeServer; +import com.validation.manager.core.server.core.VMSettingServer; +import com.validation.manager.core.server.core.VMUserServer; +import java.util.Date; +import java.util.Locale; +import org.openide.util.Lookup; +import org.openide.util.lookup.ServiceProvider; + +@ServiceProvider(service = INotificationManager.class) +public class NotificationManager implements INotificationManager { + + private static final InternationalizationProvider TRANSLATOR + = Lookup.getDefault().lookup(InternationalizationProvider.class); + + @Override + public void addNotification(String message, NotificationTypes type, + VmUser target, VmUser author) throws Exception { + NotificationServer ns = new NotificationServer(); + ns.setAuthor(author); + ns.setTargetUser(target); + ns.setContent(message); + ns.setCreationDate(new Date()); + String selected; + switch (type) { + case TEST: + selected = "notification.test.pending"; + break; + case REVIEW: + selected = "notification.review.pending"; + break; + default: + selected = "general.notification"; + } + ns.setNotificationType(NotificationTypeServer.getType(selected)); + ns.write2DB(); + //If email is configured, send the user an email as well. + if (VMSettingServer.getSetting("mail.enable").getBoolVal() + && !target.getEmail().isEmpty()) { + Lookup.getDefault().lookup(IEmailManager.class) + .sendEmail(target.getEmail(), null, + author.getEmail().isEmpty() + ? new VMUserServer(1).getEmail() + : author.getEmail(), + TRANSLATOR.translate(selected, + new Locale(target.getLocale())), + TRANSLATOR.translate("notification.new", + new Locale(target.getLocale()))); + } + } +} diff --git a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/notification/NotificationScreenProvider.java b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/notification/NotificationScreenProvider.java index f6645f29..a1594c6b 100644 --- a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/notification/NotificationScreenProvider.java +++ b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/notification/NotificationScreenProvider.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -31,6 +31,7 @@ import com.vaadin.ui.VerticalLayout; import com.validation.manager.core.DataBaseManager; import com.validation.manager.core.IMainContentProvider; +import com.validation.manager.core.VMException; import com.validation.manager.core.VMUI; import com.validation.manager.core.api.internationalization.InternationalizationProvider; import com.validation.manager.core.db.Notification; @@ -43,8 +44,8 @@ import java.util.Locale; import java.util.logging.Level; import java.util.logging.Logger; -import net.sourceforge.javydreamercsw.validation.manager.web.UserToStringConverter; import net.sourceforge.javydreamercsw.validation.manager.web.ValidationManagerUI; +import net.sourceforge.javydreamercsw.validation.manager.web.component.UserToStringConverter; import net.sourceforge.javydreamercsw.validation.manager.web.provider.AbstractProvider; import org.openide.util.Lookup; import org.openide.util.lookup.ServiceProvider; @@ -59,9 +60,6 @@ public class NotificationScreenProvider extends AbstractProvider { private static final Logger LOG = Logger.getLogger(NotificationScreenProvider.class.getSimpleName()); - private VerticalLayout vs = null; - private final InternationalizationProvider TRANSLATOR = Lookup.getDefault() - .lookup(InternationalizationProvider.class); @Override public boolean shouldDisplay() { @@ -76,16 +74,7 @@ public String getComponentCaption() { @Override public Component getContent() { - if (vs == null) { - update(); - } - return vs; - } - - @Override - public void update() { - vs = new VerticalLayout(); - super.update(); + VerticalLayout vs = new VerticalLayout(); //On top put a list of notifications BeanItemContainer container = new BeanItemContainer<>(Notification.class); @@ -201,7 +190,7 @@ public Class getPresentationType() { ns.write2DB(); ((VMUI) UI.getCurrent()).updateScreen(); ((VMUI) UI.getCurrent()).showTab(getComponentCaption()); - } catch (Exception ex) { + } catch (VMException ex) { LOG.log(Level.SEVERE, null, ex); } } @@ -217,7 +206,7 @@ public Class getPresentationType() { ns.write2DB(); ((VMUI) UI.getCurrent()).updateScreen(); ((VMUI) UI.getCurrent()).showTab(getComponentCaption()); - } catch (Exception ex) { + } catch (VMException ex) { LOG.log(Level.SEVERE, null, ex); } } @@ -238,9 +227,7 @@ public Class getPresentationType() { = new NotificationServer((Notification) n); ns.setAcknowledgeDate(new Date()); ns.write2DB(); - ((VMUI) UI.getCurrent()).updateScreen(); - ((VMUI) UI.getCurrent()).showTab(getComponentCaption()); - } catch (Exception ex) { + } catch (VMException ex) { LOG.log(Level.SEVERE, null, ex); } } @@ -250,6 +237,6 @@ public Class getPresentationType() { vs.addComponent(text); vs.setSizeFull(); vs.setId(getComponentCaption()); + return vs; } } - diff --git a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/profile/ProfileProvider.java b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/profile/ProfileProvider.java index 2b4145f4..944fe764 100644 --- a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/profile/ProfileProvider.java +++ b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/profile/ProfileProvider.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,197 +13,37 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package net.sourceforge.javydreamercsw.validation.manager.web.profile; - -import com.vaadin.data.fieldgroup.BeanFieldGroup; -import com.vaadin.event.FieldEvents; -import com.vaadin.event.FieldEvents.TextChangeListener; -import com.vaadin.icons.VaadinIcons; -import com.vaadin.ui.Alignment; -import com.vaadin.ui.Button; -import com.vaadin.ui.ComboBox; -import com.vaadin.ui.Component; -import com.vaadin.ui.Field; -import com.vaadin.ui.FormLayout; -import com.vaadin.ui.HorizontalLayout; -import com.vaadin.ui.Label; -import com.vaadin.ui.Notification; -import com.vaadin.ui.Panel; -import com.vaadin.ui.PasswordField; -import com.vaadin.ui.TextField; -import com.vaadin.ui.VerticalLayout; -import com.vaadin.ui.themes.ValoTheme; -import com.validation.manager.core.IMainContentProvider; -import com.validation.manager.core.api.internationalization.InternationalizationProvider; -import com.validation.manager.core.server.core.VMUserServer; -import com.validation.manager.core.tool.MD5; -import de.steinwedel.messagebox.ButtonOption; -import de.steinwedel.messagebox.MessageBox; -import java.util.logging.Level; -import java.util.logging.Logger; -import net.sourceforge.javydreamercsw.validation.manager.web.ValidationManagerUI; -import net.sourceforge.javydreamercsw.validation.manager.web.provider.AbstractProvider; -import org.openide.util.Exceptions; -import org.openide.util.Lookup; -import org.openide.util.lookup.ServiceProvider; - -/** - * The provider for the profile tab to manage your account. - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -@ServiceProvider(service = IMainContentProvider.class, position = 5) -public class ProfileProvider extends AbstractProvider { - - private static final Logger LOG - = Logger.getLogger(ProfileProvider.class.getSimpleName()); - - @Override - public boolean shouldDisplay() { - //Show whenever an user is logged in. - return ValidationManagerUI.getInstance().getUser() != null; - } - - @Override - public String getComponentCaption() { - return "message.admin.userProfile"; - } - - @Override - public Component getContent() { - VMUserServer user = ValidationManagerUI.getInstance().getUser(); - Panel form = new Panel(); - FormLayout layout = new FormLayout(); - form.setContent(layout); - form.addStyleName(ValoTheme.FORMLAYOUT_LIGHT); - BeanFieldGroup binder = new BeanFieldGroup(user.getClass()); - binder.setItemDataSource(user); - Field fn = binder.buildAndBind(Lookup.getDefault().lookup(InternationalizationProvider.class). - translate("general.first.name"), - "firstName", TextField.class); - layout.addComponent(fn); - Field ln = binder.buildAndBind(Lookup.getDefault().lookup(InternationalizationProvider.class). - translate("general.last.name"), - "lastName", TextField.class); - layout.addComponent(ln); - Field username = binder.buildAndBind(Lookup.getDefault().lookup(InternationalizationProvider.class). - translate("general.username"), - "username", TextField.class); - layout.addComponent(username); - PasswordField pw = (PasswordField) binder.buildAndBind( - Lookup.getDefault().lookup(InternationalizationProvider.class). - translate("general.password"), - "password", PasswordField.class); - PasswordChangeListener listener = new PasswordChangeListener(); - pw.addTextChangeListener(listener); - pw.setConverter(new UserPasswordConverter()); - layout.addComponent(pw); - Field email = binder.buildAndBind(Lookup.getDefault().lookup(InternationalizationProvider.class). - translate("general.email"), - "email", TextField.class); - layout.addComponent(email); - ComboBox locale = new ComboBox(Lookup.getDefault().lookup(InternationalizationProvider.class). - translate("general.locale")); - ValidationManagerUI.getAvailableLocales().forEach(l -> { - locale.addItem(l.toString()); - }); - if (user.getLocale() != null) { - locale.setValue(user.getLocale()); - } - layout.addComponent(locale); - Button update = new Button(Lookup.getDefault().lookup(InternationalizationProvider.class). - translate("general.update")); - update.addClickListener((Button.ClickEvent event) -> { - try { - VMUserServer us = new VMUserServer(user); - us.setFirstName((String) fn.getValue()); - us.setLastName((String) ln.getValue()); - us.setEmail((String) email.getValue()); - us.setUsername((String) username.getValue()); - us.setLocale((String) locale.getValue()); - String password = (String) pw.getValue(); - if (listener.isChanged() && !password.equals(user.getPassword())) { - //Different password. Prompt for confirmation - MessageBox mb = MessageBox.create(); - VerticalLayout vl = new VerticalLayout(); - Label l = new Label(Lookup.getDefault().lookup(InternationalizationProvider.class). - translate("password.confirm.pw.message")); - vl.addComponent(l); - PasswordField np = new PasswordField(Lookup.getDefault() - .lookup(InternationalizationProvider.class) - .translate("general.password")); - vl.addComponent(np); - mb.asModal(true) - .withCaption(Lookup.getDefault() - .lookup(InternationalizationProvider.class). - translate("password.confirm.pw")) - .withMessage(vl) - .withButtonAlignment(Alignment.MIDDLE_CENTER) - .withOkButton(() -> { - try { - if (password.equals(MD5.encrypt(np.getValue()))) { - us.setHashPassword(true); - us.setPassword(np.getValue()); - us.write2DB(); - Notification.show(Lookup.getDefault().lookup(InternationalizationProvider.class). - translate("audit.user.account.password.change"), - Notification.Type.ASSISTIVE_NOTIFICATION); - } else { - Notification.show(Lookup.getDefault().lookup(InternationalizationProvider.class). - translate("password.does.not.match"), - Notification.Type.WARNING_MESSAGE); - } - mb.close(); - } catch (Exception ex) { - Exceptions.printStackTrace(ex); - } - }, ButtonOption.focus(), - ButtonOption.closeOnClick(false), - ButtonOption.icon(VaadinIcons.CHECK)) - .withCancelButton( - ButtonOption.icon(VaadinIcons.CLOSE) - ).getWindow().setIcon(ValidationManagerUI.SMALL_APP_ICON); - mb.open(); - } else { - us.write2DB(); - } - ValidationManagerUI.getInstance().setUser(us); - } catch (Exception ex) { - LOG.log(Level.SEVERE, null, ex); - Notification.show(Lookup.getDefault().lookup(InternationalizationProvider.class). - translate("general.error.record.update"), - ex.getLocalizedMessage(), - Notification.Type.ERROR_MESSAGE); - } - }); - Button cancel = new Button(Lookup.getDefault() - .lookup(InternationalizationProvider.class). - translate("general.cancel")); - cancel.addClickListener((Button.ClickEvent event) -> { - binder.discard(); - ValidationManagerUI.getInstance().updateScreen(); - }); - HorizontalLayout hl = new HorizontalLayout(); - hl.addComponent(update); - hl.addComponent(cancel); - layout.addComponent(hl); - return form; - } - - private class PasswordChangeListener implements TextChangeListener { - - private boolean changed = false; - - @Override - public void textChange(FieldEvents.TextChangeEvent event) { - changed = true; - } - - /** - * @return the changed - */ - public boolean isChanged() { - return changed; - } - } -} +package net.sourceforge.javydreamercsw.validation.manager.web.profile; + +import com.vaadin.ui.Component; +import com.validation.manager.core.IMainContentProvider; +import net.sourceforge.javydreamercsw.validation.manager.web.ValidationManagerUI; +import net.sourceforge.javydreamercsw.validation.manager.web.component.UserComponent; +import net.sourceforge.javydreamercsw.validation.manager.web.provider.AbstractProvider; +import org.openide.util.lookup.ServiceProvider; + +/** + * The provider for the profile tab to manage your account. + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +@ServiceProvider(service = IMainContentProvider.class, position = 5) +public class ProfileProvider extends AbstractProvider { + + @Override + public boolean shouldDisplay() { + //Show whenever an user is logged in. + return ValidationManagerUI.getInstance().getUser() != null; + } + + @Override + public String getComponentCaption() { + return "message.admin.userProfile"; + } + + @Override + public Component getContent() { + return new UserComponent(ValidationManagerUI.getInstance().getUser(), + true); + } +} diff --git a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/tester/ExecutionScreen.java b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/tester/ExecutionScreen.java index bd560157..9cc270c3 100644 --- a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/tester/ExecutionScreen.java +++ b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/tester/ExecutionScreen.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,367 +13,361 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package net.sourceforge.javydreamercsw.validation.manager.web.tester; - -import com.vaadin.event.Action; -import com.vaadin.icons.VaadinIcons; -import com.vaadin.ui.Button; -import com.vaadin.ui.Component; -import com.vaadin.ui.HorizontalLayout; -import com.vaadin.ui.Label; -import com.vaadin.ui.Table; -import com.vaadin.ui.TreeTable; -import com.vaadin.ui.VerticalLayout; -import com.vaadin.ui.themes.ValoTheme; -import com.validation.manager.core.api.internationalization.InternationalizationProvider; -import com.validation.manager.core.db.ExecutionStep; -import com.validation.manager.core.db.ExecutionStepPK; -import com.validation.manager.core.db.TestCase; -import com.validation.manager.core.db.TestCaseExecution; -import com.validation.manager.core.server.core.ExecutionStepServer; -import com.validation.manager.core.server.core.ProjectServer; -import com.validation.manager.core.server.core.TestCaseExecutionServer; -import java.time.LocalDateTime; -import java.time.ZoneId; -import java.time.format.DateTimeFormatter; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; -import java.util.StringTokenizer; -import net.sourceforge.javydreamercsw.validation.manager.web.ValidationManagerUI; -import net.sourceforge.javydreamercsw.validation.manager.web.execution.ExecutionWindow; -import net.sourceforge.javydreamercsw.validation.manager.web.provider.AbstractProvider; -import net.sourceforge.javydreamercsw.validation.manager.web.quality.QualityScreenProvider; -import org.openide.util.Lookup; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public abstract class ExecutionScreen extends AbstractProvider { - - private ExecutionWindow executionWindow = null; - private final TreeTable testCaseTree - = new TreeTable("available.tests"); - - public ExecutionScreen() { - testCaseTree.setAnimationsEnabled(true); - testCaseTree.addContainerProperty("general.name", - String.class, ""); - testCaseTree.addGeneratedColumn("general.status", - (Table source, Object itemId, Object columnId) -> { - if (Lookup.getDefault().lookup(InternationalizationProvider.class) - .translate("general.status").equals(columnId) - && itemId instanceof String) { - String id = (String) itemId; - String message; - HorizontalLayout icons = new HorizontalLayout(); - Button label = new Button(); - Button label2 = new Button(); - icons.addComponent(label2); - icons.addComponent(label); - label.addStyleName(ValoTheme.BUTTON_BORDERLESS - + " labelButton"); - label2.addStyleName(ValoTheme.BUTTON_BORDERLESS - + " labelButton"); - Map summary = new HashMap<>(); - boolean locked = false; - if (id.startsWith("tce")) { - TestCaseExecutionServer tce - = new TestCaseExecutionServer( - Integer.parseInt(id.substring(3))); - summary = getSummary(tce, -1); - locked = isLocked(tce); - } else if (id.startsWith("es")) { - ExecutionStepServer es - = new ExecutionStepServer(extractExecutionStepPK(id)); - summary = getSummary( - es.getTestCaseExecution(), - Integer.parseInt(id - .substring(id.lastIndexOf("-") + 1))); - locked = es.getLocked(); - } - if (locked) { - label2.setIcon(VaadinIcons.LOCK); - label2.setDescription(Lookup.getDefault() - .lookup(InternationalizationProvider.class).translate("message.locked")); - } - if (!summary.isEmpty()) { - if (summary.containsKey("result.fail")) { - //At least one failure means the test case is failing - message = "result.fail"; - } else if (summary.containsKey("result.blocked")) { - //It is blocked - message = "result.blocked"; - } else if (summary.containsKey("result.pending") - && !summary.containsKey("result.pass")) { - //Still not done - message = "result.pending"; - } else if (summary.containsKey("result.pending") - && summary.containsKey("result.pass")) { - //In progress - message = "result.progress"; - } else { - //All is pass - message = "result.pass"; - } - label.setCaption(Lookup.getDefault() - .lookup(InternationalizationProvider.class) - .translate(message)); - label.setDescription(Lookup.getDefault() - .lookup(InternationalizationProvider.class) - .translate(message)); - //Completed. Now check result - switch (message) { - case "result.pass": - label.setIcon(VaadinIcons.CHECK); - break; - case "result.fail": - label.setIcon(VaadinIcons.CLOSE); - break; - case "result.blocked": - label.setIcon(VaadinIcons.PAUSE); - break; - case "result.pending": - label.setIcon(VaadinIcons.CLOCK); - break; - case "result.progress": - label.setIcon(VaadinIcons.AUTOMATION); - break; - default: - label.setIcon(VaadinIcons.CLOCK); - break; - } - return icons; - } - } - return new Label(); - }); - testCaseTree.addContainerProperty("general.summary", - String.class, ""); - testCaseTree.addContainerProperty("general.assignment.date", - String.class, ""); - testCaseTree.setVisibleColumns(new Object[]{ - "general.name", - "general.status", - "general.summary", - "general.assignment.date"}); - testCaseTree.addActionHandler(new Action.Handler() { - @Override - public Action[] getActions(Object target, Object sender) { - List actions = new ArrayList<>(); - if (target instanceof String) { - String t = (String) target; - int tcID = -1; - TestCaseExecutionServer tce = null; - if (t.startsWith("es")) { - tce = new TestCaseExecutionServer(new ExecutionStepServer( - extractExecutionStepPK(t)) - .getTestCaseExecution().getId()); - tcID = Integer.parseInt(t - .substring(t.lastIndexOf("-") + 1)); - } else if (t.startsWith("tce")) { - tce = new TestCaseExecutionServer( - Integer.parseInt(t.substring(3))); - } - if (!isLocked(tce, tcID) - && ExecutionScreen.this instanceof TesterScreenProvider) { - actions.add(new Action(Lookup.getDefault().lookup(InternationalizationProvider.class) - .translate("general.execute"))); - } else if (isLocked(tce, tcID) - && ExecutionScreen.this instanceof QualityScreenProvider) { - actions.add(new Action(Lookup.getDefault().lookup(InternationalizationProvider.class) - .translate("general.review"))); - } - } - return actions.toArray(new Action[actions.size()]); - } - - @Override - public void handleAction(Action action, Object sender, Object target) { - //Parse the information to get the exact Execution Step - List executions = new ArrayList<>(); - int tcID = -1; - if (((String) target).startsWith("tce")) { - executions.add(new TestCaseExecutionServer( - Integer.parseInt(((String) target).substring(3)))); - } else if (((String) target).startsWith("es")) { - executions.add(new TestCaseExecutionServer(new ExecutionStepServer( - extractExecutionStepPK((String) target)) - .getTestCaseExecution().getId())); - tcID = Integer.parseInt(((String) target) - .substring(((String) target).lastIndexOf("-") + 1)); - } - showExecutionScreen(executions, tcID); - } - }); - } - - protected Map getSummary(TestCaseExecution tce, int tcId) { - Map summary = new HashMap<>(); - tce.getExecutionStepList().forEach((ExecutionStep es) -> { - if (tcId == -1 || es.getStep().getTestCase().getId() == tcId) { - if (es.getExecutionStart() != null && es.getExecutionEnd() == null) { - //In progress - if (!summary.containsKey("progress")) { - summary.put("progress", 0); - } - summary.put("progress", summary.get("progress") + 1); - } else if (es.getResultId() == null - || (es.getExecutionStart() == null - && es.getExecutionEnd() == null)) { - //Not started - if (!summary.containsKey("result.pending")) { - summary.put("result.pending", 0); - } - summary.put("result.pending", summary.get("result.pending") + 1); - } else if (es.getExecutionStart() != null && es.getExecutionEnd() != null) { - if (!summary.containsKey(es.getResultId().getResultName())) { - summary.put(es.getResultId().getResultName(), 0); - } - summary.put(es.getResultId().getResultName(), - summary.get(es.getResultId().getResultName()) + 1); - } - } - }); - return summary; - } - - @Override - public boolean shouldDisplay() { - return ValidationManagerUI.getInstance().getUser() != null - && ValidationManagerUI.getInstance() - .checkRight("system.configuration"); - } - - protected ExecutionStepPK extractExecutionStepPK(String itemId) { - String id = itemId.substring(2); //Remove es - int esId; - int sId; - int tcId; - StringTokenizer st = new StringTokenizer(id, "-"); - esId = Integer.parseInt(st.nextToken()); - sId = Integer.parseInt(st.nextToken()); - tcId = Integer.parseInt(st.nextToken()); - return new ExecutionStepPK(esId, sId, tcId); - } - - protected void showExecutionScreen(List executions, - int tcID) { - if (executionWindow == null) { - executionWindow = new ExecutionWindow(executions, tcID, - this instanceof QualityScreenProvider); - executionWindow.setCaption(Lookup.getDefault().lookup(InternationalizationProvider.class) - .translate("test.execution")); - executionWindow.setVisible(true); - executionWindow.setClosable(false); - executionWindow.setResizable(false); - executionWindow.center(); - executionWindow.setModal(true); - executionWindow.setSizeFull(); - } - if (!ValidationManagerUI.getInstance().getWindows().contains(executionWindow)) { - ValidationManagerUI.getInstance().addWindow(executionWindow); - } - } - - @Override - public Component getContent() { - VerticalLayout vl = new VerticalLayout(); - update(); - vl.addComponent(testCaseTree); - return vl; - } - - @Override - public void update() { - if (executionWindow != null) { - executionWindow.setCaption(Lookup.getDefault().lookup(InternationalizationProvider.class) - .translate("test.execution")); - } - testCaseTree.setCaption(Lookup.getDefault().lookup(InternationalizationProvider.class) - .translate("available.tests")); - testCaseTree.removeAllItems(); - if (ValidationManagerUI.getInstance().getUser() != null) { - ProjectServer.getProjects().forEach(p -> { - if (p.getParentProjectId() == null) { - testCaseTree.addItem(new Object[]{p.getName(), - "", "",}, "p" + p.getId()); - testCaseTree.setItemIcon("p" + p.getId(), - ValidationManagerUI.PROJECT_ICON); - p.getProjectList().forEach(sp -> { - //Add subprojects - testCaseTree.addItem(new Object[]{sp.getName(), - "", "",}, "p" + sp.getId()); - testCaseTree.setParent("p" + sp.getId(), "p" + p.getId()); - testCaseTree.setItemIcon("p" + sp.getId(), - ValidationManagerUI.PROJECT_ICON); - //Add applicable Executions - Map tests = new HashMap<>(); - sp.getTestProjectList().forEach(test -> { - test.getTestPlanList().forEach(tp -> { - tp.getTestCaseList().forEach(testCase -> { - List tcids = new ArrayList<>(); - testCase.getStepList().forEach(s -> { - s.getExecutionStepList().forEach(es -> { - TestCaseExecution tce = es.getTestCaseExecution(); - testCaseTree.addItem(new Object[]{tce.getName(), - "", "",}, "tce" + tce.getId()); - testCaseTree.setParent("tce" + tce.getId(), - "p" + sp.getId()); - testCaseTree.setItemIcon("tce" + tce.getId(), - ValidationManagerUI.EXECUTION_ICON); - if (this instanceof QualityScreenProvider - && es.getLocked() - || (es.getAssignee() != null - && es.getAssignee().getId() - .equals(ValidationManagerUI.getInstance() - .getUser().getId()))) { - TestCase tc = es.getStep().getTestCase(); - if (!tcids.contains(tc.getId())) { - tcids.add(tc.getId()); - DateTimeFormatter format - = DateTimeFormatter.ofPattern("MMM d yyyy hh:mm a"); - LocalDateTime time - = LocalDateTime.ofInstant(es.getAssignedTime() - .toInstant(), ZoneId.systemDefault()); - String key = "es" + es.getExecutionStepPK().getTestCaseExecutionId() - + "-" + es.getStep().getStepPK().getId() - + "-" + tc.getId(); - testCaseTree.addItem(new Object[]{tc.getName(), - tc.getSummary(), format.format(time),}, - key); - testCaseTree.setParent(key, "tce" - + tce.getId()); - testCaseTree.setItemIcon(key, - ValidationManagerUI.TEST_ICON); - testCaseTree.setChildrenAllowed(key, false); - } - } - }); - }); - tcids.clear(); - }); - }); - }); - //Make columns autofit - int count = 0; - for (Object id : testCaseTree.getVisibleColumns()) { - if (count < 2) { - testCaseTree.setColumnExpandRatio(id, 1.0f); - } - count++; - } - testCaseTree.setSizeFull(); - }); - } - }); - } - //Update column titles - for (String h : testCaseTree.getColumnHeaders()) { - testCaseTree.setColumnHeader(h, Lookup.getDefault() - .lookup(InternationalizationProvider.class).translate(h)); - } - } -} +package net.sourceforge.javydreamercsw.validation.manager.web.tester; + +import com.vaadin.event.Action; +import com.vaadin.icons.VaadinIcons; +import com.vaadin.ui.Button; +import com.vaadin.ui.Component; +import com.vaadin.ui.HorizontalLayout; +import com.vaadin.ui.Label; +import com.vaadin.ui.Table; +import com.vaadin.ui.TreeTable; +import com.vaadin.ui.VerticalLayout; +import com.vaadin.ui.themes.ValoTheme; +import com.validation.manager.core.db.ExecutionStep; +import com.validation.manager.core.db.ExecutionStepPK; +import com.validation.manager.core.db.TestCase; +import com.validation.manager.core.db.TestCaseExecution; +import com.validation.manager.core.server.core.ExecutionStepServer; +import com.validation.manager.core.server.core.ProjectServer; +import com.validation.manager.core.server.core.TestCaseExecutionServer; +import java.time.LocalDateTime; +import java.time.ZoneId; +import java.time.format.DateTimeFormatter; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.StringTokenizer; +import net.sourceforge.javydreamercsw.validation.manager.web.ValidationManagerUI; +import net.sourceforge.javydreamercsw.validation.manager.web.execution.ExecutionWindow; +import net.sourceforge.javydreamercsw.validation.manager.web.provider.AbstractProvider; +import net.sourceforge.javydreamercsw.validation.manager.web.quality.QualityScreenProvider; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public abstract class ExecutionScreen extends AbstractProvider { + + private ExecutionWindow executionWindow = null; + private final TreeTable testCaseTree + = new TreeTable("available.tests"); + + public ExecutionScreen() { + testCaseTree.setAnimationsEnabled(true); + testCaseTree.addContainerProperty("general.name", + String.class, ""); + testCaseTree.addGeneratedColumn("general.status", + (Table source, Object itemId, Object columnId) -> { + if (TRANSLATOR + .translate("general.status").equals(columnId) + && itemId instanceof String) { + String id = (String) itemId; + String message; + HorizontalLayout icons = new HorizontalLayout(); + Button label = new Button(); + Button label2 = new Button(); + icons.addComponent(label2); + icons.addComponent(label); + label.addStyleName(ValoTheme.BUTTON_BORDERLESS + + " labelButton"); + label2.addStyleName(ValoTheme.BUTTON_BORDERLESS + + " labelButton"); + Map summary = new HashMap<>(); + boolean locked = false; + if (id.startsWith("tce")) { + TestCaseExecutionServer tce + = new TestCaseExecutionServer( + Integer.parseInt(id.substring(3))); + summary = getSummary(tce, -1); + locked = isLocked(tce); + } else if (id.startsWith("es")) { + ExecutionStepServer es + = new ExecutionStepServer(extractExecutionStepPK(id)); + summary = getSummary( + es.getTestCaseExecution(), + Integer.parseInt(id + .substring(id.lastIndexOf("-") + 1))); + locked = es.getLocked(); + } + if (locked) { + label2.setIcon(VaadinIcons.LOCK); + label2.setDescription(TRANSLATOR.translate("message.locked")); + } + if (!summary.isEmpty()) { + if (summary.containsKey("result.fail")) { + //At least one failure means the test case is failing + message = "result.fail"; + } else if (summary.containsKey("result.blocked")) { + //It is blocked + message = "result.blocked"; + } else if (summary.containsKey("result.pending") + && !summary.containsKey("result.pass")) { + //Still not done + message = "result.pending"; + } else if (summary.containsKey("result.pending") + && summary.containsKey("result.pass")) { + //In progress + message = "result.progress"; + } else { + //All is pass + message = "result.pass"; + } + label.setCaption(TRANSLATOR + .translate(message)); + label.setDescription(TRANSLATOR + .translate(message)); + //Completed. Now check result + switch (message) { + case "result.pass": + label.setIcon(VaadinIcons.CHECK); + break; + case "result.fail": + label.setIcon(VaadinIcons.CLOSE); + break; + case "result.blocked": + label.setIcon(VaadinIcons.PAUSE); + break; + case "result.pending": + label.setIcon(VaadinIcons.CLOCK); + break; + case "result.progress": + label.setIcon(VaadinIcons.AUTOMATION); + break; + default: + label.setIcon(VaadinIcons.CLOCK); + break; + } + return icons; + } + } + return new Label(); + }); + testCaseTree.addContainerProperty("general.summary", + String.class, ""); + testCaseTree.addContainerProperty("general.assignment.date", + String.class, ""); + testCaseTree.setVisibleColumns(new Object[]{ + "general.name", + "general.status", + "general.summary", + "general.assignment.date"}); + testCaseTree.addActionHandler(new Action.Handler() { + @Override + public Action[] getActions(Object target, Object sender) { + List actions = new ArrayList<>(); + if (target instanceof String) { + String t = (String) target; + int tcID = -1; + TestCaseExecutionServer tce = null; + if (t.startsWith("es")) { + tce = new TestCaseExecutionServer(new ExecutionStepServer( + extractExecutionStepPK(t)) + .getTestCaseExecution().getId()); + tcID = Integer.parseInt(t + .substring(t.lastIndexOf("-") + 1)); + } else if (t.startsWith("tce")) { + tce = new TestCaseExecutionServer( + Integer.parseInt(t.substring(3))); + } + if (!isLocked(tce, tcID) + && ExecutionScreen.this instanceof TesterScreenProvider) { + actions.add(new Action(TRANSLATOR + .translate("general.execute"))); + } else if (isLocked(tce, tcID) + && ExecutionScreen.this instanceof QualityScreenProvider) { + actions.add(new Action(TRANSLATOR + .translate("general.review"))); + } + } + return actions.toArray(new Action[actions.size()]); + } + + @Override + public void handleAction(Action action, Object sender, Object target) { + //Parse the information to get the exact Execution Step + List executions = new ArrayList<>(); + int tcID = -1; + if (((String) target).startsWith("tce")) { + executions.add(new TestCaseExecutionServer( + Integer.parseInt(((String) target).substring(3)))); + } else if (((String) target).startsWith("es")) { + executions.add(new TestCaseExecutionServer(new ExecutionStepServer( + extractExecutionStepPK((String) target)) + .getTestCaseExecution().getId())); + tcID = Integer.parseInt(((String) target) + .substring(((String) target).lastIndexOf("-") + 1)); + } + showExecutionScreen(executions, tcID); + } + }); + } + + protected Map getSummary(TestCaseExecution tce, int tcId) { + Map summary = new HashMap<>(); + tce.getExecutionStepList().forEach((ExecutionStep es) -> { + if (tcId == -1 || es.getStep().getTestCase().getId() == tcId) { + if (es.getExecutionStart() != null && es.getExecutionEnd() == null) { + //In progress + if (!summary.containsKey("progress")) { + summary.put("progress", 0); + } + summary.put("progress", summary.get("progress") + 1); + } else if (es.getResultId() == null + || (es.getExecutionStart() == null + && es.getExecutionEnd() == null)) { + //Not started + if (!summary.containsKey("result.pending")) { + summary.put("result.pending", 0); + } + summary.put("result.pending", summary.get("result.pending") + 1); + } else if (es.getExecutionStart() != null && es.getExecutionEnd() != null) { + if (!summary.containsKey(es.getResultId().getResultName())) { + summary.put(es.getResultId().getResultName(), 0); + } + summary.put(es.getResultId().getResultName(), + summary.get(es.getResultId().getResultName()) + 1); + } + } + }); + return summary; + } + + @Override + public boolean shouldDisplay() { + return ValidationManagerUI.getInstance().getUser() != null + && ValidationManagerUI.getInstance() + .checkRight("system.configuration"); + } + + protected ExecutionStepPK extractExecutionStepPK(String itemId) { + String id = itemId.substring(2); //Remove es + int esId; + int sId; + int tcId; + StringTokenizer st = new StringTokenizer(id, "-"); + esId = Integer.parseInt(st.nextToken()); + sId = Integer.parseInt(st.nextToken()); + tcId = Integer.parseInt(st.nextToken()); + return new ExecutionStepPK(esId, sId, tcId); + } + + protected void showExecutionScreen(List executions, + int tcID) { + if (executionWindow == null) { + executionWindow = new ExecutionWindow(executions, tcID, + this instanceof QualityScreenProvider); + executionWindow.setCaption(TRANSLATOR + .translate("test.execution")); + executionWindow.setVisible(true); + executionWindow.setClosable(false); + executionWindow.setResizable(false); + executionWindow.center(); + executionWindow.setModal(true); + executionWindow.setSizeFull(); + } + if (!ValidationManagerUI.getInstance().getWindows().contains(executionWindow)) { + ValidationManagerUI.getInstance().addWindow(executionWindow); + } + } + + @Override + public Component getContent() { + VerticalLayout vl = new VerticalLayout(); + update(); + vl.addComponent(testCaseTree); + return vl; + } + + @Override + public void update() { + if (executionWindow != null) { + executionWindow.setCaption(TRANSLATOR + .translate("test.execution")); + } + testCaseTree.setCaption(TRANSLATOR + .translate("available.tests")); + testCaseTree.removeAllItems(); + if (ValidationManagerUI.getInstance().getUser() != null) { + ProjectServer.getProjects().forEach(p -> { + if (p.getParentProjectId() == null) { + testCaseTree.addItem(new Object[]{p.getName(), + "", "",}, "p" + p.getId()); + testCaseTree.setItemIcon("p" + p.getId(), + ValidationManagerUI.PROJECT_ICON); + p.getProjectList().forEach(sp -> { + //Add subprojects + testCaseTree.addItem(new Object[]{sp.getName(), + "", "",}, "p" + sp.getId()); + testCaseTree.setParent("p" + sp.getId(), "p" + p.getId()); + testCaseTree.setItemIcon("p" + sp.getId(), + ValidationManagerUI.PROJECT_ICON); + //Add applicable Executions + Map tests = new HashMap<>(); + sp.getTestProjectList().forEach(test -> { + test.getTestPlanList().forEach(tp -> { + tp.getTestCaseList().forEach(testCase -> { + List tcids = new ArrayList<>(); + testCase.getStepList().forEach(s -> { + s.getExecutionStepList().forEach(es -> { + TestCaseExecution tce = es.getTestCaseExecution(); + testCaseTree.addItem(new Object[]{tce.getName(), + "", "",}, "tce" + tce.getId()); + testCaseTree.setParent("tce" + tce.getId(), + "p" + sp.getId()); + testCaseTree.setItemIcon("tce" + tce.getId(), + ValidationManagerUI.EXECUTION_ICON); + if (this instanceof QualityScreenProvider + && es.getLocked() + || (es.getAssignee() != null + && es.getAssignee().getId() + .equals(ValidationManagerUI.getInstance() + .getUser().getId()))) { + TestCase tc = es.getStep().getTestCase(); + if (!tcids.contains(tc.getId())) { + tcids.add(tc.getId()); + DateTimeFormatter format + = DateTimeFormatter.ofPattern("MMM d yyyy hh:mm a"); + LocalDateTime time + = LocalDateTime.ofInstant(es.getAssignedTime() + .toInstant(), ZoneId.systemDefault()); + String key = "es" + es.getExecutionStepPK().getTestCaseExecutionId() + + "-" + es.getStep().getStepPK().getId() + + "-" + tc.getId(); + testCaseTree.addItem(new Object[]{tc.getName(), + tc.getSummary(), format.format(time),}, + key); + testCaseTree.setParent(key, "tce" + + tce.getId()); + testCaseTree.setItemIcon(key, + ValidationManagerUI.TEST_ICON); + testCaseTree.setChildrenAllowed(key, false); + } + } + }); + }); + tcids.clear(); + }); + }); + }); + //Make columns autofit + int count = 0; + for (Object id : testCaseTree.getVisibleColumns()) { + if (count < 2) { + testCaseTree.setColumnExpandRatio(id, 1.0f); + } + count++; + } + testCaseTree.setSizeFull(); + }); + } + }); + } + //Update column titles + for (String h : testCaseTree.getColumnHeaders()) { + testCaseTree.setColumnHeader(h, TRANSLATOR.translate(h)); + } + } +} diff --git a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/wizard/assign/AssignUserStep.java b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/wizard/assign/AssignUserStep.java index e232e945..21c86d77 100644 --- a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/wizard/assign/AssignUserStep.java +++ b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/wizard/assign/AssignUserStep.java @@ -13,150 +13,150 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package net.sourceforge.javydreamercsw.validation.manager.web.wizard.assign; - -import com.vaadin.data.Item; -import com.vaadin.data.util.BeanItemContainer; -import com.vaadin.icons.VaadinIcons; -import com.vaadin.ui.AbstractSelect.ItemCaptionMode; -import com.vaadin.ui.Component; -import com.vaadin.ui.Notification; -import com.vaadin.ui.OptionGroup; -import com.vaadin.ui.TreeTable; -import com.vaadin.ui.VerticalLayout; -import com.validation.manager.core.DataBaseManager; -import com.validation.manager.core.db.TestCase; -import com.validation.manager.core.db.VmUser; -import com.validation.manager.core.db.controller.TestCaseJpaController; -import com.validation.manager.core.server.core.RoleServer; -import com.validation.manager.core.server.core.TestCaseExecutionServer; -import com.validation.manager.core.server.core.TestCaseServer; -import com.validation.manager.core.server.core.VMUserServer; -import com.validation.manager.core.tool.TCEExtraction; -import com.validation.manager.core.tool.Tool; -import java.nio.charset.StandardCharsets; -import java.util.ArrayList; -import java.util.List; -import java.util.logging.Level; -import java.util.logging.Logger; -import net.sourceforge.javydreamercsw.validation.manager.web.TreeTableCheckBox; -import net.sourceforge.javydreamercsw.validation.manager.web.ValidationManagerUI; -import org.vaadin.teemu.wizards.WizardStep; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class AssignUserStep implements WizardStep { - - private final Object key; - private final TreeTable testTree - = new TreeTable("available.tests"); - private final OptionGroup userGroup - = new OptionGroup("available.tester"); - private TestCaseExecutionServer tce = null; - private TestCaseServer tc = null; - private static final Logger LOG - = Logger.getLogger(AssignUserStep.class.getSimpleName()); - private final ValidationManagerUI ui; - - public AssignUserStep(ValidationManagerUI ui, Object item) { - this.key = item; - this.ui = ui; - } - - @Override - public String getCaption() { - return "assign.test.case"; - } - - @Override - public Component getContent() { - VerticalLayout l = new VerticalLayout(); - List testCases = new ArrayList<>(); - List users = new ArrayList<>(); - TCEExtraction extracted = Tool.extractTCE(key); - tc = extracted.getTestCase(); - tce = extracted.getTestCaseExecution(); - if (tc != null) { - testCases.add(tc.getEntity()); - } else if (tce != null) { - tce.getExecutionStepList().stream().filter((es) - -> (!testCases.contains(es.getStep().getTestCase()))) - .forEachOrdered((es) -> { - testCases.add(es.getStep().getTestCase()); - }); - } - testTree.addContainerProperty("general.name", - TreeTableCheckBox.class, ""); - testTree.addContainerProperty("general.description", - String.class, ""); - testTree.setWidth("20em"); - testCases.forEach((t) -> { - testTree.addItem(new Object[]{new TreeTableCheckBox(testTree, - t.getName(), t.getId()), - t.getSummary() == null ? "" : new String(t.getSummary(), - StandardCharsets.UTF_8)}, t.getId()); - testTree.setChildrenAllowed(t.getId(), false); - }); - testTree.setPageLength(testCases.size() + 1); - testTree.setSizeFull(); - l.addComponent(testTree); - //Add list of testers - users.addAll(RoleServer.getRole("tester").getVmUserList()); - BeanItemContainer userContainer - = new BeanItemContainer<>(VmUser.class); - userContainer.addAll(users); - userGroup.setContainerDataSource(userContainer); - userGroup.setItemCaptionMode(ItemCaptionMode.EXPLICIT); - userGroup.getItemIds().forEach(id -> { - VmUser u = (VmUser) id; - userGroup.setItemCaption(id, u.getFirstName() + " " - + u.getLastName()); - userGroup.setItemIcon(id, VaadinIcons.USER); - }); - l.addComponent(userGroup); - return l; - } - - @Override - public boolean onAdvance() { - boolean selectedTestCase = false; - List testCaseIds = new ArrayList<>(); - for (Object id : testTree.getItemIds()) { - Item item = testTree.getItem(id); - Object val = item.getItemProperty("general.name").getValue(); - if (val instanceof TreeTableCheckBox) { - TreeTableCheckBox ttcb = (TreeTableCheckBox) val; - if (ttcb.getValue()) { - selectedTestCase = true; - testCaseIds.add((Integer) id); - } - } - } - if (!selectedTestCase) { - Notification.show("unable.to.proceed", - "select.test.case.message", - Notification.Type.WARNING_MESSAGE); - return false; - } - try { - //Now process the data - VMUserServer user = new VMUserServer((VmUser) userGroup.getValue()); - TestCaseJpaController c - = new TestCaseJpaController(DataBaseManager - .getEntityManagerFactory()); - testCaseIds.forEach((id) -> { - user.assignTestCase(tce, c.findTestCase(id), ui.getUser()); - }); - } catch (Exception ex) { - LOG.log(Level.SEVERE, null, ex); - } - return true; - } - - @Override - public boolean onBack() { - return false; - } -} +package net.sourceforge.javydreamercsw.validation.manager.web.wizard.assign; + +import com.vaadin.data.Item; +import com.vaadin.data.util.BeanItemContainer; +import com.vaadin.icons.VaadinIcons; +import com.vaadin.ui.AbstractSelect.ItemCaptionMode; +import com.vaadin.ui.Component; +import com.vaadin.ui.Notification; +import com.vaadin.ui.OptionGroup; +import com.vaadin.ui.TreeTable; +import com.vaadin.ui.VerticalLayout; +import com.validation.manager.core.DataBaseManager; +import com.validation.manager.core.db.TestCase; +import com.validation.manager.core.db.VmUser; +import com.validation.manager.core.db.controller.TestCaseJpaController; +import com.validation.manager.core.server.core.RoleServer; +import com.validation.manager.core.server.core.TestCaseExecutionServer; +import com.validation.manager.core.server.core.TestCaseServer; +import com.validation.manager.core.server.core.VMUserServer; +import com.validation.manager.core.tool.TCEExtraction; +import com.validation.manager.core.tool.Tool; +import java.nio.charset.StandardCharsets; +import java.util.ArrayList; +import java.util.List; +import java.util.logging.Level; +import java.util.logging.Logger; +import net.sourceforge.javydreamercsw.validation.manager.web.component.TreeTableCheckBox; +import net.sourceforge.javydreamercsw.validation.manager.web.ValidationManagerUI; +import org.vaadin.teemu.wizards.WizardStep; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class AssignUserStep implements WizardStep { + + private final Object key; + private final TreeTable testTree + = new TreeTable("available.tests"); + private final OptionGroup userGroup + = new OptionGroup("available.tester"); + private TestCaseExecutionServer tce = null; + private TestCaseServer tc = null; + private static final Logger LOG + = Logger.getLogger(AssignUserStep.class.getSimpleName()); + private final ValidationManagerUI ui; + + public AssignUserStep(ValidationManagerUI ui, Object item) { + this.key = item; + this.ui = ui; + } + + @Override + public String getCaption() { + return "assign.test.case"; + } + + @Override + public Component getContent() { + VerticalLayout l = new VerticalLayout(); + List testCases = new ArrayList<>(); + List users = new ArrayList<>(); + TCEExtraction extracted = Tool.extractTCE(key); + tc = extracted.getTestCase(); + tce = extracted.getTestCaseExecution(); + if (tc != null) { + testCases.add(tc.getEntity()); + } else if (tce != null) { + tce.getExecutionStepList().stream().filter((es) + -> (!testCases.contains(es.getStep().getTestCase()))) + .forEachOrdered((es) -> { + testCases.add(es.getStep().getTestCase()); + }); + } + testTree.addContainerProperty("general.name", + TreeTableCheckBox.class, ""); + testTree.addContainerProperty("general.description", + String.class, ""); + testTree.setWidth("20em"); + testCases.forEach((t) -> { + testTree.addItem(new Object[]{new TreeTableCheckBox(testTree, + t.getName(), t.getId()), + t.getSummary() == null ? "" : new String(t.getSummary(), + StandardCharsets.UTF_8)}, t.getId()); + testTree.setChildrenAllowed(t.getId(), false); + }); + testTree.setPageLength(testCases.size() + 1); + testTree.setSizeFull(); + l.addComponent(testTree); + //Add list of testers + users.addAll(RoleServer.getRole("tester").getVmUserList()); + BeanItemContainer userContainer + = new BeanItemContainer<>(VmUser.class); + userContainer.addAll(users); + userGroup.setContainerDataSource(userContainer); + userGroup.setItemCaptionMode(ItemCaptionMode.EXPLICIT); + userGroup.getItemIds().forEach(id -> { + VmUser u = (VmUser) id; + userGroup.setItemCaption(id, u.getFirstName() + " " + + u.getLastName()); + userGroup.setItemIcon(id, VaadinIcons.USER); + }); + l.addComponent(userGroup); + return l; + } + + @Override + public boolean onAdvance() { + boolean selectedTestCase = false; + List testCaseIds = new ArrayList<>(); + for (Object id : testTree.getItemIds()) { + Item item = testTree.getItem(id); + Object val = item.getItemProperty("general.name").getValue(); + if (val instanceof TreeTableCheckBox) { + TreeTableCheckBox ttcb = (TreeTableCheckBox) val; + if (ttcb.getValue()) { + selectedTestCase = true; + testCaseIds.add((Integer) id); + } + } + } + if (!selectedTestCase) { + Notification.show("unable.to.proceed", + "select.test.case.message", + Notification.Type.WARNING_MESSAGE); + return false; + } + try { + //Now process the data + VMUserServer user = new VMUserServer((VmUser) userGroup.getValue()); + TestCaseJpaController c + = new TestCaseJpaController(DataBaseManager + .getEntityManagerFactory()); + testCaseIds.forEach((id) -> { + user.assignTestCase(tce, c.findTestCase(id), ui.getUser()); + }); + } catch (Exception ex) { + LOG.log(Level.SEVERE, null, ex); + } + return true; + } + + @Override + public boolean onBack() { + return false; + } +} diff --git a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/wizard/plan/DetailStep.java b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/wizard/plan/DetailStep.java index 6f91fa22..54c881c9 100644 --- a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/wizard/plan/DetailStep.java +++ b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/wizard/plan/DetailStep.java @@ -1,4 +1,4 @@ -/* +/* * Copyright 2017 Javier A. Ortiz Bultron javier.ortiz.78@gmail.com. * * Licensed under the Apache License, Version 2.0 (the "License"); @@ -13,127 +13,127 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package net.sourceforge.javydreamercsw.validation.manager.web.wizard.plan; - -import com.vaadin.data.fieldgroup.BeanFieldGroup; -import com.vaadin.ui.Component; -import com.vaadin.ui.FormLayout; -import com.vaadin.ui.Panel; -import com.vaadin.ui.TextArea; -import com.vaadin.ui.themes.ValoTheme; -import com.validation.manager.core.DataBaseManager; -import com.validation.manager.core.VMUI; -import com.validation.manager.core.db.TestCaseExecution; -import com.validation.manager.core.db.controller.TestCaseExecutionJpaController; -import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; -import com.validation.manager.core.server.core.TestCaseExecutionServer; -import com.validation.manager.core.server.core.TestCaseServer; -import java.util.List; -import java.util.logging.Level; -import java.util.logging.Logger; -import net.sourceforge.javydreamercsw.validation.manager.web.ByteToStringConverter; -import net.sourceforge.javydreamercsw.validation.manager.web.ValidationManagerUI; -import org.vaadin.teemu.wizards.WizardStep; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class DetailStep implements WizardStep { - - private List testCases; - private final TestCaseExecution tce; - private static final Logger LOG - = Logger.getLogger(DetailStep.class.getSimpleName()); - - public DetailStep() { - this.tce = new TestCaseExecution(); - } - - @Override - public String getCaption() { - return "add.details"; - } - - @Override - public Component getContent() { - Panel form = new Panel("execution.detail"); - FormLayout layout = new FormLayout(); - form.setContent(layout); - form.addStyleName(ValoTheme.FORMLAYOUT_LIGHT); - BeanFieldGroup binder = new BeanFieldGroup(TestCaseExecution.class); - binder.setItemDataSource(tce); - TextArea name = new TextArea("general.name"); - name.setConverter(new ByteToStringConverter()); - binder.bind(name, "name"); - layout.addComponent(name); - TextArea scope = new TextArea("general.scope"); - scope.setConverter(new ByteToStringConverter()); - binder.bind(scope, "scope"); - layout.addComponent(scope); - if (tce.getId() != null) { - TextArea conclusion = new TextArea("general.comclusion"); - conclusion.setConverter(new ByteToStringConverter()); - binder.bind(conclusion, "conclusion"); - layout.addComponent(conclusion); - conclusion.setSizeFull(); - layout.addComponent(conclusion); - } - binder.setBuffered(false); - binder.bindMemberFields(form); - form.setSizeFull(); - return form; - } - - @Override - public boolean onAdvance() { - try { - //Create the record - new TestCaseExecutionJpaController(DataBaseManager - .getEntityManagerFactory()).create(tce); - TestCaseExecutionServer tces = new TestCaseExecutionServer(tce); - //Now create the execution records - TestCaseServer tc; - for (Integer id : testCases) { - //Retrieve the TestCase to get the steps - tc = new TestCaseServer(id); - tces.addTestCase(tc.getEntity()); - } - try { - tces.write2DB(); - VMUI ui = ValidationManagerUI.getInstance(); - ui.buildProjectTree(ui.getSelectdValue()); - ui.updateProjectList(); - ui.updateScreen(); - ui.displayObject(tces.getEntity(), false); - return true; - } catch (NonexistentEntityException ex) { - LOG.log(Level.SEVERE, null, ex); - } catch (Exception ex) { - LOG.log(Level.SEVERE, null, ex); - } - } catch (Exception ex) { - LOG.log(Level.SEVERE, null, ex); - } - return false; - } - - @Override - public boolean onBack() { - return true; - } - - /** - * @return the testCases - */ - public List getTestCases() { - return testCases; - } - - /** - * @param testCases the testCases to set - */ - public void setTestCases(List testCases) { - this.testCases = testCases; - } -} +package net.sourceforge.javydreamercsw.validation.manager.web.wizard.plan; + +import com.vaadin.data.fieldgroup.BeanFieldGroup; +import com.vaadin.ui.Component; +import com.vaadin.ui.FormLayout; +import com.vaadin.ui.Panel; +import com.vaadin.ui.TextArea; +import com.vaadin.ui.themes.ValoTheme; +import com.validation.manager.core.DataBaseManager; +import com.validation.manager.core.VMUI; +import com.validation.manager.core.db.TestCaseExecution; +import com.validation.manager.core.db.controller.TestCaseExecutionJpaController; +import com.validation.manager.core.db.controller.exceptions.NonexistentEntityException; +import com.validation.manager.core.server.core.TestCaseExecutionServer; +import com.validation.manager.core.server.core.TestCaseServer; +import java.util.List; +import java.util.logging.Level; +import java.util.logging.Logger; +import net.sourceforge.javydreamercsw.validation.manager.web.ValidationManagerUI; +import net.sourceforge.javydreamercsw.validation.manager.web.component.ByteToStringConverter; +import org.vaadin.teemu.wizards.WizardStep; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class DetailStep implements WizardStep { + + private List testCases; + private final TestCaseExecution tce; + private static final Logger LOG + = Logger.getLogger(DetailStep.class.getSimpleName()); + + public DetailStep() { + this.tce = new TestCaseExecution(); + } + + @Override + public String getCaption() { + return "add.details"; + } + + @Override + public Component getContent() { + Panel form = new Panel("execution.detail"); + FormLayout layout = new FormLayout(); + form.setContent(layout); + form.addStyleName(ValoTheme.FORMLAYOUT_LIGHT); + BeanFieldGroup binder = new BeanFieldGroup(TestCaseExecution.class); + binder.setItemDataSource(tce); + TextArea name = new TextArea("general.name"); + name.setConverter(new ByteToStringConverter()); + binder.bind(name, "name"); + layout.addComponent(name); + TextArea scope = new TextArea("general.scope"); + scope.setConverter(new ByteToStringConverter()); + binder.bind(scope, "scope"); + layout.addComponent(scope); + if (tce.getId() != null) { + TextArea conclusion = new TextArea("general.conclusion"); + conclusion.setConverter(new ByteToStringConverter()); + binder.bind(conclusion, "conclusion"); + layout.addComponent(conclusion); + conclusion.setSizeFull(); + layout.addComponent(conclusion); + } + binder.setBuffered(false); + binder.bindMemberFields(form); + form.setSizeFull(); + return form; + } + + @Override + public boolean onAdvance() { + try { + //Create the record + new TestCaseExecutionJpaController(DataBaseManager + .getEntityManagerFactory()).create(tce); + TestCaseExecutionServer tces = new TestCaseExecutionServer(tce); + //Now create the execution records + TestCaseServer tc; + for (Integer id : testCases) { + //Retrieve the TestCase to get the steps + tc = new TestCaseServer(id); + tces.addTestCase(tc.getEntity()); + } + try { + tces.write2DB(); + VMUI ui = ValidationManagerUI.getInstance(); + ui.buildProjectTree(ui.getSelectdValue()); + ui.updateProjectList(); + ui.updateScreen(); + ui.displayObject(tces.getEntity(), false); + return true; + } catch (NonexistentEntityException ex) { + LOG.log(Level.SEVERE, null, ex); + } catch (Exception ex) { + LOG.log(Level.SEVERE, null, ex); + } + } catch (Exception ex) { + LOG.log(Level.SEVERE, null, ex); + } + return false; + } + + @Override + public boolean onBack() { + return true; + } + + /** + * @return the testCases + */ + public List getTestCases() { + return testCases; + } + + /** + * @param testCases the testCases to set + */ + public void setTestCases(List testCases) { + this.testCases = testCases; + } +} diff --git a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/wizard/plan/SelectTestCasesStep.java b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/wizard/plan/SelectTestCasesStep.java index 54f95a96..b04cfca5 100644 --- a/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/wizard/plan/SelectTestCasesStep.java +++ b/Validation-Manager-Web/src/main/java/net/sourceforge/javydreamercsw/validation/manager/web/wizard/plan/SelectTestCasesStep.java @@ -13,198 +13,198 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -package net.sourceforge.javydreamercsw.validation.manager.web.wizard.plan; - -import com.vaadin.data.Item; -import com.vaadin.ui.Component; -import com.vaadin.ui.HorizontalLayout; -import com.vaadin.ui.Notification; -import com.vaadin.ui.TreeTable; -import com.vaadin.ui.VerticalLayout; -import com.validation.manager.core.db.Project; -import java.util.ArrayList; -import java.util.List; -import java.util.logging.Level; -import java.util.logging.Logger; -import net.sourceforge.javydreamercsw.validation.manager.web.TreeTableCheckBox; -import net.sourceforge.javydreamercsw.validation.manager.web.ValidationManagerUI; -import org.vaadin.teemu.wizards.Wizard; -import org.vaadin.teemu.wizards.WizardStep; - -/** - * - * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com - */ -public class SelectTestCasesStep implements WizardStep { - - private final Project p; - private final Wizard w; - private final TreeTable testTree = new TreeTable("available.tests"); - private final List projects = new ArrayList<>(); - private static final Logger LOG - = Logger.getLogger(SelectTestCasesStep.class.getSimpleName()); - - public SelectTestCasesStep(Wizard w, Project p) { - this.p = p; - this.w = w; - } - - @Override - public String getCaption() { - return "select.test.case"; - } - - @Override - public Component getContent() { - VerticalLayout l = new VerticalLayout(); - //Add menu - HorizontalLayout menu = new HorizontalLayout(); - if (p != null) { - //Show the Test Plans for the selected project (including sub projects - testTree.addContainerProperty("general.name", - TreeTableCheckBox.class, ""); - testTree.addContainerProperty("general.description", - String.class, ""); - testTree.setWidth("20em"); - addProjectTestPlanning(testTree, p); - } - testTree.setSizeFull(); - l.addComponent(menu); - l.addComponent(testTree); - return l; - } - - @Override - public boolean onAdvance() { - //Get a list of selected test cases - List testCases - = processChildren("project" + p.getId()); - testCases.forEach((i) -> { - LOG.log(Level.FINE, "Test Case: {0}", i); - }); - if (testCases.isEmpty()) { - Notification.show("unable.to.proceed", - "select.test.case.message", - Notification.Type.WARNING_MESSAGE); - return false; - } - //update next step - DetailStep next = ((DetailStep) w.getSteps().get(1)); - next.setTestCases(testCases); - return true; - } - - @Override - public boolean onBack() { - return false; - } - - private void addProjectTestPlanning(TreeTable testTree, Project p) { - //Add the test projects - testTree.addItem(new Object[]{new TreeTableCheckBox(testTree, - p.getName(), "project" + p.getId()), ""}, - "project" + p.getId()); - if (p.getParentProjectId() != null) { - //Add as child - testTree.setParent("project" + p.getId(), - "project" + p.getParentProjectId().getId()); - } - p.getTestProjectList().stream().map((tp) -> { - TreeTableCheckBox cb = new TreeTableCheckBox(testTree, - tp.getName(), "testproject" + tp.getId()); - cb.setIcon(ValidationManagerUI.TEST_SUITE_ICON); - testTree.addItem(new Object[]{cb, ""}, - "testproject" + tp.getId()); - return tp; - }).map((tp) -> { - testTree.setParent("testproject" + tp.getId(), - "project" + p.getId()); - return tp; - }).map((tp) -> { - tp.getTestPlanList().stream().map((plan) -> { - TreeTableCheckBox pcb = new TreeTableCheckBox(testTree, - plan.getName(), plan.getTestPlanPK()); - pcb.setIcon(ValidationManagerUI.PLAN_ICON); - testTree.addItem(new Object[]{pcb, ""}, - plan.getTestPlanPK()); - return plan; - }).map((plan) -> { - testTree.setParent(plan.getTestPlanPK(), - "testproject" + tp.getId()); - return plan; - }).forEachOrdered((plan) -> { - plan.getTestCaseList().stream().map((tc) -> { - TreeTableCheckBox tccb = new TreeTableCheckBox(testTree, - tc.getName(), "tc" + tc.getId()); - tccb.setIcon(ValidationManagerUI.TEST_ICON); - testTree.addItem(new Object[]{tccb, - tc.getSummary() != null - ? new String(tc.getSummary()) : ""}, - "tc" + tc.getId()); - return tc; - }).map((tc) -> { - testTree.setParent("tc" + tc.getId(), - plan.getTestPlanPK()); - return tc; - }).forEachOrdered((tc) -> { - testTree.setChildrenAllowed("tc" + tc.getId(), false); - }); - }); - return tp; - }).forEachOrdered((tp) -> { - testTree.setCollapsed("testproject" + tp.getId(), false); - }); - p.getProjectList().forEach((sp) -> { - addProjectTestPlanning(testTree, sp); - }); - testTree.setCollapsed("project" + p.getId(), false); - } - - private List processChildren(Object parent) { - List testCases = new ArrayList<>(); - //Get a list of selected test cases - testTree.getChildren(parent).stream().map((o) -> { - if (o instanceof String) { - String id = (String) o; - if (id.startsWith("tc")) { - //Is a Test Case - Item item = testTree.getItem(id); - Object val = item.getItemProperty("general.name").getValue(); - if (val instanceof TreeTableCheckBox) { - TreeTableCheckBox ttcb = (TreeTableCheckBox) val; - if (ttcb.getValue()) { - //Selected - LOG.log(Level.FINE, "Included TC: {0}", - ttcb.getObjectId()); - testCases.add(Integer.parseInt(id.substring(2))); - Object pid = id; - //Add the related project to the list. - while (pid != null) { - if (pid instanceof String) { - String s = (String) pid; - if (s.startsWith("project")) { - LOG.log(Level.FINE, "Processing: {0}", s); - getProjects().add(Integer.parseInt(s.substring(7))); - break; - } - } - pid = testTree.getParent(pid); - } - } - } - } - } - return o; - }).filter((o) -> (testTree.hasChildren(o))).forEachOrdered((o) -> { - testCases.addAll(processChildren(o)); - }); - return testCases; - } - - /** - * @return the projects - */ - public List getProjects() { - return projects; - } -} +package net.sourceforge.javydreamercsw.validation.manager.web.wizard.plan; + +import com.vaadin.data.Item; +import com.vaadin.ui.Component; +import com.vaadin.ui.HorizontalLayout; +import com.vaadin.ui.Notification; +import com.vaadin.ui.TreeTable; +import com.vaadin.ui.VerticalLayout; +import com.validation.manager.core.db.Project; +import java.util.ArrayList; +import java.util.List; +import java.util.logging.Level; +import java.util.logging.Logger; +import net.sourceforge.javydreamercsw.validation.manager.web.component.TreeTableCheckBox; +import net.sourceforge.javydreamercsw.validation.manager.web.ValidationManagerUI; +import org.vaadin.teemu.wizards.Wizard; +import org.vaadin.teemu.wizards.WizardStep; + +/** + * + * @author Javier A. Ortiz Bultron javier.ortiz.78@gmail.com + */ +public class SelectTestCasesStep implements WizardStep { + + private final Project p; + private final Wizard w; + private final TreeTable testTree = new TreeTable("available.tests"); + private final List projects = new ArrayList<>(); + private static final Logger LOG + = Logger.getLogger(SelectTestCasesStep.class.getSimpleName()); + + public SelectTestCasesStep(Wizard w, Project p) { + this.p = p; + this.w = w; + } + + @Override + public String getCaption() { + return "select.test.case"; + } + + @Override + public Component getContent() { + VerticalLayout l = new VerticalLayout(); + //Add menu + HorizontalLayout menu = new HorizontalLayout(); + if (p != null) { + //Show the Test Plans for the selected project (including sub projects + testTree.addContainerProperty("general.name", + TreeTableCheckBox.class, ""); + testTree.addContainerProperty("general.description", + String.class, ""); + testTree.setWidth("20em"); + addProjectTestPlanning(testTree, p); + } + testTree.setSizeFull(); + l.addComponent(menu); + l.addComponent(testTree); + return l; + } + + @Override + public boolean onAdvance() { + //Get a list of selected test cases + List testCases + = processChildren("project" + p.getId()); + testCases.forEach((i) -> { + LOG.log(Level.FINE, "Test Case: {0}", i); + }); + if (testCases.isEmpty()) { + Notification.show("unable.to.proceed", + "select.test.case.message", + Notification.Type.WARNING_MESSAGE); + return false; + } + //update next step + DetailStep next = ((DetailStep) w.getSteps().get(1)); + next.setTestCases(testCases); + return true; + } + + @Override + public boolean onBack() { + return false; + } + + private void addProjectTestPlanning(TreeTable testTree, Project p) { + //Add the test projects + testTree.addItem(new Object[]{new TreeTableCheckBox(testTree, + p.getName(), "project" + p.getId()), ""}, + "project" + p.getId()); + if (p.getParentProjectId() != null) { + //Add as child + testTree.setParent("project" + p.getId(), + "project" + p.getParentProjectId().getId()); + } + p.getTestProjectList().stream().map((tp) -> { + TreeTableCheckBox cb = new TreeTableCheckBox(testTree, + tp.getName(), "testproject" + tp.getId()); + cb.setIcon(ValidationManagerUI.TEST_SUITE_ICON); + testTree.addItem(new Object[]{cb, ""}, + "testproject" + tp.getId()); + return tp; + }).map((tp) -> { + testTree.setParent("testproject" + tp.getId(), + "project" + p.getId()); + return tp; + }).map((tp) -> { + tp.getTestPlanList().stream().map((plan) -> { + TreeTableCheckBox pcb = new TreeTableCheckBox(testTree, + plan.getName(), plan.getTestPlanPK()); + pcb.setIcon(ValidationManagerUI.PLAN_ICON); + testTree.addItem(new Object[]{pcb, ""}, + plan.getTestPlanPK()); + return plan; + }).map((plan) -> { + testTree.setParent(plan.getTestPlanPK(), + "testproject" + tp.getId()); + return plan; + }).forEachOrdered((plan) -> { + plan.getTestCaseList().stream().map((tc) -> { + TreeTableCheckBox tccb = new TreeTableCheckBox(testTree, + tc.getName(), "tc" + tc.getId()); + tccb.setIcon(ValidationManagerUI.TEST_ICON); + testTree.addItem(new Object[]{tccb, + tc.getSummary() != null + ? new String(tc.getSummary()) : ""}, + "tc" + tc.getId()); + return tc; + }).map((tc) -> { + testTree.setParent("tc" + tc.getId(), + plan.getTestPlanPK()); + return tc; + }).forEachOrdered((tc) -> { + testTree.setChildrenAllowed("tc" + tc.getId(), false); + }); + }); + return tp; + }).forEachOrdered((tp) -> { + testTree.setCollapsed("testproject" + tp.getId(), false); + }); + p.getProjectList().forEach((sp) -> { + addProjectTestPlanning(testTree, sp); + }); + testTree.setCollapsed("project" + p.getId(), false); + } + + private List processChildren(Object parent) { + List testCases = new ArrayList<>(); + //Get a list of selected test cases + testTree.getChildren(parent).stream().map((o) -> { + if (o instanceof String) { + String id = (String) o; + if (id.startsWith("tc")) { + //Is a Test Case + Item item = testTree.getItem(id); + Object val = item.getItemProperty("general.name").getValue(); + if (val instanceof TreeTableCheckBox) { + TreeTableCheckBox ttcb = (TreeTableCheckBox) val; + if (ttcb.getValue()) { + //Selected + LOG.log(Level.FINE, "Included TC: {0}", + ttcb.getObjectId()); + testCases.add(Integer.parseInt(id.substring(2))); + Object pid = id; + //Add the related project to the list. + while (pid != null) { + if (pid instanceof String) { + String s = (String) pid; + if (s.startsWith("project")) { + LOG.log(Level.FINE, "Processing: {0}", s); + getProjects().add(Integer.parseInt(s.substring(7))); + break; + } + } + pid = testTree.getParent(pid); + } + } + } + } + } + return o; + }).filter((o) -> (testTree.hasChildren(o))).forEachOrdered((o) -> { + testCases.addAll(processChildren(o)); + }); + return testCases; + } + + /** + * @return the projects + */ + public List getProjects() { + return projects; + } +} diff --git a/pom.xml b/pom.xml index 124264d9..e6c960e2 100644 --- a/pom.xml +++ b/pom.xml @@ -3,7 +3,7 @@ 4.0.0 Validation-Manager - 0.3.2 + 0.3.3 net.sourceforge.javydreamercsw pom @@ -176,24 +176,6 @@ false - - cy.github - github-release-plugin - 0.5.2 - - - ${project.artifactId}-${project.version} - true - - - - - gh-upload - - deploy - - -