JackChannel.h

00001 /*
00002 Copyright (C) 2004-2006 Grame  
00003 
00004 This program is free software; you can redistribute it and/or modify
00005 it under the terms of the GNU General Public License as published by
00006 the Free Software Foundation; either version 2 of the License, or
00007 (at your option) any later version.
00008 
00009 This program is distributed in the hope that it will be useful,
00010 but WITHOUT ANY WARRANTY; without even the implied warranty of
00011 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00012 GNU General Public License for more details.
00013 
00014 You should have received a copy of the GNU General Public License
00015 along with this program; if not, write to the Free Software
00016 Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
00017 
00018 */
00019 
00020 #ifndef __JackChannel__
00021 #define __JackChannel__
00022 
00023 #include "types.h"
00024 #include "JackError.h"
00025 #include "JackTransportEngine.h"
00026 
00027 namespace Jack
00028 {
00029 
00030 class JackClientInterface;
00031 class JackClient;
00032 class JackServer;
00033 struct JackEngineControl;
00034 class JackGraphManager;
00035 
00040 class JackClientChannelInterface
00041 {
00042 
00043     public:
00044 
00045         JackClientChannelInterface()
00046         {}
00047         virtual ~JackClientChannelInterface()
00048         {}
00049 
00050         // Open the Server/Client connection
00051         virtual int Open(const char* name, char* name_res, JackClient* obj, jack_options_t options, jack_status_t* status)
00052         {
00053             return 0;
00054         }
00055 
00056         // Close the Server/Client connection
00057         virtual void Close()
00058         {}
00059 
00060         // Start listening for messages from the server
00061         virtual int Start()
00062         {
00063             return 0;
00064         }
00065 
00066         // Stop listening for messages from the server
00067         virtual void Stop()
00068         {}
00069                 
00070                 virtual int ServerCheck(const char* server_name)
00071         {
00072                         return -1;
00073                 }
00074                 
00075                 virtual void ClientCheck(const char* name, char* name_res, int protocol, int options, int* status, int* result)
00076         {}
00077         virtual void ClientOpen(const char* name, int* shared_engine, int* shared_client, int* shared_graph, int* result)
00078         {}
00079         virtual void ClientOpen(const char* name, int* ref, JackEngineControl** shared_engine, JackGraphManager** shared_manager, JackClientInterface* client, int* result)
00080         {}
00081         virtual void ClientClose(int refnum, int* result)
00082         {}
00083 
00084         virtual void ClientActivate(int refnum, int* result)
00085         {}
00086         virtual void ClientDeactivate(int refnum, int* result)
00087         {}
00088 
00089         virtual void PortRegister(int refnum, const char* name, unsigned int flags, unsigned int buffer_size, jack_port_id_t* port_index, int* result)
00090         {}
00091         virtual void PortUnRegister(int refnum, jack_port_id_t port_index, int* result)
00092         {}
00093 
00094         virtual void PortConnect(int refnum, const char* src, const char* dst, int* result)
00095         {}
00096         virtual void PortDisconnect(int refnum, const char* src, const char* dst, int* result)
00097         {}
00098         virtual void PortConnect(int refnum, jack_port_id_t src, jack_port_id_t dst, int* result)
00099         {}
00100         virtual void PortDisconnect(int refnum, jack_port_id_t src, jack_port_id_t dst, int* result)
00101         {}
00102 
00103         virtual void SetBufferSize(jack_nframes_t buffer_size, int* result)
00104         {}
00105         virtual void SetFreewheel(int onoff, int* result)
00106         {}
00107 
00108         virtual void ReleaseTimebase(int refnum, int* result)
00109         {}
00110 
00111         virtual void SetTimebaseCallback(int refnum, int conditional, int* result)
00112         {}
00113                 
00114                 virtual void GetInternalClientName(int refnum, int int_ref, char* name_res, int* result)
00115         {}
00116 
00117                 virtual void InternalClientHandle(int refnum, const char* client_name, int* status, int* int_ref, int* result)
00118         {}
00119 
00120                 virtual void InternalClientLoad(int refnum, const char* client_name, const char* so_name, const char* objet_data, int options, int* status, int* int_ref, int* result)
00121         {}
00122                 
00123                 virtual void InternalClientUnload(int refnum, int int_ref, int* status, int* result)
00124         {}
00125 };
00126 
00131 class JackNotifyChannelInterface
00132 {
00133 
00134     public:
00135 
00136         JackNotifyChannelInterface()
00137         {}
00138         virtual ~JackNotifyChannelInterface()
00139         {}
00140 
00141         // Open the Server/Client connection
00142         virtual int Open(const char* name)
00143         {
00144             return 0;
00145         }
00146         // Close the Server/Client connection
00147         virtual void Close()
00148         {}
00149 
00150         /*
00151         The "sync" parameter allows to choose between "synchronous" and "asynchronous" notification
00152         */
00153         virtual void ClientNotify(int refnum, const char* name, int notify, int sync, int value, int* result)
00154         {}
00155 
00156 };
00157 
00162 class JackServerChannelInterface
00163 {
00164 
00165     public:
00166 
00167         JackServerChannelInterface()
00168         {}
00169         virtual ~JackServerChannelInterface()
00170         {}
00171 
00172         // Open the Server/Client connection
00173         virtual int Open(JackServer* server)
00174         {
00175             return 0;
00176         }
00177         // Close the Server/Client connection
00178         virtual void Close()
00179         {}
00180 };
00181 
00186 class JackServerNotifyChannelInterface
00187 {
00188 
00189     public:
00190 
00191         JackServerNotifyChannelInterface()
00192         {}
00193         virtual ~JackServerNotifyChannelInterface()
00194         {}
00195 
00196         // Open the Server RT/Server connection
00197         virtual int Open()
00198         {
00199             return 0;
00200         }
00201         // Close the Server RT/Server connection
00202         virtual void Close()
00203         {}
00204 
00205         virtual void ClientNotify(int refnum, int notify, int value)
00206         {}
00207 
00208 };
00209 
00210 
00211 } // end of namespace
00212 
00213 #endif
00214 

Generated on Mon Oct 15 17:11:13 2007 for Jackdmp by  doxygen 1.5.1