Package org.oasisOpen.docs.wsdm.x2004.x12.muws.wsdmMuwsPart2

Examples of org.oasisOpen.docs.wsdm.x2004.x12.muws.wsdmMuwsPart2.MetricGroupDocument


        SetResourcePropertiesPortTypeImpl setResourcePropertiesPortType = new SetResourcePropertiesPortTypeImpl(getResourceContext());
        SetResourcePropertiesDocument setResourcePropertiesDocument = SetResourcePropertiesDocument.Factory.newInstance();
        SetResourcePropertiesDocument.SetResourceProperties setResourceProperties = setResourcePropertiesDocument.addNewSetResourceProperties();
        UpdateType updateType = UpdateType.Factory.newInstance();

        OperationalStatusDocument operationalStatusDocument = OperationalStatusDocument.Factory.newInstance();
        operationalStatusDocument.setOperationalStatus(status);

        XmlBeanUtils.addChildElement(updateType, operationalStatusDocument);

        setResourceProperties.setUpdateArray(new UpdateType[]{updateType});
        SetResourcePropertiesResponseDocument setResourcePropertiesResponseDocument = setResourcePropertiesPortType.setResourceProperties(setResourcePropertiesDocument);
View Full Code Here


            resourceProperty.add(currentTimeDocument);
            resourceProperty.setCallback(new org.apache.ws.resource.lifetime.callback.CurrentTimeCallback());
            resourceProperty.addChangeListener(metricsCapability);//add for management events

            resourceProperty = resourcePropertySet.get(WeatherstationPropertyQNames.OPERATIONALSTATUS);
            OperationalStatusDocument operationalStatusDocument = OperationalStatusDocument.Factory.newInstance();
            operationalStatusDocument.setOperationalStatus(OperationalStatusDocument.OperationalStatus.AVAILABLE);
            resourceProperty.add(operationalStatusDocument);
            resourceProperty.addChangeListener(operationalStatusCapability);//add for management events

            resourceProperty = resourcePropertySet.get(WeatherstationPropertyQNames.CORRELATABLEPROPERTIES);
            CorrelatablePropertiesDocument correlatablePropertiesDocument = CorrelatablePropertiesDocument.Factory.newInstance();
View Full Code Here

            currentTimeDocument.setCurrentTime(Calendar.getInstance());
            resourceProperty.add(currentTimeDocument);
            resourceProperty.setCallback(new org.apache.ws.resource.lifetime.callback.CurrentTimeCallback());

            resourceProperty = resourcePropertySet.get(IpmiserverPropertyQNames.OPERATIONALSTATUS);
            OperationalStatusDocument operationalStatusDocument = OperationalStatusDocument.Factory.newInstance();
            operationalStatusDocument.setOperationalStatus(OperationalStatusDocument.OperationalStatus.AVAILABLE);
            resourceProperty.add(operationalStatusDocument);

            /*============= Custom props =============*/
            resourceProperty = resourcePropertySet.get(IpmiserverPropertyQNames.ATTENTIONLEDON);
            AttentionLedOnDocument attentionLedOnDoc = AttentionLedOnDocument.Factory.newInstance();
View Full Code Here

            resourceProperty.add(freeStorageDocument);
            resourceProperty.addChangeListener(metricsCapability);


            resourceProperty = resourcePropertySet.get(BlackberryPropertyQNames.OPERATIONALSTATUS);
            OperationalStatusDocument operationalStatusDocument = OperationalStatusDocument.Factory.newInstance();
            operationalStatusDocument.setOperationalStatus(OperationalStatusDocument.OperationalStatus.AVAILABLE);
            resourceProperty.add(operationalStatusDocument);
            resourceProperty.addChangeListener(operationalStatusCapability);

            resourceProperty = resourcePropertySet.get(BlackberryPropertyQNames.TIME);
            TimeDocument timeDocument = TimeDocument.Factory.newInstance();
