net.anidb.udp
Class UdpResponse

java.lang.Object
  extended by net.anidb.udp.UdpResponse

public class UdpResponse
extends java.lang.Object

A response from the server.

Version:
1.0, 29.11.2009
Author:
grizzlyxp (http://anidb.net/perl-bin/animedb.pl?show=userpage&uid=63935)

Method Summary
 UdpResponseEntry getEntryAt(int index)
          Returns the entry on the given index.
 int getEntryCount()
          Returns the count of the entries.
 java.lang.String getMessageString()
          Returns the entries as an message string.
 int getReturnCode()
          Returns the return code.
 java.lang.String getReturnString()
          Returns the return string.
 java.lang.String getTrimedMessageString()
          Returns the entries as an message string as one line wihout line feeds.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Method Detail

getReturnCode

public int getReturnCode()
Returns the return code.

Returns:
The return code.

getReturnString

public java.lang.String getReturnString()
Returns the return string.

Returns:
The return string.

getEntryCount

public int getEntryCount()
Returns the count of the entries.

Returns:
The count.

getEntryAt

public UdpResponseEntry getEntryAt(int index)
Returns the entry on the given index.

Parameters:
index - The index.
Returns:
The entry.
Throws:
java.lang.IndexOutOfBoundsException - If the index is out of bounds.

getMessageString

public java.lang.String getMessageString()
Returns the entries as an message string.

Returns:
The message string or null, if this response hasn't any entries.

getTrimedMessageString

public java.lang.String getTrimedMessageString()
Returns the entries as an message string as one line wihout line feeds.

Returns:
The message string or null, if this response hasn't any entries.

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object