File tree Expand file tree Collapse file tree 2 files changed +19
-1
lines changed Expand file tree Collapse file tree 2 files changed +19
-1
lines changed Original file line number Diff line number Diff line change @@ -427,7 +427,7 @@ pub use error::TskitError;
427
427
pub use flags:: * ;
428
428
pub use individual_table:: { IndividualTable , IndividualTableRow } ;
429
429
pub use migration_table:: { MigrationTable , MigrationTableRow } ;
430
- pub use mutation_table:: { MutationTable , MutationTableRow } ;
430
+ pub use mutation_table:: { MutationTable , MutationTableRow , OwnedMutationTable } ;
431
431
pub use node_table:: { NodeTable , NodeTableRow , OwnedNodeTable } ;
432
432
pub use population_table:: { OwnedPopulationTable , PopulationTable , PopulationTableRow } ;
433
433
pub use site_table:: { SiteTable , SiteTableRow } ;
Original file line number Diff line number Diff line change @@ -4,6 +4,7 @@ use crate::SizeType;
4
4
use crate :: Time ;
5
5
use crate :: { tsk_id_t, TskitError } ;
6
6
use crate :: { MutationId , NodeId , SiteId } ;
7
+ use ll_bindings:: { tsk_mutation_table_free, tsk_mutation_table_init} ;
7
8
8
9
/// Row of a [`MutationTable`]
9
10
pub struct MutationTableRow {
@@ -196,3 +197,20 @@ impl<'a> MutationTable<'a> {
196
197
table_row_access ! ( ri. 0 , self , make_mutation_table_row)
197
198
}
198
199
}
200
+
201
+ pub struct OwnedMutationTable {
202
+ table : mbox:: MBox < ll_bindings:: tsk_mutation_table_t > ,
203
+ }
204
+
205
+ impl OwnedMutationTable {
206
+ mutation_table_add_row ! ( => add_row, self , * self . table) ;
207
+ mutation_table_add_row_with_metadata ! ( => add_row_with_metadata, self , * self . table) ;
208
+ }
209
+
210
+ build_owned_tables ! (
211
+ OwnedMutationTable ,
212
+ MutationTable ,
213
+ ll_bindings:: tsk_mutation_table_t,
214
+ tsk_mutation_table_init,
215
+ tsk_mutation_table_free
216
+ ) ;
You can’t perform that action at this time.
0 commit comments