os/persistentdata/persistentstorage/dbms/pcdbms/utable/UT_DASRC.CPP
author sl@SLION-WIN7.fritz.box
Fri, 15 Jun 2012 03:10:57 +0200
changeset 0 bde4ae8d615e
permissions -rw-r--r--
First public contribution.
sl@0
     1
// Copyright (c) 1998-2009 Nokia Corporation and/or its subsidiary(-ies).
sl@0
     2
// All rights reserved.
sl@0
     3
// This component and the accompanying materials are made available
sl@0
     4
// under the terms of "Eclipse Public License v1.0"
sl@0
     5
// which accompanies this distribution, and is available
sl@0
     6
// at the URL "http://www.eclipse.org/legal/epl-v10.html".
sl@0
     7
//
sl@0
     8
// Initial Contributors:
sl@0
     9
// Nokia Corporation - initial contribution.
sl@0
    10
//
sl@0
    11
// Contributors:
sl@0
    12
//
sl@0
    13
// Description:
sl@0
    14
//
sl@0
    15
sl@0
    16
#include "UT_STD.H"
sl@0
    17
sl@0
    18
// Class CDbDataSource
sl@0
    19
sl@0
    20
CDbDataSource::TGoto CDbDataSource::GotoL(TDbPosition aPosition,TDbRecordId& aRecordId)
sl@0
    21
	{
sl@0
    22
	for (;;)
sl@0
    23
		{
sl@0
    24
		TInt work=KMaxTInt;
sl@0
    25
		TGoto r=GotoL(work,aPosition,aRecordId);
sl@0
    26
		if (r!=EExhausted)
sl@0
    27
			return r;
sl@0
    28
		}
sl@0
    29
	}
sl@0
    30
sl@0
    31
// Class CDbDataStage
sl@0
    32
sl@0
    33
CDbDataStage::~CDbDataStage()
sl@0
    34
	{
sl@0
    35
	delete iSource;
sl@0
    36
	}
sl@0
    37
sl@0
    38
RDbRow* CDbDataStage::RowBuffer()
sl@0
    39
	{
sl@0
    40
	return Source().RowBuffer();
sl@0
    41
	}
sl@0
    42
sl@0
    43
TDbColumn CDbDataStage::Column(TDbColNo aColNo)
sl@0
    44
	{
sl@0
    45
	return Source().Column(aColNo);
sl@0
    46
	}
sl@0
    47
sl@0
    48
void CDbDataStage::Reset()
sl@0
    49
	{
sl@0
    50
	Source().Reset();
sl@0
    51
	}
sl@0
    52
sl@0
    53
TBool CDbDataStage::EvaluateL(TInt& aWork,TDbRecordId& aRecordId,TBool& aAtRow)
sl@0
    54
	{
sl@0
    55
	return Source().EvaluateL(aWork,aRecordId,aAtRow);
sl@0
    56
	}
sl@0
    57
sl@0
    58
TBool CDbDataStage::Unevaluated()
sl@0
    59
	{
sl@0
    60
	return Source().Unevaluated();
sl@0
    61
	}
sl@0
    62
sl@0
    63
TInt CDbDataStage::CountL()
sl@0
    64
	{
sl@0
    65
	return Source().CountL();
sl@0
    66
	}
sl@0
    67
sl@0
    68
CDbDataStage::TGoto CDbDataStage::GotoL(TInt& aWork,TDbPosition aPosition,TDbRecordId& aRecordId)
sl@0
    69
	{
sl@0
    70
	return Source().GotoL(aWork,aPosition,aRecordId);
sl@0
    71
	}
sl@0
    72
sl@0
    73
TBool CDbDataStage::GotoL(TDbRecordId aRecordId)
sl@0
    74
	{
sl@0
    75
	return Source().GotoL(aRecordId);
sl@0
    76
	}
sl@0
    77
sl@0
    78
void CDbDataStage::ReadRowL(TDbRecordId aRecordId)
sl@0
    79
	{
sl@0
    80
	Source().ReadRowL(aRecordId);
sl@0
    81
	}
sl@0
    82
sl@0
    83
void CDbDataStage::NewRowL(TDbRecordId aCopyRecord)
sl@0
    84
	{
sl@0
    85
	Source().NewRowL(aCopyRecord);
sl@0
    86
	}
sl@0
    87
sl@0
    88
void CDbDataStage::PrepareToWriteRowL(TWrite aWrite)
sl@0
    89
	{
sl@0
    90
	Source().PrepareToWriteRowL(aWrite);
sl@0
    91
	}
sl@0
    92
sl@0
    93
TDbRecordId CDbDataStage::WriteRowL(TWrite aWrite,TSynch aSynch)
sl@0
    94
	{
sl@0
    95
	return Source().WriteRowL(aWrite,aSynch);
sl@0
    96
	}
sl@0
    97
sl@0
    98
CDbDataStage::TDelete CDbDataStage::DeleteRowL(TDbRecordId& aRecordId,TSynch aSynch)
sl@0
    99
	{
sl@0
   100
	return Source().DeleteRowL(aRecordId,aSynch);
sl@0
   101
	}
sl@0
   102
sl@0
   103
TInt CDbDataStage::ColumnCount() const
sl@0
   104
	{
sl@0
   105
	return Source().ColumnCount();
sl@0
   106
	}
sl@0
   107
sl@0
   108
const TDbColumnDef& CDbDataStage::ColumnDef(TDbColNo aCol) const
sl@0
   109
	{
sl@0
   110
	return Source().ColumnDef(aCol);
sl@0
   111
	}
sl@0
   112
sl@0
   113
void CDbDataStage::SetIndexL(const TDesC*)
sl@0
   114
//
sl@0
   115
// Only invoked from a RDbTable.
sl@0
   116
// No data stages are present for such a view
sl@0
   117
//
sl@0
   118
	{
sl@0
   119
	__ASSERT(0);
sl@0
   120
	}
sl@0
   121
sl@0
   122
TBool CDbDataStage::SeekL(const TDbLookupKey&,RDbTable::TComparison,TDbRecordId&)
sl@0
   123
//
sl@0
   124
// Only invoked from a RDbTable.
sl@0
   125
// No data stages are present for such a view
sl@0
   126
//
sl@0
   127
	{
sl@0
   128
	__ASSERT(0);
sl@0
   129
	return EFalse;
sl@0
   130
	}
sl@0
   131
sl@0
   132
CSqlSearchCondition* CDbDataStage::ParseConstraintLC(const TDesC& aCondition)
sl@0
   133
	{
sl@0
   134
	return Source().ParseConstraintLC(aCondition);
sl@0
   135
	}
sl@0
   136