Skip to content

codestyle - remove trailing whitespaces #130

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from Apr 9, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Behavioral/Command/HelloCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

/**
* This concrete command calls "print" on the Receiver, but an external
* invoker just know he can call "execute"
* invoker just know he can call "execute"
*/
class HelloCommand implements CommandInterface
{
Expand Down
2 changes: 1 addition & 1 deletion Behavioral/NullObject/LoggerInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

/**
* LoggerInterface is a contract for logging something
*
*
* Key feature: NullLogger MUST inherit from this interface like any other Loggers
*/
interface LoggerInterface
Expand Down
2 changes: 1 addition & 1 deletion Behavioral/NullObject/NullLogger.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
/**
* Performance concerns : ok there is a call for nothing but we spare an "if is_null"
* I didn't run a benchmark but I think it's equivalent.
*
*
* Key feature : of course this logger MUST implement the same interface (or abstract)
* like the other loggers.
*/
Expand Down
2 changes: 1 addition & 1 deletion Behavioral/Observer/User.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

/**
* Observer pattern : The observed object (the subject)
*
*
* The subject maintains a list of Observers and sends notifications.
*
*/
Expand Down
2 changes: 1 addition & 1 deletion Behavioral/Observer/UserObserver.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ class UserObserver implements \SplObserver
/**
* This is the only method to implement as an observer.
* It is called by the Subject (usually by SplSubject::notify() )
*
*
* @param \SplSubject $subject
*/
public function update(\SplSubject $subject)
Expand Down
6 changes: 3 additions & 3 deletions Behavioral/Specification/Either.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ class Either extends AbstractSpecification

/**
* A composite wrapper of two specifications
*
*
* @param SpecificationInterface $left
* @param SpecificationInterface $right
*/
Expand All @@ -24,9 +24,9 @@ public function __construct(SpecificationInterface $left, SpecificationInterface

/**
* Returns the evaluation of both wrapped specifications as a logical OR
*
*
* @param Item $item
*
*
* @return bool
*/
public function isSatisfiedBy(Item $item)
Expand Down
4 changes: 2 additions & 2 deletions Behavioral/Specification/Item.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ class Item

/**
* An item must have a price
*
*
* @param int $price
*/
public function __construct($price)
Expand All @@ -20,7 +20,7 @@ public function __construct($price)

/**
* Get the items price
*
*
* @return int
*/
public function getPrice()
Expand Down
6 changes: 3 additions & 3 deletions Behavioral/Specification/Not.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ class Not extends AbstractSpecification

/**
* Creates a new specification wrapping another
*
*
* @param SpecificationInterface $spec
*/
public function __construct(SpecificationInterface $spec)
Expand All @@ -21,9 +21,9 @@ public function __construct(SpecificationInterface $spec)

/**
* Returns the negated result of the wrapped specification
*
*
* @param Item $item
*
*
* @return bool
*/
public function isSatisfiedBy(Item $item)
Expand Down
2 changes: 1 addition & 1 deletion Behavioral/TemplateMethod/Journey.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ abstract class Journey
/**
* This is the public service provided by this class and its subclasses.
* Notice it is final to "freeze" the global behavior of algorithm.
* If you want to override this contract, make an interface with only takeATrip()
* If you want to override this contract, make an interface with only takeATrip()
* and subclass it.
*/
final public function takeATrip()
Expand Down
8 changes: 4 additions & 4 deletions Behavioral/Visitor/RoleVisitorInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,25 +6,25 @@
* Visitor Pattern
*
* The contract for the visitor.
*
*
* Note 1 : in C++ or java, with method polymorphism based on type-hint, there are many
* methods visit() with different type for the 'role' parameter.
*
*
* Note 2 : the visitor must not choose itself which method to
* invoke, it is the Visitee that make this decision.
*/
interface RoleVisitorInterface
{
/**
* Visit a User object
*
*
* @param \DesignPatterns\Behavioral\Visitor\User $role
*/
public function visitUser(User $role);

/**
* Visit a Group object
*
*
* @param \DesignPatterns\Behavioral\Visitor\Group $role
*/
public function visitGroup(Group $role);
Expand Down
4 changes: 2 additions & 2 deletions Creational/AbstractFactory/AbstractFactory.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ abstract class AbstractFactory
{
/**
* Creates a text component
*
*
* @param string $content
*
* @return Text
Expand All @@ -30,7 +30,7 @@ abstract public function createText($content);

/**
* Creates a picture component
*
*
* @param string $path
* @param string $name
*
Expand Down
4 changes: 2 additions & 2 deletions Creational/AbstractFactory/Tests/AbstractFactoryTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,9 @@ public function getFactories()

/**
* This is the client of factories. Note that the client does not
* care which factory is given to him, he can create any component he
* care which factory is given to him, he can create any component he
* wants and render how he wants.
*
*
* @dataProvider getFactories
*/
public function testComponentCreation(AbstractFactory $factory)
Expand Down
1 change: 0 additions & 1 deletion Creational/Builder/BikeBuilder.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ class BikeBuilder implements BuilderInterface
*/
public function addDoors()
{

}

/**
Expand Down
4 changes: 2 additions & 2 deletions Creational/Builder/Director.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@

/**
* Director is part of the builder pattern. It knows the interface of the builder
* and builds a complex object with the help of the builder.
*
* and builds a complex object with the help of the builder.
*
* You can also inject many builders instead of one to build more complex objects
*/
class Director
Expand Down
1 change: 0 additions & 1 deletion Creational/Builder/Parts/Bike.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,4 @@
*/
class Bike extends Vehicle
{

}
1 change: 0 additions & 1 deletion Creational/Builder/Parts/Car.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,4 @@
*/
class Car extends Vehicle
{

}
1 change: 0 additions & 1 deletion Creational/Builder/Parts/Door.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,4 @@
*/
class Door
{

}
1 change: 0 additions & 1 deletion Creational/Builder/Parts/Engine.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,4 @@
*/
class Engine
{

}
1 change: 0 additions & 1 deletion Creational/Builder/Parts/Wheel.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,4 @@
*/
class Wheel
{

}
2 changes: 1 addition & 1 deletion Creational/Builder/Tests/DirectorTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ public function getBuilder()
/**
* Here we test the build process. Notice that the client don't know
* anything about the concrete builder.
*
*
* @dataProvider getBuilder
*/
public function testBuild(BuilderInterface $builder)
Expand Down
10 changes: 5 additions & 5 deletions Creational/FactoryMethod/FactoryMethod.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,20 +13,20 @@ abstract class FactoryMethod

/**
* The children of the class must implement this method
*
*
* Sometimes this method can be public to get "raw" object
*
*
* @param string $type a generic type
*
*
* @return VehicleInterface a new vehicle
*/
abstract protected function createVehicle($type);

/**
* Creates a new vehicle
*
*
* @param int $type
*
*
* @return VehicleInterface a new vehicle
*/
public function create($type)
Expand Down
1 change: 0 additions & 1 deletion Creational/FactoryMethod/Porsche.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,5 @@ public function setColor($rgb)
*/
public function addTuningAMG()
{

}
}
5 changes: 1 addition & 4 deletions Creational/Multiton/Multiton.php
Original file line number Diff line number Diff line change
Expand Up @@ -32,13 +32,12 @@ class Multiton
*/
private function __construct()
{

}

/**
* gets the instance with the given name, e.g. Multiton::INSTANCE_1
* uses lazy initialization
*
*
* @param string $instanceName
*
* @return Multiton
Expand All @@ -59,7 +58,6 @@ public static function getInstance($instanceName)
*/
private function __clone()
{

}

/**
Expand All @@ -69,6 +67,5 @@ private function __clone()
*/
private function __wakeup()
{

}
}
2 changes: 1 addition & 1 deletion Creational/Pool/Tests/TestWorker.php
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<?php
<?php

namespace DesignPatterns\Creational\Pool\Tests;

Expand Down
1 change: 0 additions & 1 deletion Creational/Prototype/BarBookPrototype.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,5 @@ class BarBookPrototype extends BookPrototype
*/
public function __clone()
{

}
}
1 change: 0 additions & 1 deletion Creational/Prototype/FooBookPrototype.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,5 @@ class FooBookPrototype extends BookPrototype
*/
public function __clone()
{

}
}
1 change: 0 additions & 1 deletion Creational/SimpleFactory/Bicycle.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,5 @@ class Bicycle implements VehicleInterface
*/
public function driveTo($destination)
{

}
}
2 changes: 1 addition & 1 deletion Creational/SimpleFactory/ConcreteFactory.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ public function __construct()

