Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
  /*
   * 
   */
  package net.officefloor.model.section;
  
  import java.util.List;
  
 
 
 @Generated("net.officefloor.model.generate.ModelGenerator")
 public class SubSectionModel extends AbstractModel implements ItemModel<SubSectionModel> {
 
     public static enum SubSectionEvent {
      CHANGE_SUB_SECTION_NAME, CHANGE_SECTION_SOURCE_CLASS_NAME, CHANGE_SECTION_LOCATION, ADD_PROPERTY, REMOVE_PROPERTY, ADD_SUB_SECTION_INPUT, REMOVE_SUB_SECTION_INPUT, ADD_SUB_SECTION_OUTPUT, REMOVE_SUB_SECTION_OUTPUT, ADD_SUB_SECTION_OBJECT, REMOVE_SUB_SECTION_OBJECT
     }

    
Default constructor.
 
     public SubSectionModel() {
     }

    
Convenience constructor for new non-linked instance.
 
     public SubSectionModel(
       String subSectionName
     , String sectionSourceClassName
     , String sectionLocation
     ) {
         this. = subSectionName;
         this. = sectionSourceClassName;
         this. = sectionLocation;
     }

    
Convenience constructor.
 
     public SubSectionModel(
       String subSectionName
     , String sectionSourceClassName
     , String sectionLocation
     , PropertyModel[] property
     , SubSectionInputModel[] subSectionInput
     , SubSectionOutputModel[] subSectionOutput
     , SubSectionObjectModel[] subSectionObject
     ) {
         this. = subSectionName;
         this. = sectionSourceClassName;
         this. = sectionLocation;
         if (property != null) {
             for (PropertyModel model : property) {
                 this..add(model);
             }
         }
         if (subSectionInput != null) {
             for (SubSectionInputModel model : subSectionInput) {
                 this..add(model);
             }
         }
         if (subSectionOutput != null) {
             for (SubSectionOutputModel model : subSectionOutput) {
                 this..add(model);
             }
         }
         if (subSectionObject != null) {
             for (SubSectionObjectModel model : subSectionObject) {
                 this..add(model);
             }
         }
     }

    
Convenience constructor allowing XY initialising.
 
     public SubSectionModel(
       String subSectionName
     , String sectionSourceClassName
     , String sectionLocation
     , PropertyModel[] property
     , SubSectionInputModel[] subSectionInput
     , SubSectionOutputModel[] subSectionOutput
     , SubSectionObjectModel[] subSectionObject
     , int x
     , int y
     ) {
         this. = subSectionName;
         this. = sectionSourceClassName;
         this. = sectionLocation;
         if (property != null) {
             for (PropertyModel model : property) {
                 this..add(model);
             }
         }
        if (subSectionInput != null) {
            for (SubSectionInputModel model : subSectionInput) {
                this..add(model);
            }
        }
        if (subSectionOutput != null) {
            for (SubSectionOutputModel model : subSectionOutput) {
                this..add(model);
            }
        }
        if (subSectionObject != null) {
            for (SubSectionObjectModel model : subSectionObject) {
                this..add(model);
            }
        }
        this.setX(x);
        this.setY(y);
    }

    
Sub section name.
    private String subSectionName;
    public String getSubSectionName() {
        return this.;
    }
    public void setSubSectionName(String subSectionName) {
        String oldValue = this.;
        this. = subSectionName;
        this.changeField(oldValuethis..);
    }

    
Section source class name.
    public String getSectionSourceClassName() {
        return this.;
    }
    public void setSectionSourceClassName(String sectionSourceClassName) {
        String oldValue = this.;
        this. = sectionSourceClassName;
    }

    
Section location.
    private String sectionLocation;
    public String getSectionLocation() {
        return this.;
    }
    public void setSectionLocation(String sectionLocation) {
        String oldValue = this.;
        this. = sectionLocation;
    }


    
Property.
    private List<PropertyModelproperty = new LinkedList<PropertyModel>();
    public List<PropertyModelgetProperties() {
        return this.;
    }
    public void addProperty(PropertyModel property) {
        this.addItemToList(propertythis..);
    }
    public void removeProperty(PropertyModel property) {
        this.removeItemFromList(propertythis..);
    }

    
Sub section input.
        return this.;
    }
    public void addSubSectionInput(SubSectionInputModel subSectionInput) {
        this.addItemToList(subSectionInputthis..);
    }
    public void removeSubSectionInput(SubSectionInputModel subSectionInput) {
        this.removeItemFromList(subSectionInputthis..);
    }

    
Sub section output.
        return this.;
    }
    public void addSubSectionOutput(SubSectionOutputModel subSectionOutput) {
        this.addItemToList(subSectionOutputthis..);
    }
    public void removeSubSectionOutput(SubSectionOutputModel subSectionOutput) {
        this.removeItemFromList(subSectionOutputthis..);
    }

    
Sub section object.
        return this.;
    }
    public void addSubSectionObject(SubSectionObjectModel subSectionObject) {
        this.addItemToList(subSectionObjectthis..);
    }
    public void removeSubSectionObject(SubSectionObjectModel subSectionObject) {
        this.removeItemFromList(subSectionObjectthis..);
    }


    
Remove Connections.
        for (SubSectionInputModel _cascade : this.) {
            _action.addCascadeModel(_cascade.removeConnections());
        }
        for (SubSectionOutputModel _cascade : this.) {
            _action.addCascadeModel(_cascade.removeConnections());
        }
        for (SubSectionObjectModel _cascade : this.) {
            _action.addCascadeModel(_cascade.removeConnections());
        }
        return _action;
    }
New to GrepCode? Check out our FAQ X