Search in sources :

Example 66 with SequenceBuilder

use of org.camunda.bpm.model.xml.type.child.SequenceBuilder in project camunda-bpmn-model by camunda.

the class ParticipantImpl method registerType.

public static void registerType(ModelBuilder modelBuilder) {
    ModelElementTypeBuilder typeBuilder = modelBuilder.defineType(Participant.class, BPMN_ELEMENT_PARTICIPANT).namespaceUri(BPMN20_NS).extendsType(BaseElement.class).instanceProvider(new ModelTypeInstanceProvider<Participant>() {

        public Participant newInstance(ModelTypeInstanceContext instanceContext) {
            return new ParticipantImpl(instanceContext);
        }
    });
    nameAttribute = typeBuilder.stringAttribute(BPMN_ATTRIBUTE_NAME).build();
    processRefAttribute = typeBuilder.stringAttribute(BPMN_ATTRIBUTE_PROCESS_REF).qNameAttributeReference(Process.class).build();
    SequenceBuilder sequenceBuilder = typeBuilder.sequence();
    interfaceRefCollection = sequenceBuilder.elementCollection(InterfaceRef.class).qNameElementReferenceCollection(Interface.class).build();
    endPointRefCollection = sequenceBuilder.elementCollection(EndPointRef.class).qNameElementReferenceCollection(EndPoint.class).build();
    participantMultiplicityChild = sequenceBuilder.element(ParticipantMultiplicity.class).build();
    typeBuilder.build();
}
Also used : SequenceBuilder(org.camunda.bpm.model.xml.type.child.SequenceBuilder) ModelElementTypeBuilder(org.camunda.bpm.model.xml.type.ModelElementTypeBuilder) ModelTypeInstanceContext(org.camunda.bpm.model.xml.impl.instance.ModelTypeInstanceContext)

Example 67 with SequenceBuilder

use of org.camunda.bpm.model.xml.type.child.SequenceBuilder in project camunda-bpmn-model by camunda.

the class IoSpecificationImpl method registerType.

public static void registerType(ModelBuilder modelBuilder) {
    ModelElementTypeBuilder typeBuilder = modelBuilder.defineType(IoSpecification.class, BPMN_ELEMENT_IO_SPECIFICATION).namespaceUri(BPMN20_NS).extendsType(BaseElement.class).instanceProvider(new ModelTypeInstanceProvider<IoSpecification>() {

        public IoSpecification newInstance(ModelTypeInstanceContext instanceContext) {
            return new IoSpecificationImpl(instanceContext);
        }
    });
    SequenceBuilder sequenceBuilder = typeBuilder.sequence();
    dataInputCollection = sequenceBuilder.elementCollection(DataInput.class).build();
    dataOutputCollection = sequenceBuilder.elementCollection(DataOutput.class).build();
    inputSetCollection = sequenceBuilder.elementCollection(InputSet.class).required().build();
    outputSetCollection = sequenceBuilder.elementCollection(OutputSet.class).required().build();
    typeBuilder.build();
}
Also used : SequenceBuilder(org.camunda.bpm.model.xml.type.child.SequenceBuilder) ModelElementTypeBuilder(org.camunda.bpm.model.xml.type.ModelElementTypeBuilder) ModelTypeInstanceContext(org.camunda.bpm.model.xml.impl.instance.ModelTypeInstanceContext)

Example 68 with SequenceBuilder

use of org.camunda.bpm.model.xml.type.child.SequenceBuilder in project camunda-bpmn-model by camunda.

the class EventImpl method registerType.

public static void registerType(ModelBuilder modelBuilder) {
    ModelElementTypeBuilder typeBuilder = modelBuilder.defineType(Event.class, BPMN_ELEMENT_EVENT).namespaceUri(BPMN20_NS).extendsType(FlowNode.class).abstractType();
    SequenceBuilder sequence = typeBuilder.sequence();
    propertyCollection = sequence.elementCollection(Property.class).build();
    typeBuilder.build();
}
Also used : SequenceBuilder(org.camunda.bpm.model.xml.type.child.SequenceBuilder) ModelElementTypeBuilder(org.camunda.bpm.model.xml.type.ModelElementTypeBuilder) Event(org.camunda.bpm.model.bpmn.instance.Event) FlowNode(org.camunda.bpm.model.bpmn.instance.FlowNode)

Example 69 with SequenceBuilder

use of org.camunda.bpm.model.xml.type.child.SequenceBuilder in project camunda-bpmn-model by camunda.

