FileDocCategorySizeDatePackage
PolicyResourceLoader.javaAPI DocExample3711Tue May 29 16:57:46 BST 2007com.sun.xml.wss.impl.util

PolicyResourceLoader

public class PolicyResourceLoader extends Object
author
ashutosh.shahi@sun.com

Fields Summary
Constructors Summary
public PolicyResourceLoader()
Creates a new instance of PolicyResourceLoader

    
Methods Summary
public static java.io.ReadergetResourceReader(java.lang.String resourceName)

        return new InputStreamReader(Thread.currentThread().getContextClassLoader().getResourceAsStream(resourceName));
    
public static com.sun.xml.ws.policy.PolicyloadPolicy(java.lang.String resourceName)

        return translateModel(unmarshallModel(resourceName));
    
public static com.sun.xml.ws.policy.PolicytranslateModel(com.sun.xml.ws.policy.sourcemodel.PolicySourceModel model)

        return PolicyModelTranslator.getTranslator().translate(model);
    
public static com.sun.xml.ws.policy.sourcemodel.PolicySourceModelunmarshallModel(java.lang.String resource)

        Reader reader = getResourceReader(resource);
        PolicySourceModel model = PolicyModelUnmarshaller.getXmlUnmarshaller().unmarshalModel(reader);
        reader.close();
        return model;