com.bemoko.live.platform.mwc.config
Interface ConfigEngine

All Superinterfaces:
org.springframework.context.ApplicationContextAware, org.springframework.beans.factory.Aware, org.springframework.beans.factory.BeanNameAware, com.bemoko.commons.spring.SelfAwareSpringBean<ConfigEngine>

public interface ConfigEngine
extends com.bemoko.commons.spring.SelfAwareSpringBean<ConfigEngine>

Interface to a configuration engine that manages the custom configuration for a site. Custom site configuration allows a site developer to provide a collection of configuration files (stored in the site "conf" directory) and compatible with that required by a @see groovy.util.ConfigSlurper.

 my.prop1 = "value1"
 my.prop2 = "value2"
  
 my.listprop1 = ["a","b","c"]
 
This configuration is then available to plugins using, e.g.
 Bemoko.config.my.prop
 
to expressions using, e.g.
 config.my.prop
 
and within templates using, e.g.
 ${config.my.prop}
 
and access to platform configuration, e.g.
 ${config.platform}
 
*


Method Summary
 Object getConfig(ConfigObject configObject, String propertyName)
           
 ConfigObject getConfig(String siteName)
           
 Object getConfig(String siteName, String propertyName)
           
 ConfigObjectWrapper getConfigWithException(String siteName)
           
 ConfigObject getPlatformConfig()
          Get platform configuration as config object
 ConfigObjectWrapper getSiteConfig(String siteName)
           
 
Methods inherited from interface com.bemoko.commons.spring.SelfAwareSpringBean
afterPropertiesSet, getSelf, setSelf
 
Methods inherited from interface org.springframework.beans.factory.BeanNameAware
setBeanName
 
Methods inherited from interface org.springframework.context.ApplicationContextAware
setApplicationContext
 

Method Detail

getConfig

ConfigObject getConfig(String siteName)

getConfig

Object getConfig(String siteName,
                 String propertyName)

getConfig

Object getConfig(ConfigObject configObject,
                 String propertyName)

getSiteConfig

ConfigObjectWrapper getSiteConfig(String siteName)
                                  throws LiveException
Throws:
LiveException

getPlatformConfig

ConfigObject getPlatformConfig()
Get platform configuration as config object

Returns:
ConfigObject

getConfigWithException

ConfigObjectWrapper getConfigWithException(String siteName)
                                           throws LiveException
Throws:
LiveException