Overview

Namespaces

  • aliuly
    • common
      • selectors
    • loader
  • xPaw

Classes

  • ArmorItems
  • BasicCli
  • BasicHelp
  • BasicPlugin
  • ChatSession
  • Cmd
  • CmdSelector
  • ExpandVars
  • FastTransfer
  • FileUtils
  • FreezeSession
  • GetMotd
  • GetMotdAsyncTask
  • InvisibleSession
  • InvUtils
  • ItemName
  • mc
  • mc2
  • MoneyAPI
  • MPMU
  • Npc
  • PermUtils
  • PluginAsyncTask
  • PluginCallbackTask
  • PMScript
  • QueryAsyncTask
  • Rcon
  • RconTask
  • Session
  • ShieldSession
  • ShoppingCart
  • SignUtils
  • SkinUtils
  • SpySession
  • SubCommandMap
  • TPUtils
  • Overview
  • Namespace
  • Class

Class BasicCli

Implements Basic CLI common functionality. It is useful for plugins that implement multiple commands or sub-commands

Direct known subclasses

aliuly\common\BasicHelp
Abstract
Namespace: aliuly\common
Located at aliuly/common/BasicCli.php
Methods summary
public
# __construct( aliuly\common\BasicPlugin $owner )

Parameters

$owner
  • Plugin that owns this module
public
# enableSCmd( str $cmd, mixed[] $opts )

Register this class as a sub-command. See BasicPlugin for details.

Register this class as a sub-command. See BasicPlugin for details.

Parameters

$cmd
  • sub-command to register
$opts
  • additional options for registering sub-command
public
# enableCmd( str $cmd, mixed[] $yaml )

Register this class as a command.

Register this class as a command.

Parameters

$cmd
  • command to register
$yaml
  • options for command
protected integer
# getPageNumber( array & $args )

Use for paginaged output implementation. This gets the player specified page number that we want to Display

Use for paginaged output implementation. This gets the player specified page number that we want to Display

Parameters

$args
  • Passed arguments

Returns

integer
page number
protected boolean
# paginateText( pocketmine\command\CommandSender $sender, integer $pageNumber, array $txt )

Use for paginaged output implementation. Shows a bunch of line in paginated output.

Use for paginaged output implementation. Shows a bunch of line in paginated output.

Parameters

$sender
  • entity that we need to display text to
$pageNumber
  • page that we need to display
$txt
  • Array containing one element per output line

Returns

boolean
true
protected boolean
# paginateTable( pocketmine\command\CommandSender $sender, integer $pageNumber, array $tab )

Use for paginaged output implementation. Formats and paginates a table

Use for paginaged output implementation. Formats and paginates a table

Parameters

$sender
  • entity that we need to display text to
$pageNumber
  • page that we need to display
$tab
$txt - Array containing one element per cell

Returns

boolean
true
public mixed
# getState( pocketmine\command\CommandSender $player, mixed $default )

Entry point for BasicPlugin state functionality. This makes it module specific. Retrieves the state.

Entry point for BasicPlugin state functionality. This makes it module specific. Retrieves the state.

Parameters

$player
  • entity that we need state from
$default
  • Default value to return if no state found

Returns

mixed
$state
public
# setState( pocketmine\command\CommandSender $player, mixed $val )

Entry point for BasicPlugin state functionality. This makes it module specific. Sets the state.

Entry point for BasicPlugin state functionality. This makes it module specific. Sets the state.

Parameters

$player
  • entity that we need to set state
$val
  • Value to use for the state
public
# unsetState( pocketmine\command\CommandSender $player )

Entry point for BasicPlugin state functionality. This makes it module specific. UnSets the state.

Entry point for BasicPlugin state functionality. This makes it module specific. UnSets the state.

Parameters

$player
  • entity that we need to unset state
Properties summary
protected $owner
#
API documentation generated by ApiGen