Class MessageP2SCreateCharacter

java.lang.Object
marauroa.common.net.message.Message
marauroa.common.net.message.MessageP2SCreateCharacter
All Implemented Interfaces:
Serializable

public class MessageP2SCreateCharacter extends Message
This message indicate the server to create a character for the specified user
See Also:
Message
  • Constructor Details

    • MessageP2SCreateCharacter

      public MessageP2SCreateCharacter()
      Constructor for allowing creation of an empty message
    • MessageP2SCreateCharacter

      public MessageP2SCreateCharacter(Channel source, String credentials, String forwardedFor, String username, String character, RPObject template)
      Constructor with a TCP/IP source/destination of the message and character name and character configuration.
      Parameters:
      source - TCP/IP address associated to this message
      credentials - authentication
      forwardedFor - forwarded for
      username - name of account
      character - the desired character name
      template - a RPObject that contains attributes that will be used on the created character.
  • Method Details

    • getCredentials

      public String getCredentials()
      Returns the credentials
      Returns:
      the credentials
    • getUsername

      public String getUsername()
      Returns the username
      Returns:
      the username
    • getCharacter

      public String getCharacter()
      Returns the character name
      Returns:
      the character name
    • getForwardedFor

      public String getForwardedFor()
      the ip-address this request is forwarded for
      Returns:
      IP-address
    • getTemplate

      public RPObject getTemplate()
      Returns the object template
      Returns:
      the object template
    • toString

      public String toString()
      This method returns a String that represent the object
      Overrides:
      toString in class Message
      Returns:
      a string representing the object.
    • writeObject

      public void writeObject(OutputSerializer out) throws IOException
      Description copied from class: Message
      Serialize the object into an ObjectOutput
      Specified by:
      writeObject in interface Serializable
      Overrides:
      writeObject in class Message
      Parameters:
      out - the output serializer.
      Throws:
      IOException - if the serializations fails
    • readObject

      public void readObject(InputSerializer in) throws IOException
      Description copied from class: Message
      Serialize the object from an ObjectInput
      Specified by:
      readObject in interface Serializable
      Overrides:
      readObject in class Message
      Parameters:
      in - the input serializer
      Throws:
      IOException - if the serializations fails