1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: featuredispatcher.hxx,v $
12 * This file is part of OpenOffice.org.
14 * OpenOffice.org is free software: you can redistribute it and/or modify
15 * it under the terms of the GNU Lesser General Public License version 3
16 * only, as published by the Free Software Foundation.
18 * OpenOffice.org is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU Lesser General Public License version 3 for more details
22 * (a copy is included in the LICENSE file that accompanied this code).
24 * You should have received a copy of the GNU Lesser General Public License
25 * version 3 along with OpenOffice.org. If not, see
26 * <http://www.openoffice.org/license.html>
27 * for a copy of the LGPLv3 License.
29 ************************************************************************/
31 #ifndef FORMS_SOLAR_DISPATCHER_HXX
32 #define FORMS_SOLAR_DISPATCHER_HXX
34 #include <rtl/ustring.hxx>
36 //.........................................................................
39 //.........................................................................
41 //=========================================================================
42 //= IFeatureDispatcher
43 //=========================================================================
44 class IFeatureDispatcher
47 /** dispatches a feature
50 the id of the feature to dispatch
52 virtual void dispatch( sal_Int32 _nFeatureId
) const = 0;
54 /** dispatches a feature, with an additional named parameter
57 the id of the feature to dispatch
59 @param _pParamAsciiName
60 the Ascii name of the parameter of the dispatch call
63 the value of the parameter of the dispatch call
65 virtual void dispatchWithArgument(
66 sal_Int32 _nFeatureId
,
67 const sal_Char
* _pParamName
,
68 const ::com::sun::star::uno::Any
& _rParamValue
71 /** checks whether a given feature is enabled
73 virtual bool isEnabled( sal_Int32 _nFeatureId
) const = 0;
75 /** returns the boolean state of a feature
77 Certain features may support more status information than only the enabled/disabled
78 state. The type of such additional information is fixed relative to a given feature, but
79 may differ between different features.
81 This method allows retrieving status information about features which have an additional
82 boolean information associated with it.
84 virtual bool getBooleanState( sal_Int32 _nFeatureId
) const = 0;
86 /** returns the string state of a feature
88 Certain features may support more status information than only the enabled/disabled
89 state. The type of such additional information is fixed relative to a given feature, but
90 may differ between different features.
92 This method allows retrieving status information about features which have an additional
93 string information associated with it.
95 virtual ::rtl::OUString
getStringState( sal_Int32 _nFeatureId
) const = 0;
97 /** returns the integer state of a feature
99 Certain features may support more status information than only the enabled/disabled
100 state. The type of such additional information is fixed relative to a given feature, but
101 may differ between different features.
103 This method allows retrieving status information about features which have an additional
104 integer information associated with it.
106 virtual sal_Int32
getIntegerState( sal_Int32 _nFeatureId
) const = 0;
109 //.........................................................................
111 //.........................................................................
113 #endif // FORMS_SOLAR_DISPATCHER_HXX