Package org.oasisOpen.docs.wsrf.x2004.x06.wsrfWSResourceProperties12Draft01

Examples of org.oasisOpen.docs.wsrf.x2004.x06.wsrfWSResourceProperties12Draft01.SetResourcePropertiesResponseDocument


            throws XmlException
    {
        final String newValue = "99";
        m_resourceContext = new SushiResourceContext();
        SetResourcePropertiesProvider set_provider = new SetResourcePropertiesProvider( m_resourceContext );
        UpdateDocument updateDoc = UpdateDocument.Factory.newInstance();
        UpdateType update = updateDoc.addNewUpdate();

        XmlObject xmlObject =
                XmlObject.Factory.parse( "<foo:Ebi xmlns:foo=\"http://ws.apache.org/resource/properties/test/sushi\">"
                + newValue + "</foo:Ebi>" );
        XmlBeanUtils.addChildElement( update, xmlObject );

        set_provider.updateResourceProperty( updateDoc.getUpdate() );

        assertPropHasOneElemWithGivenValue( SushiPropertyQNames.EBI, newValue );
    }
View Full Code Here


    public static boolean invokeSetResourceProperty(String prop, String value, String filesystemEPRUrl)
    {
        SetResourcePropertiesDocument setResourcePropertiesDocument = SetResourcePropertiesDocument.Factory.newInstance();
        SetResourcePropertiesDocument.SetResourceProperties setResourceProperties = setResourcePropertiesDocument.addNewSetResourceProperties();
        UpdateType updateType = UpdateType.Factory.newInstance();

        XmlObject simpleType = XmlBeanUtils.addChildElement(updateType, QName.valueOf(prop));
        XmlBeanUtils.setValue(simpleType, value);
        setResourceProperties.setUpdateArray(new UpdateType[]{updateType});
View Full Code Here

    protected void updateResourceProperty( XmlObject[] propElems )
    {
        SetResourcePropertiesPortTypeImpl setProvider = new SetResourcePropertiesPortTypeImpl( m_resourceContext );
        SetResourcePropertiesDocument setDocument = SetResourcePropertiesDocument.Factory.newInstance();
        SetResourcePropertiesDocument.SetResourceProperties setType = setDocument.addNewSetResourceProperties();
        UpdateType updateType = setType.addNewUpdate();
        for ( int i = 0; i < propElems.length; i++ )
        {
            XmlBeanUtils.addChildElement( updateType, propElems[i] );
        }
        setProvider.setResourceProperties( setDocument ).getSetResourcePropertiesResponse();
View Full Code Here

        ResourceProperty resourceProp = resource.getResourcePropertySet().get( SushiPropertyQNames.EBI );
        resourceProp.setCallback( callback );

        SetResourcePropertiesProvider set_provider = new SetResourcePropertiesProvider( m_resourceContext );
        UpdateDocument updateDoc = UpdateDocument.Factory.newInstance();
        UpdateType update = updateDoc.addNewUpdate();

        XmlObject xmlObject =
                XmlObject.Factory.parse( "<foo:Ebi xmlns:foo=\"http://ws.apache.org/resource/properties/test/sushi\">"
                + newValue + "</foo:Ebi>" );
        XmlBeanUtils.addChildElement( update, xmlObject );
View Full Code Here

        m_resourceContext = new SushiResourceContext( true );
        insertXsdAnyPropElem();
        assertPropHasOneElemWithGivenValue( SushiPropertyQNames.FUGU, INITIAL_PROP_VALUE_FUGU );
        SetResourcePropertiesProvider set_provider = new SetResourcePropertiesProvider( m_resourceContext );
        UpdateDocument updateDoc = UpdateDocument.Factory.newInstance();
        UpdateType update = updateDoc.addNewUpdate();
        XmlObject anyXBean = createXsdAnyPropElem();
        final String newValue = "yummy!";
        XmlBeanUtils.setValue( anyXBean, newValue );
        XmlBeanUtils.addChildElement( update, anyXBean );
        set_provider.updateResourceProperty( updateDoc.getUpdate() );
View Full Code Here

    {
        final String newValue = "99";
        m_resourceContext = new SushiResourceContext();
        SetResourcePropertiesProvider set_provider = new SetResourcePropertiesProvider( m_resourceContext );
        UpdateDocument updateDoc = UpdateDocument.Factory.newInstance();
        UpdateType update = updateDoc.addNewUpdate();

        XmlObject xmlObject =
                XmlObject.Factory.parse( "<foo:Ebi xmlns:foo=\"http://ws.apache.org/resource/properties/test/sushi\">"
                + newValue + "</foo:Ebi>" );
        XmlBeanUtils.addChildElement( update, xmlObject );
View Full Code Here

   */
  public void makeActive(EndpointReference referenceToWcConfigEpr) {
    XmlObject newEpr = ((XmlBeansEndpointReference)wsEpr).getXmlObject(AddressingConstants.NSURI_ADDRESSING_SCHEMA);
    SetResourcePropertiesDocument setResourcePropertiesDocument = SetResourcePropertiesDocument.Factory.newInstance();
        SetResourcePropertiesDocument.SetResourceProperties setResourceProperties = setResourcePropertiesDocument.addNewSetResourceProperties();
        UpdateType updateType = UpdateType.Factory.newInstance();
        WeatherStationReferenceDocument weatherDoc = WeatherStationReferenceDocument.Factory.newInstance();
        weatherDoc.setWeatherStationReference((EndpointReferenceType) newEpr);
        XmlBeanUtils.addChildElement(updateType,weatherDoc);
        setResourceProperties.setUpdateArray(new UpdateType[]{updateType});
View Full Code Here

    public void updateResourceProperty( XmlObject[] propElems ) throws FaultException
    {
        SetResourcePropertiesDocument requestDoc = SetResourcePropertiesDocument.Factory.newInstance();
        SetResourcePropertiesDocument.SetResourceProperties setResourceProperties = requestDoc.addNewSetResourceProperties();
        UpdateType updateType = setResourceProperties.addNewUpdate();
        for ( int i = 0; i < propElems.length; i++ )
        {
            XmlBeanUtils.addChildElement( updateType, propElems[i] );
        }
        XmlObject response = sendRequest( requestDoc, "http://xyz.com/action/SetResourceProperties","U" );
View Full Code Here

    public void changeOperationalStatus(OperationalStatusDocument.OperationalStatus.Enum status)
    {
        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);
View Full Code Here

      NotifyDocument.Notify ele = (NotifyDocument.Notify) arryStuff[0];
      NotificationMessageHolderType noteMess = ele.getNotificationMessageArray(0);
      XmlAnyTypeImpl mess = (XmlAnyTypeImpl)noteMess.getMessage();
      ManagementEventTypeImpl manEvt = (ManagementEventTypeImpl)XmlBeanUtils.getChildElements(mess)[0];
      //manEvt.get
      ResourcePropertyValueChangeNotificationTypeImpl propChngEvt = (ResourcePropertyValueChangeNotificationTypeImpl)XmlBeanUtils.getChildElements(manEvt)[0];
      NewValue newValue = propChngEvt.getNewValue();
//      XmlObject complience = (XmlObject)XmlBeanUtils.getChildElements(newValue)[0];
     
    } catch (Exception e) {
      // TODO Auto-generated catch block
      e.printStackTrace();
View Full Code Here

TOP

Related Classes of org.oasisOpen.docs.wsrf.x2004.x06.wsrfWSResourceProperties12Draft01.SetResourcePropertiesResponseDocument

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.