Improved docs.

This commit is contained in:
Marco Vito Moscaritolo 2015-07-19 20:09:27 +02:00
parent da17482a80
commit d22211c4b4
4 changed files with 25 additions and 8 deletions

View file

@ -99,6 +99,7 @@ class Builder implements LoggerAwareInterface
/**
* Set up the builder.
*
* @param \PHPCI\Model\Build $build
* @param LoggerInterface $logger
*/
@ -130,6 +131,7 @@ class Builder implements LoggerAwareInterface
/**
* Set the config array, as read from phpci.yml
*
* @param array|null $config
* @throws \Exception
*/
@ -144,6 +146,7 @@ class Builder implements LoggerAwareInterface
/**
* Access a variable from the phpci.yml file.
*
* @param string
* @return mixed
*/
@ -160,6 +163,7 @@ class Builder implements LoggerAwareInterface
/**
* Access a variable from the config.yml
*
* @param $key
* @return mixed
*/
@ -259,6 +263,7 @@ class Builder implements LoggerAwareInterface
/**
* Find a binary required by a plugin.
*
* @param string $binary
* @param bool $quiet
*
@ -272,6 +277,7 @@ class Builder implements LoggerAwareInterface
/**
* Replace every occurrence of the interpolation vars in the given string
* Example: "This is build %PHPCI_BUILD%" => "This is build 182"
*
* @param string $input
* @return string
*/
@ -328,6 +334,7 @@ class Builder implements LoggerAwareInterface
/**
* Write to the build log.
*
* @param $message
* @param string $level
* @param array $context
@ -339,6 +346,7 @@ class Builder implements LoggerAwareInterface
/**
* Add a success-coloured message to the log.
*
* @param string
*/
public function logSuccess($message)
@ -348,6 +356,7 @@ class Builder implements LoggerAwareInterface
/**
* Add a failure-coloured message to the log.
*
* @param string $message
* @param \Exception $exception The exception that caused the error.
*/
@ -359,6 +368,7 @@ class Builder implements LoggerAwareInterface
* Returns a configured instance of the plugin factory.
*
* @param Build $build
*
* @return PluginFactory
*/
private function buildPluginFactory(Build $build)

View file

@ -12,15 +12,17 @@ namespace PHPCI\Helper;
use b8\Config;
/**
* Login Is Disabled Helper - Checks if login is disalbed in the view
* @author Stephen Ball <phpci@stephen.rebelinblue.com>
* @package PHPCI
* @subpackage Web
*/
* Login Is Disabled Helper - Checks if login is disalbed in the view
*
* @author Stephen Ball <phpci@stephen.rebelinblue.com>
* @package PHPCI
* @subpackage Web
*/
class LoginIsDisabled
{
/**
* Checks if
*
* @param $method
* @param array $params
* @return mixed|null
@ -28,7 +30,7 @@ class LoginIsDisabled
public function __call($method, $params = array())
{
unset($method, $params);
$config = Config::getInstance();
$state = (bool) $config->get('phpci.authentication_settings.state', false);

View file

@ -11,6 +11,7 @@ namespace PHPCI\Helper;
/**
* Class MailerFactory helps to set up and configure a SwiftMailer object.
*
* @package PHPCI\Helper
*/
class MailerFactory
@ -22,6 +23,7 @@ class MailerFactory
/**
* Set the mailer factory configuration.
*
* @param array $config
*/
public function __construct($config = array())
@ -34,7 +36,8 @@ class MailerFactory
}
/**
* Returns an instance of Swift_Mailer based on the config.s
* Returns an instance of Swift_Mailer based on the config.
*
* @return \Swift_Mailer
*/
public function getSwiftMailerFromConfig()
@ -61,7 +64,9 @@ class MailerFactory
/**
* Return a specific configuration value by key.
*
* @param $configName
*
* @return null|string
*/
public function getMailConfig($configName)
@ -70,7 +75,6 @@ class MailerFactory
return $this->emailConfig[$configName];
} else {
// Check defaults
switch($configName) {
case 'smtp_address':
return "localhost";

View file

@ -12,6 +12,7 @@ session_start();
require_once(__DIR__ . '/../bootstrap.php');
/** @var PHPCI\Application */
$app = $container->get('application');
print $app->handleRequest();