Commit 53b3198d by Carsten Brandt

add exceptions to method docs

parent 55f9111f
...@@ -32,7 +32,7 @@ if (empty($methods)) { ...@@ -32,7 +32,7 @@ if (empty($methods)) {
<?= $this->context->renderMethodSignature($method) ?> <?= $this->context->renderMethodSignature($method) ?>
</div> </div>
</td></tr> </td></tr>
<?php if(!empty($method->params) || !empty($method->return)): ?> <?php if(!empty($method->params) || !empty($method->return) || !empty($method->exceptions)): ?>
<?php foreach($method->params as $param): ?> <?php foreach($method->params as $param): ?>
<tr> <tr>
<td class="paramNameCol"><?= $param->name ?></td> <td class="paramNameCol"><?= $param->name ?></td>
...@@ -42,11 +42,18 @@ if (empty($methods)) { ...@@ -42,11 +42,18 @@ if (empty($methods)) {
<?php endforeach; ?> <?php endforeach; ?>
<?php if(!empty($method->return)): ?> <?php if(!empty($method->return)): ?>
<tr> <tr>
<td class="paramNameCol"><?= '{return}'; ?></td> <td class="paramNameCol"><?= 'return'; ?></td>
<td class="paramTypeCol"><?= $this->context->typeLink($method->returnTypes); ?></td> <td class="paramTypeCol"><?= $this->context->typeLink($method->returnTypes); ?></td>
<td class="paramDescCol"><?= Markdown::process($method->return, $type); ?></td> <td class="paramDescCol"><?= Markdown::process($method->return, $type); ?></td>
</tr> </tr>
<?php endif; ?> <?php endif; ?>
<?php foreach($method->exceptions as $exception => $description): ?>
<tr>
<td class="paramNameCol"><?= 'throws' ?></td>
<td class="paramTypeCol"><?= $this->context->typeLink($exception) ?></td>
<td class="paramDescCol"><?= Markdown::process($description, $type) ?></td>
</tr>
<?php endforeach; ?>
<?php endif; ?> <?php endif; ?>
</table> </table>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment