View Javadoc
1   package com.github.celldynamics.quimp.filesystem.converter;
2   
3   import java.util.ArrayList;
4   import java.util.Collections;
5   import java.util.List;
6   
7   import com.github.celldynamics.quimp.plugin.AbstractPluginOptions;
8   
9   /**
10   * Keep status of {@link FormatConverterUi} checkboxes in {@link List}. Only active included.
11   * 
12   * <p>Name of the control is coded as Group:name stored as string.
13   * 
14   * @author p.baniukiewicz
15   *
16   */
17  public class FormatConverterModel extends AbstractPluginOptions {
18  
19    /**
20     * Keep status of checkboxes in {@link FormatConverterUi}. Only active are included, other are
21     * assumed to be unselected.
22     */
23    private List<String> status;
24  
25    /**
26     * Save one file with all snakes or many files with one snake.
27     */
28    public boolean areMultipleFiles = true;
29  
30    /**
31     * Return status map.
32     * 
33     * @return the status
34     */
35    public List<String> getStatus() {
36      return status;
37    }
38  
39    /**
40     * Default constructor.
41     */
42    public FormatConverterModel() {
43      status = Collections.synchronizedList(new ArrayList<String>());
44    }
45  
46    /*
47     * (non-Javadoc)
48     * 
49     * @see java.lang.Object#toString()
50     */
51    @Override
52    public String toString() {
53      return "FormatConverterModel [status=" + status + ", qconfFile=" + paramFile + "]";
54    }
55  
56    /*
57     * (non-Javadoc)
58     * 
59     * @see java.lang.Object#clone()
60     */
61    @Override
62    public Object clone() throws CloneNotSupportedException {
63      FormatConverterModellesystem/converter/FormatConverterModel.html#FormatConverterModel">FormatConverterModel cp = new FormatConverterModel();
64      cp.status = new ArrayList<>(this.status);
65      cp.paramFile = this.paramFile;
66      cp.areMultipleFiles = this.areMultipleFiles;
67      return cp;
68    }
69  
70  }