Update contrib.
1 // Copyright (c) 1998-2009 Nokia Corporation and/or its subsidiary(-ies).
2 // All rights reserved.
3 // This component and the accompanying materials are made available
4 // under the terms of "Eclipse Public License v1.0"
5 // which accompanies this distribution, and is available
6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
8 // Initial Contributors:
9 // Nokia Corporation - initial contribution.
16 // Class CDbTableIndexDef
17 inline const TDesC& CDbTableIndexDef::Name() const
19 inline const CDbKey& CDbTableIndexDef::Key() const
21 inline CDbKey& CDbTableIndexDef::Key()
24 inline void RDbIndexes::Add(CDbTableIndexDef* aDef)
25 {iRep.AddLast(*aDef);}
26 inline void RDbIndexes::Remove(CDbTableIndexDef* aDef)
28 inline const TSglQueBase& RDbIndexes::AsQue() const
32 inline TDbColType TDbColumnDef::Type() const
33 {return TDbColType(iType);}
36 inline HDbColumnSet::TIterator HDbColumnSet::Begin()
37 {return &iColumns[0];}
38 inline HDbColumnSet::TIteratorC HDbColumnSet::Begin() const
39 {return &iColumns[0];}
40 inline HDbColumnSet::TIteratorC HDbColumnSet::End() const
42 inline TBool HDbColumnSet::HasLongColumns() const
43 {return iAttributes&ELongColumns;}
44 inline TBool HDbColumnSet::HasAutoIncrement() const
45 {return iAttributes&EAutoIncrement;}
46 inline const TDbColumnDef& HDbColumnSet::operator[](TDbColNo aColNo) const
47 {return iColumns[aColNo-1];}
50 inline const HDbColumnSet& CDbTableDef::Columns() const
52 inline HDbColumnSet& CDbTableDef::Columns()
54 inline const TDesC& CDbTableDef::Name() const
56 inline RDbIndexes& CDbTableDef::Indexes()
58 inline const RDbIndexes& CDbTableDef::Indexes() const
60 inline const CDbTableIndexDef* CDbTableDef::Key(const TDesC& aColumn) const
61 {return FindKey(aColumn,ETrue);}
62 inline TBool CDbTableDef::IsIndexed(const TDesC& aColumn) const
63 {return FindKey(aColumn,EFalse)!=NULL;}
65 // Class RDbTableSchema
66 inline void RDbTableSchema::Add(CDbTableDef* aDef)
67 {iRep.AddLast(*aDef);}
68 inline RDbTableSchema::operator TSglQueBase&()
70 inline void RDbTableSchema::Loaded()
72 inline TBool RDbTableSchema::IsEmpty() const
73 {return iRep.IsEmpty();}
75 // Class TDbGenerationMark
76 inline void TDbGenerationMark::Construct(const TDbGeneration& aGeneration)
77 {iGeneration=&aGeneration;iMark=aGeneration;}
78 inline void TDbGenerationMark::Mark()
80 inline TBool TDbGenerationMark::Changed() const
81 {return iMark!=*iGeneration;}
83 inline TBool CDbTable::IsActive() const
84 {return iDatabase!=0;}
85 inline const CDbTableDef& CDbTable::Def() const
86 {__ASSERT_DEBUG(iDef,User::Invariant());return *iDef;}
87 inline CDbTableDatabase& CDbTable::Database()
88 {__ASSERT_DEBUG(iDatabase,User::Invariant());return *iDatabase;}
89 inline const TDbGeneration& CDbTable::Generation() const
92 inline RDbTableRow::RDbTableRow()
95 inline CDbTable& RDbTableRow::Table() const
98 // Class CDbTableDatabase
99 inline RDbTransaction& CDbTableDatabase::Transaction()
100 {return iTransaction;}
101 inline RDbTableSchema& CDbTableDatabase::Schema()
103 // Class CDbTableDatabase::CBuildIndex
104 inline CDbRecordIndex& CDbTableDatabase::CBuildIndex::Index()