Class | ::User
In: | lib/rbot/core/userdata.rb
Parent: | Object

### Methods

botdata get_botdata set_botdata with_botdata

### Public Instance methods

botdata(key=nil)

Retrive Bot data associated with the receiver. This method is intended for data retrieval only. See set_bot_data() if you need to alter User data.

get_botdata(key=nil)

Alias for botdata

set_botdata(key, value=nil, &block)

This method is used to store Bot data associated with the receiver. If no block is passed, value is stored for the key key; if a block is passed, it will be called with the previous key value as parameter, and its return value will be stored as the new value. If value is present in the block form, it will be used to initialize key if it‘s missing.

If you have to do large-scale editing of the Bot data Hash, please use with_botdata.

with_botdata(&block)

This method yields the entire Bot data Hash to the block, and stores any changes done to it, returning a copy of the (changed) Hash.

[Validate]