Phoenix.Channel.Push C# (CSharp) Méthode

Push() public méthode

public Push ( string event_, Newtonsoft.Json.Linq.JObject payload, int timeout ) : Push
event_ string
payload Newtonsoft.Json.Linq.JObject
timeout int
Résultat Push
    public Push Push(string event_, JObject payload, int timeout)
    {
      if (!_joinedOnce) //jfis - necessary?
      {
        throw new Exception($"tried to push '{event_}' to '{_topic}' before joining. Use channel.join() before pushing events");
      }

      var pushEvent = new Push(this, event_, payload, timeout);

      if (CanPush())
      {
        pushEvent.Send(); //jfis - send now if can
      }
      else
      {
        pushEvent.StartTimeout(); //jfis - if cant add to buffer, but what does start timeout do? 
        _pushBuffer.Add(pushEvent);
      }

      return pushEvent;
    }

Same methods

Channel::Push ( string event_, Newtonsoft.Json.Linq.JObject payload ) : Push