Interface ViewTemplateSupplier
-
- All Known Implementing Classes:
ViewTemplateSupplierImpl
public interface ViewTemplateSupplier
AViewTemplateSupplier
collects and provides any number ofVTViewTemplates
.This interface may be implemented by clients to implement custom logic to provide VTViewTemplates and/or
VTStyleProperties
for givenVElements
.- Since:
- 1.18
- Author:
- Lucas Koehler
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.util.Map<VTStyleProperty,java.lang.Double>
getStyleProperties(VElement vElement, ViewModelContext viewModelContext)
Return allStyleProperties
which are applicable to the providedVElement
.java.util.Set<VTViewTemplate>
getViewTemplates()
Returns a copy of the view templates known to this supplier.
-
-
-
Method Detail
-
getStyleProperties
java.util.Map<VTStyleProperty,java.lang.Double> getStyleProperties(VElement vElement, ViewModelContext viewModelContext)
Return allStyleProperties
which are applicable to the providedVElement
. The keys of the map are theStyleProperties
and the values the corresponding specificities.The returned values might be cached by the caller. Therefore, for the same arguments, the
ViewTemplateSupplier
is expected to return the same map ofStyleProperties
and specificities.- Parameters:
vElement
- theVElement
to get theStyleProperties
forviewModelContext
- theViewModelContext
currently in use- Returns:
- the map of all
StyleProperties
and their specificities for the givenVElement
or an empty map
-
getViewTemplates
java.util.Set<VTViewTemplate> getViewTemplates()
Returns a copy of the view templates known to this supplier. Modifications on the copies will not influence any future calls on theViewTemplateSupplier
- Returns:
- a copy of the
VTViewTemplates
or an empty set
-
-