gluu
限定公開メンバ関数 | 限定公開変数類 | 全メンバ一覧
org.gluu.oxauth.client.util.AbstractConfigurationFilter クラスabstract
org.gluu.oxauth.client.util.AbstractConfigurationFilter の継承関係図
Inheritance graph
org.gluu.oxauth.client.util.AbstractConfigurationFilter 連携図
Collaboration graph

限定公開メンバ関数

final String getPropertyFromInitParams (final FilterConfig filterConfig, final String propertyName, final String defaultValue)
 

限定公開変数類

final Log log = LogFactory.getLog(getClass())
 

詳解

Abstracts out the ability to configure the filters from the initial properties provided

著者
Yuriy Movchan
バージョン
0.1, 03/20/2013

関数詳解

◆ getPropertyFromInitParams()

final String org.gluu.oxauth.client.util.AbstractConfigurationFilter.getPropertyFromInitParams ( final FilterConfig  filterConfig,
final String  propertyName,
final String  defaultValue 
)
inlineprotected

Retrieves the property from the FilterConfig. First it checks the FilterConfig's initParameters to see if it has a value. If it does, it returns that, otherwise it retrieves the ServletContext's initParameters and returns that value if any.

引数
filterConfigthe Filter Configuration.
propertyNamethe property to retrieve.
defaultValuethe default value if the property is not found.
戻り値
the property value, following the above conventions. It will always return the more specific value (i.e. filter vs. context).
35  {
36 // final String value = filterConfig.getInitParameter(propertyName);
37 //
38 // if (StringHelper.isNotEmpty(value)) {
39 // log.info("Property [" + propertyName + "] loaded from FilterConfig.getInitParameter with value [" + value + "]");
40 // return value;
41 // }
42 //
43 // final String value2 = filterConfig.getServletContext().getInitParameter(propertyName);
44 // if (StringHelper.isNotEmpty(value2)) {
45 // log.info("Property [" + propertyName + "] loaded from ServletContext.getInitParameter with value [" + value2 + "]");
46 // return value2;
47 // }
48 
49  final String value3 = Configuration.instance().getPropertyValue(propertyName);
50  if (StringHelper.isNotEmpty(value3)) {
51  log.info("Property [" + propertyName + "] loaded from oxTrust.properties");
52  return value3;
53  }
54 
55  log.info("Property [" + propertyName + "] not found. Using default value [" + defaultValue + "]");
56  return defaultValue;
57  }
final Log log
Definition: AbstractConfigurationFilter.java:24

メンバ詳解

◆ log

final Log org.gluu.oxauth.client.util.AbstractConfigurationFilter.log = LogFactory.getLog(getClass())
protected

このクラス詳解は次のファイルから抽出されました: