Search in sources :

Example 11 with ModelInstance

use of org.camunda.bpm.model.xml.ModelInstance in project camunda-xml-model by camunda.

the class AttributeTest method createModel.

public static Object[] createModel() {
    TestModelParser modelParser = new TestModelParser();
    ModelInstance modelInstance = modelParser.getEmptyModel();
    Animals animals = modelInstance.newInstance(Animals.class);
    modelInstance.setDocumentElement(animals);
    createBird(modelInstance, "tweety", Gender.Female);
    return new Object[] { "created", modelInstance, modelParser };
}
Also used : ModelInstance(org.camunda.bpm.model.xml.ModelInstance) Animals(org.camunda.bpm.model.xml.testmodel.instance.Animals) TestModelParser(org.camunda.bpm.model.xml.testmodel.TestModelParser)

Aggregations

ModelInstance (org.camunda.bpm.model.xml.ModelInstance)11 TestModelParser (org.camunda.bpm.model.xml.testmodel.TestModelParser)8 Animals (org.camunda.bpm.model.xml.testmodel.instance.Animals)4 InputStream (java.io.InputStream)1 ModelReferenceException (org.camunda.bpm.model.xml.ModelReferenceException)1 ModelElementInstance (org.camunda.bpm.model.xml.instance.ModelElementInstance)1 Animal (org.camunda.bpm.model.xml.testmodel.instance.Animal)1 Bird (org.camunda.bpm.model.xml.testmodel.instance.Bird)1 Description (org.camunda.bpm.model.xml.testmodel.instance.Description)1 Test (org.junit.Test)1