com.innovenso.townplan.dsl.concepts.technology.TechnologyConfigurer.groovy Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of innovenso-townplanner-dsl Show documentation
Show all versions of innovenso-townplanner-dsl Show documentation
Domain Specific Language for the Innovenso Townplanner
package com.innovenso.townplan.dsl.concepts.technology
import com.innovenso.townplan.api.command.AddTechnologyCommand
import com.innovenso.townplan.api.value.enums.TechnologyType
import com.innovenso.townplan.domain.TownPlanImpl
import com.innovenso.townplan.dsl.TownPlanConfigurer
import com.innovenso.townplan.dsl.concepts.AbstractConceptConfigurer
import com.innovenso.townplan.dsl.traits.*
import jakarta.validation.constraints.NotNull
import lombok.NonNull
class TechnologyConfigurer extends AbstractConceptConfigurer implements HasDocumentation, HasExternalId, HasLifecycle, HasArchitectureVerdict, HasSwot, HasSecurity {
@NotNull
TechnologyType type
String recommendation
TechnologyConfigurer(@NonNull TownPlanConfigurer townPlanConfigurer) {
super(townPlanConfigurer)
}
def apply(@NonNull TownPlanImpl townPlan) {
townPlan.execute(AddTechnologyCommand.builder()
.key(key)
.title(title)
.description(description)
.type(type.label)
.technologyType(type)
.recommendation(recommendation)
.build())
}
@Override
String conceptType() {
return "IT Technology"
}
void type(TechnologyType type) {
this.type = type
}
void recommendation(String recommendation) {
this.recommendation = recommendation
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy