savara SVN: r314 - trunk/tools/eclipse/org.scribble.core/src/java/org/scribble/model.
by do-not-reply@jboss.org
Author: objectiser
Date: 2010-07-07 17:26:33 -0400 (Wed, 07 Jul 2010)
New Revision: 314
Modified:
trunk/tools/eclipse/org.scribble.core/src/java/org/scribble/model/Annotations.java
trunk/tools/eclipse/org.scribble.core/src/java/org/scribble/model/ModelObject.java
Log:
Remove serialization from the scribble model - not sure if we need to serialise the object model, as this is primarily used as an internal form.
Modified: trunk/tools/eclipse/org.scribble.core/src/java/org/scribble/model/Annotations.java
===================================================================
--- trunk/tools/eclipse/org.scribble.core/src/java/org/scribble/model/Annotations.java 2010-07-07 15:25:08 UTC (rev 313)
+++ trunk/tools/eclipse/org.scribble.core/src/java/org/scribble/model/Annotations.java 2010-07-07 21:26:33 UTC (rev 314)
@@ -24,7 +24,7 @@
* information that can be used to provide additional
* details about a model component.
*/
-public class Annotations extends java.util.HashMap<String,java.io.Serializable> {
+public class Annotations extends java.util.HashMap<String,Object> {
private static final long serialVersionUID = -4594153737794956180L;
Modified: trunk/tools/eclipse/org.scribble.core/src/java/org/scribble/model/ModelObject.java
===================================================================
--- trunk/tools/eclipse/org.scribble.core/src/java/org/scribble/model/ModelObject.java 2010-07-07 15:25:08 UTC (rev 313)
+++ trunk/tools/eclipse/org.scribble.core/src/java/org/scribble/model/ModelObject.java 2010-07-07 21:26:33 UTC (rev 314)
@@ -25,7 +25,7 @@
* This is the generic object from which all Scribble model objects
* are derived.
*/
-public abstract class ModelObject implements java.io.Serializable {
+public abstract class ModelObject {
private static final long serialVersionUID = -8915435247669402908L;
13 years, 10 months
savara SVN: r313 - in trunk/tools: plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/impl and 1 other directories.
by do-not-reply@jboss.org
Author: objectiser
Date: 2010-07-07 11:25:08 -0400 (Wed, 07 Jul 2010)
New Revision: 313
Modified:
trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/ContractGenerator.java
trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/Messages.properties
trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/impl/ContractGeneratorImpl.java
trunk/tools/tests/org.jboss.savara.protocol.contract.tests/src/java/org/jboss/savara/protocol/contract/tests/ContractGeneratorTest.java
Log:
Change so that local model supplied - does not require contract generator to perform projection.
Modified: trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/ContractGenerator.java
===================================================================
--- trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/ContractGenerator.java 2010-07-07 14:41:13 UTC (rev 312)
+++ trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/ContractGenerator.java 2010-07-07 15:25:08 UTC (rev 313)
@@ -19,25 +19,21 @@
import org.jboss.savara.contract.model.Contract;
import org.scribble.conversation.model.Conversation;
-import org.scribble.model.Role;
/**
- * This interface represents the service that generates a contract
- * from a protocol defining the behaviour of multiple interacting roles.
+ * This interface represents the capability that generates a contract
+ * from a protocol associated with a particular interacting role.
*
*/
public interface ContractGenerator {
/**
- * This method generates a contract associated with a supplied protocol
- * and optional role. If the protocol represents a local model, then
- * the role will be derived from the local model. If the protocol represents
- * a global model, then a role must be supplied.
+ * This method generates a contract associated with a supplied located
+ * protocol.
*
* @param cm The protocol
- * @param role The optional role
* @return The contract
*/
- public Contract generate(Conversation cm, Role role) throws IllegalArgumentException;
+ public Contract generate(Conversation cm) throws IllegalArgumentException;
}
Modified: trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/Messages.properties
===================================================================
--- trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/Messages.properties 2010-07-07 14:41:13 UTC (rev 312)
+++ trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/Messages.properties 2010-07-07 15:25:08 UTC (rev 313)
@@ -16,5 +16,5 @@
# * MA 02110-1301, USA.
# */
-SAVARAPC-00001=Conversation must be supplied
-SAVARAPC-00002=Role has not been defined
+SAVARAPC-00001=Protocol must be supplied
+SAVARAPC-00002=Contract generation requires a protocol that represents the local behaviour associated with a particular role
Modified: trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/impl/ContractGeneratorImpl.java
===================================================================
--- trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/impl/ContractGeneratorImpl.java 2010-07-07 14:41:13 UTC (rev 312)
+++ trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/impl/ContractGeneratorImpl.java 2010-07-07 15:25:08 UTC (rev 313)
@@ -32,16 +32,13 @@
public class ContractGeneratorImpl implements ContractGenerator {
/**
- * This method generates a contract associated with a supplied protocol
- * and optional role. If the protocol represents a local model, then
- * the role will be derived from the local model. If the protocol represents
- * a global model, then a role must be supplied.
+ * This method generates a contract associated with a supplied located
+ * protocol.
*
* @param cm The protocol
- * @param role The optional role
* @return The contract
*/
- public Contract generate(Conversation cm, Role role) throws IllegalArgumentException {
+ public Contract generate(Conversation cm) throws IllegalArgumentException {
// Check parameters
if (cm == null) {
@@ -50,8 +47,7 @@
"org.jboss.savara.protocol.contract.Messages").
getString("SAVARAPC-00001"), (Object)null));
- } else if ((cm.getLocatedName() == null || cm.getLocatedName().getRole() == null) &&
- role == null) {
+ } else if (cm.getLocatedName() == null || cm.getLocatedName().getRole() == null) {
throw new IllegalArgumentException(MessageFormat.format(
java.util.PropertyResourceBundle.getBundle(
"org.jboss.savara.protocol.contract.Messages").
Modified: trunk/tools/tests/org.jboss.savara.protocol.contract.tests/src/java/org/jboss/savara/protocol/contract/tests/ContractGeneratorTest.java
===================================================================
--- trunk/tools/tests/org.jboss.savara.protocol.contract.tests/src/java/org/jboss/savara/protocol/contract/tests/ContractGeneratorTest.java 2010-07-07 14:41:13 UTC (rev 312)
+++ trunk/tools/tests/org.jboss.savara.protocol.contract.tests/src/java/org/jboss/savara/protocol/contract/tests/ContractGeneratorTest.java 2010-07-07 15:25:08 UTC (rev 313)
@@ -17,9 +17,8 @@
try {
Conversation conv=null;
- Role role=new Role();
- generator.generate(conv, role);
+ generator.generate(conv);
fail("Should have thrown IllegalArgumentException");
@@ -29,18 +28,17 @@
}
@org.junit.Test
- public void testGenerateRoleNull() {
+ public void testGenerateProtocolNotLocated() {
ContractGenerator generator=ContractGeneratorFactory.getContractGenerator();
try {
Conversation conv=new Conversation();
- conv.setLocatedName(new LocatedName());
+ LocatedName ln=new LocatedName();
+ conv.setLocatedName(ln);
- Role role=null;
+ generator.generate(conv);
- generator.generate(conv, role);
-
fail("Should have thrown IllegalArgumentException");
} catch(IllegalArgumentException iae) {
@@ -49,7 +47,7 @@
}
@org.junit.Test
- public void testGenerateConversationAndRoleNotNull1() {
+ public void testGenerateConversationAndRoleNotNull2() {
ContractGenerator generator=ContractGeneratorFactory.getContractGenerator();
@@ -59,31 +57,10 @@
ln.setRole(new Role());
conv.setLocatedName(ln);
- Role role=null;
+ generator.generate(conv);
- generator.generate(conv, role);
-
} catch(IllegalArgumentException iae) {
fail("Should NOT have thrown IllegalArgumentException");
}
}
-
- @org.junit.Test
- public void testGenerateConversationAndRoleNotNull2() {
-
- ContractGenerator generator=ContractGeneratorFactory.getContractGenerator();
-
- try {
- Conversation conv=new Conversation();
- LocatedName ln=new LocatedName();
- conv.setLocatedName(ln);
-
- Role role=new Role();
-
- generator.generate(conv, role);
-
- } catch(IllegalArgumentException iae) {
- fail("Should NOT have thrown IllegalArgumentException");
- }
- }
}
13 years, 10 months
savara SVN: r312 - in trunk/tools: tests/org.jboss.savara.protocol.contract.tests and 1 other directory.
by do-not-reply@jboss.org
Author: objectiser
Date: 2010-07-07 10:41:13 -0400 (Wed, 07 Jul 2010)
New Revision: 312
Modified:
trunk/tools/plugins/org.jboss.savara.protocol.contract/
trunk/tools/tests/org.jboss.savara.protocol.contract.tests/
Log:
Property changes on: trunk/tools/plugins/org.jboss.savara.protocol.contract
___________________________________________________________________
Name: svn:ignore
+ bin
Property changes on: trunk/tools/tests/org.jboss.savara.protocol.contract.tests
___________________________________________________________________
Name: svn:ignore
+ bin
13 years, 10 months
savara SVN: r311 - in trunk/tools/tests/org.jboss.savara.protocol.contract.tests: META-INF and 9 other directories.
by do-not-reply@jboss.org
Author: objectiser
Date: 2010-07-07 10:25:52 -0400 (Wed, 07 Jul 2010)
New Revision: 311
Added:
trunk/tools/tests/org.jboss.savara.protocol.contract.tests/META-INF/
trunk/tools/tests/org.jboss.savara.protocol.contract.tests/META-INF/MANIFEST.MF
trunk/tools/tests/org.jboss.savara.protocol.contract.tests/src/
trunk/tools/tests/org.jboss.savara.protocol.contract.tests/src/java/
trunk/tools/tests/org.jboss.savara.protocol.contract.tests/src/java/org/
trunk/tools/tests/org.jboss.savara.protocol.contract.tests/src/java/org/jboss/
trunk/tools/tests/org.jboss.savara.protocol.contract.tests/src/java/org/jboss/savara/
trunk/tools/tests/org.jboss.savara.protocol.contract.tests/src/java/org/jboss/savara/protocol/
trunk/tools/tests/org.jboss.savara.protocol.contract.tests/src/java/org/jboss/savara/protocol/contract/
trunk/tools/tests/org.jboss.savara.protocol.contract.tests/src/java/org/jboss/savara/protocol/contract/tests/
trunk/tools/tests/org.jboss.savara.protocol.contract.tests/src/java/org/jboss/savara/protocol/contract/tests/ContractGeneratorTest.java
trunk/tools/tests/org.jboss.savara.protocol.contract.tests/src/java/org/jboss/savara/protocol/contract/tests/osgi/
trunk/tools/tests/org.jboss.savara.protocol.contract.tests/src/java/org/jboss/savara/protocol/contract/tests/osgi/Activator.java
Log:
Initial contract generation plugins.
Added: trunk/tools/tests/org.jboss.savara.protocol.contract.tests/META-INF/MANIFEST.MF
===================================================================
--- trunk/tools/tests/org.jboss.savara.protocol.contract.tests/META-INF/MANIFEST.MF (rev 0)
+++ trunk/tools/tests/org.jboss.savara.protocol.contract.tests/META-INF/MANIFEST.MF 2010-07-07 14:25:52 UTC (rev 311)
@@ -0,0 +1,15 @@
+Manifest-Version: 1.0
+Bundle-ManifestVersion: 2
+Bundle-Name: JBoss SAVARA Protocol Contract Tests Plugin
+Bundle-SymbolicName: org.jboss.savara.protocol.contract.tests
+Bundle-Version: 1.0.0.qualifier
+Bundle-Activator: org.jboss.savara.protocol.contract.tests.osgi.Activator
+Bundle-Vendor: www.jboss.org
+Bundle-RequiredExecutionEnvironment: J2SE-1.5
+Import-Package: org.osgi.framework;version="1.3.0"
+Require-Bundle: org.scribble.core,
+ org.scribble.conversation.model,
+ org.jboss.savara.contract.model,
+ org.jboss.savara.protocol.contract,
+ org.junit
+Export-Package: org.jboss.savara.protocol.contract.tests
Added: trunk/tools/tests/org.jboss.savara.protocol.contract.tests/src/java/org/jboss/savara/protocol/contract/tests/ContractGeneratorTest.java
===================================================================
--- trunk/tools/tests/org.jboss.savara.protocol.contract.tests/src/java/org/jboss/savara/protocol/contract/tests/ContractGeneratorTest.java (rev 0)
+++ trunk/tools/tests/org.jboss.savara.protocol.contract.tests/src/java/org/jboss/savara/protocol/contract/tests/ContractGeneratorTest.java 2010-07-07 14:25:52 UTC (rev 311)
@@ -0,0 +1,89 @@
+package org.jboss.savara.protocol.contract.tests;
+
+import static org.junit.Assert.*;
+
+import org.jboss.savara.protocol.contract.ContractGenerator;
+import org.jboss.savara.protocol.contract.ContractGeneratorFactory;
+import org.scribble.conversation.model.Conversation;
+import org.scribble.model.LocatedName;
+import org.scribble.model.Role;
+
+public class ContractGeneratorTest {
+
+ @org.junit.Test
+ public void testGenerateProtocolNull() {
+
+ ContractGenerator generator=ContractGeneratorFactory.getContractGenerator();
+
+ try {
+ Conversation conv=null;
+ Role role=new Role();
+
+ generator.generate(conv, role);
+
+ fail("Should have thrown IllegalArgumentException");
+
+ } catch(IllegalArgumentException iae) {
+ // Test worked
+ }
+ }
+
+ @org.junit.Test
+ public void testGenerateRoleNull() {
+
+ ContractGenerator generator=ContractGeneratorFactory.getContractGenerator();
+
+ try {
+ Conversation conv=new Conversation();
+ conv.setLocatedName(new LocatedName());
+
+ Role role=null;
+
+ generator.generate(conv, role);
+
+ fail("Should have thrown IllegalArgumentException");
+
+ } catch(IllegalArgumentException iae) {
+ // Test worked
+ }
+ }
+
+ @org.junit.Test
+ public void testGenerateConversationAndRoleNotNull1() {
+
+ ContractGenerator generator=ContractGeneratorFactory.getContractGenerator();
+
+ try {
+ Conversation conv=new Conversation();
+ LocatedName ln=new LocatedName();
+ ln.setRole(new Role());
+ conv.setLocatedName(ln);
+
+ Role role=null;
+
+ generator.generate(conv, role);
+
+ } catch(IllegalArgumentException iae) {
+ fail("Should NOT have thrown IllegalArgumentException");
+ }
+ }
+
+ @org.junit.Test
+ public void testGenerateConversationAndRoleNotNull2() {
+
+ ContractGenerator generator=ContractGeneratorFactory.getContractGenerator();
+
+ try {
+ Conversation conv=new Conversation();
+ LocatedName ln=new LocatedName();
+ conv.setLocatedName(ln);
+
+ Role role=new Role();
+
+ generator.generate(conv, role);
+
+ } catch(IllegalArgumentException iae) {
+ fail("Should NOT have thrown IllegalArgumentException");
+ }
+ }
+}
Added: trunk/tools/tests/org.jboss.savara.protocol.contract.tests/src/java/org/jboss/savara/protocol/contract/tests/osgi/Activator.java
===================================================================
--- trunk/tools/tests/org.jboss.savara.protocol.contract.tests/src/java/org/jboss/savara/protocol/contract/tests/osgi/Activator.java (rev 0)
+++ trunk/tools/tests/org.jboss.savara.protocol.contract.tests/src/java/org/jboss/savara/protocol/contract/tests/osgi/Activator.java 2010-07-07 14:25:52 UTC (rev 311)
@@ -0,0 +1,39 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+ * PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
+ * You should have received a copy of the GNU Lesser General Public License,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ */
+package org.jboss.savara.protocol.contract.tests.osgi;
+
+import org.osgi.framework.BundleActivator;
+import org.osgi.framework.BundleContext;
+
+public class Activator implements BundleActivator {
+
+ /*
+ * (non-Javadoc)
+ * @see org.osgi.framework.BundleActivator#start(org.osgi.framework.BundleContext)
+ */
+ public void start(BundleContext context) throws Exception {
+ }
+
+ /*
+ * (non-Javadoc)
+ * @see org.osgi.framework.BundleActivator#stop(org.osgi.framework.BundleContext)
+ */
+ public void stop(BundleContext context) throws Exception {
+ }
+
+}
13 years, 10 months
savara SVN: r310 - in trunk/tools: plugins/org.jboss.savara.protocol.contract/META-INF and 11 other directories.
by do-not-reply@jboss.org
Author: objectiser
Date: 2010-07-07 10:24:59 -0400 (Wed, 07 Jul 2010)
New Revision: 310
Added:
trunk/tools/plugins/org.jboss.savara.protocol.contract/META-INF/
trunk/tools/plugins/org.jboss.savara.protocol.contract/META-INF/MANIFEST.MF
trunk/tools/plugins/org.jboss.savara.protocol.contract/src/
trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/
trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/
trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/
trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/
trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/
trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/
trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/ContractGenerator.java
trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/ContractGeneratorFactory.java
trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/Messages.properties
trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/impl/
trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/impl/ContractGeneratorImpl.java
trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/osgi/
trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/osgi/Activator.java
trunk/tools/tests/org.jboss.savara.protocol.contract.tests/
trunk/tools/tests/org.jboss.savara.protocol.contract.tests/.classpath
trunk/tools/tests/org.jboss.savara.protocol.contract.tests/.project
trunk/tools/tests/org.jboss.savara.protocol.contract.tests/Copyright.txt
trunk/tools/tests/org.jboss.savara.protocol.contract.tests/build.properties
Log:
Initial contract generation plugins.
Added: trunk/tools/plugins/org.jboss.savara.protocol.contract/META-INF/MANIFEST.MF
===================================================================
--- trunk/tools/plugins/org.jboss.savara.protocol.contract/META-INF/MANIFEST.MF (rev 0)
+++ trunk/tools/plugins/org.jboss.savara.protocol.contract/META-INF/MANIFEST.MF 2010-07-07 14:24:59 UTC (rev 310)
@@ -0,0 +1,13 @@
+Manifest-Version: 1.0
+Bundle-ManifestVersion: 2
+Bundle-Name: JBoss SAVARA Protocol Contract Plugin
+Bundle-SymbolicName: org.jboss.savara.protocol.contract
+Bundle-Version: 1.0.0.qualifier
+Bundle-Activator: org.jboss.savara.protocol.contract.osgi.Activator
+Bundle-Vendor: www.jboss.org
+Bundle-RequiredExecutionEnvironment: J2SE-1.5
+Import-Package: org.osgi.framework;version="1.3.0"
+Require-Bundle: org.scribble.core,
+ org.scribble.conversation.model,
+ org.jboss.savara.contract.model
+Export-Package: org.jboss.savara.protocol.contract
Added: trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/ContractGenerator.java
===================================================================
--- trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/ContractGenerator.java (rev 0)
+++ trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/ContractGenerator.java 2010-07-07 14:24:59 UTC (rev 310)
@@ -0,0 +1,43 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+ * PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
+ * You should have received a copy of the GNU Lesser General Public License,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ */
+package org.jboss.savara.protocol.contract;
+
+import org.jboss.savara.contract.model.Contract;
+import org.scribble.conversation.model.Conversation;
+import org.scribble.model.Role;
+
+/**
+ * This interface represents the service that generates a contract
+ * from a protocol defining the behaviour of multiple interacting roles.
+ *
+ */
+public interface ContractGenerator {
+
+ /**
+ * This method generates a contract associated with a supplied protocol
+ * and optional role. If the protocol represents a local model, then
+ * the role will be derived from the local model. If the protocol represents
+ * a global model, then a role must be supplied.
+ *
+ * @param cm The protocol
+ * @param role The optional role
+ * @return The contract
+ */
+ public Contract generate(Conversation cm, Role role) throws IllegalArgumentException;
+
+}
Added: trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/ContractGeneratorFactory.java
===================================================================
--- trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/ContractGeneratorFactory.java (rev 0)
+++ trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/ContractGeneratorFactory.java 2010-07-07 14:24:59 UTC (rev 310)
@@ -0,0 +1,38 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+ * PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
+ * You should have received a copy of the GNU Lesser General Public License,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ */
+package org.jboss.savara.protocol.contract;
+
+import org.jboss.savara.protocol.contract.impl.ContractGeneratorImpl;
+
+/**
+ * This class provides access to a contract generator.
+ *
+ */
+public class ContractGeneratorFactory {
+
+ /**
+ * This method returns an instance of the ContractGenerator
+ * interface.
+ *
+ * @return The contract generator
+ */
+ public static ContractGenerator getContractGenerator() {
+ return(new ContractGeneratorImpl());
+ }
+
+}
Added: trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/Messages.properties
===================================================================
--- trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/Messages.properties (rev 0)
+++ trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/Messages.properties 2010-07-07 14:24:59 UTC (rev 310)
@@ -0,0 +1,20 @@
+#/*
+# * JBoss, Home of Professional Open Source
+# * Copyright 2008, Red Hat Middleware LLC, and others contributors as indicated
+# * by the @authors tag. All rights reserved.
+# * See the copyright.txt in the distribution for a
+# * full listing of individual contributors.
+# * This copyrighted material is made available to anyone wishing to use,
+# * modify, copy, or redistribute it subject to the terms and conditions
+# * of the GNU Lesser General Public License, v. 2.1.
+# * This program is distributed in the hope that it will be useful, but WITHOUT A
+# * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+# * PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
+# * You should have received a copy of the GNU Lesser General Public License,
+# * v.2.1 along with this distribution; if not, write to the Free Software
+# * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+# * MA 02110-1301, USA.
+# */
+
+SAVARAPC-00001=Conversation must be supplied
+SAVARAPC-00002=Role has not been defined
Added: trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/impl/ContractGeneratorImpl.java
===================================================================
--- trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/impl/ContractGeneratorImpl.java (rev 0)
+++ trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/impl/ContractGeneratorImpl.java 2010-07-07 14:24:59 UTC (rev 310)
@@ -0,0 +1,64 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+ * PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
+ * You should have received a copy of the GNU Lesser General Public License,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ */
+package org.jboss.savara.protocol.contract.impl;
+
+import java.text.MessageFormat;
+
+import org.jboss.savara.contract.model.Contract;
+import org.jboss.savara.protocol.contract.ContractGenerator;
+import org.scribble.conversation.model.Conversation;
+import org.scribble.model.Role;
+
+/**
+ * This class generates a contract from a protocol defining the behaviour of
+ * multiple interacting roles.
+ *
+ */
+public class ContractGeneratorImpl implements ContractGenerator {
+
+ /**
+ * This method generates a contract associated with a supplied protocol
+ * and optional role. If the protocol represents a local model, then
+ * the role will be derived from the local model. If the protocol represents
+ * a global model, then a role must be supplied.
+ *
+ * @param cm The protocol
+ * @param role The optional role
+ * @return The contract
+ */
+ public Contract generate(Conversation cm, Role role) throws IllegalArgumentException {
+
+ // Check parameters
+ if (cm == null) {
+ throw new IllegalArgumentException(MessageFormat.format(
+ java.util.PropertyResourceBundle.getBundle(
+ "org.jboss.savara.protocol.contract.Messages").
+ getString("SAVARAPC-00001"), (Object)null));
+
+ } else if ((cm.getLocatedName() == null || cm.getLocatedName().getRole() == null) &&
+ role == null) {
+ throw new IllegalArgumentException(MessageFormat.format(
+ java.util.PropertyResourceBundle.getBundle(
+ "org.jboss.savara.protocol.contract.Messages").
+ getString("SAVARAPC-00002"), (Object)null));
+ }
+
+ return(null);
+ }
+
+}
Added: trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/osgi/Activator.java
===================================================================
--- trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/osgi/Activator.java (rev 0)
+++ trunk/tools/plugins/org.jboss.savara.protocol.contract/src/java/org/jboss/savara/protocol/contract/osgi/Activator.java 2010-07-07 14:24:59 UTC (rev 310)
@@ -0,0 +1,39 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+ * PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
+ * You should have received a copy of the GNU Lesser General Public License,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ */
+package org.jboss.savara.protocol.contract.osgi;
+
+import org.osgi.framework.BundleActivator;
+import org.osgi.framework.BundleContext;
+
+public class Activator implements BundleActivator {
+
+ /*
+ * (non-Javadoc)
+ * @see org.osgi.framework.BundleActivator#start(org.osgi.framework.BundleContext)
+ */
+ public void start(BundleContext context) throws Exception {
+ }
+
+ /*
+ * (non-Javadoc)
+ * @see org.osgi.framework.BundleActivator#stop(org.osgi.framework.BundleContext)
+ */
+ public void stop(BundleContext context) throws Exception {
+ }
+
+}
Added: trunk/tools/tests/org.jboss.savara.protocol.contract.tests/.classpath
===================================================================
--- trunk/tools/tests/org.jboss.savara.protocol.contract.tests/.classpath (rev 0)
+++ trunk/tools/tests/org.jboss.savara.protocol.contract.tests/.classpath 2010-07-07 14:24:59 UTC (rev 310)
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.6"/>
+ <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
+ <classpathentry kind="src" path="src/java"/>
+ <classpathentry kind="output" path="bin"/>
+</classpath>
Added: trunk/tools/tests/org.jboss.savara.protocol.contract.tests/.project
===================================================================
--- trunk/tools/tests/org.jboss.savara.protocol.contract.tests/.project (rev 0)
+++ trunk/tools/tests/org.jboss.savara.protocol.contract.tests/.project 2010-07-07 14:24:59 UTC (rev 310)
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+ <name>org.jboss.savara.protocol.contract.tests</name>
+ <comment></comment>
+ <projects>
+ </projects>
+ <buildSpec>
+ <buildCommand>
+ <name>org.eclipse.jdt.core.javabuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.eclipse.pde.ManifestBuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.eclipse.pde.SchemaBuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ </buildSpec>
+ <natures>
+ <nature>org.eclipse.pde.PluginNature</nature>
+ <nature>org.eclipse.jdt.core.javanature</nature>
+ </natures>
+</projectDescription>
Added: trunk/tools/tests/org.jboss.savara.protocol.contract.tests/Copyright.txt
===================================================================
--- trunk/tools/tests/org.jboss.savara.protocol.contract.tests/Copyright.txt (rev 0)
+++ trunk/tools/tests/org.jboss.savara.protocol.contract.tests/Copyright.txt 2010-07-07 14:24:59 UTC (rev 310)
@@ -0,0 +1,17 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+ * PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
+ * You should have received a copy of the GNU Lesser General Public License,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ */
Added: trunk/tools/tests/org.jboss.savara.protocol.contract.tests/build.properties
===================================================================
--- trunk/tools/tests/org.jboss.savara.protocol.contract.tests/build.properties (rev 0)
+++ trunk/tools/tests/org.jboss.savara.protocol.contract.tests/build.properties 2010-07-07 14:24:59 UTC (rev 310)
@@ -0,0 +1,4 @@
+source.. = src/java/
+output.. = bin/
+bin.includes = META-INF/,\
+ .
13 years, 10 months
savara SVN: r309 - in trunk/tools/plugins: org.jboss.savara.contract.model/src/java/org and 1 other directories.
by do-not-reply@jboss.org
Author: objectiser
Date: 2010-07-07 10:23:56 -0400 (Wed, 07 Jul 2010)
New Revision: 309
Added:
trunk/tools/plugins/org.jboss.savara.protocol.contract/
trunk/tools/plugins/org.jboss.savara.protocol.contract/.classpath
trunk/tools/plugins/org.jboss.savara.protocol.contract/.project
trunk/tools/plugins/org.jboss.savara.protocol.contract/Copyright.txt
trunk/tools/plugins/org.jboss.savara.protocol.contract/build.properties
Removed:
trunk/tools/plugins/org.jboss.savara.contract.model/src/java/org/scribble/
Log:
Initial contract generation plugins.
Added: trunk/tools/plugins/org.jboss.savara.protocol.contract/.classpath
===================================================================
--- trunk/tools/plugins/org.jboss.savara.protocol.contract/.classpath (rev 0)
+++ trunk/tools/plugins/org.jboss.savara.protocol.contract/.classpath 2010-07-07 14:23:56 UTC (rev 309)
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.6"/>
+ <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
+ <classpathentry kind="src" path="src/java"/>
+ <classpathentry kind="output" path="bin"/>
+</classpath>
Added: trunk/tools/plugins/org.jboss.savara.protocol.contract/.project
===================================================================
--- trunk/tools/plugins/org.jboss.savara.protocol.contract/.project (rev 0)
+++ trunk/tools/plugins/org.jboss.savara.protocol.contract/.project 2010-07-07 14:23:56 UTC (rev 309)
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+ <name>org.jboss.savara.protocol.contract</name>
+ <comment></comment>
+ <projects>
+ </projects>
+ <buildSpec>
+ <buildCommand>
+ <name>org.eclipse.jdt.core.javabuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.eclipse.pde.ManifestBuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.eclipse.pde.SchemaBuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ </buildSpec>
+ <natures>
+ <nature>org.eclipse.pde.PluginNature</nature>
+ <nature>org.eclipse.jdt.core.javanature</nature>
+ </natures>
+</projectDescription>
Added: trunk/tools/plugins/org.jboss.savara.protocol.contract/Copyright.txt
===================================================================
--- trunk/tools/plugins/org.jboss.savara.protocol.contract/Copyright.txt (rev 0)
+++ trunk/tools/plugins/org.jboss.savara.protocol.contract/Copyright.txt 2010-07-07 14:23:56 UTC (rev 309)
@@ -0,0 +1,17 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+ * PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
+ * You should have received a copy of the GNU Lesser General Public License,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ */
Added: trunk/tools/plugins/org.jboss.savara.protocol.contract/build.properties
===================================================================
--- trunk/tools/plugins/org.jboss.savara.protocol.contract/build.properties (rev 0)
+++ trunk/tools/plugins/org.jboss.savara.protocol.contract/build.properties 2010-07-07 14:23:56 UTC (rev 309)
@@ -0,0 +1,4 @@
+source.. = src/java/
+output.. = bin/
+bin.includes = META-INF/,\
+ .
13 years, 10 months
savara SVN: r308 - in trunk/tools/plugins/org.jboss.savara.pi4soa.cdm: src/java/org and 1 other directory.
by do-not-reply@jboss.org
Author: objectiser
Date: 2010-07-07 04:00:27 -0400 (Wed, 07 Jul 2010)
New Revision: 308
Removed:
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/scribble/
Modified:
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/
Log:
Remove old scribble package.
Property changes on: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm
___________________________________________________________________
Name: svn:ignore
- classes
+ classes
bin
13 years, 10 months
savara SVN: r307 - in trunk/tools: features and 19 other directories.
by do-not-reply@jboss.org
Author: objectiser
Date: 2010-07-06 18:34:21 -0400 (Tue, 06 Jul 2010)
New Revision: 307
Added:
trunk/tools/features/org.jboss.savara.pi4soa.feature/
trunk/tools/features/org.jboss.savara.pi4soa.feature/Copyright.txt
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/Copyright.txt
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/CDMDefinitions.java
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/editor/
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/model/
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/osgi/
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/CDMModelParserRule.java
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/CDMTokenizer.java
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/validation/
Removed:
trunk/tools/eclipse/org.scribble.pi4soa.cdm/
trunk/tools/eclipse/org.scribble.pi4soa.feature/
trunk/tools/features/org.jboss.savara.pi4soa.feature/LICENSE.txt
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/CDMDefinitions.java
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/editor/
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/model/
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/osgi/
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/parser/CDMModelParserRule.java
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/parser/CDMTokenizer.java
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/parser/rules/
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/validation/
Modified:
trunk/tools/features/org.jboss.savara.pi4soa.feature/.project
trunk/tools/features/org.jboss.savara.pi4soa.feature/feature.xml
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/.classpath
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/.project
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/META-INF/MANIFEST.MF
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/build.properties
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/editor/CDMEditorManager.java
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/model/CDMNotation.java
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/osgi/Activator.java
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/AssignConverterRuleImpl.java
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/ConversationConverterRuleImpl.java
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/ConversationInteractionConverterRuleImpl.java
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/ConversationModelConverterRuleImpl.java
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/ConverterContext.java
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/ConverterRule.java
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/ConverterRuleFactory.java
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/ConverterUtil.java
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/DefaultConverterContext.java
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/FinalizeConverterRuleImpl.java
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/FinalizerHandlerConverterRuleImpl.java
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/IfConverterRuleImpl.java
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/IfOrWhenConverterRuleImpl.java
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/ParallelConverterRuleImpl.java
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/PerformConverterRuleImpl.java
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/SequenceConverterRuleImpl.java
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/WhenConverterRuleImpl.java
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/WhileConverterRuleImpl.java
trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/validation/TypeReferenceValidationRule.java
trunk/tools/plugins/org.jboss.savara.tools.bpel/META-INF/MANIFEST.MF
trunk/tools/plugins/org.jboss.savara.tools.bpel/src/plugintest/org/jboss/savara/tools/bpel/generator/GeneratorTest.java
Log:
Refactor CDM parser as Savara plugin - as outside scope of Scribble.
Copied: trunk/tools/features/org.jboss.savara.pi4soa.feature (from rev 306, trunk/tools/eclipse/org.scribble.pi4soa.feature)
Modified: trunk/tools/features/org.jboss.savara.pi4soa.feature/.project
===================================================================
--- trunk/tools/eclipse/org.scribble.pi4soa.feature/.project 2010-07-06 21:48:27 UTC (rev 306)
+++ trunk/tools/features/org.jboss.savara.pi4soa.feature/.project 2010-07-06 22:34:21 UTC (rev 307)
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
- <name>org.scribble.pi4soa.feature</name>
+ <name>org.jboss.savara.pi4soa.feature</name>
<comment></comment>
<projects>
</projects>
Added: trunk/tools/features/org.jboss.savara.pi4soa.feature/Copyright.txt
===================================================================
--- trunk/tools/features/org.jboss.savara.pi4soa.feature/Copyright.txt (rev 0)
+++ trunk/tools/features/org.jboss.savara.pi4soa.feature/Copyright.txt 2010-07-06 22:34:21 UTC (rev 307)
@@ -0,0 +1,17 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+ * PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
+ * You should have received a copy of the GNU Lesser General Public License,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ */
Deleted: trunk/tools/features/org.jboss.savara.pi4soa.feature/LICENSE.txt
===================================================================
--- trunk/tools/eclipse/org.scribble.pi4soa.feature/LICENSE.txt 2010-07-06 21:48:27 UTC (rev 306)
+++ trunk/tools/features/org.jboss.savara.pi4soa.feature/LICENSE.txt 2010-07-06 22:34:21 UTC (rev 307)
@@ -1,201 +0,0 @@
- Apache License
- Version 2.0, January 2004
- http://www.apache.org/licenses/
-
- TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
-
- 1. Definitions.
-
- "License" shall mean the terms and conditions for use, reproduction,
- and distribution as defined by Sections 1 through 9 of this document.
-
- "Licensor" shall mean the copyright owner or entity authorized by
- the copyright owner that is granting the License.
-
- "Legal Entity" shall mean the union of the acting entity and all
- other entities that control, are controlled by, or are under common
- control with that entity. For the purposes of this definition,
- "control" means (i) the power, direct or indirect, to cause the
- direction or management of such entity, whether by contract or
- otherwise, or (ii) ownership of fifty percent (50%) or more of the
- outstanding shares, or (iii) beneficial ownership of such entity.
-
- "You" (or "Your") shall mean an individual or Legal Entity
- exercising permissions granted by this License.
-
- "Source" form shall mean the preferred form for making modifications,
- including but not limited to software source code, documentation
- source, and configuration files.
-
- "Object" form shall mean any form resulting from mechanical
- transformation or translation of a Source form, including but
- not limited to compiled object code, generated documentation,
- and conversions to other media types.
-
- "Work" shall mean the work of authorship, whether in Source or
- Object form, made available under the License, as indicated by a
- copyright notice that is included in or attached to the work
- (an example is provided in the Appendix below).
-
- "Derivative Works" shall mean any work, whether in Source or Object
- form, that is based on (or derived from) the Work and for which the
- editorial revisions, annotations, elaborations, or other modifications
- represent, as a whole, an original work of authorship. For the purposes
- of this License, Derivative Works shall not include works that remain
- separable from, or merely link (or bind by name) to the interfaces of,
- the Work and Derivative Works thereof.
-
- "Contribution" shall mean any work of authorship, including
- the original version of the Work and any modifications or additions
- to that Work or Derivative Works thereof, that is intentionally
- submitted to Licensor for inclusion in the Work by the copyright owner
- or by an individual or Legal Entity authorized to submit on behalf of
- the copyright owner. For the purposes of this definition, "submitted"
- means any form of electronic, verbal, or written communication sent
- to the Licensor or its representatives, including but not limited to
- communication on electronic mailing lists, source code control systems,
- and issue tracking systems that are managed by, or on behalf of, the
- Licensor for the purpose of discussing and improving the Work, but
- excluding communication that is conspicuously marked or otherwise
- designated in writing by the copyright owner as "Not a Contribution."
-
- "Contributor" shall mean Licensor and any individual or Legal Entity
- on behalf of whom a Contribution has been received by Licensor and
- subsequently incorporated within the Work.
-
- 2. Grant of Copyright License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- copyright license to reproduce, prepare Derivative Works of,
- publicly display, publicly perform, sublicense, and distribute the
- Work and such Derivative Works in Source or Object form.
-
- 3. Grant of Patent License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- (except as stated in this section) patent license to make, have made,
- use, offer to sell, sell, import, and otherwise transfer the Work,
- where such license applies only to those patent claims licensable
- by such Contributor that are necessarily infringed by their
- Contribution(s) alone or by combination of their Contribution(s)
- with the Work to which such Contribution(s) was submitted. If You
- institute patent litigation against any entity (including a
- cross-claim or counterclaim in a lawsuit) alleging that the Work
- or a Contribution incorporated within the Work constitutes direct
- or contributory patent infringement, then any patent licenses
- granted to You under this License for that Work shall terminate
- as of the date such litigation is filed.
-
- 4. Redistribution. You may reproduce and distribute copies of the
- Work or Derivative Works thereof in any medium, with or without
- modifications, and in Source or Object form, provided that You
- meet the following conditions:
-
- (a) You must give any other recipients of the Work or
- Derivative Works a copy of this License; and
-
- (b) You must cause any modified files to carry prominent notices
- stating that You changed the files; and
-
- (c) You must retain, in the Source form of any Derivative Works
- that You distribute, all copyright, patent, trademark, and
- attribution notices from the Source form of the Work,
- excluding those notices that do not pertain to any part of
- the Derivative Works; and
-
- (d) If the Work includes a "NOTICE" text file as part of its
- distribution, then any Derivative Works that You distribute must
- include a readable copy of the attribution notices contained
- within such NOTICE file, excluding those notices that do not
- pertain to any part of the Derivative Works, in at least one
- of the following places: within a NOTICE text file distributed
- as part of the Derivative Works; within the Source form or
- documentation, if provided along with the Derivative Works; or,
- within a display generated by the Derivative Works, if and
- wherever such third-party notices normally appear. The contents
- of the NOTICE file are for informational purposes only and
- do not modify the License. You may add Your own attribution
- notices within Derivative Works that You distribute, alongside
- or as an addendum to the NOTICE text from the Work, provided
- that such additional attribution notices cannot be construed
- as modifying the License.
-
- You may add Your own copyright statement to Your modifications and
- may provide additional or different license terms and conditions
- for use, reproduction, or distribution of Your modifications, or
- for any such Derivative Works as a whole, provided Your use,
- reproduction, and distribution of the Work otherwise complies with
- the conditions stated in this License.
-
- 5. Submission of Contributions. Unless You explicitly state otherwise,
- any Contribution intentionally submitted for inclusion in the Work
- by You to the Licensor shall be under the terms and conditions of
- this License, without any additional terms or conditions.
- Notwithstanding the above, nothing herein shall supersede or modify
- the terms of any separate license agreement you may have executed
- with Licensor regarding such Contributions.
-
- 6. Trademarks. This License does not grant permission to use the trade
- names, trademarks, service marks, or product names of the Licensor,
- except as required for reasonable and customary use in describing the
- origin of the Work and reproducing the content of the NOTICE file.
-
- 7. Disclaimer of Warranty. Unless required by applicable law or
- agreed to in writing, Licensor provides the Work (and each
- Contributor provides its Contributions) on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
- implied, including, without limitation, any warranties or conditions
- of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
- PARTICULAR PURPOSE. You are solely responsible for determining the
- appropriateness of using or redistributing the Work and assume any
- risks associated with Your exercise of permissions under this License.
-
- 8. Limitation of Liability. In no event and under no legal theory,
- whether in tort (including negligence), contract, or otherwise,
- unless required by applicable law (such as deliberate and grossly
- negligent acts) or agreed to in writing, shall any Contributor be
- liable to You for damages, including any direct, indirect, special,
- incidental, or consequential damages of any character arising as a
- result of this License or out of the use or inability to use the
- Work (including but not limited to damages for loss of goodwill,
- work stoppage, computer failure or malfunction, or any and all
- other commercial damages or losses), even if such Contributor
- has been advised of the possibility of such damages.
-
- 9. Accepting Warranty or Additional Liability. While redistributing
- the Work or Derivative Works thereof, You may choose to offer,
- and charge a fee for, acceptance of support, warranty, indemnity,
- or other liability obligations and/or rights consistent with this
- License. However, in accepting such obligations, You may act only
- on Your own behalf and on Your sole responsibility, not on behalf
- of any other Contributor, and only if You agree to indemnify,
- defend, and hold each Contributor harmless for any liability
- incurred by, or claims asserted against, such Contributor by reason
- of your accepting any such warranty or additional liability.
-
- END OF TERMS AND CONDITIONS
-
- APPENDIX: How to apply the Apache License to your work.
-
- To apply the Apache License to your work, attach the following
- boilerplate notice, with the fields enclosed by brackets "[]"
- replaced with your own identifying information. (Don't include
- the brackets!) The text should be enclosed in the appropriate
- comment syntax for the file format. We also recommend that a
- file or class name and description of purpose be included on the
- same "printed page" as the copyright notice for easier
- identification within third-party archives.
-
- Copyright [yyyy] [name of copyright owner]
-
- 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.
Modified: trunk/tools/features/org.jboss.savara.pi4soa.feature/feature.xml
===================================================================
--- trunk/tools/eclipse/org.scribble.pi4soa.feature/feature.xml 2010-07-06 21:48:27 UTC (rev 306)
+++ trunk/tools/features/org.jboss.savara.pi4soa.feature/feature.xml 2010-07-06 22:34:21 UTC (rev 307)
@@ -1,39 +1,41 @@
<?xml version="1.0" encoding="UTF-8"?>
<feature
- id="org.scribble.pi4soa.feature"
- label="Scribble pi4soa Feature"
- version="0.1.0.qualifier"
- provider-name="www.scribble.org">
+ id="org.jboss.savara.pi4soa.feature"
+ label="JBoss SAVARA pi4soa Feature"
+ version="1.0.0.qualifier"
+ provider-name="www.jboss.org">
<description>
- This feature provides the Scribble pi4soa support.
+ This feature provides the JBoss SAVARA pi4soa support.
</description>
<copyright>
- Copyright 2005-9 Pi4 Technologies Ltd 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.
+JBoss, Home of Professional Open Source
+Copyright 2008, Red Hat Middleware LLC, and others contributors as indicated
+by the @authors tag. All rights reserved.
+See the copyright.txt in the distribution for a
+full listing of individual contributors.
+This copyrighted material is made available to anyone wishing to use,
+modify, copy, or redistribute it subject to the terms and conditions
+of the GNU Lesser General Public License, v. 2.1.
+This program is distributed in the hope that it will be useful, but WITHOUT A
+WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
+You should have received a copy of the GNU Lesser General Public License,
+v.2.1 along with this distribution; if not, write to the Free Software
+Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+MA 02110-1301, USA.
</copyright>
- <license url="http://www.apache.org/licenses/LICENSE-2.0.html">
- The scribble tools suite is licensed under the open source Apache License, version 2.0. http://www.apache.org/licenses/LICENSE-2.0.html
- </license>
-
<plugin
- id="org.scribble.pi4soa.cdm"
+ id="org.jboss.savara.pi4soa.cdm"
download-size="0"
install-size="0"
version="0.0.0"
unpack="false"/>
<plugin
- id="org.scribble.contract.model"
+ id="org.jboss.savara.contract.model"
download-size="0"
install-size="0"
version="0.0.0"
Copied: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm (from rev 306, trunk/tools/eclipse/org.scribble.pi4soa.cdm)
Modified: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/.classpath
===================================================================
--- trunk/tools/eclipse/org.scribble.pi4soa.cdm/.classpath 2010-07-06 21:48:27 UTC (rev 306)
+++ trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/.classpath 2010-07-06 22:34:21 UTC (rev 307)
@@ -3,5 +3,5 @@
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/J2SE-1.5"/>
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
<classpathentry kind="src" path="src/java"/>
- <classpathentry kind="output" path="classes"/>
+ <classpathentry kind="output" path="bin"/>
</classpath>
Modified: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/.project
===================================================================
--- trunk/tools/eclipse/org.scribble.pi4soa.cdm/.project 2010-07-06 21:48:27 UTC (rev 306)
+++ trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/.project 2010-07-06 22:34:21 UTC (rev 307)
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
- <name>org.scribble.pi4soa.cdm</name>
+ <name>org.jboss.savara.pi4soa.cdm</name>
<comment></comment>
<projects>
</projects>
Added: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/Copyright.txt
===================================================================
--- trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/Copyright.txt (rev 0)
+++ trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/Copyright.txt 2010-07-06 22:34:21 UTC (rev 307)
@@ -0,0 +1,17 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+ * PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
+ * You should have received a copy of the GNU Lesser General Public License,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ */
Modified: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/META-INF/MANIFEST.MF
===================================================================
--- trunk/tools/eclipse/org.scribble.pi4soa.cdm/META-INF/MANIFEST.MF 2010-07-06 21:48:27 UTC (rev 306)
+++ trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/META-INF/MANIFEST.MF 2010-07-06 22:34:21 UTC (rev 307)
@@ -1,10 +1,10 @@
Manifest-Version: 1.0
Bundle-ManifestVersion: 2
-Bundle-Name: Scribble pi4soa CDM
-Bundle-SymbolicName: org.scribble.pi4soa.cdm
-Bundle-Version: 0.1.0.qualifier
-Bundle-Activator: org.scribble.pi4soa.cdm.osgi.Activator
-Bundle-Vendor: www.scribble.org
+Bundle-Name: JBoss SAVARA pi4soa CDM
+Bundle-SymbolicName: org.jboss.savara.pi4soa.cdm
+Bundle-Version: 1.0.0.qualifier
+Bundle-Activator: org.jboss.savara.pi4soa.cdm.osgi.Activator
+Bundle-Vendor: www.jboss.org
Bundle-RequiredExecutionEnvironment: J2SE-1.5
Import-Package: org.osgi.framework;version="1.3.0"
Require-Bundle: org.pi4soa.cdl,
@@ -20,10 +20,10 @@
org.scribble.expression.xpath,
org.scribble.eclipse;resolution:=optional,
org.jboss.savara.contract.model
-Scribble-Extensions: org.scribble.pi4soa.cdm.parser.CDMTokenizer,
- org.scribble.pi4soa.cdm.parser.CDMModelParserRule,
- org.scribble.pi4soa.cdm.model.CDMNotation,
- org.scribble.pi4soa.cdm.validation.TypeReferenceValidationRule,
- org.scribble.pi4soa.cdm.editor.CDMEditorManager
-Export-Package: org.scribble.pi4soa.cdm.model,
- org.scribble.pi4soa.cdm.parser
+Scribble-Extensions: org.jboss.savara.pi4soa.cdm.parser.CDMTokenizer,
+ org.jboss.savara.pi4soa.cdm.parser.CDMModelParserRule,
+ org.jboss.savara.pi4soa.cdm.model.CDMNotation,
+ org.jboss.savara.pi4soa.cdm.validation.TypeReferenceValidationRule,
+ org.jboss.savara.pi4soa.cdm.editor.CDMEditorManager
+Export-Package: org.jboss.savara.pi4soa.cdm.model,
+ org.jboss.savara.pi4soa.cdm.parser
Modified: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/build.properties
===================================================================
--- trunk/tools/eclipse/org.scribble.pi4soa.cdm/build.properties 2010-07-06 21:48:27 UTC (rev 306)
+++ trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/build.properties 2010-07-06 22:34:21 UTC (rev 307)
@@ -1,4 +1,4 @@
source.. = src/java/
-output.. = classes/
+output.. = bin/
bin.includes = META-INF/,\
.
Copied: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/CDMDefinitions.java (from rev 306, trunk/tools/eclipse/org.scribble.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/CDMDefinitions.java)
===================================================================
--- trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/CDMDefinitions.java (rev 0)
+++ trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/CDMDefinitions.java 2010-07-06 22:34:21 UTC (rev 307)
@@ -0,0 +1,30 @@
+/*
+ * Copyright 2005-8 Pi4 Technologies Ltd
+ *
+ * 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.
+ *
+ *
+ * Change History:
+ * 17 Jun 2008 : Initial version created by gary
+ */
+package org.jboss.savara.pi4soa.cdm;
+
+/**
+ * This class provides common definitions used in the Scribble
+ * transformation of the CDM file.
+ */
+public class CDMDefinitions {
+
+ public static final String CDM_NOTATION="cdm";
+
+}
Copied: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/editor (from rev 306, trunk/tools/eclipse/org.scribble.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/editor)
Modified: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/editor/CDMEditorManager.java
===================================================================
--- trunk/tools/eclipse/org.scribble.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/editor/CDMEditorManager.java 2010-07-06 21:48:27 UTC (rev 306)
+++ trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/editor/CDMEditorManager.java 2010-07-06 22:34:21 UTC (rev 307)
@@ -17,10 +17,10 @@
* Change History:
* 19 Jun 2008 : Initial version created by gary
*/
-package org.scribble.pi4soa.cdm.editor;
+package org.jboss.savara.pi4soa.cdm.editor;
import org.eclipse.emf.ecore.EValidator;
-import org.scribble.pi4soa.cdm.model.*;
+import org.jboss.savara.pi4soa.cdm.model.*;
import org.scribble.extensions.RegistryInfo;
import org.scribble.model.ModelReference;
import org.scribble.model.SourceRef;
Copied: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/model (from rev 306, trunk/tools/eclipse/org.scribble.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/model)
Modified: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/model/CDMNotation.java
===================================================================
--- trunk/tools/eclipse/org.scribble.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/model/CDMNotation.java 2010-07-06 21:48:27 UTC (rev 306)
+++ trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/model/CDMNotation.java 2010-07-06 22:34:21 UTC (rev 307)
@@ -17,7 +17,7 @@
* Change History:
* 17 Jun 2008 : Initial version created by gary
*/
-package org.scribble.pi4soa.cdm.model;
+package org.jboss.savara.pi4soa.cdm.model;
import org.scribble.extensions.*;
import org.scribble.model.ModelReference;
Copied: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/osgi (from rev 306, trunk/tools/eclipse/org.scribble.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/osgi)
Modified: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/osgi/Activator.java
===================================================================
--- trunk/tools/eclipse/org.scribble.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/osgi/Activator.java 2010-07-06 21:48:27 UTC (rev 306)
+++ trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/osgi/Activator.java 2010-07-06 22:34:21 UTC (rev 307)
@@ -1,4 +1,4 @@
-package org.scribble.pi4soa.cdm.osgi;
+package org.jboss.savara.pi4soa.cdm.osgi;
import org.osgi.framework.BundleActivator;
import org.osgi.framework.BundleContext;
Copied: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/CDMModelParserRule.java (from rev 306, trunk/tools/eclipse/org.scribble.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/parser/CDMModelParserRule.java)
===================================================================
--- trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/CDMModelParserRule.java (rev 0)
+++ trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/CDMModelParserRule.java 2010-07-06 22:34:21 UTC (rev 307)
@@ -0,0 +1,133 @@
+/*
+ * Copyright 2007-9 Pi4 Technologies Ltd
+ *
+ * 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.
+ *
+ *
+ * Change History:
+ * 6 May 2009 : Initial version created by gary
+ */
+package org.jboss.savara.pi4soa.cdm.parser;
+
+import java.util.logging.Level;
+import java.util.logging.Logger;
+
+import org.jboss.savara.pi4soa.cdm.model.CDMNotation;
+import org.jboss.savara.pi4soa.cdm.parser.rules.ConverterContext;
+import org.jboss.savara.pi4soa.cdm.parser.rules.ConverterRule;
+import org.jboss.savara.pi4soa.cdm.parser.rules.ConverterRuleFactory;
+import org.jboss.savara.pi4soa.cdm.parser.rules.DefaultConverterContext;
+import org.scribble.conversation.model.ConversationModel;
+import org.scribble.extensions.RegistryFactory;
+import org.scribble.extensions.RegistryInfo;
+import org.scribble.model.Model;
+import org.scribble.model.admin.ModelListener;
+import org.scribble.parser.ParserContext;
+import org.scribble.parser.ParserRule;
+import org.scribble.parser.Token;
+
+/**
+ * This class provides the model parser for the CDM notation.
+ *
+ */
+(a)RegistryInfo(extension=ParserRule.class,notation=CDMNotation.NOTATION_CODE)
+public class CDMModelParserRule extends org.scribble.conversation.parser.ConversationModelParserRule {
+
+ /**
+ * The default constructor.
+ */
+ public CDMModelParserRule() {
+ //super(ParserRuleType.File);
+ }
+
+ /**
+ * This method determines whether the parser rules is
+ * appropriate to return a model object of the required
+ * type.
+ *
+ * @param type The required type
+ * @return Whether the parser rule returns a
+ * model object of the required type
+ */
+ public boolean isSupported(Class<?> type) {
+ return(type.isAssignableFrom(Model.class));
+ }
+
+ /**
+ * This method parses the description to obtain
+ * a model object of the appropriate type.
+ *
+ * @param context The context
+ * @param l The listener
+ * @return The model object
+ */
+ public Object parse(ParserContext context, ModelListener l) {
+ ConversationModel ret=null;
+
+ Token t=context.nextToken();
+
+ if (t != null && t.getObject() instanceof org.pi4soa.cdl.Package) {
+ try {
+ org.pi4soa.cdl.Package cdlpack=
+ (org.pi4soa.cdl.Package)t.getObject();
+
+ ConverterRule rule=ConverterRuleFactory.getConverter(ConversationModel.class,
+ cdlpack);
+
+ if (rule != null) {
+ ConverterContext cctxt=
+ new DefaultConverterContext(context.getSource());
+
+ ret = (ConversationModel)rule.convert(cctxt,
+ ConversationModel.class, cdlpack);
+ }
+
+ } catch(Exception e) {
+ logger.log(Level.SEVERE,
+ "Failed to load model", e);
+ }
+
+ if (logger.isLoggable(java.util.logging.Level.FINEST)) {
+
+ org.scribble.export.Exporter exporter=
+ (org.scribble.export.Exporter)
+ RegistryFactory.getRegistry().getExtension(
+ org.scribble.export.Exporter.class, null);
+
+ try {
+ org.scribble.export.text.TextFormatter formatter=
+ new org.scribble.export.text.TextFormatter();
+
+ java.io.ByteArrayOutputStream os=
+ new java.io.ByteArrayOutputStream();
+
+ formatter.setOutputStream(os);
+
+ exporter.export(context.getSource(), ret, formatter);
+
+ String str=new String(os.toByteArray());
+
+ System.out.println("EXPORTED CDM TEXT:");
+ System.out.println(str);
+
+ } catch(Exception e) {
+ e.printStackTrace();
+ }
+ }
+ }
+
+ return(ret);
+ }
+
+ private static Logger logger = Logger.getLogger("org.pi4soa.scribble.cdm.parser");
+}
Copied: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/CDMTokenizer.java (from rev 306, trunk/tools/eclipse/org.scribble.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/parser/CDMTokenizer.java)
===================================================================
--- trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/CDMTokenizer.java (rev 0)
+++ trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/CDMTokenizer.java 2010-07-06 22:34:21 UTC (rev 307)
@@ -0,0 +1,63 @@
+/*
+ * Copyright 2005-9 Pi4 Technologies Ltd
+ *
+ * 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.
+ *
+ *
+ * Change History:
+ * 6 May 2009 : Initial version created by gary
+ */
+package org.jboss.savara.pi4soa.cdm.parser;
+
+import org.jboss.savara.pi4soa.cdm.model.CDMNotation;
+import org.scribble.extensions.RegistryInfo;
+import org.scribble.model.ModelReference;
+import org.scribble.parser.*;
+
+/**
+ * This is the CDM based implementation of the tokenizer
+ * interface.
+ */
+(a)RegistryInfo(extension=Tokenizer.class,notation=CDMNotation.NOTATION_CODE)
+public class CDMTokenizer extends DefaultTokenizer {
+
+ /**
+ * The default constructor.
+ */
+ public CDMTokenizer() {
+ }
+
+ /**
+ * This method obtains a list of tokens based on the
+ * contents of the input stream.
+ *
+ * @param ref The model reference for the input source
+ * @param is The input stream
+ * @return The list of tokens
+ * @throws java.io.IOException Failed to derive
+ */
+ public java.util.List<Token> getTokens(ModelReference ref,
+ java.io.InputStream is) throws java.io.IOException {
+ java.util.List<Token> ret=new java.util.Vector<Token>();
+
+ org.pi4soa.cdl.Package cdlpack=
+ org.pi4soa.cdl.CDLManager.load(is);
+
+ if (cdlpack != null) {
+ Token t=new Token(cdlpack);
+ ret.add(t);
+ }
+
+ return(ret);
+ }
+}
Copied: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules (from rev 306, trunk/tools/eclipse/org.scribble.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/parser/rules)
Modified: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/AssignConverterRuleImpl.java
===================================================================
--- trunk/tools/eclipse/org.scribble.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/parser/rules/AssignConverterRuleImpl.java 2010-07-06 21:48:27 UTC (rev 306)
+++ trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/AssignConverterRuleImpl.java 2010-07-06 22:34:21 UTC (rev 307)
@@ -17,7 +17,7 @@
* Change History:
* 3 Jun 2009 : Initial version created by gary
*/
-package org.scribble.pi4soa.cdm.parser.rules;
+package org.jboss.savara.pi4soa.cdm.parser.rules;
import org.pi4soa.cdl.*;
import org.pi4soa.cdl.util.CDLTypeUtil;
Modified: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/ConversationConverterRuleImpl.java
===================================================================
--- trunk/tools/eclipse/org.scribble.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/parser/rules/ConversationConverterRuleImpl.java 2010-07-06 21:48:27 UTC (rev 306)
+++ trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/ConversationConverterRuleImpl.java 2010-07-06 22:34:21 UTC (rev 307)
@@ -17,7 +17,7 @@
* Change History:
* 6 Jun 2008 : Initial version created by gary
*/
-package org.scribble.pi4soa.cdm.parser.rules;
+package org.jboss.savara.pi4soa.cdm.parser.rules;
import java.util.logging.Logger;
Modified: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/ConversationInteractionConverterRuleImpl.java
===================================================================
--- trunk/tools/eclipse/org.scribble.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/parser/rules/ConversationInteractionConverterRuleImpl.java 2010-07-06 21:48:27 UTC (rev 306)
+++ trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/ConversationInteractionConverterRuleImpl.java 2010-07-06 22:34:21 UTC (rev 307)
@@ -17,7 +17,7 @@
* Change History:
* 6 Jun 2008 : Initial version created by gary
*/
-package org.scribble.pi4soa.cdm.parser.rules;
+package org.jboss.savara.pi4soa.cdm.parser.rules;
import java.util.logging.Logger;
Modified: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/ConversationModelConverterRuleImpl.java
===================================================================
--- trunk/tools/eclipse/org.scribble.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/parser/rules/ConversationModelConverterRuleImpl.java 2010-07-06 21:48:27 UTC (rev 306)
+++ trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/ConversationModelConverterRuleImpl.java 2010-07-06 22:34:21 UTC (rev 307)
@@ -17,7 +17,7 @@
* Change History:
* 31 Jul 2008 : Initial version created by gary
*/
-package org.scribble.pi4soa.cdm.parser.rules;
+package org.jboss.savara.pi4soa.cdm.parser.rules;
import java.util.logging.Logger;
Modified: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/ConverterContext.java
===================================================================
--- trunk/tools/eclipse/org.scribble.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/parser/rules/ConverterContext.java 2010-07-06 21:48:27 UTC (rev 306)
+++ trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/ConverterContext.java 2010-07-06 22:34:21 UTC (rev 307)
@@ -17,7 +17,7 @@
* Change History:
* 6 Jun 2008 : Initial version created by gary
*/
-package org.scribble.pi4soa.cdm.parser.rules;
+package org.jboss.savara.pi4soa.cdm.parser.rules;
import org.scribble.model.*;
import org.scribble.conversation.model.*;
Modified: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/ConverterRule.java
===================================================================
--- trunk/tools/eclipse/org.scribble.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/parser/rules/ConverterRule.java 2010-07-06 21:48:27 UTC (rev 306)
+++ trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/ConverterRule.java 2010-07-06 22:34:21 UTC (rev 307)
@@ -17,7 +17,7 @@
* Change History:
* 6 Jun 2008 : Initial version created by gary
*/
-package org.scribble.pi4soa.cdm.parser.rules;
+package org.jboss.savara.pi4soa.cdm.parser.rules;
/**
* This interface represents a CDM to Scribble conversation
Modified: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/ConverterRuleFactory.java
===================================================================
--- trunk/tools/eclipse/org.scribble.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/parser/rules/ConverterRuleFactory.java 2010-07-06 21:48:27 UTC (rev 306)
+++ trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/ConverterRuleFactory.java 2010-07-06 22:34:21 UTC (rev 307)
@@ -17,7 +17,7 @@
* Change History:
* 6 Jun 2008 : Initial version created by gary
*/
-package org.scribble.pi4soa.cdm.parser.rules;
+package org.jboss.savara.pi4soa.cdm.parser.rules;
/**
* This class represents a factory for converter rules.
Modified: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/ConverterUtil.java
===================================================================
--- trunk/tools/eclipse/org.scribble.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/parser/rules/ConverterUtil.java 2010-07-06 21:48:27 UTC (rev 306)
+++ trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/ConverterUtil.java 2010-07-06 22:34:21 UTC (rev 307)
@@ -17,7 +17,7 @@
* Change History:
* 31 Jul 2008 : Initial version created by gary
*/
-package org.scribble.pi4soa.cdm.parser.rules;
+package org.jboss.savara.pi4soa.cdm.parser.rules;
import org.scribble.model.*;
Modified: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/DefaultConverterContext.java
===================================================================
--- trunk/tools/eclipse/org.scribble.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/parser/rules/DefaultConverterContext.java 2010-07-06 21:48:27 UTC (rev 306)
+++ trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/DefaultConverterContext.java 2010-07-06 22:34:21 UTC (rev 307)
@@ -17,7 +17,7 @@
* Change History:
* 6 Jun 2008 : Initial version created by gary
*/
-package org.scribble.pi4soa.cdm.parser.rules;
+package org.jboss.savara.pi4soa.cdm.parser.rules;
import java.util.logging.Logger;
import org.scribble.util.Scope;
Modified: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/FinalizeConverterRuleImpl.java
===================================================================
--- trunk/tools/eclipse/org.scribble.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/parser/rules/FinalizeConverterRuleImpl.java 2010-07-06 21:48:27 UTC (rev 306)
+++ trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/FinalizeConverterRuleImpl.java 2010-07-06 22:34:21 UTC (rev 307)
@@ -17,7 +17,7 @@
* Change History:
* 1 Jun 2009 : Initial version created by gary
*/
-package org.scribble.pi4soa.cdm.parser.rules;
+package org.jboss.savara.pi4soa.cdm.parser.rules;
import org.pi4soa.cdl.*;
import org.pi4soa.cdl.util.CDLTypeUtil;
Modified: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/FinalizerHandlerConverterRuleImpl.java
===================================================================
--- trunk/tools/eclipse/org.scribble.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/parser/rules/FinalizerHandlerConverterRuleImpl.java 2010-07-06 21:48:27 UTC (rev 306)
+++ trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/FinalizerHandlerConverterRuleImpl.java 2010-07-06 22:34:21 UTC (rev 307)
@@ -17,7 +17,7 @@
* Change History:
* 1 Jun 2009 : Initial version created by gary
*/
-package org.scribble.pi4soa.cdm.parser.rules;
+package org.jboss.savara.pi4soa.cdm.parser.rules;
import java.util.logging.Logger;
Modified: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/IfConverterRuleImpl.java
===================================================================
--- trunk/tools/eclipse/org.scribble.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/parser/rules/IfConverterRuleImpl.java 2010-07-06 21:48:27 UTC (rev 306)
+++ trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/IfConverterRuleImpl.java 2010-07-06 22:34:21 UTC (rev 307)
@@ -17,7 +17,7 @@
* Change History:
* 6 Jun 2008 : Initial version created by gary
*/
-package org.scribble.pi4soa.cdm.parser.rules;
+package org.jboss.savara.pi4soa.cdm.parser.rules;
import org.pi4soa.cdl.*;
import org.pi4soa.cdl.util.CDLTypeUtil;
Modified: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/IfOrWhenConverterRuleImpl.java
===================================================================
--- trunk/tools/eclipse/org.scribble.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/parser/rules/IfOrWhenConverterRuleImpl.java 2010-07-06 21:48:27 UTC (rev 306)
+++ trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/IfOrWhenConverterRuleImpl.java 2010-07-06 22:34:21 UTC (rev 307)
@@ -17,7 +17,7 @@
* Change History:
* 6 Jun 2008 : Initial version created by gary
*/
-package org.scribble.pi4soa.cdm.parser.rules;
+package org.jboss.savara.pi4soa.cdm.parser.rules;
import org.pi4soa.cdl.*;
import org.pi4soa.cdl.util.CDLTypeUtil;
Modified: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/ParallelConverterRuleImpl.java
===================================================================
--- trunk/tools/eclipse/org.scribble.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/parser/rules/ParallelConverterRuleImpl.java 2010-07-06 21:48:27 UTC (rev 306)
+++ trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/ParallelConverterRuleImpl.java 2010-07-06 22:34:21 UTC (rev 307)
@@ -17,7 +17,7 @@
* Change History:
* 6 Jun 2008 : Initial version created by gary
*/
-package org.scribble.pi4soa.cdm.parser.rules;
+package org.jboss.savara.pi4soa.cdm.parser.rules;
import org.pi4soa.cdl.*;
import org.pi4soa.cdl.util.CDLTypeUtil;
Modified: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/PerformConverterRuleImpl.java
===================================================================
--- trunk/tools/eclipse/org.scribble.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/parser/rules/PerformConverterRuleImpl.java 2010-07-06 21:48:27 UTC (rev 306)
+++ trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/PerformConverterRuleImpl.java 2010-07-06 22:34:21 UTC (rev 307)
@@ -17,7 +17,7 @@
* Change History:
* 27 Jun 2008 : Initial version created by gary
*/
-package org.scribble.pi4soa.cdm.parser.rules;
+package org.jboss.savara.pi4soa.cdm.parser.rules;
import java.util.logging.Logger;
Modified: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/SequenceConverterRuleImpl.java
===================================================================
--- trunk/tools/eclipse/org.scribble.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/parser/rules/SequenceConverterRuleImpl.java 2010-07-06 21:48:27 UTC (rev 306)
+++ trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/SequenceConverterRuleImpl.java 2010-07-06 22:34:21 UTC (rev 307)
@@ -17,7 +17,7 @@
* Change History:
* 6 Jun 2008 : Initial version created by gary
*/
-package org.scribble.pi4soa.cdm.parser.rules;
+package org.jboss.savara.pi4soa.cdm.parser.rules;
import org.pi4soa.cdl.*;
import org.pi4soa.cdl.util.CDLTypeUtil;
Modified: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/WhenConverterRuleImpl.java
===================================================================
--- trunk/tools/eclipse/org.scribble.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/parser/rules/WhenConverterRuleImpl.java 2010-07-06 21:48:27 UTC (rev 306)
+++ trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/WhenConverterRuleImpl.java 2010-07-06 22:34:21 UTC (rev 307)
@@ -17,7 +17,7 @@
* Change History:
* 6 Jun 2008 : Initial version created by gary
*/
-package org.scribble.pi4soa.cdm.parser.rules;
+package org.jboss.savara.pi4soa.cdm.parser.rules;
import org.pi4soa.cdl.*;
import org.pi4soa.cdl.util.CDLTypeUtil;
Modified: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/WhileConverterRuleImpl.java
===================================================================
--- trunk/tools/eclipse/org.scribble.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/parser/rules/WhileConverterRuleImpl.java 2010-07-06 21:48:27 UTC (rev 306)
+++ trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/parser/rules/WhileConverterRuleImpl.java 2010-07-06 22:34:21 UTC (rev 307)
@@ -17,7 +17,7 @@
* Change History:
* 6 Jun 2008 : Initial version created by gary
*/
-package org.scribble.pi4soa.cdm.parser.rules;
+package org.jboss.savara.pi4soa.cdm.parser.rules;
import org.pi4soa.cdl.*;
import org.pi4soa.cdl.util.CDLTypeUtil;
Copied: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/validation (from rev 306, trunk/tools/eclipse/org.scribble.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/validation)
Modified: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/validation/TypeReferenceValidationRule.java
===================================================================
--- trunk/tools/eclipse/org.scribble.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/validation/TypeReferenceValidationRule.java 2010-07-06 21:48:27 UTC (rev 306)
+++ trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/jboss/savara/pi4soa/cdm/validation/TypeReferenceValidationRule.java 2010-07-06 22:34:21 UTC (rev 307)
@@ -17,9 +17,9 @@
* Change History:
* 2 Nov 2007 : Initial version created by gary
*/
-package org.scribble.pi4soa.cdm.validation;
+package org.jboss.savara.pi4soa.cdm.validation;
-import org.scribble.pi4soa.cdm.model.CDMNotation;
+import org.jboss.savara.pi4soa.cdm.model.CDMNotation;
import org.scribble.extensions.*;
import org.scribble.model.*;
import org.scribble.model.admin.ModelListener;
Deleted: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/CDMDefinitions.java
===================================================================
--- trunk/tools/eclipse/org.scribble.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/CDMDefinitions.java 2010-07-06 21:48:27 UTC (rev 306)
+++ trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/CDMDefinitions.java 2010-07-06 22:34:21 UTC (rev 307)
@@ -1,30 +0,0 @@
-/*
- * Copyright 2005-8 Pi4 Technologies Ltd
- *
- * 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.
- *
- *
- * Change History:
- * 17 Jun 2008 : Initial version created by gary
- */
-package org.scribble.pi4soa.cdm;
-
-/**
- * This class provides common definitions used in the Scribble
- * transformation of the CDM file.
- */
-public class CDMDefinitions {
-
- public static final String CDM_NOTATION="cdm";
-
-}
Deleted: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/parser/CDMModelParserRule.java
===================================================================
--- trunk/tools/eclipse/org.scribble.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/parser/CDMModelParserRule.java 2010-07-06 21:48:27 UTC (rev 306)
+++ trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/parser/CDMModelParserRule.java 2010-07-06 22:34:21 UTC (rev 307)
@@ -1,133 +0,0 @@
-/*
- * Copyright 2007-9 Pi4 Technologies Ltd
- *
- * 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.
- *
- *
- * Change History:
- * 6 May 2009 : Initial version created by gary
- */
-package org.scribble.pi4soa.cdm.parser;
-
-import java.util.logging.Level;
-import java.util.logging.Logger;
-
-import org.scribble.conversation.model.ConversationModel;
-import org.scribble.extensions.RegistryFactory;
-import org.scribble.extensions.RegistryInfo;
-import org.scribble.model.Model;
-import org.scribble.model.admin.ModelListener;
-import org.scribble.parser.ParserContext;
-import org.scribble.parser.ParserRule;
-import org.scribble.parser.Token;
-import org.scribble.pi4soa.cdm.model.CDMNotation;
-import org.scribble.pi4soa.cdm.parser.rules.ConverterContext;
-import org.scribble.pi4soa.cdm.parser.rules.ConverterRule;
-import org.scribble.pi4soa.cdm.parser.rules.ConverterRuleFactory;
-import org.scribble.pi4soa.cdm.parser.rules.DefaultConverterContext;
-
-/**
- * This class provides the model parser for the CDM notation.
- *
- */
-(a)RegistryInfo(extension=ParserRule.class,notation=CDMNotation.NOTATION_CODE)
-public class CDMModelParserRule extends org.scribble.conversation.parser.ConversationModelParserRule {
-
- /**
- * The default constructor.
- */
- public CDMModelParserRule() {
- //super(ParserRuleType.File);
- }
-
- /**
- * This method determines whether the parser rules is
- * appropriate to return a model object of the required
- * type.
- *
- * @param type The required type
- * @return Whether the parser rule returns a
- * model object of the required type
- */
- public boolean isSupported(Class<?> type) {
- return(type.isAssignableFrom(Model.class));
- }
-
- /**
- * This method parses the description to obtain
- * a model object of the appropriate type.
- *
- * @param context The context
- * @param l The listener
- * @return The model object
- */
- public Object parse(ParserContext context, ModelListener l) {
- ConversationModel ret=null;
-
- Token t=context.nextToken();
-
- if (t != null && t.getObject() instanceof org.pi4soa.cdl.Package) {
- try {
- org.pi4soa.cdl.Package cdlpack=
- (org.pi4soa.cdl.Package)t.getObject();
-
- ConverterRule rule=ConverterRuleFactory.getConverter(ConversationModel.class,
- cdlpack);
-
- if (rule != null) {
- ConverterContext cctxt=
- new DefaultConverterContext(context.getSource());
-
- ret = (ConversationModel)rule.convert(cctxt,
- ConversationModel.class, cdlpack);
- }
-
- } catch(Exception e) {
- logger.log(Level.SEVERE,
- "Failed to load model", e);
- }
-
- if (logger.isLoggable(java.util.logging.Level.FINEST)) {
-
- org.scribble.export.Exporter exporter=
- (org.scribble.export.Exporter)
- RegistryFactory.getRegistry().getExtension(
- org.scribble.export.Exporter.class, null);
-
- try {
- org.scribble.export.text.TextFormatter formatter=
- new org.scribble.export.text.TextFormatter();
-
- java.io.ByteArrayOutputStream os=
- new java.io.ByteArrayOutputStream();
-
- formatter.setOutputStream(os);
-
- exporter.export(context.getSource(), ret, formatter);
-
- String str=new String(os.toByteArray());
-
- System.out.println("EXPORTED CDM TEXT:");
- System.out.println(str);
-
- } catch(Exception e) {
- e.printStackTrace();
- }
- }
- }
-
- return(ret);
- }
-
- private static Logger logger = Logger.getLogger("org.pi4soa.scribble.cdm.parser");
-}
Deleted: trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/parser/CDMTokenizer.java
===================================================================
--- trunk/tools/eclipse/org.scribble.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/parser/CDMTokenizer.java 2010-07-06 21:48:27 UTC (rev 306)
+++ trunk/tools/plugins/org.jboss.savara.pi4soa.cdm/src/java/org/scribble/pi4soa/cdm/parser/CDMTokenizer.java 2010-07-06 22:34:21 UTC (rev 307)
@@ -1,63 +0,0 @@
-/*
- * Copyright 2005-9 Pi4 Technologies Ltd
- *
- * 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.
- *
- *
- * Change History:
- * 6 May 2009 : Initial version created by gary
- */
-package org.scribble.pi4soa.cdm.parser;
-
-import org.scribble.pi4soa.cdm.model.CDMNotation;
-import org.scribble.extensions.RegistryInfo;
-import org.scribble.model.ModelReference;
-import org.scribble.parser.*;
-
-/**
- * This is the CDM based implementation of the tokenizer
- * interface.
- */
-(a)RegistryInfo(extension=Tokenizer.class,notation=CDMNotation.NOTATION_CODE)
-public class CDMTokenizer extends DefaultTokenizer {
-
- /**
- * The default constructor.
- */
- public CDMTokenizer() {
- }
-
- /**
- * This method obtains a list of tokens based on the
- * contents of the input stream.
- *
- * @param ref The model reference for the input source
- * @param is The input stream
- * @return The list of tokens
- * @throws java.io.IOException Failed to derive
- */
- public java.util.List<Token> getTokens(ModelReference ref,
- java.io.InputStream is) throws java.io.IOException {
- java.util.List<Token> ret=new java.util.Vector<Token>();
-
- org.pi4soa.cdl.Package cdlpack=
- org.pi4soa.cdl.CDLManager.load(is);
-
- if (cdlpack != null) {
- Token t=new Token(cdlpack);
- ret.add(t);
- }
-
- return(ret);
- }
-}
Modified: trunk/tools/plugins/org.jboss.savara.tools.bpel/META-INF/MANIFEST.MF
===================================================================
--- trunk/tools/plugins/org.jboss.savara.tools.bpel/META-INF/MANIFEST.MF 2010-07-06 21:48:27 UTC (rev 306)
+++ trunk/tools/plugins/org.jboss.savara.tools.bpel/META-INF/MANIFEST.MF 2010-07-06 22:34:21 UTC (rev 307)
@@ -16,7 +16,7 @@
org.scribble.conversation.parser,
org.apache.commons.logging,
org.scribble.expression.xpath,
- org.scribble.pi4soa.cdm;resolution:=optional,
+ org.jboss.savara.pi4soa.cdm;resolution:=optional,
org.jboss.savara.contract.model,
org.jboss.savara.tools.wsdl,
org.eclipse.ui.ide,
Modified: trunk/tools/plugins/org.jboss.savara.tools.bpel/src/plugintest/org/jboss/savara/tools/bpel/generator/GeneratorTest.java
===================================================================
--- trunk/tools/plugins/org.jboss.savara.tools.bpel/src/plugintest/org/jboss/savara/tools/bpel/generator/GeneratorTest.java 2010-07-06 21:48:27 UTC (rev 306)
+++ trunk/tools/plugins/org.jboss.savara.tools.bpel/src/plugintest/org/jboss/savara/tools/bpel/generator/GeneratorTest.java 2010-07-06 22:34:21 UTC (rev 307)
@@ -24,7 +24,7 @@
import org.jboss.savara.tools.bpel.model.BPELNotation;
import org.jboss.savara.tools.bpel.model.DefaultBPELLanguageModel;
import org.jboss.savara.tools.bpel.util.XMLUtils;
-import org.scribble.pi4soa.cdm.model.CDMNotation;
+import org.jboss.savara.pi4soa.cdm.model.CDMNotation;
import org.scribble.extensions.RegistryFactory;
import org.scribble.model.Definition;
import org.scribble.model.ModelReference;
13 years, 10 months
savara SVN: r306 - in trunk/tools: tests and 1 other directory.
by do-not-reply@jboss.org
Author: objectiser
Date: 2010-07-06 17:48:27 -0400 (Tue, 06 Jul 2010)
New Revision: 306
Added:
trunk/tools/tests/org.jboss.savara.tools.wsdl.tests/
Removed:
trunk/tools/eclipse/org.jboss.savara.tools.wsdl.tests/
Log:
Copied: trunk/tools/tests/org.jboss.savara.tools.wsdl.tests (from rev 305, trunk/tools/eclipse/org.jboss.savara.tools.wsdl.tests)
13 years, 10 months
savara SVN: r305 - in trunk/tools: plugins and 1 other directory.
by do-not-reply@jboss.org
Author: objectiser
Date: 2010-07-06 17:47:27 -0400 (Tue, 06 Jul 2010)
New Revision: 305
Added:
trunk/tools/plugins/org.jboss.savara.tools.wsdl/
Removed:
trunk/tools/eclipse/org.jboss.savara.tools.wsdl/
Log:
Copied: trunk/tools/plugins/org.jboss.savara.tools.wsdl (from rev 304, trunk/tools/eclipse/org.jboss.savara.tools.wsdl)
13 years, 10 months