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

Examples of org.oasisOpen.docs.wsdm.x2004.x12.muws.wsdmMuwsPart1.ManageabilityCapabilityDocument


            CurrentOperationalStateDocument currentOperationalStateDocument = CurrentOperationalStateDocument.Factory.newInstance();
            currentOperationalStateDocument.addNewCurrentOperationalState();
            resourceProperty.add(currentOperationalStateDocument);

            resourceProperty = resourcePropertySet.get(WeatherstationPropertyQNames.LASTOPERATIONALSTATETRANSITION);
            LastOperationalStateTransitionDocument lastOperationalStateTransitionDocument = LastOperationalStateTransitionDocument.Factory.newInstance();
            StateTransitionType stateTransitionType = lastOperationalStateTransitionDocument.addNewLastOperationalStateTransition();
            stateTransitionType.addNewEnteredState();
            stateTransitionType.addNewPreviousState();
            stateTransitionType.setTime(Calendar.getInstance());
            stateTransitionType.setTransitionIdentifier("");
            resourceProperty.add(lastOperationalStateTransitionDocument);
View Full Code Here


            maxRespDurationMetric.setDuration(builder.toGDuration());
            resourceProperty.add(maxResponseTimeDocument);
            resourceProperty.addChangeListener(mowsMetricsCapability);

            resourceProperty = resourcePropertySet.get(WeatherstationPropertyQNames.LASTRESPONSETIME);
            LastResponseTimeDocument lastResponseTimeDocument = LastResponseTimeDocument.Factory.newInstance();
            DurationMetric lastRespDurationMetric = lastResponseTimeDocument.addNewLastResponseTime();
            lastRespDurationMetric.setGDurationValue(builder.toGDuration());
            lastRespDurationMetric.setDuration(builder.toGDuration());
            resourceProperty.add(lastResponseTimeDocument);
            resourceProperty.addChangeListener(mowsMetricsCapability);
        }
View Full Code Here

            serviceTimeMetric.setDuration(builder.toGDuration());
            resourceProperty.add(serviceTimeDocument);
            resourceProperty.addChangeListener(mowsMetricsCapability);

            resourceProperty = resourcePropertySet.get(WeatherstationPropertyQNames.MAXRESPONSETIME);
            MaxResponseTimeDocument maxResponseTimeDocument = MaxResponseTimeDocument.Factory.newInstance();
            DurationMetric maxRespDurationMetric = maxResponseTimeDocument.addNewMaxResponseTime();
            maxRespDurationMetric.setGDurationValue(builder.toGDuration());
            maxRespDurationMetric.setDuration(builder.toGDuration());
            resourceProperty.add(maxResponseTimeDocument);
            resourceProperty.addChangeListener(mowsMetricsCapability);
View Full Code Here

            successIntegerCounter.setResetAt(resetAt);
            resourceProperty.add(numberOfSuccessfulRequestsDocument);
            resourceProperty.addChangeListener(mowsMetricsCapability);

            resourceProperty = resourcePropertySet.get(WeatherstationPropertyQNames.NUMBEROFFAILEDREQUESTS);
            NumberOfFailedRequestsDocument numberOfFailedRequestsDocument = NumberOfFailedRequestsDocument.Factory.newInstance();
            IntegerCounter failedIntegerCounter = numberOfFailedRequestsDocument.addNewNumberOfFailedRequests();
            failedIntegerCounter.setBigIntegerValue(BigInteger.valueOf(30L));
            failedIntegerCounter.setResetAt(resetAt);
            resourceProperty.add(numberOfFailedRequestsDocument);
            resourceProperty.addChangeListener(mowsMetricsCapability);
View Full Code Here

            /*----------------- MOWS Metrics props -----------------*/

            Calendar resetAt = Calendar.getInstance();

            resourceProperty = resourcePropertySet.get(WeatherstationPropertyQNames.NUMBEROFREQUESTS);
            NumberOfRequestsDocument numberOfRequestsDocument = NumberOfRequestsDocument.Factory.newInstance();
            IntegerCounter integerCounter = numberOfRequestsDocument.addNewNumberOfRequests();
            integerCounter.setBigIntegerValue(BigInteger.valueOf(120L));
            integerCounter.setResetAt(resetAt);
            resourceProperty.add(numberOfRequestsDocument);
            resourceProperty.addChangeListener(mowsMetricsCapability);

