-
-
Save briandela/3731464 to your computer and use it in GitHub Desktop.
VNext SignalR API
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Clients.addMessage(message); | |
Others.addMessage(message); // Does not exist yet | |
Clients[group].addMessage(message); | |
Clients[Context.ConnectionId].addMessage(message); | |
IClientProxy proxy = Clients; | |
proxy.Invoke("addMessage", message); | |
IClientProxy proxy1 = Clients[group]; | |
proxy1.Invoke("addMessage", message); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Dynamic | |
InvokeOn.All.addMessage(message); | |
InvokeOn.Others.addMessage(message); | |
InvokeOn.Caller.addMessage(message); | |
InvokeOn.Group(group).addMessage(message); | |
InvokeOn.Client(Context.ConnectionId).addMessage(message); | |
// Indirect | |
Invoke("addMessage", message).On.All(); | |
Invoke("addMessage", message).On.Others(); | |
Invoke("addMessage", message).On.Caller(); | |
Invoke("addMessage", message).On.Group(group); | |
Invoke("addMessage", message).On.Client(Context.ConnectionId); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Dynamic | |
Clients.All.addMessage(message); | |
Clients.Others.addMessage(message); | |
Clients.Caller.addMessage(message); | |
Clients.Group(group).addMessage(message); | |
Clients.Client(Context.ConnectionId).addMessage(message); | |
// Indirect | |
Clients.Invoke("addMessage", message).On.All(); | |
Clients.Invoke("addMessage", message).On.Others(); | |
Clients.Invoke("addMessage", message).On.Caller(); | |
Clients.Invoke("addMessage", message).On.Group(group); | |
Clients.Invoke("addMessage", message).On.Client(Context.ConnectionId); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Dynamic | |
Connected.All.addMessage(message); | |
Connected.Others.addMessage(message); | |
Connected.Caller.addMessage(message); | |
Connected.Group(group).addMessage(message); | |
Connected.Client(Context.ConnectionId).addMessage(message); | |
// Indirect | |
Connected.Invoke("addMessage", message).On.All(); | |
Connected.Invoke("addMessage", message).On.Others(); | |
Connected.Invoke("addMessage", message).On.Caller(); | |
Connected.Invoke("addMessage", message).On.Group(group); | |
Connected.Invoke("addMessage", message).On.Client(Context.ConnectionId); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment