summaryrefslogtreecommitdiffstats
path: root/kexi/core/kexiuseractionmethod.h
blob: 5bfae22ceedcba473d0bde3b86773b1f4a10d7b3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
#ifndef KEXIUSERACTIONMETHOD_H
#define KEXIUSERACTIONMETHOD_H

#include <qvaluevector.h>
#include <qstring.h>
#include <qvariant.h>

typedef QValueVector<int> ArgTypes;
typedef QValueVector<QString> ArgNames;

/*! describes a UserActionCommand */
class KEXICORE_EXPORT KexiUserActionMethod
{
	public:
		/*! constructs a UserActionCommand describtion */
		KexiUserActionMethod(int method, ArgTypes types, ArgNames names);

		/*! \return method id of this method */
		int method() { return m_method; }

		/*! \return argument type information of this method */
		ArgTypes types() { return m_types; }

		/*! \return i18n argument names of this method */
		ArgNames names() { return m_names; }



		/*! \return i18n method name for \a method */
		static QString methodName(int method);

		/*! \return an i18n string for \a type */
		static QString typeName(int type);

	private:
		int m_method;
		ArgTypes m_types;
		ArgNames m_names;
};

#endif