Editor Configuration Migration
structured source editing (sse) component
Date Revision info
9/19/2005 Updated migration info for StructuredTextViewerConfiguration#setDeclaringID
9/07/2005 Initial contribution
 
Overview
 

This document is for clients who are already using the provisional extendedconfiguration extension point and StructuredTextViewerConfiguration

Migration Table
 
Code Old Code New Code
editor configuration extension point
<extension point="org.eclipse.wst.sse.ui.extendedconfiguration">
<extension point="org.eclipse.wst.sse.ui.editorConfiguration">
<configuration
	type="textviewerconfiguration"
	class=".."
	target="..." />
<sourceViewerConfiguration
	class=".."
	target="..." />
<configuration
      type="contentoutlineconfiguration"
      class=".."
      target="..." />
<contentOutlineConfiguration
	class=".."
	target="..." />
<configuration
	type="propertysheetconfiguration"
	class=".."
	target="..." />
<propertySheetConfiguration
	class=".."
	target="..." />
<configuration
	type=".."
	class=".."
	target="..." />
<provisionalConfiguration
	type=".."
	class=".."
	target="..." />
<definition
	type=".."
	value=".."
	target="..." />
<provisionalDefinition
	type=".."
	value=".."
	target="..." />
StructuredTextViewerConfiguration and its subclasses
StructuredTextViewerConfiguration field variables
STVC#configuredContentTypes located in STVC moved to subclass
STVC#fCorrectionAssistant located in STVC moved to subclass
STVC#fReconciler located in STVC moved to subclass
STVC#editorPart located in STVC deleted since it did not look like it was really needed
STVC#fHighlighter located in STVC deleted since getHighlighter was replaced by getLineStyleProviders
STVC#fResource located in STVC deleted since it did not look like it was really needed
STVC#SSE_EDITOR_ID located in STVC deleted since it did not look like it was really needed
STVC#SSE_MODEL_ID located in STVC deleted since it did not look like it was really needed
STVC#ID located in STVC deleted and moved to ExtendedConfigurationBuilder#SOURCEVIEWERCONFIGURATION
STVC#setDeclaringID located in STVC deleted and replaced through setInitializationData (STVC now implements IExecutableExtension and by doing so, initialization data is set automatically)
StructuredTextViewerConfiguration preferences/editor
STVC's preference store (constructor, fPreferenceStore, setPreferenceStore() set the preference store in STVC by either passing in a preference store in the constructor or calling setPreferenceStore. no longer way to set the preference store in STVC. By default, the preference store is the same one used in StructuredTextEditor
STVC#setEditorPart set editor part for configuration deleted because it was not really needed
StructuredTextViewerConfiguration Content Assist
STVC#setContentAssistProcessor(IContentAssistant, IContentAssistProcessor, partitionType) adds contentassistprocessor to content assist for partition type and keeps list of content assist processors added in fContentAssistProcessors deleted (just call setContentAssistProcessor directly on contentassistant)
STVC#configureOn()/updateForResource() updates all content assist processors with new IResource deleted (if you need resource, get it from the document that's in textviewer which is passed in when you compute)
STVC#unConfigure() releases any content assist processors that need releasing deleted (content assistant will handle disposing of content assist processors)
StructuredTextViewerConfiguration Highlighter
STVC#getHighlighter() creates default IHighlighter with intitial setup deleted (Highlighter is now created in StructuredTextViewer and getLineStyleProviders is called to get specific line style providers)
subclass#getHighlighter() calls super.getHighlighter; adds necessary line style providers to Highlighter deleted (replaced by getLineStyleProviders)
STVC#getLineStyleProviders(ISourceViewer sourceViewer, String partitionType) didnt exist returns null
subclass#getLineStyleProviders(ISourceViewer sourceViewer, String partitionType) didnt exist return list of line style providers applicable to partition type
StructuredTextViewerConfiguration Reconciler
STVC#createValidatorStrategy() creates extensible validator strategy to be used by reconciler created by subclasses deleted (code was moved into reconciler so it knows to create extensible validator strategy)
STVC#unConfigure() uninstall reconciler StructuredTextViewer uninstalls reconciler
StructuredTextViewerConfiguration Text Hover/InformationControlCreator/InformationPresenterControlCreator
STVC#getTextHovers() returns a list of all text hovers for StructuredTextEditors deleted
STVC#getInformationPresenterControlCreator() returns an informationpresentercontrolcreator to be used in getInformationPresenter deleted
subclass#getTextHover() call getTextHovers() to retrieve all text hovers and figure out which one to use call SSEUIPlugin.getDefault().getTextHoverManager().getTextHovers() to get list of hovers
subclass#getInformationPresenter() call getInformationPresenterControlCreator to get the control creator to use with the information presenter copy deleted getInformationPresenterControlCreator to your own subclass
StructuredTextViewerConfiguration Correction Assist
STVC#getCorrectionAssistant() super creates correction assistant with initialization then subclass would add necessary processors super returns null, subclass needs to create new instance, initialize, add processors