PocketMine-MP 5.21.2 git-a6534ecbbbcf369264567d27e5ed70f7f5be9816
Loading...
Searching...
No Matches
pocketmine\command\utils\CommandStringHelper Class Reference
+ Collaboration diagram for pocketmine\command\utils\CommandStringHelper:

Static Public Member Functions

static parseQuoteAware (string $commandLine)
 

Detailed Description

Definition at line 31 of file CommandStringHelper.php.

Member Function Documentation

◆ parseQuoteAware()

static pocketmine\command\utils\CommandStringHelper::parseQuoteAware ( string $commandLine)
static

Parses a command string into its component parts. Parts of the string which are inside unescaped quotes are considered as one argument.

Examples:

  • give "steve jobs" apple -> ['give', 'steve jobs', 'apple']
  • say "This is a \"string containing quotes\"" -> ['say', 'This is a "string containing quotes"']
Returns
string[] @phpstan-return list<string>

Definition at line 48 of file CommandStringHelper.php.


The documentation for this class was generated from the following file: