コード例 #1
0
        /// <summary>
        /// Sends a message to a channel.
        /// </summary>
        /// <param name="url">ORTC server URL.</param>
        /// <param name="isCluster">Indicates whether the ORTC server is in a cluster.</param>
        /// <param name="authenticationToken">Authentication Token which is generated by the application server, for instance a unique session ID.</param>
        /// <param name="applicationKey">Application Key that was provided to you together with the ORTC service purchasing.</param>
        /// <param name="privateKey">The private key provided to you together with the ORTC service purchasing.</param>
        /// <param name="channel">The channel where the message will be sent.</param>
        /// <param name="message">The message to send.</param>
        /// <returns>True if the send was successful or false if it was not.</returns>
        public static UnityTask <bool> SendMessage(string url, bool isCluster, string authenticationToken, string applicationKey, string privateKey, string channel, string message)
        {
            var client = new MessageClient(url, isCluster, authenticationToken, applicationKey, privateKey, channel, message);

            return(client.SendMessage());
        }
コード例 #2
0
 /// <summary> 
 /// Sends a message to a channel.
 /// </summary>
 /// <param name="url">ORTC server URL.</param>
 /// <param name="isCluster">Indicates whether the ORTC server is in a cluster.</param>
 /// <param name="authenticationToken">Authentication Token which is generated by the application server, for instance a unique session ID.</param>
 /// <param name="applicationKey">Application Key that was provided to you together with the ORTC service purchasing.</param>
 /// <param name="privateKey">The private key provided to you together with the ORTC service purchasing.</param>
 /// <param name="channel">The channel where the message will be sent.</param>
 /// <param name="message">The message to send.</param>
 /// <returns>True if the send was successful or false if it was not.</returns>
 public static UnityTask<bool> SendMessage(string url, bool isCluster, string authenticationToken, string applicationKey, string privateKey, string channel, string message)
 {
     var client = new MessageClient(url, isCluster, authenticationToken, applicationKey, privateKey, channel, message);
     return client.SendMessage();
 }