|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectnet.sf.opensmus.MUSServer
public class MUSServer
| Field Summary | |
|---|---|
int |
authentication
|
long |
drop_msg
|
java.lang.String |
encryptionKey
|
int |
idle
|
long |
in_bytes
|
long |
in_msg
|
boolean |
m_alive
Alive flag of server. |
protected java.util.Vector<java.lang.String> |
m_allowedmoviepathnames
|
protected java.util.Vector<java.lang.String> |
m_allowedmovieslist
|
java.util.concurrent.ConcurrentHashMap<java.lang.String,MUSUser> |
m_clientlist
|
MUSDBConnection |
m_dbConn
|
protected java.util.Vector<java.lang.String> |
m_disabledmovieslist
|
protected boolean |
m_enabled
|
int |
m_loginlimit
|
protected MUSServerLoginQueue |
m_loginqueue
|
int |
m_maxconnections
|
java.util.concurrent.ConcurrentHashMap<java.lang.String,MUSMovie> |
m_movielist
|
java.util.Vector<MUSConnectionPort> |
m_ports
|
MUSServerProperties |
m_props
|
MUSScriptMap |
m_scriptmap
|
MUSSQLConnection |
m_sqlConn
|
long |
m_starttime
|
java.lang.String |
m_udpAddress
|
protected java.util.Vector<java.lang.Integer> |
m_udpPortsInUse
|
int |
m_udpStartingPort
|
static java.lang.String |
m_vendorname
|
static java.lang.String |
m_version
|
long |
out_bytes
|
long |
out_msg
|
java.util.LinkedHashMap<java.lang.Integer,java.lang.Long> |
recentIPs
|
org.jboss.netty.channel.group.ChannelGroup |
UDP_channels
|
| Constructor Summary | |
|---|---|
MUSServer()
|
|
MUSServer(MUSServerProperties properties)
|
|
| Method Summary | |
|---|---|
void |
addConnectionPort(MUSConnectionPort onePort)
|
void |
addMovie(MUSMovie onemovie)
|
void |
addMUSUser(MUSUser oneClient)
|
void |
addUDPPort(int portNum)
|
void |
changeUserMovie(ServerUser wuser,
java.lang.String wnewmovie)
|
void |
checkDatabaseConnections()
|
void |
checkStructure()
|
ServerMovie |
createServerMovie(java.lang.String moviename)
Creates a new movie on the server and returns a pointer to it. |
void |
deleteServerMovie(java.lang.String moviename)
Deletes a movie from the server. |
void |
disable()
|
void |
disableMovie(java.lang.String mname)
|
void |
disconnectAllUsers()
|
boolean |
doesServerLogging()
|
void |
enable()
|
void |
enableMovie(java.lang.String mname)
|
void |
ensureLoggerThreadIsAlive()
|
void |
ensureThreadsAreAlive()
|
void |
freeConnectionPorts()
|
MUSMovie |
getMovie(java.lang.String mname)
|
ServerMovie |
getServerMovie(int movieidx)
Deprecated. since it's not working correctly |
ServerMovie |
getServerMovie(java.lang.String moviename)
Retrieves a pointer to a ServerMovie object active on the server. |
ServerUserDatabase |
getServerUserDatabase()
Returns a pointer to the ServerUserDatabase interface representing the default user authentication table. |
SQLGateway |
getSQLGateway()
Returns a pointer to the SQLGateway interface representing the default SQL connection. |
int |
getUDPPortNumber()
|
void |
initConnectionPorts()
|
protected boolean |
isMovieAllowed(java.lang.String moviename)
|
protected boolean |
isMoviePathnameAllowed(java.lang.String pathname,
int logonmsgformat)
|
void |
killServer()
|
int |
language()
This method is reserved. |
void |
logDroppedMsg()
|
void |
logInBytes(int bytes)
|
void |
logOutBytes(int bytes)
|
java.lang.String |
path()
Gets the path of the server executable in the system |
protected void |
processLogonMessage(MUSMessage msg,
MUSUser oneUser)
|
void |
put(java.lang.String msg)
Displays a message to the server active output (log file or terminal window) |
void |
queueLogonMessage(MUSMessage msg,
MUSUser oneUser)
|
void |
releaseUDPPort(int portNum)
|
void |
removeConnectionPort(MUSConnectionPort onePort)
|
void |
removeMovie(MUSMovie onemovie)
|
void |
removeMUSUser(MUSUser oneClient)
|
int |
serverMovieCount()
Gets the number of active movies in the server. |
void |
setuserLevel(int level)
Sets the default user levels for users that connect to the server and do not have a user account in the DB. |
LValue |
srvcmd_getMovies()
|
LValue |
srvcmd_getUserCount()
|
LValue |
srvcmd_getVersion()
|
int |
timeStamp()
Gets the current server time as an int |
java.lang.String |
timeString()
Gets the current server time formatted as a String |
int |
userLevel()
Gets the default user levels for users that connect to the server and do not have a user account in the DB. |
boolean |
userThreadAlive(java.lang.String uname)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public final java.util.concurrent.ConcurrentHashMap<java.lang.String,MUSUser> m_clientlist
public final java.util.concurrent.ConcurrentHashMap<java.lang.String,MUSMovie> m_movielist
protected MUSServerLoginQueue m_loginqueue
protected final java.util.Vector<java.lang.String> m_allowedmovieslist
protected final java.util.Vector<java.lang.String> m_disabledmovieslist
protected final java.util.Vector<java.lang.String> m_allowedmoviepathnames
public final java.util.Vector<MUSConnectionPort> m_ports
public final java.util.LinkedHashMap<java.lang.Integer,java.lang.Long> recentIPs
public MUSDBConnection m_dbConn
public MUSSQLConnection m_sqlConn
public MUSServerProperties m_props
public MUSScriptMap m_scriptmap
public long m_starttime
public static java.lang.String m_vendorname
public static java.lang.String m_version
public volatile int idle
public int m_maxconnections
public int m_loginlimit
protected boolean m_enabled
public volatile boolean m_alive
public java.lang.String encryptionKey
public int authentication
public int m_udpStartingPort
public java.lang.String m_udpAddress
protected java.util.Vector<java.lang.Integer> m_udpPortsInUse
public org.jboss.netty.channel.group.ChannelGroup UDP_channels
public long in_bytes
public long out_bytes
public long in_msg
public long out_msg
public long drop_msg
| Constructor Detail |
|---|
public MUSServer()
public MUSServer(MUSServerProperties properties)
| Method Detail |
|---|
public void killServer()
public void disconnectAllUsers()
public void freeConnectionPorts()
public void initConnectionPorts()
public void disable()
public void enable()
public void checkDatabaseConnections()
public void ensureLoggerThreadIsAlive()
public void ensureThreadsAreAlive()
public void removeMUSUser(MUSUser oneClient)
public void addMUSUser(MUSUser oneClient)
public boolean userThreadAlive(java.lang.String uname)
public void checkStructure()
public void logInBytes(int bytes)
public void logOutBytes(int bytes)
public void logDroppedMsg()
public void addConnectionPort(MUSConnectionPort onePort)
public void removeConnectionPort(MUSConnectionPort onePort)
public int getUDPPortNumber()
public void addUDPPort(int portNum)
public void releaseUDPPort(int portNum)
protected boolean isMovieAllowed(java.lang.String moviename)
protected boolean isMoviePathnameAllowed(java.lang.String pathname,
int logonmsgformat)
public MUSMovie getMovie(java.lang.String mname)
throws MovieNotFoundException
MovieNotFoundExceptionpublic void disableMovie(java.lang.String mname)
public void enableMovie(java.lang.String mname)
public void changeUserMovie(ServerUser wuser,
java.lang.String wnewmovie)
throws MUSErrorCode
MUSErrorCode
public void queueLogonMessage(MUSMessage msg,
MUSUser oneUser)
protected void processLogonMessage(MUSMessage msg,
MUSUser oneUser)
public void addMovie(MUSMovie onemovie)
public void removeMovie(MUSMovie onemovie)
public LValue srvcmd_getVersion()
public LValue srvcmd_getUserCount()
public LValue srvcmd_getMovies()
public SQLGateway getSQLGateway()
ServerObject
getSQLGateway in interface ServerObjectpublic ServerUserDatabase getServerUserDatabase()
ServerObject
getServerUserDatabase in interface ServerObjectpublic void put(java.lang.String msg)
ServerObject
put in interface ServerObject
public ServerMovie getServerMovie(java.lang.String moviename)
throws MovieNotFoundException
ServerObject
getServerMovie in interface ServerObjectmoviename - String with the name of the movie to be returned
MovieNotFoundException
public ServerMovie getServerMovie(int movieidx)
throws MovieNotFoundException
getServerMovie in interface ServerObjectmovieidx - index of the movie to be returned
MovieNotFoundExceptionServerObject.getServerMovie(int)
public ServerMovie createServerMovie(java.lang.String moviename)
throws MUSErrorCode
ServerObject
createServerMovie in interface ServerObjectmoviename - String with the name of the movie to be created
MUSErrorCodepublic void deleteServerMovie(java.lang.String moviename)
ServerObject
deleteServerMovie in interface ServerObjectmoviename - String with the name of the movie to be deletedpublic int serverMovieCount()
ServerObject
serverMovieCount in interface ServerObjectpublic java.lang.String path()
ServerObject
path in interface ServerObjectpublic java.lang.String timeString()
ServerObject
timeString in interface ServerObjectpublic int timeStamp()
ServerObject
timeStamp in interface ServerObjectpublic int language()
ServerObject
language in interface ServerObjectpublic int userLevel()
ServerObject
userLevel in interface ServerObjectpublic void setuserLevel(int level)
ServerObject
setuserLevel in interface ServerObjectpublic final boolean doesServerLogging()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||