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