diff --git a/include/PartitionVector.h b/include/PartitionVector.h index f1d6c33e..1f0f67a7 100644 --- a/include/PartitionVector.h +++ b/include/PartitionVector.h @@ -71,6 +71,8 @@ public: void clear(); void push_back( const Partition & partition ); void insert( iterator position, const Partition & partition ); + void push_back_adopt( Partition * partition ); + void insert_adopt( iterator position, Partition * partition ); private: std::vector v; diff --git a/src/PartitionVector.cc b/src/PartitionVector.cc index f05bedfd..c35ebf9d 100644 --- a/src/PartitionVector.cc +++ b/src/PartitionVector.cc @@ -85,4 +85,14 @@ void PartitionVector::insert( iterator position, const Partition & partition ) v.insert( position, p ); } +void PartitionVector::push_back_adopt( Partition * partition ) +{ + v.push_back( partition ); +} + +void PartitionVector::insert_adopt( iterator position, Partition * partition ) +{ + v.insert( position, partition ); +} + } //GParted