1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1.2 +++ b/os/persistentdata/persistentstorage/store/INC/S32CONT.INL Fri Jun 15 03:10:57 2012 +0200
1.3 @@ -0,0 +1,177 @@
1.4 +// Copyright (c) 1998-2009 Nokia Corporation and/or its subsidiary(-ies).
1.5 +// All rights reserved.
1.6 +// This component and the accompanying materials are made available
1.7 +// under the terms of "Eclipse Public License v1.0"
1.8 +// which accompanies this distribution, and is available
1.9 +// at the URL "http://www.eclipse.org/legal/epl-v10.html".
1.10 +//
1.11 +// Initial Contributors:
1.12 +// Nokia Corporation - initial contribution.
1.13 +//
1.14 +// Contributors:
1.15 +//
1.16 +// Description:
1.17 +//
1.18 +
1.19 +// Class TPagedSetToken
1.20 +inline TPagedSetToken::TPagedSetToken(TEmpty)
1.21 + {Clear();}
1.22 +inline TInt TPagedSetToken::Count() const
1.23 + {return iCount;}
1.24 +
1.25 +// Class TPagedSetBase
1.26 +inline TBool TPagedSetBase::IsDirty() const
1.27 + {return iTree.IsDirty();}
1.28 +inline void TPagedSetBase::MarkCurrent()
1.29 + {iTree.MarkCurrent();}
1.30 +inline void TPagedSetBase::MarkDirty()
1.31 + {iTree.MarkDirty();}
1.32 +inline TBool TPagedSetBase::IsBroken() const
1.33 + {return iTree.IsBroken();}
1.34 +inline TBool TPagedSetBase::IsIntact() const
1.35 + {return iTree.IsIntact();}
1.36 +inline void TPagedSetBase::MarkBroken()
1.37 + {iTree.MarkBroken();}
1.38 +inline TInt TPagedSetBase::Count() const
1.39 + {return iCount;}
1.40 +inline TBool TPagedSetBase::IsEmpty() const
1.41 + {return iTree.IsEmpty();}
1.42 +
1.43 +// Class TPagedMultisetBase
1.44 +inline void TPagedMultisetBase::InsertL(const TAny* aPtr)
1.45 + {TPagedSetBase::InsertAllowDuplicatesL(aPtr);}
1.46 +inline TPagedMultisetBase::TPagedMultisetBase(TInt anEntrySize)
1.47 + : TPagedSetBase(anEntrySize)
1.48 + {}
1.49 +inline TPagedMultisetBase::TPagedMultisetBase(const TPagedSetToken& aToken,TInt anEntrySize)
1.50 + : TPagedSetBase(aToken,anEntrySize)
1.51 + {}
1.52 +
1.53 +// Template class TPagedSet
1.54 +template <class T>
1.55 +inline TPagedSet<T>::TPagedSet()
1.56 + : TPagedSetBase(sizeof(T))
1.57 + {}
1.58 +template <class T>
1.59 +inline TPagedSet<T>::TPagedSet(const TPagedSetToken& aToken)
1.60 + : TPagedSetBase(aToken,sizeof(T))
1.61 + {}
1.62 +template <class T>
1.63 +inline TBool TPagedSet<T>::ContainsL(const T& anObject) const
1.64 + {return TPagedSetBase::ContainsL(&anObject);}
1.65 +template <class T>
1.66 +inline void TPagedSet<T>::InsertL(const T& anObject)
1.67 + {TPagedSetBase::InsertL(&anObject);}
1.68 +template <class T>
1.69 +inline void TPagedSet<T>::DeleteL(const T& anObject)
1.70 + {TPagedSetBase::DeleteL(&anObject);}
1.71 +inline TPagedSet<TAny>::TPagedSet(TInt anEntrySize)
1.72 + : TPagedSetBase(anEntrySize)
1.73 + {}
1.74 +inline TPagedSet<TAny>::TPagedSet(const TPagedSetToken& aToken,TInt anEntrySize)
1.75 + : TPagedSetBase(aToken,anEntrySize)
1.76 + {}
1.77 +
1.78 +// Template class TPagedMultiset
1.79 +template <class T>
1.80 +inline TPagedMultiset<T>::TPagedMultiset()
1.81 + : TPagedMultisetBase(sizeof(T))
1.82 + {}
1.83 +template <class T>
1.84 +inline TPagedMultiset<T>::TPagedMultiset(const TPagedSetToken& aToken)
1.85 + : TPagedMultisetBase(aToken,sizeof(T))
1.86 + {}
1.87 +template <class T>
1.88 +inline TBool TPagedMultiset<T>::ContainsL(const T& anObject) const
1.89 + {return TPagedMultisetBase::ContainsL(&anObject);}
1.90 +template <class T>
1.91 +inline void TPagedMultiset<T>::InsertL(const T& anObject)
1.92 + {TPagedMultisetBase::InsertL(&anObject);}
1.93 +template <class T>
1.94 +inline void TPagedMultiset<T>::DeleteL(const T& anObject)
1.95 + {TPagedMultisetBase::DeleteL(&anObject);}
1.96 +inline TPagedMultiset<TAny>::TPagedMultiset(TInt anEntrySize)
1.97 + : TPagedMultisetBase(anEntrySize)
1.98 + {}
1.99 +inline TPagedMultiset<TAny>::TPagedMultiset(const TPagedSetToken& aToken,TInt anEntrySize)
1.100 + : TPagedMultisetBase(aToken,anEntrySize)
1.101 + {}
1.102 +
1.103 +// Class TPagedSetIterBase
1.104 +inline TPagedSetIterBase::TPagedSetIterBase(const TPagedSetBase& aSet)
1.105 + : iTree(&aSet.iTree)
1.106 + {}
1.107 +
1.108 +// Class TPagedSetIter
1.109 +template <class T>
1.110 +inline TPagedSetIter<T>::TPagedSetIter(const TPagedSet<T>& aSet)
1.111 + : TPagedSetIterBase(aSet)
1.112 + {}
1.113 +template <class T>
1.114 +inline TPagedSetIter<T>::TPagedSetIter(const TPagedMultiset<T>& aSet)
1.115 + : TPagedSetIterBase(aSet)
1.116 + {}
1.117 +template <class T>
1.118 +inline T TPagedSetIter<T>::AtL() const
1.119 + {T t;TPagedSetIterBase::ExtractAtL(&t);return t;}
1.120 +template <class T>
1.121 +inline void TPagedSetIter<T>::ExtractAtL(T& anObject) const
1.122 + {TPagedSetIterBase::ExtractAtL(&anObject);}
1.123 +inline TPagedSetIter<TAny>::TPagedSetIter(const TPagedSetBase& aSet)
1.124 + : TPagedSetIterBase(aSet)
1.125 + {}
1.126 +
1.127 +// Class TPagedSetBiIterBase
1.128 +inline TPagedSetBiIterBase::TPagedSetBiIterBase(const TPagedSetBase& aSet)
1.129 + : iTree(&aSet.iTree)
1.130 + {}
1.131 +
1.132 +// Class TPagedSetBiIter
1.133 +template <class T>
1.134 +inline TPagedSetBiIter<T>::TPagedSetBiIter(const TPagedSet<T>& aSet)
1.135 + : TPagedSetBiIterBase(aSet)
1.136 + {}
1.137 +template <class T>
1.138 +inline TPagedSetBiIter<T>::TPagedSetBiIter(const TPagedMultiset<T>& aSet)
1.139 + : TPagedSetBiIterBase(aSet)
1.140 + {}
1.141 +template <class T>
1.142 +inline T TPagedSetBiIter<T>::AtL() const
1.143 + {T t;TPagedSetBiIterBase::ExtractAtL(&t);return t;}
1.144 +template <class T>
1.145 +inline void TPagedSetBiIter<T>::ExtractAtL(T& anObject) const
1.146 + {TPagedSetBiIterBase::ExtractAtL(&anObject);}
1.147 +inline TPagedSetBiIter<TAny>::TPagedSetBiIter(const TPagedSetBase& aSet)
1.148 + : TPagedSetBiIterBase(aSet)
1.149 + {}
1.150 +
1.151 +// Class TPagedSetRIterBase
1.152 +inline TBool TPagedSetRIterBase::ResetL()
1.153 + {return iIter.LastL();}
1.154 +inline TBool TPagedSetRIterBase::NextL()
1.155 + {return iIter.PreviousL();}
1.156 +inline void TPagedSetRIterBase::ExtractAtL(TAny* aPtr) const
1.157 + {iIter.ExtractAtL(aPtr);}
1.158 +inline TPagedSetRIterBase::TPagedSetRIterBase(const TPagedSetBase& aSet)
1.159 + : iIter(aSet)
1.160 + {}
1.161 +
1.162 +// Class TPagedSetRIter
1.163 +template <class T>
1.164 +inline TPagedSetRIter<T>::TPagedSetRIter(const TPagedSet<T>& aSet)
1.165 + : TPagedSetRIterBase(aSet)
1.166 + {}
1.167 +template <class T>
1.168 +inline TPagedSetRIter<T>::TPagedSetRIter(const TPagedMultiset<T>& aSet)
1.169 + : TPagedSetRIterBase(aSet)
1.170 + {}
1.171 +template <class T>
1.172 +inline T TPagedSetRIter<T>::AtL() const
1.173 + {T t;TPagedSetRIterBase::ExtractAtL(&t);return t;}
1.174 +template <class T>
1.175 +inline void TPagedSetRIter<T>::ExtractAtL(T& anObject) const
1.176 + {TPagedSetRIterBase::ExtractAtL(&anObject);}
1.177 +inline TPagedSetRIter<TAny>::TPagedSetRIter(const TPagedSetBase& aSet)
1.178 + : TPagedSetRIterBase(aSet)
1.179 + {}
1.180 +