Search in sources :

Example 66 with ModelTypeInstanceContext

use of org.camunda.bpm.model.xml.impl.instance.ModelTypeInstanceContext in project camunda-cmmn-model by camunda.

the class SentryImpl method registerType.

public static void registerType(ModelBuilder modelBuilder) {
    ModelElementTypeBuilder typeBuilder = modelBuilder.defineType(Sentry.class, CMMN_ELEMENT_SENTRY).extendsType(CmmnElement.class).namespaceUri(CMMN11_NS).instanceProvider(new ModelTypeInstanceProvider<Sentry>() {

        public Sentry newInstance(ModelTypeInstanceContext instanceContext) {
            return new SentryImpl(instanceContext);
        }
    });
    nameAttribute = typeBuilder.stringAttribute(CMMN_ATTRIBUTE_NAME).build();
    SequenceBuilder sequenceBuilder = typeBuilder.sequence();
    onPartCollection = sequenceBuilder.elementCollection(OnPart.class).build();
    ifPartChild = sequenceBuilder.element(IfPart.class).build();
    typeBuilder.build();
}
Also used : SequenceBuilder(org.camunda.bpm.model.xml.type.child.SequenceBuilder) ModelElementTypeBuilder(org.camunda.bpm.model.xml.type.ModelElementTypeBuilder) Sentry(org.camunda.bpm.model.cmmn.instance.Sentry) ModelTypeInstanceContext(org.camunda.bpm.model.xml.impl.instance.ModelTypeInstanceContext)

Example 67 with ModelTypeInstanceContext

use of org.camunda.bpm.model.xml.impl.instance.ModelTypeInstanceContext in project camunda-cmmn-model by camunda.

the class TargetImpl method registerType.

public static void registerType(ModelBuilder modelBuilder) {
    ModelElementTypeBuilder typeBuilder = modelBuilder.defineType(Target.class, CMMN_ELEMENT_TARGET).namespaceUri(CMMN11_NS).instanceProvider(new ModelTypeInstanceProvider<Target>() {

        public Target newInstance(ModelTypeInstanceContext instanceContext) {
            return new TargetImpl(instanceContext);
        }
    });
    typeBuilder.build();
}
Also used : Target(org.camunda.bpm.model.cmmn.instance.Target) ModelElementTypeBuilder(org.camunda.bpm.model.xml.type.ModelElementTypeBuilder) ModelTypeInstanceContext(org.camunda.bpm.model.xml.impl.instance.ModelTypeInstanceContext)

Example 68 with ModelTypeInstanceContext

use of org.camunda.bpm.model.xml.impl.instance.ModelTypeInstanceContext in project camunda-cmmn-model by camunda.

the class TaskImpl method registerType.

public static void registerType(ModelBuilder modelBuilder) {
    ModelElementTypeBuilder typeBuilder = modelBuilder.defineType(Task.class, CMMN_ELEMENT_TASK).namespaceUri(CMMN11_NS).extendsType(PlanItemDefinition.class).instanceProvider(new ModelTypeInstanceProvider<Task>() {

        public Task newInstance(ModelTypeInstanceContext instanceContext) {
            return new TaskImpl(instanceContext);
        }
    });
    isBlockingAttribute = typeBuilder.booleanAttribute(CMMN_ATTRIBUTE_IS_BLOCKING).defaultValue(true).build();
    SequenceBuilder sequenceBuilder = typeBuilder.sequence();
    inputsCollection = sequenceBuilder.elementCollection(InputsCaseParameter.class).build();
    outputsCollection = sequenceBuilder.elementCollection(OutputsCaseParameter.class).build();
    inputParameterCollection = sequenceBuilder.elementCollection(InputCaseParameter.class).build();
    outputParameterCollection = sequenceBuilder.elementCollection(OutputCaseParameter.class).build();
    typeBuilder.build();
}
Also used : Task(org.camunda.bpm.model.cmmn.instance.Task) PlanItemDefinition(org.camunda.bpm.model.cmmn.instance.PlanItemDefinition) 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 69 with ModelTypeInstanceContext

use of org.camunda.bpm.model.xml.impl.instance.ModelTypeInstanceContext in project camunda-cmmn-model by camunda.

