Ultralight.Client.StompClient.ExecuteWhenConnected C# (CSharp) 메소드

ExecuteWhenConnected() 개인적인 메소드

Executes the given action when the client is connected to the server, otherwise store it for later use.
private ExecuteWhenConnected ( System.Action command ) : void
command System.Action The command.
리턴 void
        private void ExecuteWhenConnected(Action command)
        {
            if (IsConnected)
            {
                command();
            }
            else
            {
                _commandQueue.Enqueue(command);
            }
        }