xref: /aoo41x/main/framework/inc/arguments.h (revision 228b4580)
1 /**************************************************************
2  *
3  * Licensed to the Apache Software Foundation (ASF) under one
4  * or more contributor license agreements.  See the NOTICE file
5  * distributed with this work for additional information
6  * regarding copyright ownership.  The ASF licenses this file
7  * to you under the Apache License, Version 2.0 (the
8  * "License"); you may not use this file except in compliance
9  * with the License.  You may obtain a copy of the License at
10  *
11  *   http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing,
14  * software distributed under the License is distributed on an
15  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16  * KIND, either express or implied.  See the License for the
17  * specific language governing permissions and limitations
18  * under the License.
19  *
20  *************************************************************/
21 
22 
23 
24 #ifndef __FRAMEWORK_ARGUMENTS_H_
25 #define __FRAMEWORK_ARGUMENTS_H_
26 
27 //_________________________________________________________________________________________________________________
28 //	includes
29 //_________________________________________________________________________________________________________________
30 
31 #include <macros/generic.hxx>
32 
33 //_________________________________________________________________________________________________________________
34 //	namespace
35 //_________________________________________________________________________________________________________________
36 
37 namespace framework{
38 
39 /*-************************************************************************************************************//**
40 	@short			These arguments are included in given parameter lists - e.g. at dispatch calls at Sequence< PropertyValue >.
41 					You can use class ArgumentAnalyzer to set/get it from a given list!
42 *//*-*************************************************************************************************************/
43 
44 #define ARGUMENTNAME_ASTEMPLATE                             DECLARE_ASCII("AsTemplate"          )   // bool
45 #define ARGUMENTNAME_CHARACTERSET                           DECLARE_ASCII("CharacterSet"        )   // string
46 #define ARGUMENTNAME_DEEPDETECTION                          DECLARE_ASCII("DeepDetection"       )   // bool
47 #define ARGUMENTNAME_DETECTSERVICE                          DECLARE_ASCII("DetectService"       )   // string
48 #define ARGUMENTNAME_EXTENSION                              DECLARE_ASCII("Extension"           )   // string
49 #define ARGUMENTNAME_FILTERNAME                             DECLARE_ASCII("FilterName"          )   // string
50 #define ARGUMENTNAME_FILTEROPTIONS                          DECLARE_ASCII("FilterOptions"       )   // string
51 #define ARGUMENTNAME_FORMAT                                 DECLARE_ASCII("Format"              )   // string
52 #define ARGUMENTNAME_FRAMENAME                              DECLARE_ASCII("FrameName"           )   // string
53 #define ARGUMENTNAME_HIDDEN                                 DECLARE_ASCII("Hidden"              )   // bool
54 #define ARGUMENTNAME_INPUTSTREAM                            DECLARE_ASCII("InputStream"         )   // Reference< XInputStream >
55 #define ARGUMENTNAME_INTERACTIONHANDLER                     DECLARE_ASCII("InteractionHandler"  )   // Reference< XInteractionHandler >
56 #define ARGUMENTNAME_JUMPMARK                               DECLARE_ASCII("JumpMark"            )   // string
57 #define ARGUMENTNAME_MACROEXECUTIONMODE                     DECLARE_ASCII("MacroExecutionMode"  )   // int16
58 #define ARGUMENTNAME_MEDIATYPE                              DECLARE_ASCII("MediaType"           )   // string
59 #define ARGUMENTNAME_MINIMIZED                              DECLARE_ASCII("Minimized"           )   // bool
60 #define ARGUMENTNAME_OPENNEWVIEW                            DECLARE_ASCII("OpenNewView"         )   // bool
61 #define ARGUMENTNAME_OUTPUTSTREAM                           DECLARE_ASCII("OutputStream"        )   // Reference< XOutputStream >
62 #define ARGUMENTNAME_PATTERN                                DECLARE_ASCII("Pattern"             )   // string
63 #define ARGUMENTNAME_POSSIZE                                DECLARE_ASCII("PosSize"             )   // rectangle
64 #define ARGUMENTNAME_POSTDATA                               DECLARE_ASCII("PostData"            )   // Reference< XInputStream >
65 #define ARGUMENTNAME_POSTSTRING                             DECLARE_ASCII("PostString"          )   // string
66 #define ARGUMENTNAME_PREVIEW                                DECLARE_ASCII("Preview"             )   // bool
67 #define ARGUMENTNAME_READONLY                               DECLARE_ASCII("ReadOnly"            )   // bool
68 #define ARGUMENTNAME_REFERRER                               DECLARE_ASCII("Referer"             )   // string
69 #define ARGUMENTNAME_SILENT                                 DECLARE_ASCII("Silent"              )   // bool
70 #define ARGUMENTNAME_STATUSINDICATOR                        DECLARE_ASCII("StatusIndicator"     )   // Reference< XStatusIndicator >
71 #define ARGUMENTNAME_TEMPLATENAME                           DECLARE_ASCII("TemplateName"        )   // string
72 #define ARGUMENTNAME_TEMPLATEREGIONNAME                     DECLARE_ASCII("TemplateRegionName"  )   // string
73 #define ARGUMENTNAME_TYPENAME                               DECLARE_ASCII("TypeName"            )   // string
74 #define ARGUMENTNAME_UPDATEDOCMODE                          DECLARE_ASCII("UpdateDocMode"       )   // int16
75 #define ARGUMENTNAME_URL                                    DECLARE_ASCII("URL"                 )   // string
76 #define ARGUMENTNAME_VERSION                                DECLARE_ASCII("Version"             )   // int16
77 #define ARGUMENTNAME_VIEWID                                 DECLARE_ASCII("ViewId"              )   // int16
78 #define ARGUMENTNAME_REPAIRPACKAGE                          DECLARE_ASCII("RepairPackage"       )   // bool
79 #define ARGUMENTNAME_DOCUMENTTITLE                          DECLARE_ASCII("DocumentTitle"       )   // string
80 
81 /*-************************************************************************************************************//**
82     @short          define our argument mask
83     @descr          These mask could be used to define a subset for analyzing arguments or specify
84                     one argument for set/get operations.
85                     We use first byte [bit 0..7] of an int32 to define 8 layer, and follow 3 bytes [bit 8..31]
86                     to address 24 properties per layer! Please use defines to build these mask!!!
87                     With these values we build an special enum field for better using at our Argumentanalyzer-interface ...
88                     Special define ANALYZE_ALL is our default for analyzing. Then we analyze complete argument list.
89 *//*-*************************************************************************************************************/
90 #define ARGUMENTLAYER_1                                     0x00000001
91 #define ARGUMENTLAYER_2                                     0x00000002
92 #define ARGUMENTLAYER_3                                     0x00000004
93 #define ARGUMENTLAYER_4                                     0x00000008
94 #define ARGUMENTLAYER_5                                     0x00000010
95 #define ARGUMENTLAYER_6                                     0x00000020
96 #define ARGUMENTLAYER_7                                     0x00000040
97 #define ARGUMENTLAYER_8                                     0x00000080
98 
99 #define ARGUMENTFLAG_1                                      0x00000100
100 #define ARGUMENTFLAG_2                                      0x00000200
101 #define ARGUMENTFLAG_3                                      0x00000400
102 #define ARGUMENTFLAG_4                                      0x00000800
103 #define ARGUMENTFLAG_5                                      0x00001000
104 #define ARGUMENTFLAG_6                                      0x00002000
105 #define ARGUMENTFLAG_7                                      0x00004000
106 #define ARGUMENTFLAG_8                                      0x00008000
107 #define ARGUMENTFLAG_9                                      0x00010000
108 #define ARGUMENTFLAG_10                                     0x00020000
109 #define ARGUMENTFLAG_11                                     0x00040000
110 #define ARGUMENTFLAG_12                                     0x00080000
111 #define ARGUMENTFLAG_13                                     0x00100000
112 #define ARGUMENTFLAG_14                                     0x00200000
113 #define ARGUMENTFLAG_15                                     0x00400000
114 #define ARGUMENTFLAG_16                                     0x00800000
115 #define ARGUMENTFLAG_17                                     0x01000000
116 #define ARGUMENTFLAG_18                                     0x02000000
117 #define ARGUMENTFLAG_19                                     0x04000000
118 #define ARGUMENTFLAG_20                                     0x08000000
119 #define ARGUMENTFLAG_21                                     0x10000000
120 #define ARGUMENTFLAG_22                                     0x20000000
121 #define ARGUMENTFLAG_23                                     0x40000000
122 #define ARGUMENTFLAG_24                                     0x80000000
123 
124 #define ANALYZE_ALL_ARGUMENTS                               0xFFFFFFFF
125 
126 enum EArgument
127 {
128     E_ASTEMPLATE            = ARGUMENTLAYER_1 | ARGUMENTFLAG_1 ,
129     E_CHARACTERSET          = ARGUMENTLAYER_1 | ARGUMENTFLAG_2 ,
130     E_DEEPDETECTION         = ARGUMENTLAYER_1 | ARGUMENTFLAG_3 ,
131     E_DETECTSERVICE         = ARGUMENTLAYER_1 | ARGUMENTFLAG_4 ,
132     E_EXTENSION             = ARGUMENTLAYER_1 | ARGUMENTFLAG_5 ,
133     E_FILTERNAME            = ARGUMENTLAYER_1 | ARGUMENTFLAG_6 ,
134     E_FILTEROPTIONS         = ARGUMENTLAYER_1 | ARGUMENTFLAG_7 ,
135     E_FORMAT                = ARGUMENTLAYER_1 | ARGUMENTFLAG_8 ,
136     E_FRAMENAME             = ARGUMENTLAYER_1 | ARGUMENTFLAG_9 ,
137     E_HIDDEN                = ARGUMENTLAYER_1 | ARGUMENTFLAG_10,
138     E_INPUTSTREAM           = ARGUMENTLAYER_1 | ARGUMENTFLAG_11,
139     E_INTERACTIONHANDLER    = ARGUMENTLAYER_1 | ARGUMENTFLAG_12,
140     E_JUMPMARK              = ARGUMENTLAYER_1 | ARGUMENTFLAG_13,
141     E_MACROEXECUTIONMODE    = ARGUMENTLAYER_1 | ARGUMENTFLAG_14,
142     E_MEDIATYPE             = ARGUMENTLAYER_1 | ARGUMENTFLAG_15,
143     E_MINIMIZED             = ARGUMENTLAYER_1 | ARGUMENTFLAG_16,
144     E_OPENNEWVIEW           = ARGUMENTLAYER_1 | ARGUMENTFLAG_17,
145     E_OUTPUTSTREAM          = ARGUMENTLAYER_1 | ARGUMENTFLAG_18,
146     E_PATTERN               = ARGUMENTLAYER_1 | ARGUMENTFLAG_19,
147     E_POSSIZE               = ARGUMENTLAYER_1 | ARGUMENTFLAG_20,
148     E_POSTDATA              = ARGUMENTLAYER_1 | ARGUMENTFLAG_21,
149     E_POSTSTRING            = ARGUMENTLAYER_1 | ARGUMENTFLAG_22,
150     E_PREVIEW               = ARGUMENTLAYER_1 | ARGUMENTFLAG_23,
151     E_READONLY              = ARGUMENTLAYER_1 | ARGUMENTFLAG_24,
152 
153     E_REFERRER              = ARGUMENTLAYER_2 | ARGUMENTFLAG_1 ,
154     E_SILENT                = ARGUMENTLAYER_2 | ARGUMENTFLAG_2 ,
155     E_STATUSINDICATOR       = ARGUMENTLAYER_2 | ARGUMENTFLAG_3 ,
156     E_TEMPLATENAME          = ARGUMENTLAYER_2 | ARGUMENTFLAG_4 ,
157     E_TEMPLATEREGIONNAME    = ARGUMENTLAYER_2 | ARGUMENTFLAG_5 ,
158     E_TYPENAME              = ARGUMENTLAYER_2 | ARGUMENTFLAG_6 ,
159     E_UPDATEDOCMODE         = ARGUMENTLAYER_2 | ARGUMENTFLAG_7 ,
160     E_URL                   = ARGUMENTLAYER_2 | ARGUMENTFLAG_8 ,
161     E_VERSION               = ARGUMENTLAYER_2 | ARGUMENTFLAG_9 ,
162     E_VIEWID                = ARGUMENTLAYER_2 | ARGUMENTFLAG_10,
163     E_REPAIRPACKAGE         = ARGUMENTLAYER_2 | ARGUMENTFLAG_11,
164     E_DOCUMENTTITLE         = ARGUMENTLAYER_2 | ARGUMENTFLAG_12
165 };
166 
167 } // namespace framework
168 
169 #endif // #ifndef __FRAMEWORK_ARGUMENTS_H_
170