summaryrefslogtreecommitdiff
path: root/decorators/libdecorator/mrmiserver_p.h
diff options
context:
space:
mode:
Diffstat (limited to 'decorators/libdecorator/mrmiserver_p.h')
-rw-r--r--decorators/libdecorator/mrmiserver_p.h69
1 files changed, 69 insertions, 0 deletions
diff --git a/decorators/libdecorator/mrmiserver_p.h b/decorators/libdecorator/mrmiserver_p.h
new file mode 100644
index 0000000..8725f19
--- /dev/null
+++ b/decorators/libdecorator/mrmiserver_p.h
@@ -0,0 +1,69 @@
+/***************************************************************************
+**
+** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (directui@nokia.com)
+**
+** This file is part of duicompositor.
+**
+** If you have questions regarding the use of this file, please contact
+** Nokia at directui@nokia.com.
+**
+** This library is free software; you can redistribute it and/or
+** modify it under the terms of the GNU Lesser General Public
+** License version 2.1 as published by the Free Software Foundation
+** and appearing in the file LICENSE.LGPL included in the packaging
+** of this file.
+**
+****************************************************************************/
+
+
+#ifndef MRMISERVER_P_H
+#define MRMISERVER_P_H
+
+#include <QVariant>
+#include <QLocalServer>
+
+class QDataStream;
+
+class MRmiServerPrivate
+{
+ Q_DECLARE_PUBLIC( MRmiServer )
+public:
+
+ MRmiServerPrivate(const QString& key);
+ virtual ~MRmiServerPrivate();
+ virtual void exportObject(QObject* p);
+ QObject* currentObject();
+ QString key() const;
+
+ virtual void _q_incoming() = 0;
+ virtual void _q_readData() = 0;
+
+ MRmiServer * q_ptr;
+private:
+ QString _key;
+ QObject* _obj;
+};
+
+class MRmiServerPrivateSocket: public MRmiServerPrivate
+{
+ Q_DECLARE_PUBLIC( MRmiServer )
+
+public:
+ MRmiServerPrivateSocket(const QString& key);
+
+ virtual void exportObject(QObject* p);
+
+ virtual void _q_incoming();
+ virtual void _q_readData();
+
+private:
+ void invoke(QDataStream&);
+
+ QLocalServer _serv;
+ QLocalSocket* _sock;
+ quint16 method_size;
+};
+
+#endif //MRMISERVER_P_H