1 /* 2 * Copyright 2007, Ingo Weinhold, ingo_weinhold@gmx.de. 3 * Distributed under the terms of the MIT License. 4 */ 5 6 #include "PartitionReference.h" 7 8 9 // constructor 10 PartitionReference::PartitionReference(partition_id id, uint32 changeCounter) 11 : Referenceable(true), // delete when unreferenced 12 fID(id), 13 fChangeCounter(changeCounter) 14 { 15 } 16 17 18 // destructor 19 PartitionReference::~PartitionReference() 20 { 21 } 22 23 24 // PartitionID 25 partition_id 26 PartitionReference::PartitionID() const 27 { 28 return fID; 29 } 30 31 32 // SetPartitionID 33 void 34 PartitionReference::SetPartitionID(partition_id id) 35 { 36 fID = id; 37 } 38 39 40 // ChangeCounter 41 uint32 42 PartitionReference::ChangeCounter() const 43 { 44 return fChangeCounter; 45 } 46 47 48 // SetChangeCounter 49 void 50 PartitionReference::SetChangeCounter(uint32 counter) 51 { 52 fChangeCounter = counter; 53 } 54