@@ -14,23 +14,23 @@ use std::{
1414#[ derive( Serialize , Deserialize , Debug , Clone ) ]
1515pub struct CoverageData {
1616 #[ serde( rename = "Sample" ) ]
17- sample_id : Option < String > ,
17+ pub sample_id : Option < String > ,
1818 #[ serde( rename = "Reference_Name" ) ]
19- reference_name : String ,
19+ pub reference_name : String ,
2020 #[ serde( rename = "Position" ) ]
21- position : String ,
21+ pub position : String ,
2222 #[ serde( rename = "Coverage Depth" ) ]
23- coverage_depth : String ,
23+ pub coverage_depth : String ,
2424 #[ serde( rename = "Consensus" ) ]
25- consensus : String ,
25+ pub consensus : String ,
2626 #[ serde( rename = "Deletions" ) ]
27- deletions : String ,
27+ pub deletions : String ,
2828 #[ serde( rename = "Ambiguous" ) ]
29- ambiguous : String ,
29+ pub ambiguous : String ,
3030 #[ serde( rename = "Consensus_Count" ) ]
31- consensus_count : String ,
31+ pub consensus_count : String ,
3232 #[ serde( rename = "Consensus_Average_Quality" ) ]
33- consensus_avg_quality : String ,
33+ pub consensus_avg_quality : String ,
3434 #[ serde( rename = "Run_ID" ) ]
3535 pub run_id : Option < String > ,
3636 #[ serde( rename = "Instrument" ) ]
@@ -68,62 +68,70 @@ pub struct ProcessedRecord {
6868}
6969
7070/// Alleles struct
71- #[ derive( Serialize , Deserialize , Debug ) ]
71+ #[ derive( Serialize , Deserialize , Debug , Clone ) ]
7272pub struct AllelesData {
7373 #[ serde( rename = "Reference_Name" ) ]
74- reference_name : String ,
74+ pub reference_name : String ,
7575 #[ serde( rename = "HMM_Position" ) ]
76- reference_position : Option < String > ,
76+ pub reference_position : Option < String > ,
7777 #[ serde( rename = "Position" ) ]
78- position : String ,
78+ pub position : String ,
7979 #[ serde( rename = "Total" ) ]
80- total : String ,
80+ pub total : String ,
8181 #[ serde( rename = "Consensus_Allele" ) ]
82- consensus_allele : String ,
82+ pub consensus_allele : String ,
8383 #[ serde( rename = "Minority_Allele" ) ]
84- minority_allele : String ,
84+ pub minority_allele : String ,
8585 #[ serde( rename = "Consensus_Count" ) ]
86- consensus_count : String ,
86+ pub consensus_count : String ,
8787 #[ serde( rename = "Minority_Count" ) ]
88- minority_count : String ,
88+ pub minority_count : String ,
8989 #[ serde( rename = "Minority_Frequency" ) ]
90- minority_frequency : String ,
91- sample_id : Option < String > ,
90+ pub minority_frequency : String ,
91+ pub sample_id : Option < String > ,
92+ #[ serde( rename = "Run_ID" ) ]
93+ pub run_id : Option < String > ,
94+ #[ serde( rename = "Instrument" ) ]
95+ pub instrument : Option < String > ,
9296}
9397
9498/// Indel struct
95- #[ derive( Serialize , Deserialize , Debug ) ]
99+ #[ derive( Serialize , Deserialize , Debug , Clone ) ]
96100pub struct IndelsData {
97101 #[ serde( rename = "Sample" ) ]
98- sample_id : Option < String > ,
102+ pub sample_id : Option < String > ,
99103 #[ serde( rename = "Reference_Name" ) ]
100- reference_name : String ,
104+ pub reference_name : String ,
101105 #[ serde( rename = "HMM_Position" ) ]
102- reference_upstream_position : Option < String > ,
106+ pub reference_upstream_position : Option < String > ,
103107 #[ serde( rename = "Upstream_Position" ) ]
104- sample_upstream_position : Option < String > ,
108+ pub sample_upstream_position : Option < String > ,
105109 #[ serde( rename = "Insert" ) ]
106- insert : Option < String > ,
110+ pub insert : Option < String > ,
107111 #[ serde( rename = "Length" ) ]
108- length : Option < String > ,
112+ pub length : Option < String > ,
109113 #[ serde( rename = "Context" ) ]
110- context : String ,
114+ pub context : String ,
111115 #[ serde( rename = "Called" ) ]
112- called : String ,
116+ pub called : String ,
113117 #[ serde( rename = "Count" ) ]
114- count : String ,
118+ pub count : String ,
115119 #[ serde( rename = "Total" ) ]
116- total : String ,
120+ pub total : String ,
117121 #[ serde( rename = "Frequency" ) ]
118- frequency : String ,
122+ pub frequency : String ,
119123 #[ serde( rename = "Average_Quality" ) ]
120- average_quality : Option < String > ,
124+ pub average_quality : Option < String > ,
121125 #[ serde( rename = "ConfidenceNotMacErr" ) ]
122- confidence_not_mac_err : Option < String > ,
126+ pub confidence_not_mac_err : Option < String > ,
123127 #[ serde( rename = "PairedUB" ) ]
124- paired_ub : String ,
128+ pub paired_ub : String ,
125129 #[ serde( rename = "QualityUB" ) ]
126- quality_ub : Option < String > ,
130+ pub quality_ub : Option < String > ,
131+ #[ serde( rename = "Run_ID" ) ]
132+ pub run_id : Option < String > ,
133+ #[ serde( rename = "Instrument" ) ]
134+ pub instrument : Option < String > ,
127135}
128136
129137#[ derive( Debug ) ]
@@ -137,87 +145,87 @@ pub struct SeqData {
137145#[ derive( Serialize , Deserialize , Debug ) ]
138146pub struct InsertionData {
139147 #[ serde( rename = "ID" ) ]
140- sample_id : Option < String > ,
148+ pub sample_id : Option < String > ,
141149 #[ serde( rename = "C_type" ) ]
142- ctype : Option < String > ,
150+ pub ctype : Option < String > ,
143151 #[ serde( rename = "Ref_ID" ) ]
144- reference : String ,
152+ pub reference : String ,
145153 #[ serde( rename = "Protein" ) ]
146- protein : String ,
154+ pub protein : String ,
147155 #[ serde( rename = "Upstream_aa" ) ]
148- upstream_aa_position : String ,
156+ pub upstream_aa_position : String ,
149157 #[ serde( rename = "Inserted_nucleotides" ) ]
150- inserted_nucleotides : String ,
158+ pub inserted_nucleotides : String ,
151159 #[ serde( rename = "Inserted_residues" ) ]
152- inserted_residues : String ,
160+ pub inserted_residues : String ,
153161 #[ serde( rename = "Upstream_nt" ) ]
154- upstream_nt : String ,
162+ pub upstream_nt : String ,
155163 #[ serde( rename = "Codon_shift" ) ]
156- in_frame : String ,
164+ pub in_frame : String ,
157165}
158166
159167/// Deletions Data
160168#[ derive( Serialize , Deserialize , Debug ) ]
161169pub struct DeletionsData {
162170 #[ serde( rename = "ID" ) ]
163- sample_id : Option < String > ,
171+ pub sample_id : Option < String > ,
164172 #[ serde( rename = "C_type" ) ]
165- ctype : Option < String > ,
173+ pub ctype : Option < String > ,
166174 #[ serde( rename = "Ref_ID" ) ]
167- reference : String ,
175+ pub reference : String ,
168176 #[ serde( rename = "Protein" ) ]
169- protein : String ,
177+ pub protein : String ,
170178 #[ serde( rename = "VH" ) ]
171- vh : Option < String > ,
179+ pub vh : Option < String > ,
172180 #[ serde( rename = "Del_AA_start" ) ]
173- del_start_aa_position : Option < String > ,
181+ pub del_start_aa_position : Option < String > ,
174182 #[ serde( rename = "Del_AA_end" ) ]
175- del_end_aa_position : Option < String > ,
183+ pub del_end_aa_position : Option < String > ,
176184 #[ serde( rename = "Del_AA_len" ) ]
177- del_aa_length : String ,
185+ pub del_aa_length : String ,
178186 #[ serde( rename = "In_frame" ) ]
179- in_frame : String ,
187+ pub in_frame : String ,
180188 #[ serde( rename = "CDS_ID" ) ]
181- cds_id : Option < String > ,
189+ pub cds_id : Option < String > ,
182190 #[ serde( rename = "Del_CDS_start" ) ]
183- del_start_cds_position : String ,
191+ pub del_start_cds_position : String ,
184192 #[ serde( rename = "Del_CDS_end" ) ]
185- del_end_cds_position : String ,
193+ pub del_end_cds_position : String ,
186194 #[ serde( rename = "Del_CDS_len" ) ]
187- del_cds_length : Option < String > ,
195+ pub del_cds_length : Option < String > ,
188196}
189197
190198/// Sequence Data
191199#[ derive( Serialize , Deserialize , Debug ) ]
192200pub struct DaisSeqData {
193201 #[ serde( rename = "ID" ) ]
194- sample_id : Option < String > ,
202+ pub sample_id : Option < String > ,
195203 #[ serde( rename = "C_type" ) ]
196- ctype : Option < String > ,
204+ pub ctype : Option < String > ,
197205 #[ serde( rename = "Ref_ID" ) ]
198- reference : String ,
206+ pub reference : String ,
199207 #[ serde( rename = "Protein" ) ]
200- protein : String ,
208+ pub protein : String ,
201209 #[ serde( rename = "VH" ) ]
202- vh : Option < String > ,
210+ pub vh : Option < String > ,
203211 #[ serde( rename = "AA_seq" ) ]
204- aa_seq : String ,
212+ pub aa_seq : String ,
205213 #[ serde( rename = "AA_aln" ) ]
206- aa_aln : String ,
214+ pub aa_aln : String ,
207215 #[ serde( rename = "CDS_ID" ) ]
208- cds_id : Option < String > ,
216+ pub cds_id : Option < String > ,
209217 #[ serde( rename = "Insertion" ) ]
210- insertion : String ,
218+ pub insertion : String ,
211219 #[ serde( rename = "Shift_Insert" ) ]
212- insertions_shift_frame : String ,
220+ pub insertions_shift_frame : String ,
213221 #[ serde( rename = "CDS_seq" ) ]
214- cds_sequence : String ,
222+ pub cds_sequence : String ,
215223 #[ serde( rename = "CDS_aln" ) ]
216- aligned_cds_sequence : String ,
224+ pub aligned_cds_sequence : String ,
217225 #[ serde( rename = "Query_nt_coordinates" ) ]
218- reference_nt_positions : String ,
226+ pub reference_nt_positions : String ,
219227 #[ serde( rename = "CDS_nt_coordinates" ) ]
220- sample_nt_positions : String ,
228+ pub sample_nt_positions : String ,
221229}
222230
223231/////////////// Imp for the process_txt_with_sample_function ///////////////
0 commit comments