DSMCC  15.3.1
source/dscore/src/siQuery.h
Go to the documentation of this file.
00001 /*******************************************************************************
00002  * Copyright © 2014 The DTVKit Open Software Foundation Ltd (www.dtvkit.org)
00003  * Copyright © 2004 Ocean Blue Software Ltd
00004  * Copyright © 2002 Koninklijke Philips Electronics N.V
00005  *
00006  * This file is part of a DTVKit Software Component
00007  * You are permitted to copy, modify or distribute this file subject to the terms
00008  * of the DTVKit 1.0 Licence which can be found in licence.txt or at www.dtvkit.org
00009  * 
00010  * THIS CODE AND INFORMATION ARE PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND,
00011  * EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE IMPLIED WARRANTIES
00012  * OF MERCHANTABILITY AND/OR FITNESS FOR A PARTICULAR PURPOSE.
00013  * 
00014  * If you or your organisation is not a member of DTVKit then you have access
00015  * to this source code outside of the terms of the licence agreement
00016  * and you are expected to delete this and any associated files immediately.
00017  * Further information on DTVKit, membership and terms can be found at www.dtvkit.org
00018  *******************************************************************************/
00025 #ifndef _SIQUERY_H_
00026 #define _SIQUERY_H_
00027 
00028 
00029 /*---includes for this file--------------------------------------------------*/
00030 
00031 
00032 #include "clDsmSystem.h"
00033 #include "linkList.h"
00034 
00035 #ifdef __cplusplus
00036 extern "C" {
00037 #endif
00038 
00039 
00040 /*---Constant and macro definitions for public use---------------------------*/
00041 
00042 #define SI_QUERY_MAGIC    0xC537D89E
00043 
00044 
00045 /*******************
00046 * EXPORTED TYPES   *
00047 ********************/
00048 
00049 typedef enum {
00050     SIQS_INITIAL = 0,
00051     SIQS_PENDING,   /* -- Waiting for results to be supplied asynchronously */
00052     SIQS_COMPLETED, /* -- Results supplied */
00053     SIQS_ABORTED,   /* -- Aborted before results supplied */
00054     SIQS_EXPIRED    /* -- Aborted before results supplied but has duplicates */
00055 } SiQueryState_t;
00056 
00057 typedef struct  {
00058     S_LLObject          llData[NUM_LISTS_SI_QUERY];
00059 
00060     U32BIT              magic;
00061     SiQueryState_t      state;
00062 
00063     clDsmSIQuery_t      query;
00064     void*               target;
00065 
00066     void*               queryHandle;    /* -- External handle */
00067 
00068     P_LLControl         llcDuplSiQuerys;   /* -- Only used if original == True */
00069     BOOLEAN             original;           /* -- original or duplicate (False) */
00070 
00071 } SiQuery_t, *pSiQuery_t;
00072 
00073 
00074 /*---Global variable declarations for public use-----------------------------*/
00075 
00076 /*---Global Function prototypes for public use---------------------------------*/
00077 
00078 clDsmErr_t siQueryStart( pclDsmInstData_t idp,
00079     /*I*/ pclDsmSIQuery_t pQueryData, void* queryTarget,
00080     /*O*/ clDsmSIQueryResult_t *pResult );
00081 
00082 void siQueryAbortPending( pclDsmInstData_t idp,
00083     /*IO*/ MemHandle *phPendingSiQueryRef );
00084 
00085 void siQueryStop( pclDsmInstData_t idp,
00086     /*IO*/ MemHandle *phSiQueryRef );
00087 
00088 clDsmErr_t siQueryProcessResult( pclDsmInstData_t idp,
00089     /*I*/ MemHandle hSiQueryRef, pclDsmSIQueryResult_t pResult );
00090 
00091 #ifdef GET_PID_LIST
00092 clDsmErr_t siQueryGetPIDList( pclDsmInstData_t idp );
00093 #endif /*GET_PID_LIST*/
00094 
00095 /*----------------------------------------------------------------------------*/
00096 #ifdef __cplusplus
00097 }
00098 #endif
00099 #endif /* _SIQUERY_H_ */
 All Data Structures Files Functions Typedefs