Interface ILanguageSettingsEditableProvider
- All Superinterfaces:
Cloneable
,ILanguageSettingsBroadcastingProvider
,ILanguageSettingsProvider
- All Known Implementing Classes:
LanguageSettingsGenericProvider
public interface ILanguageSettingsEditableProvider
extends ILanguageSettingsBroadcastingProvider, Cloneable
This interface is used in UI to identify classes allowing user to modify settings externally
contrary to some subclasses of
LanguageSettingsSerializableProvider
managing
their settings themselves and not providing such option to the user.- Since:
- 5.4
-
Method Summary
Modifier and TypeMethodDescriptionclone()
Shallow clone of the provider.getId()
Id is used to keep track of the providers internally.getName()
Name is used to present the provider to the end user in UI.getSettingEntries
(ICConfigurationDescription cfgDescription, org.eclipse.core.resources.IResource rc, String languageId) Returns the list of setting entries for the given configuration description, resource and language.void
setSettingEntries
(ICConfigurationDescription cfgDescription, org.eclipse.core.resources.IResource rc, String languageId, List<? extends ICLanguageSettingEntry> entries) Sets language settings entries for the provider.Methods inherited from interface org.eclipse.cdt.core.language.settings.providers.ILanguageSettingsBroadcastingProvider
copyStorage
-
Method Details
-
getId
String getId()Description copied from interface:ILanguageSettingsProvider
Id is used to keep track of the providers internally. Use unique id to represent the provider.- Specified by:
getId
in interfaceILanguageSettingsBroadcastingProvider
- Specified by:
getId
in interfaceILanguageSettingsProvider
- Returns:
- Id of the provider.
-
getName
String getName()Description copied from interface:ILanguageSettingsProvider
Name is used to present the provider to the end user in UI.- Specified by:
getName
in interfaceILanguageSettingsBroadcastingProvider
- Specified by:
getName
in interfaceILanguageSettingsProvider
- Returns:
- name of the provider.
-
getSettingEntries
List<ICLanguageSettingEntry> getSettingEntries(ICConfigurationDescription cfgDescription, org.eclipse.core.resources.IResource rc, String languageId) Description copied from interface:ILanguageSettingsProvider
Returns the list of setting entries for the given configuration description, resource and language.
Note to implementers - this method should not be used to do any long running operations such as extensive calculations or reading files. If you need to do so, the recommended way is to do the calculations outside of this function call - in advance and on appropriate event. For example, Build Output Parser prepares the list and stores it in internal cache while parsing output.ILanguageSettingsProvider.getSettingEntries(ICConfigurationDescription, IResource, String)
will return cached entries when asked. You can also implementICListenerAgent
interface to get registered and listen to arbitrary events.- Specified by:
getSettingEntries
in interfaceILanguageSettingsBroadcastingProvider
- Specified by:
getSettingEntries
in interfaceILanguageSettingsProvider
- Parameters:
cfgDescription
- - configuration description.rc
- - resource such as file or folder. Ifnull
, the default entries for all resources are returned.languageId
- - language id. Ifnull
, the default entries for all languages are returned. (seeLanguageManager.getLanguageForFile(org.eclipse.core.resources.IFile, ICConfigurationDescription)
).- Returns:
- the list of setting entries or
null
if no settings defined. The list needs to be a pooled list created byLanguageSettingsStorage.getPooledList(List)
to save memory and avoid deep equality comparisons.
-
setSettingEntries
void setSettingEntries(ICConfigurationDescription cfgDescription, org.eclipse.core.resources.IResource rc, String languageId, List<? extends ICLanguageSettingEntry> entries) Sets language settings entries for the provider.- Parameters:
cfgDescription
- - configuration description.rc
- - resource such as file or folder. Ifnull
the entries are considered to be being defined as default entries for resources.languageId
- - language id. Ifnull
, then entries are considered to be defined as default entries for languages.entries
- - language settings entries to set.
-
cloneShallow
Shallow clone of the provider. "Shallow" is defined here as the exact copy except that the copy will have zero language settings entries.- Returns:
- shallow copy of the provider.
- Throws:
CloneNotSupportedException
- in caseclone()
throws the exception.
-
clone
- Throws:
CloneNotSupportedException
-