Package org.camunda.spin.xml

Examples of org.camunda.spin.xml.SpinXmlElement


      });
  }

  public void testSpin_S_Available() {

    SpinXmlElement spinXmlEl = executeExpression("${ S('" + xmlString + "') }");
    assertNotNull(spinXmlEl);
    assertEquals("elementName", spinXmlEl.name());
  }
View Full Code Here


    assertEquals("elementName", spinXmlEl.name());
  }

  public void testSpin_XML_Available() {

    SpinXmlElement spinXmlEl = executeExpression("${ XML('" + xmlString + "') }");
    assertNotNull(spinXmlEl);
    assertEquals("elementName", spinXmlEl.name());
  }
View Full Code Here

    assertEquals(bean, typedValue.getValue(XmlSerializable.class));
    assertEquals(XmlSerializable.class, typedValue.getObjectType());

    assertEquals(XML_FORMAT_NAME, typedValue.getSerializationDataFormat());
    assertEquals(XmlSerializable.class.getName(), typedValue.getObjectTypeName());
    SpinXmlElement serializedValue = Spin.XML(typedValue.getValueSerialized());
    assertEquals(bean.getStringProperty(), serializedValue.childElement("stringProperty").textContent());
    assertEquals(bean.getBooleanProperty(), Boolean.parseBoolean(serializedValue.childElement("booleanProperty").textContent()));
    assertEquals(bean.getIntProperty(), Integer.parseInt(serializedValue.childElement("intProperty").textContent()));
  }
View Full Code Here

    XmlSerializable bean = new XmlSerializable("a String", 42, true);
    runtimeService.setVariable(instance.getId(), "simpleBean", objectValue(bean).serializationDataFormat(XML_FORMAT_NAME).create());

    ObjectValue typedValue = runtimeService.getVariableTyped(instance.getId(), "simpleBean", false);

    SpinXmlElement serializedValue = Spin.XML(typedValue.getValueSerialized());
    assertEquals(bean.getStringProperty(), serializedValue.childElement("stringProperty").textContent());
    assertEquals(bean.getBooleanProperty(), Boolean.parseBoolean(serializedValue.childElement("booleanProperty").textContent()));
    assertEquals(bean.getIntProperty(), Integer.parseInt(serializedValue.childElement("intProperty").textContent()));
  }
View Full Code Here

TOP

Related Classes of org.camunda.spin.xml.SpinXmlElement

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.