FileDocCategorySizeDatePackage
WebServiceConfigTest.javaAPI DocGlassfish v2 API5344Fri May 04 22:24:04 BST 2007com.sun.enterprise.management.ext.wsmgmt

WebServiceConfigTest

public final class WebServiceConfigTest extends com.sun.enterprise.management.AMXTestBase

Fields Summary
Constructors Summary
public WebServiceConfigTest()

    
Methods Summary
public static com.sun.enterprise.management.CapabilitiesgetCapabilities()

	    return getOfflineCapableCapabilities( false );
	
public voidtestConfigMBeans()

        assert (getDomainRoot().getWebServiceMgr() != null);

       final Set<WebServiceEndpointConfig>   s   =
        getDomainRoot().getQueryMgr().queryJ2EETypeSet(
                              XTypes.WEB_SERVICE_ENDPOINT_CONFIG);

       for( final WebServiceEndpointConfig wsc : s )
       {
            String oldSize = wsc.getMaxHistorySize();
            System.out.println("Old Max History size is " + oldSize);
            System.out.println("Setting Max History size to 1 " );
            wsc.setMaxHistorySize("1");
            System.out.println("New Max History size is  " 
                + wsc.getMaxHistorySize());
            assert( "1".equals(wsc.getMaxHistorySize()));
            System.out.println("Resetting Max History size to " + oldSize );
            wsc.setMaxHistorySize(oldSize);
            System.out.println("Config value is " + wsc.getMonitoringLevel());

            Map m = wsc.getTransformationRuleConfigMap();

            System.out.println("Transformation rules found " + m.size());

           Iterator itr = m.values().iterator();
           while  ( itr.hasNext()) {
                TransformationRuleConfig tc = (TransformationRuleConfig)
                itr.next();
                System.out.println("rule name is " + tc.getName());
           }
           System.out.println("Getting tranformation rules in order ");
            List l = wsc.getTransformationRuleConfigList();

            System.out.println("Transformation rules found " + l.size());

           Iterator litr = l.iterator();
           while  ( litr.hasNext()) {
                TransformationRuleConfig tc = (TransformationRuleConfig)
                litr.next();
                System.out.println("rule name is " + tc.getName());
           }
       }
       assert(true);