2017 © Pedro Peláez
 

library health-checker-check

Base interface and abstract level of the checker for health-checker

image

tonicforhealth/health-checker-check

Base interface and abstract level of the checker for health-checker

  • Friday, September 16, 2016
  • by drefixs
  • Repository
  • 1 Watchers
  • 0 Stars
  • 9,152 Installations
  • PHP
  • 2 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 7 Versions
  • 6 % Grown

The README.md

Health-checker-check

License Build Status Scrutinizer Code Quality Code Coverage SensioLabsInsight, (*1)

This is base interface and abstract level of the checker., (*2)

## Installation using Composer

$ composer require tonicforhealth/health-checker-check

## Requirements

  • PHP 5.5 or higher

## Usage

<?php

use TonicHealthCheck\Check\AbstractCheck;

class WeekendCheck extends AbstractCheck
{
    const GROUP = 'date';
    const COMPONENT = 'weekend';
    const CHECK = 'weekend-date-check';

    public function __construct($checkNode)
    {
        parent::__construct($checkNode);
    }

    /**
     * @throws giCheckException
     */
    public function performCheck()
    {
        if ($this->isNotWeekend(date())) {
            throw new CheckException('Unfortunately weekend isn\'t today.');
        }
    }

    protected function isNotWeekend($date)
    {
        return date('N', strtotime($date)) >= 6;
    }
}

$WeekendCheckI = new WeekendCheck('testnode');

$result = $WeekendCheckI->check();

if (!$result->isOk()) {
    echo $result->getError()->getMessage();
}

The Versions

16/09 2016

dev-master

9999999-dev

Base interface and abstract level of the checker for health-checker

  Sources   Download

MIT

The Requires

 

The Development Requires

by Dmitry Gopkalo

tonicforhealth health-checker-check

16/09 2016

v0.2.1

0.2.1.0

Base interface and abstract level of the checker for health-checker

  Sources   Download

MIT

The Requires

 

The Development Requires

by Dmitry Gopkalo

tonicforhealth health-checker-check

08/09 2016

v0.2.0

0.2.0.0

Base interface and abstract level of the checker for health-checker

  Sources   Download

MIT

The Requires

 

The Development Requires

by Dmitry Gopkalo

tonicforhealth health-checker-check

07/09 2016

v0.1.3

0.1.3.0

Base interface and abstract level of the checker for health-checker

  Sources   Download

MIT

The Requires

 

The Development Requires

by Dmitry Gopkalo

tonicforhealth health-checker-check

22/06 2016

v0.1.2

0.1.2.0

Base interface and abstract level of the checker for health-checker

  Sources   Download

MIT

The Requires

 

The Development Requires

by Dmitry Gopkalo

tonicforhealth health-checker-check

06/04 2016

v0.1.1

0.1.1.0

Base interface and abstract level of the checker for health-checker

  Sources   Download

MIT

The Requires

 

The Development Requires

by Dmitry Gopkalo

tonicforhealth health-checker-check

06/03 2016

v0.1.0

0.1.0.0

Base interface and abstract level of the checker for health-checker

  Sources   Download

MIT

The Requires

 

The Development Requires

by Dmitry Gopkalo

tonicforhealth health-checker-check