Skip to content

rpgmaker/PServiceBus-Java-Client

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

31 Commits
 
 
 
 
 
 
 
 

Repository files navigation

---------------------------------------------------------------------
Sample Usage
---------------------------------------------------------------------

public class ChatTopic {
	public String UserName, Message;
	public ChatTopic(){}
	public ChatTopic(String userName, String message){
		UserName = userName;
		Message = message;
	}
}


----------------------------------------------------------------------
Console application code
----------------------------------------------------------------------
//Register
PSBClient.register(ChatTopic.class);

//Subscribe 
PSBClient.subscribe(ChatTopic.class, new Action<ChatTopic>(){
	public void execute(ChatTopic msg){
		System.out.println(String.format("%s: %s",msg.UserName, msg.Message));
	}
});

//Publish
PSBClient.publish(new ChatTopic("JavaUser", "Hello from Java"));

About

Java client for using PServiceBus

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages