Module: Bukkit::BanList

Defined in:
lib/bukkit/ban_list.rb

Defined Under Namespace

Modules: Type

Instance Method Summary collapse

Instance Method Details

#ban(target, reason, expires, source) ⇒ Bukkit::BanEntry Also known as: addBan

Adds a ban to this list. If a previous ban exists, this will update the previous entry.

Parameters:

  • target (String)

    the target of the ban

  • reason (String)

    reason for the ban, nil indicates implementation default

  • expires (Date)

    date for the ban’s expiration (unban), or nil to imply forever

  • source (String)

    source of the ban, nil indicates implementation default

Returns:

  • (Bukkit::BanEntry)

    the entry for the newly created ban, or the entry for the (updated) previous ban



32
# File 'lib/bukkit/ban_list.rb', line 32

def ban(target, reason, expires, source); end

#ban_entriesArray Also known as: getBanEntries

Gets a set containing every Bukkit::BanEntry in this list.

Returns:

  • (Array)

    an array containing every entry tracked by this list



38
# File 'lib/bukkit/ban_list.rb', line 38

def ban_entries; end

#ban_entry(target) ⇒ Bukkit::BanEntry Also known as: getBanEntry

Gets a Bukkit::BanEntry by target.

Parameters:

  • target (String)

    entry parameter to search for

Returns:



19
# File 'lib/bukkit/ban_list.rb', line 19

def ban_entry(target); end

#banned?(target) ⇒ boolean Also known as: isBanned

Gets if a Bukkit::BanEntry exists for the target, indicating an active ban status.

Parameters:

  • target (String)

    the target to find

Returns:

  • (boolean)

    true if a Bukkit::BanEntry exists for the name, indicating an active ban status, false otherwise



47
# File 'lib/bukkit/ban_list.rb', line 47

def banned?(target); end

#pardon(target) ⇒ Object

Removes the specified target from this list, therefore indicating a

"not banned" status/

Parameters:

  • target (String)

    the target to remove from this list



54
# File 'lib/bukkit/ban_list.rb', line 54

def pardon(target); end