Search in sources :

Example 36 with SequenceBuilder

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

the class BpmnDiagramImpl method registerType.

public static void registerType(ModelBuilder modelBuilder) {
    ModelElementTypeBuilder typeBuilder = modelBuilder.defineType(BpmnDiagram.class, BPMNDI_ELEMENT_BPMN_DIAGRAM).namespaceUri(BPMNDI_NS).extendsType(Diagram.class).instanceProvider(new ModelTypeInstanceProvider<BpmnDiagram>() {

        public BpmnDiagram newInstance(ModelTypeInstanceContext instanceContext) {
            return new BpmnDiagramImpl(instanceContext);
        }
    });
    SequenceBuilder sequenceBuilder = typeBuilder.sequence();
    bpmnPlaneChild = sequenceBuilder.element(BpmnPlane.class).required().build();
    bpmnLabelStyleCollection = sequenceBuilder.elementCollection(BpmnLabelStyle.class).build();
    typeBuilder.build();
}
Also used : BpmnPlane(org.camunda.bpm.model.bpmn.instance.bpmndi.BpmnPlane) SequenceBuilder(org.camunda.bpm.model.xml.type.child.SequenceBuilder) ModelElementTypeBuilder(org.camunda.bpm.model.xml.type.ModelElementTypeBuilder) BpmnDiagram(org.camunda.bpm.model.bpmn.instance.bpmndi.BpmnDiagram) ModelTypeInstanceContext(org.camunda.bpm.model.xml.impl.instance.ModelTypeInstanceContext) BpmnDiagram(org.camunda.bpm.model.bpmn.instance.bpmndi.BpmnDiagram) Diagram(org.camunda.bpm.model.bpmn.instance.di.Diagram)

Example 37 with SequenceBuilder

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

the class BpmnEdgeImpl method registerType.

public static void registerType(ModelBuilder modelBuilder) {
    ModelElementTypeBuilder typeBuilder = modelBuilder.defineType(BpmnEdge.class, BPMNDI_ELEMENT_BPMN_EDGE).namespaceUri(BPMNDI_NS).extendsType(LabeledEdge.class).instanceProvider(new ModelTypeInstanceProvider<BpmnEdge>() {

        public BpmnEdge newInstance(ModelTypeInstanceContext instanceContext) {
            return new BpmnEdgeImpl(instanceContext);
        }
    });
    bpmnElementAttribute = typeBuilder.stringAttribute(BPMNDI_ATTRIBUTE_BPMN_ELEMENT).qNameAttributeReference(BaseElement.class).build();
    sourceElementAttribute = typeBuilder.stringAttribute(BPMNDI_ATTRIBUTE_SOURCE_ELEMENT).qNameAttributeReference(DiagramElement.class).build();
    targetElementAttribute = typeBuilder.stringAttribute(BPMNDI_ATTRIBUTE_TARGET_ELEMENT).qNameAttributeReference(DiagramElement.class).build();
    messageVisibleKindAttribute = typeBuilder.enumAttribute(BPMNDI_ATTRIBUTE_MESSAGE_VISIBLE_KIND, MessageVisibleKind.class).build();
    SequenceBuilder sequenceBuilder = typeBuilder.sequence();
    bpmnLabelChild = sequenceBuilder.element(BpmnLabel.class).build();
    typeBuilder.build();
}
Also used : SequenceBuilder(org.camunda.bpm.model.xml.type.child.SequenceBuilder) ModelElementTypeBuilder(org.camunda.bpm.model.xml.type.ModelElementTypeBuilder) BpmnEdge(org.camunda.bpm.model.bpmn.instance.bpmndi.BpmnEdge) ModelTypeInstanceContext(org.camunda.bpm.model.xml.impl.instance.ModelTypeInstanceContext) LabeledEdge(org.camunda.bpm.model.bpmn.instance.di.LabeledEdge)

Example 38 with SequenceBuilder

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

the class BpmnShapeImpl method registerType.

public static void registerType(ModelBuilder modelBuilder) {
    ModelElementTypeBuilder typeBuilder = modelBuilder.defineType(BpmnShape.class, BPMNDI_ELEMENT_BPMN_SHAPE).namespaceUri(BPMNDI_NS).extendsType(LabeledShape.class).instanceProvider(new ModelTypeInstanceProvider<BpmnShape>() {

        public BpmnShape newInstance(ModelTypeInstanceContext instanceContext) {
            return new BpmnShapeImpl(instanceContext);
        }
    });
    bpmnElementAttribute = typeBuilder.stringAttribute(BPMNDI_ATTRIBUTE_BPMN_ELEMENT).qNameAttributeReference(BaseElement.class).build();
    isHorizontalAttribute = typeBuilder.booleanAttribute(BPMNDI_ATTRIBUTE_IS_HORIZONTAL).build();
    isExpandedAttribute = typeBuilder.booleanAttribute(BPMNDI_ATTRIBUTE_IS_EXPANDED).build();
    isMarkerVisibleAttribute = typeBuilder.booleanAttribute(BPMNDI_ATTRIBUTE_IS_MARKER_VISIBLE).build();
    isMessageVisibleAttribute = typeBuilder.booleanAttribute(BPMNDI_ATTRIBUTE_IS_MESSAGE_VISIBLE).build();
    participantBandKindAttribute = typeBuilder.enumAttribute(BPMNDI_ATTRIBUTE_PARTICIPANT_BAND_KIND, ParticipantBandKind.class).build();
    choreographyActivityShapeAttribute = typeBuilder.stringAttribute(BPMNDI_ATTRIBUTE_CHOREOGRAPHY_ACTIVITY_SHAPE).qNameAttributeReference(BpmnShape.class).build();
    SequenceBuilder sequenceBuilder = typeBuilder.sequence();
    bpmnLabelChild = sequenceBuilder.element(BpmnLabel.class).build();
    typeBuilder.build();
}
Also used : LabeledShape(org.camunda.bpm.model.bpmn.instance.di.LabeledShape) BpmnShape(org.camunda.bpm.model.bpmn.instance.bpmndi.BpmnShape) 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 39 with SequenceBuilder

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

