package com.ruoyi.generator.domain.front.dto;

import java.util.ArrayList;
import java.util.List;

public class BusinessLoopPlan
{
    private String domainName;
    private List<BusinessLoopObject> coreObjects = new ArrayList<BusinessLoopObject>();
    private List<BusinessLoopStateMachine> stateMachines = new ArrayList<BusinessLoopStateMachine>();
    private List<BusinessLoopAction> actions = new ArrayList<BusinessLoopAction>();
    private List<BusinessLoopQuantityEffect> quantityRules = new ArrayList<BusinessLoopQuantityEffect>();
    private List<BusinessLoopRecordEffect> recordRules = new ArrayList<BusinessLoopRecordEffect>();
    private List<BusinessLoopPageBinding> pageBindings = new ArrayList<BusinessLoopPageBinding>();
    private List<BusinessLoopAcceptanceScenario> acceptanceScenarios = new ArrayList<BusinessLoopAcceptanceScenario>();

    public String getDomainName() { return domainName; }
    public void setDomainName(String domainName) { this.domainName = domainName; }
    public List<BusinessLoopObject> getCoreObjects() { return coreObjects; }
    public void setCoreObjects(List<BusinessLoopObject> coreObjects) { this.coreObjects = coreObjects == null ? new ArrayList<BusinessLoopObject>() : coreObjects; }
    public List<BusinessLoopStateMachine> getStateMachines() { return stateMachines; }
    public void setStateMachines(List<BusinessLoopStateMachine> stateMachines) { this.stateMachines = stateMachines == null ? new ArrayList<BusinessLoopStateMachine>() : stateMachines; }
    public List<BusinessLoopAction> getActions() { return actions; }
    public void setActions(List<BusinessLoopAction> actions) { this.actions = actions == null ? new ArrayList<BusinessLoopAction>() : actions; }
    public List<BusinessLoopQuantityEffect> getQuantityRules() { return quantityRules; }
    public void setQuantityRules(List<BusinessLoopQuantityEffect> quantityRules) { this.quantityRules = quantityRules == null ? new ArrayList<BusinessLoopQuantityEffect>() : quantityRules; }
    public List<BusinessLoopRecordEffect> getRecordRules() { return recordRules; }
    public void setRecordRules(List<BusinessLoopRecordEffect> recordRules) { this.recordRules = recordRules == null ? new ArrayList<BusinessLoopRecordEffect>() : recordRules; }
    public List<BusinessLoopPageBinding> getPageBindings() { return pageBindings; }
    public void setPageBindings(List<BusinessLoopPageBinding> pageBindings) { this.pageBindings = pageBindings == null ? new ArrayList<BusinessLoopPageBinding>() : pageBindings; }
    public List<BusinessLoopAcceptanceScenario> getAcceptanceScenarios() { return acceptanceScenarios; }
    public void setAcceptanceScenarios(List<BusinessLoopAcceptanceScenario> acceptanceScenarios) { this.acceptanceScenarios = acceptanceScenarios == null ? new ArrayList<BusinessLoopAcceptanceScenario>() : acceptanceScenarios; }

    public static class BusinessLoopObject
    {
        private String code;
        private String name;
        private String tableName;
        private String objectType;

        public String getCode() { return code; }
        public void setCode(String code) { this.code = code; }
        public String getName() { return name; }
        public void setName(String name) { this.name = name; }
        public String getTableName() { return tableName; }
        public void setTableName(String tableName) { this.tableName = tableName; }
        public String getObjectType() { return objectType; }
        public void setObjectType(String objectType) { this.objectType = objectType; }
    }

    public static class BusinessLoopStateMachine
    {
        private String objectCode;
        private String tableName;
        private String statusField;
        private List<String> states = new ArrayList<String>();
        private List<BusinessLoopStateTransition> transitions = new ArrayList<BusinessLoopStateTransition>();

        public String getObjectCode() { return objectCode; }
        public void setObjectCode(String objectCode) { this.objectCode = objectCode; }
        public String getTableName() { return tableName; }
        public void setTableName(String tableName) { this.tableName = tableName; }
        public String getStatusField() { return statusField; }
        public void setStatusField(String statusField) { this.statusField = statusField; }
        public List<String> getStates() { return states; }
        public void setStates(List<String> states) { this.states = states == null ? new ArrayList<String>() : states; }
        public List<BusinessLoopStateTransition> getTransitions() { return transitions; }
        public void setTransitions(List<BusinessLoopStateTransition> transitions) { this.transitions = transitions == null ? new ArrayList<BusinessLoopStateTransition>() : transitions; }
    }

    public static class BusinessLoopStateTransition
    {
        private String actionCode;
        private String fromState;
        private String toState;

        public String getActionCode() { return actionCode; }
        public void setActionCode(String actionCode) { this.actionCode = actionCode; }
        public String getFromState() { return fromState; }
        public void setFromState(String fromState) { this.fromState = fromState; }
        public String getToState() { return toState; }
        public void setToState(String toState) { this.toState = toState; }
    }

