use of org.camunda.bpm.model.xml.type.child.SequenceBuilder in project camunda-cmmn-model by camunda.
the class CamundaVariableListenerImpl method registerType.
public static void registerType(ModelBuilder modelBuilder) {
ModelElementTypeBuilder typeBuilder = modelBuilder.defineType(CamundaVariableListener.class, CAMUNDA_ELEMENT_VARIABLE_LISTENER).namespaceUri(CAMUNDA_NS).instanceProvider(new ModelTypeInstanceProvider<CamundaVariableListener>() {
public CamundaVariableListener newInstance(ModelTypeInstanceContext instanceContext) {
return new CamundaVariableListenerImpl(instanceContext);
}
});
camundaEventAttribute = typeBuilder.stringAttribute(CAMUNDA_ATTRIBUTE_EVENT).namespace(CAMUNDA_NS).build();
camundaClassAttribute = typeBuilder.stringAttribute(CAMUNDA_ATTRIBUTE_CLASS).namespace(CAMUNDA_NS).build();
camundaExpressionAttribute = typeBuilder.stringAttribute(CAMUNDA_ATTRIBUTE_EXPRESSION).namespace(CAMUNDA_NS).build();
camundaDelegateExpressionAttribute = typeBuilder.stringAttribute(CAMUNDA_ATTRIBUTE_DELEGATE_EXPRESSION).namespace(CAMUNDA_NS).build();
SequenceBuilder sequenceBuilder = typeBuilder.sequence();
camundaFieldCollection = sequenceBuilder.elementCollection(CamundaField.class).build();
camundaScriptChild = sequenceBuilder.element(CamundaScript.class).build();
typeBuilder.build();
}
use of org.camunda.bpm.model.xml.type.child.SequenceBuilder in project camunda-xml-model by camunda.
the class Animal method registerType.
public static void registerType(ModelBuilder modelBuilder) {
ModelElementTypeBuilder typeBuilder = modelBuilder.defineType(Animal.class, TYPE_NAME_ANIMAL).namespaceUri(MODEL_NAMESPACE).abstractType();
idAttr = typeBuilder.stringAttribute(ATTRIBUTE_NAME_ID).idAttribute().build();
nameAttr = typeBuilder.stringAttribute(ATTRIBUTE_NAME_NAME).build();
fatherRef = typeBuilder.stringAttribute(ATTRIBUTE_NAME_FATHER).qNameAttributeReference(Animal.class).build();
motherRef = typeBuilder.stringAttribute(ATTRIBUTE_NAME_MOTHER).idAttributeReference(Animal.class).build();
isEndangeredAttr = typeBuilder.booleanAttribute(ATTRIBUTE_NAME_IS_ENDANGERED).defaultValue(false).build();
genderAttr = typeBuilder.enumAttribute(ATTRIBUTE_NAME_GENDER, Gender.class).required().build();
ageAttr = typeBuilder.integerAttribute(ATTRIBUTE_NAME_AGE).build();
bestFriendsRefCollection = typeBuilder.stringAttribute(ATTRIBUTE_NAME_BEST_FRIEND_REFS).idAttributeReferenceCollection(Animal.class, AnimalAttributeReferenceCollection.class).build();
SequenceBuilder sequence = typeBuilder.sequence();
relationshipDefinitionsColl = sequence.elementCollection(RelationshipDefinition.class).build();
relationshipDefinitionRefsColl = sequence.elementCollection(RelationshipDefinitionRef.class).qNameElementReferenceCollection(RelationshipDefinition.class).build();
typeBuilder.build();
}
use of org.camunda.bpm.model.xml.type.child.SequenceBuilder in project camunda-xml-model by camunda.
the class Egg method registerType.
public static void registerType(ModelBuilder modelBuilder) {
ModelElementTypeBuilder typeBuilder = modelBuilder.defineType(Egg.class, ELEMENT_NAME_EGG).namespaceUri(MODEL_NAMESPACE).instanceProvider(new ModelElementTypeBuilder.ModelTypeInstanceProvider<Egg>() {
public Egg newInstance(ModelTypeInstanceContext instanceContext) {
return new Egg(instanceContext);
}
});
idAttr = typeBuilder.stringAttribute(ATTRIBUTE_NAME_ID).idAttribute().build();
SequenceBuilder sequenceBuilder = typeBuilder.sequence();
motherRefChild = sequenceBuilder.element(Mother.class).uriElementReference(Animal.class).build();
guardianRefCollection = sequenceBuilder.elementCollection(Guardian.class).uriElementReferenceCollection(Animal.class).build();
typeBuilder.build();
}
use of org.camunda.bpm.model.xml.type.child.SequenceBuilder in project camunda-xml-model by camunda.
the class FlyingAnimal method registerType.
public static void registerType(ModelBuilder modelBuilder) {
ModelElementTypeBuilder typeBuilder = modelBuilder.defineType(FlyingAnimal.class, TYPE_NAME_FLYING_ANIMAL).namespaceUri(MODEL_NAMESPACE).extendsType(Animal.class).abstractType();
wingspanAttribute = typeBuilder.doubleAttribute(ATTRIBUTE_NAME_WINGSPAN).build();
SequenceBuilder sequence = typeBuilder.sequence();
flightInstructorChild = sequence.element(FlightInstructor.class).idElementReference(FlyingAnimal.class).build();
flightPartnerRefsColl = sequence.elementCollection(FlightPartnerRef.class).idElementReferenceCollection(FlyingAnimal.class).build();
typeBuilder.build();
}
use of org.camunda.bpm.model.xml.type.child.SequenceBuilder in project camunda-cmmn-model by camunda.
the class CaseFileItemOnPartImpl method registerType.
public static void registerType(ModelBuilder modelBuilder) {
ModelElementTypeBuilder typeBuilder = modelBuilder.defineType(CaseFileItemOnPart.class, CMMN_ELEMENT_CASE_FILE_ITEM_ON_PART).extendsType(OnPart.class).namespaceUri(CMMN11_NS).instanceProvider(new ModelTypeInstanceProvider<CaseFileItemOnPart>() {
public CaseFileItemOnPart newInstance(ModelTypeInstanceContext instanceContext) {
return new CaseFileItemOnPartImpl(instanceContext);
}
});
sourceRefAttribute = typeBuilder.stringAttribute(CMMN_ATTRIBUTE_SOURCE_REF).idAttributeReference(CaseFileItem.class).build();
SequenceBuilder sequenceBuilder = typeBuilder.sequence();
standardEventChild = sequenceBuilder.element(CaseFileItemTransitionStandardEvent.class).build();
typeBuilder.build();
}
Aggregations