initial checkin
diff --git a/bundles/org.eclipse.wst.xsl.exslt.core/.classpath b/bundles/org.eclipse.wst.xsl.exslt.core/.classpath
new file mode 100644
index 0000000..64c5e31
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.exslt.core/.classpath
@@ -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/J2SE-1.5"/>
+	<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
+	<classpathentry kind="src" path="src"/>
+	<classpathentry kind="output" path="bin"/>
+</classpath>
diff --git a/bundles/org.eclipse.wst.xsl.exslt.core/.project b/bundles/org.eclipse.wst.xsl.exslt.core/.project
new file mode 100644
index 0000000..cc82e49
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.exslt.core/.project
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+	<name>org.eclipse.wst.xsl.exslt.core</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>
+		<buildCommand>
+			<name>org.eclipse.pde.api.tools.apiAnalysisBuilder</name>
+			<arguments>
+			</arguments>
+		</buildCommand>
+	</buildSpec>
+	<natures>
+		<nature>org.eclipse.pde.PluginNature</nature>
+		<nature>org.eclipse.jdt.core.javanature</nature>
+		<nature>org.eclipse.pde.api.tools.apiAnalysisNature</nature>
+	</natures>
+</projectDescription>
diff --git a/bundles/org.eclipse.wst.xsl.exslt.core/.settings/org.eclipse.jdt.core.prefs b/bundles/org.eclipse.wst.xsl.exslt.core/.settings/org.eclipse.jdt.core.prefs
new file mode 100644
index 0000000..bd0b325
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.exslt.core/.settings/org.eclipse.jdt.core.prefs
@@ -0,0 +1,8 @@
+#Fri Sep 18 21:17:47 GMT 2009
+eclipse.preferences.version=1
+org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5
+org.eclipse.jdt.core.compiler.compliance=1.5
+org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
+org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
+org.eclipse.jdt.core.compiler.source=1.5
diff --git a/bundles/org.eclipse.wst.xsl.exslt.core/META-INF/MANIFEST.MF b/bundles/org.eclipse.wst.xsl.exslt.core/META-INF/MANIFEST.MF
new file mode 100644
index 0000000..22d8ff7
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.exslt.core/META-INF/MANIFEST.MF
@@ -0,0 +1,14 @@
+Manifest-Version: 1.0
+Bundle-ManifestVersion: 2
+Bundle-Name: %pluginName
+Bundle-SymbolicName: org.eclipse.wst.xsl.exslt.core;singleton:=true
+Bundle-Version: 1.0.0.qualifier
+Bundle-Activator: org.eclipse.wst.xsl.exslt.core.internal.EXSLTCore
+Require-Bundle: org.eclipse.core.runtime,
+ org.eclipse.wst.common.uriresolver;bundle-version="[1.1.0,2.0.0)",
+ org.eclipse.core.resources;bundle-version="[3.4.0,4.0.0)"
+Bundle-ActivationPolicy: lazy
+Bundle-RequiredExecutionEnvironment: J2SE-1.5
+Export-Package: org.eclipse.wst.xsl.exslt.core.internal;x-internal:=true,
+ org.eclipse.wst.xsl.exslt.core.internal.resolver;x-internal:=true
+Bundle-Vendor: %providerName
diff --git a/bundles/org.eclipse.wst.xsl.exslt.core/about.html b/bundles/org.eclipse.wst.xsl.exslt.core/about.html
new file mode 100644
index 0000000..2199df3
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.exslt.core/about.html
@@ -0,0 +1,34 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
+<HTML>
+
+<head>
+<title>About</title>
+<meta http-equiv=Content-Type content="text/html; charset=ISO-8859-1">
+</head>
+
+<BODY lang="EN-US">
+
+<H3>About This Content</H3>
+
+<P>June, 2008</P>
+
+<H3>License</H3>
+
+<P>The Eclipse Foundation makes available all content in this plug-in 
+("Content"). Unless otherwise indicated below, the Content is provided to you 
+under the terms and conditions of the Eclipse Public License Version 1.0 
+("EPL"). A copy of the EPL is available at
+<A href="http://www.eclipse.org/org/documents/epl-v10.php">http://www.eclipse.org/org/documents/epl-v10.php</A>. 
+For purposes of the EPL, "Program" will mean the Content.</P>
+
+<P>If you did not receive this Content directly from the Eclipse Foundation, the 
+Content is being redistributed by another party ("Redistributor") and different 
+terms and conditions may apply to your use of any object code in the Content. 
+Check the Redistributor’s license that was provided with the Content. If no such 
+license exists, contact the Redistributor. Unless otherwise indicated below, the 
+terms and conditions of the EPL still apply to any source code in the Content 
+and such source code may be obtained at
+<A href="http://www.eclipse.org/">http://www.eclipse.org/</A>.</P>
+
+</BODY>
+</HTML>
diff --git a/bundles/org.eclipse.wst.xsl.exslt.core/build.properties b/bundles/org.eclipse.wst.xsl.exslt.core/build.properties
new file mode 100644
index 0000000..25879c8
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.exslt.core/build.properties
@@ -0,0 +1,7 @@
+source.. = src/
+output.. = bin/
+bin.includes = META-INF/,\
+               .,\
+               plugin.xml,\
+               schemas/,\
+               bin/
diff --git a/bundles/org.eclipse.wst.xsl.exslt.core/plugin.properties b/bundles/org.eclipse.wst.xsl.exslt.core/plugin.properties
new file mode 100644
index 0000000..dbe24d9
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.exslt.core/plugin.properties
@@ -0,0 +1,13 @@
+###############################################################################
+# Copyright (c) 2009 Standards for Technology in Automotive Retail 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:
+#     David Carver - Initial API and Implementation
+###############################################################################
+
+providerName=Eclipse Web Tools Platform
+pluginName=EXSLT UI Extensions
diff --git a/bundles/org.eclipse.wst.xsl.exslt.core/plugin.xml b/bundles/org.eclipse.wst.xsl.exslt.core/plugin.xml
new file mode 100644
index 0000000..ab73fbe
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.exslt.core/plugin.xml
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<?eclipse version="3.4"?>
+<plugin>
+   <extension
+         point="org.eclipse.wst.common.uriresolver.resolverExtensions">
+      <resolverExtension
+            class="org.eclipse.wst.xsl.exslt.core.internal.resolver.EXSLTResolverExtension"
+            stage="prenormalization">
+      </resolverExtension>
+   </extension>
+
+</plugin>
diff --git a/bundles/org.eclipse.wst.xsl.exslt.core/schemas/common.xsd b/bundles/org.eclipse.wst.xsl.exslt.core/schemas/common.xsd
new file mode 100644
index 0000000..a0b6ea8
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.exslt.core/schemas/common.xsd
@@ -0,0 +1,48 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" targetNamespace="http://exslt.org/common" xmlns="http://exslt.org/common" elementFormDefault="qualified">
+
+	<xsd:element name="document" type="DocumentType">
+		<xsd:annotation>
+			<xsd:documentation source="http://www.exslt.org/exsl/elements/document/exsl.document.html">
+			    The exsl:document element is used to create multiple result documents. As well as the main result document, there can be subsidiary result documents. Each subsidiary result document is created using an exsl:document element. The content of the exsl:document element is a template; this is instantiated to create a sequence of nodes; a root node is created with this sequence of nodes as its children; the tree with this root node represents the subsidiary result document. The href attribute specifies where the subsidiary document should be stored; it must be an absolute or relative URI; it must not have a fragment identifier.
+			</xsd:documentation>
+		</xsd:annotation>
+	</xsd:element>
+	
+	<xsd:complexType name="DocumentType">
+		<xsd:sequence>
+			<xsd:any namespace="##other"/>
+		</xsd:sequence>
+		<xsd:attribute name="href" use="required" type="xsd:anyURI">
+		    <xsd:annotation>
+		    	<xsd:documentation source="http://www.exslt.org/exsl/elements/document/exsl.document.html">
+		    	     The href attribute specifies where the subsidiary document should be stored; it must be an absolute or relative URI; it must not have a fragment identifier.
+		    	</xsd:documentation>
+		    </xsd:annotation>
+		</xsd:attribute>
+		<xsd:attribute name="method" use="optional" type="MethodEnumeratedType"/>
+		<xsd:attribute name="version" use="optional" type="xsd:NMTOKEN"/>
+		<xsd:attribute name="encoding" use="optional" type="xsd:string"/>
+		<xsd:attribute name="omit-xml-declaration" use="optional" type="YesNoEnumeratedType"/>
+		<xsd:attribute name="doctype-public" use="optional" type="xsd:string"/>
+		<xsd:attribute name="doctype-system" use="optional" type="xsd:string"/>
+		<xsd:attribute name="cdata-section-elements" use="optional" type="xsd:string"/>
+		<xsd:attribute name="indent" use="optional" type="YesNoEnumeratedType"/>
+		<xsd:attribute name="media-type" use="optional" type="xsd:string"/>
+	</xsd:complexType>
+	
+	<xsd:simpleType name="MethodEnumeratedType">
+		<xsd:restriction base="xsd:token">
+			<xsd:enumeration value="xml"/>
+			<xsd:enumeration value="html"/>
+			<xsd:enumeration value="text"/>
+		</xsd:restriction>
+	</xsd:simpleType>
+	
+	<xsd:simpleType name="YesNoEnumeratedType">
+		<xsd:restriction base="xsd:token">
+			<xsd:enumeration value="yes"/>
+			<xsd:enumeration value="no"/>
+		</xsd:restriction>
+	</xsd:simpleType>
+</xsd:schema>
\ No newline at end of file
diff --git a/bundles/org.eclipse.wst.xsl.exslt.core/src/org/eclipse/wst/xsl/exslt/core/internal/EXSLTCore.java b/bundles/org.eclipse.wst.xsl.exslt.core/src/org/eclipse/wst/xsl/exslt/core/internal/EXSLTCore.java
new file mode 100644
index 0000000..5eed4ce
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.exslt.core/src/org/eclipse/wst/xsl/exslt/core/internal/EXSLTCore.java
@@ -0,0 +1,72 @@
+/*******************************************************************************
+ * Copyright (c) 2009 Standards for Technology in Automotive Retail 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:
+ *     David Carver - initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.wst.xsl.exslt.core.internal;
+
+import org.eclipse.core.runtime.Plugin;
+import org.osgi.framework.BundleContext;
+
+/**
+ * The activator class controls the plug-in life cycle
+ */
+public class EXSLTCore extends Plugin {
+
+	// The plug-in ID
+	public static final String PLUGIN_ID = "org.eclipse.wst.xsl.exslt.core";
+	
+	public static final String EXSLT_MATH_NAMESPACE = "http://exslt.org/math";
+	public static final String EXSLT_FUNC_NAMESPACE = "http://exslt.org/functions";
+	public static final String EXSLT_COMMON_NAMESPACE = "http://exslt.org/common";
+	public static final String EXSLT_DYNAMIC_NAMESPACE = "http://exslt.org/dynamic";
+	public static final String EXSLT_DATE_NAMESPACE = "http://www.exslt.org/date/index.html";
+	public static final String EXSLT_RANDOM_NAMESPACE = "http://exslt.org/random";
+	public static final String EXSLT_REGEX_NAMESPACE = "http://exslt.org/regular-expressions";
+	public static final String EXSLT_SETS_NAMESPACE = "http://exslt.org/sets";
+	public static final String EXSLT_STRING_NAMESPACE = "http://exslt.org/strings";
+	
+
+	// The shared instance
+	private static EXSLTCore plugin;
+	
+	/**
+	 * The constructor
+	 */
+	public EXSLTCore() {
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.eclipse.core.runtime.Plugins#start(org.osgi.framework.BundleContext)
+	 */
+	public void start(BundleContext context) throws Exception {
+		super.start(context);
+		plugin = this;
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.eclipse.core.runtime.Plugin#stop(org.osgi.framework.BundleContext)
+	 */
+	public void stop(BundleContext context) throws Exception {
+		plugin = null;
+		super.stop(context);
+	}
+
+	/**
+	 * Returns the shared instance
+	 *
+	 * @return the shared instance
+	 */
+	public static EXSLTCore getDefault() {
+		return plugin;
+	}
+
+}
diff --git a/bundles/org.eclipse.wst.xsl.exslt.core/src/org/eclipse/wst/xsl/exslt/core/internal/resolver/EXSLTResolverExtension.java b/bundles/org.eclipse.wst.xsl.exslt.core/src/org/eclipse/wst/xsl/exslt/core/internal/resolver/EXSLTResolverExtension.java
new file mode 100644
index 0000000..378dcca
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.exslt.core/src/org/eclipse/wst/xsl/exslt/core/internal/resolver/EXSLTResolverExtension.java
@@ -0,0 +1,44 @@
+/*******************************************************************************
+ * Copyright (c) 2009 Standards for Technology in Automotive Retail 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:
+ *     David Carver - initial API and implementation
+ *******************************************************************************/
+package org.eclipse.wst.xsl.exslt.core.internal.resolver;
+
+import java.net.URL;
+
+import org.eclipse.core.resources.IFile;
+import org.eclipse.wst.common.uriresolver.internal.provisional.URIResolverExtension;
+import org.eclipse.wst.xsl.exslt.core.internal.EXSLTCore;
+import org.osgi.framework.Bundle;
+
+public class EXSLTResolverExtension implements URIResolverExtension {
+	Bundle bundle = null;
+	
+	public EXSLTResolverExtension() {
+		bundle = EXSLTCore.getDefault().getBundle();
+	}
+
+	public String resolve(IFile file, String baseLocation, String publicId, String systemId)
+	{
+		if (EXSLTCore.EXSLT_COMMON_NAMESPACE.equals(publicId)) {
+			return getURLPath("/schemas/common.xsd");
+		}
+		
+		if (EXSLTCore.EXSLT_FUNC_NAMESPACE.equals(publicId)) {
+			return getURLPath("/schemas/function.xsd");
+		}
+		
+		return null;
+	}
+	
+	private String getURLPath(String grammarPath) {
+		URL pluginURL = bundle.getEntry(grammarPath);
+		return pluginURL.toExternalForm();
+	}
+}
diff --git a/bundles/org.eclipse.wst.xsl.exslt.ui/.classpath b/bundles/org.eclipse.wst.xsl.exslt.ui/.classpath
new file mode 100644
index 0000000..64c5e31
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.exslt.ui/.classpath
@@ -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/J2SE-1.5"/>
+	<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
+	<classpathentry kind="src" path="src"/>
+	<classpathentry kind="output" path="bin"/>
+</classpath>
diff --git a/bundles/org.eclipse.wst.xsl.exslt.ui/.project b/bundles/org.eclipse.wst.xsl.exslt.ui/.project
new file mode 100644
index 0000000..59ac6c2
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.exslt.ui/.project
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+	<name>org.eclipse.wst.xsl.exslt.ui</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>
+		<buildCommand>
+			<name>org.eclipse.pde.api.tools.apiAnalysisBuilder</name>
+			<arguments>
+			</arguments>
+		</buildCommand>
+	</buildSpec>
+	<natures>
+		<nature>org.eclipse.pde.PluginNature</nature>
+		<nature>org.eclipse.jdt.core.javanature</nature>
+		<nature>org.eclipse.pde.api.tools.apiAnalysisNature</nature>
+	</natures>
+</projectDescription>
diff --git a/bundles/org.eclipse.wst.xsl.exslt.ui/.settings/org.eclipse.jdt.core.prefs b/bundles/org.eclipse.wst.xsl.exslt.ui/.settings/org.eclipse.jdt.core.prefs
new file mode 100644
index 0000000..7ba2275
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.exslt.ui/.settings/org.eclipse.jdt.core.prefs
@@ -0,0 +1,8 @@
+#Tue Sep 22 21:35:12 GMT 2009
+eclipse.preferences.version=1
+org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5
+org.eclipse.jdt.core.compiler.compliance=1.5
+org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
+org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
+org.eclipse.jdt.core.compiler.source=1.5
diff --git a/bundles/org.eclipse.wst.xsl.exslt.ui/META-INF/MANIFEST.MF b/bundles/org.eclipse.wst.xsl.exslt.ui/META-INF/MANIFEST.MF
new file mode 100644
index 0000000..786aa53
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.exslt.ui/META-INF/MANIFEST.MF
@@ -0,0 +1,18 @@
+Manifest-Version: 1.0
+Bundle-ManifestVersion: 2
+Bundle-Name: %pluginName
+Bundle-SymbolicName: org.eclipse.wst.xsl.exslt.ui;singleton:=true
+Bundle-Version: 1.0.0.qualifier
+Bundle-Activator: org.eclipse.wst.xsl.exslt.ui.internal.EXSLTUIPlugin
+Require-Bundle: org.eclipse.ui,
+ org.eclipse.core.runtime,
+ org.eclipse.wst.xsl.ui;bundle-version="[1.1.0,2.0.0)",
+ org.eclipse.jface.text;bundle-version="[3.4.0,4.0.0)",
+ org.eclipse.wst.xml.core;bundle-version="[1.1.0,2.0.0)",
+ org.eclipse.wst.xsl.core;bundle-version="[1.1.0,2.0.0)",
+ org.eclipse.wst.sse.core;bundle-version="[1.1.0,2.0.0)",
+ org.eclipse.wst.sse.ui;bundle-version="[1.1.200,2.0.0)",
+ org.eclipse.wst.xsl.exslt.core;bundle-version="[1.0.0,2.0.0)"
+Bundle-ActivationPolicy: lazy
+Bundle-RequiredExecutionEnvironment: J2SE-1.5
+Bundle-Vendor: %providerName
diff --git a/bundles/org.eclipse.wst.xsl.exslt.ui/about.html b/bundles/org.eclipse.wst.xsl.exslt.ui/about.html
new file mode 100644
index 0000000..2199df3
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.exslt.ui/about.html
@@ -0,0 +1,34 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
+<HTML>
+
+<head>
+<title>About</title>
+<meta http-equiv=Content-Type content="text/html; charset=ISO-8859-1">
+</head>
+
+<BODY lang="EN-US">
+
+<H3>About This Content</H3>
+
+<P>June, 2008</P>
+
+<H3>License</H3>
+
+<P>The Eclipse Foundation makes available all content in this plug-in 
+("Content"). Unless otherwise indicated below, the Content is provided to you 
+under the terms and conditions of the Eclipse Public License Version 1.0 
+("EPL"). A copy of the EPL is available at
+<A href="http://www.eclipse.org/org/documents/epl-v10.php">http://www.eclipse.org/org/documents/epl-v10.php</A>. 
+For purposes of the EPL, "Program" will mean the Content.</P>
+
+<P>If you did not receive this Content directly from the Eclipse Foundation, the 
+Content is being redistributed by another party ("Redistributor") and different 
+terms and conditions may apply to your use of any object code in the Content. 
+Check the Redistributor’s license that was provided with the Content. If no such 
+license exists, contact the Redistributor. Unless otherwise indicated below, the 
+terms and conditions of the EPL still apply to any source code in the Content 
+and such source code may be obtained at
+<A href="http://www.eclipse.org/">http://www.eclipse.org/</A>.</P>
+
+</BODY>
+</HTML>
diff --git a/bundles/org.eclipse.wst.xsl.exslt.ui/build.properties b/bundles/org.eclipse.wst.xsl.exslt.ui/build.properties
new file mode 100644
index 0000000..bf47ce8
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.exslt.ui/build.properties
@@ -0,0 +1,10 @@
+source.. = src/
+output.. = bin/
+bin.includes = META-INF/,\
+               .,\
+               plugin.xml,\
+               about.html
+src.includes = src/,\
+               build.properties,\
+               plugin.xml,\
+               about.html
diff --git a/bundles/org.eclipse.wst.xsl.exslt.ui/plugin.properties b/bundles/org.eclipse.wst.xsl.exslt.ui/plugin.properties
new file mode 100644
index 0000000..cbf2eb6
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.exslt.ui/plugin.properties
@@ -0,0 +1,13 @@
+###############################################################################
+# Copyright (c) 2009 Standards for Technology in Automotive Retail 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:
+#     David Carver - Initial API and Implementation
+###############################################################################
+
+providerName=Eclipse Web Tools Platform
+pluginName=EXSLT Core Extensions
diff --git a/bundles/org.eclipse.wst.xsl.exslt.ui/plugin.xml b/bundles/org.eclipse.wst.xsl.exslt.ui/plugin.xml
new file mode 100644
index 0000000..2eac0c1
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.exslt.ui/plugin.xml
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<?eclipse version="3.4"?>
+<plugin>
+   <extension
+         point="org.eclipse.wst.xsl.ui.contentAssistProcessor">
+      <processor
+            class="org.eclipse.wst.xsl.exslt.ui.internal.contentassist.EXSLTCommonContentAssistProcessor">
+      </processor>
+   </extension>
+
+</plugin>
diff --git a/bundles/org.eclipse.wst.xsl.exslt.ui/src/org/eclipse/wst/xsl/exslt/ui/internal/EXSLTUIPlugin.java b/bundles/org.eclipse.wst.xsl.exslt.ui/src/org/eclipse/wst/xsl/exslt/ui/internal/EXSLTUIPlugin.java
new file mode 100644
index 0000000..f751469
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.exslt.ui/src/org/eclipse/wst/xsl/exslt/ui/internal/EXSLTUIPlugin.java
@@ -0,0 +1,60 @@
+/*******************************************************************************
+ * Copyright (c) 2009 Standards for Technology in Automotive Retail 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:
+ *     David Carver - initial API and implementation
+ *******************************************************************************/
+package org.eclipse.wst.xsl.exslt.ui.internal;
+
+import org.eclipse.ui.plugin.AbstractUIPlugin;
+import org.osgi.framework.BundleContext;
+
+/**
+ * The activator class controls the plug-in life cycle
+ */
+public class EXSLTUIPlugin extends AbstractUIPlugin {
+
+	// The plug-in ID
+	public static final String PLUGIN_ID = "org.eclipse.wst.xsl.exslt.ui";
+
+	// The shared instance
+	private static EXSLTUIPlugin plugin;
+	
+	/**
+	 * The constructor
+	 */
+	public EXSLTUIPlugin() {
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framework.BundleContext)
+	 */
+	public void start(BundleContext context) throws Exception {
+		super.start(context);
+		plugin = this;
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framework.BundleContext)
+	 */
+	public void stop(BundleContext context) throws Exception {
+		plugin = null;
+		super.stop(context);
+	}
+
+	/**
+	 * Returns the shared instance
+	 *
+	 * @return the shared instance
+	 */
+	public static EXSLTUIPlugin getDefault() {
+		return plugin;
+	}
+
+}
diff --git a/bundles/org.eclipse.wst.xsl.exslt.ui/src/org/eclipse/wst/xsl/exslt/ui/internal/contentassist/CommonContentAssistRequest.java b/bundles/org.eclipse.wst.xsl.exslt.ui/src/org/eclipse/wst/xsl/exslt/ui/internal/contentassist/CommonContentAssistRequest.java
new file mode 100644
index 0000000..f94928e
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.exslt.ui/src/org/eclipse/wst/xsl/exslt/ui/internal/contentassist/CommonContentAssistRequest.java
@@ -0,0 +1,110 @@
+/*******************************************************************************
+ * Copyright (c) 2009 Standards for Technology in Automotive Retail 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:
+ *     David Carver - initial API and implementation
+ *******************************************************************************/
+package org.eclipse.wst.xsl.exslt.ui.internal.contentassist;
+
+import java.util.ArrayList;
+
+import org.eclipse.jface.text.ITextViewer;
+import org.eclipse.jface.text.contentassist.ICompletionProposal;
+import org.eclipse.wst.sse.core.internal.provisional.text.IStructuredDocumentRegion;
+import org.eclipse.wst.sse.core.internal.provisional.text.ITextRegion;
+import org.eclipse.wst.xml.core.internal.contentmodel.util.DOMNamespaceHelper;
+import org.eclipse.wst.xml.core.internal.contentmodel.util.NamespaceTable;
+import org.eclipse.wst.xml.core.internal.provisional.document.IDOMAttr;
+import org.eclipse.wst.xsl.core.model.CallTemplate;
+import org.eclipse.wst.xsl.exslt.core.internal.EXSLTCore;
+import org.eclipse.wst.xsl.ui.internal.util.XSLPluginImageHelper;
+import org.eclipse.wst.xsl.ui.internal.util.XSLPluginImages;
+import org.eclipse.wst.xsl.ui.provisional.contentassist.AbstractXSLContentAssistRequest;
+import org.eclipse.wst.xsl.ui.provisional.contentassist.CustomCompletionProposal;
+import org.eclipse.wst.xsl.ui.provisional.contentassist.SelectAttributeContentAssist;
+import org.w3c.dom.Document;
+import org.w3c.dom.Element;
+import org.w3c.dom.Node;
+
+public class CommonContentAssistRequest extends SelectAttributeContentAssist {
+
+	private static final String EXSLT_COMMON_NAMESPACE = "http://exslt.org/common";
+	private static final String NODE_SET = "node-set( )";
+	private static final String OBJECT_TYPE = "object-type( )";
+	
+	String prefix = "";
+	public CommonContentAssistRequest(Node node,
+			IStructuredDocumentRegion documentRegion,
+			ITextRegion completionRegion, int begin, int length, String filter,
+			ITextViewer textViewer) {
+		super(node, documentRegion, completionRegion, begin, length, filter,
+				textViewer);
+		
+	}
+
+	@Override
+	public ArrayList<ICompletionProposal> getCompletionProposals() {
+		proposals.clear();
+		
+		adjustXPathStart(SELECT_ATTRIBUTE);
+
+		int offset = getReplacementBeginPosition();
+		IDOMAttr attrNode = getAttribute(SELECT_ATTRIBUTE);
+
+		this.matchString = extractXPathMatchString(attrNode, getRegion(),
+				getReplacementBeginPosition());
+
+		addSelectProposals((Element) getNode().getParentNode(), offset);
+
+		return getAllCompletionProposals();
+	}
+
+	@Override
+	protected void addSelectProposals(Element rootElement, int offset) {
+		Document doc = rootElement.getOwnerDocument();
+		NamespaceTable namespaceTable = new NamespaceTable(doc);
+		namespaceTable.addElement(doc.getDocumentElement());
+		prefix = namespaceTable.getPrefixForURI(EXSLTCore.EXSLT_COMMON_NAMESPACE);
+		addNodeSetProposal();
+		addObjectTypeProposal();
+	}
+	
+	private void addNodeSetProposal() {
+		String nodeset = "";
+	
+		if (prefix != null) {
+			nodeset = prefix + ":" + NODE_SET;
+		} else {
+			nodeset = NODE_SET;
+		}
+		
+		CustomCompletionProposal proposal = new CustomCompletionProposal(
+				nodeset, getStartOffset() + 1, 0,
+				nodeset.length(), XSLPluginImageHelper
+						.getInstance().getImage(
+								XSLPluginImages.IMG_XPATH_FUNCTION), nodeset, null, null, 0);
+		proposals.add((ICompletionProposal)proposal);
+	}
+	
+	private void addObjectTypeProposal() {
+		String nodeset = "";
+	
+		if (prefix != null) {
+			nodeset = prefix + ":" + OBJECT_TYPE;
+		} else {
+			nodeset = OBJECT_TYPE;
+		}
+		
+		CustomCompletionProposal proposal = new CustomCompletionProposal(
+				nodeset, getStartOffset() + 1, 0,
+				nodeset.length(), XSLPluginImageHelper
+						.getInstance().getImage(
+								XSLPluginImages.IMG_XPATH_FUNCTION), nodeset, null, null, 0);
+		proposals.add((ICompletionProposal)proposal);
+	}	
+	
+}
diff --git a/bundles/org.eclipse.wst.xsl.exslt.ui/src/org/eclipse/wst/xsl/exslt/ui/internal/contentassist/EXSLTCommonContentAssistProcessor.java b/bundles/org.eclipse.wst.xsl.exslt.ui/src/org/eclipse/wst/xsl/exslt/ui/internal/contentassist/EXSLTCommonContentAssistProcessor.java
new file mode 100644
index 0000000..599ff37
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.exslt.ui/src/org/eclipse/wst/xsl/exslt/ui/internal/contentassist/EXSLTCommonContentAssistProcessor.java
@@ -0,0 +1,88 @@
+/*******************************************************************************
+ * Copyright (c) 2009 Standards for Technology in Automotive Retail 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:
+ *     David Carver - initial API and implementation
+ *******************************************************************************/
+package org.eclipse.wst.xsl.exslt.ui.internal.contentassist;
+
+import java.util.ArrayList;
+
+import org.eclipse.jface.text.ITextViewer;
+import org.eclipse.jface.text.contentassist.ICompletionProposal;
+import org.eclipse.jface.text.contentassist.IContentAssistProcessor;
+import org.eclipse.jface.text.contentassist.IContextInformation;
+import org.eclipse.jface.text.contentassist.IContextInformationValidator;
+import org.eclipse.wst.xsl.core.XSLCore;
+import org.eclipse.wst.xsl.ui.internal.XSLUIConstants;
+import org.eclipse.wst.xsl.ui.internal.XSLUIPlugin;
+import org.eclipse.wst.xsl.ui.internal.contentassist.XSLContentAssistRequestFactory;
+import org.eclipse.wst.xsl.ui.provisional.contentassist.AbstractXSLContentAssistProcessor;
+import org.eclipse.wst.xsl.ui.provisional.contentassist.IContentAssistProposalRequest;
+import org.w3c.dom.Document;
+import org.w3c.dom.Element;
+
+public class EXSLTCommonContentAssistProcessor extends
+		AbstractXSLContentAssistProcessor implements IContentAssistProcessor {
+
+	private ArrayList<ICompletionProposal> exsltProposals;
+	
+	public EXSLTCommonContentAssistProcessor() {
+	}
+
+	public String getMaximumVersion() {
+		return "1.0";
+	}
+
+	public String getMinimumVersion() {
+		return "1.0";
+	}
+
+	public ArrayList<String> getNamespaces() {
+		return null;
+	}
+
+
+	public IContextInformation[] computeContextInformation(ITextViewer viewer,
+			int offset) {
+		return null;
+	}
+
+
+	public char[] getContextInformationAutoActivationCharacters() {
+		return null;
+	}
+
+	public IContextInformationValidator getContextInformationValidator() {
+		return null;
+	}
+	
+	public ICompletionProposal[] computeCompletionProposals(
+			ITextViewer textViewer, int documentPosition) {
+		initializeProposalVariables(textViewer, documentPosition);
+		
+		// Only provide proposals for elements in either the XSLT Namespace or EXSLT namespace.
+		if (!xmlNode.getNamespaceURI().contains("http://exslt.org/") &&
+			!xmlNode.getNamespaceURI().equals(XSLCore.XSL_NAMESPACE_URI)) {
+			return null;
+		}
+
+		EXSLTContentAssistRequestFactory requestFactory = new EXSLTContentAssistRequestFactory(
+				textViewer, cursorPosition, xmlNode, sdRegion,
+				completionRegion, matchString);
+		
+		IContentAssistProposalRequest contentAssistRequest = requestFactory
+			.getContentAssistRequest();
+		
+		exsltProposals = contentAssistRequest.getCompletionProposals();
+		ICompletionProposal[] proposals = new ICompletionProposal[exsltProposals.size()];
+		exsltProposals.toArray(proposals);
+		
+		return proposals;
+	}
+
+}
diff --git a/bundles/org.eclipse.wst.xsl.exslt.ui/src/org/eclipse/wst/xsl/exslt/ui/internal/contentassist/EXSLTContentAssistRequestFactory.java b/bundles/org.eclipse.wst.xsl.exslt.ui/src/org/eclipse/wst/xsl/exslt/ui/internal/contentassist/EXSLTContentAssistRequestFactory.java
new file mode 100644
index 0000000..5d4978b
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.exslt.ui/src/org/eclipse/wst/xsl/exslt/ui/internal/contentassist/EXSLTContentAssistRequestFactory.java
@@ -0,0 +1,112 @@
+/*******************************************************************************
+ * Copyright (c) 2009 Standards for Technology in Automotive Retail 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:
+ *     David Carver - initial API and implementation
+ *******************************************************************************/
+package org.eclipse.wst.xsl.exslt.ui.internal.contentassist;
+
+import org.eclipse.jface.text.ITextViewer;
+import org.eclipse.wst.sse.core.internal.provisional.text.IStructuredDocumentRegion;
+import org.eclipse.wst.sse.core.internal.provisional.text.ITextRegion;
+import org.eclipse.wst.xml.core.internal.provisional.document.IDOMAttr;
+import org.eclipse.wst.xml.core.internal.provisional.document.IDOMElement;
+import org.eclipse.wst.xml.core.internal.provisional.document.IDOMNode;
+import org.eclipse.wst.xsl.ui.internal.contentassist.href.HrefContentAssistRequest;
+import org.eclipse.wst.xsl.ui.provisional.contentassist.IContentAssistProposalRequest;
+import org.eclipse.wst.xsl.ui.provisional.contentassist.NullContentAssistRequest;
+import org.eclipse.wst.xsl.ui.provisional.contentassist.SelectAttributeContentAssist;
+import org.eclipse.wst.xsl.ui.provisional.contentassist.TestAttributeContentAssist;
+import org.w3c.dom.NamedNodeMap;
+
+/**
+ * A Factory that determines which Content Assist Request class is needed and
+ * returns the appropriate class.
+ * 
+ * @author David Carver
+ * @since 1.0
+ */
+public class EXSLTContentAssistRequestFactory {
+	private static final String ATTR_SELECT = "select"; //$NON-NLS-1$
+	private static final String ATTR_TEST = "test"; //$NON-NLS-1$
+	private static final String ATTR_MATCH = "match"; //$NON-NLS-1$
+	private ITextViewer textViewer;
+	private int documentPosition;
+	private IDOMNode xmlNode;
+	private IStructuredDocumentRegion sdRegion;
+	private ITextRegion completionRegion;
+	private String matchString;
+	
+
+	/**
+	 * @param textViewer
+	 * @param documentPosition
+	 * @param xmlNode
+	 * @param sdRegion
+	 * @param completionRegion
+	 * @param matchString
+	 */
+	public EXSLTContentAssistRequestFactory(ITextViewer textViewer, int documentPosition, IDOMNode xmlNode,
+			IStructuredDocumentRegion sdRegion, ITextRegion completionRegion,
+			String matchString) {
+		this.textViewer = textViewer;
+		this.documentPosition = documentPosition;
+		this.xmlNode = xmlNode;
+		this.sdRegion = sdRegion;
+		this.completionRegion = completionRegion;
+		this.matchString = matchString;
+	}
+	
+	/**
+	 * Get the appropriate content assist request class for the XSL request.
+	 * @return
+	 */
+	public IContentAssistProposalRequest getContentAssistRequest() {
+		NamedNodeMap nodeMap = xmlNode.getAttributes();
+		IDOMElement element = (IDOMElement) xmlNode;
+		IContentAssistProposalRequest proposal = commonAttributeProposals(nodeMap);
+		
+		if (proposal instanceof NullContentAssistRequest) {
+			if (isElementProposal(element)) {
+				proposal = getNullProposal();
+			}
+		}
+
+		return proposal;
+	}
+	
+	private boolean isElementProposal(IDOMElement element) {
+		String localName = element.getLocalName();
+		return false;
+	}
+	
+	private IContentAssistProposalRequest commonAttributeProposals(
+			NamedNodeMap nodeMap) {
+		if (hasAttributeAtTextRegion(ATTR_SELECT, nodeMap,
+				completionRegion) ||
+			hasAttributeAtTextRegion(ATTR_TEST, nodeMap, completionRegion)) {
+			return new CommonContentAssistRequest(xmlNode, sdRegion,
+					completionRegion, documentPosition, 0, matchString,
+					textViewer);
+		}
+		
+		return getNullProposal();
+	}
+	
+	protected boolean hasAttributeAtTextRegion(String attrName,
+			NamedNodeMap nodeMap, ITextRegion aRegion) {
+		IDOMAttr attrNode = (IDOMAttr) nodeMap.getNamedItem(attrName);
+		return attrNode != null && attrNode.getValueRegion() != null
+				&& attrNode.getValueRegion().getStart() == aRegion.getStart();
+	}	
+	
+	private IContentAssistProposalRequest getNullProposal() {
+		return new NullContentAssistRequest(xmlNode, sdRegion,
+				completionRegion, documentPosition, 0, matchString, textViewer);
+	}
+	
+}