HostedConnection can now supply the Server instance
that is hosting it. git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@7082 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
This commit is contained in:
parent
35e19c1667
commit
6ee8fb646c
@ -43,6 +43,11 @@ import java.util.Set;
|
||||
*/
|
||||
public interface HostedConnection extends MessageConnection
|
||||
{
|
||||
/**
|
||||
* Returns the Server instance that is hosting this connection.
|
||||
*/
|
||||
public Server getServer();
|
||||
|
||||
/**
|
||||
* Returns the server-unique ID for this client.
|
||||
*/
|
||||
|
@ -379,7 +379,12 @@ public class DefaultServer implements Server
|
||||
{
|
||||
id = nextId.getAndIncrement();
|
||||
}
|
||||
|
||||
|
||||
public Server getServer()
|
||||
{
|
||||
return DefaultServer.this;
|
||||
}
|
||||
|
||||
public int getId()
|
||||
{
|
||||
return id;
|
||||
|
Loading…
x
Reference in New Issue
Block a user