authentication-mechanism xsd type
+ * @author Ralf Battenfeld
+ * @author Andrew Lee Rubinger
+ */
+public interface AuthenticationMechanism {
+
+ public AuthenticationMechanism authenticationMechanismType(String authenticationMechanismType);
+ public String getAuthenticationMechanismType();
+ public AuthenticationMechanism removeAuthenticationMechanismType();
+
+ public AuthenticationMechanism description(String description);
+ public String getDescription();
+ public AuthenticationMechanism removeDescription();
+
+ public AuthenticationMechanism credentialInterface(String credentialInterface);
+ public String getCredentialInterface();
+ public AuthenticationMechanism removeCredentialInterface();
+}
diff --git a/api-javaee-prototype/src/main/java/org/jboss/shrinkwrap/descriptor/api/connector10/ConfigProperty.java b/api-javaee-prototype/src/main/java/org/jboss/shrinkwrap/descriptor/api/connector10/ConfigProperty.java
new file mode 100644
index 00000000..c4deeece
--- /dev/null
+++ b/api-javaee-prototype/src/main/java/org/jboss/shrinkwrap/descriptor/api/connector10/ConfigProperty.java
@@ -0,0 +1,27 @@
+package org.jboss.shrinkwrap.descriptor.api.connector10;
+
+/**
+ * This interface defines the contract for the config-property xsd type
+ * @author Ralf Battenfeld
+ * @author Andrew Lee Rubinger
+ */
+public interface ConfigProperty {
+
+ public ConfigProperty configPropertyValue(String configPropertyValue);
+ public String getConfigPropertyValue();
+ public ConfigProperty removeConfigPropertyValue();
+
+ public ConfigProperty description(String description);
+ public String getDescription();
+ public ConfigProperty removeDescription();
+
+
+ public ConfigProperty configPropertyName(String configPropertyName);
+ public String getConfigPropertyName();
+ public ConfigProperty removeConfigPropertyName();
+
+
+ public ConfigProperty configPropertyType(String configPropertyType);
+ public String getConfigPropertyType();
+ public ConfigProperty removeConfigPropertyType();
+}
diff --git a/api-javaee-prototype/src/main/java/org/jboss/shrinkwrap/descriptor/api/connector10/ConnectorDescriptor.java b/api-javaee-prototype/src/main/java/org/jboss/shrinkwrap/descriptor/api/connector10/ConnectorDescriptor.java
new file mode 100644
index 00000000..f2db5523
--- /dev/null
+++ b/api-javaee-prototype/src/main/java/org/jboss/shrinkwrap/descriptor/api/connector10/ConnectorDescriptor.java
@@ -0,0 +1,45 @@
+package org.jboss.shrinkwrap.descriptor.api.connector10;
+
+import org.jboss.shrinkwrap.descriptor.api.Descriptor;
+import org.jboss.shrinkwrap.descriptor.api.DescriptorNamespace;
+
+public interface ConnectorDescriptor extends Descriptor, DescriptorNamespace icon xsd type
+ *
+ * @author Ralf Battenfeld
+ * @author Andrew Lee Rubinger
+ */
+public interface Icon {
+
+ public Icon smallIcon(String smallIcon);
+ public String getSmallIcon();
+ public Icon removeSmallIcon();
+
+ public Icon largeIcon(String largeIcon);
+ public String getLargeIcon();
+ public Icon removeLargeIcon();
+}
diff --git a/api-javaee-prototype/src/main/java/org/jboss/shrinkwrap/descriptor/api/connector10/License.java b/api-javaee-prototype/src/main/java/org/jboss/shrinkwrap/descriptor/api/connector10/License.java
new file mode 100644
index 00000000..23df90ae
--- /dev/null
+++ b/api-javaee-prototype/src/main/java/org/jboss/shrinkwrap/descriptor/api/connector10/License.java
@@ -0,0 +1,17 @@
+package org.jboss.shrinkwrap.descriptor.api.connector10;
+
+/**
+ * This interface defines the contract for the license xsd type
+ * @author Ralf Battenfeld
+ * @author Andrew Lee Rubinger
+ */
+public interface License {
+
+ public License description(String description);
+ public String getDescription();
+ public License removeDescription();
+
+ public License licenseRequired(String licenseRequired);
+ public String getLicenseRequired();
+ public License removeLicenseRequired();
+}
diff --git a/api-javaee-prototype/src/main/java/org/jboss/shrinkwrap/descriptor/api/connector10/Resourceadapter.java b/api-javaee-prototype/src/main/java/org/jboss/shrinkwrap/descriptor/api/connector10/Resourceadapter.java
new file mode 100644
index 00000000..b94add3b
--- /dev/null
+++ b/api-javaee-prototype/src/main/java/org/jboss/shrinkwrap/descriptor/api/connector10/Resourceadapter.java
@@ -0,0 +1,54 @@
+package org.jboss.shrinkwrap.descriptor.api.connector10;
+
+import java.util.List;
+
+/**
+ * This interface defines the contract for the resourceadapter
+ * xsd type
+ *
+ * @author Ralf Battenfeld
+ * @author Andrew Lee Rubinger
+ */
+public interface Resourceadapter {
+
+ public Resourceadapter connectionInterface(String connectionInterface);
+ public String getConnectionInterface();
+ public Resourceadapter removeConnectionInterface();
+
+ public Resourceadapter addConfigProperty(final ConfigProperty configProperty);
+ public List security-permission xsd type
+ * @author Ralf Battenfeld
+ * @author Andrew Lee Rubinger
+ */
+public interface SecurityPermission {
+
+ public SecurityPermission securityPermissionSpec(String securityPermissionSpec);
+ public String getSecurityPermissionSpec();
+ public SecurityPermission removeSecurityPermissionSpec();
+
+ public SecurityPermission description(String description);
+ public String getDescription();
+ public SecurityPermission removeDescription();
+}
diff --git a/api-javaee-prototype/src/main/java/org/jboss/shrinkwrap/descriptor/api/connector10/package-info.java b/api-javaee-prototype/src/main/java/org/jboss/shrinkwrap/descriptor/api/connector10/package-info.java
new file mode 100644
index 00000000..e272bab7
--- /dev/null
+++ b/api-javaee-prototype/src/main/java/org/jboss/shrinkwrap/descriptor/api/connector10/package-info.java
@@ -0,0 +1,5 @@
+ /**
+ * Provides the interfaces and enumeration types as defined in the schema
+ */
+
+package org.jboss.shrinkwrap.descriptor.api.connector10;
diff --git a/impl-javaee-prototype/src/main/java/org/jboss/shrinkwrap/descriptor/impl/connector10/ChildNodeInitializer.java b/impl-javaee-prototype/src/main/java/org/jboss/shrinkwrap/descriptor/impl/connector10/ChildNodeInitializer.java
new file mode 100644
index 00000000..69d65743
--- /dev/null
+++ b/impl-javaee-prototype/src/main/java/org/jboss/shrinkwrap/descriptor/impl/connector10/ChildNodeInitializer.java
@@ -0,0 +1,10 @@
+package org.jboss.shrinkwrap.descriptor.impl.connector10;
+
+import org.jboss.shrinkwrap.descriptor.spi.node.Node;
+
+public interface ChildNodeInitializer {
+
+ public void initialize(String nodeName, Node node);
+
+ public void assign(String nodeName, Node node);
+}
diff --git a/impl-javaee-prototype/src/main/java/org/jboss/shrinkwrap/descriptor/impl/connector10/ConfigPropertyImpl.java b/impl-javaee-prototype/src/main/java/org/jboss/shrinkwrap/descriptor/impl/connector10/ConfigPropertyImpl.java
new file mode 100644
index 00000000..829cd1ec
--- /dev/null
+++ b/impl-javaee-prototype/src/main/java/org/jboss/shrinkwrap/descriptor/impl/connector10/ConfigPropertyImpl.java
@@ -0,0 +1,175 @@
+package org.jboss.shrinkwrap.descriptor.impl.connector10;
+
+import org.jboss.shrinkwrap.descriptor.api.connector10.ConfigProperty;
+import org.jboss.shrinkwrap.descriptor.spi.node.Node;
+
+/**
+ * This class implements the config-property xsd type
+ *
+ * @author Ralf Battenfeld
+ * @author Andrew Lee Rubinger
+ */
+public class ConfigPropertyImpl implements ConfigProperty, ChildNodeInitializer {
+ private boolean isDetached = true;
+ private Node detachedNode;
+ private Node childNode;
+
+ public void initialize(String nodeName, Node node) {
+ if (isDetached) {
+ if (detachedNode != null) {
+ childNode = node.createChild(nodeName);
+ Node.copyFromTo(detachedNode, childNode); // setters already called
+ } else {
+ childNode = node.createChild(nodeName); // just created no setters called
+ }
+ isDetached = false;
+ } else {
+ throw new IllegalArgumentException();
+ }
+ }
+
+ public void assign(String nodeName, Node node) {
+ childNode = node;
+ isDetached = false;
+ }
+
+
+ /**
+ * Sets the config-property-value element
+ *
+ * @param configPropertyValue
+ * the value for the element config-property-value
+ * @return the current instance of ConfigProperty
+ */
+ public ConfigProperty configPropertyValue(String configPropertyValue) {
+ getNode().getOrCreate("config-property-value").text(configPropertyValue);
+ return this;
+ }
+
+ /**
+ * Returns the config-property-value element
+ *
+ * @return the node defined for the element
+ * config-property-value
+ */
+ public String getConfigPropertyValue() {
+ return getNode().getTextValueForPatternName("config-property-value");
+ }
+
+ /**
+ * Removes the config-property-value element
+ *
+ * @return the current instance of ConfigProperty
+ */
+ public ConfigProperty removeConfigPropertyValue() {
+ getNode().removeChildren("config-property-value");
+ return this;
+ }
+
+ /**
+ * Sets the description element
+ *
+ * @param description
+ * the value for the element description
+ * @return the current instance of ConfigProperty
+ */
+ public ConfigProperty description(String description) {
+ getNode().getOrCreate("description").text(description);
+ return this;
+ }
+
+ /**
+ * Returns the description element
+ *
+ * @return the node defined for the element description
+ */
+ public String getDescription() {
+ return getNode().getTextValueForPatternName("description");
+ }
+
+ /**
+ * Removes the description element
+ *
+ * @return the current instance of ConfigProperty
+ */
+ public ConfigProperty removeDescription() {
+ getNode().removeChildren("description");
+ return this;
+ }
+
+ /**
+ * Sets the config-property-name element
+ *
+ * @param configPropertyName
+ * the value for the element config-property-name
+ * @return the current instance of ConfigProperty
+ */
+ public ConfigProperty configPropertyName(String configPropertyName) {
+ getNode().getOrCreate("config-property-name").text(configPropertyName);
+ return this;
+ }
+
+ /**
+ * Returns the config-property-name element
+ *
+ * @return the node defined for the element
+ * config-property-name
+ */
+ public String getConfigPropertyName() {
+ return getNode().getTextValueForPatternName("config-property-name");
+ }
+
+ /**
+ * Removes the config-property-name element
+ *
+ * @return the current instance of ConfigProperty
+ */
+ public ConfigProperty removeConfigPropertyName() {
+ getNode().removeChildren("config-property-name");
+ return this;
+ }
+
+ /**
+ * Sets the config-property-type element
+ *
+ * @param configPropertyType
+ * the value for the element config-property-type
+ * @return the current instance of ConfigProperty
+ */
+ public ConfigProperty configPropertyType(String configPropertyType) {
+ getNode().getOrCreate("config-property-type").text(configPropertyType);
+ return this;
+ }
+
+ /**
+ * Returns the config-property-type element
+ *
+ * @return the node defined for the element
+ * config-property-type
+ */
+ public String getConfigPropertyType() {
+ return getNode().getTextValueForPatternName("config-property-type");
+ }
+
+ /**
+ * Removes the config-property-type element
+ *
+ * @return the current instance of ConfigProperty
+ */
+ public ConfigProperty removeConfigPropertyType() {
+ getNode().removeChildren("config-property-type");
+ return this;
+ }
+
+ private Node getNode() {
+ if (!isDetached) {
+ return childNode;
+ }
+
+ if (detachedNode == null) {
+ detachedNode = new Node("DetachedNode");
+ }
+
+ return detachedNode;
+ }
+}
diff --git a/impl-javaee-prototype/src/main/java/org/jboss/shrinkwrap/descriptor/impl/connector10/ConnectorDescriptorImpl.java b/impl-javaee-prototype/src/main/java/org/jboss/shrinkwrap/descriptor/impl/connector10/ConnectorDescriptorImpl.java
new file mode 100644
index 00000000..7b1680cf
--- /dev/null
+++ b/impl-javaee-prototype/src/main/java/org/jboss/shrinkwrap/descriptor/impl/connector10/ConnectorDescriptorImpl.java
@@ -0,0 +1,168 @@
+package org.jboss.shrinkwrap.descriptor.impl.connector10;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import org.jboss.shrinkwrap.descriptor.api.DescriptorNamespace;
+import org.jboss.shrinkwrap.descriptor.api.connector10.ConnectorDescriptor;
+import org.jboss.shrinkwrap.descriptor.api.connector10.Factory;
+import org.jboss.shrinkwrap.descriptor.api.connector10.Icon;
+import org.jboss.shrinkwrap.descriptor.api.connector10.License;
+import org.jboss.shrinkwrap.descriptor.api.connector10.Resourceadapter;
+import org.jboss.shrinkwrap.descriptor.spi.node.Node;
+import org.jboss.shrinkwrap.descriptor.spi.node.NodeDescriptorImplBase;
+
+/**
+ * + * This deployment descriptor provides the functionalities as described in the + * specification + *
+ * Example: + *
+ *
+ * ConnectorDescriptor descriptor = Descriptors.create(ConnectorDescriptor.class);
+ *
+ *
+ *
+ * @author Ralf Battenfeld
+ * @author Andrew Lee Rubinger
+ */
+public class ConnectorDescriptorImpl extends NodeDescriptorImplBase implements
+ DescriptorNamespaceConnectorDescriptor
+ */
+ public ConnectorDescriptor addDefaultNamespaces() {
+ return this;
+ }
+
+ /**
+ * Adds a new namespace
+ *
+ * @return the current instance of ConnectorDescriptor
+ */
+ public ConnectorDescriptor addNamespace(String name, String value) {
+ model.attribute(name, value);
+ return this;
+ }
+
+ /**
+ * Returns all defined namespaces.
+ *
+ * @return all defined namespaces
+ */
+ public ListConnectorDescriptor
+ */
+ public ConnectorDescriptor removeAllNamespaces() {
+ List resourceadapter xsd type
+ *
+ * @author Ralf Battenfeld
+ * @author Andrew Lee Rubinger
+ */
+public class ResourceadapterImpl implements Resourceadapter, ChildNodeInitializer {
+ private boolean isDetached = true;
+ private Node detachedNode;
+ private Node childNode;
+
+ public void initialize(String nodeName, Node node) {
+ if (isDetached) {
+ if (detachedNode != null) {
+ childNode = node.createChild(nodeName);
+ Node.copyFromTo(detachedNode, childNode); // setters already called
+ } else {
+ childNode = node.createChild(nodeName); // just created no setters called
+ }
+ isDetached = false;
+ } else {
+ throw new IllegalArgumentException();
+ }
+ }
+
+ public void assign(String nodeName, Node node) {
+ childNode = node;
+ isDetached = false;
+ }
+
+ /**
+ * Creates a new config-property element
+ *
+ * @return the new created instance of ConfigProperty
+ */
+ public Resourceadapter addConfigProperty(ConfigProperty configProperty) {
+ if (configProperty instanceof ChildNodeInitializer) {
+ ((ChildNodeInitializer)configProperty).initialize("config-property", getNode());
+ }
+ return this;
+ }
+
+ /**
+ * Returns all config-property elements
+ *
+ * @return list of config-property
+ */
+ public Listconfig-property elements
+ *
+ * @return the current instance of ConfigProperty
+ */
+ public Resourceadapter removeAllConfigProperty() {
+ getNode().removeChildren("config-property");
+ return this;
+ }
+
+ private Node getNode() {
+ if (!isDetached) {
+ return childNode;
+ }
+
+ if (detachedNode == null) {
+ detachedNode = new Node("DetachedNode");
+ }
+
+ return detachedNode;
+ }
+
+ //-----------------------------------------------------------------------||
+ //-- TransactionSupport -------------------------------------------------||
+ //-----------------------------------------------------------------------||
+
+ @Override
+ public Resourceadapter transactionSupport(String transactionSupport) {
+ childNode.getOrCreate("transaction-support").text(transactionSupport);
+ return this;
+ }
+
+ @Override
+ public String getTransactionSupport() {
+ return childNode.getTextValueForPatternName("transaction-support");
+ }
+
+ @Override
+ public Resourceadapter removeTransactionSupport() {
+ childNode.removeChildren("transaction-support");
+ return this;
+ }
+
+ //-----------------------------------------------------------------------||
+ //-- ConnectionFactory -------------------------------------------------||
+ //-----------------------------------------------------------------------||
+
+ @Override
+ public Resourceadapter connectionfactoryImplClass(String connectionfactoryImplClass) {
+ childNode.getOrCreate("connectionfactory-impl-class").text(connectionfactoryImplClass);
+ return this;
+ }
+
+ @Override
+ public String getConnectionfactoryImplClass() {
+ return childNode.getTextValueForPatternName("connectionfactory-impl-class");
+ }
+
+ @Override
+ public Resourceadapter removeConnectionfactoryImplClass() {
+ childNode.removeChildren("connectionfactory-impl-class");
+ return this;
+ }
+
+ //-----------------------------------------------------------------------||
+ //-- ConnectionImplClass ------------------------------------------------||
+ //-----------------------------------------------------------------------||
+
+ @Override
+ public Resourceadapter connectionImplClass(String connectionImplClass) {
+ childNode.getOrCreate("connection-impl-class").text(connectionImplClass);
+ return this;
+ }
+
+ @Override
+ public String getConnectionImplClass() {
+ return childNode.getTextValueForPatternName("connection-impl-class");
+ }
+
+ @Override
+ public Resourceadapter removeConnectionImplClass() {
+ childNode.removeChildren("connection-impl-class");
+ return this;
+ }
+
+ //-----------------------------------------------------------------------||
+ //-- ConnectionInterface ------------------------------------------------||
+ //-----------------------------------------------------------------------||
+
+ @Override
+ public Resourceadapter connectionInterface(String connectionInterface) {
+ childNode.getOrCreate("connection-interface").text(connectionInterface);
+ return this;
+ }
+
+ @Override
+ public String getConnectionInterface() {
+ return childNode.getTextValueForPatternName("connection-interface");
+ }
+
+ @Override
+ public Resourceadapter removeConnectionInterface() {
+ childNode.removeChildren("connection-interface");
+ return this;
+ }
+
+ //-----------------------------------------------------------------------||
+ //-- ConnectionInterface ------------------------------------------------||
+ //-----------------------------------------------------------------------||
+
+ @Override
+ public Resourceadapter connectionfactoryInterface(String connectionfactoryInterface) {
+ childNode.getOrCreate("connectionfactory-interface").text(connectionfactoryInterface);
+ return this;
+ }
+
+ @Override
+ public String getConnectionfactoryInterface() {
+ return childNode.getTextValueForPatternName("connectionfactory-interface");
+ }
+
+ @Override
+ public Resourceadapter removeConnectionfactoryInterface() {
+ childNode.removeChildren("connectionfactory-interface");
+ return this;
+ }
+
+ //-----------------------------------------------------------------------||
+ //-- ReauthenticationSupport --------------------------------------------||
+ //-----------------------------------------------------------------------||
+
+ @Override
+ public Resourceadapter reauthenticationSupport(String reauthenticationSupport) {
+ childNode.getOrCreate("reauthentication-support").text(reauthenticationSupport);
+ return this;
+ }
+
+ @Override
+ public String getReauthenticationSupport() {
+ return childNode.getTextValueForPatternName("reauthentication-support");
+ }
+
+ @Override
+ public Resourceadapter removeReauthenticationSupport() {
+ childNode.removeChildren("reauthentication-support");
+ return this;
+ }
+
+ //-----------------------------------------------------------------------||
+ //-- ManagedconnectionfactoryClass --------------------------------------||
+ //-----------------------------------------------------------------------||
+
+ @Override
+ public Resourceadapter managedconnectionfactoryClass(String managedconnectionfactoryClass) {
+ childNode.getOrCreate("managedconnectionfactory-class").text(managedconnectionfactoryClass);
+ return this;
+ }
+
+ @Override
+ public String getManagedconnectionfactoryClass() {
+ return childNode.getTextValueForPatternName("managedconnectionfactory-class");
+ }
+
+ @Override
+ public Resourceadapter removeManagedconnectionfactoryClass() {
+ childNode.removeChildren("managedconnectionfactory-class");
+ return this;
+ }
+}
diff --git a/impl-javaee-prototype/src/main/java/org/jboss/shrinkwrap/descriptor/impl/connector10/decorators/ConcreteConfigPropertyImpl.java b/impl-javaee-prototype/src/main/java/org/jboss/shrinkwrap/descriptor/impl/connector10/decorators/ConcreteConfigPropertyImpl.java
new file mode 100644
index 00000000..750b5202
--- /dev/null
+++ b/impl-javaee-prototype/src/main/java/org/jboss/shrinkwrap/descriptor/impl/connector10/decorators/ConcreteConfigPropertyImpl.java
@@ -0,0 +1,64 @@
+package org.jboss.shrinkwrap.descriptor.impl.connector10.decorators;
+
+import org.jboss.shrinkwrap.descriptor.api.connector10.ConfigProperty;
+
+/**
+ * This class implements the config-property xsd type
+ *
+ * @author Ralf Battenfeld
+ * @author Andrew Lee Rubinger
+ */
+public class ConcreteConfigPropertyImpl extends ConfigfPropertyDecorator {
+
+ public ConcreteConfigPropertyImpl(ConfigProperty configProperty) {
+ super(configProperty);
+ }
+
+ public ConfigProperty configPropertyValue(String configPropertyValue) {
+ return configProperty.configPropertyValue(configPropertyValue);
+ }
+
+ public String getConfigPropertyValue() {
+ return configProperty.getConfigPropertyValue();
+ }
+
+ public ConfigProperty removeConfigPropertyValue() {
+ return configProperty.removeConfigPropertyValue();
+ }
+
+ public ConfigProperty description(String description) {
+ return configProperty.description(description);
+ }
+
+ public String getDescription() {
+ return configProperty.getDescription();
+ }
+
+ public ConfigProperty removeDescription() {
+ return configProperty.removeDescription();
+ }
+
+ public ConfigProperty configPropertyName(String configPropertyName) {
+ return configProperty.configPropertyName(configPropertyName);
+ }
+
+ public String getConfigPropertyName() {
+ return configProperty.getConfigPropertyName();
+ }
+
+ public ConfigProperty removeConfigPropertyName() {
+ return configProperty.removeConfigPropertyName();
+ }
+
+ public ConfigProperty configPropertyType(String configPropertyType) {
+ return configProperty.configPropertyType(configPropertyType);
+ }
+
+ public String getConfigPropertyType() {
+ return configProperty.getConfigPropertyType();
+ }
+
+ public ConfigProperty removeConfigPropertyType() {
+ return configProperty.removeConfigPropertyType();
+ }
+}
diff --git a/impl-javaee-prototype/src/main/java/org/jboss/shrinkwrap/descriptor/impl/connector10/decorators/ConfigfPropertyDecorator.java b/impl-javaee-prototype/src/main/java/org/jboss/shrinkwrap/descriptor/impl/connector10/decorators/ConfigfPropertyDecorator.java
new file mode 100644
index 00000000..0fece138
--- /dev/null
+++ b/impl-javaee-prototype/src/main/java/org/jboss/shrinkwrap/descriptor/impl/connector10/decorators/ConfigfPropertyDecorator.java
@@ -0,0 +1,23 @@
+package org.jboss.shrinkwrap.descriptor.impl.connector10.decorators;
+
+import org.jboss.shrinkwrap.descriptor.api.connector10.ConfigProperty;
+import org.jboss.shrinkwrap.descriptor.impl.connector10.ChildNodeInitializer;
+import org.jboss.shrinkwrap.descriptor.spi.node.Node;
+
+
+public abstract class ConfigfPropertyDecorator implements ConfigProperty, ChildNodeInitializer {
+ protected ConfigProperty configProperty;
+ protected Node childNode;
+
+ public ConfigfPropertyDecorator (ConfigProperty configProperty) {
+ this.configProperty = configProperty;
+ }
+
+ public void initialize(String nodeName, Node node) {
+ this.childNode = node.createChild(nodeName);
+ }
+
+ public void assign(String nodeName, Node node) {
+ this.childNode = node;
+ }
+}
diff --git a/impl-javaee-prototype/src/main/resources/META-INF/services/org.jboss.shrinkwrap.descriptor.api.connector10.ConnectorDescriptor b/impl-javaee-prototype/src/main/resources/META-INF/services/org.jboss.shrinkwrap.descriptor.api.connector10.ConnectorDescriptor
new file mode 100644
index 00000000..5bd7e38c
--- /dev/null
+++ b/impl-javaee-prototype/src/main/resources/META-INF/services/org.jboss.shrinkwrap.descriptor.api.connector10.ConnectorDescriptor
@@ -0,0 +1,3 @@
+implClass=org.jboss.shrinkwrap.descriptor.impl.connector10.ConnectorDescriptorImpl
+importerClass=org.jboss.shrinkwrap.descriptor.spi.node.dom.XmlDomNodeDescriptorImporterImpl
+defaultName=ra.xml
\ No newline at end of file
diff --git a/impl-javaee-prototype/src/test/java/org/jboss/shrinkwrap/descriptor/test/connector10/ConnectorDescriptorTestCase.java b/impl-javaee-prototype/src/test/java/org/jboss/shrinkwrap/descriptor/test/connector10/ConnectorDescriptorTestCase.java
new file mode 100644
index 00000000..a55aa844
--- /dev/null
+++ b/impl-javaee-prototype/src/test/java/org/jboss/shrinkwrap/descriptor/test/connector10/ConnectorDescriptorTestCase.java
@@ -0,0 +1,134 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * 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 org.jboss.shrinkwrap.descriptor.test.connector10;
+
+import java.util.List;
+
+import org.jboss.shrinkwrap.descriptor.api.Descriptors;
+import org.jboss.shrinkwrap.descriptor.api.connector10.ConfigProperty;
+import org.jboss.shrinkwrap.descriptor.api.connector10.ConnectorDescriptor;
+import org.jboss.shrinkwrap.descriptor.api.connector10.Factory;
+import org.jboss.shrinkwrap.descriptor.api.connector10.Resourceadapter;
+import org.jboss.shrinkwrap.descriptor.impl.connector10.ChildNodeInitializer;
+import org.jboss.shrinkwrap.descriptor.impl.connector10.ResourceadapterImpl;
+import org.jboss.shrinkwrap.descriptor.spi.node.Node;
+import org.junit.Test;
+
+public class ConnectorDescriptorTestCase {
+
+ @Test
+ public void testFactory() throws Exception {
+ final ConnectorDescriptor jca10Generated = create();
+ final Factory factory = jca10Generated.getFactory();
+
+ jca10Generated
+ .description("It is a sample resource adapter")
+ .setResourceadapter(factory.resourceadapter()
+ .addConfigProperty(factory.configProperty()
+ .configPropertyName("Input")
+ .configPropertyType("java.lang.String")
+ .configPropertyValue("test messages")));
+
+ String generatedRaXml = jca10Generated.exportAsString();
+ System.out.println(generatedRaXml);
+ }
+
+ @Test
+ public void testDetachedMode() throws Exception {
+ final ConnectorDescriptor jca10Generated = create();
+ final Factory factory = jca10Generated.getFactory();
+
+ final Resourceadapter resourceAdapter = factory.resourceadapter();
+
+ final ConfigProperty property = factory.configProperty()
+ .configPropertyName("Input")
+ .configPropertyType("java.lang.String")
+ .configPropertyValue("test messages");
+
+ jca10Generated
+ .description("It is a sample resource adapter")
+ .setResourceadapter(resourceAdapter.addConfigProperty(property));
+
+ String generatedRaXml = jca10Generated.exportAsString();
+ System.out.println(generatedRaXml);
+ }
+
+
+ @Test
+ public void testConvenientResourceAdapter() throws Exception {
+ final ConnectorDescriptor jca10Generated = create();
+ final Factory factory = jca10Generated.getFactory();
+
+ final ConvenientResourceAdapter resourceAdapter = new ConvenientResourceAdapter();
+
+ final ConfigProperty property = factory.configProperty()
+ .configPropertyName("Input")
+ .configPropertyType("java.lang.String")
+ .configPropertyValue("test messages");
+
+ jca10Generated
+ .description("It is a sample resource adapter")
+ .setResourceadapter(resourceAdapter.addConfigProperty(property));
+
+ String generatedRaXml = jca10Generated.exportAsString();
+ System.out.println(generatedRaXml);
+ }
+
+ // -------------------------------------------------------------------------------------||
+ // Internal Helper --------------------------------------------------------------------||
+ // -------------------------------------------------------------------------------------||
+
+ private ConnectorDescriptor create() {
+ return Descriptors.create(ConnectorDescriptor.class);
+ }
+
+ private class ConvenientResourceAdapter implements Resourceadapter, ChildNodeInitializer {
+ final ResourceadapterImpl resourceAdapter = new ResourceadapterImpl();
+
+ @Override
+ public void initialize(String nodeName, Node node) {
+ node.attribute("attr", "val");
+ final Node myNode = node.createChild("my-node");
+ myNode.attribute("my-attribute", "great");
+ myNode.text("my-text");
+ resourceAdapter.initialize(nodeName, node);
+ }
+
+ @Override
+ public void assign(String nodeName, Node node) {
+ resourceAdapter.assign(nodeName, node);
+ }
+
+ @Override
+ public Resourceadapter addConfigProperty(ConfigProperty configProperty) {
+ resourceAdapter.addConfigProperty(configProperty);
+ return this;
+ }
+
+ @Override
+ public Listthis reference to the specified {@link Node}
* @param copyTarget