rveppclient.h

来自「h.248协议源码」· C头文件 代码 · 共 100 行

H
100
字号
#if (0)
******************************************************************************
Filename   :
Description:
******************************************************************************
                Copyright (c) 1999 RADVision Inc.
************************************************************************
NOTICE:
This document contains information that is proprietary to RADVision LTD.
No part of this publication may be reproduced in any form whatsoever 
without written prior approval by RADVision LTD..

RADVision LTD. reserves the right to revise this publication and make 
changes without obligation to notify any person of such revisions or 
changes.
******************************************************************************
$Revision:$
$Date:$
$Author: S. Cipolli$
******************************************************************************
#endif

#ifndef RV_EPPCLIENT_H
#define RV_EPPCLIENT_H

#include "rvtypes.h"
#include "rvptrlist.h"
#include "rvthread.h"
#include "rvsocket.h"
#include "rvepp.h"

#ifdef __cplusplus
extern "C" {
#endif

/* Client */

typedef struct {
	RvSocket s;
	char name[32];
	char packages[32];
	char ip[32];
	RvInetPort port;
	void* data;
	char profile[32];
} RvEppClientEndpoint;

RvEppClientEndpoint* rvEppClientEndpointConstruct(RvEppClientEndpoint* ece,
  const char* name, const char* packages, 
  const char* ip, RvInetPort port);
void rvEppClientEndpointDestruct(RvEppClientEndpoint* ece);
#define rvEppClientEndpointGetName(ece)			((ece->name))
#define rvEppClientEndpointGetPackages(ece)		((ece)->packages)
#define rvEppClientEndpointGetIp(ece)			((ece)->ip)
#define rvEppClientEndpointGetPort(ece)			((ece)->port)
#define rvEppClientEndpointGetProfile(ece)		((ece)->profile)
#define rvEppClientEndpointGetUserData(ece)		((ece)->data)
#define rvEppClientEndpointSetUserData(ece, d)	((ece)->data = (d))

struct RvEppClient_;
typedef void (*RvEppClientRegister)(struct RvEppClient_* ec, RvEppClientEndpoint* ece, void *data);
typedef void (*RvEppClientEvent)(struct RvEppClient_* ec, RvEppClientEndpoint* ece, const char* eventName, 
								 char* eventParams, void *data);
typedef void (*RvEppClientUnregister)(struct RvEppClient_* ec, RvEppClientEndpoint* ece, void *data);
typedef struct RvEppClient_ {
	RvSocket s;
	RvThread thread;
	RvBool done;
	RvPtrList endpoints;
	RvEppClientRegister eRegister;
	RvEppClientEvent eEvent;
	RvEppClientUnregister eUnregister;
	void *data;
} RvEppClient;

RvEppClient* rvEppClientConstruct(RvEppClient* ec, RvInetPort port,
  RvEppClientRegister eRegister, RvEppClientEvent eEvent,
  RvEppClientUnregister eUnregister, void *data);
void rvEppClientDestruct(RvEppClient* ec);
RvEppConnId rvEppClientOpen(RvEppClient* ec, RvEppClientEndpoint* ece,
  RvEppConnParameters* connParams);
RvBool rvEppClientModify(RvEppClient* ec, RvEppClientEndpoint* ece,
  RvEppConnId connId, RvEppConnParameters* connParams);
char* rvEppClientQuery(RvEppClient* ec, RvEppClientEndpoint* ece, 
  const char* termConnId, const char* propertyName, OUT char* propertyValue);
RvBool rvEppClientSet(RvEppClient* ec, RvEppClientEndpoint* ece, const char* termConnId, 
					  const char* propertyName, const char* propertyValue);
RvInetPort rvEppClientGetPort(RvEppClient* ec, RvEppClientEndpoint* ece, 
  RvEppConnId connId);
RvBool rvEppClientClose(RvEppClient* ec, RvEppClientEndpoint* ece, RvEppConnId connId);
RvBool rvEppClientStart(RvEppClient* ec, RvEppClientEndpoint* ece, const char* signal);
RvBool rvEppClientStop(RvEppClient* ec, RvEppClientEndpoint* ece, const char* signal);


#ifdef __cplusplus
}
#endif

#endif

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?