Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## it.gotoandplay.smartfoxclient.data
Class Buddy

    java.lang.Object
      it.gotoandplay.smartfoxclient.data.Buddy

    public class Buddy

extends java.lang.Object

The Buddy class represents the user buddy.

This class is used internally by the `SmartFoxClient` class; also, Buddy objects are returned by various methods and events of the SmartFoxServer API.

Version:
  1.0.0
Author:
  The gotoAndPlay() Team
  http://www.smartfoxserver.com
  http://www.gotoandplay.it
See Also:
  `SmartFoxClient.buddyList`, `SmartFoxClient.addBuddy(java.lang.String)`, `SmartFoxClient.getBuddyByName(java.lang.String)`, `SmartFoxClient.getBuddyById(int)`, `SmartFoxClient.getBuddyRoom(it.gotoandplay.smartfoxclient.data.Buddy)`, `SmartFoxClient.loadBuddyList()`, `SmartFoxClient.removeBuddy(java.lang.String)`, `SmartFoxClient.sendBuddyPermissionResponse(boolean, java.lang.String)`, `SmartFoxClient.setBuddyVariables(java.util.Map)`

Constructor Summary
`Buddy()`

Method Summary
`int` | `getId()` Returns the buddy id.
`java.lang.String` | `getName()` Returns the buddy name.
`java.util.Map<java.lang.String,java.lang.String>` | `getVariables()` Returns the buddy variables.
`boolean` | `isBlocked()` Returns if the user is blocked.
`boolean` | `isOnline()` Returns if the user is online or not.
`void` | `setBlocked(boolean blocked)`
`void` | `setId(int id)`
`void` | `setName(java.lang.String name)`
`void` | `setOnline(boolean online)`
`void` | `setVariables(java.util.Map<java.lang.String,java.lang.String> variables)`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### Buddy

    public Buddy()

Method Detail

### getName

    public java.lang.String getName()

  Returns the buddy name.

  Returns:
    the buddy name.

### setName

    public void setName(java.lang.String name)

### getId

    public int getId()

  Returns the buddy id.

  Returns:
    the buddy id.

### setId

    public void setId(int id)

### isOnline

    public boolean isOnline()

  Returns if the user is online or not.

  Returns:
    if the user is online or not.

### setOnline

    public void setOnline(boolean online)

### isBlocked

    public boolean isBlocked()

  Returns if the user is blocked.

  Returns:
    if the user is blocked.

### setBlocked

    public void setBlocked(boolean blocked)

### getVariables

    public java.util.Map<java.lang.String,java.lang.String> getVariables()

  Returns the buddy variables.

  The buddy variables are represented but `Map` where the variable name is key and the variable value is value.

  Returns:
    buddy variables.

### setVariables

    public void setVariables(java.util.Map<java.lang.String,java.lang.String> variables)

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD