Package org.oasisOpen.docs.wsdm.x2004.x04.muws05.schema

Examples of org.oasisOpen.docs.wsdm.x2004.x04.muws05.schema.IntegerMetric


         // init the {http://docs.oasis-open.org/wsdm/2004/12/muws/wsdm-muws-part2.xsd}Relationship Resource Property

         //   init the {http://docs.oasis-open.org/wsdm/2004/12/muws/wsdm-muws-part2.xsd}CurrentTime ResourceProperty
         resourceProperty = resourcePropertySet.get( ApplicationPropertyQNames.CURRENTTIME );
         CurrentTimeDocument currentTimeDocument = CurrentTimeDocument.Factory.newInstance(  );
         currentTimeDocument.setCurrentTime( Calendar.getInstance(  ) );
         resourceProperty.add( currentTimeDocument );
         resourceProperty.setCallback( new org.apache.ws.resource.lifetime.callback.CurrentTimeCallback(  ) );
         resourceProperty.addChangeListener( metricCapability );

         // init the {http://ws.apache.org/namespaces/muse/muws-ext-1.xsd}Owner Resource Property
View Full Code Here


            else
            {
                resourceID = id.toString();
            }

            DestructionNotificationDocument destructionNotifDoc = DestructionNotificationDocument.Factory.newInstance();
            DestructionNotificationDocument.DestructionNotification destructionNotif = destructionNotifDoc.addNewDestructionNotification();
            destructionNotif.setResourceId((String) resourceID);
            try
            {
                publish(buildManagementEvent(destructionNotifDoc));
            }
View Full Code Here

        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

            EndpointReferenceType weatherStationEpr = (EndpointReferenceType) propElems[0];
            ResourcePropertySet resourcePropertySet = ((PropertiesResource) this).getResourcePropertySet();
            ResourceProperty resourceProperty = resourcePropertySet.get(WeatherClientConfigPropertyQNames.RELATIONSHIP);

            //define a relationship
            RelationshipDocument relationshipDocument = RelationshipDocument.Factory.newInstance();
            RelationshipType relationshipType = InteropRequestUtils.createRelationshipType(relationshipDocument.addNewRelationship());

            //add self as a participant
            RelationshipParticipantType parentRelationshipParticipantType = relationshipType.addNewParticipant();
            XmlBeansEndpointReference xmlEpr = (XmlBeansEndpointReference) this.getEndpointReference();
            EndpointReferenceType configEndpointReferenceType = (EndpointReferenceType) xmlEpr.getXmlObject(AddressingConstants.NSURI_ADDRESSING_SCHEMA);
View Full Code Here

        //iterate the relationships
        Iterator iterator = resourceProperty.iterator();
        List removeList = new ArrayList();
        while (iterator.hasNext())
        {
            RelationshipDocument relationshipDocument = (RelationshipDocument) iterator.next();
            RelationshipParticipantType[] participantArray = relationshipDocument.getRelationship().getParticipantArray();

            for (int i = 0; i < participantArray.length; i++)
            {
                RelationshipParticipantType relationshipParticipantType = participantArray[i];
                if (resourceId != null && resourceId.equals(relationshipParticipantType.getResourceId()))
View Full Code Here

        //get the request epr
        org.wsdmdemo.service.weatherStationDir.AddWeatherStationDocument.AddWeatherStation addWeatherStation = requestDoc.getAddWeatherStation();
        org.xmlsoap.schemas.ws.x2004.x08.addressing.EndpointReferenceType addedEpr = addWeatherStation.getEndpointReference();

        //define a relationship
        RelationshipDocument relationshipDocument = RelationshipDocument.Factory.newInstance();


        //define the relationship type
        RelationshipType relationshipType = InteropRequestUtils.createRelationshipType(relationshipDocument.addNewRelationship());


        //add self as a participant
        RelationshipParticipantType parentRelationshipParticipantType = relationshipType.addNewParticipant();
        WeatherStationDirResource resource = (WeatherStationDirResource) getResource();
View Full Code Here

TOP

Related Classes of org.oasisOpen.docs.wsdm.x2004.x04.muws05.schema.IntegerMetric

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.