the class CamundaFormFieldImpl method registerType.

public static void registerType(ModelBuilder modelBuilder) {
    ModelElementTypeBuilder typeBuilder = modelBuilder.defineType(CamundaFormField.class, CAMUNDA_ELEMENT_FORM_FIELD).namespaceUri(CAMUNDA_NS).instanceProvider(new ModelTypeInstanceProvider<CamundaFormField>() {

        public CamundaFormField newInstance(ModelTypeInstanceContext instanceContext) {
            return new CamundaFormFieldImpl(instanceContext);
        }
    });
    camundaIdAttribute = typeBuilder.stringAttribute(CAMUNDA_ATTRIBUTE_ID).namespace(CAMUNDA_NS).build();
    camundaLabelAttribute = typeBuilder.stringAttribute(CAMUNDA_ATTRIBUTE_LABEL).namespace(CAMUNDA_NS).build();
    camundaTypeAttribute = typeBuilder.stringAttribute(CAMUNDA_ATTRIBUTE_TYPE).namespace(CAMUNDA_NS).build();
    camundaDatePatternAttribute = typeBuilder.stringAttribute(CAMUNDA_ATTRIBUTE_DATE_PATTERN).namespace(CAMUNDA_NS).build();
    camundaDefaultValueAttribute = typeBuilder.stringAttribute(CAMUNDA_ATTRIBUTE_DEFAULT_VALUE).namespace(CAMUNDA_NS).build();
    SequenceBuilder sequenceBuilder = typeBuilder.sequence();
    camundaPropertiesChild = sequenceBuilder.element(CamundaProperties.class).build();
    camundaValidationChild = sequenceBuilder.element(CamundaValidation.class).build();
    camundaValueCollection = sequenceBuilder.elementCollection(CamundaValue.class).build();
    typeBuilder.build();
}
Also used : SequenceBuilder(org.camunda.bpm.model.xml.type.child.SequenceBuilder) ModelElementTypeBuilder(org.camunda.bpm.model.xml.type.ModelElementTypeBuilder) CamundaFormField(org.camunda.bpm.model.bpmn.instance.camunda.CamundaFormField) ModelTypeInstanceContext(org.camunda.bpm.model.xml.impl.instance.ModelTypeInstanceContext)

Example 40 with SequenceBuilder

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

the class CamundaFormPropertyImpl method registerType.

public static void registerType(ModelBuilder modelBuilder) {
    ModelElementTypeBuilder typeBuilder = modelBuilder.defineType(CamundaFormProperty.class, CAMUNDA_ELEMENT_FORM_PROPERTY).namespaceUri(CAMUNDA_NS).instanceProvider(new ModelTypeInstanceProvider<CamundaFormProperty>() {

        public CamundaFormProperty newInstance(ModelTypeInstanceContext instanceContext) {
            return new CamundaFormPropertyImpl(instanceContext);
        }
    });
    camundaIdAttribute = typeBuilder.stringAttribute(CAMUNDA_ATTRIBUTE_ID).namespace(CAMUNDA_NS).build();
    camundaNameAttribute = typeBuilder.stringAttribute(CAMUNDA_ATTRIBUTE_NAME).namespace(CAMUNDA_NS).build();
    camundaTypeAttribute = typeBuilder.stringAttribute(CAMUNDA_ATTRIBUTE_TYPE).namespace(CAMUNDA_NS).build();
    camundaRequiredAttribute = typeBuilder.booleanAttribute(CAMUNDA_ATTRIBUTE_REQUIRED).namespace(CAMUNDA_NS).defaultValue(false).build();
    camundaReadableAttribute = typeBuilder.booleanAttribute(CAMUNDA_ATTRIBUTE_READABLE).namespace(CAMUNDA_NS).defaultValue(true).build();
    camundaWriteableAttribute = typeBuilder.booleanAttribute(CAMUNDA_ATTRIBUTE_WRITEABLE).namespace(CAMUNDA_NS).defaultValue(true).build();
    camundaVariableAttribute = typeBuilder.stringAttribute(CAMUNDA_ATTRIBUTE_VARIABLE).namespace(CAMUNDA_NS).build();
    camundaExpressionAttribute = typeBuilder.stringAttribute(CAMUNDA_ATTRIBUTE_EXPRESSION).namespace(CAMUNDA_NS).build();
    camundaDatePatternAttribute = typeBuilder.stringAttribute(CAMUNDA_ATTRIBUTE_DATE_PATTERN).namespace(CAMUNDA_NS).build();
    camundaDefaultAttribute = typeBuilder.stringAttribute(CAMUNDA_ATTRIBUTE_DEFAULT).namespace(CAMUNDA_NS).build();
    SequenceBuilder sequenceBuilder = typeBuilder.sequence();
    camundaValueCollection = sequenceBuilder.elementCollection(CamundaValue.class).build();
    typeBuilder.build();
}
Also used : CamundaFormProperty(org.camunda.bpm.model.bpmn.instance.camunda.CamundaFormProperty) 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)

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