InDesign SDK  20.5
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
IMemoryStreamData.h
1 //========================================================================================
2 //
3 // $File$
4 //
5 // Owner: Michael Martz
6 //
7 // $Author$
8 //
9 // $DateTime$
10 //
11 // $Revision$
12 //
13 // $Change$
14 //
15 // Copyright 1997-2010 Adobe Systems Incorporated. All rights reserved.
16 //
17 // NOTICE: Adobe permits you to use, modify, and distribute this file in accordance
18 // with the terms of the Adobe license agreement accompanying it. If you have received
19 // this file from a source other than Adobe, then your use, modification, or
20 // distribution of it requires the prior written permission of Adobe.
21 //
22 //
23 // Purpose:
24 // Data interface for attaching an IXferBytes to a stream.
25 //
26 // Streams are usually accessed via the helper functions in StreamUtils:
27 // you probably will not need direct access to this interface.
28 //
29 // When using the memory stream objects, it is typical to use a MemXferBytes object
30 // as the underlying xferbytes. However, it is not necessary. Any xferBytes could be used
31 // as long as it is self contained (initializes within its constructor.
32 //
33 //========================================================================================
34 
35 #ifndef _IMemoryStreamData_
36 #define _IMemoryStreamData_
37 
38 #include "IPMUnknown.h"
39 #include "ShuksanID.h"
40 
41 class IXferBytes;
42 
48  {
49  public:
50  enum { kDefaultIID = IID_IMEMORYSTREAMDATA };
51 
52 
60  virtual void Set(IXferBytes* underlyingXferBytes, bool16 takeOwnership = kFalse) = 0;
61 
66  virtual IXferBytes* GetXferBytes() const = 0;
67 
72  virtual bool16 IsOwnedXferBytes() const = 0;
73  };
74 
75 
76 #endif // _IMemoryStreamData_