public class ExtensionXMIViewModelProvider extends Object implements IFilteredViewProvider
IViewProvider
which loads view models from extension points.NOT_APPLICABLE
Constructor and Description |
---|
ExtensionXMIViewModelProvider() |
Modifier and Type | Method and Description |
---|---|
double |
canProvideViewModel(org.eclipse.emf.ecore.EObject eObject,
VViewModelProperties properties,
Collection<String> requiredKeys)
Queries the confidence with which I can provide a view model for the given domain model
object where some keys in the properties are required to be matched in
an implementation-specific way by the view models the I have access to. |
VView |
provideViewModel(org.eclipse.emf.ecore.EObject eObject,
VViewModelProperties properties,
Collection<String> requiredKeys)
Obtains the view model that I can
provide
for the given domain model
object . |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
canProvideViewModel, provideViewModel
public double canProvideViewModel(org.eclipse.emf.ecore.EObject eObject, VViewModelProperties properties, Collection<String> requiredKeys)
IFilteredViewProvider
object
where some keys in the properties
are required to be matched in
an implementation-specific way by the view models the I have access to.canProvideViewModel
in interface IFilteredViewProvider
eObject
- the domain model object for which a view is to be requestedproperties
- the properties
for providing the view, that
may or may not include matching filtersrequiredKeys
- a subset (possibly empty) of the keys in the properties
that
must be matched by any view model that I would provide. If any of these keys does not match
a view model, then that view model must not be provided. Otherwise, it may just be less
preferred than some other view model that does matchVView
for the given object
, or
IViewProvider.NOT_APPLICABLE
if I cannot provide a view modelpublic VView provideViewModel(org.eclipse.emf.ecore.EObject eObject, VViewModelProperties properties, Collection<String> requiredKeys)
IFilteredViewProvider
object
. This method is only called if a previous invocation of
IFilteredViewProvider.canProvideViewModel(EObject, VViewModelProperties, Collection)
with the same arguments
returned the highest positive result amongst all available providers.provideViewModel
in interface IFilteredViewProvider
eObject
- the domain model object for which a view is to be requestedproperties
- the properties
for providing the view, that
may or may not include matching filtersrequiredKeys
- a subset (possibly empty) of the keys in the properties
that
must be matched by any view model that I would provide. If any of these keys does not match
a view model, then that view model must not be provided. Otherwise, it may just be less
preferred than some other view model that does matchCopyright © 2019. All rights reserved.