    public static class BusinessLoopAction
    {
        private String code;
        private String name;
        private String actor;
        private String ownerObject;
        private String ownerTable;
        private String triggerPage;
        private boolean required;
        private List<String> preconditions = new ArrayList<String>();
        private List<BusinessLoopStateTransition> stateTransitions = new ArrayList<BusinessLoopStateTransition>();
        private List<BusinessLoopQuantityEffect> quantityEffects = new ArrayList<BusinessLoopQuantityEffect>();
        private List<BusinessLoopRecordEffect> recordEffects = new ArrayList<BusinessLoopRecordEffect>();

        public String getCode() { return code; }
        public void setCode(String code) { this.code = code; }
        public String getName() { return name; }
        public void setName(String name) { this.name = name; }
        public String getActor() { return actor; }
        public void setActor(String actor) { this.actor = actor; }
        public String getOwnerObject() { return ownerObject; }
        public void setOwnerObject(String ownerObject) { this.ownerObject = ownerObject; }
        public String getOwnerTable() { return ownerTable; }
        public void setOwnerTable(String ownerTable) { this.ownerTable = ownerTable; }
        public String getTriggerPage() { return triggerPage; }
        public void setTriggerPage(String triggerPage) { this.triggerPage = triggerPage; }
        public boolean isRequired() { return required; }
        public void setRequired(boolean required) { this.required = required; }
        public List<String> getPreconditions() { return preconditions; }
        public void setPreconditions(List<String> preconditions) { this.preconditions = preconditions == null ? new ArrayList<String>() : preconditions; }
        public List<BusinessLoopStateTransition> getStateTransitions() { return stateTransitions; }
        public void setStateTransitions(List<BusinessLoopStateTransition> stateTransitions) { this.stateTransitions = stateTransitions == null ? new ArrayList<BusinessLoopStateTransition>() : stateTransitions; }
        public List<BusinessLoopQuantityEffect> getQuantityEffects() { return quantityEffects; }
        public void setQuantityEffects(List<BusinessLoopQuantityEffect> quantityEffects) { this.quantityEffects = quantityEffects == null ? new ArrayList<BusinessLoopQuantityEffect>() : quantityEffects; }
        public List<BusinessLoopRecordEffect> getRecordEffects() { return recordEffects; }
        public void setRecordEffects(List<BusinessLoopRecordEffect> recordEffects) { this.recordEffects = recordEffects == null ? new ArrayList<BusinessLoopRecordEffect>() : recordEffects; }
    }

    public static class BusinessLoopQuantityEffect
    {
        private String actionCode;
        private String objectCode;
        private String tableName;
        private String quantityField;
        private String effectType;
        private String amount;

        public String getActionCode() { return actionCode; }
        public void setActionCode(String actionCode) { this.actionCode = actionCode; }
        public String getObjectCode() { return objectCode; }
        public void setObjectCode(String objectCode) { this.objectCode = objectCode; }
        public String getTableName() { return tableName; }
        public void setTableName(String tableName) { this.tableName = tableName; }
        public String getQuantityField() { return quantityField; }
        public void setQuantityField(String quantityField) { this.quantityField = quantityField; }
        public String getEffectType() { return effectType; }
        public void setEffectType(String effectType) { this.effectType = effectType; }
        public String getAmount() { return amount; }
        public void setAmount(String amount) { this.amount = amount; }
    }

    public static class BusinessLoopRecordEffect
    {
        private String actionCode;
        private String objectCode;
        private String tableName;
        private String operation;

        public String getActionCode() { return actionCode; }
        public void setActionCode(String actionCode) { this.actionCode = actionCode; }
        public String getObjectCode() { return objectCode; }
        public void setObjectCode(String objectCode) { this.objectCode = objectCode; }
        public String getTableName() { return tableName; }
        public void setTableName(String tableName) { this.tableName = tableName; }
        public String getOperation() { return operation; }
        public void setOperation(String operation) { this.operation = operation; }
    }

    public static class BusinessLoopPageBinding
    {
        private String actionCode;
        private String target;
        private String pageCode;
        private String tableName;
        private String slot;

        public String getActionCode() { return actionCode; }
        public void setActionCode(String actionCode) { this.actionCode = actionCode; }
        public String getTarget() { return target; }
        public void setTarget(String target) { this.target = target; }
        public String getPageCode() { return pageCode; }
        public void setPageCode(String pageCode) { this.pageCode = pageCode; }
        public String getTableName() { return tableName; }
        public void setTableName(String tableName) { this.tableName = tableName; }
        public String getSlot() { return slot; }
        public void setSlot(String slot) { this.slot = slot; }
    }

    public static class BusinessLoopAcceptanceScenario
    {
        private String name;
        private List<String> steps = new ArrayList<String>();
        private List<String> expectedResults = new ArrayList<String>();

        public String getName() { return name; }
        public void setName(String name) { this.name = name; }
        public List<String> getSteps() { return steps; }
        public void setSteps(List<String> steps) { this.steps = steps == null ? new ArrayList<String>() : steps; }
        public List<String> getExpectedResults() { return expectedResults; }
        public void setExpectedResults(List<String> expectedResults) { this.expectedResults = expectedResults == null ? new ArrayList<String>() : expectedResults; }
    }
}
