hxsrc.h
上传用户:zhongxx05
上传日期:2007-06-06
资源大小:33641k
文件大小:8k
源码类别:

Symbian

开发平台:

C/C++

  1. /* ***** BEGIN LICENSE BLOCK ***** 
  2.  * Version: RCSL 1.0/RPSL 1.0 
  3.  *  
  4.  * Portions Copyright (c) 1995-2002 RealNetworks, Inc. All Rights Reserved. 
  5.  *      
  6.  * The contents of this file, and the files included with this file, are 
  7.  * subject to the current version of the RealNetworks Public Source License 
  8.  * Version 1.0 (the "RPSL") available at 
  9.  * http://www.helixcommunity.org/content/rpsl unless you have licensed 
  10.  * the file under the RealNetworks Community Source License Version 1.0 
  11.  * (the "RCSL") available at http://www.helixcommunity.org/content/rcsl, 
  12.  * in which case the RCSL will apply. You may also obtain the license terms 
  13.  * directly from RealNetworks.  You may not use this file except in 
  14.  * compliance with the RPSL or, if you have a valid RCSL with RealNetworks 
  15.  * applicable to this file, the RCSL.  Please see the applicable RPSL or 
  16.  * RCSL for the rights, obligations and limitations governing use of the 
  17.  * contents of the file.  
  18.  *  
  19.  * This file is part of the Helix DNA Technology. RealNetworks is the 
  20.  * developer of the Original Code and owns the copyrights in the portions 
  21.  * it created. 
  22.  *  
  23.  * This file, and the files included with this file, is distributed and made 
  24.  * available on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 
  25.  * EXPRESS OR IMPLIED, AND REALNETWORKS HEREBY DISCLAIMS ALL SUCH WARRANTIES, 
  26.  * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, FITNESS 
  27.  * FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 
  28.  * 
  29.  * Technology Compatibility Kit Test Suite(s) Location: 
  30.  *    http://www.helixcommunity.org/content/tck 
  31.  * 
  32.  * Contributor(s): 
  33.  *  
  34.  * ***** END LICENSE BLOCK ***** */ 
  35. #ifndef _HXSRC_H_
  36. #define _HXSRC_H_
  37. /*
  38.  * Forward declarations of some interfaces defined or used here-in.
  39.  */
  40. typedef _INTERFACE IHXRawSourceObject IHXRawSourceObject;
  41. typedef _INTERFACE IHXRawSinkObject IHXRawSinkObject;
  42. typedef _INTERFACE IHXSourceFinderObject IHXSourceFinderObject;
  43. typedef _INTERFACE IHXSourceFinderResponse IHXSourceFinderResponse;
  44. typedef _INTERFACE IHXRequest IHXRequest;
  45. /****************************************************************************
  46.  * 
  47.  *  Interface:
  48.  * 
  49.  * IHXRawSourceObject
  50.  * 
  51.  *  Purpose:
  52.  * 
  53.  * Object that serves packets to sinks
  54.  * 
  55.  *  IID_IHXRawSourceObject:
  56.  * 
  57.  * {00001000-0901-11d1-8B06-00A024406D59}
  58.  * 
  59.  */
  60. DEFINE_GUID(IID_IHXRawSourceObject, 0x00001000, 0x901, 0x11d1, 0x8b, 0x6, 0x0, 
  61. 0xa0, 0x24, 0x40, 0x6d, 0x59);
  62. #undef  INTERFACE
  63. #define INTERFACE   IHXRawSourceObject
  64. DECLARE_INTERFACE_(IHXRawSourceObject, IUnknown)
  65. {
  66. /*
  67.  * IUnknown methods
  68.  */
  69.     STDMETHOD(QueryInterface) (THIS_
  70. REFIID riid,
  71. void** ppvObj) PURE;
  72.     STDMETHOD_(ULONG32,AddRef) (THIS) PURE;
  73.     STDMETHOD_(ULONG32,Release) (THIS) PURE;
  74. /*
  75.  * IHXRawSourceObject methods
  76.  */
  77.     /************************************************************************
  78.      * Method:
  79.      *     IHXRawSourceObject::Init
  80.      * Purpose:
  81.      *     Initializes the connection between the source and the sink
  82.      */
  83.     STDMETHOD(Init) (THIS_
  84. IUnknown* pUnknown) PURE;
  85.     STDMETHOD(Done) (THIS) PURE;
  86.     STDMETHOD(GetFileHeader) (THIS) PURE;
  87.     STDMETHOD(GetStreamHeader) (THIS_
  88. UINT16 unStreamNumber) PURE;
  89.     STDMETHOD(StartPackets) (THIS_
  90. UINT16 unStreamNumber) PURE;
  91.     STDMETHOD(StopPackets) (THIS_
  92. UINT16 unStreamNumber) PURE;
  93. };
  94. /****************************************************************************
  95.  * 
  96.  *  Interface:
  97.  * 
  98.  * IHXRawSinkObject
  99.  * 
  100.  *  Purpose:
  101.  * 
  102.  * Object that receives raw packets from a source
  103.  * 
  104.  *  IID_IHXRawSinkObject:
  105.  * 
  106.  * {00001001-0901-11d1-8B06-00A024406D59}
  107.  * 
  108.  */
  109. DEFINE_GUID(IID_IHXRawSinkObject, 0x00001001, 0x901, 0x11d1, 0x8b, 0x6, 0x0, 
  110. 0xa0, 0x24, 0x40, 0x6d, 0x59);
  111. #undef  INTERFACE
  112. #define INTERFACE   IHXRawSinkObject
  113. DECLARE_INTERFACE_(IHXRawSinkObject, IUnknown)
  114. {
  115. /*
  116.  * IUnknown methods
  117.  */
  118.     STDMETHOD(QueryInterface) (THIS_
  119. REFIID riid,
  120. void** ppvObj) PURE;
  121.     STDMETHOD_(ULONG32,AddRef) (THIS) PURE;
  122.     STDMETHOD_(ULONG32,Release) (THIS) PURE;
  123. /*
  124.  * IHXRawSinkObject methods
  125.  */
  126.     /************************************************************************
  127.      * Method:
  128.      *     IHXRawSinkObject::InitDone
  129.      * Purpose:
  130.      *     Callback after source object has initialized the connection
  131.      */
  132.     STDMETHOD(InitDone) (THIS_
  133. HX_RESULT status) PURE;
  134.     STDMETHOD(FileHeaderReady) (THIS_
  135. HX_RESULT status,
  136. IHXValues* pHeader) PURE;
  137.     STDMETHOD(StreamHeaderReady) (THIS_
  138. HX_RESULT status,
  139. IHXValues* pHeader) PURE;
  140.     STDMETHOD(PacketReady) (THIS_
  141. HX_RESULT status,
  142. IHXPacket* pPacket) PURE;
  143.     STDMETHOD(StreamDone) (THIS_
  144. UINT16 unStreamNumber) PURE;
  145. };
  146. /****************************************************************************
  147.  * 
  148.  *  Interface:
  149.  * 
  150.  * IHXSourceFinderObject
  151.  * 
  152.  *  Purpose:
  153.  * 
  154.  * Object that allows a sink to search for a raw packet source
  155.  * 
  156.  *  IID_IHXSourceFinderObject:
  157.  * 
  158.  * {00001002-0901-11d1-8B06-00A024406D59}
  159.  * 
  160.  */
  161. DEFINE_GUID(IID_IHXSourceFinderObject, 0x00001002, 0x901, 0x11d1, 0x8b, 0x6, 0x0, 
  162. 0xa0, 0x24, 0x40, 0x6d, 0x59);
  163. #define CLSID_IHXSourceFinderObject IID_IHXSourceFinderObject
  164. #undef  INTERFACE
  165. #define INTERFACE   IHXSourceFinderObject
  166. #define CLSID_IHXSourceFinderObject IID_IHXSourceFinderObject
  167. DECLARE_INTERFACE_(IHXSourceFinderObject, IUnknown)
  168. {
  169. /*
  170.  * IUnknown methods
  171.  */
  172.     STDMETHOD(QueryInterface) (THIS_
  173. REFIID riid,
  174. void** ppvObj) PURE;
  175.     STDMETHOD_(ULONG32,AddRef) (THIS) PURE;
  176.     STDMETHOD_(ULONG32,Release) (THIS) PURE;
  177. /*
  178.  * IHXSourceFinderObject methods
  179.  */
  180.     STDMETHOD(Init) (THIS_ 
  181. IUnknown* pUnknown) PURE;
  182.     STDMETHOD(Find) (THIS_
  183. IHXRequest* pRequest) PURE;
  184.     STDMETHOD(Done) (THIS) PURE;
  185. };
  186. /****************************************************************************
  187.  * 
  188.  *  Interface:
  189.  * 
  190.  * IHXSourceFinderResponse
  191.  * 
  192.  *  Purpose:
  193.  * 
  194.  * Object that returns a raw packet source to a sink
  195.  * 
  196.  *  IID_IHXSourceFinderResponse:
  197.  * 
  198.  * {00001003-0901-11d1-8B06-00A024406D59}
  199.  * 
  200.  */
  201. DEFINE_GUID(IID_IHXSourceFinderResponse, 0x00001003, 0x901, 0x11d1,
  202.             0x8b, 0x6, 0x0, 0xa0, 0x24, 0x40, 0x6d, 0x59);
  203. #undef  INTERFACE
  204. #define INTERFACE   IHXSourceFinderResponse
  205. DECLARE_INTERFACE_(IHXSourceFinderResponse, IUnknown)
  206. {
  207. /*
  208.  * IUnknown methods
  209.  */
  210.     STDMETHOD(QueryInterface) (THIS_
  211. REFIID riid,
  212. void** ppvObj) PURE;
  213.     STDMETHOD_(ULONG32,AddRef) (THIS) PURE;
  214.     STDMETHOD_(ULONG32,Release) (THIS) PURE;
  215. /*
  216.  * IHXSourceFinderResponse methods
  217.  */
  218.     STDMETHOD(InitDone) (THIS_
  219. HX_RESULT status) PURE;
  220.     STDMETHOD(FindDone) (THIS_
  221. HX_RESULT status,
  222. IUnknown* pUnknown) PURE;
  223. };
  224. /****************************************************************************
  225.  * 
  226.  *  Interface:
  227.  * 
  228.  * IHXSourceFinderFileResponse
  229.  *      A source finder response interface for static content.  Returns the
  230.  *      underlying file object associated with the raw source container. 
  231.  *
  232.  *  IID_IHXSourceFinderFileResponse:
  233.  * 
  234.  * {00001004-0901-11d1-8B06-00A024406D59}
  235.  * 
  236.  */
  237. DEFINE_GUID(IID_IHXSourceFinderFileResponse, 0x00001004, 0x901, 0x11d1,
  238.             0x8b, 0x6, 0x0, 0xa0, 0x24, 0x40, 0x6d, 0x59);
  239. #undef  INTERFACE
  240. #define INTERFACE   IHXSourceFinderFileResponse
  241. DECLARE_INTERFACE_(IHXSourceFinderFileResponse, IUnknown)
  242. {
  243. /*
  244.  * IUnknown methods
  245.  */
  246.     STDMETHOD(QueryInterface) (THIS_
  247. REFIID riid,
  248. void** ppvObj) PURE;
  249.     STDMETHOD_(ULONG32,AddRef) (THIS) PURE;
  250.     STDMETHOD_(ULONG32,Release) (THIS) PURE;
  251. /*
  252.  * IHXSourceFinderFileResponse methods
  253.  */
  254.     STDMETHOD(FindDone) (THIS_
  255. HX_RESULT status,
  256. IUnknown* pSourceContainer,
  257.                     IUnknown*   pFileObject) PURE;
  258. };
  259. #endif /* _HXSRC_H_ */