the class TextImpl method registerType.

public static void registerType(ModelBuilder modelBuilder) {
    ModelElementTypeBuilder typeBuilder = modelBuilder.defineType(Text.class, CMMN_ELEMENT_TEXT).namespaceUri(CMMN11_NS).instanceProvider(new ModelTypeInstanceProvider<Text>() {

        public Text newInstance(ModelTypeInstanceContext instanceContext) {
            return new TextImpl(instanceContext);
        }
    });
    typeBuilder.build();
}
Also used : ModelElementTypeBuilder(org.camunda.bpm.model.xml.type.ModelElementTypeBuilder) Text(org.camunda.bpm.model.cmmn.instance.Text) ModelTypeInstanceContext(org.camunda.bpm.model.xml.impl.instance.ModelTypeInstanceContext)

Example 70 with ModelTypeInstanceContext

use of org.camunda.bpm.model.xml.impl.instance.ModelTypeInstanceContext in project camunda-cmmn-model by camunda.

the class TimerEventImpl method registerType.

public static void registerType(ModelBuilder modelBuilder) {
    ModelElementTypeBuilder typeBuilder = modelBuilder.defineType(TimerEvent.class, CMMN_ELEMENT_TIMER_EVENT).namespaceUri(CMMN10_NS).extendsType(Event.class).instanceProvider(new ModelTypeInstanceProvider<TimerEvent>() {

        public TimerEvent newInstance(ModelTypeInstanceContext instanceContext) {
            return new TimerEventImpl(instanceContext);
        }
    });
    SequenceBuilder sequenceBuilder = typeBuilder.sequence();
    timerExpressionChild = sequenceBuilder.element(TimerExpression.class).build();
    timerStartChild = sequenceBuilder.element(StartTrigger.class).build();
    typeBuilder.build();
}
Also used : SequenceBuilder(org.camunda.bpm.model.xml.type.child.SequenceBuilder) ModelElementTypeBuilder(org.camunda.bpm.model.xml.type.ModelElementTypeBuilder) TimerEvent(org.camunda.bpm.model.cmmn.instance.TimerEvent) TimerEvent(org.camunda.bpm.model.cmmn.instance.TimerEvent) Event(org.camunda.bpm.model.cmmn.instance.Event) ModelTypeInstanceContext(org.camunda.bpm.model.xml.impl.instance.ModelTypeInstanceContext)

Aggregations

ModelTypeInstanceContext (org.camunda.bpm.model.xml.impl.instance.ModelTypeInstanceContext)373 ModelElementTypeBuilder (org.camunda.bpm.model.xml.type.ModelElementTypeBuilder)373 SequenceBuilder (org.camunda.bpm.model.xml.type.child.SequenceBuilder)133 BaseElement (org.camunda.bpm.model.bpmn.instance.BaseElement)27 DmnElementReference (org.camunda.bpm.model.dmn.instance.DmnElementReference)23 CmmnElement (org.camunda.bpm.model.cmmn.instance.CmmnElement)14 Expression (org.camunda.bpm.model.bpmn.instance.Expression)13 EventDefinition (org.camunda.bpm.model.bpmn.instance.EventDefinition)9 RootElement (org.camunda.bpm.model.bpmn.instance.RootElement)9 Task (org.camunda.bpm.model.bpmn.instance.Task)8 Expression (org.camunda.bpm.model.cmmn.instance.Expression)8 Expression (org.camunda.bpm.model.dmn.instance.Expression)8 FormalExpression (org.camunda.bpm.model.bpmn.instance.FormalExpression)5 InformationItem (org.camunda.bpm.model.dmn.instance.InformationItem)5 LiteralExpression (org.camunda.bpm.model.dmn.instance.LiteralExpression)5 NamedElement (org.camunda.bpm.model.dmn.instance.NamedElement)5 Gateway (org.camunda.bpm.model.bpmn.instance.Gateway)4 CaseParameter (org.camunda.bpm.model.cmmn.instance.CaseParameter)4 PlanItemDefinition (org.camunda.bpm.model.cmmn.instance.PlanItemDefinition)4 Task (org.camunda.bpm.model.cmmn.instance.Task)4