|
0
|
1 |
/*
|
|
|
2 |
* Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
|
|
|
3 |
* All rights reserved.
|
|
|
4 |
* This component and the accompanying materials are made available
|
|
|
5 |
* under the terms of "Eclipse Public License v1.0"
|
|
|
6 |
* which accompanies this distribution, and is available
|
|
|
7 |
* at the URL "http://www.eclipse.org/legal/epl-v10.html".
|
|
|
8 |
*
|
|
|
9 |
* Initial Contributors:
|
|
|
10 |
* Nokia Corporation - initial contribution.
|
|
|
11 |
*
|
|
|
12 |
* Contributors:
|
|
|
13 |
*
|
|
|
14 |
* Description:
|
|
|
15 |
*
|
|
|
16 |
*/
|
|
|
17 |
|
|
|
18 |
|
|
|
19 |
|
|
|
20 |
|
|
|
21 |
/**
|
|
|
22 |
@file
|
|
|
23 |
@publishedPartner
|
|
|
24 |
@released
|
|
|
25 |
*/
|
|
|
26 |
|
|
|
27 |
#ifndef MAUDIODATACONSUMER_H
|
|
|
28 |
#define MAUDIODATACONSUMER_H
|
|
|
29 |
|
|
|
30 |
#include <a3f/a3fbase.h>
|
|
|
31 |
|
|
|
32 |
class MMMFBufferSink;
|
|
|
33 |
class CMMFBuffer;
|
|
|
34 |
|
|
|
35 |
/**
|
|
|
36 |
* An interface to a set of callback functions that a buffer sink client must implement.
|
|
|
37 |
*/
|
|
|
38 |
class MMMFAudioDataConsumer
|
|
|
39 |
{
|
|
|
40 |
public:
|
|
|
41 |
/**
|
|
|
42 |
* Provides a buffer with audio data to the client.
|
|
|
43 |
*
|
|
|
44 |
* After reading the data from the buffer, the client must call MBufferSink::BufferEmptied() passing the buffer as a parameter.
|
|
|
45 |
* @param aSink a pointer to the sink providing the buffer.
|
|
|
46 |
* @param aBuffer a pointer to the buffer to empty.
|
|
|
47 |
*/
|
|
|
48 |
virtual void BufferToBeEmptied(MMMFBufferSink* aSink, CMMFBuffer* aBuffer)=0;
|
|
|
49 |
|
|
|
50 |
|
|
|
51 |
/**
|
|
|
52 |
* Indicates that any outstanding buffer requests are to be cancelled, so that control of those buffers returns to the framework.
|
|
|
53 |
* The client must call MMMFBufferSink::BuffersDiscarded() to acknowledge that this has taken place.
|
|
|
54 |
* @param aSource the source whose previous buffer requests should be ignored.
|
|
|
55 |
*/
|
|
|
56 |
virtual void DiscardBuffers(MMMFBufferSink* aSink)=0;
|
|
|
57 |
};
|
|
|
58 |
|
|
|
59 |
#endif // MAUDIODATACONSUMER_H
|