View Full Code Here

            integerCounter.setResetAt(resetAt);
            resourceProperty.add(numberOfRequestsDocument);
            resourceProperty.addChangeListener(mowsMetricsCapability);

            resourceProperty = resourcePropertySet.get(WeatherstationPropertyQNames.NUMBEROFSUCCESSFULREQUESTS);
            NumberOfSuccessfulRequestsDocument numberOfSuccessfulRequestsDocument = NumberOfSuccessfulRequestsDocument.Factory.newInstance();
            IntegerCounter successIntegerCounter = numberOfSuccessfulRequestsDocument.addNewNumberOfSuccessfulRequests();
            successIntegerCounter.setBigIntegerValue(BigInteger.valueOf(90L));
            successIntegerCounter.setResetAt(resetAt);
            resourceProperty.add(numberOfSuccessfulRequestsDocument);
            resourceProperty.addChangeListener(mowsMetricsCapability);
View Full Code Here

            failedIntegerCounter.setResetAt(resetAt);
            resourceProperty.add(numberOfFailedRequestsDocument);
            resourceProperty.addChangeListener(mowsMetricsCapability);

            resourceProperty = resourcePropertySet.get(WeatherstationPropertyQNames.SERVICETIME);
            ServiceTimeDocument serviceTimeDocument = ServiceTimeDocument.Factory.newInstance();
            DurationMetric serviceTimeMetric = serviceTimeDocument.addNewServiceTime();
            GDurationBuilder builder = new GDurationBuilder(+1, 1, 2, 3, 4, 5, 6, new BigDecimal("0.789"));
            serviceTimeMetric.setGDurationValue(builder.toGDuration());
            serviceTimeMetric.setDuration(builder.toGDuration());
            resourceProperty.add(serviceTimeDocument);
            resourceProperty.addChangeListener(mowsMetricsCapability);
View Full Code Here

     * @return Source EPR
     */
    private EndpointReferenceType parseSourceEpr(ManagementEventTypeImpl manEvt)
    {
        ComponentType sourceComponent = manEvt.getSourceComponent();
        ComponentAddressType sourceCompAddr = sourceComponent.getComponentAddressArray(0);
        EndpointReferenceType sourceEpr =
                (EndpointReferenceType) XmlBeanUtils.getChildElements(sourceCompAddr)[0];
        return sourceEpr;
    }
View Full Code Here

        {
            List reporterComponentAddresses = new ArrayList();

            for (int i = 0; i < m_reporterComponentAddresses.length; i++)
            {
                ComponentAddressType reporterComponentAddressType = reporterComponentType.addNewComponentAddress();
                XmlBeanUtils.addChildElement(reporterComponentAddressType, (XmlObject) m_reporterComponentAddresses[i]);
                reporterComponentAddresses.add(reporterComponentAddressType);
            }

            reporterComponentType.setComponentAddressArray((ComponentAddressType[]) reporterComponentAddresses.toArray(new ComponentAddressType[0]));
        }

        org.oasisOpen.docs.wsdm.x2004.x12.muws.wsdmMuwsPart1.ComponentType sourceComponentType = managementEventType.addNewSourceComponent();
        if (m_sourceResourceId != null)
        {
            sourceComponentType.setResourceId(m_sourceResourceId);
        }

        if (m_sourceComponentAddresses != null)
        {
            List sourceComponentAddresses = new ArrayList();
            for (int i = 0; i < m_sourceComponentAddresses.length; i++)
            {
                ComponentAddressType sourceComponentAddressType = sourceComponentType.addNewComponentAddress();
                XmlBeanUtils.addChildElement(sourceComponentAddressType, (XmlObject) m_sourceComponentAddresses[i]);
                sourceComponentAddresses.add(sourceComponentAddressType);
            }

            sourceComponentType.setComponentAddressArray((ComponentAddressType[]) sourceComponentAddresses.toArray(new ComponentAddressType[0]));
View Full Code Here

     * @param manEvt
     * @return Source EPR
     */
    private EndpointReferenceType parseSourceEpr(ManagementEventTypeImpl manEvt)
    {
        ComponentType sourceComponent = manEvt.getSourceComponent();
        ComponentAddressType sourceCompAddr = sourceComponent.getComponentAddressArray(0);
        EndpointReferenceType sourceEpr =
                (EndpointReferenceType) XmlBeanUtils.getChildElements(sourceCompAddr)[0];
        return sourceEpr;
    }
View Full Code Here

TOP

Related Classes of org.oasisOpen.docs.wsdm.x2004.x12.muws.wsdmMuwsPart1.ManageabilityCapabilityDocument

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.