| @@ 75-79 (lines=5) @@ | ||
| 72 | } |
|
| 73 | } |
|
| 74 | ||
| 75 | if (null !== $itemOperations = $resourceMetadata->getItemOperations()) { |
|
| 76 | foreach ($itemOperations as $operationName => $operation) { |
|
| 77 | $annotations[] = $this->getApiDoc(false, $resourceClass, $resourceMetadata, $operationName, $resourceHydraDoc); |
|
| 78 | } |
|
| 79 | } |
|
| 80 | } |
|
| 81 | ||
| 82 | return $annotations; |
|
| @@ 73-77 (lines=5) @@ | ||
| 70 | throw new InvalidResourceException(sprintf('Resource %s has no short name defined.', $resourceClass)); |
|
| 71 | } |
|
| 72 | ||
| 73 | if (null !== $collectionOperations = $resourceMetadata->getCollectionOperations()) { |
|
| 74 | foreach ($collectionOperations as $operationName => $operation) { |
|
| 75 | $this->addRoute($routeCollection, $resourceClass, $operationName, $operation, $resourceShortName, true); |
|
| 76 | } |
|
| 77 | } |
|
| 78 | ||
| 79 | if (null !== $itemOperations = $resourceMetadata->getItemOperations()) { |
|
| 80 | foreach ($itemOperations as $operationName => $operation) { |
|
| @@ 79-83 (lines=5) @@ | ||
| 76 | } |
|
| 77 | } |
|
| 78 | ||
| 79 | if (null !== $itemOperations = $resourceMetadata->getItemOperations()) { |
|
| 80 | foreach ($itemOperations as $operationName => $operation) { |
|
| 81 | $this->addRoute($routeCollection, $resourceClass, $operationName, $operation, $resourceShortName, false); |
|
| 82 | } |
|
| 83 | } |
|
| 84 | } |
|
| 85 | ||
| 86 | return $routeCollection; |
|