public class QuickDiff extends Object
This class may be instantiated, it is not intended to be subclassed.
Constructor and Description |
---|
QuickDiff()
Creates a new instance.
|
Modifier and Type | Method and Description |
---|---|
IAnnotationModel |
createQuickDiffAnnotationModel(ITextEditor editor,
String id)
Creates a new line differ annotation model with its reference provider set to the reference provider
obtained by calling
getReferenceProviderOrDefault(editor, id) . |
Object |
getConfiguredQuickDiffProvider(IAnnotationModel differ)
Returns the identifier of the quick diff provider installed with the given diff annotation
model, or the empty string if it is not a diff annotation model or has no configured diff
provider.
|
ReferenceProviderDescriptor |
getDefaultProvider()
Returns the descriptor of the "last saved version" reference provider.
|
List |
getReferenceProviderDescriptors()
Returns a non-modifiable list of
ReferenceProviderDescriptor describing all extension
to the quickDiffReferenceProvider extension point. |
IQuickDiffReferenceProvider |
getReferenceProviderOrDefault(ITextEditor editor,
String id)
Returns the quick diff reference provider registered under
id , or the default
reference provider. |
public ReferenceProviderDescriptor getDefaultProvider()
Clients should not cache this value because it can change when plug-ins get dynamically added or removed.
null
if nonepublic List getReferenceProviderDescriptors()
ReferenceProviderDescriptor
describing all extension
to the quickDiffReferenceProvider
extension point.
Clients should not cache this list because it can change when plug-ins get dynamically added or removed.
quickDiffReferenceProvider
extension point.public IQuickDiffReferenceProvider getReferenceProviderOrDefault(ITextEditor editor, String id)
id
, or the default
reference provider. The returned provider gets its editor set to editor
. If neither
the requested provider nor the default provider return true
from isEnabled
after
having the editor set, null
is returned.
Clients should not cache this value because it can change when plug-ins get dynamically added or removed.
editor
- the editor to be installed with the returned providerid
- the id as specified in the plugin.xml
that installs the reference providerid
, or the default reference provider, or null
public IAnnotationModel createQuickDiffAnnotationModel(ITextEditor editor, String id)
getReferenceProviderOrDefault(editor, id)
.editor
- the editor to be installed with the returned providerid
- the id as specified in the plugin.xml
that installs the reference providerpublic Object getConfiguredQuickDiffProvider(IAnnotationModel differ)
differ
- a diff annotation model
Copyright (c) 2000, 2014 Eclipse Contributors and others. All rights reserved.Guidelines for using Eclipse APIs.