class.php 1.54 KB
Newer Older
1 2
<?php

3 4 5
use yii\apidoc\models\ClassDoc;
use yii\apidoc\models\InterfaceDoc;
use yii\apidoc\models\TraitDoc;
6 7 8 9 10 11 12 13 14 15 16 17
/**
 * @var ClassDoc|InterfaceDoc|TraitDoc $item
 * @var yii\web\View $this
 */

?>
<h1><?php
	if ($item instanceof InterfaceDoc) {
		echo 'Interface ';
	} elseif ($item instanceof TraitDoc) {
		echo 'Trait ';
	} else {
18 19 20 21 22 23
		if ($item->isFinal) {
			echo 'Final ';
		}
		if ($item->isAbstract) {
			echo 'Abstract ';
		}
24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55
		echo 'Class ';
	}
	echo $item->name;
?></h1>
<div id="nav">
<a href="index.html">All Classes</a>
<?php if(!($item instanceof InterfaceDoc) && !empty($item->properties)): ?>
| <a href="#properties">Properties</a>
<?php endif; ?>
<?php if(!empty($item->methods)): ?>
| <a href="#methods">Methods</a>
<?php endif; ?>
<?php if($item instanceof ClassDoc && !empty($item->events)): ?>
| <a href="#events">Events</a>
<?php endif; ?>
</div>

<?= $this->render('classSummary', ['item' => $item]); ?>

<a name="properties"></a>
<?php //$this->renderPartial('propertySummary',array('class'=>$item,'protected'=>false)); ?>
<?php //$this->renderPartial('propertySummary',array('class'=>$item,'protected'=>true)); ?>

<a name="methods"></a>
<?php //$this->renderPartial('methodSummary',array('class'=>$item,'protected'=>false)); ?>
<?php //$this->renderPartial('methodSummary',array('class'=>$item,'protected'=>true)); ?>

<a name="events"></a>
<?php //$this->renderPartial('eventSummary',array('class'=>$item)); ?>

<?php //$this->renderPartial('propertyDetails',array('class'=>$item)); ?>
<?php //$this->renderPartial('methodDetails',array('class'=>$item)); ?>