| 1 | <?php |
||
| 7 | class Fighter extends Model |
||
| 8 | { |
||
| 9 | /** |
||
| 10 | * Get the Competitor's Championship. |
||
| 11 | * |
||
| 12 | * @return \Illuminate\Database\Eloquent\Relations\BelongsTo |
||
| 13 | */ |
||
| 14 | function championship() |
||
| 18 | |||
| 19 | /** |
||
| 20 | * @return \Illuminate\Database\Eloquent\Relations\HasManyThrough |
||
| 21 | */ |
||
| 22 | function category() |
||
| 26 | |||
| 27 | /** |
||
| 28 | * @return Competitor|Team |
||
| 29 | */ |
||
| 30 | function fighter() |
||
| 38 | } |
||
| 39 |
Adding explicit visibility (
private,protected, orpublic) is generally recommend to communicate to other developers how, and from where this method is intended to be used.