summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRainer Pielmann2012-02-01 09:07:12 (EST)
committerStephan Born2012-04-24 04:30:11 (EDT)
commit5e240e5f27c6f56192410e40bdad4051d19236e3 (patch)
tree19a89227d1e8595d4a7249e3db425b99238054dd
parentaa07ea945b24bc2c695f59eb561ec71dde9a5346 (diff)
downloadorg.eclipse.stardust.ide-5e240e5f27c6f56192410e40bdad4051d19236e3.zip
org.eclipse.stardust.ide-5e240e5f27c6f56192410e40bdad4051d19236e3.tar.gz
org.eclipse.stardust.ide-5e240e5f27c6f56192410e40bdad4051d19236e3.tar.bz2
Jira-ID: CRNT-22383 Merge changes done on b_dev_6_0_x after 6.0.2.GA (6.0.2.2-r49368) through 6.0.3.GA (6.0.3.6-r50668) and beyond (6.0.x HEAD) to 7.0 (trunk) - moonglow / simulation / tate / tds (org.eclipse.stardust.modeling.templates.basic)
git-svn-id: http://emeafrazerg/svn/ipp/product/trunk/stardust/ide@53308 8100b5e0-4d52-466c-ae9c-bdeccbdeaf6b
-rw-r--r--modeling/org.eclipse.stardust.modeling.templates.basic/html/dynamicspawn.html11
-rw-r--r--modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/Templates_Basic_Messages.java96
-rw-r--r--modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/BasicControlFlowPatterns.java7
-rw-r--r--modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/DynamicSpawnTemplateFactory.java32
-rw-r--r--modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/ExclusiveChoiceAndMergeTemplateAdapter.java37
-rw-r--r--modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/ExclusiveChoiceTemplateAdapter.java39
-rw-r--r--modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/GenericPatternsFactory.java8
-rw-r--r--modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/LoopTemplateAdapter.java41
-rw-r--r--modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/ParallelSplitAndSynchronizationTemplateAdapter.java37
-rw-r--r--modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/ParallelSplitTemplateAdapter.java38
-rw-r--r--modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/SequenceTemplateAdapter.java37
-rw-r--r--modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/templates-basic-messages.properties46
-rw-r--r--modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ExclusiveChoiceAndMergeTemplatePage.java16
-rw-r--r--modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ExclusiveChoiceAndMergeTemplateWizard.java23
-rw-r--r--modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ExclusiveChoiceTemplatePage.java16
-rw-r--r--modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ExclusiveChoiceTemplateWizard.java15
-rw-r--r--modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/LoopTemplatePage.java28
-rw-r--r--modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/LoopTemplateWizard.java23
-rw-r--r--modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ParallelSplitAndSynchronizationTemplatePage.java18
-rw-r--r--modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ParallelSplitAndSynchronizationTemplateWizard.java23
-rw-r--r--modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ParallelSplitTemplatePage.java18
-rw-r--r--modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ParallelSplitTemplateWizard.java15
-rw-r--r--modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/SequenceTemplatePage.java26
-rw-r--r--modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/SequenceTemplateWizard.java19
24 files changed, 398 insertions, 271 deletions
diff --git a/modeling/org.eclipse.stardust.modeling.templates.basic/html/dynamicspawn.html b/modeling/org.eclipse.stardust.modeling.templates.basic/html/dynamicspawn.html
new file mode 100644
index 0000000..1a3c36e
--- /dev/null
+++ b/modeling/org.eclipse.stardust.modeling.templates.basic/html/dynamicspawn.html
@@ -0,0 +1,11 @@
+<title>Infinity Process Platform Online Documentation</title>
+<h1>Dynamic Spawn Pattern</h1>
+<h2>Description</h2>
+<p>This is a pattern to dynamically spawn a subprocess for a list of entries and pass the entries to the subprocess, execute those and join them again.</p>
+<h2>Parameter</h2>
+<ul>
+ <li>Implementation Process</li>
+</ul>
+<h2>Example</h2>
+<img src="/images/dynamicspawn.jpg"></img>
+
diff --git a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/Templates_Basic_Messages.java b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/Templates_Basic_Messages.java
new file mode 100644
index 0000000..80c9074
--- /dev/null
+++ b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/Templates_Basic_Messages.java
@@ -0,0 +1,96 @@
+/*******************************************************************************
+ * Copyright (c) 2011 SunGard CSA LLC and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * SunGard CSA LLC - initial API and implementation and/or initial documentation
+ *******************************************************************************/
+package org.eclipse.stardust.modeling.templates.basic;
+
+import org.eclipse.osgi.util.NLS;
+
+public class Templates_Basic_Messages extends NLS {
+ private static final String BUNDLE_NAME = "org.eclipse.stardust.modeling.templates.basic.templates-basic-messages"; //$NON-NLS-1$
+
+ public static String COMBO_BOX_HORIZONTAL;
+
+ public static String COMBO_BOX_VERTICAL;
+
+ public static String ERR_MSG_PLEASE_PROVIDE_A_LOOP_CONDITION;
+
+ public static String ERR_MSG_PLEASE_PROVIDE_A_VALID_NUMBER_OF_ACTIVITIES;
+
+ public static String LBL_TXT_ACTIVITY_KIND;
+
+ public static String LBL_TXT_LOOP_CONDITIONS;
+
+ public static String LBL_TXT_NUMBER_OF_ACTIVITIES;
+
+ public static String LBL_TXT_ORIENTATION;
+
+ public static String TXT_APPLY_PARALLEL_SPLIT_TEMPLATE;
+
+ public static String TXT_AND_SPLIT_TEMPLATE;
+
+ public static String TXT_APPLICATION_ACTIVITY;
+
+ public static String TXT_APPLY_EXCLUSIVE_CHOICE_AND_MERGE_TEMPLATE;
+
+ public static String TXT_APPLY_EXCLUSIVE_CHOICE_TEMPLATE;
+
+ public static String TXT_APPLY_LOOP_TEMPLATE;
+
+ public static String TXT_ADVANCED_BRANCHING_AND_SYNCHRONIZATION_PATTERNS;
+
+ public static String TXT_APPLY_SEQUENCE_TEMPLATE;
+
+ public static String TXT_APPLY_SPLIT_AND_SYNCHRONIZATION_TEMPLATE;
+
+ public static String TXT_BASIC_CONTROL_FLOW_PATTERN;
+
+ public static String TXT_ECLUSIVE_CHOICE_AND_MERGE;
+
+ public static String TXT_EXCLUSIVE_CHOICE;
+
+ public static String TXT_EXCLUSIVE_CHOICE_AND_MERGE_PATTERN;
+
+ public static String TXT_EXCLUSIVE_CHOICE_AND_MERGE_TEMPLATE;
+
+ public static String TXT_EXCLUSIVE_CHOICE_PATTERN;
+
+ public static String TXT_EXCLUSIVE_CHOICE_TEMPLATE;
+
+ public static String TXT_DYNAMIC_SPAWN;
+
+ public static String TXT_GENERIC_PATTERNS;
+
+ public static String TXT_LOOP;
+
+ public static String TXT_LOOP_PATTERN;
+
+ public static String TXT_LOOP_TEMPLATE;
+
+ public static String TXT_PARALLEL_SPLIT;
+
+ public static String TXT_PARALLEL_SPLIT_AND_SYNC;
+
+ public static String TXT_PARALLEL_SPLIT_PATTERN;
+
+ public static String TXT_SEQUENCE;
+
+ public static String TXT_SEQUENCE_PATTERN;
+
+ public static String TXT_SEQUENCE_TEMPLATE;
+
+ public static String TXT_VERTICAL;
+ static {
+ // initialize resource bundle
+ NLS.initializeMessages(BUNDLE_NAME, Templates_Basic_Messages.class);
+ }
+
+ private Templates_Basic_Messages() {
+ }
+}
diff --git a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/BasicControlFlowPatterns.java b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/BasicControlFlowPatterns.java
index 15f1644..1cb62c9 100644
--- a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/BasicControlFlowPatterns.java
+++ b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/BasicControlFlowPatterns.java
@@ -12,6 +12,7 @@ package org.eclipse.stardust.modeling.templates.basic.factories;
import java.util.Map;
+import org.eclipse.stardust.modeling.templates.basic.Templates_Basic_Messages;
import org.eclipse.stardust.modeling.templates.spi.ITemplate;
import org.eclipse.stardust.modeling.templates.spi.ITemplateFactory;
@@ -27,17 +28,17 @@ public class BasicControlFlowPatterns implements ITemplateFactory
public String getDescription()
{
- return "Basic Control Flow Patterns";
+ return Templates_Basic_Messages.TXT_BASIC_CONTROL_FLOW_PATTERN;
}
public String getId()
{
- return "Basic Control Flow Patterns";
+ return "Basic Control Flow Patterns"; //$NON-NLS-1$
}
public String getName()
{
- return "Basic Control Flow Patterns";
+ return Templates_Basic_Messages.TXT_BASIC_CONTROL_FLOW_PATTERN;
}
public ITemplateFactory getParentFactory()
diff --git a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/DynamicSpawnTemplateFactory.java b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/DynamicSpawnTemplateFactory.java
index 9ee9f59..916b9b9 100644
--- a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/DynamicSpawnTemplateFactory.java
+++ b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/DynamicSpawnTemplateFactory.java
@@ -11,7 +11,10 @@
package org.eclipse.stardust.modeling.templates.basic.factories;
import org.eclipse.emf.ecore.resource.URIConverter;
+import org.eclipse.stardust.modeling.templates.basic.Templates_Basic_Messages;
import org.eclipse.stardust.modeling.templates.defaulttemplate.TemplateFactory;
+import org.eclipse.stardust.modeling.templates.defaulttemplate.TemplateHelper;
+import org.eclipse.stardust.modeling.templates.spi.ITemplate;
public class DynamicSpawnTemplateFactory extends TemplateFactory
@@ -22,10 +25,37 @@ public class DynamicSpawnTemplateFactory extends TemplateFactory
return new POCClasspathUriConverter();
}
+ public ITemplate[] getTemplates()
+ {
+ ITemplate[] templates = super.getTemplates();
+ for (int i = 0; i < templates.length; i++)
+ {
+ ITemplate template = templates[i];
+ if (template.getId().equals("dynamicSpawn")) //$NON-NLS-1$
+ {
+ template
+ .setName(Templates_Basic_Messages.TXT_DYNAMIC_SPAWN);
+ }
+ }
+ return templates;
+ }
+
public String getId()
{
- return "Advanced Branching and Synchronization Patterns";
+ return "Advanced Branching and Synchronization Patterns"; //$NON-NLS-1$
+ }
+
+ public String getName()
+ {
+ return Templates_Basic_Messages.TXT_ADVANCED_BRANCHING_AND_SYNCHRONIZATION_PATTERNS;
}
+
+ public String getDescription()
+ {
+ return TemplateHelper.readDescriptionFromBundle(
+ "org.eclipse.stardust.modeling.templates.basic.nl", "dynamicspawn.html", this); //$NON-NLS-1$ //$NON-NLS-2$
+ }
+
diff --git a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/ExclusiveChoiceAndMergeTemplateAdapter.java b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/ExclusiveChoiceAndMergeTemplateAdapter.java
index 483dc38..f1739de 100644
--- a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/ExclusiveChoiceAndMergeTemplateAdapter.java
+++ b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/ExclusiveChoiceAndMergeTemplateAdapter.java
@@ -17,6 +17,7 @@ import org.eclipse.stardust.model.xpdl.carnot.DiagramType;
import org.eclipse.stardust.model.xpdl.carnot.ModelType;
import org.eclipse.stardust.modeling.core.editors.WorkflowModelEditor;
import org.eclipse.stardust.modeling.repository.common.ImportCancelledException;
+import org.eclipse.stardust.modeling.templates.basic.Templates_Basic_Messages;
import org.eclipse.stardust.modeling.templates.basic.ui.ExclusiveChoiceAndMergeTemplateWizard;
import org.eclipse.stardust.modeling.templates.defaulttemplate.TemplateHelper;
import org.eclipse.stardust.modeling.templates.spi.ITemplate;
@@ -37,39 +38,19 @@ public class ExclusiveChoiceAndMergeTemplateAdapter implements ITemplate
public String getDescription()
{
- String description = null;
- try
- {
- description = TemplateHelper.readResourceToString("/html/exclusivechoiceandmerge.html", parentTemplateFactory);
- }
- catch (Throwable e)
- {
- description = null;
- }
- if (description != null) {
- return description;
- }
- return "<h1><b>Exclusive Choice and Merge with N-Threads</b></h1>" +
- "<p><b>Description</b><p>" +
- "This pattern consists of a start activity which spawns via <i>XOR</i> to N threads with one activity each and joins via <i>XOR</i> to one end activity." +
- "<p><b>Parameter</b></p>" +
- "<ul>" +
- " <li>Number of activities</li>" +
- " <li>Type of activity (Default: Application Activity)</li>" +
- "</ul>" +
- "<p><b>Example</b></p>" +
- "<img src=\"/images/exclusivesplitandmerge.JPG\"\\>";
+ return TemplateHelper.readDescriptionFromBundle(
+ "com.infinity.bpm.modeling.templates.basic.nl", //$NON-NLS-1$
+ "exclusivechoiceandmerge.html", parentTemplateFactory); //$NON-NLS-1$
}
-
public String getId()
{
- return "Exclusive Choice and Merge";
+ return "Exclusive Choice and Merge"; //$NON-NLS-1$
}
public String getName()
{
- return "Exclusive Choice and Merge";
+ return Templates_Basic_Messages.TXT_ECLUSIVE_CHOICE_AND_MERGE;
}
public String getCategory()
@@ -114,6 +95,12 @@ public class ExclusiveChoiceAndMergeTemplateAdapter implements ITemplate
{
return parentTemplateFactory;
}
+
+ public void setName(String name)
+ {
+ // TODO Auto-generated method stub
+
+ }
diff --git a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/ExclusiveChoiceTemplateAdapter.java b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/ExclusiveChoiceTemplateAdapter.java
index 9139b1d..db62c13 100644
--- a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/ExclusiveChoiceTemplateAdapter.java
+++ b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/ExclusiveChoiceTemplateAdapter.java
@@ -17,6 +17,7 @@ import org.eclipse.stardust.model.xpdl.carnot.DiagramType;
import org.eclipse.stardust.model.xpdl.carnot.ModelType;
import org.eclipse.stardust.modeling.core.editors.WorkflowModelEditor;
import org.eclipse.stardust.modeling.repository.common.ImportCancelledException;
+import org.eclipse.stardust.modeling.templates.basic.Templates_Basic_Messages;
import org.eclipse.stardust.modeling.templates.basic.ui.ExclusiveChoiceTemplateWizard;
import org.eclipse.stardust.modeling.templates.defaulttemplate.TemplateHelper;
import org.eclipse.stardust.modeling.templates.spi.ITemplate;
@@ -37,41 +38,21 @@ public class ExclusiveChoiceTemplateAdapter implements ITemplate
public String getDescription()
{
- String description = null;
- try
- {
- description = TemplateHelper.readResourceToString("/html/exclusivechoice.html", parentTemplateFactory);
- }
- catch (Throwable e)
- {
- description = null;
- }
- if (description != null) {
- return description;
- }
- return "<h1><b>Exclusive Choice with N-Threads</b></h1>" +
- "<p><b>Description</b><p>" +
- "This pattern consists of a start activity which spawns via <i>XOR</i> to N threads." +
- "<p><b>Parameter</b></p>" +
- "<ul>" +
- " <li>Number of activities</li>" +
- " <li>Type of activity (Default: Application Activity)</li>" +
- "</ul>" +
- "<p><b>Example</b></p>" +
- "<img src=\"/images/exclusivechoice.JPG\"\\>";
- }
-
+ return TemplateHelper.readDescriptionFromBundle(
+ "com.infinity.bpm.modeling.templates.basic.nl", "exclusivechoice.html", //$NON-NLS-1$ //$NON-NLS-2$
+ parentTemplateFactory);
+ }
public String getId()
{
- return "Exclusive Choice";
+ return "Exclusive Choice"; //$NON-NLS-1$
}
public String getName()
{
- return "Exclusive Choice";
+ return Templates_Basic_Messages.TXT_EXCLUSIVE_CHOICE;
}
public String getCategory()
@@ -116,6 +97,12 @@ public class ExclusiveChoiceTemplateAdapter implements ITemplate
{
return parentTemplateFactory;
}
+
+ public void setName(String name)
+ {
+ // TODO Auto-generated method stub
+
+ }
diff --git a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/GenericPatternsFactory.java b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/GenericPatternsFactory.java
index f28c6ae..bc96dce 100644
--- a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/GenericPatternsFactory.java
+++ b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/GenericPatternsFactory.java
@@ -13,7 +13,7 @@ package org.eclipse.stardust.modeling.templates.basic.factories;
import java.util.HashMap;
import java.util.Map;
-import org.eclipse.stardust.modeling.templates.defaulttemplate.TemplateFactory;
+import org.eclipse.stardust.modeling.templates.basic.Templates_Basic_Messages;
import org.eclipse.stardust.modeling.templates.spi.ITemplate;
import org.eclipse.stardust.modeling.templates.spi.ITemplateFactory;
@@ -29,17 +29,17 @@ public class GenericPatternsFactory implements ITemplateFactory
public String getDescription()
{
- return "Generic Patterns";
+ return Templates_Basic_Messages.TXT_GENERIC_PATTERNS;
}
public String getId()
{
- return "Generic Patterns";
+ return "Generic Patterns"; //$NON-NLS-1$
}
public String getName()
{
- return "Generic Patterns";
+ return Templates_Basic_Messages.TXT_GENERIC_PATTERNS;
}
public ITemplateFactory getParentFactory()
diff --git a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/LoopTemplateAdapter.java b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/LoopTemplateAdapter.java
index c184e19..269fcaf 100644
--- a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/LoopTemplateAdapter.java
+++ b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/LoopTemplateAdapter.java
@@ -17,6 +17,7 @@ import org.eclipse.stardust.model.xpdl.carnot.DiagramType;
import org.eclipse.stardust.model.xpdl.carnot.ModelType;
import org.eclipse.stardust.modeling.core.editors.WorkflowModelEditor;
import org.eclipse.stardust.modeling.repository.common.ImportCancelledException;
+import org.eclipse.stardust.modeling.templates.basic.Templates_Basic_Messages;
import org.eclipse.stardust.modeling.templates.basic.ui.LoopTemplateWizard;
import org.eclipse.stardust.modeling.templates.defaulttemplate.TemplateHelper;
import org.eclipse.stardust.modeling.templates.spi.ITemplate;
@@ -37,42 +38,20 @@ public class LoopTemplateAdapter implements ITemplate
public String getDescription()
{
- String description = null;
- try
- {
- description = TemplateHelper.readResourceToString("/html/loop.html", parentTemplateFactory);
- }
- catch (Throwable e)
- {
- description = null;
- }
- if (description != null) {
- return description;
- }
- return "<h1><b>Loop Pattern</b></h1>" +
- "<p><b>Description</b><p>" +
- "This pattern consists of a sequence of N activities and a loop transition back to the first." +
- "<p><b>Parameter</b></p>" +
- "<ul>" +
- " <li>Number of activities</li>" +
- " <li>Type of activity (Default: Application Activity)</li>" +
- " <li>Loop condition</li>" +
- " <li>Orientation (Default: Vertical)</li>" +
- "</ul>" +
- "<p><b>Example</b></p>" +
- "<img src=\"/images/loop.JPG\"\\>";
+ return TemplateHelper.readDescriptionFromBundle(
+ "com.infinity.bpm.modeling.templates.basic.nl", "loop.html", //$NON-NLS-1$ //$NON-NLS-2$
+ parentTemplateFactory);
+
}
-
-
public String getId()
{
- return "Loop";
+ return "Loop"; //$NON-NLS-1$
}
public String getName()
{
- return "Loop";
+ return Templates_Basic_Messages.TXT_LOOP;
}
public String getCategory()
@@ -117,6 +96,12 @@ public class LoopTemplateAdapter implements ITemplate
{
return parentTemplateFactory;
}
+
+ public void setName(String name)
+ {
+ // TODO Auto-generated method stub
+
+ }
diff --git a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/ParallelSplitAndSynchronizationTemplateAdapter.java b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/ParallelSplitAndSynchronizationTemplateAdapter.java
index 7557e39..952d2a9 100644
--- a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/ParallelSplitAndSynchronizationTemplateAdapter.java
+++ b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/ParallelSplitAndSynchronizationTemplateAdapter.java
@@ -17,6 +17,7 @@ import org.eclipse.stardust.model.xpdl.carnot.DiagramType;
import org.eclipse.stardust.model.xpdl.carnot.ModelType;
import org.eclipse.stardust.modeling.core.editors.WorkflowModelEditor;
import org.eclipse.stardust.modeling.repository.common.ImportCancelledException;
+import org.eclipse.stardust.modeling.templates.basic.Templates_Basic_Messages;
import org.eclipse.stardust.modeling.templates.basic.ui.ParallelSplitAndSynchronizationTemplateWizard;
import org.eclipse.stardust.modeling.templates.defaulttemplate.TemplateHelper;
import org.eclipse.stardust.modeling.templates.spi.ITemplate;
@@ -37,28 +38,10 @@ public class ParallelSplitAndSynchronizationTemplateAdapter implements ITemplate
public String getDescription()
{
- String description = null;
- try
- {
- description = TemplateHelper.readResourceToString("/html/parallelandsplitwithjoin.html", parentTemplateFactory);
- }
- catch (Throwable e)
- {
- description = null;
- }
- if (description != null) {
- return description;
- }
- return "<h1><b>Parallel Split and Synchronization Pattern</b></h1>" +
- "<p><b>Description</b><p>" +
- "This pattern consists of a start activity which spawns via <i>AND</i> to N threads with one activity each and joins via <i>AND</i> to one end activity."+
- "<p><b>Parameter</b></p>" +
- "<ul>" +
- " <li>Number of activities</li>" +
- " <li>Type of activity (Default: Application Activity)</li>" +
- "</ul>" +
- "<p><b>Example</b></p>" +
- "<img src=\"/images/parallelandsplitwithjoin.JPG\"\\>";
+ return TemplateHelper.readDescriptionFromBundle(
+ "com.infinity.bpm.modeling.templates.basic.nl", //$NON-NLS-1$
+ "parallelandsplitwithjoin.html", parentTemplateFactory); //$NON-NLS-1$
+
}
@@ -66,12 +49,12 @@ public class ParallelSplitAndSynchronizationTemplateAdapter implements ITemplate
public String getId()
{
- return "Parallel Split and Synchronization";
+ return "Parallel Split and Synchronization"; //$NON-NLS-1$
}
public String getName()
{
- return "Parallel Split and Synchronization";
+ return Templates_Basic_Messages.TXT_PARALLEL_SPLIT_AND_SYNC;
}
public String getCategory()
@@ -116,6 +99,12 @@ public class ParallelSplitAndSynchronizationTemplateAdapter implements ITemplate
{
return parentTemplateFactory;
}
+
+ public void setName(String name)
+ {
+ // TODO Auto-generated method stub
+
+ }
diff --git a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/ParallelSplitTemplateAdapter.java b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/ParallelSplitTemplateAdapter.java
index 0aa14a0..c318404 100644
--- a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/ParallelSplitTemplateAdapter.java
+++ b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/ParallelSplitTemplateAdapter.java
@@ -17,6 +17,7 @@ import org.eclipse.stardust.model.xpdl.carnot.DiagramType;
import org.eclipse.stardust.model.xpdl.carnot.ModelType;
import org.eclipse.stardust.modeling.core.editors.WorkflowModelEditor;
import org.eclipse.stardust.modeling.repository.common.ImportCancelledException;
+import org.eclipse.stardust.modeling.templates.basic.Templates_Basic_Messages;
import org.eclipse.stardust.modeling.templates.basic.ui.ParallelSplitTemplateWizard;
import org.eclipse.stardust.modeling.templates.defaulttemplate.TemplateHelper;
import org.eclipse.stardust.modeling.templates.spi.ITemplate;
@@ -37,38 +38,19 @@ public class ParallelSplitTemplateAdapter implements ITemplate
public String getDescription()
{
- String description = null;
- try
- {
- description = TemplateHelper.readResourceToString("/html/parallelsplit.html", parentTemplateFactory);
- }
- catch (Throwable e)
- {
- description = null;
- }
- if (description != null) {
- return description;
- }
- return "<h1><b>Parallel Split with N-Threads</b></h1>" +
- "<p><b>Description</b><p>" +
- "This pattern consists of a start activity which spawns via <i>AND</i> to N threads." +
- "<p><b>Parameter</b></p>" +
- "<ul>" +
- " <li>Number of activities</li>" +
- " <li>Type of activity (Default: Application Activity)</li>" +
- "</ul>" +
- "<p><b>Example</b></p>" +
- "<img src=\"/images/parallelsplit.JPG\"\\>";
- }
+ return TemplateHelper.readDescriptionFromBundle(
+ "com.infinity.bpm.modeling.templates.basic.nl", "parallelsplit.html", //$NON-NLS-1$ //$NON-NLS-2$
+ parentTemplateFactory);
+ }
public String getId()
{
- return "Parallel Split";
+ return "Parallel Split"; //$NON-NLS-1$
}
public String getName()
{
- return "Parallel Split";
+ return Templates_Basic_Messages.TXT_PARALLEL_SPLIT;
}
public String getCategory()
@@ -113,6 +95,12 @@ public class ParallelSplitTemplateAdapter implements ITemplate
{
return parentTemplateFactory;
}
+
+ public void setName(String name)
+ {
+ // TODO Auto-generated method stub
+
+ }
diff --git a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/SequenceTemplateAdapter.java b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/SequenceTemplateAdapter.java
index 5a6dd06..42bd401 100644
--- a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/SequenceTemplateAdapter.java
+++ b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/factories/SequenceTemplateAdapter.java
@@ -17,6 +17,7 @@ import org.eclipse.stardust.model.xpdl.carnot.DiagramType;
import org.eclipse.stardust.model.xpdl.carnot.ModelType;
import org.eclipse.stardust.modeling.core.editors.WorkflowModelEditor;
import org.eclipse.stardust.modeling.repository.common.ImportCancelledException;
+import org.eclipse.stardust.modeling.templates.basic.Templates_Basic_Messages;
import org.eclipse.stardust.modeling.templates.basic.ui.SequenceTemplateWizard;
import org.eclipse.stardust.modeling.templates.defaulttemplate.TemplateHelper;
import org.eclipse.stardust.modeling.templates.spi.ITemplate;
@@ -37,39 +38,19 @@ public class SequenceTemplateAdapter implements ITemplate
public String getDescription()
{
- String description = null;
- try
- {
- description = TemplateHelper.readResourceToString("/html/sequence.html", parentTemplateFactory);
- }
- catch (Throwable e)
- {
- description = null;
- }
- if (description != null) {
- return description;
- }
- return "<h1><b>Activity Sequence</b></h1>" +
- "<p><b>Description</b><p>" +
- "This pattern consists of a sequence of activities." +
- "<p><b>Parameter</b></p>" +
- "<ul>" +
- " <li>Number of activities</li>" +
- " <li>Type of activity (Default: Application Activity)</li>" +
- " <li>Orientation (Default: Vertical)</li>" +
- "</ul>" +
- "<p><b>Example</b></p>" +
- "<img src=\"/images/sequence.JPG\"\\>";
+ return TemplateHelper.readDescriptionFromBundle(
+ "com.infinity.bpm.modeling.templates.basic.nl", "sequence.html", //$NON-NLS-1$ //$NON-NLS-2$
+ parentTemplateFactory);
}
public String getId()
{
- return "Sequence";
+ return "Sequence"; //$NON-NLS-1$
}
public String getName()
{
- return "Sequence";
+ return Templates_Basic_Messages.TXT_SEQUENCE;
}
public String getCategory()
@@ -114,6 +95,12 @@ public class SequenceTemplateAdapter implements ITemplate
{
return parentTemplateFactory;
}
+
+ public void setName(String name)
+ {
+ // TODO Auto-generated method stub
+
+ }
diff --git a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/templates-basic-messages.properties b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/templates-basic-messages.properties
new file mode 100644
index 0000000..2ca968a
--- /dev/null
+++ b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/templates-basic-messages.properties
@@ -0,0 +1,46 @@
+###############################################################################
+# Copyright (c) 2011 SunGard CSA LLC and others.
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Eclipse Public License v1.0
+# which accompanies this distribution, and is available at
+# http://www.eclipse.org/legal/epl-v10.html
+#
+# Contributors:
+# SunGard CSA LLC - initial API and implementation and/or initial documentation
+###############################################################################
+COMBO_BOX_HORIZONTAL=Horizontal
+COMBO_BOX_VERTICAL=Vertical
+ERR_MSG_PLEASE_PROVIDE_A_LOOP_CONDITION=Please provide a loop condition.
+ERR_MSG_PLEASE_PROVIDE_A_VALID_NUMBER_OF_ACTIVITIES=Please provide a valid number of activities (>=2 and <=99)
+LBL_TXT_ACTIVITY_KIND=Activity Kind:
+LBL_TXT_LOOP_CONDITIONS=Loop Condition:
+LBL_TXT_NUMBER_OF_ACTIVITIES=Number of Activities:
+LBL_TXT_ORIENTATION=Orientation:
+TXT_APPLY_PARALLEL_SPLIT_TEMPLATE=Apply "Parallel Split Template"
+TXT_AND_SPLIT_TEMPLATE=AND Split Template
+TXT_APPLICATION_ACTIVITY=Application Activity
+TXT_APPLY_EXCLUSIVE_CHOICE_AND_MERGE_TEMPLATE=Apply "Exclusive Choice And Merge Template"
+TXT_APPLY_EXCLUSIVE_CHOICE_TEMPLATE=Apply "Exclusive Choice Template"
+TXT_APPLY_LOOP_TEMPLATE=Apply "Loop Template"
+TXT_APPLY_SEQUENCE_TEMPLATE=Apply "Sequence Template"
+TXT_APPLY_SPLIT_AND_SYNCHRONIZATION_TEMPLATE=Apply "Parallel Split And Synchronization Template"
+TXT_BASIC_CONTROL_FLOW_PATTERN=Basic Control Flow Patterns
+TXT_ADVANCED_BRANCHING_AND_SYNCHRONIZATION_PATTERNS=Advanced Branching and Synchronization Patterns
+TXT_ECLUSIVE_CHOICE_AND_MERGE=Exclusive Choice and Merge
+TXT_EXCLUSIVE_CHOICE=Exclusive Choice
+TXT_EXCLUSIVE_CHOICE_AND_MERGE_PATTERN=Exclusive Choice and Merge Pattern
+TXT_EXCLUSIVE_CHOICE_AND_MERGE_TEMPLATE=Exclusive Choice and Merge Template
+TXT_EXCLUSIVE_CHOICE_PATTERN=Exclusive Choice Pattern
+TXT_EXCLUSIVE_CHOICE_TEMPLATE=Exclusive Choice Template
+TXT_GENERIC_PATTERNS=Generic Patterns
+TXT_LOOP=Loop
+TXT_LOOP_PATTERN=Loop Pattern
+TXT_LOOP_TEMPLATE=Loop Template
+TXT_PARALLEL_SPLIT=Parallel Split
+TXT_PARALLEL_SPLIT_AND_SYNC=Parallel Split and Synchronization
+TXT_PARALLEL_SPLIT_PATTERN=Parallel Split Pattern
+TXT_SEQUENCE=Sequence
+TXT_SEQUENCE_PATTERN=Sequence Pattern
+TXT_SEQUENCE_TEMPLATE=Sequence Template
+TXT_VERTICAL=Vertical
+TXT_DYNAMIC_SPAWN=Dynamic Spawn
diff --git a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ExclusiveChoiceAndMergeTemplatePage.java b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ExclusiveChoiceAndMergeTemplatePage.java
index 494bd87..4f73b11 100644
--- a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ExclusiveChoiceAndMergeTemplatePage.java
+++ b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ExclusiveChoiceAndMergeTemplatePage.java
@@ -17,6 +17,8 @@ import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.jface.dialogs.IDialogConstants;
import org.eclipse.jface.resource.ImageDescriptor;
import org.eclipse.jface.wizard.WizardPage;
+import org.eclipse.stardust.modeling.templates.Templates_Messages;
+import org.eclipse.stardust.modeling.templates.basic.Templates_Basic_Messages;
import org.eclipse.swt.SWT;
import org.eclipse.swt.events.SelectionEvent;
import org.eclipse.swt.events.SelectionListener;
@@ -55,9 +57,9 @@ public class ExclusiveChoiceAndMergeTemplatePage extends WizardPage {
gd.horizontalAlignment = SWT.FILL;
gd.verticalAlignment = SWT.FILL;
composite.setLayoutData(gd);
- Group group = createGroup(composite, "Exclusive Choice and Merge Pattern");
+ Group group = createGroup(composite, Templates_Basic_Messages.TXT_EXCLUSIVE_CHOICE_AND_MERGE_PATTERN);
Label nameLabel = new Label(group, SWT.NONE);
- nameLabel.setText("Number of Activities:");
+ nameLabel.setText(Templates_Basic_Messages.LBL_TXT_NUMBER_OF_ACTIVITIES);
numberText = new Text(group, SWT.BORDER);
GridData data = new GridData(GridData.FILL_HORIZONTAL);
data.widthHint = IDialogConstants.ENTRY_FIELD_WIDTH;
@@ -65,12 +67,12 @@ public class ExclusiveChoiceAndMergeTemplatePage extends WizardPage {
Label kind = new Label(group, SWT.NONE);
- kind.setText("Activity Kind:");
+ kind.setText(Templates_Basic_Messages.LBL_TXT_ACTIVITY_KIND);
combo = new Combo(group, SWT.READ_ONLY);
data = new GridData(GridData.FILL_HORIZONTAL);
data.widthHint = IDialogConstants.ENTRY_FIELD_WIDTH;
combo.setLayoutData(data);
- combo.setItems(new String[]{"Manual Activity", "Application Activity", "Route Activity"});
+ combo.setItems(new String[]{Templates_Messages.MANUAL_ACTIVITY, Templates_Messages.APPLICATION_ACTIVITY, Templates_Messages.ROUTE_ACTIVITY});
combo.select(1);
kindText = combo.getText();
@@ -106,19 +108,19 @@ public class ExclusiveChoiceAndMergeTemplatePage extends WizardPage {
number = numberText.getText();
kindText = combo.getText();
if (number.length() == 0) {
- setErrorMessage("Please provide a valid number of activities (>=2 and <=99)");
+ setErrorMessage(Templates_Basic_Messages.ERR_MSG_PLEASE_PROVIDE_A_VALID_NUMBER_OF_ACTIVITIES);
setPageComplete(false);
return;
}
try {
int i = Integer.parseInt(number);
if (i < 2 || i >99) {
- setErrorMessage("Please provide a valid number of activities (>=2 and <=99)");
+ setErrorMessage(Templates_Basic_Messages.ERR_MSG_PLEASE_PROVIDE_A_VALID_NUMBER_OF_ACTIVITIES);
setPageComplete(false);
return;
}
} catch (Throwable t) {
- setErrorMessage("Please provide a valid number of activities (>=2 and <=99)");
+ setErrorMessage(Templates_Basic_Messages.ERR_MSG_PLEASE_PROVIDE_A_VALID_NUMBER_OF_ACTIVITIES);
setPageComplete(false);
return;
}
diff --git a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ExclusiveChoiceAndMergeTemplateWizard.java b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ExclusiveChoiceAndMergeTemplateWizard.java
index 218d192..9d42b62 100644
--- a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ExclusiveChoiceAndMergeTemplateWizard.java
+++ b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ExclusiveChoiceAndMergeTemplateWizard.java
@@ -29,6 +29,7 @@ import org.eclipse.stardust.model.xpdl.carnot.XmlTextNode;
import org.eclipse.stardust.model.xpdl.carnot.util.ModelUtils;
import org.eclipse.stardust.modeling.core.editors.WorkflowModelEditor;
import org.eclipse.stardust.modeling.core.editors.figures.anchors.TransitionConnectionAnchor;
+import org.eclipse.stardust.modeling.templates.basic.Templates_Basic_Messages;
import org.eclipse.stardust.modeling.templates.defaulttemplate.TemplateHelper;
@@ -59,7 +60,7 @@ public class ExclusiveChoiceAndMergeTemplateWizard extends Wizard {
DiagramType targetDiagram, EditPart editPart, int xHint, int yHint)
{
super();
- this.setWindowTitle("Apply \"Exclusive Choice And Merge Template\"");
+ this.setWindowTitle(Templates_Basic_Messages.TXT_APPLY_EXCLUSIVE_CHOICE_AND_MERGE_TEMPLATE);
this.editPart = editPart;
model = targetModel;
editor = targetEditor;
@@ -77,7 +78,7 @@ public class ExclusiveChoiceAndMergeTemplateWizard extends Wizard {
public void addPages() {
super.addPages();
- newTemplatePage = new ExclusiveChoiceAndMergeTemplatePage("Exclusive Choice and Merge Template", "Exclusive Choice and Merge Template", null);
+ newTemplatePage = new ExclusiveChoiceAndMergeTemplatePage(Templates_Basic_Messages.TXT_EXCLUSIVE_CHOICE_AND_MERGE_TEMPLATE, Templates_Basic_Messages.TXT_EXCLUSIVE_CHOICE_AND_MERGE_TEMPLATE, null);
this.addPage(newTemplatePage);
}
@@ -87,7 +88,7 @@ public class ExclusiveChoiceAndMergeTemplateWizard extends Wizard {
int x = xHint;
int y = yHint;
//Create activity which contains the AND Split
- ActivityType rootActivity = templateHelper.createActivity(kind + " 0", kind);
+ ActivityType rootActivity = templateHelper.createActivity(kind + " 0", kind); //$NON-NLS-1$
rootActivity.setSplit(JoinSplitType.XOR_LITERAL);
ActivitySymbolType rootActivitySymbol = templateHelper.createActivitySymbol(rootActivity, x, y);
GatewaySymbol gatewaySymbol = templateHelper.createGatewaySymbol(rootActivitySymbol, FlowControlType.SPLIT_LITERAL);
@@ -98,7 +99,7 @@ public class ExclusiveChoiceAndMergeTemplateWizard extends Wizard {
rootTransitionSymbol.setSourceActivitySymbol(rootActivitySymbol);
rootTransitionSymbol.setTargetActivitySymbol(gatewaySymbol);
//Create activity which contains the XOR Join
- ActivityType joinActivity = templateHelper.createActivity(kind + " 99", kind);
+ ActivityType joinActivity = templateHelper.createActivity(kind + " 99", kind); //$NON-NLS-1$
joinActivity.setJoin(JoinSplitType.XOR_LITERAL);
ActivitySymbolType joinActivitySymbol = templateHelper.createActivitySymbol(joinActivity, xHint, y + 300);
GatewaySymbol joinGatewaySymbol = templateHelper.createGatewaySymbol(joinActivitySymbol, FlowControlType.JOIN_LITERAL);
@@ -107,13 +108,13 @@ public class ExclusiveChoiceAndMergeTemplateWizard extends Wizard {
//Create the split activities for the split
y = y + 100;
for (int i = 0; i < number; i++) {
- ActivityType splitActivity = templateHelper.createActivity(kind + " " + (i + 1), kind);
+ ActivityType splitActivity = templateHelper.createActivity(kind + " " + (i + 1), kind); //$NON-NLS-1$
ActivitySymbolType splitActivitySymbol = templateHelper.createActivitySymbol(splitActivity, x, y);
- TransitionType splitTransition = templateHelper.createTransition("Transition " + i);
- splitTransition.setCondition("CONDITION");
+ TransitionType splitTransition = templateHelper.createTransition("Transition " + i); //$NON-NLS-1$
+ splitTransition.setCondition("CONDITION"); //$NON-NLS-1$
expression = CarnotWorkflowModelFactory.eINSTANCE.createXmlTextNode();
splitTransition.setExpression(expression);
- ModelUtils.setCDataString(expression.getMixed(), "true", true);
+ ModelUtils.setCDataString(expression.getMixed(), "true", true); //$NON-NLS-1$
TransitionConnectionType splitTransitionSymbol = templateHelper.createTransitionSymbol(splitTransition);
splitTransition.setFrom(rootActivity);
splitTransition.setTo(splitActivity);
@@ -122,11 +123,11 @@ public class ExclusiveChoiceAndMergeTemplateWizard extends Wizard {
splitTransitionSymbol.setTargetAnchor(TransitionConnectionAnchor.TOP);
x = x + 200;
//Connect to join activity
- TransitionType joinTransition = templateHelper.createTransition("Transition " + i);
- joinTransition.setCondition("CONDITION");
+ TransitionType joinTransition = templateHelper.createTransition("Transition " + i); //$NON-NLS-1$
+ joinTransition.setCondition("CONDITION"); //$NON-NLS-1$
expression = CarnotWorkflowModelFactory.eINSTANCE.createXmlTextNode();
joinTransition.setExpression(expression);
- ModelUtils.setCDataString(expression.getMixed(), "true", true);
+ ModelUtils.setCDataString(expression.getMixed(), "true", true); //$NON-NLS-1$
TransitionConnectionType joinTransitionSymbol = templateHelper.createTransitionSymbol(joinTransition);
joinTransition.setFrom(splitActivity);
joinTransition.setTo(joinActivity);
diff --git a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ExclusiveChoiceTemplatePage.java b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ExclusiveChoiceTemplatePage.java
index 6e9dcfd..f6ef88a 100644
--- a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ExclusiveChoiceTemplatePage.java
+++ b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ExclusiveChoiceTemplatePage.java
@@ -17,6 +17,8 @@ import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.jface.dialogs.IDialogConstants;
import org.eclipse.jface.resource.ImageDescriptor;
import org.eclipse.jface.wizard.WizardPage;
+import org.eclipse.stardust.modeling.templates.Templates_Messages;
+import org.eclipse.stardust.modeling.templates.basic.Templates_Basic_Messages;
import org.eclipse.swt.SWT;
import org.eclipse.swt.events.SelectionEvent;
import org.eclipse.swt.events.SelectionListener;
@@ -55,9 +57,9 @@ public class ExclusiveChoiceTemplatePage extends WizardPage {
gd.horizontalAlignment = SWT.FILL;
gd.verticalAlignment = SWT.FILL;
composite.setLayoutData(gd);
- Group group = createGroup(composite, "Exclusive Choice Pattern");
+ Group group = createGroup(composite, Templates_Basic_Messages.TXT_EXCLUSIVE_CHOICE_PATTERN);
Label nameLabel = new Label(group, SWT.NONE);
- nameLabel.setText("Number of Activities:");
+ nameLabel.setText(Templates_Basic_Messages.LBL_TXT_NUMBER_OF_ACTIVITIES);
numberText = new Text(group, SWT.BORDER);
GridData data = new GridData(GridData.FILL_HORIZONTAL);
data.widthHint = IDialogConstants.ENTRY_FIELD_WIDTH;
@@ -65,12 +67,12 @@ public class ExclusiveChoiceTemplatePage extends WizardPage {
Label kind = new Label(group, SWT.NONE);
- kind.setText("Activity Kind:");
+ kind.setText(Templates_Basic_Messages.LBL_TXT_ACTIVITY_KIND);
combo = new Combo(group, SWT.READ_ONLY);
data = new GridData(GridData.FILL_HORIZONTAL);
data.widthHint = IDialogConstants.ENTRY_FIELD_WIDTH;
combo.setLayoutData(data);
- combo.setItems(new String[]{"Manual Activity", "Application Activity", "Route Activity"});
+ combo.setItems(new String[]{Templates_Messages.MANUAL_ACTIVITY, Templates_Messages.APPLICATION_ACTIVITY, Templates_Messages.ROUTE_ACTIVITY});
combo.select(1);
kindText = combo.getText();
@@ -106,19 +108,19 @@ public class ExclusiveChoiceTemplatePage extends WizardPage {
number = numberText.getText();
kindText = combo.getText();
if (number.length() == 0) {
- setErrorMessage("Please provide a valid number of activities (>=2 and <=99)");
+ setErrorMessage(Templates_Basic_Messages.ERR_MSG_PLEASE_PROVIDE_A_VALID_NUMBER_OF_ACTIVITIES);
setPageComplete(false);
return;
}
try {
int i = Integer.parseInt(number);
if (i < 2 || i >99) {
- setErrorMessage("Please provide a valid number of activities (>=2 and <=99)");
+ setErrorMessage(Templates_Basic_Messages.ERR_MSG_PLEASE_PROVIDE_A_VALID_NUMBER_OF_ACTIVITIES);
setPageComplete(false);
return;
}
} catch (Throwable t) {
- setErrorMessage("Please provide a valid number of activities (>=2 and <=99)");
+ setErrorMessage(Templates_Basic_Messages.ERR_MSG_PLEASE_PROVIDE_A_VALID_NUMBER_OF_ACTIVITIES);
setPageComplete(false);
return;
}
diff --git a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ExclusiveChoiceTemplateWizard.java b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ExclusiveChoiceTemplateWizard.java
index daf90fd..b34ed56 100644
--- a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ExclusiveChoiceTemplateWizard.java
+++ b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ExclusiveChoiceTemplateWizard.java
@@ -29,6 +29,7 @@ import org.eclipse.stardust.model.xpdl.carnot.XmlTextNode;
import org.eclipse.stardust.model.xpdl.carnot.util.ModelUtils;
import org.eclipse.stardust.modeling.core.editors.WorkflowModelEditor;
import org.eclipse.stardust.modeling.core.editors.figures.anchors.TransitionConnectionAnchor;
+import org.eclipse.stardust.modeling.templates.basic.Templates_Basic_Messages;
import org.eclipse.stardust.modeling.templates.defaulttemplate.TemplateHelper;
@@ -59,7 +60,7 @@ public class ExclusiveChoiceTemplateWizard extends Wizard {
DiagramType targetDiagram, EditPart editPart, int xHint, int yHint)
{
super();
- this.setWindowTitle("Apply \"Exclusive Choice Template\"");
+ this.setWindowTitle(Templates_Basic_Messages.TXT_APPLY_EXCLUSIVE_CHOICE_TEMPLATE);
this.editPart = editPart;
model = targetModel;
editor = targetEditor;
@@ -77,7 +78,7 @@ public class ExclusiveChoiceTemplateWizard extends Wizard {
public void addPages() {
super.addPages();
- newTemplatePage = new ExclusiveChoiceTemplatePage("Exclusive Choice Template", "Exclusive Choice Template", null);
+ newTemplatePage = new ExclusiveChoiceTemplatePage( Templates_Basic_Messages.TXT_EXCLUSIVE_CHOICE_TEMPLATE, Templates_Basic_Messages.TXT_EXCLUSIVE_CHOICE_TEMPLATE, null);
this.addPage(newTemplatePage);
}
@@ -89,7 +90,7 @@ public class ExclusiveChoiceTemplateWizard extends Wizard {
int y = yHint;
//Create activity which contains the Exclusive Choice
- ActivityType rootActivity = templateHelper.createActivity(kind + " 0", kind);
+ ActivityType rootActivity = templateHelper.createActivity(kind + " 0", kind); //$NON-NLS-1$
rootActivity.setSplit(JoinSplitType.XOR_LITERAL);
ActivitySymbolType rootActivitySymbol = templateHelper.createActivitySymbol(rootActivity, x, y);
GatewaySymbol gatewaySymbol = templateHelper.createGatewaySymbol(rootActivitySymbol, FlowControlType.SPLIT_LITERAL);
@@ -103,13 +104,13 @@ public class ExclusiveChoiceTemplateWizard extends Wizard {
//Create the split activities for the split
y = y + 100;
for (int i = 0; i < number; i++) {
- ActivityType splitActivity = templateHelper.createActivity(kind + " " + (i + 1), kind);
+ ActivityType splitActivity = templateHelper.createActivity(kind + " " + (i + 1), kind); //$NON-NLS-1$
ActivitySymbolType splitActivitySymbol = templateHelper.createActivitySymbol(splitActivity, x, y);
- TransitionType splitTransition = templateHelper.createTransition("Transition " + i);
- splitTransition.setCondition("CONDITION");
+ TransitionType splitTransition = templateHelper.createTransition("Transition " + i); //$NON-NLS-1$
+ splitTransition.setCondition("CONDITION"); //$NON-NLS-1$
expression = CarnotWorkflowModelFactory.eINSTANCE.createXmlTextNode();
splitTransition.setExpression(expression);
- ModelUtils.setCDataString(expression.getMixed(), "true", true);
+ ModelUtils.setCDataString(expression.getMixed(), "true", true); //$NON-NLS-1$
TransitionConnectionType splitTransitionSymbol = templateHelper.createTransitionSymbol(splitTransition);
splitTransition.setFrom(rootActivity);
splitTransition.setTo(splitActivity);
diff --git a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/LoopTemplatePage.java b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/LoopTemplatePage.java
index d095633..975c965 100644
--- a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/LoopTemplatePage.java
+++ b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/LoopTemplatePage.java
@@ -17,6 +17,8 @@ import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.jface.dialogs.IDialogConstants;
import org.eclipse.jface.resource.ImageDescriptor;
import org.eclipse.jface.wizard.WizardPage;
+import org.eclipse.stardust.modeling.templates.Templates_Messages;
+import org.eclipse.stardust.modeling.templates.basic.Templates_Basic_Messages;
import org.eclipse.swt.SWT;
import org.eclipse.swt.events.SelectionEvent;
import org.eclipse.swt.events.SelectionListener;
@@ -59,9 +61,9 @@ public class LoopTemplatePage extends WizardPage {
gd.horizontalAlignment = SWT.FILL;
gd.verticalAlignment = SWT.FILL;
composite.setLayoutData(gd);
- Group group = createGroup(composite, "Loop Pattern");
+ Group group = createGroup(composite, Templates_Basic_Messages.TXT_LOOP_PATTERN);
Label nameLabel = new Label(group, SWT.NONE);
- nameLabel.setText("Number of Activities:");
+ nameLabel.setText(Templates_Basic_Messages.LBL_TXT_NUMBER_OF_ACTIVITIES);
numberText = new Text(group, SWT.BORDER);
GridData data = new GridData(GridData.FILL_HORIZONTAL);
data.widthHint = IDialogConstants.ENTRY_FIELD_WIDTH;
@@ -69,17 +71,17 @@ public class LoopTemplatePage extends WizardPage {
Label kind = new Label(group, SWT.NONE);
- kind.setText("Activity Kind:");
+ kind.setText(Templates_Basic_Messages.LBL_TXT_ACTIVITY_KIND);
combo = new Combo(group, SWT.READ_ONLY);
data = new GridData(GridData.FILL_HORIZONTAL);
data.widthHint = IDialogConstants.ENTRY_FIELD_WIDTH;
combo.setLayoutData(data);
- combo.setItems(new String[]{"Manual Activity", "Application Activity", "Route Activity"});
+ combo.setItems(new String[]{Templates_Messages.MANUAL_ACTIVITY, Templates_Messages.APPLICATION_ACTIVITY, Templates_Messages.ROUTE_ACTIVITY});
combo.select(1);
- kindText = "Application Activity";
+ kindText = Templates_Basic_Messages.TXT_APPLICATION_ACTIVITY;
Label conditionLabel = new Label(group, SWT.NONE);
- conditionLabel.setText("Loop Condition:");
+ conditionLabel.setText(Templates_Basic_Messages.LBL_TXT_LOOP_CONDITIONS);
conditionText = new Text(group, SWT.BORDER);
data = new GridData(GridData.FILL_HORIZONTAL);
data.widthHint = IDialogConstants.ENTRY_FIELD_WIDTH;
@@ -102,14 +104,14 @@ public class LoopTemplatePage extends WizardPage {
});
Label orientation = new Label(group, SWT.NONE);
- orientation.setText("Orientation:");
+ orientation.setText(Templates_Basic_Messages.LBL_TXT_ORIENTATION);
orientationCombo = new Combo(group, SWT.READ_ONLY);
data = new GridData(GridData.FILL_HORIZONTAL);
data.widthHint = IDialogConstants.ENTRY_FIELD_WIDTH;
orientationCombo.setLayoutData(data);
- orientationCombo.setItems(new String[]{"Vertical", "Horizontal"});
+ orientationCombo.setItems(new String[]{Templates_Basic_Messages.COMBO_BOX_VERTICAL, Templates_Basic_Messages.COMBO_BOX_HORIZONTAL});
orientationCombo.select(0);
- orientationText = "Vertical";
+ orientationText = Templates_Basic_Messages.TXT_VERTICAL;
orientationCombo.addSelectionListener(new SelectionListener(){
@@ -143,24 +145,24 @@ public class LoopTemplatePage extends WizardPage {
kindText = combo.getText();
loopCondition = conditionText.getText();
if (number.length() == 0) {
- setErrorMessage("Please provide a valid number of activities (>=2 and <=99)");
+ setErrorMessage(Templates_Basic_Messages.ERR_MSG_PLEASE_PROVIDE_A_VALID_NUMBER_OF_ACTIVITIES);
setPageComplete(false);
return;
}
try {
int i = Integer.parseInt(number);
if (i < 2 || i >99) {
- setErrorMessage("Please provide a valid number of activities (>=2 and <=99)");
+ setErrorMessage(Templates_Basic_Messages.ERR_MSG_PLEASE_PROVIDE_A_VALID_NUMBER_OF_ACTIVITIES);
setPageComplete(false);
return;
}
} catch (Throwable t) {
- setErrorMessage("Please provide a valid number of activities (>=2 and <=99)");
+ setErrorMessage(Templates_Basic_Messages.ERR_MSG_PLEASE_PROVIDE_A_VALID_NUMBER_OF_ACTIVITIES);
setPageComplete(false);
return;
}
if (loopCondition.length() == 0) {
- setErrorMessage("Please provide a loop condition.");
+ setErrorMessage(Templates_Basic_Messages.ERR_MSG_PLEASE_PROVIDE_A_LOOP_CONDITION);
setPageComplete(false);
return;
}
diff --git a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/LoopTemplateWizard.java b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/LoopTemplateWizard.java
index f8ada60..9f074a4 100644
--- a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/LoopTemplateWizard.java
+++ b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/LoopTemplateWizard.java
@@ -26,6 +26,7 @@ import org.eclipse.stardust.model.xpdl.carnot.XmlTextNode;
import org.eclipse.stardust.model.xpdl.carnot.util.ModelUtils;
import org.eclipse.stardust.modeling.core.editors.WorkflowModelEditor;
import org.eclipse.stardust.modeling.core.editors.figures.anchors.TransitionConnectionAnchor;
+import org.eclipse.stardust.modeling.templates.basic.Templates_Basic_Messages;
import org.eclipse.stardust.modeling.templates.defaulttemplate.TemplateHelper;
@@ -56,7 +57,7 @@ public class LoopTemplateWizard extends Wizard {
DiagramType targetDiagram, EditPart editPart, int xHint, int yHint)
{
super();
- this.setWindowTitle("Apply \"Loop Template\"");
+ this.setWindowTitle(Templates_Basic_Messages.TXT_APPLY_LOOP_TEMPLATE);
this.editPart = editPart;
model = targetModel;
editor = targetEditor;
@@ -74,7 +75,7 @@ public class LoopTemplateWizard extends Wizard {
public void addPages() {
super.addPages();
- newTemplatePage = new LoopTemplatePage("Loop Template", "Loop Template", null);
+ newTemplatePage = new LoopTemplatePage(Templates_Basic_Messages.TXT_LOOP_TEMPLATE, Templates_Basic_Messages.TXT_LOOP_TEMPLATE, null);
this.addPage(newTemplatePage);
}
@@ -92,20 +93,20 @@ public class LoopTemplateWizard extends Wizard {
ActivitySymbolType firstActivitySymbol = null;
for (int i = 0; i < number; i++) {
- ActivityType sequenceActivity = templateHelper.createActivity(kind + " " + (i + 1), kind);
+ ActivityType sequenceActivity = templateHelper.createActivity(kind + " " + (i + 1), kind); //$NON-NLS-1$
ActivitySymbolType sequenceActivitySymbol = templateHelper.createActivitySymbol(sequenceActivity, x, y);
if (lastActivity != null) {
- TransitionType sequenceTransition = templateHelper.createTransition("Transition " + i);
- sequenceTransition.setCondition("CONDITION");
+ TransitionType sequenceTransition = templateHelper.createTransition("Transition " + i); //$NON-NLS-1$
+ sequenceTransition.setCondition("CONDITION"); //$NON-NLS-1$
expression = CarnotWorkflowModelFactory.eINSTANCE.createXmlTextNode();
sequenceTransition.setExpression(expression);
- ModelUtils.setCDataString(expression.getMixed(), "true", true);
+ ModelUtils.setCDataString(expression.getMixed(), "true", true); //$NON-NLS-1$
TransitionConnectionType sequenceTransitionSymbol = templateHelper.createTransitionSymbol(sequenceTransition);
sequenceTransition.setFrom(lastActivity);
sequenceTransition.setTo(sequenceActivity);
sequenceTransitionSymbol.setSourceActivitySymbol(lastActivitySymbol);
sequenceTransitionSymbol.setTargetActivitySymbol(sequenceActivitySymbol);
- if (orientation.equalsIgnoreCase("Vertical")) {
+ if (orientation.equalsIgnoreCase("Vertical")) { //$NON-NLS-1$
sequenceTransitionSymbol.setSourceAnchor(TransitionConnectionAnchor.BOTTOM);
sequenceTransitionSymbol.setTargetAnchor(TransitionConnectionAnchor.TOP);
} else {
@@ -113,7 +114,7 @@ public class LoopTemplateWizard extends Wizard {
sequenceTransitionSymbol.setTargetAnchor(TransitionConnectionAnchor.LEFT);
}
}
- if (orientation.equalsIgnoreCase("Vertical")) {
+ if (orientation.equalsIgnoreCase("Vertical")) { //$NON-NLS-1$
y = y + 100;
} else {
x = x + 250;
@@ -126,8 +127,8 @@ public class LoopTemplateWizard extends Wizard {
}
}
//Create Loop transition
- TransitionType loopTransition = templateHelper.createTransition("Transition");
- loopTransition.setCondition("CONDITION");
+ TransitionType loopTransition = templateHelper.createTransition("Transition"); //$NON-NLS-1$
+ loopTransition.setCondition("CONDITION"); //$NON-NLS-1$
expression = CarnotWorkflowModelFactory.eINSTANCE.createXmlTextNode();
loopTransition.setExpression(expression);
ModelUtils.setCDataString(expression.getMixed(), condition, true);
@@ -136,7 +137,7 @@ public class LoopTemplateWizard extends Wizard {
loopTransition.setTo(firstActivity);
loopTransitionSymbol.setSourceActivitySymbol(lastActivitySymbol);
loopTransitionSymbol.setTargetActivitySymbol(firstActivitySymbol);
- if (orientation.equalsIgnoreCase("Vertical")) {
+ if (orientation.equalsIgnoreCase("Vertical")) { //$NON-NLS-1$
loopTransitionSymbol.setSourceAnchor(TransitionConnectionAnchor.RIGHT);
loopTransitionSymbol.setTargetAnchor(TransitionConnectionAnchor.RIGHT);
} else {
diff --git a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ParallelSplitAndSynchronizationTemplatePage.java b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ParallelSplitAndSynchronizationTemplatePage.java
index c936edc..f7db571 100644
--- a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ParallelSplitAndSynchronizationTemplatePage.java
+++ b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ParallelSplitAndSynchronizationTemplatePage.java
@@ -17,6 +17,8 @@ import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.jface.dialogs.IDialogConstants;
import org.eclipse.jface.resource.ImageDescriptor;
import org.eclipse.jface.wizard.WizardPage;
+import org.eclipse.stardust.modeling.templates.Templates_Messages;
+import org.eclipse.stardust.modeling.templates.basic.Templates_Basic_Messages;
import org.eclipse.swt.SWT;
import org.eclipse.swt.events.SelectionEvent;
import org.eclipse.swt.events.SelectionListener;
@@ -55,9 +57,9 @@ public class ParallelSplitAndSynchronizationTemplatePage extends WizardPage {
gd.horizontalAlignment = SWT.FILL;
gd.verticalAlignment = SWT.FILL;
composite.setLayoutData(gd);
- Group group = createGroup(composite, "Parallel Split Pattern");
+ Group group = createGroup(composite, Templates_Basic_Messages.TXT_PARALLEL_SPLIT_PATTERN);
Label nameLabel = new Label(group, SWT.NONE);
- nameLabel.setText("Number of Activities:");
+ nameLabel.setText(Templates_Basic_Messages.LBL_TXT_NUMBER_OF_ACTIVITIES);
numberText = new Text(group, SWT.BORDER);
GridData data = new GridData(GridData.FILL_HORIZONTAL);
data.widthHint = IDialogConstants.ENTRY_FIELD_WIDTH;
@@ -65,14 +67,14 @@ public class ParallelSplitAndSynchronizationTemplatePage extends WizardPage {
Label kind = new Label(group, SWT.NONE);
- kind.setText("Activity Kind:");
+ kind.setText(Templates_Basic_Messages.LBL_TXT_ACTIVITY_KIND);
combo = new Combo(group, SWT.READ_ONLY);
data = new GridData(GridData.FILL_HORIZONTAL);
data.widthHint = IDialogConstants.ENTRY_FIELD_WIDTH;
combo.setLayoutData(data);
- combo.setItems(new String[]{"Manual Activity", "Application Activity", "Route Activity"});
+ combo.setItems(new String[]{Templates_Messages.MANUAL_ACTIVITY, Templates_Messages.APPLICATION_ACTIVITY, Templates_Messages.ROUTE_ACTIVITY});
combo.select(1);
- kindText = "Application Activity";
+ kindText = Templates_Messages.APPLICATION_ACTIVITY;
@@ -106,19 +108,19 @@ public class ParallelSplitAndSynchronizationTemplatePage extends WizardPage {
number = numberText.getText();
kindText = combo.getText();
if (number.length() == 0) {
- setErrorMessage("Please provide a valid number of activities (>=2 and <=99)");
+ setErrorMessage(Templates_Basic_Messages.ERR_MSG_PLEASE_PROVIDE_A_VALID_NUMBER_OF_ACTIVITIES);
setPageComplete(false);
return;
}
try {
int i = Integer.parseInt(number);
if (i < 2 || i >99) {
- setErrorMessage("Please provide a valid number of activities (>=2 and <=99)");
+ setErrorMessage(Templates_Basic_Messages.ERR_MSG_PLEASE_PROVIDE_A_VALID_NUMBER_OF_ACTIVITIES);
setPageComplete(false);
return;
}
} catch (Throwable t) {
- setErrorMessage("Please provide a valid number of activities (>=2 and <=99)");
+ setErrorMessage(Templates_Basic_Messages.ERR_MSG_PLEASE_PROVIDE_A_VALID_NUMBER_OF_ACTIVITIES);
setPageComplete(false);
return;
}
diff --git a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ParallelSplitAndSynchronizationTemplateWizard.java b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ParallelSplitAndSynchronizationTemplateWizard.java
index 18d2abb..21ff895 100644
--- a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ParallelSplitAndSynchronizationTemplateWizard.java
+++ b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ParallelSplitAndSynchronizationTemplateWizard.java
@@ -29,6 +29,7 @@ import org.eclipse.stardust.model.xpdl.carnot.XmlTextNode;
import org.eclipse.stardust.model.xpdl.carnot.util.ModelUtils;
import org.eclipse.stardust.modeling.core.editors.WorkflowModelEditor;
import org.eclipse.stardust.modeling.core.editors.figures.anchors.TransitionConnectionAnchor;
+import org.eclipse.stardust.modeling.templates.basic.Templates_Basic_Messages;
import org.eclipse.stardust.modeling.templates.defaulttemplate.TemplateHelper;
@@ -59,7 +60,7 @@ public class ParallelSplitAndSynchronizationTemplateWizard extends Wizard {
DiagramType targetDiagram, EditPart editPart, int xHint, int yHint)
{
super();
- this.setWindowTitle("Apply \"Parallel Split And Synchronization Template\"");
+ this.setWindowTitle(Templates_Basic_Messages.TXT_APPLY_SPLIT_AND_SYNCHRONIZATION_TEMPLATE);
this.editPart = editPart;
model = targetModel;
editor = targetEditor;
@@ -77,7 +78,7 @@ public class ParallelSplitAndSynchronizationTemplateWizard extends Wizard {
public void addPages() {
super.addPages();
- newTemplatePage = new ParallelSplitTemplatePage("AND Split Template", "AND Split Template", null);
+ newTemplatePage = new ParallelSplitTemplatePage(Templates_Basic_Messages.TXT_AND_SPLIT_TEMPLATE, Templates_Basic_Messages.TXT_AND_SPLIT_TEMPLATE, null); //$NON-NLS-1$
this.addPage(newTemplatePage);
}
@@ -87,7 +88,7 @@ public class ParallelSplitAndSynchronizationTemplateWizard extends Wizard {
int x = xHint;
int y = yHint;
//Create activity which contains the AND Split
- ActivityType rootActivity = templateHelper.createActivity(kind + " 0", kind);
+ ActivityType rootActivity = templateHelper.createActivity(kind + " 0", kind); //$NON-NLS-1$
rootActivity.setSplit(JoinSplitType.AND_LITERAL);
ActivitySymbolType rootActivitySymbol = templateHelper.createActivitySymbol(rootActivity, x, y);
GatewaySymbol gatewaySymbol = templateHelper.createGatewaySymbol(rootActivitySymbol, FlowControlType.SPLIT_LITERAL);
@@ -98,7 +99,7 @@ public class ParallelSplitAndSynchronizationTemplateWizard extends Wizard {
rootTransitionSymbol.setSourceActivitySymbol(rootActivitySymbol);
rootTransitionSymbol.setTargetActivitySymbol(gatewaySymbol);
//Create activity which contains the AND Join
- ActivityType joinActivity = templateHelper.createActivity(kind + " 99", kind);
+ ActivityType joinActivity = templateHelper.createActivity(kind + " 99", kind); //$NON-NLS-1$
joinActivity.setJoin(JoinSplitType.AND_LITERAL);
ActivitySymbolType joinActivitySymbol = templateHelper.createActivitySymbol(joinActivity, xHint, y + 300);
GatewaySymbol joinGatewaySymbol = templateHelper.createGatewaySymbol(joinActivitySymbol, FlowControlType.JOIN_LITERAL);
@@ -107,13 +108,13 @@ public class ParallelSplitAndSynchronizationTemplateWizard extends Wizard {
//Create the split activities for the split
y = y + 100;
for (int i = 0; i < number; i++) {
- ActivityType splitActivity = templateHelper.createActivity(kind + " " + (i + 1), kind);
+ ActivityType splitActivity = templateHelper.createActivity(kind + " " + (i + 1), kind); //$NON-NLS-1$
ActivitySymbolType splitActivitySymbol = templateHelper.createActivitySymbol(splitActivity, x, y);
- TransitionType splitTransition = templateHelper.createTransition("Transition " + i);
- splitTransition.setCondition("CONDITION");
+ TransitionType splitTransition = templateHelper.createTransition("Transition " + i); //$NON-NLS-1$
+ splitTransition.setCondition("CONDITION"); //$NON-NLS-1$
expression = CarnotWorkflowModelFactory.eINSTANCE.createXmlTextNode();
splitTransition.setExpression(expression);
- ModelUtils.setCDataString(expression.getMixed(), "true", true);
+ ModelUtils.setCDataString(expression.getMixed(), "true", true); //$NON-NLS-1$
TransitionConnectionType splitTransitionSymbol = templateHelper.createTransitionSymbol(splitTransition);
splitTransition.setFrom(rootActivity);
splitTransition.setTo(splitActivity);
@@ -122,11 +123,11 @@ public class ParallelSplitAndSynchronizationTemplateWizard extends Wizard {
splitTransitionSymbol.setTargetAnchor(TransitionConnectionAnchor.TOP);
x = x + 200;
//Connect to join activity
- TransitionType joinTransition = templateHelper.createTransition("Transition " + i);
- joinTransition.setCondition("CONDITION");
+ TransitionType joinTransition = templateHelper.createTransition("Transition " + i); //$NON-NLS-1$
+ joinTransition.setCondition("CONDITION"); //$NON-NLS-1$
expression = CarnotWorkflowModelFactory.eINSTANCE.createXmlTextNode();
joinTransition.setExpression(expression);
- ModelUtils.setCDataString(expression.getMixed(), "true", true);
+ ModelUtils.setCDataString(expression.getMixed(), "true", true); //$NON-NLS-1$
TransitionConnectionType joinTransitionSymbol = templateHelper.createTransitionSymbol(joinTransition);
joinTransition.setFrom(splitActivity);
joinTransition.setTo(joinActivity);
diff --git a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ParallelSplitTemplatePage.java b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ParallelSplitTemplatePage.java
index f5fa6dc..987a09a 100644
--- a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ParallelSplitTemplatePage.java
+++ b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ParallelSplitTemplatePage.java
@@ -17,6 +17,8 @@ import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.jface.dialogs.IDialogConstants;
import org.eclipse.jface.resource.ImageDescriptor;
import org.eclipse.jface.wizard.WizardPage;
+import org.eclipse.stardust.modeling.templates.Templates_Messages;
+import org.eclipse.stardust.modeling.templates.basic.Templates_Basic_Messages;
import org.eclipse.swt.SWT;
import org.eclipse.swt.events.SelectionEvent;
import org.eclipse.swt.events.SelectionListener;
@@ -55,9 +57,9 @@ public class ParallelSplitTemplatePage extends WizardPage {
gd.horizontalAlignment = SWT.FILL;
gd.verticalAlignment = SWT.FILL;
composite.setLayoutData(gd);
- Group group = createGroup(composite, "Parallel Split Pattern");
+ Group group = createGroup(composite, Templates_Basic_Messages.TXT_PARALLEL_SPLIT_PATTERN);
Label nameLabel = new Label(group, SWT.NONE);
- nameLabel.setText("Number of Activities:");
+ nameLabel.setText(Templates_Basic_Messages.LBL_TXT_NUMBER_OF_ACTIVITIES);
numberText = new Text(group, SWT.BORDER);
GridData data = new GridData(GridData.FILL_HORIZONTAL);
data.widthHint = IDialogConstants.ENTRY_FIELD_WIDTH;
@@ -65,14 +67,14 @@ public class ParallelSplitTemplatePage extends WizardPage {
Label kind = new Label(group, SWT.NONE);
- kind.setText("Activity Kind:");
+ kind.setText(Templates_Basic_Messages.LBL_TXT_ACTIVITY_KIND);
combo = new Combo(group, SWT.READ_ONLY);
data = new GridData(GridData.FILL_HORIZONTAL);
data.widthHint = IDialogConstants.ENTRY_FIELD_WIDTH;
combo.setLayoutData(data);
- combo.setItems(new String[]{"Manual Activity", "Application Activity", "Route Activity"});
+ combo.setItems(new String[]{Templates_Messages.MANUAL_ACTIVITY, Templates_Messages.APPLICATION_ACTIVITY, Templates_Messages.ROUTE_ACTIVITY});
combo.select(1);
- kindText = "Application Activity";
+ kindText = Templates_Basic_Messages.TXT_APPLICATION_ACTIVITY;
@@ -106,19 +108,19 @@ public class ParallelSplitTemplatePage extends WizardPage {
number = numberText.getText();
kindText = combo.getText();
if (number.length() == 0) {
- setErrorMessage("Please provide a valid number of activities (>=2 and <=99)");
+ setErrorMessage(Templates_Basic_Messages.ERR_MSG_PLEASE_PROVIDE_A_VALID_NUMBER_OF_ACTIVITIES);
setPageComplete(false);
return;
}
try {
int i = Integer.parseInt(number);
if (i < 2 || i >99) {
- setErrorMessage("Please provide a valid number of activities (>=2 and <=99)");
+ setErrorMessage(Templates_Basic_Messages.ERR_MSG_PLEASE_PROVIDE_A_VALID_NUMBER_OF_ACTIVITIES);
setPageComplete(false);
return;
}
} catch (Throwable t) {
- setErrorMessage("Please provide a valid number of activities (>=2 and <=99)");
+ setErrorMessage(Templates_Basic_Messages.ERR_MSG_PLEASE_PROVIDE_A_VALID_NUMBER_OF_ACTIVITIES);
setPageComplete(false);
return;
}
diff --git a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ParallelSplitTemplateWizard.java b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ParallelSplitTemplateWizard.java
index 02933e0..89b7151 100644
--- a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ParallelSplitTemplateWizard.java
+++ b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/ParallelSplitTemplateWizard.java
@@ -29,6 +29,7 @@ import org.eclipse.stardust.model.xpdl.carnot.XmlTextNode;
import org.eclipse.stardust.model.xpdl.carnot.util.ModelUtils;
import org.eclipse.stardust.modeling.core.editors.WorkflowModelEditor;
import org.eclipse.stardust.modeling.core.editors.figures.anchors.TransitionConnectionAnchor;
+import org.eclipse.stardust.modeling.templates.basic.Templates_Basic_Messages;
import org.eclipse.stardust.modeling.templates.defaulttemplate.TemplateHelper;
@@ -59,7 +60,7 @@ public class ParallelSplitTemplateWizard extends Wizard {
DiagramType targetDiagram, EditPart editPart, int xHint, int yHint)
{
super();
- this.setWindowTitle("Apply \"Parallel Split Template\"");
+ this.setWindowTitle(Templates_Basic_Messages.TXT_APPLY_PARALLEL_SPLIT_TEMPLATE);
this.editPart = editPart;
model = targetModel;
editor = targetEditor;
@@ -77,7 +78,7 @@ public class ParallelSplitTemplateWizard extends Wizard {
public void addPages() {
super.addPages();
- newTemplatePage = new ParallelSplitTemplatePage("AND Split Template", "AND Split Template", null);
+ newTemplatePage = new ParallelSplitTemplatePage(Templates_Basic_Messages.TXT_AND_SPLIT_TEMPLATE, Templates_Basic_Messages.TXT_AND_SPLIT_TEMPLATE, null);
this.addPage(newTemplatePage);
}
@@ -89,7 +90,7 @@ public class ParallelSplitTemplateWizard extends Wizard {
int y = yHint;
//Create activity which contains the AND Split
- ActivityType rootActivity = templateHelper.createActivity(kind + " 0", kind);
+ ActivityType rootActivity = templateHelper.createActivity(kind + " 0", kind); //$NON-NLS-1$
rootActivity.setSplit(JoinSplitType.AND_LITERAL);
ActivitySymbolType rootActivitySymbol = templateHelper.createActivitySymbol(rootActivity, x, y);
GatewaySymbol gatewaySymbol = templateHelper.createGatewaySymbol(rootActivitySymbol, FlowControlType.SPLIT_LITERAL);
@@ -102,13 +103,13 @@ public class ParallelSplitTemplateWizard extends Wizard {
//Create the split activities for the split
y = y + 100;
for (int i = 0; i < number; i++) {
- ActivityType splitActivity = templateHelper.createActivity(kind + " " + (i + 1), kind);
+ ActivityType splitActivity = templateHelper.createActivity(kind + " " + (i + 1), kind); //$NON-NLS-1$
ActivitySymbolType splitActivitySymbol = templateHelper.createActivitySymbol(splitActivity, x, y);
- TransitionType splitTransition = templateHelper.createTransition("Transition " + i);
- splitTransition.setCondition("CONDITION");
+ TransitionType splitTransition = templateHelper.createTransition("Transition " + i); //$NON-NLS-1$
+ splitTransition.setCondition("CONDITION"); //$NON-NLS-1$
expression = CarnotWorkflowModelFactory.eINSTANCE.createXmlTextNode();
splitTransition.setExpression(expression);
- ModelUtils.setCDataString(expression.getMixed(), "true", true);
+ ModelUtils.setCDataString(expression.getMixed(), "true", true); //$NON-NLS-1$
TransitionConnectionType splitTransitionSymbol = templateHelper.createTransitionSymbol(splitTransition);
splitTransition.setFrom(rootActivity);
splitTransition.setTo(splitActivity);
diff --git a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/SequenceTemplatePage.java b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/SequenceTemplatePage.java
index d1ec143..68740fc 100644
--- a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/SequenceTemplatePage.java
+++ b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/SequenceTemplatePage.java
@@ -17,6 +17,8 @@ import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.jface.dialogs.IDialogConstants;
import org.eclipse.jface.resource.ImageDescriptor;
import org.eclipse.jface.wizard.WizardPage;
+import org.eclipse.stardust.modeling.templates.Templates_Messages;
+import org.eclipse.stardust.modeling.templates.basic.Templates_Basic_Messages;
import org.eclipse.swt.SWT;
import org.eclipse.swt.events.SelectionEvent;
import org.eclipse.swt.events.SelectionListener;
@@ -57,9 +59,9 @@ public class SequenceTemplatePage extends WizardPage {
gd.horizontalAlignment = SWT.FILL;
gd.verticalAlignment = SWT.FILL;
composite.setLayoutData(gd);
- Group group = createGroup(composite, "Sequence Pattern");
+ Group group = createGroup(composite, Templates_Basic_Messages.TXT_SEQUENCE_PATTERN);
Label nameLabel = new Label(group, SWT.NONE);
- nameLabel.setText("Number of Activities:");
+ nameLabel.setText(Templates_Basic_Messages.LBL_TXT_NUMBER_OF_ACTIVITIES);
numberText = new Text(group, SWT.BORDER);
GridData data = new GridData(GridData.FILL_HORIZONTAL);
data.widthHint = IDialogConstants.ENTRY_FIELD_WIDTH;
@@ -67,14 +69,16 @@ public class SequenceTemplatePage extends WizardPage {
Label kind = new Label(group, SWT.NONE);
- kind.setText("Activity Kind:");
+ kind.setText(Templates_Basic_Messages.LBL_TXT_ACTIVITY_KIND);
combo = new Combo(group, SWT.READ_ONLY);
data = new GridData(GridData.FILL_HORIZONTAL);
data.widthHint = IDialogConstants.ENTRY_FIELD_WIDTH;
combo.setLayoutData(data);
- combo.setItems(new String[]{"Manual Activity", "Application Activity", "Route Activity"});
+ combo.setItems(new String[] {
+ Templates_Messages.MANUAL_ACTIVITY, Templates_Messages.APPLICATION_ACTIVITY,
+ Templates_Messages.ROUTE_ACTIVITY});
combo.select(1);
- kindText = "Application Activity";
+ kindText = Templates_Basic_Messages.TXT_APPLICATION_ACTIVITY;
combo.addSelectionListener(new SelectionListener(){
@@ -93,14 +97,14 @@ public class SequenceTemplatePage extends WizardPage {
});
Label orientation = new Label(group, SWT.NONE);
- orientation.setText("Orientation:");
+ orientation.setText(Templates_Basic_Messages.LBL_TXT_ORIENTATION);
orientationCombo = new Combo(group, SWT.READ_ONLY);
data = new GridData(GridData.FILL_HORIZONTAL);
data.widthHint = IDialogConstants.ENTRY_FIELD_WIDTH;
orientationCombo.setLayoutData(data);
- orientationCombo.setItems(new String[]{"Vertical", "Horizontal"});
+ orientationCombo.setItems(new String[]{Templates_Basic_Messages.COMBO_BOX_VERTICAL, Templates_Basic_Messages.COMBO_BOX_HORIZONTAL});
orientationCombo.select(0);
- orientationText = "Vertical";
+ orientationText = Templates_Basic_Messages.TXT_VERTICAL;
orientationCombo.addSelectionListener(new SelectionListener(){
@@ -132,19 +136,19 @@ public class SequenceTemplatePage extends WizardPage {
number = numberText.getText();
kindText = combo.getText();
if (number.length() == 0) {
- setErrorMessage("Please provide a valid number of activities (>=2 and <=99)");
+ setErrorMessage(Templates_Basic_Messages.ERR_MSG_PLEASE_PROVIDE_A_VALID_NUMBER_OF_ACTIVITIES);
setPageComplete(false);
return;
}
try {
int i = Integer.parseInt(number);
if (i < 2 || i >99) {
- setErrorMessage("Please provide a valid number of activities (>=2 and <=99)");
+ setErrorMessage(Templates_Basic_Messages.ERR_MSG_PLEASE_PROVIDE_A_VALID_NUMBER_OF_ACTIVITIES);
setPageComplete(false);
return;
}
} catch (Throwable t) {
- setErrorMessage("Please provide a valid number of activities (>=2 and <=99)");
+ setErrorMessage(Templates_Basic_Messages.ERR_MSG_PLEASE_PROVIDE_A_VALID_NUMBER_OF_ACTIVITIES);
setPageComplete(false);
return;
}
diff --git a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/SequenceTemplateWizard.java b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/SequenceTemplateWizard.java
index 6953113..fc01f8c 100644
--- a/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/SequenceTemplateWizard.java
+++ b/modeling/org.eclipse.stardust.modeling.templates.basic/src/org/eclipse/stardust/modeling/templates/basic/ui/SequenceTemplateWizard.java
@@ -26,6 +26,7 @@ import org.eclipse.stardust.model.xpdl.carnot.XmlTextNode;
import org.eclipse.stardust.model.xpdl.carnot.util.ModelUtils;
import org.eclipse.stardust.modeling.core.editors.WorkflowModelEditor;
import org.eclipse.stardust.modeling.core.editors.figures.anchors.TransitionConnectionAnchor;
+import org.eclipse.stardust.modeling.templates.basic.Templates_Basic_Messages;
import org.eclipse.stardust.modeling.templates.defaulttemplate.TemplateHelper;
@@ -56,7 +57,7 @@ public class SequenceTemplateWizard extends Wizard {
DiagramType targetDiagram, EditPart editPart, int xHint, int yHint)
{
super();
- this.setWindowTitle("Apply \"Sequence Template\"");
+ this.setWindowTitle(Templates_Basic_Messages.TXT_APPLY_SEQUENCE_TEMPLATE);
this.editPart = editPart;
model = targetModel;
editor = targetEditor;
@@ -74,7 +75,7 @@ public class SequenceTemplateWizard extends Wizard {
public void addPages() {
super.addPages();
- newTemplatePage = new SequenceTemplatePage("Sequence Template", "Sequence Template", null);
+ newTemplatePage = new SequenceTemplatePage(Templates_Basic_Messages.TXT_SEQUENCE_TEMPLATE, Templates_Basic_Messages.TXT_SEQUENCE_TEMPLATE, null);
this.addPage(newTemplatePage);
}
@@ -88,21 +89,21 @@ public class SequenceTemplateWizard extends Wizard {
ActivityType lastActivity = null;
ActivitySymbolType lastActivitySymbol = null;
- for (int i = 0; i < number; i++) {
- ActivityType sequenceActivity = templateHelper.createActivity(kind + " " + (i + 1), kind);
+ for (int i = 0; i < number; i++) {
+ ActivityType sequenceActivity = templateHelper.createActivity(kind + " " + (i + 1), kind); //$NON-NLS-1$
ActivitySymbolType sequenceActivitySymbol = templateHelper.createActivitySymbol(sequenceActivity, x, y);
if (lastActivity != null) {
- TransitionType sequenceTransition = templateHelper.createTransition("Transition " + i);
- sequenceTransition.setCondition("CONDITION");
+ TransitionType sequenceTransition = templateHelper.createTransition("Transition " + i); //$NON-NLS-1$
+ sequenceTransition.setCondition("CONDITION"); //$NON-NLS-1$
expression = CarnotWorkflowModelFactory.eINSTANCE.createXmlTextNode();
sequenceTransition.setExpression(expression);
- ModelUtils.setCDataString(expression.getMixed(), "true", true);
+ ModelUtils.setCDataString(expression.getMixed(), "true", true); //$NON-NLS-1$
TransitionConnectionType sequenceTransitionSymbol = templateHelper.createTransitionSymbol(sequenceTransition);
sequenceTransition.setFrom(lastActivity);
sequenceTransition.setTo(sequenceActivity);
sequenceTransitionSymbol.setSourceActivitySymbol(lastActivitySymbol);
sequenceTransitionSymbol.setTargetActivitySymbol(sequenceActivitySymbol);
- if (orientation.equalsIgnoreCase("Vertical")) {
+ if (orientation.equalsIgnoreCase(Templates_Basic_Messages.TXT_VERTICAL)) {
sequenceTransitionSymbol.setSourceAnchor(TransitionConnectionAnchor.BOTTOM);
sequenceTransitionSymbol.setTargetAnchor(TransitionConnectionAnchor.TOP);
} else {
@@ -110,7 +111,7 @@ public class SequenceTemplateWizard extends Wizard {
sequenceTransitionSymbol.setTargetAnchor(TransitionConnectionAnchor.LEFT);
}
}
- if (orientation.equalsIgnoreCase("Vertical")) {
+ if (orientation.equalsIgnoreCase(Templates_Basic_Messages.TXT_VERTICAL)) {
y = y + 100;
} else {
x = x + 250;