MHEG  17.9.0
 All Data Structures Files Functions Variables Typedefs Enumerations Macros Pages
mh5link.h
Go to the documentation of this file.
1 /*******************************************************************************
2  * Copyright © 2014 The DTVKit Open Software Foundation Ltd (www.dtvkit.org)
3  * Copyright © 2004 Ocean Blue Software Ltd
4  * Copyright © 2000 Koninklijke Philips Electronics N.V
5  *
6  * This file is part of a DTVKit Software Component
7  * You are permitted to copy, modify or distribute this file subject to the terms
8  * of the DTVKit 1.0 Licence which can be found in licence.txt or at www.dtvkit.org
9  *
10  * THIS CODE AND INFORMATION ARE PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND,
11  * EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE IMPLIED WARRANTIES
12  * OF MERCHANTABILITY AND/OR FITNESS FOR A PARTICULAR PURPOSE.
13  *
14  * If you or your organisation is not a member of DTVKit then you have access
15  * to this source code outside of the terms of the licence agreement
16  * and you are expected to delete this and any associated files immediately.
17  * Further information on DTVKit, membership and terms can be found at www.dtvkit.org
18  *******************************************************************************/
31 #ifndef _MH5LINK_H
32 #define _MH5LINK_H
33 
34 /*---includes for this file--------------------------------------------------*/
35 #include "mh5ingredient.h"
36 #include "mh5action.h"
37 
38 /*---Constant and macro definitions for public use---------------------------*/
39 
40 #define HTEXT_TOP_STR 1
41 #define HTEXT_BOT_STR 2
42 
43 /*---Enumerations for public use---------------------------------------------*/
44 
45 /*---Global type defs for public use-----------------------------------------*/
46 typedef struct sMHEG5Link
47 {
48  /* Base class */
49  MHEG5Ingredient ingredient;
50 
51  /* Exchanged attributes */
52  MH5GroupRef sourcegid; /* \ */
53  MHEG5Int source; /* | LinkCondition */
54  MHEG5EventType eventType; /* | */
55  MHEG5Generic eventData; /* / */
56  MHEG5ActionList linkEffect;
57 
58  /* No internal attributes for this class */
59 
60  /* Engine data */
61  struct sMHEG5Link *nextActiveLink; /* Pointer to the next currently */
62  /* active link */
63 } MHEG5Link;
64 
65 /*---Global variable declarations for public use-----------------------------*/
66 
67 /*---Global Function prototypes for public use-------------------------------*/
68 
80 void MHEG5linkInit(MHEG5Link *link);
81 
82 
90 void MHEG5linkFree(MHEG5Link *link);
91 
92 
93 /*
94  Internal behaviours
95  */
96 void MHEG5linkPrepare(MHEG5Link *link);
97 void MHEG5linkDestruct(MHEG5Link *link);
98 void MHEG5linkActivate(MHEG5Link *link);
99 void MHEG5linkDeactivate(MHEG5Link *link);
100 U8BIT* MHEG5linkEventName( MHEG5Link *link );
101 
102 /*
103  Actions
104  */
105 MHEG5ErrorCode MHEG5activate(MHEG5Root *target, MHEG5GList *params);
106 MHEG5ErrorCode MHEG5deactivate(MHEG5Root *target, MHEG5GList *params);
107 
108 /*
109  Internal Engine Functions
110  */
111 
112 int LNK_RegisterString( MHEG5String s );
113 int LNK_GetStringIndex( MHEG5String s );
114 MHEG5String LNK_GetString( int i );
115 
116 
117 void initialiseActiveLinkQs(void);
118 
119 #ifdef MH5PRINTOUT
120 void MHEG5linkPrint(MHEG5Link *link, char *out);
121 #endif
122 
123 extern MHEG5Link *activeLinksHead[MHEG5LASTEVENT + 1];
124 extern unsigned int existsLinkCount[MHEG5LASTEVENT + 1];
125 
126 #endif /*_MH5LINK_H*/
Definition: mh5action.h:199
Implementation of the Ingredient class.
Definition: mh5base.h:82
Definition: mh5ingredient.h:63
Definition: mh5base.h:97
Manage elementary actions Manage a table of all actions and call a specific action which is defined b...
Definition: mh5base.h:169
Definition: mh5base.h:147
Definition: mh5root.h:43