Merge branch 'releases/Release_2_11_3_Branch'
[jalview.git] / src / jalview / json / binding / biojson / v1 / SequencePojo.java
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.json.binding.biojson.v1;
22
23 import com.github.reinert.jjschema.Attributes;
24
25 public class SequencePojo
26 {
27   @Attributes(
28     required = true,
29     minLength = 3,
30     maxLength = 2147483647,
31     description = "Sequence residue characters. An aligned sequence may contain <br>one of the following gap characters &#x201c;.&#x201d;, &#x201c;-&#x201d; or &#x201c;&nbsp;&#x201d;")
32   private String seq;
33
34   @Attributes(required = true, description = "Sequence name")
35   private String name;
36
37   @Attributes(
38     required = false,
39     description = "Sequence type",
40     enums =
41     { "DNA", "RNA", "Protein" })
42   private String type;
43
44   @Attributes(
45     required = true,
46     description = "Unique identifier for a given Sequence")
47   private String id;
48
49   @Attributes(
50     required = false,
51     description = "The order/position of a sequence in the alignment space")
52   private int order;
53
54   @Attributes(
55     required = true,
56     description = "The index of the sequence’s first residue in its source database, <br>using a one-based numbering index system")
57   private int start;
58
59   @Attributes(
60     required = true,
61     description = "The index of the sequence’s last residue in its source database, <br>using a one-based numbering index system")
62   private int end;
63
64   public SequencePojo()
65   {
66   }
67
68   public SequencePojo(int start, int end, String id, String name,
69           String seq)
70   {
71     this.id = id;
72     this.name = name;
73     this.seq = seq;
74   }
75
76   public String getSeq()
77   {
78     return seq;
79   }
80
81   public void setSeq(String seq)
82   {
83     this.seq = seq;
84   }
85
86   public String getName()
87   {
88
89     return name;
90   }
91
92   public void setName(String name)
93   {
94     this.name = name;
95   }
96
97   public String getId()
98   {
99     return id;
100   }
101
102   public void setId(String id)
103   {
104     this.id = id;
105   }
106
107   public int getStart()
108   {
109     return start;
110   }
111
112   public void setStart(int start)
113   {
114     this.start = start;
115   }
116
117   public int getEnd()
118   {
119     return end;
120   }
121
122   public void setEnd(int end)
123   {
124     this.end = end;
125   }
126
127   public int getOrder()
128   {
129     return order;
130   }
131
132   public void setOrder(int order)
133   {
134     this.order = order;
135   }
136
137   public String getType()
138   {
139     return type;
140   }
141
142   public void setType(String type)
143   {
144     this.type = type;
145   }
146
147 }