Class Content

  • package PHPHtmlParser
CloneableInstantiable
Methods
public __construct(string $content = '')
 

Content constructor.

    public char(?int $char = NULL) : string
     

    Gets the current character we are at.

    • return string
    public copyByToken(string $token, bool $char = false, bool $escape = false)
     

    Copies the content until it reaches the token string.,

    • return string
    • uses
    public copyUntil(string $string, bool $char = false, bool $escape = false) : string
     

    Copy the content until we find the given string.

    • return string
    public copyUntilUnless(string $string, string $unless)
     

    Copies the content until the string is found and return it
    unless the 'unless' is found in the substring.

    • return string
    public fastForward(int $count) : PHPHtmlParser\Content
     

    Moves the current position forward.

    public getPosition() : int
     

    Returns the current position of the content.

    • return int
    public rewind(int $count) : PHPHtmlParser\Content
     

    Moves the current position backward.

    public skip(string $string, bool $copy = false)
     

    Skip a given set of characters.

    public skipByToken(string $token, bool $copy = false)
     

    Skip a given token of pre-defined characters.

    Properties
    protected $attr
    protected $blank
     

    The following 4 strings are tags that are important to us.

    • var string
    protected $content
     

    The content string.

    • var string
    protected $equal
    protected $pos
     

    The current position we are in the content.

    • var int
    protected $size
     

    The size of the content.

    • var int
    protected $slash
    © 2020 Bruce Wells
    Search Namespaces \ Classes
    ConfigurationNumbers (0-9.) only