com.breeweb.slimconnect.data
Class Player

java.lang.Object
  extended bycom.breeweb.slimconnect.data.Player
All Implemented Interfaces:
java.lang.Comparable

public class Player
extends java.lang.Object
implements java.lang.Comparable

Author:
Bas de Bree

Constructor Summary
Player(int index, java.lang.String id, java.lang.String name)
          constructs an Player object.
 
Method Summary
 int compareTo(java.lang.Object anObject)
           
 boolean equals(java.lang.Object anObject)
           
 java.lang.String getId()
          Returns the current index number in the Slimp3Server.
 int getIndex()
           
 java.lang.String getName()
          Returns the name of the player
 int hashCode()
           
 void setId(java.lang.String string)
          Sets the ID of the player
 void setIndex(int i)
          sets the current index number in the Slimp3Server / Squeezebox server.
 void setName(java.lang.String string)
          The name of the player
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Player

public Player(int index,
              java.lang.String id,
              java.lang.String name)
constructs an Player object. This object refers to the player in the Slimp3Server.

Parameters:
index - the current index in the Squeezebox server.
id - the ID of the player
name - the name of the player.
Method Detail

equals

public boolean equals(java.lang.Object anObject)

hashCode

public int hashCode()

compareTo

public int compareTo(java.lang.Object anObject)
Specified by:
compareTo in interface java.lang.Comparable

toString

public java.lang.String toString()

getId

public java.lang.String getId()
Returns the current index number in the Slimp3Server.

Returns:
the current index number in the Slimp3Server.

getName

public java.lang.String getName()
Returns the name of the player

Returns:
the name of the player

getIndex

public int getIndex()
Returns:
the index within the Squeezebox server.

setId

public void setId(java.lang.String string)
Sets the ID of the player

Parameters:
string - the current ID

setName

public void setName(java.lang.String string)
The name of the player

Parameters:
string - the name of the player

setIndex

public void setIndex(int i)
sets the current index number in the Slimp3Server / Squeezebox server.

Parameters:
i - the index within the Squeezebox server