|
From: <tri...@us...> - 2007-12-28 23:21:40
|
Revision: 222
http://equanda.svn.sourceforge.net/equanda/?rev=222&view=rev
Author: triathlon98
Date: 2007-12-28 15:21:37 -0800 (Fri, 28 Dec 2007)
Log Message:
-----------
EQ-118 replace all "object model" by "domain model"
assure testcases rely on jboss4.2.2 and work with that version
Modified Paths:
--------------
trunk/equanda-client/pom.xml
trunk/equanda-client/src/main/java/org/equanda/export/Export.java
trunk/equanda-client/src/main/java/org/equanda/export/ExportField.java
trunk/equanda-client/src/main/java/org/equanda/export/ExportFieldEvaluator.java
trunk/equanda-client/src/main/java/org/equanda/persistence/query/EquandaQuery.java
trunk/equanda-client/src/main/java/org/equanda/persistence/query/EquandaQueryImpl.java
trunk/equanda-client/src/main/java/org/equanda/translations/TranslatorEJBUtil.java
trunk/equanda-generate/src/main/java/org/equanda/persistence/xml/OMTable.java
trunk/equanda-generate/src/main/velocity/docs/index.html.vm
trunk/equanda-generate/src/main/velocity/docs.ini
trunk/equanda-generate/src/main/velocity/ejb3/DMFieldBean.java.vm
trunk/equanda-generate/src/main/velocity/ejb3/DMObjectBean.java.vm
trunk/equanda-generate/src/main/velocity/ejb3/DMObjectSelector.java.vm
trunk/equanda-generate/src/main/velocity/ejb3/EquandaGlobal.java.vm
trunk/equanda-generate/src/main/velocity/ejb3/LazyEJBList.java.vm
trunk/equanda-generate/src/main/velocity/ejb3/LazyProxyList.java.vm
trunk/equanda-generate/src/main/velocity/ejb3/Mediator.java.vm
trunk/equanda-generate/src/main/velocity/ejb3/MediatorBase.java.vm
trunk/equanda-generate/src/main/velocity/ejb3/MediatorRoot.java.vm
trunk/equanda-generate/src/main/velocity/ejb3/ObjectBase.java.vm
trunk/equanda-generate/src/main/velocity/ejb3/ObjectBean.java.vm
trunk/equanda-generate/src/main/velocity/ejb3/ObjectProxy.java.vm
trunk/equanda-generate/src/main/velocity/ejb3/ObjectProxyState.java.vm
trunk/equanda-generate/src/main/velocity/ejb3/ObjectSelectorBean.java.vm
trunk/equanda-generate/src/main/velocity/ejb3/ObjectSelectorEJB.java.vm
trunk/equanda-generate/src/main/velocity/ejb3/ObjectSelectorHelper.java.vm
trunk/equanda-generate/src/main/velocity/ejb3/ObjectSelectorHelperBase.java.vm
trunk/equanda-generate/src/main/velocity/ejb3/ObjectType.java.vm
trunk/equanda-generate/src/main/velocity/ejb3/ProxyObjectUpdater.java.vm
trunk/equanda-generate/src/main/velocity/import/DatabaseMap.java.vm
trunk/equanda-generate/src/main/velocity/import/FieldMap.java.vm
trunk/equanda-generate/src/main/velocity/import/ImportObjectProxy.java.vm
trunk/equanda-generate/src/main/velocity/login/bean/LoginEJBUtil.java.vm
trunk/equanda-generate/src/main/velocity/t5gui/base/EditPageBase.java.vm
trunk/equanda-generate/src/main/velocity/t5gui/base/SelectComponentBase.java.vm
trunk/equanda-generate/src/main/velocity/t5gui/base/SelectPageBase.java.vm
trunk/equanda-generate/src/main/velocity/t5gui/components/Display.java.vm
trunk/equanda-generate/src/main/velocity/t5gui/components/LinkList.java.vm
trunk/equanda-generate/src/main/velocity/t5gui/components/Select.java.vm
trunk/equanda-generate/src/main/velocity/t5gui/pages/Edit.java.vm
trunk/equanda-generate/src/main/velocity/t5gui/pages/Select.java.vm
trunk/equanda-generate/src/site/wiki/templates/gui-descriptors.wiki
trunk/equanda-maven-plugin/src/main/java/org/equanda/plugin/GeneratePlugin.java
trunk/equanda-maven-plugin/src/main/java/org/equanda/plugin/TranslatePlugin.java
trunk/equanda-maven-plugin/src/site/wiki/generate.wiki
trunk/equanda-server/pom.xml
trunk/equanda-server/src/main/java/org/equanda/attachment/AttachmentServlet.java
trunk/equanda-server/src/main/java/org/equanda/validation/UniqueConverter.java
trunk/equanda-server/src/main/java/org/equanda/validation/UniqueConverterAdapter.java
trunk/equanda-server/src/main/java/org/equanda/ymport/FieldHandler.java
trunk/equanda-server/src/main/java/org/equanda/ymport/ImportHandler.java
trunk/equanda-server/src/main/java/org/equanda/ymport/TableHandler.java
trunk/equanda-t5gui/pom.xml
trunk/equanda-t5gui/src/main/java/org/equanda/t5gui/EquandaGridDataSource.java
trunk/equanda-t5gui/src/main/java/org/equanda/t5gui/services/AppModule.java
trunk/equanda-t5gui/src/main/java/org/equanda/t5gui/translators/UoidTranslator.java
trunk/equanda-t5gui/src/main/site/wiki/index.wiki
trunk/equanda-tapestry4/pom.xml
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/binder/BasicFieldBinder.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/binder/MultipleFieldBinderSource.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/binder/ProxyBinderSource.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/components/Border.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/components/ParametersSuggestReturnHandler.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/components/action/ParameterInputContainerImpl.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/components/action/equandaAction/EquandaAction.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/components/equandaField/EquandaField2.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/components/equandaLinkSelects/EquandaLinkSelects.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/components/equandaTable/EquandaTable.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/components/equandaType/EquandaType.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/components/input/DescriptionInputContainerImpl.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/components/input/equandaAttachment/EquandaAttachment.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/components/input/equandaInput/EquandaInput.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/components/input/equandaInputBlock/EquandaInputBlock.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/components/input/equandaLinkInput/LinkInputBinderWrapper.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/components/input/equandaLinkInput/actionHandler/LinkInputActionHandlerImpl.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/components/select/SelectObject.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/components/select/equandaSelectResults/EquandaSelectResults.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/components/shared/AddViewEditCommons.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/components/shared/PageGroupCommons.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/components/userAdmin/configList/ConfigList.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/components/userAdmin/table/tableRights/TableRights.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/navigation/HasBidirectionalLinkParameter.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/navigation/HasProxyParameter.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/navigation/NavigationEntryContainer.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/navigation/NavigationablePageImpl.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/navigation/ReturnHandlerField.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/pages/EquandaBasePage.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/pages/TapestryHome.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/pages/action/ActionPageParams.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/pages/alerts/Alerts.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/pages/alerts/dataModel/AlertFacade.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/pages/alerts/dataModel/AlertsAdministrationQuery.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/pages/edit/EditPage.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/pages/masterDetail/TableMasterDetailBasePage.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/pages/masterDetail/TableMasterDetailPageParameters.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/pages/masterDetail/TableMasterDetailReturnHandler.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/pages/masterDetail/parameter/TableParameter.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/pages/select/SelectPageParams.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/pages/shared/AddViewEditManipulation.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/pages/shared/AddViewEditPageParameters.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/pages/tableManager/TableManagerPage.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/pages/userAdmin/login/changePassword/ChangePassword.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/pages/userAdmin/startPageConfig/StartPageConfig.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/pages/view/ViewPage.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/pages/wiki/ViewPageRedirector.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/selectionModel/EmbeddedFieldSelectionModel.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/selectionModel/LinkFieldSelectionModel.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/selectionModel/RoleSelectionModel.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/squeezeAdaptor/EquandaProxySqueezeAdaptor.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/translator/DisplayTranslator.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/translator/UoidTranslator.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/useradmin/GlobalUserAdmin.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/useradmin/cache/CacheLoaderPersister.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/useradmin/cache/UserAdminCache.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/util/EquandaProxyAccessor.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/util/Global.java
trunk/equanda-tapestry4/src/main/java/org/equanda/tapestry/util/LoginResolver.java
trunk/equanda-test/pom.xml
trunk/equanda-test/test-core/pom.xml
trunk/equanda-test/test-core/src/main/java/org/equanda/test/dm/server/ActionMediator.java
trunk/equanda-test/test-core/src/main/java/org/equanda/test/dm/server/AutoFieldsMediator.java
trunk/equanda-test/test-core/src/main/java/org/equanda/test/dm/server/BuilderSetSelectorHelper.java
trunk/equanda-test/test-core/src/main/java/org/equanda/test/dm/server/DefaultMediator.java
trunk/equanda-test/test-core/src/main/java/org/equanda/test/dm/server/EquandaRoleMediator.java
trunk/equanda-test/test-core/src/main/java/org/equanda/test/dm/server/LinkableMediator.java
trunk/equanda-test/test-core/src/main/java/org/equanda/test/dm/server/PriorityFieldsMediator.java
trunk/equanda-test/test-core/src/main/java/org/equanda/test/dm/server/ProgrConstraintsMediator.java
trunk/equanda-test/test-core/src/main/java/org/equanda/test/dm/server/SecurMediator.java
trunk/equanda-test/test-core/src/main/java/org/equanda/test/dm/server/SecurSelectorHelper.java
trunk/equanda-test/test-core/src/main/java/org/equanda/test/dm/server/VehicleWithWingsMediator.java
trunk/equanda-test/test-core/src/main/java/org/equanda/test/dm/server/VeryDocumentedSelectorHelper.java
trunk/equanda-test/test-ddltool/pom.xml
trunk/equanda-test/test-t4-gui/pom.xml
trunk/equanda-test/test-t4-gui/src/main/webapp/config.properties
trunk/equanda-test/test-test/pom.xml
trunk/equanda-test/test-test/src/test/java/org/equanda/test/applet/EquandaView.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/applet/TestApplet.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/export/ExportTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/pages/testFilters/TestFilters.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/ActionTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/BuilderSetTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/ChoicesTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/CloneableTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/CompareTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/DefaultTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/DelegateTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/DowngradeTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/EmbeddedTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/EntityTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/EquandaQueryTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/FieldTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/ImmutableIfGlobalInheritedTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/ImmutableIfGlobalTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/InheritanceTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/LazyInstTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/LinkTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/ModifiedProxyTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/MultipleFieldTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/PriorityTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/ProgrConstraintsTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/ProxyTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/RemoveLinksTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/RemoveTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/RequiredFieldsTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/SecurityTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/SelectionTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/SelectorUpdateTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/SelectorsFiltersTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/SelectorsSortingTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/SetEquandaRollbackTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/StringLengthTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/SubselectTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/TestAdapter.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/TypeTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/xejb/UniqueFieldsTest.java
trunk/equanda-test/test-test/src/test/java/org/equanda/test/ymport/ImportTest.java
trunk/equanda-tool/import.ini
trunk/equanda-tool/pom.xml
trunk/equanda-tool/src/main/java/org/equanda/tool/export/ExportWorker.java
trunk/equanda-tool/src/main/java/org/equanda/tool/export/object/ObjectSelector.java
trunk/equanda-tool/src/main/java/org/equanda/tool/print/provider/ReportPrintInfo.java
trunk/equanda-tool/src/main/java/org/equanda/tool/shared/worker/Worker.java
trunk/equanda-tool/src/site/wiki/ImportServlet.wiki
trunk/equanda-tool/translationsEditor.ini
trunk/equanda-util/pom.xml
trunk/equanda-util/src/main/java/org/equanda/util/accessor/ObjectAccessor.java
trunk/equanda-util/src/site/wiki/index.wiki
trunk/equanda-util/src/test/java/org/equanda/util/OMExtensionTest.java
trunk/pom.xml
trunk/src/site/wiki/config.wiki
trunk/src/site/wiki/gettingstarted.wiki
trunk/src/site/wiki/index.wiki
Added Paths:
-----------
trunk/equanda-client/src/main/java/org/equanda/persistence/CheckRulesState.java
trunk/equanda-client/src/main/java/org/equanda/persistence/ClientEquandaStateInterceptor.java
trunk/equanda-client/src/main/java/org/equanda/persistence/ConcurrentModificationException.java
trunk/equanda-client/src/main/java/org/equanda/persistence/EJBUtil.java
trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaConstraintViolation.java
trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaDowngradeException.java
trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaEJB.java
trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaEntity.java
trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaFieldBean.java
trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaImportProxy.java
trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaList.java
trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaMediatorRoot.java
trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaObjectType.java
trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaOperationNotAllowed.java
trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaPersistenceError.java
trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaPersistenceException.java
trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaProxy.java
trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaProxyState.java
trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaSelector.java
trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaSelectorHelper.java
trunk/equanda-client/src/main/java/org/equanda/persistence/ExceptionCodes.java
trunk/equanda-client/src/main/java/org/equanda/persistence/HasUOID.java
trunk/equanda-client/src/main/java/org/equanda/persistence/InvalidUOIDException.java
trunk/equanda-client/src/main/java/org/equanda/persistence/LazyEJBListBase.java
trunk/equanda-client/src/main/java/org/equanda/persistence/LazyList.java
trunk/equanda-client/src/main/java/org/equanda/persistence/LazyProxyListBase.java
trunk/equanda-client/src/main/java/org/equanda/persistence/LenientChecksState.java
trunk/equanda-client/src/main/java/org/equanda/persistence/ObjectSelector.java
trunk/equanda-client/src/main/java/org/equanda/persistence/ObjectType.java
trunk/equanda-client/src/main/java/org/equanda/persistence/SelectorsState.java
trunk/equanda-client/src/main/java/org/equanda/persistence/SelectorsStateType.java
trunk/equanda-client/src/main/java/org/equanda/persistence/ServerEquandaStateInterceptor.java
trunk/equanda-client/src/main/java/org/equanda/persistence/UOID.java
trunk/equanda-client/src/main/java/org/equanda/persistence/UOIDGenerator.java
trunk/equanda-client/src/main/java/org/equanda/persistence/query/
trunk/equanda-client/src/test/java/org/equanda/persistence/EquandaListTest.java
trunk/equanda-generate/src/main/velocity/docs/dm.mm.vm
trunk/equanda-maven-plugin/src/main/java/org/equanda/plugin/DmReportPlugin.java
trunk/equanda-test/src/main/dm/
trunk/equanda-test/src/main/dm/dm.ini
trunk/equanda-test/src/main/dm/dm.xml
trunk/equanda-test/test-core/src/main/java/org/equanda/test/dm/
trunk/equanda-util/src/main/java/org/equanda/util/script/DMExtension.java
trunk/src/site/wiki/dm.wiki
Removed Paths:
-------------
trunk/equanda-client/src/main/java/org/equanda/persistence/om/
trunk/equanda-client/src/test/java/org/equanda/persistence/om/
trunk/equanda-test/src/main/dm/om.ini
trunk/equanda-test/src/main/dm/om.xml
trunk/equanda-test/src/main/om/
trunk/equanda-test/test-core/src/main/java/org/equanda/test/om/
Modified: trunk/equanda-client/pom.xml
===================================================================
--- trunk/equanda-client/pom.xml 2007-12-27 01:30:28 UTC (rev 221)
+++ trunk/equanda-client/pom.xml 2007-12-28 23:21:37 UTC (rev 222)
@@ -30,9 +30,24 @@
<artifactId>commons-httpclient</artifactId>
</dependency>
<dependency>
- <groupId>org.jboss</groupId>
- <artifactId>jboss-ejb3x</artifactId>
+ <groupId>javax.persistence</groupId>
+ <artifactId>persistence-api</artifactId>
<scope>provided</scope>
</dependency>
+ <dependency>
+ <groupId>jboss</groupId>
+ <artifactId>jboss-annotations-ejb3</artifactId>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>jboss</groupId>
+ <artifactId>jboss-ejb-api</artifactId>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>jboss</groupId>
+ <artifactId>jboss-aop</artifactId>
+ <scope>provided</scope>
+ </dependency>
</dependencies>
</project>
Modified: trunk/equanda-client/src/main/java/org/equanda/export/Export.java
===================================================================
--- trunk/equanda-client/src/main/java/org/equanda/export/Export.java 2007-12-27 01:30:28 UTC (rev 221)
+++ trunk/equanda-client/src/main/java/org/equanda/export/Export.java 2007-12-28 23:21:37 UTC (rev 222)
@@ -24,8 +24,8 @@
package org.equanda.export;
-import org.equanda.persistence.om.UOID;
-import org.equanda.persistence.om.EquandaProxy;
+import org.equanda.persistence.UOID;
+import org.equanda.persistence.EquandaProxy;
import org.equanda.util.Base64;
import org.equanda.util.INIFile;
import org.equanda.util.StringSplitter;
Modified: trunk/equanda-client/src/main/java/org/equanda/export/ExportField.java
===================================================================
--- trunk/equanda-client/src/main/java/org/equanda/export/ExportField.java 2007-12-27 01:30:28 UTC (rev 221)
+++ trunk/equanda-client/src/main/java/org/equanda/export/ExportField.java 2007-12-28 23:21:37 UTC (rev 222)
@@ -24,7 +24,7 @@
package org.equanda.export;
-import org.equanda.persistence.om.EquandaProxy;
+import org.equanda.persistence.EquandaProxy;
import java.lang.reflect.Method;
import java.util.Collection;
Modified: trunk/equanda-client/src/main/java/org/equanda/export/ExportFieldEvaluator.java
===================================================================
--- trunk/equanda-client/src/main/java/org/equanda/export/ExportFieldEvaluator.java 2007-12-27 01:30:28 UTC (rev 221)
+++ trunk/equanda-client/src/main/java/org/equanda/export/ExportFieldEvaluator.java 2007-12-28 23:21:37 UTC (rev 222)
@@ -24,7 +24,7 @@
package org.equanda.export;
-import org.equanda.persistence.om.EquandaProxy;
+import org.equanda.persistence.EquandaProxy;
import javolution.lang.TextBuilder;
import java.lang.reflect.Method;
Copied: trunk/equanda-client/src/main/java/org/equanda/persistence/CheckRulesState.java (from rev 217, trunk/equanda-client/src/main/java/org/equanda/persistence/om/CheckRulesState.java)
===================================================================
--- trunk/equanda-client/src/main/java/org/equanda/persistence/CheckRulesState.java (rev 0)
+++ trunk/equanda-client/src/main/java/org/equanda/persistence/CheckRulesState.java 2007-12-28 23:21:37 UTC (rev 222)
@@ -0,0 +1,50 @@
+/**
+ * This file is part of the equanda project.
+ *
+ * The contents of this file are subject to the Mozilla Public License Version 1.1 (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.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis, WITHOUT WARRANTY OF
+ * ANY KIND, either express or implied. See the License for the specific language governing rights and
+ * limitations under the License.
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 2 or later (the "GPL"), or
+ * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
+ * in which case the provisions of the GPL or the LGPL are applicable instead
+ * of those above. If you wish to allow use of your version of this file only
+ * under the terms of either the GPL or the LGPL, and not to allow others to
+ * use your version of this file under the terms of the MPL, indicate your
+ * decision by deleting the provisions above and replace them with the notice
+ * and other provisions required by the GPL or the LGPL. If you do not delete
+ * the provisions above, a recipient may use your version of this file under
+ * the terms of any one of the MPL, the GPL or the LGPL.
+ */
+
+package org.equanda.persistence;
+
+/**
+ * Store the state whether declarative rules should be checked or not. This is stored in a ThreadLocal.
+ * When this is false, checks are skipped.
+ * This should only be used internally in the system to avoid double checks (and resulting slowness).
+ *
+ * @author <a href="mailto:jo...@pr...">Joachim Van der Auwera</a>
+ */
+public class CheckRulesState
+{
+ public static final String RULES_CHECKS_STATE_CONTEXT = "equanda-CheckRulesStateContext";
+
+ private static ThreadLocal state = new ThreadLocal()
+ {
+ protected Object initialValue()
+ {
+ return Boolean.TRUE;
+ }
+ };
+
+ public static boolean getCheckRules() { return (Boolean) state.get(); }
+
+ public static void setCheckRules( boolean value ) { state.set( Boolean.valueOf( value ) ); }
+
+}
\ No newline at end of file
Copied: trunk/equanda-client/src/main/java/org/equanda/persistence/ClientEquandaStateInterceptor.java (from rev 217, trunk/equanda-client/src/main/java/org/equanda/persistence/om/ClientEquandaStateInterceptor.java)
===================================================================
--- trunk/equanda-client/src/main/java/org/equanda/persistence/ClientEquandaStateInterceptor.java (rev 0)
+++ trunk/equanda-client/src/main/java/org/equanda/persistence/ClientEquandaStateInterceptor.java 2007-12-28 23:21:37 UTC (rev 222)
@@ -0,0 +1,68 @@
+/**
+ * This file is part of the equanda project.
+ *
+ * The contents of this file are subject to the Mozilla Public License Version 1.1 (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.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis, WITHOUT WARRANTY OF
+ * ANY KIND, either express or implied. See the License for the specific language governing rights and
+ * limitations under the License.
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 2 or later (the "GPL"), or
+ * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
+ * in which case the provisions of the GPL or the LGPL are applicable instead
+ * of those above. If you wish to allow use of your version of this file only
+ * under the terms of either the GPL or the LGPL, and not to allow others to
+ * use your version of this file under the terms of the MPL, indicate your
+ * decision by deleting the provisions above and replace them with the notice
+ * and other provisions required by the GPL or the LGPL. If you do not delete
+ * the provisions above, a recipient may use your version of this file under
+ * the terms of any one of the MPL, the GPL or the LGPL.
+ */
+
+package org.equanda.persistence;
+
+import org.jboss.aop.advice.Interceptor;
+import org.jboss.aop.joinpoint.Invocation;
+
+import java.io.ObjectStreamException;
+import java.io.Serializable;
+
+/**
+ * Client side interceptor to transport the equanda state to the server as part of the invocation context.
+ *
+ * @author <a href="mailto:jo...@pr...">Joachim Van der Auwera</a>
+ */
+public class ClientEquandaStateInterceptor
+ implements Interceptor, Serializable
+{
+ private static final long serialVersionUID = 4536126296845291076L;
+
+ public static final ClientEquandaStateInterceptor singleton = new ClientEquandaStateInterceptor();
+
+ public String getName()
+ {
+ return "ClientEquandaStateInterceptor";
+ }
+
+ public Object invoke( Invocation invocation )
+ throws Throwable
+ {
+ invocation.getMetaData().addMetaData( LenientChecksState.LENIENT_CHECKS_STATE_CONTEXT,
+ LenientChecksState.LENIENT_CHECKS_STATE_CONTEXT,
+ LenientChecksState.getLenientChecks() );
+
+ invocation.getMetaData().addMetaData( SelectorsState.SELECTORS_STATE_CONTEXT,
+ SelectorsState.SELECTORS_STATE_CONTEXT,
+ SelectorsState.getSelectorsState() );
+ return invocation.invokeNext();
+ }
+
+ Object readResolve()
+ throws ObjectStreamException
+ {
+ return singleton;
+ }
+}
Copied: trunk/equanda-client/src/main/java/org/equanda/persistence/ConcurrentModificationException.java (from rev 217, trunk/equanda-client/src/main/java/org/equanda/persistence/om/ConcurrentModificationException.java)
===================================================================
--- trunk/equanda-client/src/main/java/org/equanda/persistence/ConcurrentModificationException.java (rev 0)
+++ trunk/equanda-client/src/main/java/org/equanda/persistence/ConcurrentModificationException.java 2007-12-28 23:21:37 UTC (rev 222)
@@ -0,0 +1,73 @@
+/**
+ * This file is part of the equanda project.
+ *
+ * The contents of this file are subject to the Mozilla Public License Version 1.1 (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.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis, WITHOUT WARRANTY OF
+ * ANY KIND, either express or implied. See the License for the specific language governing rights and
+ * limitations under the License.
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 2 or later (the "GPL"), or
+ * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
+ * in which case the provisions of the GPL or the LGPL are applicable instead
+ * of those above. If you wish to allow use of your version of this file only
+ * under the terms of either the GPL or the LGPL, and not to allow others to
+ * use your version of this file under the terms of the MPL, indicate your
+ * decision by deleting the provisions above and replace them with the notice
+ * and other provisions required by the GPL or the LGPL. If you do not delete
+ * the provisions above, a recipient may use your version of this file under
+ * the terms of any one of the MPL, the GPL or the LGPL.
+ */
+
+package org.equanda.persistence;
+
+import javax.ejb.ApplicationException;
+
+/**
+ * Exception indicating a concurrent modification
+ *
+ * @author NetRom team
+ */
+@ApplicationException( rollback = true )
+public class ConcurrentModificationException
+ extends EquandaConstraintViolation
+{
+ public static final String DEFAULT_MESSAGE = "CONCURRENT MODIFICATION EXCEPTION";
+
+ private static final long serialVersionUID = 2220363507832990301L;
+
+ public ConcurrentModificationException() {}
+
+ public ConcurrentModificationException( Exception ex )
+ {
+ super( ex );
+ }
+
+ public ConcurrentModificationException( int exceptionCode, Exception ex, String... parameters )
+ {
+ super( exceptionCode, ex, parameters );
+ }
+
+ public ConcurrentModificationException( int exceptionCode, Exception ex )
+ {
+ super( exceptionCode, ex );
+ }
+
+ public ConcurrentModificationException( int exceptionCode, String... parameters )
+ {
+ super( exceptionCode, parameters );
+ }
+
+ public ConcurrentModificationException( int exceptionCode )
+ {
+ super( exceptionCode );
+ }
+
+ String getDefaultMessage()
+ {
+ return DEFAULT_MESSAGE;
+ }
+}
Copied: trunk/equanda-client/src/main/java/org/equanda/persistence/EJBUtil.java (from rev 217, trunk/equanda-client/src/main/java/org/equanda/persistence/om/EJBUtil.java)
===================================================================
--- trunk/equanda-client/src/main/java/org/equanda/persistence/EJBUtil.java (rev 0)
+++ trunk/equanda-client/src/main/java/org/equanda/persistence/EJBUtil.java 2007-12-28 23:21:37 UTC (rev 222)
@@ -0,0 +1,62 @@
+/**
+ * This file is part of the equanda project.
+ *
+ * The contents of this file are subject to the Mozilla Public License Version 1.1 (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.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis, WITHOUT WARRANTY OF
+ * ANY KIND, either express or implied. See the License for the specific language governing rights and
+ * limitations under the License.
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 2 or later (the "GPL"), or
+ * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
+ * in which case the provisions of the GPL or the LGPL are applicable instead
+ * of those above. If you wish to allow use of your version of this file only
+ * under the terms of either the GPL or the LGPL, and not to allow others to
+ * use your version of this file under the terms of the MPL, indicate your
+ * decision by deleting the provisions above and replace them with the notice
+ * and other provisions required by the GPL or the LGPL. If you do not delete
+ * the provisions above, a recipient may use your version of this file under
+ * the terms of any one of the MPL, the GPL or the LGPL.
+ */
+
+package org.equanda.persistence;
+
+import javax.naming.InitialContext;
+
+/**
+ * Utility methods for the EJBUtil classes, avoids duplication of common code.
+ *
+ * @author <a href="mailto:jo...@pr...">Joachim Van der Auwera</a>
+ */
+public class EJBUtil
+{
+ public static <T> T lookup( String jndiName, Class<T> narrowTo )
+ throws javax.naming.NamingException
+ {
+ return lookup( null, jndiName, narrowTo );
+ }
+
+ public static <T> T lookup( java.util.Hashtable environment, String jndiName, Class<T> narrowTo )
+ throws javax.naming.NamingException
+ {
+ // Obtain initial context
+ InitialContext initialContext = new InitialContext( environment );
+ try
+ {
+ Object objRef = initialContext.lookup( jndiName );
+ // only narrow if necessary
+ if ( narrowTo.isInstance( java.rmi.Remote.class ) )
+ {
+ objRef = javax.rmi.PortableRemoteObject.narrow( objRef, narrowTo );
+ }
+ return (T) objRef;
+ }
+ finally
+ {
+ initialContext.close();
+ }
+ }
+}
Copied: trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaConstraintViolation.java (from rev 217, trunk/equanda-client/src/main/java/org/equanda/persistence/om/EquandaConstraintViolation.java)
===================================================================
--- trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaConstraintViolation.java (rev 0)
+++ trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaConstraintViolation.java 2007-12-28 23:21:37 UTC (rev 222)
@@ -0,0 +1,73 @@
+/**
+ * This file is part of the equanda project.
+ *
+ * The contents of this file are subject to the Mozilla Public License Version 1.1 (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.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis, WITHOUT WARRANTY OF
+ * ANY KIND, either express or implied. See the License for the specific language governing rights and
+ * limitations under the License.
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 2 or later (the "GPL"), or
+ * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
+ * in which case the provisions of the GPL or the LGPL are applicable instead
+ * of those above. If you wish to allow use of your version of this file only
+ * under the terms of either the GPL or the LGPL, and not to allow others to
+ * use your version of this file under the terms of the MPL, indicate your
+ * decision by deleting the provisions above and replace them with the notice
+ * and other provisions required by the GPL or the LGPL. If you do not delete
+ * the provisions above, a recipient may use your version of this file under
+ * the terms of any one of the MPL, the GPL or the LGPL.
+ */
+
+package org.equanda.persistence;
+
+import javax.ejb.ApplicationException;
+
+/**
+ * Exception indicating a constraint violation
+ *
+ * @author <a href="mailto:jo...@pr...">Joachim Van der Auwera</a>
+ */
+@ApplicationException( rollback = true )
+public class EquandaConstraintViolation
+ extends EquandaPersistenceException
+{
+ public static final String DEFAULT_MESSAGE = "CONSTRAINT VIOLATION";
+
+ private static final long serialVersionUID = 2220363507832990306L;
+
+ public EquandaConstraintViolation() {}
+
+ public EquandaConstraintViolation( Exception ex )
+ {
+ super( ex );
+ }
+
+ public EquandaConstraintViolation( int exceptionCode, Exception ex, String... parameters )
+ {
+ super( exceptionCode, ex, parameters );
+ }
+
+ public EquandaConstraintViolation( int exceptionCode, Exception ex )
+ {
+ super( exceptionCode, ex );
+ }
+
+ public EquandaConstraintViolation( int exceptionCode, String... parameters )
+ {
+ super( exceptionCode, parameters );
+ }
+
+ public EquandaConstraintViolation( int exceptionCode )
+ {
+ super( exceptionCode );
+ }
+
+ String getDefaultMessage()
+ {
+ return DEFAULT_MESSAGE;
+ }
+}
Copied: trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaDowngradeException.java (from rev 217, trunk/equanda-client/src/main/java/org/equanda/persistence/om/EquandaDowngradeException.java)
===================================================================
--- trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaDowngradeException.java (rev 0)
+++ trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaDowngradeException.java 2007-12-28 23:21:37 UTC (rev 222)
@@ -0,0 +1,72 @@
+/**
+ * This file is part of the equanda project.
+ *
+ * The contents of this file are subject to the Mozilla Public License Version 1.1 (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.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis, WITHOUT WARRANTY OF
+ * ANY KIND, either express or implied. See the License for the specific language governing rights and
+ * limitations under the License.
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 2 or later (the "GPL"), or
+ * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
+ * in which case the provisions of the GPL or the LGPL are applicable instead
+ * of those above. If you wish to allow use of your version of this file only
+ * under the terms of either the GPL or the LGPL, and not to allow others to
+ * use your version of this file under the terms of the MPL, indicate your
+ * decision by deleting the provisions above and replace them with the notice
+ * and other provisions required by the GPL or the LGPL. If you do not delete
+ * the provisions above, a recipient may use your version of this file under
+ * the terms of any one of the MPL, the GPL or the LGPL.
+ */
+
+package org.equanda.persistence;
+
+import javax.ejb.ApplicationException;
+
+/**
+ * Exception indicating a constraint violation
+ *
+ * @author NetRom team
+ */
+@ApplicationException( rollback = false )
+public class EquandaDowngradeException
+ extends EquandaConstraintViolation
+{
+ public static String DEFAULT_MESSAGE = "DOWNGRADE EXCEPTION";
+
+ public EquandaDowngradeException() {}
+
+ public EquandaDowngradeException( Exception ex )
+ {
+ super( ex );
+ }
+
+ public EquandaDowngradeException( int exceptionCode, Exception ex, String... parameters )
+ {
+ super( exceptionCode, ex, parameters );
+ }
+
+ public EquandaDowngradeException( int exceptionCode, Exception ex )
+ {
+ super( exceptionCode, ex );
+ }
+
+ public EquandaDowngradeException( int exceptionCode, String... parameters )
+ {
+ super( exceptionCode, parameters );
+ }
+
+ public EquandaDowngradeException( int exceptionCode )
+ {
+ super( exceptionCode );
+ }
+
+ String getDefaultMessage()
+ {
+ return DEFAULT_MESSAGE;
+ }
+
+}
Copied: trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaEJB.java (from rev 217, trunk/equanda-client/src/main/java/org/equanda/persistence/om/EquandaEJB.java)
===================================================================
--- trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaEJB.java (rev 0)
+++ trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaEJB.java 2007-12-28 23:21:37 UTC (rev 222)
@@ -0,0 +1,50 @@
+/**
+ * This file is part of the equanda project.
+ *
+ * The contents of this file are subject to the Mozilla Public License Version 1.1 (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.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis, WITHOUT WARRANTY OF
+ * ANY KIND, either express or implied. See the License for the specific language governing rights and
+ * limitations under the License.
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 2 or later (the "GPL"), or
+ * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
+ * in which case the provisions of the GPL or the LGPL are applicable instead
+ * of those above. If you wish to allow use of your version of this file only
+ * under the terms of either the GPL or the LGPL, and not to allow others to
+ * use your version of this file under the terms of the MPL, indicate your
+ * decision by deleting the provisions above and replace them with the notice
+ * and other provisions required by the GPL or the LGPL. If you do not delete
+ * the provisions above, a recipient may use your version of this file under
+ * the terms of any one of the MPL, the GPL or the LGPL.
+ */
+
+package org.equanda.persistence;
+
+/**
+ * Base interface for both local and remote EJB interfaces (for ObjectBase which is a shared interface for both).
+ *
+ * @author <a href="mailto:jo...@pr...">Joachim Van der Auwera</a>
+ */
+public interface EquandaEJB
+ extends HasUOID
+{
+ void init( UOID uoid )
+ throws EquandaPersistenceException;
+ void initEntity( EquandaEntity entity )
+ throws EquandaPersistenceException;
+
+ // equanda built-in methods
+
+ java.sql.Timestamp getEquandaModificationDate();
+ String getEquandaType();
+ boolean isEquandaType( String type );
+ String getEquandaName();
+ String getEquandaStatus();
+ void setEquandaStatus( String status );
+
+ void remove();
+}
Copied: trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaEntity.java (from rev 217, trunk/equanda-client/src/main/java/org/equanda/persistence/om/EquandaEntity.java)
===================================================================
--- trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaEntity.java (rev 0)
+++ trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaEntity.java 2007-12-28 23:21:37 UTC (rev 222)
@@ -0,0 +1,51 @@
+/**
+ * This file is part of the equanda project.
+ *
+ * The contents of this file are subject to the Mozilla Public License Version 1.1 (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.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis, WITHOUT WARRANTY OF
+ * ANY KIND, either express or implied. See the License for the specific language governing rights and
+ * limitations under the License.
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 2 or later (the "GPL"), or
+ * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
+ * in which case the provisions of the GPL or the LGPL are applicable instead
+ * of those above. If you wish to allow use of your version of this file only
+ * under the terms of either the GPL or the LGPL, and not to allow others to
+ * use your version of this file under the terms of the MPL, indicate your
+ * decision by deleting the provisions above and replace them with the notice
+ * and other provisions required by the GPL or the LGPL. If you do not delete
+ * the provisions above, a recipient may use your version of this file under
+ * the terms of any one of the MPL, the GPL or the LGPL.
+ */
+
+package org.equanda.persistence;
+
+import java.sql.Timestamp;
+
+/**
+ * Marker interface to indicate equanda entity beans (DMObjectBean)
+ *
+ * @author <a href="mailto:jo...@pr...">Joachim Van der Auwera</a>
+ */
+public interface EquandaEntity
+{
+ UOID getUOID();
+
+ String getEquandaStatus();
+
+ void setEquandaStatus( String status );
+
+ Timestamp getEquandaModificationDate();
+
+ Timestamp getEquandaCreationDate();
+
+ void setEquandaModificationDate( Timestamp modified );
+
+ String getEquandaType();
+
+ long getEquandaVersion();
+}
Copied: trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaFieldBean.java (from rev 217, trunk/equanda-client/src/main/java/org/equanda/persistence/om/EquandaFieldBean.java)
===================================================================
--- trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaFieldBean.java (rev 0)
+++ trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaFieldBean.java 2007-12-28 23:21:37 UTC (rev 222)
@@ -0,0 +1,64 @@
+/**
+ * This file is part of the equanda project.
+ *
+ * The contents of this file are subject to the Mozilla Public License Version 1.1 (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.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis, WITHOUT WARRANTY OF
+ * ANY KIND, either express or implied. See the License for the specific language governing rights and
+ * limitations under the License.
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 2 or later (the "GPL"), or
+ * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
+ * in which case the provisions of the GPL or the LGPL are applicable instead
+ * of those above. If you wish to allow use of your version of this file only
+ * under the terms of either the GPL or the LGPL, and not to allow others to
+ * use your version of this file under the terms of the MPL, indicate your
+ * decision by deleting the provisions above and replace them with the notice
+ * and other provisions required by the GPL or the LGPL. If you do not delete
+ * the provisions above, a recipient may use your version of this file under
+ * the terms of any one of the MPL, the GPL or the LGPL.
+ */
+
+package org.equanda.persistence;
+
+import javax.persistence.Column;
+import javax.persistence.EmbeddedId;
+import javax.persistence.Version;
+import javax.persistence.MappedSuperclass;
+import java.sql.Timestamp;
+
+/**
+ * Base implementation for a equanda entity bean (DMFieldBean)
+ *
+ * @author <a href="mailto:jo...@pr...">Joachim Van der Auwera</a>
+ */
+@MappedSuperclass
+public class EquandaFieldBean
+{
+ // fields
+ protected UOID uoid;
+ protected Timestamp equandaCreation;
+
+ @EmbeddedId
+ public UOID getUOID()
+ { return uoid; }
+
+ public void setUOID( UOID uoid ) { this.uoid = uoid; }
+
+ @Version
+ @Column(
+ name = "EQUANDA_CREATION"
+ )
+ public Timestamp getEquandaCreationDate()
+ {
+ return equandaCreation;
+ }
+
+ public void setEquandaCreationDate( Timestamp created )
+ {
+ equandaCreation = created;
+ }
+}
Copied: trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaImportProxy.java (from rev 217, trunk/equanda-client/src/main/java/org/equanda/persistence/om/EquandaImportProxy.java)
===================================================================
--- trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaImportProxy.java (rev 0)
+++ trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaImportProxy.java 2007-12-28 23:21:37 UTC (rev 222)
@@ -0,0 +1,74 @@
+/**
+ * This file is part of the equanda project.
+ *
+ * The contents of this file are subject to the Mozilla Public License Version 1.1 (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.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis, WITHOUT WARRANTY OF
+ * ANY KIND, either express or implied. See the License for the specific language governing rights and
+ * limitations under the License.
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 2 or later (the "GPL"), or
+ * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
+ * in which case the provisions of the GPL or the LGPL are applicable instead
+ * of those above. If you wish to allow use of your version of this file only
+ * under the terms of either the GPL or the LGPL, and not to allow others to
+ * use your version of this file under the terms of the MPL, indicate your
+ * decision by deleting the provisions above and replace them with the notice
+ * and other provisions required by the GPL or the LGPL. If you do not delete
+ * the provisions above, a recipient may use your version of this file under
+ * the terms of any one of the MPL, the GPL or the LGPL.
+ */
+
+package org.equanda.persistence;
+
+/**
+ * Some extra mathods which are available in all importproxy objects
+ *
+ * @author <a href="mailto:jo...@pr...">Joachim Van der Auwera</a>
+ */
+public interface EquandaImportProxy
+{
+ void setUOID( UOID id );
+
+ void setUOID( String id );
+
+ boolean hasUOID();
+
+ String getEquandaType();
+
+ public UOID getUOID();
+
+ java.sql.Timestamp getEquandaModificationDate();
+
+ long getEquandaVersion();
+
+ boolean isEquandaModificationDateModified();
+
+ String getEquandaStatus();
+
+ void setEquandaStatus( String status );
+
+ String getEquandaName();
+
+ boolean isEquandaType( String type );
+
+ void setEquandaType( String type );
+
+ boolean isModified( boolean typeFieldsOnly );
+
+ boolean isModified();
+
+ void equandaUpdate()
+ throws EquandaPersistenceException;
+
+ void equandaUpdate( boolean updateTypeFieldsOnly )
+ throws EquandaPersistenceException;
+
+ void removeEntityBean()
+ throws EquandaPersistenceException;
+
+ void setEquandaUpdate( boolean update );
+}
Copied: trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaList.java (from rev 217, trunk/equanda-client/src/main/java/org/equanda/persistence/om/EquandaList.java)
===================================================================
--- trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaList.java (rev 0)
+++ trunk/equanda-client/src/main/java/org/equanda/persistence/EquandaList.java 2007-12-28 23:21:37 UTC (rev 222)
@@ -0,0 +1,533 @@
+/**
+ * This file is part of the equanda project.
+ *
+ * The contents of this file are subject to the Mozilla Public License Version 1.1 (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.mozilla.org/MPL/
+ *
+ * Software distributed under the License is distributed on an "AS IS" basis, WITHOUT WARRANTY OF
+ * ANY KIND, either express or implied. See the License for the specific language governing rights and
+ * limitations under the License.
+ *
+ * Alternatively, the contents of this file may be used under the terms of
+ * either the GNU General Public License Version 2 or later (the "GPL"), or
+ * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
+ * in which case the provisions of the GPL or the LGPL are applicable instead
+ * of those above. If you wish to allow use of your version of this file only
+ * under the terms of either the GPL or the LGPL, and not to allow others to
+ * use your version of this file under the terms of the MPL, indicate your
+ * decision by deleting the provisions above and replace them with the notice
+ * and other provisions required by the GPL or the LGPL. If you do not delete
+ * the provisions above, a recipient may use your version of this file under
+ * the terms of any one of the MPL, the GPL or the LGPL.
+ */
+
+package org.equanda.persistence;
+
+import javolution.lang.TextBuilder;
+
+import java.io.Serializable;
+import java.util.*;
+
+/**
+ * Simple list with "modified" detection support
+ *
+ * @author <a href="mailto:jo...@pr...">Joachim Van der Auwera</a>
+ * @author <a href="mailto:an...@pa...">Andrei Chiritescu</a>
+ */
+public class EquandaList<E>
+ implements List<E>, Serializable
+{
+ private static final long serialVersionUID = -3119090825066956438L;
+
+ protected List<ElementWrapper> list;
+ protected boolean proxySetterUsed =
+ false; // this is taken into consideration only where there are no object in the list or in the remove list (situation where we cannot know if the object was modified or not)
+ private Set<ElementWrapper> removeList = new HashSet<ElementWrapper>();
+
+ public EquandaList()
+ {
+ list = new ArrayList<ElementWrapper>();
+ }
+
+ EquandaList( List<ElementWrapper> base )
+ {
+ list = base;
+ }
+
+ public int size() { return list.size(); }
+
+ public boolean isEmpty() { return list.isEmpty(); }
+
+ public boolean contains( Object o ) { return indexOf( o ) >= 0; }
+
+ public Iterator<E> iterator() { return new CustomIterator( list.iterator() ); }
+
+ public Object[] toArray()
+ {
+ Object[] result = new Object[list.size()];
+ for ( int i = 0; i < list.size() ; i++ )
+ {
+ ElementWrapper ew = list.get( i );
+ result[ i ] = ew == null ? null : ew.element;
+ }
+ return result;
+ }
+
+ public <E> E[] toArray( E[] result )
+ {
+ int size = list.size();
+ if ( result.length < size )
+ {
+ result = (E[]) java.lang.reflect.Array.newInstance( result.getClass().getComponentType(), size );
+ }
+ for ( int i = 0; i < list.size() ; i++ )
+ {
+ ElementWrapper ew = list.get( i );
+ result[ i ] = ew == null ? null : (E) ew.element;
+ }
+ if ( result.length > size )
+ {
+ result[ size ] = null;
+ }
+ return result;
+ }
+
+ public boolean add( E element )
+ {
+ return _add( list.size(), element );
+ }
+
+ public void add( int index, E element )
+ {
+ _add( index, element );
+ }
+
+ private boolean _add( int index, E element )
+ {
+ ElementWrapper we = buildNewEW( element, true );
+ // if the element already exist in the list then just replace the element
+ int idx = we == null ? -1 : list.indexOf( we );
+ if ( idx >= 0 )
+ {
+ list.set( idx, we );
+ }
+ else
+ {
+ list.add( index, we );
+ //modified = true;
+ }
+ if ( we != null ) removeFromRemoveList( we );
+ return true;
+ }
+
+ public boolean addAll( Collection<? extends E> c )
+ {
+ boolean _modified = false;
+ for ( E element : c ) if ( add( element ) ) _modified = true;
+ return _modified;
+ }
+
+ public boolean addAll( int index, Collection<? extends E> c )
+ {
+ boolean _modified = false;
+ for ( E element : c ) if ( _add( index, element ) ) _modified = true;
+ return _modified;
+ }
+
+ public boolean remove( Object element )
+ {
+ ElementWrapper we = buildNewEW( (E) element, false );
+ boolean _modified = list.remove( we );
+ //if ( _modified ) modified = true;
+ if ( we != null ) removeList.add( we );
+ return _modified;
+ }
+
+ public E remove( int index )
+ {
+ ElementWrapper element = list.remove( index );
+ if ( element != null )
+ {
+ removeList.add( element );
+ //modified = true;
+ return element.element;
+ }
+ return null;
+ }
+
+ protected boolean _removeWrapper( ElementWrapper ew )
+ {
+ return ew != null && list.remove( ew ) && removeList.add( ew );
+ }
+
+ public boolean removeAll( Collection<?> c )
+ {
+ boolean _modified = false;
+ for ( Object element : c ) if ( remove( element ) ) _modified = true;
+ return _modified;
+ }
+
+ public boolean retainAll( Collection<?> c )
+ {
+ ArrayList<ElementWrapper> tmpRemoveList = new ArrayList<ElementWrapper>();
+ for ( ElementWrapper element : list ) if ( !c.contains( element.element ) ) tmpRemoveList.add( element );
+ for ( ElementWrapper element : tmpRemoveList ) _removeWrapper( element );
+ return !tmpRemoveList.isEmpty();
+ }
+
+ public boolean containsAll( Collection<?> c )
+ {
+ for ( Object o : c ) if ( !contains( o ) ) return false;
+ return true;
+ }
+
+ public void clear()
+ {
+ if ( !list.isEmpty() )
+ {
+ //modified = true;
+ for ( ElementWrapper element : list ) if ( element != null ) removeList.add( element );
+ list.clear();
+ }
+ }
+
+ public boolean equals( Object o )
+ {
+ if ( o == this ) return true;
+ if ( o == null || !( o instanceof List ) || ( (List) o ).size() != this.size() ) return false;
+ return this.containsAll( (List) o ) && ( (List) o ).containsAll( this );
+ }
+
+ public int hashCode() { return list.hashCode() + 37 * removeList.hashCode(); }
+
+ public E get( int index )
+ {
+ ElementWrapper element = list.get( index );
+ ...
[truncated message content] |