public class ModelDesignsManager extends AbstractLogEnabled implements ThreadSafe, Serviceable, Component
Modifier and Type | Class and Description |
---|---|
class |
ModelDesignsManager.Design
Bean representing a model design
|
Modifier and Type | Field and Description |
---|---|
private Map<String,Map<String,ModelDesignsManager.Design>> |
_designsCache |
private SkinModelsManager |
_modelsManager |
private SourceResolver |
_resolver |
private SkinFactoryComponent |
_skinFactoryManager |
static String |
ROLE
The avalon role name
|
Constructor and Description |
---|
ModelDesignsManager() |
Modifier and Type | Method and Description |
---|---|
private ModelDesignsManager.Design |
_configureDesign(String modelName,
File configurationFile) |
private void |
_configureDesigns(String modelName) |
private I18nizableText |
_configureI18nizableText(Configuration configuration,
I18nizableText defaultValue,
String modelName) |
private String |
_getColorTheme(File file) |
private Map<String,Object> |
_getParameterValues(String modelName,
File file) |
void |
applyDesign(String modelName,
String id,
File skinDir)
Apply a design
|
ModelDesignsManager.Design |
getDesign(String modelName,
String id)
Get design instance of given id and model name
|
Map<String,ModelDesignsManager.Design> |
getDesigns(String modelName)
Get all design instances for given model
|
void |
service(ServiceManager smanager) |
enableLogging, getLogger, setupLogger, setupLogger, setupLogger
private SkinModelsManager _modelsManager
private SkinFactoryComponent _skinFactoryManager
private SourceResolver _resolver
private Map<String,Map<String,ModelDesignsManager.Design>> _designsCache
public ModelDesignsManager()
public void service(ServiceManager smanager) throws ServiceException
service
in interface Serviceable
ServiceException
public Map<String,ModelDesignsManager.Design> getDesigns(String modelName)
modelName
- The model namepublic ModelDesignsManager.Design getDesign(String modelName, String id)
modelName
- The model nameid
- The idpublic void applyDesign(String modelName, String id, File skinDir)
modelName
- The model nameid
- Id of designskinDir
- The skin directory (could be temp, work or skins)private void _configureDesigns(String modelName)
private ModelDesignsManager.Design _configureDesign(String modelName, File configurationFile)
private String _getColorTheme(File file)
private I18nizableText _configureI18nizableText(Configuration configuration, I18nizableText defaultValue, String modelName) throws ConfigurationException
ConfigurationException