AloFramework Handlers 2.0 API
  • Namespace
  • Class
  • Tree
  • Deprecated
  • Todo

Namespaces

  • AloFramework
    • Handlers
      • Config
      • Output
        • Styles
  • PHP

Classes

  • AbstractStyle
  • Error
  • Info
  • Warning

Class AbstractStyle

Abstract version of the CLI output formatter. See Symfony\Component\Console\Formatter\OutputFormatterStyle for descriptions of the setters.

AloFramework\Handlers\Output\Styles\AbstractStyle implements Symfony\Component\Console\Formatter\OutputFormatterStyleInterface

Direct known subclasses

AloFramework\Handlers\Output\Styles\Error, AloFramework\Handlers\Output\Styles\Info, AloFramework\Handlers\Output\Styles\Warning

Abstract
Namespace: AloFramework\Handlers\Output\Styles
Author: Art a.molcanovas@gmail.com
Located at class/Output/Styles/AbstractStyle.php

Methods summary

public
# __construct( string|array $setOption = null )

Constructor

Constructor

Parameters

$setOption
Optionally set a formatter style option or array of options

Author

Art a.molcanovas@gmail.com
public
# setBackground( string $bg = null )

Sets the background colour

Sets the background colour

Parameters

$bg
The background colour

Author

Art a.molcanovas@gmail.com

Codecoverageignore

  • nothing to test.

public
# setOptions( array $opt )

Sets multiple options

Sets multiple options

Parameters

$opt
The options

Author

Art a.molcanovas@gmail.com

Codecoverageignore

  • nothing to test.

public
# setOption( string $opt )

Sets an option

Sets an option

Parameters

$opt
The option

Author

Art a.molcanovas@gmail.com

Codecoverageignore

  • nothing to test.

public
# setForeground( string $fg = null )

Sets the foreground colour

Sets the foreground colour

Parameters

$fg
The foreground colour

Author

Art a.molcanovas@gmail.com

Codecoverageignore

  • nothing to test.

public
# unsetOption( string $option )

Unsets some specific style option.

Unsets some specific style option.

Parameters

$option
The option name

Author

Art a.molcanovas@gmail.com

Codecoverageignore

  • nothing to test.

public string
# apply( string $text )

Applies the style to a given text.

Applies the style to a given text.

Parameters

$text
The text to style

Returns

string

Codecoverageignore

  • nothing to test.

Properties summary

protected AloFramework\Handlers\Config\AbstractConfig $cfg

Config instance

Config instance

#
AloFramework Handlers 2.0 API API documentation generated by ApiGen