1 | <?php |
||
26 | class ConeMethods |
||
27 | { |
||
28 | |||
29 | /** |
||
30 | * The cone primitive under the hood is a cylinder primitive with varying top and bottom radiuses. |
||
31 | */ |
||
32 | const DEFAULTS = array( |
||
33 | /* Height of the cone. */ |
||
34 | 'height' => 2, |
||
35 | /* Whether the ends of the cone are open (true) or capped ('false'). */ |
||
36 | 'openEnded' => 'false', |
||
37 | /* Radius of the bottom end of the cone. */ |
||
38 | 'radiusBottom' => 1, |
||
39 | /* Radius of the top end of the cone. */ |
||
40 | 'radiusTop' => 1, |
||
41 | /* Number of segmented faces around the circumference of the cone. */ |
||
42 | 'segmentsRadial' => 36, |
||
43 | /* Number of rows of faces along the height of the cone. */ |
||
44 | 'segmentsHeight' => 18, |
||
45 | /* Starting angle in degrees. */ |
||
46 | 'thetaStart' => 0, |
||
47 | /* Central angle in degrees. */ |
||
48 | 'thetaLength' => 360 |
||
49 | ); |
||
50 | |||
51 | /** |
||
52 | * Height of the cone. |
||
53 | * |
||
54 | * @param &array $dom_attributes |
||
|
|||
55 | * @param float|int $height |
||
56 | * @return void |
||
57 | */ |
||
58 | 1 | public function height(array &$dom_attributes, float $height) |
|
62 | |||
63 | /** |
||
64 | * Whether the ends of the cone are open (true) or capped (false). |
||
65 | * |
||
66 | * @param &array $dom_attributes |
||
67 | * @param bool|false $openEnded |
||
68 | * @return void |
||
69 | */ |
||
70 | 1 | public function openEnded(array &$dom_attributes, bool $openEnded = false) |
|
75 | |||
76 | /** |
||
77 | * Radius of the bottom end of the cone. |
||
78 | * |
||
79 | * @param &array $dom_attributes |
||
80 | * @param float|int $radiusBottom |
||
81 | * @return void |
||
82 | */ |
||
83 | 1 | public function radiusBottom(array &$dom_attributes, float $radiusBottom) |
|
87 | |||
88 | /** |
||
89 | * Radius of the top end of the cone. |
||
90 | * |
||
91 | * @param &array $dom_attributes |
||
92 | * @param float|int $radiusBottom |
||
93 | * @return void |
||
94 | */ |
||
95 | 1 | public function radiusTop(array &$dom_attributes, float $radiusTop) |
|
99 | |||
100 | /** |
||
101 | * Number of segmented faces around the circumference of the cone. |
||
102 | * |
||
103 | * @param &array $dom_attributes |
||
104 | * @param int $segmentsRadial |
||
105 | * @return void |
||
106 | */ |
||
107 | 1 | public function segmentsRadial(array &$dom_attributes, int $segmentsRadial) |
|
111 | |||
112 | /** |
||
113 | * Number of rows of faces along the height of the cone. |
||
114 | * |
||
115 | * @param &array $dom_attributes |
||
116 | * @param int $segmentsHeight |
||
117 | * @return void |
||
118 | */ |
||
119 | 1 | public function segmentsHeight(array &$dom_attributes, int $segmentsHeight) |
|
123 | |||
124 | /** |
||
125 | * Starting angle in degrees. |
||
126 | * |
||
127 | * @param &array $dom_attributes |
||
128 | * @param float|int $thetaStart |
||
129 | * @return void |
||
130 | */ |
||
131 | 1 | public function thetaStart(array &$dom_attributes, float $thetaStart) |
|
135 | |||
136 | /** |
||
137 | * Central angle in degrees. |
||
138 | * |
||
139 | * @param &array $dom_attributes |
||
140 | * @param float|int $thetaLength |
||
141 | * @return void |
||
142 | */ |
||
143 | 1 | public function thetaLength(array &$dom_attributes, float $thetaLength) |
|
147 | } |
||
148 |
This check marks PHPDoc comments that could not be parsed by our parser. To see which comment annotations we can parse, please refer to our documentation on supported doc-types.