C# Class Fun.FunapiMulticastClient

Show file Open project: iFunFactory/demo-kgc-2015 Class Usage Examples

Public Methods

Method Description
FunapiMulticastClient ( FunapiNetwork network, FunEncoding encoding ) : UnityEngine
InChannel ( string channel_id ) : bool
JoinChannel ( string channel_id, ChannelReceiveHandler handler ) : bool
LeaveChannel ( string channel_id ) : bool
SendToChannel ( FunMulticastMessage mcast_msg ) : bool

The sender must fill in the mcast_msg. The "channel_id" field is mandatory. And mcas_msg must have join and leave flags set.

SendToChannel ( object json_msg ) : bool

The sender must fill in the mcast_msg. The "channel_id" field is mandatory. And mcas_msg must have join and leave flags set.

Private Methods

Method Description
OnReceived ( string msg_type, object body ) : void

Method Details

FunapiMulticastClient() public method

public FunapiMulticastClient ( FunapiNetwork network, FunEncoding encoding ) : UnityEngine
network FunapiNetwork
encoding FunEncoding
return UnityEngine

InChannel() public method

public InChannel ( string channel_id ) : bool
channel_id string
return bool

JoinChannel() public method

public JoinChannel ( string channel_id, ChannelReceiveHandler handler ) : bool
channel_id string
handler ChannelReceiveHandler
return bool

LeaveChannel() public method

public LeaveChannel ( string channel_id ) : bool
channel_id string
return bool

SendToChannel() public method

The sender must fill in the mcast_msg. The "channel_id" field is mandatory. And mcas_msg must have join and leave flags set.
public SendToChannel ( FunMulticastMessage mcast_msg ) : bool
mcast_msg FunMulticastMessage
return bool

SendToChannel() public method

The sender must fill in the mcast_msg. The "channel_id" field is mandatory. And mcas_msg must have join and leave flags set.
public SendToChannel ( object json_msg ) : bool
json_msg object
return bool