Clover icon

Coverage Report

  1. Project Clover database Tue Oct 29 2024 21:36:55 GMT
  2. Package jalview.datamodel

File AlignExportSettingsAdapter.java

 

Coverage histogram

../../img/srcFileCovDistChart7.png
29% of files have more coverage

Code metrics

0
15
11
1
110
63
11
0.73
1.36
11
1

Classes

Class Line # Actions
AlignExportSettingsAdapter 29 15 11
0.6153846461.5%
 

Contributing tests

This file is covered by 20 tests. .

Source view

1    /*
2    * Jalview - A Sequence Alignment Editor and Viewer ($$Version-Rel$$)
3    * Copyright (C) $$Year-Rel$$ The Jalview Authors
4    *
5    * This file is part of Jalview.
6    *
7    * Jalview is free software: you can redistribute it and/or
8    * modify it under the terms of the GNU General Public License
9    * as published by the Free Software Foundation, either version 3
10    * of the License, or (at your option) any later version.
11    *
12    * Jalview is distributed in the hope that it will be useful, but
13    * WITHOUT ANY WARRANTY; without even the implied warranty
14    * of MERCHANTABILITY or FITNESS FOR A PARTICULAR
15    * PURPOSE. See the GNU General Public License for more details.
16    *
17    * You should have received a copy of the GNU General Public License
18    * along with Jalview. If not, see <http://www.gnu.org/licenses/>.
19    * The Jalview Authors are detailed in the 'AUTHORS' file.
20    */
21    package jalview.datamodel;
22   
23    import jalview.api.AlignExportSettingsI;
24   
25    /**
26    * Export options that may be constructed as 'all' or 'none' (and further
27    * adjusted if wanted)
28    */
 
29    public class AlignExportSettingsAdapter implements AlignExportSettingsI
30    {
31    private boolean exportHiddenSeqs;
32   
33    private boolean exportHiddenCols;
34   
35    private boolean exportAnnotations;
36   
37    private boolean exportFeatures;
38   
39    private boolean exportGroups;
40   
41    /**
42    * Constructor sets all options to either true or false
43    *
44    * @param defaultOption
45    */
 
46  127 toggle public AlignExportSettingsAdapter(boolean defaultOption)
47    {
48  127 exportAnnotations = defaultOption;
49  127 exportFeatures = defaultOption;
50  127 exportGroups = defaultOption;
51  127 exportHiddenCols = defaultOption;
52  127 exportHiddenSeqs = defaultOption;
53    }
54   
 
55  5 toggle @Override
56    public boolean isExportHiddenSequences()
57    {
58  5 return exportHiddenSeqs;
59    }
60   
 
61  5 toggle @Override
62    public boolean isExportHiddenColumns()
63    {
64  5 return exportHiddenCols;
65    }
66   
 
67  8 toggle @Override
68    public boolean isExportAnnotations()
69    {
70  8 return exportAnnotations;
71    }
72   
 
73  8 toggle @Override
74    public boolean isExportFeatures()
75    {
76  8 return exportFeatures;
77    }
78   
 
79  8 toggle @Override
80    public boolean isExportGroups()
81    {
82  8 return exportGroups;
83    }
84   
 
85  0 toggle public void setExportHiddenSequences(boolean exportHiddenSeqs)
86    {
87  0 this.exportHiddenSeqs = exportHiddenSeqs;
88    }
89   
 
90  0 toggle public void setExportHiddenColumns(boolean exportHiddenCols)
91    {
92  0 this.exportHiddenCols = exportHiddenCols;
93    }
94   
 
95  0 toggle public void setExportAnnotations(boolean exportAnnotations)
96    {
97  0 this.exportAnnotations = exportAnnotations;
98    }
99   
 
100  0 toggle public void setExportFeatures(boolean exportFeatures)
101    {
102  0 this.exportFeatures = exportFeatures;
103    }
104   
 
105  0 toggle public void setExportGroups(boolean exportGroups)
106    {
107  0 this.exportGroups = exportGroups;
108    }
109   
110    }