Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/flash/4.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Adobe Flash媒体服务器聊天室_Flash_Chat_Flash Media Server_Videochat - Fatal编程技术网

Adobe Flash媒体服务器聊天室

Adobe Flash媒体服务器聊天室,flash,chat,flash-media-server,videochat,Flash,Chat,Flash Media Server,Videochat,我正在使用Flash Media Development Server 4.5创建一个小型聊天应用程序。我已经在Flash中创建了所有用户界面组件 要使用聊天应用程序,用户需要来回发送消息。Flash player如何连接到其他Flash player?例如,如果您有一个由20名成员组成的小组。如何向客户端而不是群发送特定消息?聊天应用程序的示例是www.red5chat.com。免费使用。并检查代码flash和Java。将私有消息发送到服务器中的客户端代码为 public void send_

我正在使用Flash Media Development Server 4.5创建一个小型聊天应用程序。我已经在Flash中创建了所有用户界面组件


要使用聊天应用程序,用户需要来回发送消息。Flash player如何连接到其他Flash player?例如,如果您有一个由20名成员组成的小组。如何向客户端而不是群发送特定消息?

聊天应用程序的示例是www.red5chat.com。免费使用。并检查代码flash和Java。将私有消息发送到服务器中的客户端代码为

public void send_private(String fromPseudo, String DestinationID,String msg) {
        //IConnection current = Red5.getConnectionLocal();
        Iterator<IConnection> it = scope.getConnections();
        log.debug("send_private to "+DestinationID+" "+msg);
        //String uid = scope.getClient().getId();
        while (it.hasNext()) {
        IConnection conn = it.next();
        String id=conn.getClient().getId();
        log.debug("id="+id+ " senTO="+DestinationID);
        //if (sendTo.equals(id)) log.info("PAREIL"); else log.info("differents");

        if (!(DestinationID.equals(id))) continue;
        log.info("receive_private "+DestinationID+" "+msg);
            if (conn instanceof IServiceCapableConnection) {
                ((IServiceCapableConnection) conn).invoke("receivePrivateMsg", new Object[]{fromPseudo, msg});
                log.info("received_private "+DestinationID+" "+msg);
            }   
        }
    }
public void send\u private(String fromposeudo,String DestinationID,String msg){
//i连接电流=Red5.getConnectionLocal();
迭代器it=scope.getConnections();
log.debug(“将_private发送到”+DestinationID+“”+msg);
//字符串uid=scope.getClient().getId();
while(it.hasNext()){
IConnection conn=it.next();
字符串id=conn.getClient().getId();
log.debug(“id=“+id+”senTO=“+DestinationID”);
//if(sendTo.equals(id))log.info(“PAREIL”);else log.info(“差异”);
如果(!(DestinationID.equals(id)))继续;
log.info(“接收私有”+DestinationID+“”+msg);
if(IServiceCapableConnection的连接实例){
调用(“receivePrivateMsg”,新对象[]{fromposeudo,msg});
log.info(“已接收的\u private”+DestinationID+“”+msg);
}   
}
}