Katana Plug-in APIs 0.1

KatanaPipe.h

00001 // Copyright (c) 2012 The Foundry Visionmongers Ltd. All Rights Reserved.
00002 
00003 #ifndef KATANA_PIPE_H
00004 #define KATANA_PIPE_H
00005 
00006 #include <string>
00007 
00008 #include <FnDisplayDriver/suite/FnDisplayDriverSuite.h>
00009 #include <FnPluginSystem/FnPluginSystem.h>
00010 
00011 #include "Message.h"
00012 #include "NewChannelMessage.h"
00013 
00014 namespace Foundry
00015 {
00016 namespace Katana
00017 {
00035 class KatanaPipe
00036 {
00037 public:
00058     KatanaPipe(const std::string& hostName,
00059                unsigned int portNumber,
00060                size_t maxQueueSize,
00061                int linger = -1);
00062 
00068     ~KatanaPipe();
00069 
00079     int connect();
00080 
00091     int send(const Message& message);
00092 
00100     void flushPipe(const NewChannelMessage& channel);
00101 
00108     void closeChannel(const NewChannelMessage& channel);
00109 
00116     static FnPlugStatus setHost(FnPluginHost* host);
00117 
00118     static void setSuite(const FnDisplayDriverHostSuite_v1* suite);
00119 
00125     static const FnDisplayDriverHostSuite_v1* getSuite();
00126 
00127 private:
00128     // Disable copy and assignment
00129     KatanaPipe(const KatanaPipe& rhs);
00130     KatanaPipe& operator=(const KatanaPipe& rhs);
00131 
00132     FnKatanaPipeHandle _handle;
00133 
00134     static const FnDisplayDriverHostSuite_v1* _suite;
00135 };
00139 }  // namespace Katana
00140 }  // namespace Foundry
00141 
00142 #endif
 All Classes Functions Variables Typedefs Enumerations Enumerator