aboutsummaryrefslogtreecommitdiff
path: root/id/server/moa-id-commons
diff options
context:
space:
mode:
Diffstat (limited to 'id/server/moa-id-commons')
-rw-r--r--id/server/moa-id-commons/.classpath38
-rw-r--r--id/server/moa-id-commons/.gitignore1
-rw-r--r--id/server/moa-id-commons/.project37
-rw-r--r--id/server/moa-id-commons/.settings/org.eclipse.core.resources.prefs5
-rw-r--r--id/server/moa-id-commons/.settings/org.eclipse.jdt.core.prefs5
-rw-r--r--id/server/moa-id-commons/.settings/org.eclipse.jpt.core.prefs3
-rw-r--r--id/server/moa-id-commons/.settings/org.eclipse.m2e.core.prefs4
-rw-r--r--id/server/moa-id-commons/.settings/org.eclipse.wst.common.component7
-rw-r--r--id/server/moa-id-commons/.settings/org.eclipse.wst.common.project.facet.core.prefs.xml7
-rw-r--r--id/server/moa-id-commons/.settings/org.eclipse.wst.common.project.facet.core.xml6
-rw-r--r--id/server/moa-id-commons/.settings/org.eclipse.wst.validation.prefs2
-rw-r--r--id/server/moa-id-commons/pom.xml4
-rw-r--r--id/server/moa-id-commons/src/main/java/at/gv/egovernment/moa/id/commons/xjc/JaxbBooleanAdapter.java59
13 files changed, 176 insertions, 2 deletions
diff --git a/id/server/moa-id-commons/.classpath b/id/server/moa-id-commons/.classpath
new file mode 100644
index 000000000..a6c84d0a8
--- /dev/null
+++ b/id/server/moa-id-commons/.classpath
@@ -0,0 +1,38 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+ <classpathentry kind="src" output="target/classes" path="src/main/java">
+ <attributes>
+ <attribute name="optional" value="true"/>
+ <attribute name="maven.pomderived" value="true"/>
+ </attributes>
+ </classpathentry>
+ <classpathentry kind="src" output="target/test-classes" path="src/test/java">
+ <attributes>
+ <attribute name="optional" value="true"/>
+ <attribute name="maven.pomderived" value="true"/>
+ </attributes>
+ </classpathentry>
+ <classpathentry including="**/*.java" kind="src" path="target/generated-sources/xjc"/>
+ <classpathentry excluding="**" kind="src" output="target/classes" path="src/main/resources/config">
+ <attributes>
+ <attribute name="maven.pomderived" value="true"/>
+ </attributes>
+ </classpathentry>
+ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/J2SE-1.5">
+ <attributes>
+ <attribute name="maven.pomderived" value="true"/>
+ </attributes>
+ </classpathentry>
+ <classpathentry kind="con" path="org.eclipse.m2e.MAVEN2_CLASSPATH_CONTAINER">
+ <attributes>
+ <attribute name="maven.pomderived" value="true"/>
+ <attribute name="org.eclipse.jst.component.nondependency" value=""/>
+ </attributes>
+ </classpathentry>
+ <classpathentry excluding="**" kind="src" output="target/test-classes" path="src/test/resources">
+ <attributes>
+ <attribute name="maven.pomderived" value="true"/>
+ </attributes>
+ </classpathentry>
+ <classpathentry kind="output" path="target/classes"/>
+</classpath>
diff --git a/id/server/moa-id-commons/.gitignore b/id/server/moa-id-commons/.gitignore
new file mode 100644
index 000000000..ea8c4bf7f
--- /dev/null
+++ b/id/server/moa-id-commons/.gitignore
@@ -0,0 +1 @@
+/target
diff --git a/id/server/moa-id-commons/.project b/id/server/moa-id-commons/.project
new file mode 100644
index 000000000..a7c3725f2
--- /dev/null
+++ b/id/server/moa-id-commons/.project
@@ -0,0 +1,37 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+ <name>moa-id-commons</name>
+ <comment></comment>
+ <projects>
+ <project>moa-common</project>
+ </projects>
+ <buildSpec>
+ <buildCommand>
+ <name>org.eclipse.wst.common.project.facet.core.builder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.eclipse.jdt.core.javabuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.eclipse.wst.validation.validationbuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.eclipse.m2e.core.maven2Builder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ </buildSpec>
+ <natures>
+ <nature>org.eclipse.m2e.core.maven2Nature</nature>
+ <nature>org.eclipse.jem.workbench.JavaEMFNature</nature>
+ <nature>org.eclipse.wst.common.modulecore.ModuleCoreNature</nature>
+ <nature>org.eclipse.jdt.core.javanature</nature>
+ <nature>org.eclipse.wst.common.project.facet.core.nature</nature>
+ </natures>
+</projectDescription>
diff --git a/id/server/moa-id-commons/.settings/org.eclipse.core.resources.prefs b/id/server/moa-id-commons/.settings/org.eclipse.core.resources.prefs
new file mode 100644
index 000000000..95c6d7ddd
--- /dev/null
+++ b/id/server/moa-id-commons/.settings/org.eclipse.core.resources.prefs
@@ -0,0 +1,5 @@
+eclipse.preferences.version=1
+encoding//src/main/resources=UTF-8
+encoding//src/main/resources/config=UTF-8
+encoding//src/test/resources=UTF-8
+encoding/<project>=UTF-8
diff --git a/id/server/moa-id-commons/.settings/org.eclipse.jdt.core.prefs b/id/server/moa-id-commons/.settings/org.eclipse.jdt.core.prefs
new file mode 100644
index 000000000..abec6ca38
--- /dev/null
+++ b/id/server/moa-id-commons/.settings/org.eclipse.jdt.core.prefs
@@ -0,0 +1,5 @@
+eclipse.preferences.version=1
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5
+org.eclipse.jdt.core.compiler.compliance=1.5
+org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning
+org.eclipse.jdt.core.compiler.source=1.5
diff --git a/id/server/moa-id-commons/.settings/org.eclipse.jpt.core.prefs b/id/server/moa-id-commons/.settings/org.eclipse.jpt.core.prefs
new file mode 100644
index 000000000..3e2d23923
--- /dev/null
+++ b/id/server/moa-id-commons/.settings/org.eclipse.jpt.core.prefs
@@ -0,0 +1,3 @@
+eclipse.preferences.version=1
+org.eclipse.jpt.core.platform=generic
+org.eclipse.jpt.jpa.core.discoverAnnotatedClasses=true
diff --git a/id/server/moa-id-commons/.settings/org.eclipse.m2e.core.prefs b/id/server/moa-id-commons/.settings/org.eclipse.m2e.core.prefs
new file mode 100644
index 000000000..f897a7f1c
--- /dev/null
+++ b/id/server/moa-id-commons/.settings/org.eclipse.m2e.core.prefs
@@ -0,0 +1,4 @@
+activeProfiles=
+eclipse.preferences.version=1
+resolveWorkspaceProjects=true
+version=1
diff --git a/id/server/moa-id-commons/.settings/org.eclipse.wst.common.component b/id/server/moa-id-commons/.settings/org.eclipse.wst.common.component
new file mode 100644
index 000000000..9e5e3ed1c
--- /dev/null
+++ b/id/server/moa-id-commons/.settings/org.eclipse.wst.common.component
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?><project-modules id="moduleCoreId" project-version="1.5.0">
+ <wb-module deploy-name="moa-id-commons">
+ <wb-resource deploy-path="/" source-path="/src/main/java"/>
+ <wb-resource deploy-path="/" source-path="/target/generated-sources/xjc"/>
+ <wb-resource deploy-path="/" source-path="/src/main/resources/config"/>
+ </wb-module>
+</project-modules>
diff --git a/id/server/moa-id-commons/.settings/org.eclipse.wst.common.project.facet.core.prefs.xml b/id/server/moa-id-commons/.settings/org.eclipse.wst.common.project.facet.core.prefs.xml
new file mode 100644
index 000000000..7961132fd
--- /dev/null
+++ b/id/server/moa-id-commons/.settings/org.eclipse.wst.common.project.facet.core.prefs.xml
@@ -0,0 +1,7 @@
+<root>
+ <facet id="jpt.jpa">
+ <node name="libprov">
+ <attribute name="provider-id" value="jpa-no-op-library-provider"/>
+ </node>
+ </facet>
+</root>
diff --git a/id/server/moa-id-commons/.settings/org.eclipse.wst.common.project.facet.core.xml b/id/server/moa-id-commons/.settings/org.eclipse.wst.common.project.facet.core.xml
new file mode 100644
index 000000000..8956fb143
--- /dev/null
+++ b/id/server/moa-id-commons/.settings/org.eclipse.wst.common.project.facet.core.xml
@@ -0,0 +1,6 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<faceted-project>
+ <installed facet="java" version="1.5"/>
+ <installed facet="jst.utility" version="1.0"/>
+ <installed facet="jpt.jpa" version="1.0"/>
+</faceted-project>
diff --git a/id/server/moa-id-commons/.settings/org.eclipse.wst.validation.prefs b/id/server/moa-id-commons/.settings/org.eclipse.wst.validation.prefs
new file mode 100644
index 000000000..04cad8cb7
--- /dev/null
+++ b/id/server/moa-id-commons/.settings/org.eclipse.wst.validation.prefs
@@ -0,0 +1,2 @@
+disabled=06target
+eclipse.preferences.version=1
diff --git a/id/server/moa-id-commons/pom.xml b/id/server/moa-id-commons/pom.xml
index 4b2ae6536..b49f438cf 100644
--- a/id/server/moa-id-commons/pom.xml
+++ b/id/server/moa-id-commons/pom.xml
@@ -239,7 +239,7 @@
</executions>
</plugin> -->
- <plugin>
+<!-- <plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>properties-maven-plugin</artifactId>
<version>1.0-alpha-2</version>
@@ -256,7 +256,7 @@
</configuration>
</execution>
</executions>
- </plugin>
+ </plugin> -->
<!--This plugin's configuration is used to store Eclipse m2e settings only. It has no influence on the Maven build itself.-->
<plugin>
diff --git a/id/server/moa-id-commons/src/main/java/at/gv/egovernment/moa/id/commons/xjc/JaxbBooleanAdapter.java b/id/server/moa-id-commons/src/main/java/at/gv/egovernment/moa/id/commons/xjc/JaxbBooleanAdapter.java
new file mode 100644
index 000000000..c1c841282
--- /dev/null
+++ b/id/server/moa-id-commons/src/main/java/at/gv/egovernment/moa/id/commons/xjc/JaxbBooleanAdapter.java
@@ -0,0 +1,59 @@
+/*
+ * Copyright 2014 Federal Chancellery Austria
+ * MOA-ID has been developed in a cooperation between BRZ, the Federal
+ * Chancellery Austria - ICT staff unit, and Graz University of Technology.
+ *
+ * Licensed under the EUPL, Version 1.1 or - as soon they will be approved by
+ * the European Commission - subsequent versions of the EUPL (the "Licence");
+ * You may not use this work except in compliance with the Licence.
+ * You may obtain a copy of the Licence at:
+ * http://www.osor.eu/eupl/
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the Licence is distributed on an "AS IS" basis,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the Licence for the specific language governing permissions and
+ * limitations under the Licence.
+ *
+ * This product combines work with different licenses. See the "NOTICE" text
+ * file for details on the various modules and licenses.
+ * The "NOTICE" text file is part of the distribution. Any derivative works
+ * that you distribute must include a readable copy of the "NOTICE" text file.
+ */
+package at.gv.egovernment.moa.id.commons.xjc;
+
+/**
+ * @author tlenz
+ *
+ */
+import javax.xml.bind.annotation.adapters.XmlAdapter;
+
+/**
+ * Utility class to correctly render the xml types used in JAXB.
+ */
+public class JaxbBooleanAdapter extends XmlAdapter<String, Boolean>
+{
+ @Override
+ public Boolean unmarshal(String v) throws Exception
+ {
+ if ("1".equals(v))
+ {
+ return true;
+ }
+ return false;
+ }
+
+ @Override
+ public String marshal(Boolean v) throws Exception
+ {
+ if (v == null)
+ {
+ return null;
+ }
+ if (v)
+ {
+ return "1";
+ }
+ return "0";
+ }
+}