2017 © Pedro Peláez
 

library correct-brackets

Return true if the line is correct - all brackets are correctly opened and closed, or false otherwise

image

anikin-elets/correct-brackets

Return true if the line is correct - all brackets are correctly opened and closed, or false otherwise

  • Thursday, May 3, 2018
  • by tanukin
  • Repository
  • 1 Watchers
  • 1 Stars
  • 10 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 6 Versions
  • 0 % Grown

The README.md

Библиотека Correct Brackets

Тестовая библиотека

Возвращает true, если переданная строка корректна т.е. все открытые скобки корректно открыты и закрыты, или же false в противном случае., (*1)

Install via Composer:

composer require anikin-elets/correct-brackets

Usage

$line = '()()(    )()()';
$allowedChars = ['(', ')', '\r', '\n', '\t', '\s'];

$bracketLibrary = new \Library\Command\BracketCommand($line, $allowedChars);
try {
    $isCorrect = $bracketLibrary->execute();
} catch (\Library\Exceptions\InvalidArgumentException $e) {
    echo sprintf("ERROR: %s", $e->getMessage());
}

The Versions

03/05 2018

dev-master

9999999-dev

Return true if the line is correct - all brackets are correctly opened and closed, or false otherwise

  Sources   Download

MIT

The Requires

  • php ~7.1

 

The Development Requires

by Anikin Ewgeny
by Anikin Evgenij

03/05 2018

dev-code-review

dev-code-review

Return true if the line is correct - all brackets are correctly opened and closed, or false otherwise

  Sources   Download

MIT

The Requires

  • php ~7.1

 

The Development Requires

by Anikin Evgenij

03/05 2018

2.0.2

2.0.2.0

Return true if the line is correct - all brackets are correctly opened and closed, or false otherwise

  Sources   Download

MIT

The Requires

  • php ~7.1

 

The Development Requires

by Anikin Evgenij

03/05 2018

2.0.1

2.0.1.0

Return true if the line is correct - all brackets are correctly opened and closed, or false otherwise

  Sources   Download

MIT

The Requires

  • php ~7.1

 

The Development Requires

by Anikin Evgenij

03/05 2018

2.0.0

2.0.0.0

Return true if the line is correct - all brackets are correctly opened and closed, or false otherwise

  Sources   Download

MIT

The Requires

  • php ~7.1

 

The Development Requires

by Anikin Evgenij

06/01 2018

1.0.0

1.0.0.0

Return true if the line is correct - all brackets are correctly opened and closed, or false otherwise

  Sources   Download

MIT

The Requires

  • php ~7.1

 

by Anikin Ewgeny