View Full Code Here

    public ResourceProperty refreshProperty(ResourceProperty propthrows CallbackFailedException
    {
        if ( prop.isEmpty() )
        {
            OperationalStatusDocument statusDoc = OperationalStatusDocument.Factory.newInstance();
            statusDoc.setOperationalStatus( getBackendStatus() );
            prop.add( statusDoc );
        }
        else
        {
            OperationalStatusDocument.OperationalStatus status = (OperationalStatusDocument.OperationalStatus) prop.get( 0 );
View Full Code Here

        XmlObject[] capabilityPropElems = m_resource.getResourceProperty(
                ManageabilityCharacteristicsCapability.PROP_NAME_MANAGEABILITY_CAPABILITY );
        assertContainsURI( capabilityPropElems, OperationalStatusCapability.URI );

        // init status to Available
        OperationalStatusDocument operationalStatusDoc = OperationalStatusDocument.Factory.newInstance();
        operationalStatusDoc.setOperationalStatus( OperationalStatusDocument.OperationalStatus.AVAILABLE );
        setSingleProperty( m_resource, operationalStatusDoc );

        m_resource.subscribe( s_consumerURL, new QName( MuwsConstants.NSURI_MUWS_PART2_TOPICS, OperationalStatusCapability.TOPIC_NAME, MuwsConstants.NSPREFIX_MUWS_PART2_TOPICS ) );
        PortListen notifListener = new PortListen( NOTIF_LISTENER_PORT, NOTIF_LISTENER_TIMEOUT );

        // change status to Unavailable
        operationalStatusDoc.setOperationalStatus( OperationalStatusDocument.OperationalStatus.UNAVAILABLE );
        setSingleProperty( m_resource, operationalStatusDoc );

        // make sure we receive a propChanged mgmtEvent
        ManagementEventType mgmtEvent = waitForManagementEvent( notifListener );
        XmlObject[] propChangedEvents = XmlBeanUtils.getChildElements(mgmtEvent, new QName(ResourcePropertiesConstants.NSURI_WSRP_SCHEMA, "ResourcePropertyValueChangeNotification"));
View Full Code Here

            currentTimeDocument.setCurrentTime(Calendar.getInstance());
            resourceProperty.add(currentTimeDocument);
            resourceProperty.setCallback(new org.apache.ws.resource.lifetime.callback.CurrentTimeCallback());

            resourceProperty = resourcePropertySet.get(IpmiserverPropertyQNames.OPERATIONALSTATUS);
            OperationalStatusDocument operationalStatusDocument = OperationalStatusDocument.Factory.newInstance();
            operationalStatusDocument.setOperationalStatus(OperationalStatusDocument.OperationalStatus.AVAILABLE);
            resourceProperty.add(operationalStatusDocument);

            /*============= Custom props =============*/
            resourceProperty = resourcePropertySet.get(IpmiserverPropertyQNames.ATTENTIONLEDON);
            AttentionLedOnDocument attentionLedOnDoc = AttentionLedOnDocument.Factory.newInstance();
View Full Code Here

            resourceProperty.add(freeStorageDocument);
            resourceProperty.addChangeListener(metricsCapability);


            resourceProperty = resourcePropertySet.get(BlackberryPropertyQNames.OPERATIONALSTATUS);
            OperationalStatusDocument operationalStatusDocument = OperationalStatusDocument.Factory.newInstance();
            operationalStatusDocument.setOperationalStatus(OperationalStatusDocument.OperationalStatus.AVAILABLE);
            resourceProperty.add(operationalStatusDocument);
            resourceProperty.addChangeListener(operationalStatusCapability);

            resourceProperty = resourcePropertySet.get(BlackberryPropertyQNames.TIME);
            TimeDocument timeDocument = TimeDocument.Factory.newInstance();
View Full Code Here

            resourceProperty.add(currentTimeDocument);
            resourceProperty.setCallback(new org.apache.ws.resource.lifetime.callback.CurrentTimeCallback());
            resourceProperty.addChangeListener(metricsCapability);//add for management events

            resourceProperty = resourcePropertySet.get(WeatherstationPropertyQNames.OPERATIONALSTATUS);
            OperationalStatusDocument operationalStatusDocument = OperationalStatusDocument.Factory.newInstance();
            operationalStatusDocument.setOperationalStatus(OperationalStatusDocument.OperationalStatus.AVAILABLE);
            resourceProperty.add(operationalStatusDocument);
            resourceProperty.addChangeListener(operationalStatusCapability);//add for management events

            resourceProperty = resourcePropertySet.get(WeatherstationPropertyQNames.CORRELATABLEPROPERTIES);
            CorrelatablePropertiesDocument correlatablePropertiesDocument = CorrelatablePropertiesDocument.Factory.newInstance();
View Full Code Here

        return ((GetCurrentTemperatureResponseDocument.GetCurrentTemperatureResponse)response).getGetCurrentTemperatureResult();
    }

    public RelationshipType[] queryRelationshipsByType( QName type throws FaultException, MalformedURLException, XmlException
    {
        QueryRelationshipsByTypeDocument requestDoc = QueryRelationshipsByTypeDocument.Factory.newInstance();
        QueryRelationshipsByTypeDocument.QueryRelationshipsByType queryRelationshipsByType = requestDoc.addNewQueryRelationshipsByType();
        queryRelationshipsByType.setRequestedType(type);
        URL url = new URL(m_url,"weatherstation");

        EnvelopeDocument requestEnvelopeDoc = createEnvelope();
        Envelope requestEnvelope = requestEnvelopeDoc.getEnvelope();
View Full Code Here

TOP

Related Classes of org.oasisOpen.docs.wsdm.x2004.x12.muws.wsdmMuwsPart2.MetricGroupDocument

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.