/**
* Creates a vehicle
*
*
* @param string $type a known type key
*
* @return VehicleInterface a new instance of VehicleInterface
Expand Down
1 change: 0 additions & 1 deletion Creational/SimpleFactory/Scooter.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,5 @@ class Scooter implements VehicleInterface
*/
public function driveTo($destination)
{

}
}
4 changes: 0 additions & 4 deletions Creational/Singleton/Singleton.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ class Singleton
*/
public static function getInstance()
{

if (null === static::$instance) {
static::$instance = new static;
}
Expand All @@ -33,7 +32,6 @@ public static function getInstance()
*/
private function __construct()
{

}

/**
Expand All @@ -43,7 +41,6 @@ private function __construct()
*/
private function __clone()
{

}

/**
Expand All @@ -53,6 +50,5 @@ private function __clone()
*/
private function __wakeup()
{

}
}
1 change: 0 additions & 1 deletion Creational/StaticFactory/FormatNumber.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,4 @@
*/
class FormatNumber implements FormatterInterface
{

}
1 change: 0 additions & 1 deletion Creational/StaticFactory/FormatString.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,4 @@
*/
class FormatString implements FormatterInterface
{

}
1 change: 0 additions & 1 deletion Creational/StaticFactory/FormatterInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,4 @@
*/
interface FormatterInterface
{

}
4 changes: 2 additions & 2 deletions More/Repository/PostRepository.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@
/**
* Repository for class Post
* This class is between Entity layer(class Post) and access object layer(interface Storage)
*
*
* Repository encapsulates the set of objects persisted in a data store and the operations performed over them
* providing a more object-oriented view of the persistence layer
*
*
* Repository also supports the objective of achieving a clean separation and one-way dependency
* between the domain and data mapping layers
*
Expand Down
Loading