the class ExtensionImpl method registerType.

public static void registerType(ModelBuilder modelBuilder) {
    ModelElementTypeBuilder typeBuilder = modelBuilder.defineType(Extension.class, BPMN_ELEMENT_EXTENSION).namespaceUri(BPMN20_NS).instanceProvider(new ModelTypeInstanceProvider<Extension>() {

        public Extension newInstance(ModelTypeInstanceContext instanceContext) {
            return new ExtensionImpl(instanceContext);
        }
    });
    // TODO: qname reference extension definition
    definitionAttribute = typeBuilder.stringAttribute(BPMN_ATTRIBUTE_DEFINITION).build();
    mustUnderstandAttribute = typeBuilder.booleanAttribute(BPMN_ATTRIBUTE_MUST_UNDERSTAND).defaultValue(false).build();
    SequenceBuilder sequenceBuilder = typeBuilder.sequence();
    documentationCollection = sequenceBuilder.elementCollection(Documentation.class).build();
    typeBuilder.build();
}
Also used : Extension(org.camunda.bpm.model.bpmn.instance.Extension) SequenceBuilder(org.camunda.bpm.model.xml.type.child.SequenceBuilder) ModelElementTypeBuilder(org.camunda.bpm.model.xml.type.ModelElementTypeBuilder) ModelTypeInstanceContext(org.camunda.bpm.model.xml.impl.instance.ModelTypeInstanceContext)

Example 70 with SequenceBuilder

use of org.camunda.bpm.model.xml.type.child.SequenceBuilder in project camunda-bpmn-model by camunda.

the class FlowElementImpl method registerType.

public static void registerType(ModelBuilder modelBuilder) {
    ModelElementTypeBuilder typeBuilder = modelBuilder.defineType(FlowElement.class, BPMN_ELEMENT_FLOW_ELEMENT).namespaceUri(BPMN20_NS).extendsType(BaseElement.class).abstractType();
    nameAttribute = typeBuilder.stringAttribute(BPMN_ATTRIBUTE_NAME).build();
    SequenceBuilder sequenceBuilder = typeBuilder.sequence();
    auditingChild = sequenceBuilder.element(Auditing.class).build();
    monitoringChild = sequenceBuilder.element(Monitoring.class).build();
    categoryValueRefCollection = sequenceBuilder.elementCollection(CategoryValueRef.class).qNameElementReferenceCollection(CategoryValue.class).build();
    typeBuilder.build();
}
Also used : SequenceBuilder(org.camunda.bpm.model.xml.type.child.SequenceBuilder) ModelElementTypeBuilder(org.camunda.bpm.model.xml.type.ModelElementTypeBuilder)

Aggregations

ModelElementTypeBuilder (org.camunda.bpm.model.xml.type.ModelElementTypeBuilder)152 SequenceBuilder (org.camunda.bpm.model.xml.type.child.SequenceBuilder)152 ModelTypeInstanceContext (org.camunda.bpm.model.xml.impl.instance.ModelTypeInstanceContext)133 BaseElement (org.camunda.bpm.model.bpmn.instance.BaseElement)14 CmmnElement (org.camunda.bpm.model.cmmn.instance.CmmnElement)13 Expression (org.camunda.bpm.model.dmn.instance.Expression)8 FlowElement (org.camunda.bpm.model.bpmn.instance.FlowElement)4 Task (org.camunda.bpm.model.cmmn.instance.Task)4 EventDefinition (org.camunda.bpm.model.bpmn.instance.EventDefinition)3 RootElement (org.camunda.bpm.model.bpmn.instance.RootElement)3 DmnElement (org.camunda.bpm.model.dmn.instance.DmnElement)3 DrgElement (org.camunda.bpm.model.dmn.instance.DrgElement)3 NamedElement (org.camunda.bpm.model.dmn.instance.NamedElement)3 ConversationNode (org.camunda.bpm.model.bpmn.instance.ConversationNode)2 CorrelationPropertyRetrievalExpression (org.camunda.bpm.model.bpmn.instance.CorrelationPropertyRetrievalExpression)2 Expression (org.camunda.bpm.model.bpmn.instance.Expression)2 FlowNode (org.camunda.bpm.model.bpmn.instance.FlowNode)2 Operation (org.camunda.bpm.model.bpmn.instance.Operation)2 Task (org.camunda.bpm.model.bpmn.instance.Task)2 Node (org.camunda.bpm.model.bpmn.instance.di.Node)2