Skip to main content

This CGIT instance is deprecated, and repositories have been moved to Gitlab or Github. See the repository descriptions for specific locations.

summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorpavery2005-04-01 21:09:29 +0000
committerpavery2005-04-01 21:09:29 +0000
commit40dd89ea147e353bc3559f130246c887e7c6ffff (patch)
tree64372abaa16ac977b112bf04bcb4e4fb46519bca
parent89f4f03964b704dcfcfa41b7e46f7e3333b6eb93 (diff)
downloadwebtools.sourceediting-40dd89ea147e353bc3559f130246c887e7c6ffff.tar.gz
webtools.sourceediting-40dd89ea147e353bc3559f130246c887e7c6ffff.tar.xz
webtools.sourceediting-40dd89ea147e353bc3559f130246c887e7c6ffff.zip
more API cleanup (mostly partition types)
-rw-r--r--bundles/org.eclipse.jst.jsp.core/src/org/eclipse/jst/jsp/core/internal/document/PageDirectiveAdapterImpl.java4
-rw-r--r--bundles/org.eclipse.jst.jsp.core/src/org/eclipse/jst/jsp/core/internal/text/NullStructuredDocumentPartitioner.java16
-rw-r--r--bundles/org.eclipse.jst.jsp.core/src/org/eclipse/jst/jsp/core/internal/text/StructuredTextPartitionerForJSP.java43
-rw-r--r--bundles/org.eclipse.jst.jsp.core/src/org/eclipse/jst/jsp/core/text/IJSPPartitionTypes.java (renamed from bundles/org.eclipse.jst.jsp.core/src/org/eclipse/jst/jsp/core/text/IJSPPartitions.java)7
-rw-r--r--bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/StructuredTextViewerConfigurationJSP.java102
-rw-r--r--bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/breakpointproviders/JavaStratumBreakpointProvider.java4
-rw-r--r--bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/contentassist/JSPContentAssistProcessor.java45
-rw-r--r--bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/contentassist/JSPJavaContentAssistProcessor.java4
-rw-r--r--bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/contentassist/NoRegionContentAssistProcessorForJSP.java24
-rw-r--r--bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/hyperlink/TaglibHyperlinkDetector.java8
-rw-r--r--bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/java/search/JSPFindOccurrencesAction.java4
-rw-r--r--bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/reconcile/ReconcileStepForJava.java4
-rw-r--r--bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/registry/AdapterFactoryProviderForJSP.java2
-rw-r--r--bundles/org.eclipse.wst.css.core/src/org/eclipse/wst/css/core/format/FormatProcessorCSS.java6
-rw-r--r--bundles/org.eclipse.wst.css.core/src/org/eclipse/wst/css/core/internal/cleanup/CleanupProcessorCSS.java2
-rw-r--r--bundles/org.eclipse.wst.css.core/src/org/eclipse/wst/css/core/internal/text/StructuredTextPartitionerForCSS.java10
-rw-r--r--bundles/org.eclipse.wst.css.core/src/org/eclipse/wst/css/core/text/ICSSPartitionTypes.java (renamed from bundles/org.eclipse.wst.css.core/src/org/eclipse/wst/css/core/text/ICSSPartitions.java)6
-rw-r--r--bundles/org.eclipse.wst.css.ui/src/org/eclipse/wst/css/ui/StructuredTextViewerConfigurationCSS.java16
-rw-r--r--bundles/org.eclipse.wst.css.ui/src/org/eclipse/wst/css/ui/registry/AdapterFactoryProviderCSS.java2
-rw-r--r--bundles/org.eclipse.wst.dtd.core/src/org/eclipse/wst/dtd/core/internal/text/StructuredTextPartitionerForDTD.java10
-rw-r--r--bundles/org.eclipse.wst.dtd.core/src/org/eclipse/wst/dtd/core/text/IDTDPartitionTypes.java (renamed from bundles/org.eclipse.wst.dtd.core/src/org/eclipse/wst/dtd/core/text/IDTDPartitions.java)7
-rw-r--r--bundles/org.eclipse.wst.dtd.ui/src/org/eclipse/wst/dtd/ui/StructuredTextViewerConfigurationDTD.java12
-rw-r--r--bundles/org.eclipse.wst.dtd.ui/src/org/eclipse/wst/dtd/ui/internal/style/LineStyleProviderForDTDSubSet.java7
-rw-r--r--bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/HTMLFormatContraints.java2
-rw-r--r--bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/format/HTMLFormatContraintsImpl.java2
-rw-r--r--bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/format/HTMLFormatProcessorImpl.java4
-rw-r--r--bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/format/HTMLFormatter.java6
-rw-r--r--bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/format/HTMLFormatterFactory.java4
-rw-r--r--bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/internal/cleanup/HTMLCleanupProcessorImpl.java2
-rw-r--r--bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/internal/text/StructuredTextPartitionerForHTML.java78
-rw-r--r--bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/text/IHTMLPartitionTypes.java (renamed from bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/text/IHTMLPartitions.java)9
-rw-r--r--bundles/org.eclipse.wst.html.ui/src/org/eclipse/wst/html/ui/StructuredTextViewerConfigurationHTML.java50
-rw-r--r--bundles/org.eclipse.wst.html.ui/src/org/eclipse/wst/html/ui/internal/contentassist/NoRegionContentAssistProcessorForHTML.java12
-rw-r--r--bundles/org.eclipse.wst.html.ui/src/org/eclipse/wst/html/ui/internal/contentoutline/HTMLNodeActionManager.java2
-rw-r--r--bundles/org.eclipse.wst.html.ui/src/org/eclipse/wst/html/ui/internal/search/HTMLFindOccurrencesAction.java4
-rw-r--r--bundles/org.eclipse.wst.sse.core/component.xml105
-rw-r--r--bundles/org.eclipse.wst.sse.core/schema/formatProcessors.exsd12
-rw-r--r--bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/AbstractModelLoader.java5
-rw-r--r--bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/IModelLoader.java2
-rw-r--r--bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/document/AbstractDocumentLoader.java11
-rw-r--r--bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/document/IDocumentLoader.java3
-rw-r--r--bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/format/IStructuredContentFormatter.java19
-rw-r--r--bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/cleanup/AbstractStructuredCleanupProcessor.java2
-rw-r--r--bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/format/AbstractStructuredFormatProcessor.java (renamed from bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/format/AbstractStructuredFormatProcessor.java)2
-rw-r--r--bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/format/IStructuredFormatContraints.java (renamed from bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/format/IStructuredFormatContraints.java)10
-rw-r--r--bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/format/IStructuredFormatPreferences.java (renamed from bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/format/IStructuredFormatPreferences.java)8
-rw-r--r--bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/format/IStructuredFormatProcessor.java (renamed from bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/format/IStructuredFormatProcessor.java)59
-rw-r--r--bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/format/IStructuredFormatter.java (renamed from bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/format/IStructuredFormatter.java)8
-rw-r--r--bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/format/StructuredFormatContraints.java (renamed from bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/format/StructuredFormatContraints.java)2
-rw-r--r--bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/format/StructuredFormatPreferences.java (renamed from bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/format/StructuredFormatPreferences.java)2
-rw-r--r--bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/text/BasicStructuredDocument.java15
-rw-r--r--bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/text/rules/StructuredTextPartitioner.java42
-rw-r--r--bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/IStructuredDocument.java2
-rw-r--r--bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/IStructuredPartitionTypes.java (renamed from bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/IStructuredPartitions.java)4
-rw-r--r--bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/IStructuredPartitioning.java12
-rw-r--r--bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/IStructuredRegion.java (renamed from bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/StructuredRegion.java)2
-rw-r--r--bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/IStructuredTextPartitioner.java70
-rw-r--r--bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/IStructuredTypedRegion.java (renamed from bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/StructuredTypedRegion.java)4
-rw-r--r--bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/SimpleStructuredRegion.java2
-rw-r--r--bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/SimpleStructuredTypedRegion.java2
-rw-r--r--bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/StructuredTextViewerConfiguration.java3
-rw-r--r--bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/extension/FormatProcessorsExtensionReader.java2
-rw-r--r--bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/format/StructuredFormattingStrategy.java2
-rw-r--r--bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/internal/SSEUIPluginResources.properties1
-rw-r--r--bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/internal/actions/FormatActionDelegate.java2
-rw-r--r--bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/internal/reconcile/DirtyRegionProcessor.java4
-rw-r--r--bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/internal/reconcile/StructuredReconcileStep.java9
-rw-r--r--bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/internal/ui/OffsetStatusLineContributionItem.java7
-rw-r--r--bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/openon/OpenOnProvider.java3
-rw-r--r--bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/CommentNodeFormatter.java2
-rw-r--r--bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/DocumentNodeFormatter.java4
-rw-r--r--bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/ElementNodeFormatter.java2
-rw-r--r--bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/FormatProcessorXML.java6
-rw-r--r--bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/IStructuredFormatPreferencesXML.java2
-rw-r--r--bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/NodeFormatter.java8
-rw-r--r--bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/StructuredFormatPreferencesXML.java2
-rw-r--r--bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/TextNodeFormatter.java2
-rw-r--r--bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/internal/cleanup/CleanupProcessorXML.java2
-rw-r--r--bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/internal/text/rules/StructuredTextPartitionerForXML.java11
-rw-r--r--bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/text/IXMLPartitions.java5
-rw-r--r--bundles/org.eclipse.wst.xml.ui/src/org/eclipse/wst/xml/ui/StructuredTextViewerConfigurationXML.java14
-rw-r--r--bundles/org.eclipse.wst.xml.ui/src/org/eclipse/wst/xml/ui/internal/XMLUIPluginResources.properties1
-rw-r--r--bundles/org.eclipse.wst.xml.ui/src/org/eclipse/wst/xml/ui/internal/contentoutline/XMLNodeActionManager.java2
-rw-r--r--bundles/org.eclipse.wst.xml.ui/src/org/eclipse/wst/xml/ui/internal/correction/SurroundWithNewElementQuickAssistProposal.java2
-rw-r--r--bundles/org.eclipse.wst.xsd.ui/src/org/eclipse/wst/xsd/ui/internal/actions/CreateAttributeAndRequired.java2
-rw-r--r--bundles/org.eclipse.wst.xsd.ui/src/org/eclipse/wst/xsd/ui/internal/actions/CreateElementAction.java2
-rw-r--r--bundles/org.eclipse.wst.xsd.ui/src/org/eclipse/wst/xsd/ui/internal/actions/SetBaseTypeAction.java2
-rw-r--r--bundles/org.eclipse.wst.xsd.ui/src/org/eclipse/wst/xsd/ui/internal/commands/AbstractCommand.java2
-rw-r--r--bundles/org.eclipse.wst.xsd.ui/src/org/eclipse/wst/xsd/ui/internal/util/XSDDOMHelper.java2
89 files changed, 515 insertions, 518 deletions
diff --git a/bundles/org.eclipse.jst.jsp.core/src/org/eclipse/jst/jsp/core/internal/document/PageDirectiveAdapterImpl.java b/bundles/org.eclipse.jst.jsp.core/src/org/eclipse/jst/jsp/core/internal/document/PageDirectiveAdapterImpl.java
index 32c235e121..55bf775609 100644
--- a/bundles/org.eclipse.jst.jsp.core/src/org/eclipse/jst/jsp/core/internal/document/PageDirectiveAdapterImpl.java
+++ b/bundles/org.eclipse.jst.jsp.core/src/org/eclipse/jst/jsp/core/internal/document/PageDirectiveAdapterImpl.java
@@ -33,7 +33,7 @@ import org.eclipse.wst.sse.core.IStructuredModel;
import org.eclipse.wst.sse.core.internal.modelhandler.EmbeddedTypeRegistry;
import org.eclipse.wst.sse.core.internal.modelhandler.EmbeddedTypeRegistryImpl;
import org.eclipse.wst.sse.core.modelhandler.EmbeddedTypeHandler;
-import org.eclipse.wst.sse.core.text.IStructuredDocument;
+import org.eclipse.wst.sse.core.text.IStructuredPartitioning;
import org.eclipse.wst.sse.core.util.Debug;
import org.eclipse.wst.sse.core.util.StringUtils;
import org.eclipse.wst.xml.core.document.XMLNode;
@@ -485,7 +485,7 @@ public class PageDirectiveAdapterImpl implements PageDirectiveAdapter {
*/
public void setLanguage(String newLanguage) {
this.cachedLanguage = newLanguage;
- IDocumentPartitioner partitioner = ((IDocumentExtension3) model.getStructuredDocument()).getDocumentPartitioner(IStructuredDocument.DEFAULT_STRUCTURED_PARTITIONING);
+ IDocumentPartitioner partitioner = ((IDocumentExtension3) model.getStructuredDocument()).getDocumentPartitioner(IStructuredPartitioning.DEFAULT_STRUCTURED_PARTITIONING);
if (partitioner instanceof StructuredTextPartitionerForJSP) {
((StructuredTextPartitionerForJSP) partitioner).setLanguage(newLanguage);
}
diff --git a/bundles/org.eclipse.jst.jsp.core/src/org/eclipse/jst/jsp/core/internal/text/NullStructuredDocumentPartitioner.java b/bundles/org.eclipse.jst.jsp.core/src/org/eclipse/jst/jsp/core/internal/text/NullStructuredDocumentPartitioner.java
index fd932d35cd..3fae7869db 100644
--- a/bundles/org.eclipse.jst.jsp.core/src/org/eclipse/jst/jsp/core/internal/text/NullStructuredDocumentPartitioner.java
+++ b/bundles/org.eclipse.jst.jsp.core/src/org/eclipse/jst/jsp/core/internal/text/NullStructuredDocumentPartitioner.java
@@ -16,7 +16,7 @@ import org.eclipse.jface.text.ITypedRegion;
import org.eclipse.wst.sse.core.text.IStructuredDocumentRegion;
import org.eclipse.wst.sse.core.text.IStructuredTextPartitioner;
import org.eclipse.wst.sse.core.text.ITextRegion;
-import org.eclipse.wst.sse.core.text.StructuredTypedRegion;
+import org.eclipse.wst.sse.core.text.IStructuredTypedRegion;
/**
* To be used when no known partitioner is available.
@@ -24,7 +24,7 @@ import org.eclipse.wst.sse.core.text.StructuredTypedRegion;
*/
public class NullStructuredDocumentPartitioner implements IStructuredTextPartitioner {
- public class NullStructuredTypedRegion implements StructuredTypedRegion {
+ public class NullStructuredTypedRegion implements IStructuredTypedRegion {
private int fOffset;
@@ -70,8 +70,8 @@ public class NullStructuredDocumentPartitioner implements IStructuredTextPartiti
// nothing to do
}
- public StructuredTypedRegion createPartition(int offset, int length, String type) {
- StructuredTypedRegion result = new NullStructuredTypedRegion();
+ public IStructuredTypedRegion createPartition(int offset, int length, String type) {
+ IStructuredTypedRegion result = new NullStructuredTypedRegion();
result.setOffset(offset);
result.setLength(length);
result.setType(type);
@@ -82,7 +82,7 @@ public class NullStructuredDocumentPartitioner implements IStructuredTextPartiti
// nothing to do
}
- public String getDefault() {
+ public String getDefaultPartitionType() {
return ST_UNKNOWN_PARTITION;
}
@@ -94,7 +94,7 @@ public class NullStructuredDocumentPartitioner implements IStructuredTextPartiti
return ST_UNKNOWN_PARTITION;
}
- public String getPartitionTypeBetween(IStructuredDocumentRegion previousNode, ITextRegion previousStartTagNameRegion, IStructuredDocumentRegion nextNode, ITextRegion nextEndTagNameRegion) {
+ public String getPartitionTypeBetween(IStructuredDocumentRegion previousNode, IStructuredDocumentRegion nextNode) {
return ST_UNKNOWN_PARTITION;
}
@@ -111,11 +111,11 @@ public class NullStructuredDocumentPartitioner implements IStructuredTextPartiti
}
public String getContentType(int offset) {
- return getDefault();
+ return getDefaultPartitionType();
}
public ITypedRegion getPartition(int offset) {
- return createPartition(offset, 1, getDefault());
+ return createPartition(offset, 1, getDefaultPartitionType());
}
} \ No newline at end of file
diff --git a/bundles/org.eclipse.jst.jsp.core/src/org/eclipse/jst/jsp/core/internal/text/StructuredTextPartitionerForJSP.java b/bundles/org.eclipse.jst.jsp.core/src/org/eclipse/jst/jsp/core/internal/text/StructuredTextPartitionerForJSP.java
index 25f487c72b..066584f80e 100644
--- a/bundles/org.eclipse.jst.jsp.core/src/org/eclipse/jst/jsp/core/internal/text/StructuredTextPartitionerForJSP.java
+++ b/bundles/org.eclipse.jst.jsp.core/src/org/eclipse/jst/jsp/core/internal/text/StructuredTextPartitionerForJSP.java
@@ -24,7 +24,7 @@ import org.eclipse.jst.jsp.core.contentmodel.tld.JSP12TLDNames;
import org.eclipse.jst.jsp.core.encoding.JSPDocumentHeadContentDetector;
import org.eclipse.jst.jsp.core.internal.parser.JSPSourceParser;
import org.eclipse.jst.jsp.core.model.parser.DOMJSPRegionContexts;
-import org.eclipse.jst.jsp.core.text.IJSPPartitions;
+import org.eclipse.jst.jsp.core.text.IJSPPartitionTypes;
import org.eclipse.wst.html.core.internal.text.StructuredTextPartitionerForHTML;
import org.eclipse.wst.sse.core.internal.parser.ForeignRegion;
import org.eclipse.wst.sse.core.internal.text.rules.StructuredTextPartitioner;
@@ -173,7 +173,7 @@ public class StructuredTextPartitionerForJSP extends StructuredTextPartitioner {
private static final String XHTML_MIME_TYPE = "text/xhtml"; //$NON-NLS-1$
private static final String XML_MIME_TYPE = "text/xml"; //$NON-NLS-1$
- private final static String[] fConfiguredContentTypes = new String[]{IJSPPartitions.JSP_DEFAULT, IJSPPartitions.JSP_DEFAULT_EL, IJSPPartitions.JSP_DIRECTIVE, IJSPPartitions.JSP_CONTENT_DELIMITER, IJSPPartitions.JSP_CONTENT_JAVA, IJSPPartitions.JSP_CONTENT_JAVASCRIPT, IJSPPartitions.JSP_COMMENT};
+ private final static String[] fConfiguredContentTypes = new String[]{IJSPPartitionTypes.JSP_DEFAULT, IJSPPartitionTypes.JSP_DEFAULT_EL, IJSPPartitionTypes.JSP_DIRECTIVE, IJSPPartitionTypes.JSP_CONTENT_DELIMITER, IJSPPartitionTypes.JSP_CONTENT_JAVA, IJSPPartitionTypes.JSP_CONTENT_JAVASCRIPT, IJSPPartitionTypes.JSP_COMMENT};
/**
* @return
@@ -296,8 +296,8 @@ public class StructuredTextPartitionerForJSP extends StructuredTextPartitioner {
super.disconnect();
}
- public String getDefault() {
- return getEmbeddedPartitioner().getDefault();
+ public String getDefaultPartitionType() {
+ return getEmbeddedPartitioner().getDefaultPartitionType();
}
/**
@@ -363,24 +363,24 @@ public class StructuredTextPartitionerForJSP extends StructuredTextPartitioner {
result = getPartitionTypeForDocumentLanguage();
}
else if (region_type == DOMJSPRegionContexts.JSP_COMMENT_TEXT || region_type == DOMJSPRegionContexts.JSP_COMMENT_OPEN || region_type == DOMJSPRegionContexts.JSP_COMMENT_CLOSE)
- result = IJSPPartitions.JSP_COMMENT;
+ result = IJSPPartitionTypes.JSP_COMMENT;
else if (region_type == DOMJSPRegionContexts.JSP_DIRECTIVE_NAME || region_type == DOMJSPRegionContexts.JSP_DIRECTIVE_OPEN || region_type == DOMJSPRegionContexts.JSP_DIRECTIVE_CLOSE)
- result = IJSPPartitions.JSP_DIRECTIVE;
+ result = IJSPPartitionTypes.JSP_DIRECTIVE;
else if (region_type == DOMJSPRegionContexts.JSP_CLOSE || region_type == DOMJSPRegionContexts.JSP_SCRIPTLET_OPEN || region_type == DOMJSPRegionContexts.JSP_EXPRESSION_OPEN || region_type == DOMJSPRegionContexts.JSP_DECLARATION_OPEN)
- result = IJSPPartitions.JSP_CONTENT_DELIMITER;
+ result = IJSPPartitionTypes.JSP_CONTENT_DELIMITER;
else if (region_type == DOMJSPRegionContexts.JSP_ROOT_TAG_NAME)
- result = IJSPPartitions.JSP_DEFAULT;
+ result = IJSPPartitionTypes.JSP_DEFAULT;
else if (region_type == DOMJSPRegionContexts.JSP_EL_OPEN || region_type == DOMJSPRegionContexts.JSP_EL_CONTENT || region_type == DOMJSPRegionContexts.JSP_EL_CLOSE || region_type == DOMJSPRegionContexts.JSP_EL_DQUOTE
|| region_type == DOMJSPRegionContexts.JSP_EL_SQUOTE || region_type == DOMJSPRegionContexts.JSP_EL_QUOTED_CONTENT)
- result = IJSPPartitions.JSP_DEFAULT_EL;
+ result = IJSPPartitionTypes.JSP_DEFAULT_EL;
else if (region_type == XMLRegionContext.XML_CONTENT) {
// possibly between <jsp:scriptlet>, <jsp:expression>,
- // <jsp:declration>
+ // <jsp:declaration>
IStructuredDocumentRegion sdRegion = this.structuredDocument.getRegionAtCharacterOffset(offset);
if (isJspJavaActionName(getParentName(sdRegion)))
result = getPartitionTypeForDocumentLanguage();
else
- result = getDefault();
+ result = getDefaultPartitionType();
}
else {
result = getEmbeddedPartitioner().getPartitionType(region, offset);
@@ -388,27 +388,20 @@ public class StructuredTextPartitionerForJSP extends StructuredTextPartitioner {
return result;
}
- /**
- * @see com.ibm.sed.structuredDocument.partition.StructuredTextPartitioner#getPartitionType(com.ibm.sed.structuredDocument.ITextRegion,
- * com.ibm.sed.structuredDocument.ITextRegion)
- */
- public String getPartitionTypeBetween(IStructuredDocumentRegion previousNode, ITextRegion previousStartTagNameRegion, IStructuredDocumentRegion nextNode, ITextRegion nextEndTagNameRegion) {
- return getEmbeddedPartitioner().getPartitionTypeBetween(previousNode, previousStartTagNameRegion, nextNode, nextEndTagNameRegion);
+ public String getPartitionTypeBetween(IStructuredDocumentRegion previousNode, IStructuredDocumentRegion nextNode) {
+ return getEmbeddedPartitioner().getPartitionTypeBetween(previousNode, nextNode);
}
- /**
- * @return
- */
private String getPartitionTypeForDocumentLanguage() {
String result;
if (fLanguage == null || fLanguage.equalsIgnoreCase("java")) { //$NON-NLS-1$
- result = IJSPPartitions.JSP_CONTENT_JAVA;
+ result = IJSPPartitionTypes.JSP_CONTENT_JAVA;
}
else if (fLanguage.equalsIgnoreCase("javascript")) { //$NON-NLS-1$
- result = IJSPPartitions.JSP_CONTENT_JAVASCRIPT;
+ result = IJSPPartitionTypes.JSP_CONTENT_JAVASCRIPT;
}
else {
- result = IJSPPartitions.JSP_SCRIPT_PREFIX + getLanguage().toUpperCase(Locale.ENGLISH);
+ result = IJSPPartitionTypes.JSP_SCRIPT_PREFIX + getLanguage().toUpperCase(Locale.ENGLISH);
}
return result;
}
@@ -454,11 +447,11 @@ public class StructuredTextPartitionerForJSP extends StructuredTextPartitioner {
String documentRegionContext = sdRegion.getType();
if (containedChildRegion != null) {
if (documentRegionContext.equals(DOMJSPRegionContexts.JSP_DIRECTIVE_NAME) || documentRegionContext.equals(DOMJSPRegionContexts.JSP_ROOT_TAG_NAME)) {
- setInternalPartition(offset, containedChildRegion.getLength(), IJSPPartitions.JSP_DIRECTIVE);
+ setInternalPartition(offset, containedChildRegion.getLength(), IJSPPartitionTypes.JSP_DIRECTIVE);
return true;
}
if (fEnableJSPActionPartitions && isAction(sdRegion, offset)) {
- setInternalPartition(offset, containedChildRegion.getLength(), IJSPPartitions.JSP_DIRECTIVE);
+ setInternalPartition(offset, containedChildRegion.getLength(), IJSPPartitionTypes.JSP_DIRECTIVE);
return true;
}
}
diff --git a/bundles/org.eclipse.jst.jsp.core/src/org/eclipse/jst/jsp/core/text/IJSPPartitions.java b/bundles/org.eclipse.jst.jsp.core/src/org/eclipse/jst/jsp/core/text/IJSPPartitionTypes.java
index 9f14225d6d..52fe6d4f26 100644
--- a/bundles/org.eclipse.jst.jsp.core/src/org/eclipse/jst/jsp/core/text/IJSPPartitions.java
+++ b/bundles/org.eclipse.jst.jsp.core/src/org/eclipse/jst/jsp/core/text/IJSPPartitionTypes.java
@@ -1,18 +1,15 @@
package org.eclipse.jst.jsp.core.text;
-import org.eclipse.wst.sse.core.text.IStructuredPartitions;
/**
* This interface is not intended to be implemented.
- * It defines the partitioning for JSP and all its partitions.
+ * It defines the partition types for JSP.
* Clients should reference the partition type Strings defined here directly.
*
* @since 1.0
*/
-public interface IJSPPartitions {
+public interface IJSPPartitionTypes {
- String JSP_PARTITIONING = IStructuredPartitions.STRUCTURED_PARTITIONING;
-
String JSP_DEFAULT = "org.eclipse.jst.jsp.DEFAULT_JSP"; //$NON-NLS-1$
String JSP_COMMENT = "org.eclipse.jst.jsp.JSP_COMMENT"; //$NON-NLS-1$
diff --git a/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/StructuredTextViewerConfigurationJSP.java b/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/StructuredTextViewerConfigurationJSP.java
index 0788eb3692..57439e70d2 100644
--- a/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/StructuredTextViewerConfigurationJSP.java
+++ b/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/StructuredTextViewerConfigurationJSP.java
@@ -35,7 +35,7 @@ import org.eclipse.jface.text.reconciler.IReconciler;
import org.eclipse.jface.text.reconciler.IReconcilingStrategy;
import org.eclipse.jface.text.source.ISourceViewer;
import org.eclipse.jst.jsp.core.internal.text.StructuredTextPartitionerForJSP;
-import org.eclipse.jst.jsp.core.text.IJSPPartitions;
+import org.eclipse.jst.jsp.core.text.IJSPPartitionTypes;
import org.eclipse.jst.jsp.ui.internal.autoedit.StructuredAutoEditStrategyJSP;
import org.eclipse.jst.jsp.ui.internal.contentassist.JSPContentAssistProcessor;
import org.eclipse.jst.jsp.ui.internal.contentassist.JSPJavaContentAssistProcessor;
@@ -54,12 +54,12 @@ import org.eclipse.jst.jsp.ui.internal.taginfo.JSPJavaJavadocHoverProcessor;
import org.eclipse.jst.jsp.ui.internal.taginfo.JSPTagInfoHoverProcessor;
import org.eclipse.ui.texteditor.AbstractDecoratedTextEditorPreferenceConstants;
import org.eclipse.ui.texteditor.ITextEditor;
-import org.eclipse.wst.css.core.text.ICSSPartitions;
+import org.eclipse.wst.css.core.text.ICSSPartitionTypes;
import org.eclipse.wst.css.ui.contentassist.CSSContentAssistProcessor;
import org.eclipse.wst.css.ui.style.LineStyleProviderForEmbeddedCSS;
import org.eclipse.wst.html.core.format.HTMLFormatProcessorImpl;
import org.eclipse.wst.html.core.internal.text.StructuredTextPartitionerForHTML;
-import org.eclipse.wst.html.core.text.IHTMLPartitions;
+import org.eclipse.wst.html.core.text.IHTMLPartitionTypes;
import org.eclipse.wst.html.ui.internal.contentassist.HTMLContentAssistProcessor;
import org.eclipse.wst.html.ui.style.LineStyleProviderForHTML;
import org.eclipse.wst.html.ui.taginfo.HTMLBestMatchHoverProcessor;
@@ -72,7 +72,7 @@ import org.eclipse.wst.javascript.common.ui.internal.taginfo.JavaScriptInformati
import org.eclipse.wst.javascript.common.ui.internal.taginfo.JavaScriptTagInfoHoverProcessor;
import org.eclipse.wst.sse.core.IStructuredModel;
import org.eclipse.wst.sse.core.StructuredModelManager;
-import org.eclipse.wst.sse.core.text.IStructuredPartitions;
+import org.eclipse.wst.sse.core.text.IStructuredPartitionTypes;
import org.eclipse.wst.sse.ui.StructuredTextViewerConfiguration;
import org.eclipse.wst.sse.ui.format.StructuredFormattingStrategy;
import org.eclipse.wst.sse.ui.internal.SSEUIPlugin;
@@ -122,11 +122,11 @@ public class StructuredTextViewerConfigurationJSP extends StructuredTextViewerCo
allStrategies.add(superStrategies[i]);
}
- if (contentType == IJSPPartitions.JSP_CONTENT_JAVA) {
+ if (contentType == IJSPPartitionTypes.JSP_CONTENT_JAVA) {
allStrategies.add(getJavaSourceViewerConfiguration().getAutoEditStrategies(sourceViewer, IJavaPartitions.JAVA_PARTITIONING)[0]);
}
- if (contentType == IHTMLPartitions.HTML_DEFAULT || contentType == IHTMLPartitions.HTML_DECLARATION) {
+ if (contentType == IHTMLPartitionTypes.HTML_DEFAULT || contentType == IHTMLPartitionTypes.HTML_DECLARATION) {
allStrategies.add(new StructuredAutoEditStrategyJSP());
}
@@ -140,8 +140,8 @@ public class StructuredTextViewerConfigurationJSP extends StructuredTextViewerCo
String[] jspTypes = StructuredTextPartitionerForJSP.getConfiguredContentTypes();
configuredContentTypes = new String[2 + xmlTypes.length + htmlTypes.length + jspTypes.length];
- configuredContentTypes[0] = IStructuredPartitions.DEFAULT_PARTITION;
- configuredContentTypes[1] = IStructuredPartitions.UNKNOWN_PARTITION;
+ configuredContentTypes[0] = IStructuredPartitionTypes.DEFAULT_PARTITION;
+ configuredContentTypes[1] = IStructuredPartitionTypes.UNKNOWN_PARTITION;
int index = 0;
System.arraycopy(xmlTypes, 0, configuredContentTypes, index += 2, xmlTypes.length);
@@ -166,36 +166,36 @@ public class StructuredTextViewerConfigurationJSP extends StructuredTextViewerCo
IContentAssistProcessor noRegionProcessorJsp = new NoRegionContentAssistProcessorForJSP();
// HTML
- setContentAssistProcessor(contentAssistant, htmlContentAssistProcessor, IHTMLPartitions.HTML_DEFAULT);
- setContentAssistProcessor(contentAssistant, htmlContentAssistProcessor, IHTMLPartitions.HTML_COMMENT);
+ setContentAssistProcessor(contentAssistant, htmlContentAssistProcessor, IHTMLPartitionTypes.HTML_DEFAULT);
+ setContentAssistProcessor(contentAssistant, htmlContentAssistProcessor, IHTMLPartitionTypes.HTML_COMMENT);
// HTML JavaScript
- setContentAssistProcessor(contentAssistant, jsContentAssistProcessor, IHTMLPartitions.SCRIPT);
+ setContentAssistProcessor(contentAssistant, jsContentAssistProcessor, IHTMLPartitionTypes.SCRIPT);
// CSS
- setContentAssistProcessor(contentAssistant, cssContentAssistProcessor, ICSSPartitions.STYLE);
- setContentAssistProcessor(contentAssistant, cssContentAssistProcessor, ICSSPartitions.STYLE);
+ setContentAssistProcessor(contentAssistant, cssContentAssistProcessor, ICSSPartitionTypes.STYLE);
+ setContentAssistProcessor(contentAssistant, cssContentAssistProcessor, ICSSPartitionTypes.STYLE);
// JSP
- setContentAssistProcessor(contentAssistant, jspContentAssistProcessor, IStructuredPartitions.DEFAULT_PARTITION);
+ setContentAssistProcessor(contentAssistant, jspContentAssistProcessor, IStructuredPartitionTypes.DEFAULT_PARTITION);
setContentAssistProcessor(contentAssistant, jspContentAssistProcessor, IXMLPartitions.XML_DEFAULT);
- setContentAssistProcessor(contentAssistant, jspContentAssistProcessor, IHTMLPartitions.HTML_DEFAULT);
- setContentAssistProcessor(contentAssistant, jspContentAssistProcessor, IHTMLPartitions.HTML_COMMENT);
- setContentAssistProcessor(contentAssistant, jspContentAssistProcessor, IJSPPartitions.JSP_DEFAULT);
+ setContentAssistProcessor(contentAssistant, jspContentAssistProcessor, IHTMLPartitionTypes.HTML_DEFAULT);
+ setContentAssistProcessor(contentAssistant, jspContentAssistProcessor, IHTMLPartitionTypes.HTML_COMMENT);
+ setContentAssistProcessor(contentAssistant, jspContentAssistProcessor, IJSPPartitionTypes.JSP_DEFAULT);
// JSP directives
- setContentAssistProcessor(contentAssistant, jspContentAssistProcessor, IJSPPartitions.JSP_DIRECTIVE);
+ setContentAssistProcessor(contentAssistant, jspContentAssistProcessor, IJSPPartitionTypes.JSP_DIRECTIVE);
// JSP delimiters
- setContentAssistProcessor(contentAssistant, jspContentAssistProcessor, IJSPPartitions.JSP_CONTENT_DELIMITER);
+ setContentAssistProcessor(contentAssistant, jspContentAssistProcessor, IJSPPartitionTypes.JSP_CONTENT_DELIMITER);
// JSP JavaScript
- setContentAssistProcessor(contentAssistant, jspContentAssistProcessor, IJSPPartitions.JSP_CONTENT_JAVASCRIPT);
+ setContentAssistProcessor(contentAssistant, jspContentAssistProcessor, IJSPPartitionTypes.JSP_CONTENT_JAVASCRIPT);
// JSP Java
- setContentAssistProcessor(contentAssistant, jspJavaContentAssistProcessor, IJSPPartitions.JSP_CONTENT_JAVA);
+ setContentAssistProcessor(contentAssistant, jspJavaContentAssistProcessor, IJSPPartitionTypes.JSP_CONTENT_JAVA);
// unknown
- setContentAssistProcessor(contentAssistant, noRegionProcessorJsp, IStructuredPartitions.UNKNOWN_PARTITION);
+ setContentAssistProcessor(contentAssistant, noRegionProcessorJsp, IStructuredPartitionTypes.UNKNOWN_PARTITION);
// CMVC 269718
// JSP COMMENT
- setContentAssistProcessor(contentAssistant, jspContentAssistProcessor, IJSPPartitions.JSP_COMMENT);
+ setContentAssistProcessor(contentAssistant, jspContentAssistProcessor, IJSPPartitionTypes.JSP_COMMENT);
}
return ca;
@@ -209,10 +209,10 @@ public class StructuredTextViewerConfigurationJSP extends StructuredTextViewerCo
ITextEditor editor = getTextEditor();
if (editor != null) {
IContentAssistProcessor correctionProcessor = new CorrectionProcessorXML(editor);
- correctionAssistant.setContentAssistProcessor(correctionProcessor, IHTMLPartitions.HTML_DEFAULT);
+ correctionAssistant.setContentAssistProcessor(correctionProcessor, IHTMLPartitionTypes.HTML_DEFAULT);
correctionProcessor = new CorrectionProcessorJSP(editor);
- correctionAssistant.setContentAssistProcessor(correctionProcessor, IJSPPartitions.JSP_CONTENT_JAVA);
+ correctionAssistant.setContentAssistProcessor(correctionProcessor, IJSPPartitionTypes.JSP_CONTENT_JAVA);
}
}
@@ -223,20 +223,20 @@ public class StructuredTextViewerConfigurationJSP extends StructuredTextViewerCo
MultiPassContentFormatter formatter = new MultiPassContentFormatter(getConfiguredDocumentPartitioning(sourceViewer), IXMLPartitions.XML_DEFAULT);
formatter.setMasterStrategy(new StructuredFormattingStrategy(new HTMLFormatProcessorImpl()));
- formatter.setSlaveStrategy(new FormattingStrategyJSPJava(), IJSPPartitions.JSP_CONTENT_JAVA);
+ formatter.setSlaveStrategy(new FormattingStrategyJSPJava(), IJSPPartitionTypes.JSP_CONTENT_JAVA);
return formatter;
}
public ITextDoubleClickStrategy getDoubleClickStrategy(ISourceViewer sourceViewer, String contentType) {
- if (contentType.compareTo(IHTMLPartitions.HTML_DEFAULT) == 0)
+ if (contentType.compareTo(IHTMLPartitionTypes.HTML_DEFAULT) == 0)
// HTML
return new XMLDoubleClickStrategy();
- else if (contentType.compareTo(IHTMLPartitions.SCRIPT) == 0 || contentType.compareTo(IJSPPartitions.JSP_CONTENT_JAVA) == 0 || contentType.compareTo(IJSPPartitions.JSP_CONTENT_JAVASCRIPT) == 0)
+ else if (contentType.compareTo(IHTMLPartitionTypes.SCRIPT) == 0 || contentType.compareTo(IJSPPartitionTypes.JSP_CONTENT_JAVA) == 0 || contentType.compareTo(IJSPPartitionTypes.JSP_CONTENT_JAVASCRIPT) == 0)
// HTML JavaScript
// JSP Java or JSP JavaScript
return getJavaSourceViewerConfiguration().getDoubleClickStrategy(sourceViewer, contentType);
- else if (contentType.compareTo(IJSPPartitions.JSP_DEFAULT) == 0)
+ else if (contentType.compareTo(IJSPPartitionTypes.JSP_DEFAULT) == 0)
// JSP
return new XMLDoubleClickStrategy();
else
@@ -249,24 +249,24 @@ public class StructuredTextViewerConfigurationJSP extends StructuredTextViewerCo
if (highlighter != null) {
// HTML
LineStyleProvider htmlLineStyleProvider = new LineStyleProviderForHTML();
- highlighter.addProvider(IHTMLPartitions.HTML_DEFAULT, htmlLineStyleProvider);
- highlighter.addProvider(IHTMLPartitions.HTML_COMMENT, htmlLineStyleProvider);
- highlighter.addProvider(IHTMLPartitions.HTML_DECLARATION, htmlLineStyleProvider);
+ highlighter.addProvider(IHTMLPartitionTypes.HTML_DEFAULT, htmlLineStyleProvider);
+ highlighter.addProvider(IHTMLPartitionTypes.HTML_COMMENT, htmlLineStyleProvider);
+ highlighter.addProvider(IHTMLPartitionTypes.HTML_DECLARATION, htmlLineStyleProvider);
// HTML JavaScript
LineStyleProvider jsLineStyleProvider = new LineStyleProviderForJavaScript();
- highlighter.addProvider(IHTMLPartitions.SCRIPT, jsLineStyleProvider);
+ highlighter.addProvider(IHTMLPartitionTypes.SCRIPT, jsLineStyleProvider);
// CSS
LineStyleProvider cssLineStyleProvider = new LineStyleProviderForEmbeddedCSS();
- highlighter.addProvider(ICSSPartitions.STYLE, cssLineStyleProvider);
+ highlighter.addProvider(ICSSPartitionTypes.STYLE, cssLineStyleProvider);
// JSP
LineStyleProvider jspLineStyleProvider = new LineStyleProviderForJSP();
- highlighter.addProvider(IJSPPartitions.JSP_DEFAULT, jspLineStyleProvider);
- highlighter.addProvider(IJSPPartitions.JSP_COMMENT, jspLineStyleProvider);
- highlighter.addProvider(IJSPPartitions.JSP_DIRECTIVE, jspLineStyleProvider);
- highlighter.addProvider(IJSPPartitions.JSP_CONTENT_DELIMITER, jspLineStyleProvider);
+ highlighter.addProvider(IJSPPartitionTypes.JSP_DEFAULT, jspLineStyleProvider);
+ highlighter.addProvider(IJSPPartitionTypes.JSP_COMMENT, jspLineStyleProvider);
+ highlighter.addProvider(IJSPPartitionTypes.JSP_DIRECTIVE, jspLineStyleProvider);
+ highlighter.addProvider(IJSPPartitionTypes.JSP_CONTENT_DELIMITER, jspLineStyleProvider);
// XML
LineStyleProviderForXML xmlLineStyleProvider = new LineStyleProviderForXML();
@@ -278,8 +278,8 @@ public class StructuredTextViewerConfigurationJSP extends StructuredTextViewerCo
// JSP Java or JSP JavaScript
- highlighter.addProvider(IJSPPartitions.JSP_CONTENT_JAVA, new LineStyleProviderForJava());
- highlighter.addProvider(IJSPPartitions.JSP_CONTENT_JAVASCRIPT, new LineStyleProviderForJavaScript());
+ highlighter.addProvider(IJSPPartitionTypes.JSP_CONTENT_JAVA, new LineStyleProviderForJava());
+ highlighter.addProvider(IJSPPartitionTypes.JSP_CONTENT_JAVASCRIPT, new LineStyleProviderForJavaScript());
}
return highlighter;
@@ -291,11 +291,11 @@ public class StructuredTextViewerConfigurationJSP extends StructuredTextViewerCo
// HTML
IInformationProvider htmlInformationProvider = new HTMLInformationProvider();
- fInformationPresenter.setInformationProvider(htmlInformationProvider, IHTMLPartitions.HTML_DEFAULT);
+ fInformationPresenter.setInformationProvider(htmlInformationProvider, IHTMLPartitionTypes.HTML_DEFAULT);
// HTML JavaScript
IInformationProvider javascriptInformationProvider = new JavaScriptInformationProvider();
- fInformationPresenter.setInformationProvider(javascriptInformationProvider, IHTMLPartitions.SCRIPT);
+ fInformationPresenter.setInformationProvider(javascriptInformationProvider, IHTMLPartitionTypes.SCRIPT);
// XML
IInformationProvider xmlInformationProvider = new XMLInformationProvider();
@@ -308,7 +308,7 @@ public class StructuredTextViewerConfigurationJSP extends StructuredTextViewerCo
public ITextHover getTextHover(ISourceViewer sourceViewer, String contentType, int stateMask) {
// html
- if (contentType == IHTMLPartitions.HTML_DEFAULT) {
+ if (contentType == IHTMLPartitionTypes.HTML_DEFAULT) {
TextHoverManager.TextHoverDescriptor[] hoverDescs = getTextHovers();
int i = 0;
while (i < hoverDescs.length) {
@@ -325,7 +325,7 @@ public class StructuredTextViewerConfigurationJSP extends StructuredTextViewerCo
}
i++;
}
- } else if (contentType == IHTMLPartitions.SCRIPT) {
+ } else if (contentType == IHTMLPartitionTypes.SCRIPT) {
// HTML JavaScript
TextHoverManager.TextHoverDescriptor[] hoverDescs = getTextHovers();
int i = 0;
@@ -343,7 +343,7 @@ public class StructuredTextViewerConfigurationJSP extends StructuredTextViewerCo
}
i++;
}
- } else if ((contentType == IJSPPartitions.JSP_DEFAULT) || (contentType == IJSPPartitions.JSP_DIRECTIVE)) {
+ } else if ((contentType == IJSPPartitionTypes.JSP_DEFAULT) || (contentType == IJSPPartitionTypes.JSP_DIRECTIVE)) {
// JSP
TextHoverManager.TextHoverDescriptor[] hoverDescs = getTextHovers();
int i = 0;
@@ -361,7 +361,7 @@ public class StructuredTextViewerConfigurationJSP extends StructuredTextViewerCo
}
i++;
}
- } else if (contentType == IJSPPartitions.JSP_CONTENT_JAVA) {
+ } else if (contentType == IJSPPartitionTypes.JSP_CONTENT_JAVA) {
// JSP Java
TextHoverManager.TextHoverDescriptor[] hoverDescs = getTextHovers();
int i = 0;
@@ -452,13 +452,13 @@ public class StructuredTextViewerConfigurationJSP extends StructuredTextViewerCo
IReconcilingStrategy markupStrategy = new StructuredTextReconcilingStrategyForMarkup((ITextEditor) editorPart);
IReconcilingStrategy jspStrategy = new StructuredTextReconcilingStrategyForJSP((ITextEditor) editorPart);
- fReconciler.setReconcilingStrategy(markupStrategy, IStructuredPartitions.DEFAULT_PARTITION);
+ fReconciler.setReconcilingStrategy(markupStrategy, IStructuredPartitionTypes.DEFAULT_PARTITION);
fReconciler.setReconcilingStrategy(markupStrategy, IXMLPartitions.XML_DEFAULT);
- fReconciler.setReconcilingStrategy(jspStrategy, IJSPPartitions.JSP_DEFAULT);
- fReconciler.setReconcilingStrategy(jspStrategy, IJSPPartitions.JSP_CONTENT_JAVA);
- fReconciler.setReconcilingStrategy(jspStrategy, IJSPPartitions.JSP_CONTENT_DELIMITER);
- fReconciler.setReconcilingStrategy(jspStrategy, IJSPPartitions.JSP_DIRECTIVE);
+ fReconciler.setReconcilingStrategy(jspStrategy, IJSPPartitionTypes.JSP_DEFAULT);
+ fReconciler.setReconcilingStrategy(jspStrategy, IJSPPartitionTypes.JSP_CONTENT_JAVA);
+ fReconciler.setReconcilingStrategy(jspStrategy, IJSPPartitionTypes.JSP_CONTENT_DELIMITER);
+ fReconciler.setReconcilingStrategy(jspStrategy, IJSPPartitionTypes.JSP_DIRECTIVE);
fReconciler.setDefaultStrategy(markupStrategy);
diff --git a/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/breakpointproviders/JavaStratumBreakpointProvider.java b/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/breakpointproviders/JavaStratumBreakpointProvider.java
index bbe098de25..73974b2f28 100644
--- a/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/breakpointproviders/JavaStratumBreakpointProvider.java
+++ b/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/breakpointproviders/JavaStratumBreakpointProvider.java
@@ -27,7 +27,7 @@ import org.eclipse.jface.text.BadLocationException;
import org.eclipse.jface.text.IDocument;
import org.eclipse.jface.text.IRegion;
import org.eclipse.jface.text.ITypedRegion;
-import org.eclipse.jst.jsp.core.text.IJSPPartitions;
+import org.eclipse.jst.jsp.core.text.IJSPPartitionTypes;
import org.eclipse.jst.jsp.ui.internal.JSPUIPlugin;
import org.eclipse.ui.IEditorInput;
import org.eclipse.ui.IStorageEditorInput;
@@ -158,7 +158,7 @@ public class JavaStratumBreakpointProvider implements IBreakpointProvider, IExec
// custom
// tags,
// return that position
- if (type == IJSPPartitions.JSP_CONTENT_JAVA || type == IJSPPartitions.JSP_DIRECTIVE) {
+ if (type == IJSPPartitionTypes.JSP_CONTENT_JAVA || type == IJSPPartitionTypes.JSP_DIRECTIVE) {
result = partitions[i].getOffset();
}
}
diff --git a/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/contentassist/JSPContentAssistProcessor.java b/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/contentassist/JSPContentAssistProcessor.java
index b9bf9cc336..6ba5dd9d5b 100644
--- a/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/contentassist/JSPContentAssistProcessor.java
+++ b/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/contentassist/JSPContentAssistProcessor.java
@@ -36,7 +36,7 @@ import org.eclipse.jst.jsp.core.internal.contentmodel.TaglibController;
import org.eclipse.jst.jsp.core.internal.contentmodel.tld.TLDCMDocumentManager;
import org.eclipse.jst.jsp.core.internal.document.PageDirectiveAdapterFactory;
import org.eclipse.jst.jsp.core.model.parser.DOMJSPRegionContexts;
-import org.eclipse.jst.jsp.core.text.IJSPPartitions;
+import org.eclipse.jst.jsp.core.text.IJSPPartitionTypes;
import org.eclipse.jst.jsp.ui.internal.JSPUIPlugin;
import org.eclipse.jst.jsp.ui.internal.Logger;
import org.eclipse.jst.jsp.ui.internal.editor.JSPEditorPluginImageHelper;
@@ -48,7 +48,7 @@ import org.eclipse.wst.html.core.HTMLCMProperties;
import org.eclipse.wst.html.core.contentmodel.HTMLCMDocumentFactory;
import org.eclipse.wst.html.core.contentmodel.HTMLElementDeclaration;
import org.eclipse.wst.html.core.contentmodel.JSPCMDocument;
-import org.eclipse.wst.html.core.text.IHTMLPartitions;
+import org.eclipse.wst.html.core.text.IHTMLPartitionTypes;
import org.eclipse.wst.html.ui.internal.contentassist.HTMLContentAssistProcessor;
import org.eclipse.wst.javascript.common.ui.internal.contentassist.JavaScriptContentAssistProcessor;
import org.eclipse.wst.sse.core.IModelManager;
@@ -59,7 +59,8 @@ import org.eclipse.wst.sse.core.StructuredModelManager;
import org.eclipse.wst.sse.core.parser.BlockMarker;
import org.eclipse.wst.sse.core.text.IStructuredDocument;
import org.eclipse.wst.sse.core.text.IStructuredDocumentRegion;
-import org.eclipse.wst.sse.core.text.IStructuredPartitions;
+import org.eclipse.wst.sse.core.text.IStructuredPartitionTypes;
+import org.eclipse.wst.sse.core.text.IStructuredPartitioning;
import org.eclipse.wst.sse.core.text.ITextRegion;
import org.eclipse.wst.sse.core.text.ITextRegionContainer;
import org.eclipse.wst.sse.core.text.ITextRegionList;
@@ -146,14 +147,14 @@ public class JSPContentAssistProcessor extends AbstractContentAssistProcessor im
XMLContentAssistProcessor xmlProcessor = new XMLContentAssistProcessor();
JavaScriptContentAssistProcessor javascriptProcessor = new JavaScriptContentAssistProcessor();
- fPartitionToProcessorMap.put(IHTMLPartitions.HTML_DEFAULT, htmlProcessor);
+ fPartitionToProcessorMap.put(IHTMLPartitionTypes.HTML_DEFAULT, htmlProcessor);
fPartitionToProcessorMap.put(IXMLPartitions.XML_DEFAULT, xmlProcessor);
- fPartitionToProcessorMap.put(IStructuredPartitions.DEFAULT_PARTITION, htmlProcessor);
- fPartitionToProcessorMap.put(IJSPPartitions.JSP_DEFAULT, jspJavaProcessor);
- fPartitionToProcessorMap.put(IJSPPartitions.JSP_DIRECTIVE, xmlProcessor);
- fPartitionToProcessorMap.put(IHTMLPartitions.HTML_COMMENT, htmlProcessor);
- fPartitionToProcessorMap.put(IJSPPartitions.JSP_CONTENT_JAVASCRIPT, javascriptProcessor);
- fPartitionToProcessorMap.put(IHTMLPartitions.SCRIPT, javascriptProcessor); // default
+ fPartitionToProcessorMap.put(IStructuredPartitionTypes.DEFAULT_PARTITION, htmlProcessor);
+ fPartitionToProcessorMap.put(IJSPPartitionTypes.JSP_DEFAULT, jspJavaProcessor);
+ fPartitionToProcessorMap.put(IJSPPartitionTypes.JSP_DIRECTIVE, xmlProcessor);
+ fPartitionToProcessorMap.put(IHTMLPartitionTypes.HTML_COMMENT, htmlProcessor);
+ fPartitionToProcessorMap.put(IJSPPartitionTypes.JSP_CONTENT_JAVASCRIPT, javascriptProcessor);
+ fPartitionToProcessorMap.put(IHTMLPartitionTypes.SCRIPT, javascriptProcessor); // default
// to
// javascript
// for
@@ -611,7 +612,7 @@ public class JSPContentAssistProcessor extends AbstractContentAssistProcessor im
// ANOTHER WORKAROUND UNTIL PARTITIONING TAKES CARE OF THIS
// check for xml-jsp tags...
// CMVC 243657
- if (partitionType == IJSPPartitions.JSP_DIRECTIVE && fn != null) {
+ if (partitionType == IJSPPartitionTypes.JSP_DIRECTIVE && fn != null) {
IStructuredDocumentRegion possibleXMLJSP = ((fn.getType() == XMLRegionContext.XML_CONTENT) && fn.getPrevious() != null) ? fn.getPrevious() : fn;
ITextRegionList regions = possibleXMLJSP.getRegions();
if (regions.size() > 1) {
@@ -636,7 +637,7 @@ public class JSPContentAssistProcessor extends AbstractContentAssistProcessor im
// ** THIS IS A TEMP FIX UNTIL PARTITIONING TAKES CARE OF THIS...
// CMVC 241882
// check for XML-JSP in a <script> region
- if (partitionType == IJSPPartitions.JSP_CONTENT_JAVASCRIPT || partitionType == IHTMLPartitions.SCRIPT) {
+ if (partitionType == IJSPPartitionTypes.JSP_CONTENT_JAVASCRIPT || partitionType == IHTMLPartitionTypes.SCRIPT) {
// fn should be block text
IStructuredDocumentRegion decodedSDRegion = decodeScriptBlock(fn.getFullText());
// System.out.println("decoded > " +
@@ -671,7 +672,7 @@ public class JSPContentAssistProcessor extends AbstractContentAssistProcessor im
// /////////////////////////////////////////////////////////////////////////
// check special JSP delimiter cases
- if (fn != null && partitionType == IJSPPartitions.JSP_CONTENT_DELIMITER) {
+ if (fn != null && partitionType == IJSPPartitionTypes.JSP_CONTENT_DELIMITER) {
IStructuredDocumentRegion fnDelim = fn;
// if it's a nested JSP region, need to get the correct
@@ -728,7 +729,7 @@ public class JSPContentAssistProcessor extends AbstractContentAssistProcessor im
// adapter get the proposals
if (documentPosition > 0) {
String checkType = getPartitionType((StructuredTextViewer) viewer, documentPosition - 1);
- if (checkType != IJSPPartitions.JSP_CONTENT_JAVASCRIPT) { // this
+ if (checkType != IJSPPartitionTypes.JSP_CONTENT_JAVASCRIPT) { // this
// check
// is
// failing
@@ -740,7 +741,7 @@ public class JSPContentAssistProcessor extends AbstractContentAssistProcessor im
// javascript...)
return getJSPJavaCompletionProposals(viewer, documentPosition);
} else {
- partitionType = IJSPPartitions.JSP_CONTENT_JAVASCRIPT;
+ partitionType = IJSPPartitionTypes.JSP_CONTENT_JAVASCRIPT;
}
}
} else if ((firstRegion.getType() == XMLRegionContext.XML_TAG_OPEN) && documentPosition >= fnDelim.getEndOffset()) {
@@ -757,10 +758,10 @@ public class JSPContentAssistProcessor extends AbstractContentAssistProcessor im
// JAVASCRIPT adapter get the proposals
if (documentPosition > 0) {
String checkType = getPartitionType((StructuredTextViewer) viewer, documentPosition - 1);
- if (checkType != IJSPPartitions.JSP_CONTENT_JAVASCRIPT) {
+ if (checkType != IJSPPartitionTypes.JSP_CONTENT_JAVASCRIPT) {
return getJSPJavaCompletionProposals(viewer, documentPosition);
} else {
- partitionType = IJSPPartitions.JSP_CONTENT_JAVASCRIPT;
+ partitionType = IJSPPartitionTypes.JSP_CONTENT_JAVASCRIPT;
}
}
}
@@ -837,7 +838,7 @@ public class JSPContentAssistProcessor extends AbstractContentAssistProcessor im
if (p != null) {
embeddedResults = p.computeCompletionProposals(viewer, documentPosition);
// get bean methods, objects, and constants if there are any...
- if (partitionType == IJSPPartitions.JSP_CONTENT_JAVASCRIPT || partitionType == IHTMLPartitions.SCRIPT) {
+ if (partitionType == IJSPPartitionTypes.JSP_CONTENT_JAVASCRIPT || partitionType == IHTMLPartitionTypes.SCRIPT) {
ICompletionProposal[] beanResults = getJSPJavaBeanProposals(viewer, documentPosition);
if (beanResults != null && beanResults.length > 0) {
ICompletionProposal[] added = new ICompletionProposal[beanResults.length + embeddedResults.length];
@@ -877,7 +878,7 @@ public class JSPContentAssistProcessor extends AbstractContentAssistProcessor im
// CMVC 269718
// check for |<%-- --%> first position of jsp comment
- if (partitionType == IJSPPartitions.JSP_COMMENT) {
+ if (partitionType == IJSPPartitionTypes.JSP_COMMENT) {
if (sdRegion.getStartOffset() == documentPosition) {
ICompletionProposal[] htmlResults = getHTMLCompletionProposals(viewer, documentPosition);
jspResults = merge(jspResults, htmlResults);
@@ -959,7 +960,7 @@ public class JSPContentAssistProcessor extends AbstractContentAssistProcessor im
*/
private ICompletionProposal[] getHTMLCompletionProposals(ITextViewer viewer, int documentPosition) {
- IContentAssistProcessor p = (IContentAssistProcessor) fPartitionToProcessorMap.get(IHTMLPartitions.HTML_DEFAULT);
+ IContentAssistProcessor p = (IContentAssistProcessor) fPartitionToProcessorMap.get(IHTMLPartitionTypes.HTML_DEFAULT);
return p.computeCompletionProposals(viewer, documentPosition);
}
@@ -970,7 +971,7 @@ public class JSPContentAssistProcessor extends AbstractContentAssistProcessor im
* @return ICompletionProposal[]
*/
protected ICompletionProposal[] getJSPJavaCompletionProposals(ITextViewer viewer, int documentPosition) {
- JSPJavaContentAssistProcessor p = (JSPJavaContentAssistProcessor) fPartitionToProcessorMap.get(IJSPPartitions.JSP_DEFAULT);
+ JSPJavaContentAssistProcessor p = (JSPJavaContentAssistProcessor) fPartitionToProcessorMap.get(IJSPPartitionTypes.JSP_DEFAULT);
p.initialize(fResource);
return p.computeCompletionProposals(viewer, documentPosition);
}
@@ -983,7 +984,7 @@ public class JSPContentAssistProcessor extends AbstractContentAssistProcessor im
protected String getPartitionType(StructuredTextViewer viewer, int documentPosition) {
String partitionType = null;
try {
- partitionType = TextUtilities.getContentType(viewer.getDocument(), IStructuredDocument.DEFAULT_STRUCTURED_PARTITIONING, viewer.modelOffset2WidgetOffset(documentPosition), false);
+ partitionType = TextUtilities.getContentType(viewer.getDocument(), IStructuredPartitioning.DEFAULT_STRUCTURED_PARTITIONING, viewer.modelOffset2WidgetOffset(documentPosition), false);
} catch (BadLocationException e) {
partitionType = IDocument.DEFAULT_CONTENT_TYPE;
}
diff --git a/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/contentassist/JSPJavaContentAssistProcessor.java b/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/contentassist/JSPJavaContentAssistProcessor.java
index 1313ef70f0..bfe026d8b4 100644
--- a/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/contentassist/JSPJavaContentAssistProcessor.java
+++ b/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/contentassist/JSPJavaContentAssistProcessor.java
@@ -21,7 +21,7 @@ import org.eclipse.jface.text.contentassist.IContentAssistProcessor;
import org.eclipse.jface.text.contentassist.IContextInformation;
import org.eclipse.jface.text.contentassist.IContextInformationValidator;
import org.eclipse.jst.jsp.core.model.parser.DOMJSPRegionContexts;
-import org.eclipse.jst.jsp.core.text.IJSPPartitions;
+import org.eclipse.jst.jsp.core.text.IJSPPartitionTypes;
import org.eclipse.wst.sse.core.IndexedRegion;
import org.eclipse.wst.sse.core.text.IStructuredDocumentRegion;
import org.eclipse.wst.sse.core.text.ITextRegion;
@@ -306,7 +306,7 @@ public class JSPJavaContentAssistProcessor implements IContentAssistProcessor, I
// need to compute context info here, if it's JSP, call java computer
IDocumentPartitioner dp = viewer.getDocument().getDocumentPartitioner();
String type = dp.getPartition(documentOffset).getType();
- if (type == IJSPPartitions.JSP_DEFAULT || type == IJSPPartitions.JSP_CONTENT_JAVA) {
+ if (type == IJSPPartitionTypes.JSP_DEFAULT || type == IJSPPartitionTypes.JSP_CONTENT_JAVA) {
// get context info from completion results...
ICompletionProposal[] proposals = computeCompletionProposals(viewer, documentOffset);
for (int i = 0; i < proposals.length; i++) {
diff --git a/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/contentassist/NoRegionContentAssistProcessorForJSP.java b/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/contentassist/NoRegionContentAssistProcessorForJSP.java
index f2ad51f683..27ba42251e 100644
--- a/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/contentassist/NoRegionContentAssistProcessorForJSP.java
+++ b/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/contentassist/NoRegionContentAssistProcessorForJSP.java
@@ -14,12 +14,12 @@ import org.eclipse.jface.text.ITextViewer;
import org.eclipse.jface.text.contentassist.IContentAssistProcessor;
import org.eclipse.jst.jsp.core.JSP11Namespace;
import org.eclipse.jst.jsp.core.model.parser.DOMJSPRegionContexts;
-import org.eclipse.jst.jsp.core.text.IJSPPartitions;
-import org.eclipse.wst.html.core.text.IHTMLPartitions;
+import org.eclipse.jst.jsp.core.text.IJSPPartitionTypes;
+import org.eclipse.wst.html.core.text.IHTMLPartitionTypes;
import org.eclipse.wst.html.ui.internal.contentassist.NoRegionContentAssistProcessorForHTML;
import org.eclipse.wst.sse.core.text.IStructuredDocument;
import org.eclipse.wst.sse.core.text.IStructuredDocumentRegion;
-import org.eclipse.wst.sse.core.text.IStructuredPartitions;
+import org.eclipse.wst.sse.core.text.IStructuredPartitionTypes;
import org.eclipse.wst.xml.core.text.IXMLPartitions;
/**
@@ -42,21 +42,21 @@ public class NoRegionContentAssistProcessorForJSP extends NoRegionContentAssistP
super.initPartitionToProcessorMap();
IContentAssistProcessor jspContentAssistProcessor = new JSPContentAssistProcessor();
// JSP
- fPartitionToProcessorMap.put(IStructuredPartitions.DEFAULT_PARTITION, jspContentAssistProcessor);
+ fPartitionToProcessorMap.put(IStructuredPartitionTypes.DEFAULT_PARTITION, jspContentAssistProcessor);
fPartitionToProcessorMap.put(IXMLPartitions.XML_DEFAULT, jspContentAssistProcessor);
- fPartitionToProcessorMap.put(IHTMLPartitions.HTML_DEFAULT, jspContentAssistProcessor);
- fPartitionToProcessorMap.put(IHTMLPartitions.HTML_COMMENT, jspContentAssistProcessor);
- fPartitionToProcessorMap.put(IJSPPartitions.JSP_DEFAULT, jspContentAssistProcessor);
+ fPartitionToProcessorMap.put(IHTMLPartitionTypes.HTML_DEFAULT, jspContentAssistProcessor);
+ fPartitionToProcessorMap.put(IHTMLPartitionTypes.HTML_COMMENT, jspContentAssistProcessor);
+ fPartitionToProcessorMap.put(IJSPPartitionTypes.JSP_DEFAULT, jspContentAssistProcessor);
// JSP directives
- fPartitionToProcessorMap.put(IJSPPartitions.JSP_DIRECTIVE, jspContentAssistProcessor);
+ fPartitionToProcessorMap.put(IJSPPartitionTypes.JSP_DIRECTIVE, jspContentAssistProcessor);
// JSP delimiters
- fPartitionToProcessorMap.put(IJSPPartitions.JSP_CONTENT_DELIMITER, jspContentAssistProcessor);
+ fPartitionToProcessorMap.put(IJSPPartitionTypes.JSP_CONTENT_DELIMITER, jspContentAssistProcessor);
// JSP JavaScript
- fPartitionToProcessorMap.put(IJSPPartitions.JSP_CONTENT_JAVASCRIPT, jspContentAssistProcessor);
+ fPartitionToProcessorMap.put(IJSPPartitionTypes.JSP_CONTENT_JAVASCRIPT, jspContentAssistProcessor);
IContentAssistProcessor jspJavaContentAssistProcessor = new JSPJavaContentAssistProcessor();
// JSP Java
- fPartitionToProcessorMap.put(IJSPPartitions.JSP_CONTENT_JAVA, jspJavaContentAssistProcessor);
+ fPartitionToProcessorMap.put(IJSPPartitionTypes.JSP_CONTENT_JAVA, jspJavaContentAssistProcessor);
}
/*
@@ -96,7 +96,7 @@ public class NoRegionContentAssistProcessorForJSP extends NoRegionContentAssistP
if (p == null) {
IStructuredDocumentRegion sdRegion = ((IStructuredDocument) viewer.getDocument()).getRegionAtCharacterOffset(documentOffset);
if (isJSPRegion(sdRegion))
- p = (IContentAssistProcessor) fPartitionToProcessorMap.get(IJSPPartitions.JSP_CONTENT_JAVA);
+ p = (IContentAssistProcessor) fPartitionToProcessorMap.get(IJSPPartitionTypes.JSP_CONTENT_JAVA);
}
return p;
}
diff --git a/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/hyperlink/TaglibHyperlinkDetector.java b/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/hyperlink/TaglibHyperlinkDetector.java
index 9a814d3f4a..d0df36aa7f 100644
--- a/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/hyperlink/TaglibHyperlinkDetector.java
+++ b/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/hyperlink/TaglibHyperlinkDetector.java
@@ -19,12 +19,12 @@ import org.eclipse.jst.jsp.core.JSP11Namespace;
import org.eclipse.jst.jsp.core.internal.contentmodel.ITaglibRecord;
import org.eclipse.jst.jsp.core.internal.contentmodel.TLDRecord;
import org.eclipse.jst.jsp.core.internal.contentmodel.TaglibIndex;
-import org.eclipse.jst.jsp.core.text.IJSPPartitions;
+import org.eclipse.jst.jsp.core.text.IJSPPartitionTypes;
import org.eclipse.jst.jsp.ui.internal.Logger;
import org.eclipse.wst.sse.core.IStructuredModel;
import org.eclipse.wst.sse.core.IndexedRegion;
import org.eclipse.wst.sse.core.StructuredModelManager;
-import org.eclipse.wst.sse.core.text.IStructuredDocument;
+import org.eclipse.wst.sse.core.text.IStructuredPartitioning;
import org.eclipse.wst.sse.core.util.StringUtils;
import org.eclipse.wst.xml.core.document.XMLAttr;
import org.eclipse.wst.xml.core.document.XMLNode;
@@ -46,8 +46,8 @@ public class TaglibHyperlinkDetector implements IHyperlinkDetector {
if (doc != null) {
try {
// check if jsp tag/directive first
- ITypedRegion partition = TextUtilities.getPartition(doc, IStructuredDocument.DEFAULT_STRUCTURED_PARTITIONING, region.getOffset(), false);
- if (partition != null && partition.getType() == IJSPPartitions.JSP_DIRECTIVE) {
+ ITypedRegion partition = TextUtilities.getPartition(doc, IStructuredPartitioning.DEFAULT_STRUCTURED_PARTITIONING, region.getOffset(), false);
+ if (partition != null && partition.getType() == IJSPPartitionTypes.JSP_DIRECTIVE) {
// check if jsp taglib directive
Node currentNode = getCurrentNode(doc, region.getOffset());
if (currentNode != null && currentNode.getNodeType() == Node.ELEMENT_NODE && JSP11Namespace.ElementName.DIRECTIVE_TAGLIB.equalsIgnoreCase(currentNode.getNodeName())) {
diff --git a/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/java/search/JSPFindOccurrencesAction.java b/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/java/search/JSPFindOccurrencesAction.java
index fc643b3203..22cf2586f5 100644
--- a/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/java/search/JSPFindOccurrencesAction.java
+++ b/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/java/search/JSPFindOccurrencesAction.java
@@ -19,7 +19,7 @@ import org.eclipse.jst.jsp.core.internal.java.IJSPTranslation;
import org.eclipse.jst.jsp.core.internal.java.JSPTranslation;
import org.eclipse.jst.jsp.core.internal.java.JSPTranslationAdapter;
import org.eclipse.jst.jsp.core.model.parser.DOMJSPRegionContexts;
-import org.eclipse.jst.jsp.core.text.IJSPPartitions;
+import org.eclipse.jst.jsp.core.text.IJSPPartitionTypes;
import org.eclipse.search.ui.ISearchQuery;
import org.eclipse.swt.graphics.Point;
import org.eclipse.ui.texteditor.ITextEditor;
@@ -96,7 +96,7 @@ public class JSPFindOccurrencesAction extends BasicFindOccurrencesAction impleme
* @see com.ibm.sse.editor.internal.search.BasicFindOccurrencesAction#getPartitionTypes()
*/
public String[] getPartitionTypes() {
- return new String[]{IJSPPartitions.JSP_DEFAULT, IJSPPartitions.JSP_CONTENT_JAVA};
+ return new String[]{IJSPPartitionTypes.JSP_DEFAULT, IJSPPartitionTypes.JSP_CONTENT_JAVA};
}
/**
diff --git a/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/reconcile/ReconcileStepForJava.java b/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/reconcile/ReconcileStepForJava.java
index 3e5a868003..49cfb1a64c 100644
--- a/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/reconcile/ReconcileStepForJava.java
+++ b/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/reconcile/ReconcileStepForJava.java
@@ -24,7 +24,7 @@ import org.eclipse.jface.text.reconciler.IReconcileResult;
import org.eclipse.jface.text.reconciler.IReconcileStep;
import org.eclipse.jst.jsp.core.internal.java.JSPTranslation;
import org.eclipse.jst.jsp.core.internal.java.JSPTranslationExtension;
-import org.eclipse.jst.jsp.core.text.IJSPPartitions;
+import org.eclipse.jst.jsp.core.text.IJSPPartitionTypes;
import org.eclipse.wst.sse.core.IStructuredModel;
import org.eclipse.wst.sse.core.StructuredModelManager;
import org.eclipse.wst.sse.core.text.IStructuredDocument;
@@ -162,7 +162,7 @@ public class ReconcileStepForJava extends StructuredReconcileStep {
key = createKey(fStructuredDocument.getRegionAtCharacterOffset(jspOffset), ReconcileAnnotationKey.TOTAL);
}
else {
- key = createKey(IJSPPartitions.JSP_DEFAULT, ReconcileAnnotationKey.TOTAL);
+ key = createKey(IJSPPartitionTypes.JSP_DEFAULT, ReconcileAnnotationKey.TOTAL);
}
TemporaryAnnotation annotation = new TemporaryAnnotation(pos, type, problem.getMessage(), key, problem.getID());
annotation.setAdditionalFixInfo(problem);
diff --git a/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/registry/AdapterFactoryProviderForJSP.java b/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/registry/AdapterFactoryProviderForJSP.java
index 39104b687f..ab8f226b8a 100644
--- a/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/registry/AdapterFactoryProviderForJSP.java
+++ b/bundles/org.eclipse.jst.jsp.ui/src/org/eclipse/jst/jsp/ui/internal/registry/AdapterFactoryProviderForJSP.java
@@ -19,8 +19,8 @@ import org.eclipse.jst.jsp.core.modelhandler.ModelHandlerForJSP;
import org.eclipse.jst.jsp.ui.internal.JSPUIPlugin;
import org.eclipse.ui.views.properties.IPropertySource;
import org.eclipse.wst.html.ui.internal.contentoutline.JFaceNodeAdapterFactoryForHTML;
-import org.eclipse.wst.sse.core.IAdapterFactory;
import org.eclipse.wst.sse.core.FactoryRegistry;
+import org.eclipse.wst.sse.core.IAdapterFactory;
import org.eclipse.wst.sse.core.IStructuredModel;
import org.eclipse.wst.sse.core.internal.PropagatingAdapter;
import org.eclipse.wst.sse.core.modelhandler.IDocumentTypeHandler;
diff --git a/bundles/org.eclipse.wst.css.core/src/org/eclipse/wst/css/core/format/FormatProcessorCSS.java b/bundles/org.eclipse.wst.css.core/src/org/eclipse/wst/css/core/format/FormatProcessorCSS.java
index 8ce323113b..3236af6480 100644
--- a/bundles/org.eclipse.wst.css.core/src/org/eclipse/wst/css/core/format/FormatProcessorCSS.java
+++ b/bundles/org.eclipse.wst.css.core/src/org/eclipse/wst/css/core/format/FormatProcessorCSS.java
@@ -21,9 +21,9 @@ import org.eclipse.wst.css.core.internal.formatter.CSSSourceFormatterFactory;
import org.eclipse.wst.sse.core.INodeNotifier;
import org.eclipse.wst.sse.core.IStructuredModel;
import org.eclipse.wst.sse.core.IndexedRegion;
-import org.eclipse.wst.sse.core.format.AbstractStructuredFormatProcessor;
-import org.eclipse.wst.sse.core.format.IStructuredFormatPreferences;
-import org.eclipse.wst.sse.core.format.IStructuredFormatter;
+import org.eclipse.wst.sse.core.internal.format.AbstractStructuredFormatProcessor;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatPreferences;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatter;
import org.eclipse.wst.xml.core.document.XMLModel;
import org.w3c.dom.Node;
diff --git a/bundles/org.eclipse.wst.css.core/src/org/eclipse/wst/css/core/internal/cleanup/CleanupProcessorCSS.java b/bundles/org.eclipse.wst.css.core/src/org/eclipse/wst/css/core/internal/cleanup/CleanupProcessorCSS.java
index 424d84b8d6..842f06dead 100644
--- a/bundles/org.eclipse.wst.css.core/src/org/eclipse/wst/css/core/internal/cleanup/CleanupProcessorCSS.java
+++ b/bundles/org.eclipse.wst.css.core/src/org/eclipse/wst/css/core/internal/cleanup/CleanupProcessorCSS.java
@@ -25,9 +25,9 @@ import org.eclipse.wst.css.core.internal.formatter.CSSSourceFormatterFactory;
import org.eclipse.wst.sse.core.INodeNotifier;
import org.eclipse.wst.sse.core.IStructuredModel;
import org.eclipse.wst.sse.core.IndexedRegion;
-import org.eclipse.wst.sse.core.format.IStructuredFormatProcessor;
import org.eclipse.wst.sse.core.internal.cleanup.AbstractStructuredCleanupProcessor;
import org.eclipse.wst.sse.core.internal.cleanup.IStructuredCleanupHandler;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatProcessor;
import org.eclipse.wst.xml.core.document.XMLModel;
import org.w3c.dom.Node;
diff --git a/bundles/org.eclipse.wst.css.core/src/org/eclipse/wst/css/core/internal/text/StructuredTextPartitionerForCSS.java b/bundles/org.eclipse.wst.css.core/src/org/eclipse/wst/css/core/internal/text/StructuredTextPartitionerForCSS.java
index 7b6321feea..80923b6a95 100644
--- a/bundles/org.eclipse.wst.css.core/src/org/eclipse/wst/css/core/internal/text/StructuredTextPartitionerForCSS.java
+++ b/bundles/org.eclipse.wst.css.core/src/org/eclipse/wst/css/core/internal/text/StructuredTextPartitionerForCSS.java
@@ -11,20 +11,20 @@
package org.eclipse.wst.css.core.internal.text;
import org.eclipse.jface.text.IDocumentPartitioner;
-import org.eclipse.wst.css.core.text.ICSSPartitions;
+import org.eclipse.wst.css.core.text.ICSSPartitionTypes;
import org.eclipse.wst.sse.core.internal.text.rules.StructuredTextPartitioner;
-import org.eclipse.wst.sse.core.text.IStructuredPartitions;
+import org.eclipse.wst.sse.core.text.IStructuredPartitionTypes;
public class StructuredTextPartitionerForCSS extends StructuredTextPartitioner {
- public final static String[] legalTypes = new String[]{ICSSPartitions.STYLE, IStructuredPartitions.DEFAULT_PARTITION};
+ public final static String[] legalTypes = new String[]{ICSSPartitionTypes.STYLE, IStructuredPartitionTypes.DEFAULT_PARTITION};
public StructuredTextPartitionerForCSS() {
super();
}
- public String getDefault() {
- return ICSSPartitions.STYLE;
+ public String getDefaultPartitionType() {
+ return ICSSPartitionTypes.STYLE;
}
public String[] getLegalContentTypes() {
diff --git a/bundles/org.eclipse.wst.css.core/src/org/eclipse/wst/css/core/text/ICSSPartitions.java b/bundles/org.eclipse.wst.css.core/src/org/eclipse/wst/css/core/text/ICSSPartitionTypes.java
index 2a8d8e9e98..323ab609ed 100644
--- a/bundles/org.eclipse.wst.css.core/src/org/eclipse/wst/css/core/text/ICSSPartitions.java
+++ b/bundles/org.eclipse.wst.css.core/src/org/eclipse/wst/css/core/text/ICSSPartitionTypes.java
@@ -1,6 +1,6 @@
package org.eclipse.wst.css.core.text;
-import org.eclipse.wst.sse.core.text.IStructuredPartitions;
+import org.eclipse.wst.sse.core.text.IStructuredPartitionTypes;
/**
* This interface is not intended to be implemented.
@@ -9,9 +9,7 @@ import org.eclipse.wst.sse.core.text.IStructuredPartitions;
*
* @since 1.0
*/
-public interface ICSSPartitions extends IStructuredPartitions {
+public interface ICSSPartitionTypes extends IStructuredPartitionTypes {
- String CSS_PARTITIONING = IStructuredPartitions.STRUCTURED_PARTITIONING;
-
String STYLE = "org.eclipse.wst.css.STYLE"; //$NON-NLS-1$
}
diff --git a/bundles/org.eclipse.wst.css.ui/src/org/eclipse/wst/css/ui/StructuredTextViewerConfigurationCSS.java b/bundles/org.eclipse.wst.css.ui/src/org/eclipse/wst/css/ui/StructuredTextViewerConfigurationCSS.java
index 992ae9fb8d..867fbd2d31 100644
--- a/bundles/org.eclipse.wst.css.ui/src/org/eclipse/wst/css/ui/StructuredTextViewerConfigurationCSS.java
+++ b/bundles/org.eclipse.wst.css.ui/src/org/eclipse/wst/css/ui/StructuredTextViewerConfigurationCSS.java
@@ -20,12 +20,12 @@ import org.eclipse.jface.text.formatter.IContentFormatter;
import org.eclipse.jface.text.formatter.MultiPassContentFormatter;
import org.eclipse.jface.text.source.ISourceViewer;
import org.eclipse.wst.css.core.format.FormatProcessorCSS;
-import org.eclipse.wst.css.core.text.ICSSPartitions;
+import org.eclipse.wst.css.core.text.ICSSPartitionTypes;
import org.eclipse.wst.css.ui.autoedit.StructuredAutoEditStrategyCSS;
import org.eclipse.wst.css.ui.contentassist.CSSContentAssistProcessor;
import org.eclipse.wst.css.ui.style.LineStyleProviderForCSS;
import org.eclipse.wst.css.ui.taginfo.CSSBestMatchHoverProcessor;
-import org.eclipse.wst.sse.core.text.IStructuredPartitions;
+import org.eclipse.wst.sse.core.text.IStructuredPartitionTypes;
import org.eclipse.wst.sse.ui.StructuredTextViewerConfiguration;
import org.eclipse.wst.sse.ui.format.StructuredFormattingStrategy;
import org.eclipse.wst.sse.ui.style.IHighlighter;
@@ -47,7 +47,7 @@ public class StructuredTextViewerConfigurationCSS extends StructuredTextViewerCo
allStrategies.add(superStrategies[i]);
}
- if (contentType == ICSSPartitions.STYLE) {
+ if (contentType == ICSSPartitionTypes.STYLE) {
allStrategies.add(new StructuredAutoEditStrategyCSS());
}
@@ -56,7 +56,7 @@ public class StructuredTextViewerConfigurationCSS extends StructuredTextViewerCo
public String[] getConfiguredContentTypes(ISourceViewer sourceViewer) {
if (configuredContentTypes == null) {
- configuredContentTypes = new String[]{ICSSPartitions.STYLE, IStructuredPartitions.DEFAULT_PARTITION, IStructuredPartitions.UNKNOWN_PARTITION};
+ configuredContentTypes = new String[]{ICSSPartitionTypes.STYLE, IStructuredPartitionTypes.DEFAULT_PARTITION, IStructuredPartitionTypes.UNKNOWN_PARTITION};
}
return configuredContentTypes;
}
@@ -70,15 +70,15 @@ public class StructuredTextViewerConfigurationCSS extends StructuredTextViewerCo
// CSSContentAssistProcessor(),
// ICSSPartitions.STYLE);
IContentAssistProcessor cssProcessor = new CSSContentAssistProcessor();
- setContentAssistProcessor((ContentAssistant) contentAssistant, cssProcessor, ICSSPartitions.STYLE);
- setContentAssistProcessor((ContentAssistant) contentAssistant, cssProcessor, IStructuredPartitions.UNKNOWN_PARTITION);
+ setContentAssistProcessor((ContentAssistant) contentAssistant, cssProcessor, ICSSPartitionTypes.STYLE);
+ setContentAssistProcessor((ContentAssistant) contentAssistant, cssProcessor, IStructuredPartitionTypes.UNKNOWN_PARTITION);
}
return contentAssistant;
}
public IContentFormatter getContentFormatter(ISourceViewer sourceViewer) {
- final MultiPassContentFormatter formatter = new MultiPassContentFormatter(getConfiguredDocumentPartitioning(sourceViewer), ICSSPartitions.STYLE);
+ final MultiPassContentFormatter formatter = new MultiPassContentFormatter(getConfiguredDocumentPartitioning(sourceViewer), ICSSPartitionTypes.STYLE);
formatter.setMasterStrategy(new StructuredFormattingStrategy(new FormatProcessorCSS()));
@@ -89,7 +89,7 @@ public class StructuredTextViewerConfigurationCSS extends StructuredTextViewerCo
IHighlighter highlighter = super.getHighlighter(sourceViewer);
if (highlighter != null) {
- highlighter.addProvider(ICSSPartitions.STYLE, new LineStyleProviderForCSS());
+ highlighter.addProvider(ICSSPartitionTypes.STYLE, new LineStyleProviderForCSS());
}
return highlighter;
diff --git a/bundles/org.eclipse.wst.css.ui/src/org/eclipse/wst/css/ui/registry/AdapterFactoryProviderCSS.java b/bundles/org.eclipse.wst.css.ui/src/org/eclipse/wst/css/ui/registry/AdapterFactoryProviderCSS.java
index 242795c9d8..c77d8cff90 100644
--- a/bundles/org.eclipse.wst.css.ui/src/org/eclipse/wst/css/ui/registry/AdapterFactoryProviderCSS.java
+++ b/bundles/org.eclipse.wst.css.ui/src/org/eclipse/wst/css/ui/registry/AdapterFactoryProviderCSS.java
@@ -12,8 +12,8 @@ import org.eclipse.ui.views.properties.IPropertySource;
import org.eclipse.wst.css.core.modelhandler.ModelHandlerForCSS;
import org.eclipse.wst.css.ui.internal.contentoutline.JFaceNodeAdapterFactoryCSS;
import org.eclipse.wst.css.ui.internal.properties.CSSPropertySourceAdapterFactory;
-import org.eclipse.wst.sse.core.IAdapterFactory;
import org.eclipse.wst.sse.core.FactoryRegistry;
+import org.eclipse.wst.sse.core.IAdapterFactory;
import org.eclipse.wst.sse.core.IStructuredModel;
import org.eclipse.wst.sse.core.modelhandler.IDocumentTypeHandler;
import org.eclipse.wst.sse.ui.internal.contentoutline.IJFaceNodeAdapter;
diff --git a/bundles/org.eclipse.wst.dtd.core/src/org/eclipse/wst/dtd/core/internal/text/StructuredTextPartitionerForDTD.java b/bundles/org.eclipse.wst.dtd.core/src/org/eclipse/wst/dtd/core/internal/text/StructuredTextPartitionerForDTD.java
index 99f5d9c857..5031c24a32 100644
--- a/bundles/org.eclipse.wst.dtd.core/src/org/eclipse/wst/dtd/core/internal/text/StructuredTextPartitionerForDTD.java
+++ b/bundles/org.eclipse.wst.dtd.core/src/org/eclipse/wst/dtd/core/internal/text/StructuredTextPartitionerForDTD.java
@@ -12,9 +12,9 @@
*******************************************************************************/
package org.eclipse.wst.dtd.core.internal.text;
-import org.eclipse.wst.dtd.core.text.IDTDPartitions;
+import org.eclipse.wst.dtd.core.text.IDTDPartitionTypes;
import org.eclipse.wst.sse.core.internal.text.rules.StructuredTextPartitioner;
-import org.eclipse.wst.sse.core.text.IStructuredPartitions;
+import org.eclipse.wst.sse.core.text.IStructuredPartitionTypes;
public class StructuredTextPartitionerForDTD extends StructuredTextPartitioner {
@@ -27,8 +27,8 @@ public class StructuredTextPartitionerForDTD extends StructuredTextPartitioner {
*
* @see org.eclipse.wst.sse.core.text.rules.StructuredTextPartitioner#getDefault()
*/
- public String getDefault() {
- return IDTDPartitions.DTD_DEFAULT;
+ public String getDefaultPartitionType() {
+ return IDTDPartitionTypes.DTD_DEFAULT;
}
/*
@@ -37,6 +37,6 @@ public class StructuredTextPartitionerForDTD extends StructuredTextPartitioner {
* @see org.eclipse.wst.sse.core.text.rules.StructuredTextPartitioner#initLegalContentTypes()
*/
protected void initLegalContentTypes() {
- fSupportedTypes = new String[]{IDTDPartitions.DTD_DEFAULT, IStructuredPartitions.UNKNOWN_PARTITION};
+ fSupportedTypes = new String[]{IDTDPartitionTypes.DTD_DEFAULT, IStructuredPartitionTypes.UNKNOWN_PARTITION};
}
}
diff --git a/bundles/org.eclipse.wst.dtd.core/src/org/eclipse/wst/dtd/core/text/IDTDPartitions.java b/bundles/org.eclipse.wst.dtd.core/src/org/eclipse/wst/dtd/core/text/IDTDPartitionTypes.java
index d5e6f4574e..0a6be92557 100644
--- a/bundles/org.eclipse.wst.dtd.core/src/org/eclipse/wst/dtd/core/text/IDTDPartitions.java
+++ b/bundles/org.eclipse.wst.dtd.core/src/org/eclipse/wst/dtd/core/text/IDTDPartitionTypes.java
@@ -1,17 +1,14 @@
package org.eclipse.wst.dtd.core.text;
-import org.eclipse.wst.sse.core.text.IStructuredPartitions;
/**
* This interface is not intended to be implemented.
- * It defines the partitioning for DTD and all its partitions.
+ * It defines the partition types DTD.
* Clients should reference the partition type Strings defined here directly.
*
* @since 1.0
*/
-public interface IDTDPartitions {
-
- String DTD_PARTITIONING = IStructuredPartitions.STRUCTURED_PARTITIONING;
+public interface IDTDPartitionTypes {
String DTD_DEFAULT = "org.eclipse.wst.dtd.DEFAULT"; //$NON-NLS-1$
}
diff --git a/bundles/org.eclipse.wst.dtd.ui/src/org/eclipse/wst/dtd/ui/StructuredTextViewerConfigurationDTD.java b/bundles/org.eclipse.wst.dtd.ui/src/org/eclipse/wst/dtd/ui/StructuredTextViewerConfigurationDTD.java
index ebdd7adf1c..fffffa40c3 100644
--- a/bundles/org.eclipse.wst.dtd.ui/src/org/eclipse/wst/dtd/ui/StructuredTextViewerConfigurationDTD.java
+++ b/bundles/org.eclipse.wst.dtd.ui/src/org/eclipse/wst/dtd/ui/StructuredTextViewerConfigurationDTD.java
@@ -15,11 +15,11 @@ package org.eclipse.wst.dtd.ui;
import org.eclipse.jface.preference.IPreferenceStore;
import org.eclipse.jface.text.ITextHover;
import org.eclipse.jface.text.source.ISourceViewer;
-import org.eclipse.wst.dtd.core.text.IDTDPartitions;
+import org.eclipse.wst.dtd.core.text.IDTDPartitionTypes;
import org.eclipse.wst.dtd.ui.internal.style.LineStyleProviderForDTD;
import org.eclipse.wst.dtd.ui.internal.taginfo.DTDBestMatchHoverProcessor;
import org.eclipse.wst.sse.core.text.IStructuredDocument;
-import org.eclipse.wst.sse.core.text.IStructuredPartitions;
+import org.eclipse.wst.sse.core.text.IStructuredPartitionTypes;
import org.eclipse.wst.sse.ui.StructuredTextViewerConfiguration;
import org.eclipse.wst.sse.ui.style.IHighlighter;
import org.eclipse.wst.sse.ui.style.LineStyleProvider;
@@ -58,7 +58,7 @@ public class StructuredTextViewerConfigurationDTD extends StructuredTextViewerCo
*/
public String[] getConfiguredContentTypes(ISourceViewer sourceViewer) {
if (configuredContentTypes == null) {
- configuredContentTypes = new String[]{IDTDPartitions.DTD_DEFAULT, IStructuredPartitions.DEFAULT_PARTITION, IStructuredPartitions.UNKNOWN_PARTITION};
+ configuredContentTypes = new String[]{IDTDPartitionTypes.DTD_DEFAULT, IStructuredPartitionTypes.DEFAULT_PARTITION, IStructuredPartitionTypes.UNKNOWN_PARTITION};
}
return configuredContentTypes;
}
@@ -76,9 +76,9 @@ public class StructuredTextViewerConfigurationDTD extends StructuredTextViewerCo
LineStyleProvider dtdProvider = new LineStyleProviderForDTD();
LineStyleProvider noopProvider = new LineStyleProviderForNoOp();
- highlighter.addProvider(IDTDPartitions.DTD_DEFAULT, dtdProvider);
- highlighter.addProvider(IStructuredPartitions.DEFAULT_PARTITION, dtdProvider);
- highlighter.addProvider(IStructuredPartitions.UNKNOWN_PARTITION, noopProvider);
+ highlighter.addProvider(IDTDPartitionTypes.DTD_DEFAULT, dtdProvider);
+ highlighter.addProvider(IStructuredPartitionTypes.DEFAULT_PARTITION, dtdProvider);
+ highlighter.addProvider(IStructuredPartitionTypes.UNKNOWN_PARTITION, noopProvider);
highlighter.setDocument((IStructuredDocument) sourceViewer.getDocument());
diff --git a/bundles/org.eclipse.wst.dtd.ui/src/org/eclipse/wst/dtd/ui/internal/style/LineStyleProviderForDTDSubSet.java b/bundles/org.eclipse.wst.dtd.ui/src/org/eclipse/wst/dtd/ui/internal/style/LineStyleProviderForDTDSubSet.java
index 028dfdddd4..3768474f90 100644
--- a/bundles/org.eclipse.wst.dtd.ui/src/org/eclipse/wst/dtd/ui/internal/style/LineStyleProviderForDTDSubSet.java
+++ b/bundles/org.eclipse.wst.dtd.ui/src/org/eclipse/wst/dtd/ui/internal/style/LineStyleProviderForDTDSubSet.java
@@ -24,12 +24,13 @@ import org.eclipse.jface.text.TextUtilities;
import org.eclipse.swt.custom.StyleRange;
import org.eclipse.swt.graphics.RGB;
import org.eclipse.wst.dtd.core.contenttype.ContentTypeIdForDTD;
-import org.eclipse.wst.dtd.core.text.IDTDPartitions;
+import org.eclipse.wst.dtd.core.text.IDTDPartitionTypes;
import org.eclipse.wst.dtd.ui.internal.DTDUIPlugin;
import org.eclipse.wst.sse.core.IStructuredModel;
import org.eclipse.wst.sse.core.StructuredModelManager;
import org.eclipse.wst.sse.core.text.IStructuredDocument;
import org.eclipse.wst.sse.core.text.IStructuredDocumentRegion;
+import org.eclipse.wst.sse.core.text.IStructuredPartitioning;
import org.eclipse.wst.sse.core.text.ITextRegion;
import org.eclipse.wst.sse.ui.preferences.ui.ColorHelper;
import org.eclipse.wst.sse.ui.style.AbstractLineStyleProvider;
@@ -45,7 +46,7 @@ public class LineStyleProviderForDTDSubSet extends AbstractLineStyleProvider imp
super();
fInternalProvider = new LineStyleProviderForDTD();
fInternalRanges = new StyleRange[0];
- fPartitioning = IStructuredDocument.DEFAULT_STRUCTURED_PARTITIONING;
+ fPartitioning = IStructuredPartitioning.DEFAULT_STRUCTURED_PARTITIONING;
}
/**
@@ -115,7 +116,7 @@ public class LineStyleProviderForDTDSubSet extends AbstractLineStyleProvider imp
* int, int, java.util.Collection)
*/
public boolean prepareRegions(ITypedRegion typedRegion, int lineRequestStart, int lineRequestLength, Collection holdResults) {
- if (!IDTDPartitions.DTD_DEFAULT.equals(typedRegion.getType())) {
+ if (!IDTDPartitionTypes.DTD_DEFAULT.equals(typedRegion.getType())) {
// compute an internal DTD model and return linestyles for it
ITextRegion dtdContentRegion = null;
IStructuredDocumentRegion doctype = getDocument().getRegionAtCharacterOffset(typedRegion.getOffset());
diff --git a/bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/HTMLFormatContraints.java b/bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/HTMLFormatContraints.java
index 5346737757..0362d5fc15 100644
--- a/bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/HTMLFormatContraints.java
+++ b/bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/HTMLFormatContraints.java
@@ -10,7 +10,7 @@
*******************************************************************************/
package org.eclipse.wst.html.core;
-import org.eclipse.wst.sse.core.format.IStructuredFormatContraints;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatContraints;
/**
* @deprecated
diff --git a/bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/format/HTMLFormatContraintsImpl.java b/bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/format/HTMLFormatContraintsImpl.java
index 06c61cac56..5d5103e4aa 100644
--- a/bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/format/HTMLFormatContraintsImpl.java
+++ b/bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/format/HTMLFormatContraintsImpl.java
@@ -11,7 +11,7 @@
package org.eclipse.wst.html.core.format;
import org.eclipse.wst.html.core.HTMLFormatContraints;
-import org.eclipse.wst.sse.core.format.StructuredFormatContraints;
+import org.eclipse.wst.sse.core.internal.format.StructuredFormatContraints;
/**
* @deprecated
diff --git a/bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/format/HTMLFormatProcessorImpl.java b/bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/format/HTMLFormatProcessorImpl.java
index 8e49a516e7..f34d415dbe 100644
--- a/bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/format/HTMLFormatProcessorImpl.java
+++ b/bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/format/HTMLFormatProcessorImpl.java
@@ -12,9 +12,9 @@ package org.eclipse.wst.html.core.format;
import org.eclipse.core.runtime.Preferences;
import org.eclipse.wst.html.core.internal.HTMLCorePlugin;
-import org.eclipse.wst.sse.core.format.IStructuredFormatPreferences;
-import org.eclipse.wst.sse.core.format.IStructuredFormatter;
import org.eclipse.wst.sse.core.internal.SSECorePlugin;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatPreferences;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatter;
import org.eclipse.wst.sse.core.preferences.CommonModelPreferenceNames;
import org.eclipse.wst.xml.core.format.FormatProcessorXML;
import org.eclipse.wst.xml.core.format.IStructuredFormatPreferencesXML;
diff --git a/bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/format/HTMLFormatter.java b/bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/format/HTMLFormatter.java
index 778d7c404b..61612486bf 100644
--- a/bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/format/HTMLFormatter.java
+++ b/bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/format/HTMLFormatter.java
@@ -16,10 +16,10 @@ import org.eclipse.jface.text.BadLocationException;
import org.eclipse.wst.html.core.HTMLCMProperties;
import org.eclipse.wst.html.core.HTMLFormatContraints;
import org.eclipse.wst.html.core.internal.HTMLCorePlugin;
-import org.eclipse.wst.sse.core.format.IStructuredFormatContraints;
-import org.eclipse.wst.sse.core.format.IStructuredFormatPreferences;
-import org.eclipse.wst.sse.core.format.IStructuredFormatter;
import org.eclipse.wst.sse.core.internal.SSECorePlugin;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatContraints;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatPreferences;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatter;
import org.eclipse.wst.sse.core.preferences.CommonModelPreferenceNames;
import org.eclipse.wst.sse.core.text.IStructuredDocument;
import org.eclipse.wst.sse.core.text.IStructuredDocumentRegion;
diff --git a/bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/format/HTMLFormatterFactory.java b/bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/format/HTMLFormatterFactory.java
index 68e11d0497..857394274d 100644
--- a/bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/format/HTMLFormatterFactory.java
+++ b/bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/format/HTMLFormatterFactory.java
@@ -12,9 +12,9 @@ package org.eclipse.wst.html.core.format;
import org.eclipse.core.runtime.Preferences;
import org.eclipse.wst.html.core.internal.HTMLCorePlugin;
-import org.eclipse.wst.sse.core.format.IStructuredFormatPreferences;
-import org.eclipse.wst.sse.core.format.IStructuredFormatter;
import org.eclipse.wst.sse.core.internal.SSECorePlugin;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatPreferences;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatter;
import org.eclipse.wst.sse.core.preferences.CommonModelPreferenceNames;
import org.eclipse.wst.xml.core.format.IStructuredFormatPreferencesXML;
import org.eclipse.wst.xml.core.format.StructuredFormatPreferencesXML;
diff --git a/bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/internal/cleanup/HTMLCleanupProcessorImpl.java b/bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/internal/cleanup/HTMLCleanupProcessorImpl.java
index b16fb5d99b..ea6a01d816 100644
--- a/bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/internal/cleanup/HTMLCleanupProcessorImpl.java
+++ b/bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/internal/cleanup/HTMLCleanupProcessorImpl.java
@@ -14,8 +14,8 @@ import org.eclipse.core.runtime.Preferences;
import org.eclipse.wst.html.core.contenttype.ContentTypeIdForHTML;
import org.eclipse.wst.html.core.format.HTMLFormatProcessorImpl;
import org.eclipse.wst.html.core.internal.HTMLCorePlugin;
-import org.eclipse.wst.sse.core.format.IStructuredFormatProcessor;
import org.eclipse.wst.sse.core.internal.cleanup.IStructuredCleanupHandler;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatProcessor;
import org.eclipse.wst.xml.core.internal.cleanup.CleanupProcessorXML;
import org.w3c.dom.Node;
diff --git a/bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/internal/text/StructuredTextPartitionerForHTML.java b/bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/internal/text/StructuredTextPartitionerForHTML.java
index 0e7570ad48..193ac23b73 100644
--- a/bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/internal/text/StructuredTextPartitionerForHTML.java
+++ b/bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/internal/text/StructuredTextPartitionerForHTML.java
@@ -13,15 +13,15 @@ package org.eclipse.wst.html.core.internal.text;
import java.util.Locale;
import org.eclipse.jface.text.IDocumentPartitioner;
-import org.eclipse.wst.css.core.text.ICSSPartitions;
+import org.eclipse.wst.css.core.text.ICSSPartitionTypes;
import org.eclipse.wst.html.core.HTML40Namespace;
-import org.eclipse.wst.html.core.text.IHTMLPartitions;
+import org.eclipse.wst.html.core.text.IHTMLPartitionTypes;
import org.eclipse.wst.sse.core.internal.parser.ForeignRegion;
import org.eclipse.wst.sse.core.text.IStructuredDocumentRegion;
import org.eclipse.wst.sse.core.text.IStructuredTextPartitioner;
import org.eclipse.wst.sse.core.text.ITextRegion;
import org.eclipse.wst.sse.core.text.ITextRegionList;
-import org.eclipse.wst.sse.core.text.StructuredTypedRegion;
+import org.eclipse.wst.sse.core.text.IStructuredTypedRegion;
import org.eclipse.wst.sse.core.util.ScriptLanguageKeys;
import org.eclipse.wst.sse.core.util.StringUtils;
import org.eclipse.wst.xml.core.internal.text.rules.StructuredTextPartitionerForXML;
@@ -34,20 +34,17 @@ import org.eclipse.wst.xml.core.parser.XMLRegionContext;
*/
public class StructuredTextPartitionerForHTML extends StructuredTextPartitionerForXML implements IStructuredTextPartitioner {
- private final static String[] configuredContentTypes = new String[]{IHTMLPartitions.HTML_DEFAULT, IHTMLPartitions.HTML_DECLARATION, IHTMLPartitions.HTML_COMMENT, IHTMLPartitions.SCRIPT, ICSSPartitions.STYLE};
+ private final static String[] configuredContentTypes = new String[]{IHTMLPartitionTypes.HTML_DEFAULT, IHTMLPartitionTypes.HTML_DECLARATION, IHTMLPartitionTypes.HTML_COMMENT, IHTMLPartitionTypes.SCRIPT, ICSSPartitionTypes.STYLE};
public static final String JAVASCRIPT = "javascript"; //$NON-NLS-1$
public static final String JAVASCRIPT_APPLICATION = "application/x-javascript"; //$NON-NLS-1$
- /**
- * Constructor for JSPDocumentPartioner.
- */
public StructuredTextPartitionerForHTML() {
super();
}
- public StructuredTypedRegion createPartition(int offset, int length, String type) {
- if (type == IHTMLPartitions.SCRIPT) {
+ public IStructuredTypedRegion createPartition(int offset, int length, String type) {
+ if (type == IHTMLPartitionTypes.SCRIPT) {
IStructuredDocumentRegion node = structuredDocument.getRegionAtCharacterOffset(offset);
if (node != null) {
String stype = getScriptingPartitionType(node);
@@ -57,13 +54,9 @@ public class StructuredTextPartitionerForHTML extends StructuredTextPartitionerF
return super.createPartition(offset, length, type);
}
- /**
- * @see com.ibm.sed.structuredDocument.partition.StructuredTextPartitioner#createPartition(int,
- * int, java.lang.String)
- */
protected void setInternalPartition(int offset, int length, String type) {
String localType = type;
- if (type == IHTMLPartitions.SCRIPT) {
+ if (type == IHTMLPartitionTypes.SCRIPT) {
IStructuredDocumentRegion node = structuredDocument.getRegionAtCharacterOffset(offset);
if (node != null) {
localType = getScriptingPartitionType(node);
@@ -75,7 +68,7 @@ public class StructuredTextPartitionerForHTML extends StructuredTextPartitionerF
private String getScriptingPartitionType(IStructuredDocumentRegion coreNode) {
String language = null;
String type = null;
- String result = IHTMLPartitions.SCRIPT;
+ String result = IHTMLPartitionTypes.SCRIPT;
IStructuredDocumentRegion node = coreNode;
ITextRegion attrNameRegion = null;
while (node != null && isValidScriptingRegionType(node.getType())) {
@@ -123,44 +116,59 @@ public class StructuredTextPartitionerForHTML extends StructuredTextPartitionerF
private String lookupScriptType(String type) {
for (int i = 0; i < ScriptLanguageKeys.JAVASCRIPT_MIME_TYPE_KEYS.length; i++)
if (ScriptLanguageKeys.JAVASCRIPT_MIME_TYPE_KEYS[i].equalsIgnoreCase(type))
- return IHTMLPartitions.SCRIPT;
- return IHTMLPartitions.SCRIPT + ".type." + type.toUpperCase(Locale.ENGLISH); //$NON-NLS-1$
+ return IHTMLPartitionTypes.SCRIPT;
+ return IHTMLPartitionTypes.SCRIPT + ".type." + type.toUpperCase(Locale.ENGLISH); //$NON-NLS-1$
}
private String lookupScriptLanguage(String language) {
for (int i = 0; i < ScriptLanguageKeys.JAVASCRIPT_LANGUAGE_KEYS.length; i++)
if (ScriptLanguageKeys.JAVASCRIPT_LANGUAGE_KEYS[i].equalsIgnoreCase(language))
- return IHTMLPartitions.SCRIPT;
- return IHTMLPartitions.SCRIPT + ".language." + language.toUpperCase(Locale.ENGLISH); //$NON-NLS-1$
+ return IHTMLPartitionTypes.SCRIPT;
+ return IHTMLPartitionTypes.SCRIPT + ".language." + language.toUpperCase(Locale.ENGLISH); //$NON-NLS-1$
}
- /**
- * @see com.ibm.sed.model.StructuredTextPartitioner#getPartitionType(com.ibm.sed.structuredDocument.ITextRegion)
- */
public String getPartitionType(ITextRegion region, int offset) {
String result = null;
if (region.getType() == XMLRegionContext.XML_COMMENT_TEXT || region.getType() == XMLRegionContext.XML_COMMENT_OPEN)
- result = IHTMLPartitions.HTML_COMMENT;
+ result = IHTMLPartitionTypes.HTML_COMMENT;
else if (region.getType() == XMLRegionContext.XML_DOCTYPE_DECLARATION || region.getType() == XMLRegionContext.XML_DECLARATION_OPEN)
- result = IHTMLPartitions.HTML_DECLARATION;
+ result = IHTMLPartitionTypes.HTML_DECLARATION;
else
result = super.getPartitionType(region, offset);
return result;
}
- /**
- * @see com.ibm.sed.structuredDocument.partition.StructuredTextPartitioner#getPartitionTypeBetween(com.ibm.sed.structuredDocument.ITextRegion,
- * com.ibm.sed.structuredDocument.ITextRegion)
- */
- public String getPartitionTypeBetween(IStructuredDocumentRegion previousNode, ITextRegion previousStartTagNameRegion, IStructuredDocumentRegion nextNode, ITextRegion nextEndTagNameRegion) {
+ public String getPartitionTypeBetween(IStructuredDocumentRegion previousNode, IStructuredDocumentRegion nextNode) {
+
+ ITextRegion previousStartTagNameRegion = null;
+ ITextRegion nextEndTagNameRegion = null;
+
+ ITextRegion[] regions = previousNode.getRegions().toArray();
+ for (int i = 0; i < regions.length; i++) {
+ if(regions[i].getType() == XMLRegionContext.XML_TAG_NAME) {
+ previousStartTagNameRegion = regions[i];
+ break;
+ }
+ }
+ regions = nextNode.getRegions().toArray();
+ for (int i = 0; i < regions.length; i++) {
+ if(regions[i].getType() == XMLRegionContext.XML_TAG_NAME) {
+ nextEndTagNameRegion = regions[i];
+ break;
+ }
+ }
+
+ if(previousStartTagNameRegion == null || nextEndTagNameRegion == null)
+ return IHTMLPartitionTypes.HTML_DEFAULT;
+
String name1 = previousNode.getText(previousStartTagNameRegion);
String name2 = nextNode.getText(nextEndTagNameRegion);
if (name1.equalsIgnoreCase(HTML40Namespace.ElementName.SCRIPT) && name2.equalsIgnoreCase(HTML40Namespace.ElementName.SCRIPT))
// return ST_SCRIPT;
return getScriptingPartitionType(structuredDocument.getRegionAtCharacterOffset(previousNode.getStartOffset(previousStartTagNameRegion)));
else if (name1.equalsIgnoreCase(HTML40Namespace.ElementName.STYLE) && name2.equalsIgnoreCase(HTML40Namespace.ElementName.STYLE))
- return ICSSPartitions.STYLE;
- return super.getPartitionTypeBetween(previousNode, previousStartTagNameRegion, nextNode, nextEndTagNameRegion);
+ return ICSSPartitionTypes.STYLE;
+ return super.getPartitionTypeBetween(previousNode, nextNode);
}
@@ -173,17 +181,17 @@ public class StructuredTextPartitionerForHTML extends StructuredTextPartitionerF
result = getUnknown();
}
else if (tagname.equalsIgnoreCase(HTML40Namespace.ElementName.SCRIPT))
- result = IHTMLPartitions.SCRIPT;
+ result = IHTMLPartitionTypes.SCRIPT;
else if (tagname.equalsIgnoreCase(HTML40Namespace.ElementName.STYLE))
- result = ICSSPartitions.STYLE;
+ result = ICSSPartitionTypes.STYLE;
else
result = super.getPartitionType(region, offset);
return result;
}
- public String getDefault() {
- return IHTMLPartitions.HTML_DEFAULT;
+ public String getDefaultPartitionType() {
+ return IHTMLPartitionTypes.HTML_DEFAULT;
}
public IDocumentPartitioner newInstance() {
diff --git a/bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/text/IHTMLPartitions.java b/bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/text/IHTMLPartitionTypes.java
index bf44601d5b..d003c4e2b6 100644
--- a/bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/text/IHTMLPartitions.java
+++ b/bundles/org.eclipse.wst.html.core/src/org/eclipse/wst/html/core/text/IHTMLPartitionTypes.java
@@ -1,18 +1,15 @@
package org.eclipse.wst.html.core.text;
-import org.eclipse.wst.sse.core.text.IStructuredPartitions;
/**
* This interface is not intended to be implemented.
- * It defines the partitioning for HTML and all its partitions.
+ * It defines the partition types for HTML.
* Clients should reference the partition type Strings defined here directly.
*
* @since 1.0
*/
-public interface IHTMLPartitions {
-
- String HTML_PARTITIONING = IStructuredPartitions.STRUCTURED_PARTITIONING;
-
+public interface IHTMLPartitionTypes {
+
String HTML_DEFAULT = "org.eclipse.wst.html.HTML_DEFAULT"; //$NON-NLS-1$
String HTML_DECLARATION = "org.eclipse.wst.html.HTML_DECLARATION"; //$NON-NLS-1$
String HTML_COMMENT = "org.eclipse.wst.html.HTML_COMMENT"; //$NON-NLS-1$
diff --git a/bundles/org.eclipse.wst.html.ui/src/org/eclipse/wst/html/ui/StructuredTextViewerConfigurationHTML.java b/bundles/org.eclipse.wst.html.ui/src/org/eclipse/wst/html/ui/StructuredTextViewerConfigurationHTML.java
index 69997a96d7..5c03f78823 100644
--- a/bundles/org.eclipse.wst.html.ui/src/org/eclipse/wst/html/ui/StructuredTextViewerConfigurationHTML.java
+++ b/bundles/org.eclipse.wst.html.ui/src/org/eclipse/wst/html/ui/StructuredTextViewerConfigurationHTML.java
@@ -35,12 +35,12 @@ import org.eclipse.jface.text.reconciler.IReconcilingStrategy;
import org.eclipse.jface.text.source.ISourceViewer;
import org.eclipse.ui.texteditor.AbstractDecoratedTextEditorPreferenceConstants;
import org.eclipse.ui.texteditor.ITextEditor;
-import org.eclipse.wst.css.core.text.ICSSPartitions;
+import org.eclipse.wst.css.core.text.ICSSPartitionTypes;
import org.eclipse.wst.css.ui.contentassist.CSSContentAssistProcessor;
import org.eclipse.wst.css.ui.style.LineStyleProviderForEmbeddedCSS;
import org.eclipse.wst.html.core.format.HTMLFormatProcessorImpl;
import org.eclipse.wst.html.core.internal.text.StructuredTextPartitionerForHTML;
-import org.eclipse.wst.html.core.text.IHTMLPartitions;
+import org.eclipse.wst.html.core.text.IHTMLPartitionTypes;
import org.eclipse.wst.html.ui.internal.contentassist.HTMLContentAssistProcessor;
import org.eclipse.wst.html.ui.internal.contentassist.NoRegionContentAssistProcessorForHTML;
import org.eclipse.wst.html.ui.internal.hyperlink.URIHyperlinkDetector;
@@ -55,7 +55,7 @@ import org.eclipse.wst.javascript.common.ui.internal.taginfo.JavaScriptInformati
import org.eclipse.wst.javascript.common.ui.internal.taginfo.JavaScriptTagInfoHoverProcessor;
import org.eclipse.wst.sse.core.IStructuredModel;
import org.eclipse.wst.sse.core.StructuredModelManager;
-import org.eclipse.wst.sse.core.text.IStructuredPartitions;
+import org.eclipse.wst.sse.core.text.IStructuredPartitionTypes;
import org.eclipse.wst.sse.ui.StructuredTextViewerConfiguration;
import org.eclipse.wst.sse.ui.format.StructuredFormattingStrategy;
import org.eclipse.wst.sse.ui.internal.StructuredTextEditor;
@@ -100,7 +100,7 @@ public class StructuredTextViewerConfigurationHTML extends StructuredTextViewerC
allStrategies.add(superStrategies[i]);
}
- if (contentType == IHTMLPartitions.HTML_DEFAULT || contentType == IHTMLPartitions.HTML_DECLARATION) {
+ if (contentType == IHTMLPartitionTypes.HTML_DEFAULT || contentType == IHTMLPartitionTypes.HTML_DECLARATION) {
allStrategies.add(new StructuredAutoEditStrategyXML());
}
@@ -113,8 +113,8 @@ public class StructuredTextViewerConfigurationHTML extends StructuredTextViewerC
String[] htmlTypes = StructuredTextPartitionerForHTML.getConfiguredContentTypes();
configuredContentTypes = new String[2 + xmlTypes.length + htmlTypes.length];
- configuredContentTypes[0] = IStructuredPartitions.DEFAULT_PARTITION;
- configuredContentTypes[1] = IStructuredPartitions.UNKNOWN_PARTITION;
+ configuredContentTypes[0] = IStructuredPartitionTypes.DEFAULT_PARTITION;
+ configuredContentTypes[1] = IStructuredPartitionTypes.UNKNOWN_PARTITION;
int index = 0;
System.arraycopy(xmlTypes, 0, configuredContentTypes, index += 2, xmlTypes.length);
@@ -136,24 +136,24 @@ public class StructuredTextViewerConfigurationHTML extends StructuredTextViewerC
IContentAssistProcessor noRegionProcessorForHTML = new NoRegionContentAssistProcessorForHTML();
// HTML
- setContentAssistProcessor(contentAssistant, htmlContentAssistProcessor, IHTMLPartitions.HTML_DEFAULT);
- setContentAssistProcessor(contentAssistant, htmlContentAssistProcessor, IHTMLPartitions.HTML_COMMENT);
+ setContentAssistProcessor(contentAssistant, htmlContentAssistProcessor, IHTMLPartitionTypes.HTML_DEFAULT);
+ setContentAssistProcessor(contentAssistant, htmlContentAssistProcessor, IHTMLPartitionTypes.HTML_COMMENT);
// JavaScript
- setContentAssistProcessor(contentAssistant, jsContentAssistProcessor, IHTMLPartitions.SCRIPT);
+ setContentAssistProcessor(contentAssistant, jsContentAssistProcessor, IHTMLPartitionTypes.SCRIPT);
// CSS
- setContentAssistProcessor(contentAssistant, cssContentAssistProcessor, ICSSPartitions.STYLE);
+ setContentAssistProcessor(contentAssistant, cssContentAssistProcessor, ICSSPartitionTypes.STYLE);
// unknown
- setContentAssistProcessor(contentAssistant, noRegionProcessorForHTML, IStructuredPartitions.UNKNOWN_PARTITION);
+ setContentAssistProcessor(contentAssistant, noRegionProcessorForHTML, IStructuredPartitionTypes.UNKNOWN_PARTITION);
}
return ca;
}
public IContentFormatter getContentFormatter(ISourceViewer sourceViewer) {
- final MultiPassContentFormatter formatter = new MultiPassContentFormatter(getConfiguredDocumentPartitioning(sourceViewer), IHTMLPartitions.HTML_DEFAULT);
+ final MultiPassContentFormatter formatter = new MultiPassContentFormatter(getConfiguredDocumentPartitioning(sourceViewer), IHTMLPartitionTypes.HTML_DEFAULT);
formatter.setMasterStrategy(new StructuredFormattingStrategy(new HTMLFormatProcessorImpl()));
@@ -168,7 +168,7 @@ public class StructuredTextViewerConfigurationHTML extends StructuredTextViewerC
ITextEditor editor = getTextEditor();
if (editor != null) {
IContentAssistProcessor correctionProcessor = new CorrectionProcessorXML(editor);
- correctionAssistant.setContentAssistProcessor(correctionProcessor, IHTMLPartitions.HTML_DEFAULT);
+ correctionAssistant.setContentAssistProcessor(correctionProcessor, IHTMLPartitionTypes.HTML_DEFAULT);
correctionAssistant.setContentAssistProcessor(correctionProcessor, IXMLPartitions.XML_CDATA);
correctionAssistant.setContentAssistProcessor(correctionProcessor, IXMLPartitions.XML_COMMENT);
correctionAssistant.setContentAssistProcessor(correctionProcessor, IXMLPartitions.XML_DECLARATION);
@@ -181,10 +181,10 @@ public class StructuredTextViewerConfigurationHTML extends StructuredTextViewerC
}
public ITextDoubleClickStrategy getDoubleClickStrategy(ISourceViewer sourceViewer, String contentType) {
- if (contentType.compareTo(IHTMLPartitions.HTML_DEFAULT) == 0)
+ if (contentType.compareTo(IHTMLPartitionTypes.HTML_DEFAULT) == 0)
// HTML
return new XMLDoubleClickStrategy();
- else if (contentType.compareTo(IHTMLPartitions.SCRIPT) == 0)
+ else if (contentType.compareTo(IHTMLPartitionTypes.SCRIPT) == 0)
// JavaScript
return getJavaSourceViewerConfiguration(sourceViewer).getDoubleClickStrategy(sourceViewer, contentType);
else
@@ -197,17 +197,17 @@ public class StructuredTextViewerConfigurationHTML extends StructuredTextViewerC
if (highlighter != null) {
// HTML
LineStyleProvider htmlLineStyleProvider = new LineStyleProviderForHTML();
- highlighter.addProvider(IHTMLPartitions.HTML_DEFAULT, htmlLineStyleProvider);
- highlighter.addProvider(IHTMLPartitions.HTML_COMMENT, htmlLineStyleProvider);
- highlighter.addProvider(IHTMLPartitions.HTML_DECLARATION, htmlLineStyleProvider);
+ highlighter.addProvider(IHTMLPartitionTypes.HTML_DEFAULT, htmlLineStyleProvider);
+ highlighter.addProvider(IHTMLPartitionTypes.HTML_COMMENT, htmlLineStyleProvider);
+ highlighter.addProvider(IHTMLPartitionTypes.HTML_DECLARATION, htmlLineStyleProvider);
// JavaScript
LineStyleProvider jsLineStyleProvider = new LineStyleProviderForJavaScript();
- highlighter.addProvider(IHTMLPartitions.SCRIPT, jsLineStyleProvider);
+ highlighter.addProvider(IHTMLPartitionTypes.SCRIPT, jsLineStyleProvider);
// CSS
LineStyleProvider cssLineStyleProvider = new LineStyleProviderForEmbeddedCSS();
- highlighter.addProvider(ICSSPartitions.STYLE, cssLineStyleProvider);
+ highlighter.addProvider(ICSSPartitionTypes.STYLE, cssLineStyleProvider);
}
return highlighter;
@@ -241,11 +241,11 @@ public class StructuredTextViewerConfigurationHTML extends StructuredTextViewerC
// HTML
IInformationProvider htmlInformationProvider = new HTMLInformationProvider();
- fInformationPresenter.setInformationProvider(htmlInformationProvider, IHTMLPartitions.HTML_DEFAULT);
+ fInformationPresenter.setInformationProvider(htmlInformationProvider, IHTMLPartitionTypes.HTML_DEFAULT);
// JavaScript
IInformationProvider javascriptInformationProvider = new JavaScriptInformationProvider();
- fInformationPresenter.setInformationProvider(javascriptInformationProvider, IHTMLPartitions.SCRIPT);
+ fInformationPresenter.setInformationProvider(javascriptInformationProvider, IHTMLPartitionTypes.SCRIPT);
fInformationPresenter.setSizeConstraints(60, 10, true, true);
}
@@ -294,7 +294,7 @@ public class StructuredTextViewerConfigurationHTML extends StructuredTextViewerC
IReconcilingStrategy markupStrategy = new StructuredTextReconcilingStrategyForMarkup((ITextEditor) editorPart);
- fReconciler.setReconcilingStrategy(markupStrategy, IStructuredPartitions.DEFAULT_PARTITION);
+ fReconciler.setReconcilingStrategy(markupStrategy, IStructuredPartitionTypes.DEFAULT_PARTITION);
fReconciler.setReconcilingStrategy(markupStrategy, IXMLPartitions.XML_DEFAULT);
fReconciler.setDefaultStrategy(markupStrategy);
@@ -320,7 +320,7 @@ public class StructuredTextViewerConfigurationHTML extends StructuredTextViewerC
String hoverType = hoverDescs[i].getId();
if (TextHoverManager.COMBINATION_HOVER.equalsIgnoreCase(hoverType)) {
// treat specially if it's JavaScript, HTML otherwise
- if (contentType.equals(IHTMLPartitions.SCRIPT)) {
+ if (contentType.equals(IHTMLPartitionTypes.SCRIPT)) {
hover = new JavaScriptBestMatchHoverProcessor();
}
else {
@@ -335,7 +335,7 @@ public class StructuredTextViewerConfigurationHTML extends StructuredTextViewerC
}
else if (TextHoverManager.DOCUMENTATION_HOVER.equalsIgnoreCase(hoverType)) {
// treat specially if it's JavaScript, HTML otherwise
- if (contentType.equals(IHTMLPartitions.SCRIPT)) {
+ if (contentType.equals(IHTMLPartitionTypes.SCRIPT)) {
hover = new JavaScriptTagInfoHoverProcessor();
}
else {
diff --git a/bundles/org.eclipse.wst.html.ui/src/org/eclipse/wst/html/ui/internal/contentassist/NoRegionContentAssistProcessorForHTML.java b/bundles/org.eclipse.wst.html.ui/src/org/eclipse/wst/html/ui/internal/contentassist/NoRegionContentAssistProcessorForHTML.java
index 1c1652a64e..61e47302af 100644
--- a/bundles/org.eclipse.wst.html.ui/src/org/eclipse/wst/html/ui/internal/contentassist/NoRegionContentAssistProcessorForHTML.java
+++ b/bundles/org.eclipse.wst.html.ui/src/org/eclipse/wst/html/ui/internal/contentassist/NoRegionContentAssistProcessorForHTML.java
@@ -11,9 +11,9 @@
package org.eclipse.wst.html.ui.internal.contentassist;
import org.eclipse.jface.text.contentassist.IContentAssistProcessor;
-import org.eclipse.wst.css.core.text.ICSSPartitions;
+import org.eclipse.wst.css.core.text.ICSSPartitionTypes;
import org.eclipse.wst.css.ui.contentassist.CSSContentAssistProcessor;
-import org.eclipse.wst.html.core.text.IHTMLPartitions;
+import org.eclipse.wst.html.core.text.IHTMLPartitionTypes;
import org.eclipse.wst.javascript.common.ui.internal.contentassist.JavaScriptContentAssistProcessor;
import org.eclipse.wst.xml.ui.contentassist.NoRegionContentAssistProcessor;
@@ -28,13 +28,13 @@ public class NoRegionContentAssistProcessorForHTML extends NoRegionContentAssist
protected void initPartitionToProcessorMap() {
super.initPartitionToProcessorMap();
IContentAssistProcessor htmlProcessor = new HTMLContentAssistProcessor();
- fPartitionToProcessorMap.put(IHTMLPartitions.HTML_DEFAULT, htmlProcessor);
- fPartitionToProcessorMap.put(IHTMLPartitions.HTML_COMMENT, htmlProcessor);
+ fPartitionToProcessorMap.put(IHTMLPartitionTypes.HTML_DEFAULT, htmlProcessor);
+ fPartitionToProcessorMap.put(IHTMLPartitionTypes.HTML_COMMENT, htmlProcessor);
IContentAssistProcessor jsContentAssistProcessor = new JavaScriptContentAssistProcessor();
- fPartitionToProcessorMap.put(IHTMLPartitions.SCRIPT, jsContentAssistProcessor);
+ fPartitionToProcessorMap.put(IHTMLPartitionTypes.SCRIPT, jsContentAssistProcessor);
IContentAssistProcessor cssContentAssistProcessor = new CSSContentAssistProcessor();
- fPartitionToProcessorMap.put(ICSSPartitions.STYLE, cssContentAssistProcessor);
+ fPartitionToProcessorMap.put(ICSSPartitionTypes.STYLE, cssContentAssistProcessor);
}
} \ No newline at end of file
diff --git a/bundles/org.eclipse.wst.html.ui/src/org/eclipse/wst/html/ui/internal/contentoutline/HTMLNodeActionManager.java b/bundles/org.eclipse.wst.html.ui/src/org/eclipse/wst/html/ui/internal/contentoutline/HTMLNodeActionManager.java
index ea3cf64195..fef5dc5df2 100644
--- a/bundles/org.eclipse.wst.html.ui/src/org/eclipse/wst/html/ui/internal/contentoutline/HTMLNodeActionManager.java
+++ b/bundles/org.eclipse.wst.html.ui/src/org/eclipse/wst/html/ui/internal/contentoutline/HTMLNodeActionManager.java
@@ -18,7 +18,7 @@ import org.eclipse.wst.html.core.format.HTMLFormatProcessorImpl;
import org.eclipse.wst.html.core.internal.HTMLCorePlugin;
import org.eclipse.wst.html.core.preferences.HTMLContentBuilder;
import org.eclipse.wst.sse.core.IStructuredModel;
-import org.eclipse.wst.sse.core.format.IStructuredFormatProcessor;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatProcessor;
import org.eclipse.wst.sse.core.preferences.CommonModelPreferenceNames;
import org.eclipse.wst.xml.core.internal.contentmodel.CMNode;
import org.eclipse.wst.xml.core.internal.contentmodel.util.DOMContentBuilder;
diff --git a/bundles/org.eclipse.wst.html.ui/src/org/eclipse/wst/html/ui/internal/search/HTMLFindOccurrencesAction.java b/bundles/org.eclipse.wst.html.ui/src/org/eclipse/wst/html/ui/internal/search/HTMLFindOccurrencesAction.java
index c30659d870..30ea5e4d0c 100644
--- a/bundles/org.eclipse.wst.html.ui/src/org/eclipse/wst/html/ui/internal/search/HTMLFindOccurrencesAction.java
+++ b/bundles/org.eclipse.wst.html.ui/src/org/eclipse/wst/html/ui/internal/search/HTMLFindOccurrencesAction.java
@@ -13,7 +13,7 @@ package org.eclipse.wst.html.ui.internal.search;
import java.util.ResourceBundle;
import org.eclipse.ui.texteditor.ITextEditor;
-import org.eclipse.wst.html.core.text.IHTMLPartitions;
+import org.eclipse.wst.html.core.text.IHTMLPartitionTypes;
import org.eclipse.wst.sse.ui.internal.search.BasicFindOccurrencesAction;
import org.eclipse.wst.xml.core.parser.XMLRegionContext;
import org.eclipse.wst.xml.core.text.IXMLPartitions;
@@ -35,7 +35,7 @@ public class HTMLFindOccurrencesAction extends BasicFindOccurrencesAction {
*/
public String[] getPartitionTypes() {
- return new String[]{IHTMLPartitions.HTML_DEFAULT, IXMLPartitions.XML_DEFAULT};
+ return new String[]{IHTMLPartitionTypes.HTML_DEFAULT, IXMLPartitions.XML_DEFAULT};
}
/**
diff --git a/bundles/org.eclipse.wst.sse.core/component.xml b/bundles/org.eclipse.wst.sse.core/component.xml
index da6a4dda2c..43b9751ec3 100644
--- a/bundles/org.eclipse.wst.sse.core/component.xml
+++ b/bundles/org.eclipse.wst.sse.core/component.xml
@@ -1,54 +1,57 @@
<?xml version="1.0" encoding="UTF-8"?>
-<component xmlns="http://eclipse.org/wtp/releng/tools/component-model"
- name="org.eclipse.wst.sse">
- <component-depends unrestricted="true"></component-depends>
- <plugin id="org.eclipse.wst.sse.core" />
- <plugin id="org.eclipse.wst.sse.ui" />
-
- <!-- core -->
-
-<!-- dw-->
- <package name="org.eclipse.wst.sse.core" />
- <type name="LifecycleNotificationManager" reference="false" implement="false" subclass="false" instantiate="false" />
- <type name="ModelLifecycleEvent" reference="false" implement="false" subclass="false" instantiate="false" />
- <type name="DocumentChanged" reference="false" implement="false" subclass="false" instantiate="false" />
-
-<!-- dw -->
- <package name="org.eclipse.wst.sse.core.events" />
- <type name="IModelAboutToBeChangedListener" reference="false" implement="false" subclass="false" instantiate="false" />
- <type name="IStructuredDocumentListener" reference="false" implement="false" subclass="false" instantiate="false" />
-
-<!-- nitin-->
- <package name="org.eclipse.wst.sse.core.text" />
-<!-- nitin-->
- <package name="org.eclipse.wst.sse.core.filebuffers" />
-
-
- <package name="org.eclipse.wst.sse.core.preferences" />
- <type name="PreferenceChangeListener" reference="false" implement="false" subclass="false" instantiate="false" />
-
- <!-- ui -->
-
- <package name="org.eclipse.wst.sse.ui.preferences" />
- <type name="PreferenceManager" reference="false" implement="false" subclass="false" instantiate="false" />
-
-<!-- nitin-->
- <package name="org.eclipse.wst.sse.ui" />
-
-<!-- dw-->
- <package name="org.eclipse.wst.sse.ui.style"/>
- <type name="Highlighter" reference="false" implement="false" subclass="false" instantiate="false" />
- <type name="IHighlighter" reference="false" implement="false" subclass="false" instantiate="false" />
- <type name="LineStyleProviderForNoOp" reference="false" implement="false" subclass="false" instantiate="false" />
- <type name="YUV_RGBConverter" reference="false" implement="false" subclass="false" instantiate="false" />
-
-
-<!-- nitin-->
- <package name="org.eclipse.wst.sse.ui.views.contentoutline"/>
-<!-- nitin-->
- <package name="org.eclipse.wst.sse.ui.views.properties"/>
-
-<!-- dw-->
- <package name="org.eclipse.wst.sse.ui.contentproperties" />
+<component xmlns="http://eclipse.org/wtp/releng/tools/component-model" name="org.eclipse.wst.sse">
+ <component-depends unrestricted="true"></component-depends>
+ <plugin id="org.eclipse.wst.sse.core" />
+ <plugin id="org.eclipse.wst.sse.ui" />
+
+ <!-- core -->
+
+ <!-- dw-->
+ <package name="org.eclipse.wst.sse.core">
+ <type name="LifecycleNotificationManager" reference="false" implement="false" subclass="false" instantiate="false" />
+ <type name="ModelLifecycleEvent" reference="false" implement="false" subclass="false" instantiate="false" />
+ <type name="DocumentChanged" reference="false" implement="false" subclass="false" instantiate="false" />
+ </package>
+
+ <!-- dw -->
+ <package name="org.eclipse.wst.sse.core.events" />
+ <type name="IModelAboutToBeChangedListener" reference="false" implement="false" subclass="false" instantiate="false" />
+ <type name="IStructuredDocumentListener" reference="false" implement="false" subclass="false" instantiate="false" />
+
+ <!-- nitin-->
+ <package name="org.eclipse.wst.sse.core.text" >
+ <type name="IStructuredTextPartitioner" reference="false" implement="false" subclass="false" instantiate="false" />
+ </package>
+ <!-- nitin-->
+ <package name="org.eclipse.wst.sse.core.filebuffers" />
+
+ <package name="org.eclipse.wst.sse.core.preferences" >
+ <type name="PreferenceChangeListener" reference="false" implement="false" subclass="false" instantiate="false" />
+ </package>
+
+ <!-- ui -->
+
+ <package name="org.eclipse.wst.sse.ui.preferences" >
+ <type name="PreferenceManager" reference="false" implement="false" subclass="false" instantiate="false" />
+ </package>
+
+ <!-- nitin-->
+ <package name="org.eclipse.wst.sse.ui" />
+
+ <!-- dw-->
+ <package name="org.eclipse.wst.sse.ui.style">
+ <type name="Highlighter" reference="false" implement="false" subclass="false" instantiate="false" />
+ <type name="IHighlighter" reference="false" implement="false" subclass="false" instantiate="false" />
+ <type name="LineStyleProviderForNoOp" reference="false" implement="false" subclass="false" instantiate="false" />
+ <type name="YUV_RGBConverter" reference="false" implement="false" subclass="false" instantiate="false" />
+ </package>
+
+ <!-- nitin-->
+ <package name="org.eclipse.wst.sse.ui.views.contentoutline" />
+ <!-- nitin-->
+ <package name="org.eclipse.wst.sse.ui.views.properties" />
+
+ <!-- dw-->
+ <package name="org.eclipse.wst.sse.ui.contentproperties" />
</component> \ No newline at end of file
diff --git a/bundles/org.eclipse.wst.sse.core/schema/formatProcessors.exsd b/bundles/org.eclipse.wst.sse.core/schema/formatProcessors.exsd
index 975641685e..bba4976a97 100644
--- a/bundles/org.eclipse.wst.sse.core/schema/formatProcessors.exsd
+++ b/bundles/org.eclipse.wst.sse.core/schema/formatProcessors.exsd
@@ -66,7 +66,7 @@
<meta.section type="since"/>
</appInfo>
<documentation>
- [Enter the first release in which this extension point appears.]
+ 1.0
</documentation>
</annotation>
@@ -75,11 +75,11 @@
<meta.section type="examples"/>
</appInfo>
<documentation>
- &lt;extension point=&quot;org.eclipse.wst.sse.core.formatProcessors&quot;&gt;
- &lt;processor
- class=&quot;org.eclipse.wst.sse.core.xml.format.FormatProcessorXML&quot;
- contentTypeId=&quot;org.eclipse.core.runtime.xml&quot;&gt;
- &lt;/processor&gt;
+ &lt;extension point=&quot;org.eclipse.wst.sse.core.formatProcessors&quot;&gt;
+ &lt;processor
+ class=&quot;org.eclipse.wst.sse.core.xml.format.FormatProcessorXML&quot;
+ contentTypeId=&quot;org.eclipse.core.runtime.xml&quot;&gt;
+ &lt;/processor&gt;
&lt;/extension&gt;
</documentation>
</annotation>
diff --git a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/AbstractModelLoader.java b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/AbstractModelLoader.java
index bbee77cbb4..b8900362f4 100644
--- a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/AbstractModelLoader.java
+++ b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/AbstractModelLoader.java
@@ -37,6 +37,7 @@ import org.eclipse.wst.sse.core.parser.StructuredDocumentRegionHandlerExtension;
import org.eclipse.wst.sse.core.parser.StructuredDocumentRegionParser;
import org.eclipse.wst.sse.core.parser.StructuredDocumentRegionParserExtension;
import org.eclipse.wst.sse.core.text.IStructuredDocument;
+import org.eclipse.wst.sse.core.text.IStructuredPartitioning;
import org.eclipse.wst.sse.core.util.Assert;
@@ -454,11 +455,11 @@ public abstract class AbstractModelLoader implements IModelLoader {
if (newInstance.getDocumentPartitioner() instanceof StructuredTextPartitioner) {
StructuredTextPartitioner partitioner = null;
if (oldInstance instanceof IDocumentExtension3 && newInstance instanceof IDocumentExtension3) {
- partitioner = ((StructuredTextPartitioner) ((IDocumentExtension3) newInstance).getDocumentPartitioner(IStructuredDocument.DEFAULT_STRUCTURED_PARTITIONING));
+ partitioner = ((StructuredTextPartitioner) ((IDocumentExtension3) newInstance).getDocumentPartitioner(IStructuredPartitioning.DEFAULT_STRUCTURED_PARTITIONING));
if (partitioner != null) {
partitioner = (StructuredTextPartitioner) partitioner.newInstance();
}
- ((IDocumentExtension3) oldInstance).setDocumentPartitioner(IStructuredDocument.DEFAULT_STRUCTURED_PARTITIONING, partitioner);
+ ((IDocumentExtension3) oldInstance).setDocumentPartitioner(IStructuredPartitioning.DEFAULT_STRUCTURED_PARTITIONING, partitioner);
}
if (partitioner == null) {
partitioner = (StructuredTextPartitioner) ((StructuredTextPartitioner) newInstance.getDocumentPartitioner()).newInstance();
diff --git a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/IModelLoader.java b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/IModelLoader.java
index 89da2c0597..45044f21b0 100644
--- a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/IModelLoader.java
+++ b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/IModelLoader.java
@@ -54,8 +54,6 @@ public interface IModelLoader {
void load(InputStream inputStream, IStructuredModel model, EncodingRule encodingRule) throws IOException;
- void load(InputStream inputStream, IStructuredModel model, String encodingName, String lineDelimiter) throws IOException;
-
void load(String filename, InputStream inputStream, IStructuredModel model, String encodingName, String lineDelimiter) throws IOException;
IModelLoader newInstance();
diff --git a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/document/AbstractDocumentLoader.java b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/document/AbstractDocumentLoader.java
index f5a46bc8b1..ddfe39fdcf 100644
--- a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/document/AbstractDocumentLoader.java
+++ b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/document/AbstractDocumentLoader.java
@@ -34,7 +34,7 @@ import org.eclipse.wst.sse.core.internal.encoding.ContentTypeEncodingPreferences
import org.eclipse.wst.sse.core.internal.encoding.EncodingMemento;
import org.eclipse.wst.sse.core.internal.encoding.EncodingRule;
import org.eclipse.wst.sse.core.internal.exceptions.MalformedInputExceptionWithDetail;
-import org.eclipse.wst.sse.core.text.IStructuredDocument;
+import org.eclipse.wst.sse.core.text.IStructuredPartitioning;
@@ -102,7 +102,7 @@ public abstract class AbstractDocumentLoader implements IDocumentLoader {
IDocumentPartitioner defaultPartitioner = getDefaultDocumentPartitioner();
if (structuredDocument instanceof IDocumentExtension3) {
- ((IDocumentExtension3) structuredDocument).setDocumentPartitioner(IStructuredDocument.DEFAULT_STRUCTURED_PARTITIONING, defaultPartitioner);
+ ((IDocumentExtension3) structuredDocument).setDocumentPartitioner(IStructuredPartitioning.DEFAULT_STRUCTURED_PARTITIONING, defaultPartitioner);
}
else {
structuredDocument.setDocumentPartitioner(defaultPartitioner);
@@ -135,13 +135,6 @@ public abstract class AbstractDocumentLoader implements IDocumentLoader {
return structuredDocument;
}
- public IEncodedDocument createNewStructuredDocument(Reader reader) throws UnsupportedEncodingException, IOException {
- IEncodedDocument structuredDocument = createNewStructuredDocument();
- StringBuffer allText = readInputStream(fFullPreparedReader);
- structuredDocument.set(allText.toString());
- return structuredDocument;
- }
-
public IEncodedDocument createNewStructuredDocument(String filename, InputStream inputStream) throws UnsupportedEncodingException, IOException {
return createNewStructuredDocument(filename, inputStream, EncodingRule.CONTENT_BASED);
}
diff --git a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/document/IDocumentLoader.java b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/document/IDocumentLoader.java
index 419706c06b..4f636d8ab2 100644
--- a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/document/IDocumentLoader.java
+++ b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/document/IDocumentLoader.java
@@ -15,7 +15,6 @@ package org.eclipse.wst.sse.core.document;
import java.io.IOException;
import java.io.InputStream;
import java.io.Reader;
-import java.io.UnsupportedEncodingException;
import org.eclipse.core.resources.IFile;
import org.eclipse.core.runtime.CoreException;
@@ -38,8 +37,6 @@ public interface IDocumentLoader {
*/
IEncodedDocument createNewStructuredDocument(IFile iFile) throws java.io.IOException, CoreException;
- IEncodedDocument createNewStructuredDocument(Reader reader) throws UnsupportedEncodingException, IOException;
-
/**
* This method must return a new instance of IEncodedDocument, that has
* been initialized with appropriate parser. For many loaders, the
diff --git a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/format/IStructuredContentFormatter.java b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/format/IStructuredContentFormatter.java
deleted file mode 100644
index 729b416971..0000000000
--- a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/format/IStructuredContentFormatter.java
+++ /dev/null
@@ -1,19 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2004 IBM Corporation 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:
- * IBM Corporation - initial API and implementation
- * Jens Lukowski/Innoopract - initial renaming/restructuring
- *
- *******************************************************************************/
-package org.eclipse.wst.sse.core.format;
-
-import org.eclipse.wst.sse.core.IStructuredModel;
-
-public interface IStructuredContentFormatter {
- void setModel(IStructuredModel model);
-}
diff --git a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/cleanup/AbstractStructuredCleanupProcessor.java b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/cleanup/AbstractStructuredCleanupProcessor.java
index d11004acb2..9ffbd73fb3 100644
--- a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/cleanup/AbstractStructuredCleanupProcessor.java
+++ b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/cleanup/AbstractStructuredCleanupProcessor.java
@@ -28,9 +28,9 @@ import org.eclipse.jface.text.IRegion;
import org.eclipse.jface.text.TextUtilities;
import org.eclipse.wst.sse.core.IStructuredModel;
import org.eclipse.wst.sse.core.StructuredModelManager;
-import org.eclipse.wst.sse.core.format.IStructuredFormatProcessor;
import org.eclipse.wst.sse.core.internal.Logger;
import org.eclipse.wst.sse.core.internal.encoding.CommonEncodingPreferenceNames;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatProcessor;
import org.eclipse.wst.sse.core.text.IStructuredDocument;
import org.w3c.dom.Attr;
import org.w3c.dom.Node;
diff --git a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/format/AbstractStructuredFormatProcessor.java b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/format/AbstractStructuredFormatProcessor.java
index a7e0b3fb25..5dda5223ec 100644
--- a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/format/AbstractStructuredFormatProcessor.java
+++ b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/format/AbstractStructuredFormatProcessor.java
@@ -10,7 +10,7 @@
* Jens Lukowski/Innoopract - initial renaming/restructuring
*
*******************************************************************************/
-package org.eclipse.wst.sse.core.format;
+package org.eclipse.wst.sse.core.internal.format;
import java.io.ByteArrayInputStream;
import java.io.FileInputStream;
diff --git a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/format/IStructuredFormatContraints.java b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/format/IStructuredFormatContraints.java
index f3bcbd6942..11d7ca2da5 100644
--- a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/format/IStructuredFormatContraints.java
+++ b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/format/IStructuredFormatContraints.java
@@ -10,8 +10,13 @@
* Jens Lukowski/Innoopract - initial renaming/restructuring
*
*******************************************************************************/
-package org.eclipse.wst.sse.core.format;
+package org.eclipse.wst.sse.core.internal.format;
+/**
+ * These are items that change from element to element.
+ * Passed from node to node in a recursive call.
+ * eg. current indent is 2 deep, but for the next node might be 3...
+ */
public interface IStructuredFormatContraints {
boolean getClearAllBlankLines();
@@ -19,6 +24,9 @@ public interface IStructuredFormatContraints {
boolean getFormatWithSiblingIndent();
+ /**
+ * some special elements can ignore clearing blank lines
+ * */
void setClearAllBlankLines(boolean clearAllBlankLines);
void setCurrentIndent(String currentIndent);
diff --git a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/format/IStructuredFormatPreferences.java b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/format/IStructuredFormatPreferences.java
index 3329cb62ec..f7819f3f76 100644
--- a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/format/IStructuredFormatPreferences.java
+++ b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/format/IStructuredFormatPreferences.java
@@ -10,9 +10,15 @@
* Jens Lukowski/Innoopract - initial renaming/restructuring
*
*******************************************************************************/
-package org.eclipse.wst.sse.core.format;
+package org.eclipse.wst.sse.core.internal.format;
+/**
+ * These are items that do not change from element to element.
+ * Passed from node to node in a recursive call because sometimes
+ * child nodes don't have access to the preferences
+ */
public interface IStructuredFormatPreferences {
+
boolean getClearAllBlankLines();
String getIndent();
diff --git a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/format/IStructuredFormatProcessor.java b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/format/IStructuredFormatProcessor.java
index e279a676a8..d47c9bdb91 100644
--- a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/format/IStructuredFormatProcessor.java
+++ b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/format/IStructuredFormatProcessor.java
@@ -10,7 +10,7 @@
* Jens Lukowski/Innoopract - initial renaming/restructuring
*
*******************************************************************************/
-package org.eclipse.wst.sse.core.format;
+package org.eclipse.wst.sse.core.internal.format;
import java.io.IOException;
@@ -21,30 +21,11 @@ import org.eclipse.jface.text.IDocument;
import org.eclipse.wst.sse.core.IStructuredModel;
import org.w3c.dom.Node;
-
+/**
+ * The main formatting engine.
+ * Loops through all the nodes in an IStructuredModel.
+ */
public interface IStructuredFormatProcessor {
- /**
- * This form of the FormatProcessor takes an input string as input,
- * creates an InputStream from the input string, create a temporary model
- * of the content type specified, formats the whole model, then returns
- * the formatted input string.
- */
- String formatContent(String content) throws IOException, CoreException;
-
- /**
- * This form of the FormatProcessor takes an input string as input,
- * creates an InputStream from the input string, create a temporary model
- * of the content type specified, formats the model within start and
- * length, then returns the formatted input string.
- */
- String formatContent(String content, int start, int length) throws IOException, CoreException;
-
- /**
- * This form of the FormatProcessor takes an IDocument as input, creates a
- * temporary model of content type calculated using the IDocument's file
- * extension, formats the whole model, then releases the model.
- */
- void formatDocument(IDocument document) throws IOException, CoreException;
/**
* This form of the FormatProcessor takes an IDocument as input, creates a
@@ -62,30 +43,6 @@ public interface IStructuredFormatProcessor {
void formatFile(IFile file) throws IOException, CoreException;
/**
- * This form of the FormatProcessor takes an IFile as input, creates a
- * temporary model of content type calculated using the IFile's file
- * extension, formats the model within start and length, then releases the
- * model.
- */
- void formatFile(IFile file, int start, int length) throws IOException, CoreException;
-
- /**
- * This form of the FormatProcessor takes a file name as input,creates an
- * InputStream from the file, create a temporary model of content type
- * calculated using the file name's file extension, formats the whole
- * model, then releases the model.
- */
- void formatFileName(String fileName) throws IOException, CoreException;
-
- /**
- * This form of the FormatProcessor takes a file name as input,creates an
- * InputStream from the file, create a temporary model of content type
- * calculated using the file name's file extension, formats the model
- * within start and length, then releases the model.
- */
- void formatFileName(String fileName, int start, int length) throws IOException, CoreException;
-
- /**
* This form of the FormatProcessor takes a model as input, and formats
* the whole model.
*/
@@ -103,5 +60,11 @@ public interface IStructuredFormatProcessor {
*/
void formatNode(Node node);
+ /**
+ * Sets the progress monitor for this <code>IStructuredFormatProcessor</code>.
+ * The monitor is used to display progress or cancel if the formatter is run
+ * in a background job.
+ * @param monitor
+ */
void setProgressMonitor(IProgressMonitor monitor);
}
diff --git a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/format/IStructuredFormatter.java b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/format/IStructuredFormatter.java
index 59cb989ad6..c22ee6bdf6 100644
--- a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/format/IStructuredFormatter.java
+++ b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/format/IStructuredFormatter.java
@@ -10,12 +10,18 @@
* Jens Lukowski/Innoopract - initial renaming/restructuring
*
*******************************************************************************/
-package org.eclipse.wst.sse.core.format;
+package org.eclipse.wst.sse.core.internal.format;
import org.eclipse.core.runtime.IProgressMonitor;
import org.w3c.dom.Node;
+/**
+ * Knows how to format a particular node.
+ *
+ * eg. generic node, text node, document node, comment, etc...
+ */
public interface IStructuredFormatter {
+
void format(Node node);
void format(Node node, IStructuredFormatContraints formatContraints);
diff --git a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/format/StructuredFormatContraints.java b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/format/StructuredFormatContraints.java
index 8dcf98c7d5..e26cff2289 100644
--- a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/format/StructuredFormatContraints.java
+++ b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/format/StructuredFormatContraints.java
@@ -10,7 +10,7 @@
* Jens Lukowski/Innoopract - initial renaming/restructuring
*
*******************************************************************************/
-package org.eclipse.wst.sse.core.format;
+package org.eclipse.wst.sse.core.internal.format;
public class StructuredFormatContraints implements IStructuredFormatContraints {
protected int fAvailableLineWidth;
diff --git a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/format/StructuredFormatPreferences.java b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/format/StructuredFormatPreferences.java
index b41d11b0f7..67ad7cd54e 100644
--- a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/format/StructuredFormatPreferences.java
+++ b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/format/StructuredFormatPreferences.java
@@ -10,7 +10,7 @@
* Jens Lukowski/Innoopract - initial renaming/restructuring
*
*******************************************************************************/
-package org.eclipse.wst.sse.core.format;
+package org.eclipse.wst.sse.core.internal.format;
public class StructuredFormatPreferences implements IStructuredFormatPreferences {
private boolean fClearAllBlankLines;
diff --git a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/text/BasicStructuredDocument.java b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/text/BasicStructuredDocument.java
index cf9b8abc7b..f753643d4e 100644
--- a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/text/BasicStructuredDocument.java
+++ b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/text/BasicStructuredDocument.java
@@ -64,6 +64,7 @@ import org.eclipse.wst.sse.core.parser.RegionParser;
import org.eclipse.wst.sse.core.text.IStructuredDocument;
import org.eclipse.wst.sse.core.text.IStructuredDocumentRegion;
import org.eclipse.wst.sse.core.text.IStructuredDocumentRegionList;
+import org.eclipse.wst.sse.core.text.IStructuredPartitioning;
import org.eclipse.wst.sse.core.text.IStructuredTextReParser;
import org.eclipse.wst.sse.core.undo.IStructuredTextUndoManager;
import org.eclipse.wst.sse.core.util.Assert;
@@ -1040,7 +1041,7 @@ public class BasicStructuredDocument implements IStructuredDocument, IDocumentEx
public ITypedRegion[] computePartitioning(int offset, int length) throws BadLocationException {
ITypedRegion[] typedRegions = null;
try {
- typedRegions = computePartitioning(IStructuredDocument.DEFAULT_STRUCTURED_PARTITIONING, offset, length, false);
+ typedRegions = computePartitioning(IStructuredPartitioning.DEFAULT_STRUCTURED_PARTITIONING, offset, length, false);
}
catch (BadPartitioningException e) {
// impossible in this context
@@ -1067,7 +1068,7 @@ public class BasicStructuredDocument implements IStructuredDocument, IDocumentEx
return ((IDocumentPartitionerExtension2) partitioner).computePartitioning(offset, length, includeZeroLengthPartitions);
else if (partitioner != null)
return partitioner.computePartitioning(offset, length);
- else if (IStructuredDocument.DEFAULT_STRUCTURED_PARTITIONING.equals(partitioning))
+ else if (IStructuredPartitioning.DEFAULT_STRUCTURED_PARTITIONING.equals(partitioning))
return new TypedRegion[]{new TypedRegion(offset, length, DEFAULT_CONTENT_TYPE)};
else
throw new BadPartitioningException();
@@ -1340,7 +1341,7 @@ public class BasicStructuredDocument implements IStructuredDocument, IDocumentEx
return ((IDocumentPartitionerExtension2) partitioner).getContentType(offset, preferOpenPartitions);
else if (partitioner != null)
return partitioner.getContentType(offset);
- else if (IStructuredDocument.DEFAULT_STRUCTURED_PARTITIONING.equals(partitioning))
+ else if (IStructuredPartitioning.DEFAULT_STRUCTURED_PARTITIONING.equals(partitioning))
return DEFAULT_CONTENT_TYPE;
else
throw new BadPartitioningException();
@@ -1400,7 +1401,7 @@ public class BasicStructuredDocument implements IStructuredDocument, IDocumentEx
public String[] getLegalContentTypes() {
String[] result = null;
try {
- result = getLegalContentTypes(IStructuredDocument.DEFAULT_STRUCTURED_PARTITIONING);
+ result = getLegalContentTypes(IStructuredPartitioning.DEFAULT_STRUCTURED_PARTITIONING);
}
catch (BadPartitioningException e) {
// impossible in this context
@@ -1417,7 +1418,7 @@ public class BasicStructuredDocument implements IStructuredDocument, IDocumentEx
IDocumentPartitioner partitioner = getDocumentPartitioner(partitioning);
if (partitioner != null)
return partitioner.getLegalContentTypes();
- if (IStructuredDocument.DEFAULT_STRUCTURED_PARTITIONING.equals(partitioning))
+ if (IStructuredPartitioning.DEFAULT_STRUCTURED_PARTITIONING.equals(partitioning))
return new String[]{DEFAULT_CONTENT_TYPE};
throw new BadPartitioningException();
}
@@ -1562,7 +1563,7 @@ public class BasicStructuredDocument implements IStructuredDocument, IDocumentEx
public ITypedRegion getPartition(int offset) throws BadLocationException {
ITypedRegion partition = null;
try {
- partition = getPartition(IStructuredDocument.DEFAULT_STRUCTURED_PARTITIONING, offset, false);
+ partition = getPartition(IStructuredPartitioning.DEFAULT_STRUCTURED_PARTITIONING, offset, false);
}
catch (BadPartitioningException e) {
throw new Error(e);
@@ -1591,7 +1592,7 @@ public class BasicStructuredDocument implements IStructuredDocument, IDocumentEx
else if (partitioner != null) {
result = partitioner.getPartition(offset);
}
- else if (IStructuredDocument.DEFAULT_STRUCTURED_PARTITIONING.equals(partitioning)) {
+ else if (IStructuredPartitioning.DEFAULT_STRUCTURED_PARTITIONING.equals(partitioning)) {
result = new TypedRegion(0, getLength(), DEFAULT_CONTENT_TYPE);
}
else
diff --git a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/text/rules/StructuredTextPartitioner.java b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/text/rules/StructuredTextPartitioner.java
index 703c04b1aa..ef5c428341 100644
--- a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/text/rules/StructuredTextPartitioner.java
+++ b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/internal/text/rules/StructuredTextPartitioner.java
@@ -27,13 +27,13 @@ import org.eclipse.wst.sse.core.internal.parser.ForeignRegion;
import org.eclipse.wst.sse.core.parser.IBlockedStructuredDocumentRegion;
import org.eclipse.wst.sse.core.text.IStructuredDocument;
import org.eclipse.wst.sse.core.text.IStructuredDocumentRegion;
-import org.eclipse.wst.sse.core.text.IStructuredPartitions;
+import org.eclipse.wst.sse.core.text.IStructuredPartitionTypes;
import org.eclipse.wst.sse.core.text.ITextRegion;
import org.eclipse.wst.sse.core.text.ITextRegionContainer;
import org.eclipse.wst.sse.core.text.ITextRegionList;
import org.eclipse.wst.sse.core.text.SimpleStructuredTypedRegion;
-import org.eclipse.wst.sse.core.text.StructuredRegion;
-import org.eclipse.wst.sse.core.text.StructuredTypedRegion;
+import org.eclipse.wst.sse.core.text.IStructuredRegion;
+import org.eclipse.wst.sse.core.text.IStructuredTypedRegion;
/**
@@ -61,7 +61,7 @@ public class StructuredTextPartitioner implements IDocumentPartitioner {
//public final static String ST_UNKNOWN_PARTITION = IStructuredPartitions.ST_UNKNOWN_PARTITION; //$NON-NLS-1$
private CachedComputedPartitions cachedPartitions = new CachedComputedPartitions(-1, -1, null);
protected String[] fSupportedTypes = null;
- protected StructuredTypedRegion internalReusedTempInstance = new SimpleStructuredTypedRegion(0, 0, IStructuredPartitions.DEFAULT_PARTITION);
+ protected IStructuredTypedRegion internalReusedTempInstance = new SimpleStructuredTypedRegion(0, 0, IStructuredPartitionTypes.DEFAULT_PARTITION);
protected IStructuredDocument structuredDocument;
/**
@@ -111,7 +111,7 @@ public class StructuredTextPartitioner implements IDocumentPartitioner {
return new ITypedRegion[]{createPartition(offset, length, getUnknown())};
}
int currentPos = offset;
- StructuredTypedRegion previousPartition = null;
+ IStructuredTypedRegion previousPartition = null;
while (currentPos < endPos) {
internalGetPartition(currentPos, false);
currentPos += internalReusedTempInstance.getLength();
@@ -125,7 +125,7 @@ public class StructuredTextPartitioner implements IDocumentPartitioner {
previousPartition.setLength(previousPartition.getLength() + internalReusedTempInstance.getLength());
} else {
// not the same, so add to list
- StructuredTypedRegion partition = createNewPartitionInstance();
+ IStructuredTypedRegion partition = createNewPartitionInstance();
list.add(partition);
// and make current, previous
previousPartition = partition;
@@ -136,12 +136,12 @@ public class StructuredTextPartitioner implements IDocumentPartitioner {
}
if (results.length > 0) {
// truncate returned results to requested range
- if (results[0].getOffset() < offset && results[0] instanceof StructuredRegion) {
- ((StructuredRegion) results[0]).setOffset(offset);
+ if (results[0].getOffset() < offset && results[0] instanceof IStructuredRegion) {
+ ((IStructuredRegion) results[0]).setOffset(offset);
}
int lastEnd = results[results.length - 1].getOffset() + results[results.length - 1].getLength();
- if (lastEnd > offset + length && results[results.length - 1] instanceof StructuredRegion) {
- ((StructuredRegion) results[results.length - 1]).setLength(offset + length - results[results.length - 1].getOffset());
+ if (lastEnd > offset + length && results[results.length - 1] instanceof IStructuredRegion) {
+ ((IStructuredRegion) results[results.length - 1]).setLength(offset + length - results[results.length - 1].getOffset());
}
}
cachedPartitions.fLength = length;
@@ -188,7 +188,7 @@ public class StructuredTextPartitioner implements IDocumentPartitioner {
return containsEmbeddedRegion;
}
- private StructuredTypedRegion createNewPartitionInstance() {
+ private IStructuredTypedRegion createNewPartitionInstance() {
return new SimpleStructuredTypedRegion(internalReusedTempInstance.getOffset(), internalReusedTempInstance.getLength(), internalReusedTempInstance.getType());
}
@@ -205,7 +205,7 @@ public class StructuredTextPartitioner implements IDocumentPartitioner {
*
* TODO: should be protected
*/
- public StructuredTypedRegion createPartition(int offset, int length, String type) {
+ public IStructuredTypedRegion createPartition(int offset, int length, String type) {
return new SimpleStructuredTypedRegion(offset, length, type);
}
@@ -268,9 +268,9 @@ public class StructuredTextPartitioner implements IDocumentPartitioner {
/**
* To be used by default!
*/
- public String getDefault() {
+ public String getDefaultPartitionType() {
- return IStructuredPartitions.DEFAULT_PARTITION;
+ return IStructuredPartitionTypes.DEFAULT_PARTITION;
}
/**
@@ -363,7 +363,7 @@ public class StructuredTextPartitioner implements IDocumentPartitioner {
private String getPartitionType(ITextRegion region) {
// if it get's to this "raw" level, then
// must be default.
- return getDefault();
+ return getDefaultPartitionType();
}
/**
@@ -375,7 +375,7 @@ public class StructuredTextPartitioner implements IDocumentPartitioner {
* @return String
*/
protected String getPartitionType(ITextRegion region, int offset) {
- String result = getDefault();
+ String result = getDefaultPartitionType();
// if (region instanceof ContextRegionContainer) {
// result = getPartitionType((ITextRegionContainer) region, offset);
// } else {
@@ -434,8 +434,8 @@ public class StructuredTextPartitioner implements IDocumentPartitioner {
* @param nextEndTagNameRegion
* @return String
*/
- protected String getPartitionTypeBetween(IStructuredDocumentRegion previousNode, ITextRegion previousStartTagNameRegion, IStructuredDocumentRegion nextNode, ITextRegion nextEndTagNameRegion) {
- return getDefault();
+ protected String getPartitionTypeBetween(IStructuredDocumentRegion previousNode, IStructuredDocumentRegion nextNode) {
+ return getDefaultPartitionType();
}
/**
@@ -480,14 +480,14 @@ public class StructuredTextPartitioner implements IDocumentPartitioner {
* about are attempt to partition
*/
protected String getUnknown() {
- return IStructuredPartitions.UNKNOWN_PARTITION;
+ return IStructuredPartitionTypes.UNKNOWN_PARTITION;
}
/**
* to be abstract eventually
*/
protected void initLegalContentTypes() {
- fSupportedTypes = new String[]{IStructuredPartitions.DEFAULT_PARTITION, IStructuredPartitions.UNKNOWN_PARTITION};
+ fSupportedTypes = new String[]{IStructuredPartitionTypes.DEFAULT_PARTITION, IStructuredPartitionTypes.UNKNOWN_PARTITION};
}
/**
@@ -514,7 +514,7 @@ public class StructuredTextPartitioner implements IDocumentPartitioner {
// In order to prevent infinite error loops, this partition must
// never have a zero length
// unless the document is also zero length
- setInternalPartition(offset, 0, getDefault());
+ setInternalPartition(offset, 0, getDefaultPartitionType());
partitionFound = true;
} else if (structuredDocumentRegion == null && docLength != 0) {
// this case is "unusual". When would region be null, and document
diff --git a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/IStructuredDocument.java b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/IStructuredDocument.java
index 4672f9e5d1..89ea205caf 100644
--- a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/IStructuredDocument.java
+++ b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/IStructuredDocument.java
@@ -31,8 +31,6 @@ import org.eclipse.wst.sse.core.undo.IStructuredTextUndoManager;
*/
public interface IStructuredDocument extends IEncodedDocument, IDocumentExtension, IAdaptable {
- String DEFAULT_STRUCTURED_PARTITIONING = "org.eclipse.wst.sse.core.default_structured_text_partitioning";
-
void addDocumentAboutToChangeListener(IModelAboutToBeChangedListener listener);
/**
diff --git a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/IStructuredPartitions.java b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/IStructuredPartitionTypes.java
index b1e761c7ba..9aa339b756 100644
--- a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/IStructuredPartitions.java
+++ b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/IStructuredPartitionTypes.java
@@ -7,10 +7,8 @@ package org.eclipse.wst.sse.core.text;
*
* @since 1.0
*/
-public interface IStructuredPartitions {
+public interface IStructuredPartitionTypes {
- String STRUCTURED_PARTITIONING = "org.eclipse.wst.sse.PARTITIONING"; //$NON-NLS-1$
-
String DEFAULT_PARTITION = "org.eclipse.wst.sse.ST_DEFAULT"; //$NON-NLS-1$
String UNKNOWN_PARTITION = "org.eclipse.wst.sse.UNKNOWN_PARTITION_TYPE"; //$NON-NLS-1$
}
diff --git a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/IStructuredPartitioning.java b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/IStructuredPartitioning.java
new file mode 100644
index 0000000000..3b7c43401a
--- /dev/null
+++ b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/IStructuredPartitioning.java
@@ -0,0 +1,12 @@
+package org.eclipse.wst.sse.core.text;
+
+/**
+ * Identifies the way that Documents are partitioned.
+ *
+ * @since 1.0
+ */
+public interface IStructuredPartitioning {
+
+ /** String to identify default partitioning*/
+ String DEFAULT_STRUCTURED_PARTITIONING = "org.eclipse.wst.sse.core.default_structured_text_partitioning";
+}
diff --git a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/StructuredRegion.java b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/IStructuredRegion.java
index b1face686e..03cac1a5ef 100644
--- a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/StructuredRegion.java
+++ b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/IStructuredRegion.java
@@ -20,7 +20,7 @@ import org.eclipse.jface.text.IRegion;
* Note: There MIGHT be some code that assumes regions are immutable. This
* class would not be appropriate for those uses.
*/
-public interface StructuredRegion extends IRegion {
+public interface IStructuredRegion extends IRegion {
void setLength(int length);
void setOffset(int offset);
diff --git a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/IStructuredTextPartitioner.java b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/IStructuredTextPartitioner.java
index 17a70a466c..4ce3cca9c9 100644
--- a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/IStructuredTextPartitioner.java
+++ b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/IStructuredTextPartitioner.java
@@ -12,36 +12,74 @@
*******************************************************************************/
package org.eclipse.wst.sse.core.text;
-import org.eclipse.jface.text.IDocument;
import org.eclipse.jface.text.IDocumentPartitioner;
/**
- * A partitioner interface required by the StructuredTextPartitionerForJSP for
- * handling the embedded content type properly. This has not yet been
- * finalized.
+ * A partitioner interface required for handling the embedded content type
+ * properly.
+ *
+ * ISSUE: need to investigate necessity of these methods
+ *
+ * @since 1.0
*/
public interface IStructuredTextPartitioner extends IDocumentPartitioner {
- void connect(IDocument document);
/**
- * @deprecated - (dmw) not sure why we needed to make this part of
- * interface ... but probably shouldn't be.
- *
- * (nsd) Used by JSP partitioner to ensure that the partitioner of the
+ * Used by JSP partitioner to ensure that the partitioner of the
* embedded content type gets to create the partition in case the specific
* classes are important.
+ *
+ * ISSUE: investigate if we really need this...
*/
- StructuredTypedRegion createPartition(int offset, int length, String type);
+ IStructuredTypedRegion createPartition(int offset, int length, String partitionType);
- void disconnect();
-
- String getDefault();
-
- String[] getLegalContentTypes();
+ /**
+ * Returns the Default partition type for this partitioner.
+ * <p>
+ * eg:
+ * <br><code>org.eclipse.wst.xml.core.text.IXMLPartitions.XML_DEFAULT</code>
+ * <br><code>org.eclipse.wst.html.core.text.IHTMLPartitions.HTML_DEFAULT</code>
+ * <br><code>org.eclipse.wst.jsp.core.text.IJSPPartitions.JSP_DEFAULT</code>
+ * </p>
+ * @see org.eclipse.wst.sse.core.text.IStructuredPartitionTypes
+ * @see org.eclipse.wst.xml.core.text.IXMLPartitions
+ * @see org.eclipse.wst.html.core.text.IHTMLPartitions
+ * @see org.eclipse.wst.jsp.core.text.IJSPPartitions
+ *
+ * @return the Default partition type for this partitioner.
+ */
+ String getDefaultPartitionType();
+ /**
+ * Returns the particular partition type for the given region/offset.
+ * <p>
+ * eg:
+ * <br><code>org.eclipse.wst.xml.core.text.IXMLPartitions.XML_DEFAULT</code>
+ * <br><code>org.eclipse.wst.html.core.text.IHTMLPartitions.HTML_DEFAULT</code>
+ * <br><code>org.eclipse.wst.jsp.core.text.IJSPPartitions.JSP_DEFAULT</code>
+ * </p>
+ *
+ * @param region of the IStructuredDocument
+ * @param offset in the IStructuredDoucment
+ * @return the particular partition type for the given region/offset.
+ */
String getPartitionType(ITextRegion region, int offset);
- String getPartitionTypeBetween(IStructuredDocumentRegion previousNode, ITextRegion previousStartTagNameRegion, IStructuredDocumentRegion nextNode, ITextRegion nextEndTagNameRegion);
+ /**
+ * Returns the partition type String of the IStructuredDocumentRegion
+ * between the 2 region parameters.
+ * Useful for finding the partition type of a 0 length region.
+ * eg.
+ * <pre>
+ * <script type="text/javascript">|</script>
+ * </pre>
+ * @param previousNode
+ * @param nextNode
+ * @return the partition type of the node between previousNode and nextNode
+ * @deprecated move to IDocumentPartitionerExtension2 ->
+ * String getContentType(int offset, boolean preferOpenPartitions);
+ */
+ String getPartitionTypeBetween(IStructuredDocumentRegion previousNode, IStructuredDocumentRegion nextNode);
}
diff --git a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/StructuredTypedRegion.java b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/IStructuredTypedRegion.java
index e4aee0036b..2e2c6d2ffa 100644
--- a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/StructuredTypedRegion.java
+++ b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/IStructuredTypedRegion.java
@@ -19,6 +19,6 @@ import org.eclipse.jface.text.ITypedRegion;
* type to be set. This is useful when iterating through a number of "small"
* regions, that all map to the the same partion regions.
*/
-public interface StructuredTypedRegion extends StructuredRegion, ITypedRegion {
- void setType(String type);
+public interface IStructuredTypedRegion extends IStructuredRegion, ITypedRegion {
+ void setType(String partitionType);
}
diff --git a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/SimpleStructuredRegion.java b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/SimpleStructuredRegion.java
index 4ab5c4ab30..bb429a92e0 100644
--- a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/SimpleStructuredRegion.java
+++ b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/SimpleStructuredRegion.java
@@ -19,7 +19,7 @@ import org.eclipse.jface.text.IRegion;
/**
* Similar to jface region except we wanted a setting on length
*/
-public class SimpleStructuredRegion implements StructuredRegion {
+public class SimpleStructuredRegion implements IStructuredRegion {
/** The region length */
private int fLength;
diff --git a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/SimpleStructuredTypedRegion.java b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/SimpleStructuredTypedRegion.java
index f4f1117b72..2bf4262ac9 100644
--- a/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/SimpleStructuredTypedRegion.java
+++ b/bundles/org.eclipse.wst.sse.core/src/org/eclipse/wst/sse/core/text/SimpleStructuredTypedRegion.java
@@ -18,7 +18,7 @@ package org.eclipse.wst.sse.core.text;
* Similar jace TypedRegion, but had to subclass our version which allowed
* length to be set.
*/
-public class SimpleStructuredTypedRegion extends SimpleStructuredRegion implements StructuredTypedRegion {
+public class SimpleStructuredTypedRegion extends SimpleStructuredRegion implements IStructuredTypedRegion {
/** The region's type */
private String fType;
diff --git a/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/StructuredTextViewerConfiguration.java b/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/StructuredTextViewerConfiguration.java
index 8e17fc169d..9cd3a1ae99 100644
--- a/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/StructuredTextViewerConfiguration.java
+++ b/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/StructuredTextViewerConfiguration.java
@@ -38,6 +38,7 @@ import org.eclipse.ui.IEditorPart;
import org.eclipse.ui.editors.text.TextSourceViewerConfiguration;
import org.eclipse.ui.texteditor.ITextEditor;
import org.eclipse.wst.sse.core.text.IStructuredDocument;
+import org.eclipse.wst.sse.core.text.IStructuredPartitioning;
import org.eclipse.wst.sse.ui.extension.ExtendedConfigurationBuilder;
import org.eclipse.wst.sse.ui.extension.IExtendedConfiguration;
import org.eclipse.wst.sse.ui.internal.IReleasable;
@@ -160,7 +161,7 @@ public class StructuredTextViewerConfiguration extends TextSourceViewerConfigura
* @see org.eclipse.jface.text.source.SourceViewerConfiguration#getConfiguredDocumentPartitioning(org.eclipse.jface.text.source.ISourceViewer)
*/
public String getConfiguredDocumentPartitioning(ISourceViewer sourceViewer) {
- return IStructuredDocument.DEFAULT_STRUCTURED_PARTITIONING;
+ return IStructuredPartitioning.DEFAULT_STRUCTURED_PARTITIONING;
}
/*
diff --git a/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/extension/FormatProcessorsExtensionReader.java b/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/extension/FormatProcessorsExtensionReader.java
index a89683c642..7dc9553e0f 100644
--- a/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/extension/FormatProcessorsExtensionReader.java
+++ b/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/extension/FormatProcessorsExtensionReader.java
@@ -21,7 +21,7 @@ import org.eclipse.core.runtime.IExtensionRegistry;
import org.eclipse.core.runtime.Platform;
import org.eclipse.core.runtime.content.IContentType;
import org.eclipse.core.runtime.content.IContentTypeManager;
-import org.eclipse.wst.sse.core.format.IStructuredFormatProcessor;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatProcessor;
import org.eclipse.wst.sse.ui.internal.extension.RegistryReader;
import org.osgi.framework.Bundle;
diff --git a/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/format/StructuredFormattingStrategy.java b/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/format/StructuredFormattingStrategy.java
index 2ad356be36..5bfe477614 100644
--- a/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/format/StructuredFormattingStrategy.java
+++ b/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/format/StructuredFormattingStrategy.java
@@ -23,7 +23,7 @@ import org.eclipse.jface.text.formatter.ContextBasedFormattingStrategy;
import org.eclipse.jface.text.formatter.FormattingContextProperties;
import org.eclipse.jface.text.formatter.IFormattingContext;
import org.eclipse.wst.sse.core.exceptions.SourceEditingRuntimeException;
-import org.eclipse.wst.sse.core.format.IStructuredFormatProcessor;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatProcessor;
public class StructuredFormattingStrategy extends ContextBasedFormattingStrategy {
diff --git a/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/internal/SSEUIPluginResources.properties b/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/internal/SSEUIPluginResources.properties
index 48e24a0362..dfc45a3fcf 100644
--- a/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/internal/SSEUIPluginResources.properties
+++ b/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/internal/SSEUIPluginResources.properties
@@ -590,3 +590,4 @@ EOL_NoTranslation=No translation
FileModelProvider.0=Error reloading {0}
JFaceNodeAdapter.0=Update Outline
ShowView.errorTitle=Problems Showing View
+proc_dirty_regions.0 = Processing Dirty Regions \ No newline at end of file
diff --git a/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/internal/actions/FormatActionDelegate.java b/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/internal/actions/FormatActionDelegate.java
index 47f8b2aa26..dbd7796403 100644
--- a/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/internal/actions/FormatActionDelegate.java
+++ b/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/internal/actions/FormatActionDelegate.java
@@ -25,8 +25,8 @@ import org.eclipse.core.runtime.Status;
import org.eclipse.core.runtime.content.IContentDescription;
import org.eclipse.core.runtime.content.IContentType;
import org.eclipse.core.runtime.jobs.Job;
-import org.eclipse.wst.sse.core.format.IStructuredFormatProcessor;
import org.eclipse.wst.sse.core.internal.exceptions.MalformedInputExceptionWithDetail;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatProcessor;
import org.eclipse.wst.sse.ui.extension.FormatProcessorsExtensionReader;
import org.eclipse.wst.sse.ui.internal.Logger;
import org.eclipse.wst.sse.ui.internal.SSEUIPlugin;
diff --git a/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/internal/reconcile/DirtyRegionProcessor.java b/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/internal/reconcile/DirtyRegionProcessor.java
index 6dcde5ece6..98e9e11504 100644
--- a/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/internal/reconcile/DirtyRegionProcessor.java
+++ b/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/internal/reconcile/DirtyRegionProcessor.java
@@ -39,6 +39,7 @@ import org.eclipse.jface.text.reconciler.IReconcilingStrategyExtension;
import org.eclipse.wst.sse.core.events.NewDocumentEvent;
import org.eclipse.wst.sse.core.events.NoChangeEvent;
import org.eclipse.wst.sse.ui.internal.Logger;
+import org.eclipse.wst.sse.ui.internal.SSEUIPlugin;
/**
* This job holds a queue of updates from the editor (DirtyRegions) to
@@ -91,8 +92,9 @@ public class DirtyRegionProcessor extends Job implements IReconciler {
* Creates a new StructuredRegionProcessor
*/
public DirtyRegionProcessor() {
+
// init job stuff
- super("Processing Dirty Regions");
+ super(SSEUIPlugin.getResourceString("%proc_dirty_regions.0"));
setPriority(Job.LONG);
setSystem(true);
// init some fields
diff --git a/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/internal/reconcile/StructuredReconcileStep.java b/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/internal/reconcile/StructuredReconcileStep.java
index e8a7a210d5..a54039bc80 100644
--- a/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/internal/reconcile/StructuredReconcileStep.java
+++ b/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/internal/reconcile/StructuredReconcileStep.java
@@ -30,7 +30,8 @@ import org.eclipse.jface.text.reconciler.IReconcileResult;
import org.eclipse.jface.text.reconciler.IReconcileStep;
import org.eclipse.wst.sse.core.text.IStructuredDocument;
import org.eclipse.wst.sse.core.text.IStructuredDocumentRegion;
-import org.eclipse.wst.sse.core.text.IStructuredPartitions;
+import org.eclipse.wst.sse.core.text.IStructuredPartitionTypes;
+import org.eclipse.wst.sse.core.text.IStructuredPartitioning;
import org.eclipse.wst.sse.ui.internal.IReleasable;
import org.eclipse.wst.sse.ui.internal.Logger;
@@ -89,7 +90,7 @@ public abstract class StructuredReconcileStep extends AbstractReconcileStep impl
public ReconcileAnnotationKey createKey(IStructuredDocumentRegion sdRegion, int scope) {
ITypedRegion tr = getPartition(sdRegion);
- String partitionType = (tr != null) ? tr.getType() : IStructuredPartitions.UNKNOWN_PARTITION;
+ String partitionType = (tr != null) ? tr.getType() : IStructuredPartitionTypes.UNKNOWN_PARTITION;
return createKey(partitionType, scope);
}
@@ -111,7 +112,7 @@ public abstract class StructuredReconcileStep extends AbstractReconcileStep impl
// https://bugs.eclipse.org/bugs/show_bug.cgi?id=86069
if (doc != null) {
try {
- tr = TextUtilities.getPartition(doc, IStructuredDocument.DEFAULT_STRUCTURED_PARTITIONING, offset, false);
+ tr = TextUtilities.getPartition(doc, IStructuredPartitioning.DEFAULT_STRUCTURED_PARTITIONING, offset, false);
} catch (BadLocationException e) {
if (DEBUG)
Logger.logException("problem getting partition at: " + offset, e);
@@ -148,7 +149,7 @@ public abstract class StructuredReconcileStep extends AbstractReconcileStep impl
public String getPartitionType(IDocument doc, int offset) {
ITypedRegion tr = getPartition(doc, offset);
- return (tr != null) ? tr.getType() : IStructuredPartitions.UNKNOWN_PARTITION;
+ return (tr != null) ? tr.getType() : IStructuredPartitionTypes.UNKNOWN_PARTITION;
}
public String[] getPartitionTypes() {
diff --git a/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/internal/ui/OffsetStatusLineContributionItem.java b/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/internal/ui/OffsetStatusLineContributionItem.java
index 9a5b99ccf3..3b50e5d153 100644
--- a/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/internal/ui/OffsetStatusLineContributionItem.java
+++ b/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/internal/ui/OffsetStatusLineContributionItem.java
@@ -63,6 +63,7 @@ import org.eclipse.wst.sse.core.IStructuredModel;
import org.eclipse.wst.sse.core.StructuredModelManager;
import org.eclipse.wst.sse.core.text.IStructuredDocument;
import org.eclipse.wst.sse.core.text.IStructuredDocumentRegion;
+import org.eclipse.wst.sse.core.text.IStructuredPartitioning;
import org.eclipse.wst.sse.core.text.ITextRegion;
import org.eclipse.wst.sse.core.text.ITextRegionCollection;
import org.eclipse.wst.sse.core.text.ITextRegionContainer;
@@ -238,10 +239,10 @@ public class OffsetStatusLineContributionItem extends StatusLineContributionItem
});
try {
String selectedPartitioning = partitioningCombo.getItem(0);
- if (Utilities.contains(partitionings, IStructuredDocument.DEFAULT_STRUCTURED_PARTITIONING)) {
- selectedPartitioning = IStructuredDocument.DEFAULT_STRUCTURED_PARTITIONING;
+ if (Utilities.contains(partitionings, IStructuredPartitioning.DEFAULT_STRUCTURED_PARTITIONING)) {
+ selectedPartitioning = IStructuredPartitioning.DEFAULT_STRUCTURED_PARTITIONING;
for (int i = 0; i < partitionings.length; i++) {
- if (partitionings[i].equals(IStructuredDocument.DEFAULT_STRUCTURED_PARTITIONING)) {
+ if (partitionings[i].equals(IStructuredPartitioning.DEFAULT_STRUCTURED_PARTITIONING)) {
partitioningCombo.select(i);
}
}
diff --git a/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/openon/OpenOnProvider.java b/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/openon/OpenOnProvider.java
index d7d9735789..d0ecc421ec 100644
--- a/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/openon/OpenOnProvider.java
+++ b/bundles/org.eclipse.wst.sse.ui/src/org/eclipse/wst/sse/ui/openon/OpenOnProvider.java
@@ -24,6 +24,7 @@ import org.eclipse.wst.sse.core.IModelManager;
import org.eclipse.wst.sse.core.IStructuredModel;
import org.eclipse.wst.sse.core.StructuredModelManager;
import org.eclipse.wst.sse.core.text.IStructuredDocument;
+import org.eclipse.wst.sse.core.text.IStructuredPartitioning;
import org.eclipse.wst.sse.ui.extensions.openon.IOpenOn;
import org.eclipse.wst.sse.ui.internal.openon.OpenOnBuilder;
import org.eclipse.wst.sse.ui.internal.openon.OpenOnDefinition;
@@ -122,7 +123,7 @@ public class OpenOnProvider {
try {
// TODO: provide partitioning information so we're not using a default like this
if (document instanceof IStructuredDocument) {
- type = TextUtilities.getContentType(document, IStructuredDocument.DEFAULT_STRUCTURED_PARTITIONING, offset, false);
+ type = TextUtilities.getContentType(document, IStructuredPartitioning.DEFAULT_STRUCTURED_PARTITIONING, offset, false);
}
}
catch (BadLocationException e1) {
diff --git a/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/CommentNodeFormatter.java b/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/CommentNodeFormatter.java
index f962f15db6..fe8835b104 100644
--- a/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/CommentNodeFormatter.java
+++ b/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/CommentNodeFormatter.java
@@ -12,7 +12,7 @@
*******************************************************************************/
package org.eclipse.wst.xml.core.format;
-import org.eclipse.wst.sse.core.format.IStructuredFormatContraints;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatContraints;
import org.eclipse.wst.sse.core.util.StringUtils;
import org.eclipse.wst.xml.core.document.XMLNode;
import org.w3c.dom.Node;
diff --git a/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/DocumentNodeFormatter.java b/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/DocumentNodeFormatter.java
index ee671a9925..ea73b78ac0 100644
--- a/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/DocumentNodeFormatter.java
+++ b/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/DocumentNodeFormatter.java
@@ -12,8 +12,8 @@
*******************************************************************************/
package org.eclipse.wst.xml.core.format;
-import org.eclipse.wst.sse.core.format.IStructuredFormatContraints;
-import org.eclipse.wst.sse.core.format.IStructuredFormatter;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatContraints;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatter;
import org.eclipse.wst.xml.core.document.XMLNode;
diff --git a/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/ElementNodeFormatter.java b/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/ElementNodeFormatter.java
index 9434e8f5b5..830ca8aaba 100644
--- a/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/ElementNodeFormatter.java
+++ b/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/ElementNodeFormatter.java
@@ -14,7 +14,7 @@ package org.eclipse.wst.xml.core.format;
import org.eclipse.jface.text.BadLocationException;
import org.eclipse.wst.sse.core.exceptions.SourceEditingRuntimeException;
-import org.eclipse.wst.sse.core.format.IStructuredFormatContraints;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatContraints;
import org.eclipse.wst.sse.core.text.IStructuredDocument;
import org.eclipse.wst.sse.core.text.IStructuredDocumentRegion;
import org.eclipse.wst.sse.core.text.ITextRegion;
diff --git a/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/FormatProcessorXML.java b/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/FormatProcessorXML.java
index 292bde58c4..fd1e453206 100644
--- a/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/FormatProcessorXML.java
+++ b/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/FormatProcessorXML.java
@@ -13,10 +13,10 @@
package org.eclipse.wst.xml.core.format;
import org.eclipse.core.runtime.Preferences;
-import org.eclipse.wst.sse.core.format.AbstractStructuredFormatProcessor;
-import org.eclipse.wst.sse.core.format.IStructuredFormatPreferences;
-import org.eclipse.wst.sse.core.format.IStructuredFormatter;
import org.eclipse.wst.sse.core.internal.SSECorePlugin;
+import org.eclipse.wst.sse.core.internal.format.AbstractStructuredFormatProcessor;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatPreferences;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatter;
import org.eclipse.wst.sse.core.preferences.CommonModelPreferenceNames;
import org.eclipse.wst.xml.core.internal.XMLCorePlugin;
import org.eclipse.wst.xml.core.internal.document.CDATASectionImpl;
diff --git a/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/IStructuredFormatPreferencesXML.java b/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/IStructuredFormatPreferencesXML.java
index bc3faccf25..e5cd452f3e 100644
--- a/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/IStructuredFormatPreferencesXML.java
+++ b/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/IStructuredFormatPreferencesXML.java
@@ -12,7 +12,7 @@
*******************************************************************************/
package org.eclipse.wst.xml.core.format;
-import org.eclipse.wst.sse.core.format.IStructuredFormatPreferences;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatPreferences;
public interface IStructuredFormatPreferencesXML extends IStructuredFormatPreferences {
boolean getSplitMultiAttrs();
diff --git a/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/NodeFormatter.java b/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/NodeFormatter.java
index 79c2c2b333..ad5aa37d83 100644
--- a/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/NodeFormatter.java
+++ b/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/NodeFormatter.java
@@ -16,11 +16,11 @@ import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.core.runtime.Preferences;
import org.eclipse.jface.text.BadLocationException;
import org.eclipse.wst.sse.core.exceptions.SourceEditingRuntimeException;
-import org.eclipse.wst.sse.core.format.IStructuredFormatContraints;
-import org.eclipse.wst.sse.core.format.IStructuredFormatPreferences;
-import org.eclipse.wst.sse.core.format.IStructuredFormatter;
-import org.eclipse.wst.sse.core.format.StructuredFormatContraints;
import org.eclipse.wst.sse.core.internal.SSECorePlugin;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatContraints;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatPreferences;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatter;
+import org.eclipse.wst.sse.core.internal.format.StructuredFormatContraints;
import org.eclipse.wst.sse.core.internal.parser.ContextRegion;
import org.eclipse.wst.sse.core.preferences.CommonModelPreferenceNames;
import org.eclipse.wst.sse.core.text.IStructuredDocument;
diff --git a/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/StructuredFormatPreferencesXML.java b/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/StructuredFormatPreferencesXML.java
index 079ae41c29..77a293a105 100644
--- a/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/StructuredFormatPreferencesXML.java
+++ b/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/StructuredFormatPreferencesXML.java
@@ -12,7 +12,7 @@
*******************************************************************************/
package org.eclipse.wst.xml.core.format;
-import org.eclipse.wst.sse.core.format.StructuredFormatPreferences;
+import org.eclipse.wst.sse.core.internal.format.StructuredFormatPreferences;
public class StructuredFormatPreferencesXML extends StructuredFormatPreferences implements IStructuredFormatPreferencesXML {
private boolean fSplitMultiAttrs;
diff --git a/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/TextNodeFormatter.java b/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/TextNodeFormatter.java
index 9bc4fe1d56..29477216ce 100644
--- a/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/TextNodeFormatter.java
+++ b/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/format/TextNodeFormatter.java
@@ -17,7 +17,7 @@ import java.util.Vector;
import org.eclipse.jface.text.BadLocationException;
import org.eclipse.wst.sse.core.exceptions.SourceEditingRuntimeException;
-import org.eclipse.wst.sse.core.format.IStructuredFormatContraints;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatContraints;
import org.eclipse.wst.sse.core.text.IStructuredDocument;
import org.eclipse.wst.sse.core.util.StringUtils;
import org.eclipse.wst.xml.core.document.XMLNode;
diff --git a/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/internal/cleanup/CleanupProcessorXML.java b/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/internal/cleanup/CleanupProcessorXML.java
index 6d12e091e3..51b206aa50 100644
--- a/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/internal/cleanup/CleanupProcessorXML.java
+++ b/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/internal/cleanup/CleanupProcessorXML.java
@@ -13,11 +13,11 @@
package org.eclipse.wst.xml.core.internal.cleanup;
import org.eclipse.core.runtime.Preferences;
-import org.eclipse.wst.sse.core.format.IStructuredFormatProcessor;
import org.eclipse.wst.sse.core.internal.cleanup.AbstractStructuredCleanupProcessor;
import org.eclipse.wst.sse.core.internal.cleanup.IStructuredCleanupHandler;
import org.eclipse.wst.sse.core.internal.cleanup.IStructuredCleanupPreferences;
import org.eclipse.wst.sse.core.internal.cleanup.StructuredCleanupPreferences;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatProcessor;
import org.eclipse.wst.sse.core.preferences.CommonModelPreferenceNames;
import org.eclipse.wst.xml.core.contenttype.ContentTypeIdForXML;
import org.eclipse.wst.xml.core.format.FormatProcessorXML;
diff --git a/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/internal/text/rules/StructuredTextPartitionerForXML.java b/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/internal/text/rules/StructuredTextPartitionerForXML.java
index cc6000f74c..e74f4f00de 100644
--- a/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/internal/text/rules/StructuredTextPartitionerForXML.java
+++ b/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/internal/text/rules/StructuredTextPartitionerForXML.java
@@ -26,9 +26,6 @@ public class StructuredTextPartitionerForXML extends StructuredTextPartitioner i
private final static String[] configuredContentTypes = new String[]{IXMLPartitions.XML_DEFAULT, IXMLPartitions.XML_CDATA, IXMLPartitions.XML_PI, IXMLPartitions.XML_DECLARATION, IXMLPartitions.XML_COMMENT, IXMLPartitions.DTD_SUBSET};
- /**
- * Constructor for JSPDocumentPartioner.
- */
public StructuredTextPartitionerForXML() {
super();
}
@@ -66,11 +63,11 @@ public class StructuredTextPartitionerForXML extends StructuredTextPartitioner i
return super.getPartitionType(region, offset);
}
- public String getPartitionTypeBetween(IStructuredDocumentRegion previousNode, ITextRegion previousStartTagNameRegion, IStructuredDocumentRegion nextNode, ITextRegion nextEndTagNameRegion) {
- return super.getPartitionTypeBetween(previousNode, previousStartTagNameRegion, nextNode, nextEndTagNameRegion);
+ public String getPartitionTypeBetween(IStructuredDocumentRegion previousNode, IStructuredDocumentRegion nextNode) {
+ return super.getPartitionTypeBetween(previousNode, nextNode);
}
- public String getDefault() {
+ public String getDefaultPartitionType() {
return IXMLPartitions.XML_DEFAULT;
}
@@ -115,7 +112,7 @@ public class StructuredTextPartitionerForXML extends StructuredTextPartitioner i
ITextRegion previousName = previousStructuredDocumentRegion.getRegionAtCharacterOffset(previousStructuredDocumentRegion.getEndOffset(previousStart));
ITextRegion nextName = sdRegion.getRegionAtCharacterOffset(sdRegion.getEndOffset(next));
if (previousName != null && nextName != null && previousName.getType() == XMLRegionContext.XML_TAG_NAME && nextName.getType() == XMLRegionContext.XML_TAG_NAME) {
- setInternalPartition(offset, 0, getPartitionTypeBetween(previousStructuredDocumentRegion, previousName, sdRegion, nextName));
+ setInternalPartition(offset, 0, getPartitionTypeBetween(previousStructuredDocumentRegion, sdRegion));
partitionFound = true;
}
}
diff --git a/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/text/IXMLPartitions.java b/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/text/IXMLPartitions.java
index 78a5219297..d4ede16440 100644
--- a/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/text/IXMLPartitions.java
+++ b/bundles/org.eclipse.wst.xml.core/src/org/eclipse/wst/xml/core/text/IXMLPartitions.java
@@ -1,19 +1,16 @@
package org.eclipse.wst.xml.core.text;
-import org.eclipse.wst.sse.core.text.IStructuredPartitions;
/**
* This interface is not intended to be implemented.
- * It defines the partitioning for XML and all its partitions.
+ * It defines the partition types for XML.
* Clients should reference the partition type Strings defined here directly.
*
* @since 1.0
*/
public interface IXMLPartitions {
- String XML_PARTITIONING = IStructuredPartitions.STRUCTURED_PARTITIONING;
-
String XML_DEFAULT = "org.eclipse.wst.xml.XML_DEFAULT"; //$NON-NLS-1$
String XML_CDATA = "org.eclipse.wst.xml.XML_CDATA"; //$NON-NLS-1$
String XML_PI = "org.eclipse.wst.xml.XML_PI"; //$NON-NLS-1$
diff --git a/bundles/org.eclipse.wst.xml.ui/src/org/eclipse/wst/xml/ui/StructuredTextViewerConfigurationXML.java b/bundles/org.eclipse.wst.xml.ui/src/org/eclipse/wst/xml/ui/StructuredTextViewerConfigurationXML.java
index aa45193170..443c3141fc 100644
--- a/bundles/org.eclipse.wst.xml.ui/src/org/eclipse/wst/xml/ui/StructuredTextViewerConfigurationXML.java
+++ b/bundles/org.eclipse.wst.xml.ui/src/org/eclipse/wst/xml/ui/StructuredTextViewerConfigurationXML.java
@@ -36,7 +36,7 @@ import org.eclipse.ui.texteditor.AbstractDecoratedTextEditorPreferenceConstants;
import org.eclipse.ui.texteditor.ITextEditor;
import org.eclipse.wst.sse.core.IStructuredModel;
import org.eclipse.wst.sse.core.StructuredModelManager;
-import org.eclipse.wst.sse.core.text.IStructuredPartitions;
+import org.eclipse.wst.sse.core.text.IStructuredPartitionTypes;
import org.eclipse.wst.sse.ui.StructuredTextViewerConfiguration;
import org.eclipse.wst.sse.ui.format.StructuredFormattingStrategy;
import org.eclipse.wst.sse.ui.internal.StructuredTextEditor;
@@ -102,8 +102,8 @@ public class StructuredTextViewerConfigurationXML extends StructuredTextViewerCo
if (configuredContentTypes == null) {
String[] xmlTypes = StructuredTextPartitionerForXML.getConfiguredContentTypes();
configuredContentTypes = new String[xmlTypes.length + 2];
- configuredContentTypes[0] = IStructuredPartitions.DEFAULT_PARTITION;
- configuredContentTypes[1] = IStructuredPartitions.UNKNOWN_PARTITION;
+ configuredContentTypes[0] = IStructuredPartitionTypes.DEFAULT_PARTITION;
+ configuredContentTypes[1] = IStructuredPartitionTypes.UNKNOWN_PARTITION;
int index = 0;
System.arraycopy(xmlTypes, 0, configuredContentTypes, index += 2, xmlTypes.length);
}
@@ -117,9 +117,9 @@ public class StructuredTextViewerConfigurationXML extends StructuredTextViewerCo
ContentAssistant contentAssistant = (ContentAssistant) ca;
IContentAssistProcessor xmlContentAssistProcessor = new XMLContentAssistProcessor();
IContentAssistProcessor noRegionProcessor = new NoRegionContentAssistProcessor();
- setContentAssistProcessor(contentAssistant, xmlContentAssistProcessor, IStructuredPartitions.DEFAULT_PARTITION);
+ setContentAssistProcessor(contentAssistant, xmlContentAssistProcessor, IStructuredPartitionTypes.DEFAULT_PARTITION);
setContentAssistProcessor(contentAssistant, xmlContentAssistProcessor, IXMLPartitions.XML_DEFAULT);
- setContentAssistProcessor(contentAssistant, noRegionProcessor, IStructuredPartitions.UNKNOWN_PARTITION);
+ setContentAssistProcessor(contentAssistant, noRegionProcessor, IStructuredPartitionTypes.UNKNOWN_PARTITION);
}
return ca;
}
@@ -180,7 +180,7 @@ public class StructuredTextViewerConfigurationXML extends StructuredTextViewerCo
if (fInformationPresenter == null) {
fInformationPresenter = new InformationPresenter(getInformationPresenterControlCreator(sourceViewer));
IInformationProvider xmlInformationProvider = new XMLInformationProvider();
- fInformationPresenter.setInformationProvider(xmlInformationProvider, IStructuredPartitions.DEFAULT_PARTITION);
+ fInformationPresenter.setInformationProvider(xmlInformationProvider, IStructuredPartitionTypes.DEFAULT_PARTITION);
fInformationPresenter.setInformationProvider(xmlInformationProvider, IXMLPartitions.XML_DEFAULT);
fInformationPresenter.setSizeConstraints(60, 10, true, true);
}
@@ -241,7 +241,7 @@ public class StructuredTextViewerConfigurationXML extends StructuredTextViewerCo
public ITextHover getTextHover(ISourceViewer sourceViewer, String contentType, int stateMask) {
// look for appropriate text hover processor to return based on
// content type and state mask
- if ((contentType == IStructuredPartitions.DEFAULT_PARTITION) || (contentType == IXMLPartitions.XML_DEFAULT)) {
+ if ((contentType == IStructuredPartitionTypes.DEFAULT_PARTITION) || (contentType == IXMLPartitions.XML_DEFAULT)) {
// check which of xml's text hover is handling stateMask
TextHoverManager.TextHoverDescriptor[] hoverDescs = getTextHovers();
int i = 0;
diff --git a/bundles/org.eclipse.wst.xml.ui/src/org/eclipse/wst/xml/ui/internal/XMLUIPluginResources.properties b/bundles/org.eclipse.wst.xml.ui/src/org/eclipse/wst/xml/ui/internal/XMLUIPluginResources.properties
index 9179545989..fbf6661027 100644
--- a/bundles/org.eclipse.wst.xml.ui/src/org/eclipse/wst/xml/ui/internal/XMLUIPluginResources.properties
+++ b/bundles/org.eclipse.wst.xml.ui/src/org/eclipse/wst/xml/ui/internal/XMLUIPluginResources.properties
@@ -220,3 +220,4 @@ QuickFixProcessorXML.16=Remove this attribute and its value
XMLPropertySourceAdapter.0=Attributes
WorkbenchDefaultEncodingSettings.0=Use workbench encoding
+refreshoutline.0=Refreshing Outline
diff --git a/bundles/org.eclipse.wst.xml.ui/src/org/eclipse/wst/xml/ui/internal/contentoutline/XMLNodeActionManager.java b/bundles/org.eclipse.wst.xml.ui/src/org/eclipse/wst/xml/ui/internal/contentoutline/XMLNodeActionManager.java
index ff815f7a5c..dea8ad1151 100644
--- a/bundles/org.eclipse.wst.xml.ui/src/org/eclipse/wst/xml/ui/internal/contentoutline/XMLNodeActionManager.java
+++ b/bundles/org.eclipse.wst.xml.ui/src/org/eclipse/wst/xml/ui/internal/contentoutline/XMLNodeActionManager.java
@@ -14,7 +14,7 @@ package org.eclipse.wst.xml.ui.internal.contentoutline;
import org.eclipse.jface.viewers.Viewer;
import org.eclipse.wst.sse.core.IStructuredModel;
-import org.eclipse.wst.sse.core.format.IStructuredFormatProcessor;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatProcessor;
import org.eclipse.wst.xml.core.format.FormatProcessorXML;
import org.eclipse.wst.xml.core.internal.contentmodel.modelquery.ModelQuery;
import org.eclipse.wst.xml.core.internal.modelquery.ModelQueryUtil;
diff --git a/bundles/org.eclipse.wst.xml.ui/src/org/eclipse/wst/xml/ui/internal/correction/SurroundWithNewElementQuickAssistProposal.java b/bundles/org.eclipse.wst.xml.ui/src/org/eclipse/wst/xml/ui/internal/correction/SurroundWithNewElementQuickAssistProposal.java
index 9e510030ab..154392d802 100644
--- a/bundles/org.eclipse.wst.xml.ui/src/org/eclipse/wst/xml/ui/internal/correction/SurroundWithNewElementQuickAssistProposal.java
+++ b/bundles/org.eclipse.wst.xml.ui/src/org/eclipse/wst/xml/ui/internal/correction/SurroundWithNewElementQuickAssistProposal.java
@@ -19,7 +19,7 @@ import org.eclipse.text.edits.InsertEdit;
import org.eclipse.text.edits.MalformedTreeException;
import org.eclipse.text.edits.MultiTextEdit;
import org.eclipse.wst.sse.core.exceptions.SourceEditingRuntimeException;
-import org.eclipse.wst.sse.core.format.IStructuredFormatProcessor;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatProcessor;
import org.eclipse.wst.sse.ui.internal.StructuredTextViewer;
import org.eclipse.wst.sse.ui.internal.contentassist.ContentAssistUtils;
import org.eclipse.wst.xml.core.document.XMLNode;
diff --git a/bundles/org.eclipse.wst.xsd.ui/src/org/eclipse/wst/xsd/ui/internal/actions/CreateAttributeAndRequired.java b/bundles/org.eclipse.wst.xsd.ui/src/org/eclipse/wst/xsd/ui/internal/actions/CreateAttributeAndRequired.java
index 6a634e2b88..122da07156 100644
--- a/bundles/org.eclipse.wst.xsd.ui/src/org/eclipse/wst/xsd/ui/internal/actions/CreateAttributeAndRequired.java
+++ b/bundles/org.eclipse.wst.xsd.ui/src/org/eclipse/wst/xsd/ui/internal/actions/CreateAttributeAndRequired.java
@@ -15,7 +15,7 @@ import java.util.List;
import org.eclipse.jface.action.Action;
import org.eclipse.jface.viewers.ISelectionProvider;
import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.wst.sse.core.format.IStructuredFormatProcessor;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatProcessor;
import org.eclipse.wst.xml.core.document.XMLModel;
import org.eclipse.wst.xml.core.document.XMLNode;
import org.eclipse.wst.xml.core.format.FormatProcessorXML;
diff --git a/bundles/org.eclipse.wst.xsd.ui/src/org/eclipse/wst/xsd/ui/internal/actions/CreateElementAction.java b/bundles/org.eclipse.wst.xsd.ui/src/org/eclipse/wst/xsd/ui/internal/actions/CreateElementAction.java
index 3190d532b7..fb9f00fba3 100644
--- a/bundles/org.eclipse.wst.xsd.ui/src/org/eclipse/wst/xsd/ui/internal/actions/CreateElementAction.java
+++ b/bundles/org.eclipse.wst.xsd.ui/src/org/eclipse/wst/xsd/ui/internal/actions/CreateElementAction.java
@@ -18,7 +18,7 @@ import org.eclipse.jface.resource.ImageDescriptor;
import org.eclipse.jface.viewers.ISelectionProvider;
import org.eclipse.jface.viewers.StructuredSelection;
import org.eclipse.swt.widgets.Display;
-import org.eclipse.wst.sse.core.format.IStructuredFormatProcessor;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatProcessor;
import org.eclipse.wst.xml.core.document.XMLModel;
import org.eclipse.wst.xml.core.document.XMLNode;
import org.eclipse.wst.xml.core.format.FormatProcessorXML;
diff --git a/bundles/org.eclipse.wst.xsd.ui/src/org/eclipse/wst/xsd/ui/internal/actions/SetBaseTypeAction.java b/bundles/org.eclipse.wst.xsd.ui/src/org/eclipse/wst/xsd/ui/internal/actions/SetBaseTypeAction.java
index 27bbabbee7..78ed454a95 100644
--- a/bundles/org.eclipse.wst.xsd.ui/src/org/eclipse/wst/xsd/ui/internal/actions/SetBaseTypeAction.java
+++ b/bundles/org.eclipse.wst.xsd.ui/src/org/eclipse/wst/xsd/ui/internal/actions/SetBaseTypeAction.java
@@ -18,7 +18,7 @@ import org.eclipse.jface.resource.ImageDescriptor;
import org.eclipse.jface.window.Window;
import org.eclipse.swt.widgets.Display;
import org.eclipse.swt.widgets.Shell;
-import org.eclipse.wst.sse.core.format.IStructuredFormatProcessor;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatProcessor;
import org.eclipse.wst.xml.core.document.XMLModel;
import org.eclipse.wst.xml.core.document.XMLNode;
import org.eclipse.wst.xml.core.format.FormatProcessorXML;
diff --git a/bundles/org.eclipse.wst.xsd.ui/src/org/eclipse/wst/xsd/ui/internal/commands/AbstractCommand.java b/bundles/org.eclipse.wst.xsd.ui/src/org/eclipse/wst/xsd/ui/internal/commands/AbstractCommand.java
index 9d8c0a1e09..7d0a84e662 100644
--- a/bundles/org.eclipse.wst.xsd.ui/src/org/eclipse/wst/xsd/ui/internal/commands/AbstractCommand.java
+++ b/bundles/org.eclipse.wst.xsd.ui/src/org/eclipse/wst/xsd/ui/internal/commands/AbstractCommand.java
@@ -10,7 +10,7 @@
*******************************************************************************/
package org.eclipse.wst.xsd.ui.internal.commands;
-import org.eclipse.wst.sse.core.format.IStructuredFormatProcessor;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatProcessor;
import org.eclipse.wst.xml.core.document.XMLModel;
import org.eclipse.wst.xml.core.document.XMLNode;
import org.eclipse.wst.xml.core.format.FormatProcessorXML;
diff --git a/bundles/org.eclipse.wst.xsd.ui/src/org/eclipse/wst/xsd/ui/internal/util/XSDDOMHelper.java b/bundles/org.eclipse.wst.xsd.ui/src/org/eclipse/wst/xsd/ui/internal/util/XSDDOMHelper.java
index 4c84c36412..e0835b28f6 100644
--- a/bundles/org.eclipse.wst.xsd.ui/src/org/eclipse/wst/xsd/ui/internal/util/XSDDOMHelper.java
+++ b/bundles/org.eclipse.wst.xsd.ui/src/org/eclipse/wst/xsd/ui/internal/util/XSDDOMHelper.java
@@ -10,7 +10,7 @@
*******************************************************************************/
package org.eclipse.wst.xsd.ui.internal.util;
-import org.eclipse.wst.sse.core.format.IStructuredFormatProcessor;
+import org.eclipse.wst.sse.core.internal.format.IStructuredFormatProcessor;
import org.eclipse.wst.xml.core.document.XMLModel;
import org.eclipse.wst.xml.core.document.XMLNode;
import org.eclipse.wst.xml.core.format.FormatProcessorXML;

Back to the top