1 18 package org.apache.beehive.netui.script.common.bundle; 19 20 import java.util.Locale ; 21 import java.util.ResourceBundle ; 22 23 import org.apache.struts.util.MessageResources; 24 25 28 public class BundleNodeFactory { 29 30 private static final BundleNodeFactory FACTORY = new BundleNodeFactory(); 31 32 public static final BundleNodeFactory getInstance() { 33 return FACTORY; 34 } 35 36 private BundleNodeFactory() {} 37 38 public final BundleNode getStrutsBundleNode(String name, MessageResources messageResources, Locale locale) { 39 return new StrutsBundleNode(locale, messageResources); 40 } 41 42 public final BundleNode getResourceBundleNode(String name, ResourceBundle resourceBundle, Locale locale) { 43 return new ResourceBundleNode(resourceBundle); 44 } 45 } 46 | Popular Tags |