Skip to content

Commit

Permalink
Class is final -> all protected methods could be private
Browse files Browse the repository at this point in the history
  • Loading branch information
mabar committed Sep 17, 2018
1 parent 162b95c commit dc1a532
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion src/Schema/Serialization/ArrayHydrator.php
Expand Up @@ -33,7 +33,7 @@ public function hydrate($data): Schema
/**
* @param mixed[] $data
*/
protected function hydrateEndpoint(array $data): Endpoint
private function hydrateEndpoint(array $data): Endpoint
{
if (!isset($data['handler'])) {
throw new InvalidStateException("Schema route 'handler' is required");
Expand Down
12 changes: 6 additions & 6 deletions src/Schema/Serialization/ArraySerializator.php
Expand Up @@ -42,7 +42,7 @@ public function serialize(SchemaBuilder $builder): array
/**
* @return mixed[]
*/
protected function serializeEndpoint(Controller $controller, Method $method): array
private function serializeEndpoint(Controller $controller, Method $method): array
{
$endpoint = $this->serializeInit($controller, $method);
$this->serializeNegotiations($endpoint, $method);
Expand All @@ -55,7 +55,7 @@ protected function serializeEndpoint(Controller $controller, Method $method): ar
/**
* @return mixed[]
*/
protected function serializeInit(Controller $controller, Method $method): array
private function serializeInit(Controller $controller, Method $method): array
{
// Build full mask (@GroupPath(s) + @ControllerPath + @Path)
// without duplicated slashes (//)
Expand Down Expand Up @@ -106,7 +106,7 @@ protected function serializeInit(Controller $controller, Method $method): array
/**
* @param mixed[] $endpoint
*/
protected function serializePattern(array &$endpoint, Controller $controller, Method $method): void
private function serializePattern(array &$endpoint, Controller $controller, Method $method): void
{
$mask = $endpoint['mask'];
$maskParameters = [];
Expand Down Expand Up @@ -174,7 +174,7 @@ protected function serializePattern(array &$endpoint, Controller $controller, Me
/**
* @param mixed[] $endpoint
*/
protected function serializeNegotiations(array &$endpoint, Method $method): void
private function serializeNegotiations(array &$endpoint, Method $method): void
{
// Add negotiations
foreach ($method->getNegotiations() as $negotiation) {
Expand All @@ -189,7 +189,7 @@ protected function serializeNegotiations(array &$endpoint, Method $method): void
/**
* @param mixed[] $endpoint
*/
protected function serializeMappers(array &$endpoint, Method $method): void
private function serializeMappers(array &$endpoint, Method $method): void
{
// Add request & response mappers
if ($method->getRequestMapper()) {
Expand All @@ -209,7 +209,7 @@ protected function serializeMappers(array &$endpoint, Method $method): void
* @param mixed[] $endpoint
* @param mixed[] $parameter
*/
protected function serializeEndpointParameter(array &$endpoint, array $parameter, Method $method): void
private function serializeEndpointParameter(array &$endpoint, array $parameter, Method $method): void
{
// Build parameters
$p = [
Expand Down

0 comments on commit dc1a532

Please sign in to comment.