kr.co.hit.live.resources.impl
Class PropertyResourcesFactory
java.lang.Object
kr.co.hit.live.resources.impl.ResourcesFactoryBase
kr.co.hit.live.resources.impl.PropertyResourcesFactory
- All Implemented Interfaces:
- ResourcesFactory
public class PropertyResourcesFactory
- extends ResourcesFactoryBase
Resources 인스턴스를 생성하는 ResourcesFactory에
대한 구현 클래스이다. Resources 인스턴스는
'베이스 URL + 각 도큐먼트의 메세지에 적용될 Locale을 반영하는 name suffix' 유형의
프로퍼티 파일의 그룹을 래핑한다. 리소스는 도큐먼트내에서 java.util.ResourceBundle.getBundle().에 의해 수행되는것과
동일한 방식으로 lookup된다.
createResources() 메소드를 통해 전달되는 configuration 변수는
프로퍼티 파일 그룹의 베이스 네임 URL이어야 한다.
예를 들어, configuration URL이 http://localhost/foo/Bar로 전달된다면
en_US 로케일에 대한 리소스는 http://localhost/foo/Bar_en_US.properties에
저장되고, 기본 리소스는 http://localhost/foo/Bar.properties에 저장된다.
- Since:
- 3.0
- Version:
- $Revision: 1.1 $ $Date: 2006/09/26 08:20:09 $
- Author:
- 김광영
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
PropertyResourcesFactory
public PropertyResourcesFactory()
createResources
protected Resources createResources(String name,
String base)
throws ResourcesException
명시된 논리명을 기반으로 새로운 Resources 인스턴스를
생성하여 리턴한다. init() 메소드가 호출되고 나서 관련 프로퍼티를 위임한다.
- Specified by:
createResources in class ResourcesFactoryBase
- Parameters:
name - 생성될 Resources인스턴스의 논리명base - 해당 리소스에 대한 Configuration 스트링
- Throws:
ResourcesException - 명시된 논리명의 Resources
인스턴스가 생성될 수 없는 경우
Copyright © 2014. All Rights Reserved.