Issues (1377)

Security Analysis    no request data  

This project does not seem to handle request data directly as such no vulnerable execution paths were found.

  Cross-Site Scripting
Cross-Site Scripting enables an attacker to inject code into the response of a web-request that is viewed by other users. It can for example be used to bypass access controls, or even to take over other users' accounts.
  File Exposure
File Exposure allows an attacker to gain access to local files that he should not be able to access. These files can for example include database credentials, or other configuration files.
  File Manipulation
File Manipulation enables an attacker to write custom data to files. This potentially leads to injection of arbitrary code on the server.
  Object Injection
Object Injection enables an attacker to inject an object into PHP code, and can lead to arbitrary code execution, file exposure, or file manipulation attacks.
  Code Injection
Code Injection enables an attacker to execute arbitrary code on the server.
  Response Splitting
Response Splitting can be used to send arbitrary responses.
  File Inclusion
File Inclusion enables an attacker to inject custom files into PHP's file loading mechanism, either explicitly passed to include, or for example via PHP's auto-loading mechanism.
  Command Injection
Command Injection enables an attacker to inject a shell command that is execute with the privileges of the web-server. This can be used to expose sensitive data, or gain access of your server.
  SQL Injection
SQL Injection enables an attacker to execute arbitrary SQL code on your database server gaining access to user data, or manipulating user data.
  XPath Injection
XPath Injection enables an attacker to modify the parts of XML document that are read. If that XML document is for example used for authentication, this can lead to further vulnerabilities similar to SQL Injection.
  LDAP Injection
LDAP Injection enables an attacker to inject LDAP statements potentially granting permission to run unauthorized queries, or modify content inside the LDAP tree.
  Header Injection
  Other Vulnerability
This category comprises other attack vectors such as manipulating the PHP runtime, loading custom extensions, freezing the runtime, or similar.
  Regex Injection
Regex Injection enables an attacker to execute arbitrary code in your PHP process.
  XML Injection
XML Injection enables an attacker to read files on your local filesystem including configuration files, or can be abused to freeze your web-server process.
  Variable Injection
Variable Injection enables an attacker to overwrite program variables with custom data, and can lead to further vulnerabilities.
Unfortunately, the security analysis is currently not available for your project. If you are a non-commercial open-source project, please contact support to gain access.

API/Chart/Series/HighchartsTreemap.php (10 issues)

Upgrade to new PHP Analysis Engine

These results are based on our legacy PHP analysis, consider migrating to our new PHP analysis engine instead. Learn more

1
<?php
2
3
/**
4
 * This file is part of the highcharts-bundle package.
5
 *
6
 * (c) 2017 WEBEWEB
7
 *
8
 * For the full copyright and license information, please view the LICENSE
9
 * file that was distributed with this source code.
10
 */
11
12
namespace WBW\Bundle\HighchartsBundle\API\Chart\Series;
13
14
use JsonSerializable;
15
use WBW\Library\Core\Utility\Argument\ArrayUtility;
16
17
/**
18
 * Highcharts treemap.
19
 *
20
 * @author webeweb <https://github.com/webeweb/>
21
 * @package WBW\Bundle\HighchartsBundle\API\Chart\Series
22
 * @version 5.0.14
23
 * @final
24
 */
25
final class HighchartsTreemap implements JsonSerializable {
26
27
    /**
28
     * Allow drill to node.
29
     *
30
     * @var boolean
31
     * @since 4.1.0
32
     */
33
    private $allowDrillToNode = false;
34
35
    /**
36
     * Allow point select.
37
     *
38
     * @var boolean
39
     * @since 1.2.0
40
     */
41
    private $allowPointSelect = false;
42
43
    /**
44
     * Alternate starting direction.
45
     *
46
     * @var boolean
47
     * @since 4.1.0
48
     */
49
    private $alternateStartingDirection = false;
50
51
    /**
52
     * Animation.
53
     *
54
     * @var boolean
55
     */
56
    private $animation = true;
57
58
    /**
59
     * Animation limit.
60
     *
61
     * @var integer
62
     */
63
    private $animationLimit;
64
65
    /**
66
     * Border color.
67
     *
68
     * @var string
69
     */
70
    private $borderColor = "#e6e6e6";
71
72
    /**
73
     * Border width.
74
     *
75
     * @var integer
76
     */
77
    private $borderWidth = 1;
78
79
    /**
80
     * Class name.
81
     *
82
     * @var string
83
     * @since 5.0.0
84
     */
85
    private $className;
86
87
    /**
88
     * Color.
89
     *
90
     * @var string
91
     * @since 4.0
92
     */
93
    private $color;
94
95
    /**
96
     * Color by point.
97
     *
98
     * @var boolean
99
     * @since 2.0
100
     */
101
    private $colorByPoint = false;
102
103
    /**
104
     * Color index.
105
     *
106
     * @var integer
107
     * @since 5.0.0
108
     */
109
    private $colorIndex;
110
111
    /**
112
     * Colors.
113
     *
114
     * @var array
115
     * @since 3.0
116
     */
117
    private $colors;
118
119
    /**
120
     * Crisp.
121
     *
122
     * @var boolean
123
     * @since 5.0.10
124
     */
125
    private $crisp = true;
126
127
    /**
128
     * Crop threshold.
129
     *
130
     * @var integer
131
     * @since 4.1.0
132
     */
133
    private $cropThreshold = 300;
134
135
    /**
136
     * Cursor.
137
     *
138
     * @var string
139
     */
140
    private $cursor;
141
142
    /**
143
     * Data.
144
     *
145
     * @var array
146
     */
147
    private $data;
148
149
    /**
150
     * Data labels.
151
     *
152
     * @var \WBW\Bundle\HighchartsBundle\API\Chart\Series\Treemap\HighchartsDataLabels
153
     * @since 4.1.0
154
     */
155
    private $dataLabels;
156
157
    /**
158
     * Description.
159
     *
160
     * @var string
161
     * @since 5.0.0
162
     */
163
    private $description;
164
165
    /**
166
     * Enable mouse tracking.
167
     *
168
     * @var boolean
169
     */
170
    private $enableMouseTracking = true;
171
172
    /**
173
     * Events.
174
     *
175
     * @var \WBW\Bundle\HighchartsBundle\API\Chart\Series\Treemap\HighchartsEvents
176
     */
177
    private $events;
178
179
    /**
180
     * Expose element to a11y.
181
     *
182
     * @var boolean
183
     * @since 5.0.12
184
     */
185
    private $exposeElementToA11y;
186
187
    /**
188
     * Find nearest point by.
189
     *
190
     * @var string
191
     * @since 5.0.10
192
     */
193
    private $findNearestPointBy;
194
195
    /**
196
     * Get extremes from all.
197
     *
198
     * @var boolean
199
     * @since 4.1.6
200
     */
201
    private $getExtremesFromAll = false;
202
203
    /**
204
     * Id.
205
     *
206
     * @var string
207
     * @since 1.2.0
208
     */
209
    private $id;
210
211
    /**
212
     * Ignore hidden point.
213
     *
214
     * @var boolean
215
     * @since 5.0.8
216
     */
217
    private $ignoreHiddenPoint = true;
218
219
    /**
220
     * Index.
221
     *
222
     * @var integer
223
     * @since 2.3.0
224
     */
225
    private $index;
226
227
    /**
228
     * Interact by leaf.
229
     *
230
     * @var boolean
231
     * @since 4.1.2
232
     */
233
    private $interactByLeaf;
234
235
    /**
236
     * Keys.
237
     *
238
     * @var array
239
     * @since 4.1.6
240
     */
241
    private $keys;
242
243
    /**
244
     * Layout algorithm.
245
     *
246
     * @var string
247
     * @since 4.1.0
248
     */
249
    private $layoutAlgorithm = "sliceAndDice";
250
251
    /**
252
     * Layout starting direction.
253
     *
254
     * @var string
255
     * @since 4.1.0
256
     */
257
    private $layoutStartingDirection = "vertical";
258
259
    /**
260
     * Legend index.
261
     *
262
     * @var integer
263
     */
264
    private $legendIndex;
265
266
    /**
267
     * Level is constant.
268
     *
269
     * @var boolean
270
     * @since 4.1.0
271
     */
272
    private $levelIsConstant = true;
273
274
    /**
275
     * Levels.
276
     *
277
     * @var array
278
     * @since 4.1.0
279
     */
280
    private $levels;
281
282
    /**
283
     * Linked to.
284
     *
285
     * @var string
286
     * @since 3.0
287
     */
288
    private $linkedTo;
289
290
    /**
291
     * Max point width.
292
     *
293
     * @var integer
294
     * @since 4.1.8
295
     */
296
    private $maxPointWidth;
297
298
    /**
299
     * Name.
300
     *
301
     * @var string
302
     */
303
    private $name;
304
305
    /**
306
     * Opacity.
307
     *
308
     * @var integer
309
     * @since 4.2.4
310
     */
311
    private $opacity = 0.15;
312
313
    /**
314
     * Point.
315
     *
316
     * @var \WBW\Bundle\HighchartsBundle\API\Chart\Series\Treemap\HighchartsPoint
317
     */
318
    private $point;
319
320
    /**
321
     * Point description formatter.
322
     *
323
     * @var string
324
     * @since 5.0.12
325
     */
326
    private $pointDescriptionFormatter;
327
328
    /**
329
     * Selected.
330
     *
331
     * @var boolean
332
     * @since 1.2.0
333
     */
334
    private $selected = false;
335
336
    /**
337
     * Shadow.
338
     *
339
     * @var boolean|array
340
     */
341
    private $shadow = false;
342
343
    /**
344
     * Show checkbox.
345
     *
346
     * @var boolean
347
     * @since 1.2.0
348
     */
349
    private $showCheckbox = false;
350
351
    /**
352
     * Show in legend.
353
     *
354
     * @var boolean
355
     */
356
    private $showInLegend = false;
357
358
    /**
359
     * Skip keyboard navigation.
360
     *
361
     * @var boolean
362
     * @since 5.0.12
363
     */
364
    private $skipKeyboardNavigation;
365
366
    /**
367
     * Sort index.
368
     *
369
     * @var integer
370
     * @since 4.1.10
371
     */
372
    private $sortIndex;
373
374
    /**
375
     * States.
376
     *
377
     * @var \WBW\Bundle\HighchartsBundle\API\Chart\Series\Treemap\HighchartsStates
378
     */
379
    private $states;
380
381
    /**
382
     * Sticky tracking.
383
     *
384
     * @var boolean
385
     * @since 2.0
386
     */
387
    private $stickyTracking = true;
388
389
    /**
390
     * Tooltip.
391
     *
392
     * @var \WBW\Bundle\HighchartsBundle\API\Chart\Series\Treemap\HighchartsTooltip
393
     * @since 4.1.0
394
     */
395
    private $tooltip;
396
397
    /**
398
     * Turbo threshold.
399
     *
400
     * @var integer
401
     * @since 2.2
402
     */
403
    private $turboThreshold = 1000;
404
405
    /**
406
     * Type.
407
     *
408
     * @var string
409
     */
410
    private $type;
411
412
    /**
413
     * Visible.
414
     *
415
     * @var boolean
416
     */
417
    private $visible = true;
418
419
    /**
420
     * X axis.
421
     *
422
     * @var integer|string
423
     */
424
    private $xAxis = "0";
425
426
    /**
427
     * Y axis.
428
     *
429
     * @var integer|string
430
     */
431
    private $yAxis = "0";
432
433
    /**
434
     * Z index.
435
     *
436
     * @var integer
437
     */
438
    private $zIndex;
439
440
    /**
441
     * Zone axis.
442
     *
443
     * @var string
444
     * @since 4.1.0
445
     */
446
    private $zoneAxis = "y";
447
448
    /**
449
     * Zones.
450
     *
451
     * @var array
452
     * @since 4.1.0
453
     */
454
    private $zones;
455
456
    /**
457
     * Constructor.
458
     *
459
     * @param boolean $ignoreDefaultValues Ignore the default values.
460
     */
461
    public function __construct($ignoreDefaultValues = true) {
462
        if (true === $ignoreDefaultValues) {
463
            $this->clear();
464
        }
465
    }
466
467
    /**
468
     * Clear.
469
     *
470
     * @return void
471
     */
472
    public function clear() {
473
474
        // Clear the allow drill to node.
475
        $this->allowDrillToNode = null;
476
477
        // Clear the allow point select.
478
        $this->allowPointSelect = null;
479
480
        // Clear the alternate starting direction.
481
        $this->alternateStartingDirection = null;
482
483
        // Clear the animation.
484
        $this->animation = null;
485
486
        // Clear the animation limit.
487
        $this->animationLimit = null;
488
489
        // Clear the border color.
490
        $this->borderColor = null;
491
492
        // Clear the border width.
493
        $this->borderWidth = null;
494
495
        // Clear the class name.
496
        $this->className = null;
497
498
        // Clear the color.
499
        $this->color = null;
500
501
        // Clear the color by point.
502
        $this->colorByPoint = null;
503
504
        // Clear the color index.
505
        $this->colorIndex = null;
506
507
        // Clear the colors.
508
        $this->colors = null;
0 ignored issues
show
Documentation Bug introduced by
It seems like null of type null is incompatible with the declared type array of property $colors.

Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.

Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..

Loading history...
509
510
        // Clear the crisp.
511
        $this->crisp = null;
512
513
        // Clear the crop threshold.
514
        $this->cropThreshold = null;
515
516
        // Clear the cursor.
517
        $this->cursor = null;
518
519
        // Clear the data.
520
        $this->data = null;
0 ignored issues
show
Documentation Bug introduced by
It seems like null of type null is incompatible with the declared type array of property $data.

Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.

Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..

Loading history...
521
522
        // Clear the data labels.
523
        if (null !== $this->dataLabels) {
524
            $this->dataLabels->clear();
525
        }
526
527
        // Clear the description.
528
        $this->description = null;
529
530
        // Clear the enable mouse tracking.
531
        $this->enableMouseTracking = null;
532
533
        // Clear the events.
534
        if (null !== $this->events) {
535
            $this->events->clear();
536
        }
537
538
        // Clear the expose element to a11y.
539
        $this->exposeElementToA11y = null;
540
541
        // Clear the find nearest point by.
542
        $this->findNearestPointBy = null;
543
544
        // Clear the get extremes from all.
545
        $this->getExtremesFromAll = null;
546
547
        // Clear the id.
548
        $this->id = null;
549
550
        // Clear the ignore hidden point.
551
        $this->ignoreHiddenPoint = null;
552
553
        // Clear the index.
554
        $this->index = null;
555
556
        // Clear the interact by leaf.
557
        $this->interactByLeaf = null;
558
559
        // Clear the keys.
560
        $this->keys = null;
0 ignored issues
show
Documentation Bug introduced by
It seems like null of type null is incompatible with the declared type array of property $keys.

Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.

Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..

Loading history...
561
562
        // Clear the layout algorithm.
563
        $this->layoutAlgorithm = null;
564
565
        // Clear the layout starting direction.
566
        $this->layoutStartingDirection = null;
567
568
        // Clear the legend index.
569
        $this->legendIndex = null;
570
571
        // Clear the level is constant.
572
        $this->levelIsConstant = null;
573
574
        // Clear the levels.
575
        $this->levels = null;
0 ignored issues
show
Documentation Bug introduced by
It seems like null of type null is incompatible with the declared type array of property $levels.

Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.

Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..

Loading history...
576
577
        // Clear the linked to.
578
        $this->linkedTo = null;
579
580
        // Clear the max point width.
581
        $this->maxPointWidth = null;
582
583
        // Clear the name.
584
        $this->name = null;
585
586
        // Clear the opacity.
587
        $this->opacity = null;
588
589
        // Clear the point.
590
        if (null !== $this->point) {
591
            $this->point->clear();
592
        }
593
594
        // Clear the point description formatter.
595
        $this->pointDescriptionFormatter = null;
596
597
        // Clear the selected.
598
        $this->selected = null;
599
600
        // Clear the shadow.
601
        $this->shadow = null;
602
603
        // Clear the show checkbox.
604
        $this->showCheckbox = null;
605
606
        // Clear the show in legend.
607
        $this->showInLegend = null;
608
609
        // Clear the skip keyboard navigation.
610
        $this->skipKeyboardNavigation = null;
611
612
        // Clear the sort index.
613
        $this->sortIndex = null;
614
615
        // Clear the states.
616
        if (null !== $this->states) {
617
            $this->states->clear();
618
        }
619
620
        // Clear the sticky tracking.
621
        $this->stickyTracking = null;
622
623
        // Clear the tooltip.
624
        if (null !== $this->tooltip) {
625
            $this->tooltip->clear();
626
        }
627
628
        // Clear the turbo threshold.
629
        $this->turboThreshold = null;
630
631
        // Clear the type.
632
        $this->type = null;
633
634
        // Clear the visible.
635
        $this->visible = null;
636
637
        // Clear the x axis.
638
        $this->xAxis = null;
639
640
        // Clear the y axis.
641
        $this->yAxis = null;
642
643
        // Clear the z index.
644
        $this->zIndex = null;
645
646
        // Clear the zone axis.
647
        $this->zoneAxis = null;
648
649
        // Clear the zones.
650
        $this->zones = null;
0 ignored issues
show
Documentation Bug introduced by
It seems like null of type null is incompatible with the declared type array of property $zones.

Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.

Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..

Loading history...
651
    }
652
653
    /**
654
     * Get the allow drill to node.
655
     *
656
     * @return boolean Returns the allow drill to node.
657
     */
658
    public function getAllowDrillToNode() {
659
        return $this->allowDrillToNode;
660
    }
661
662
    /**
663
     * Get the allow point select.
664
     *
665
     * @return boolean Returns the allow point select.
666
     */
667
    public function getAllowPointSelect() {
668
        return $this->allowPointSelect;
669
    }
670
671
    /**
672
     * Get the alternate starting direction.
673
     *
674
     * @return boolean Returns the alternate starting direction.
675
     */
676
    public function getAlternateStartingDirection() {
677
        return $this->alternateStartingDirection;
678
    }
679
680
    /**
681
     * Get the animation.
682
     *
683
     * @return boolean Returns the animation.
684
     */
685
    public function getAnimation() {
686
        return $this->animation;
687
    }
688
689
    /**
690
     * Get the animation limit.
691
     *
692
     * @return integer Returns the animation limit.
693
     */
694
    public function getAnimationLimit() {
695
        return $this->animationLimit;
696
    }
697
698
    /**
699
     * Get the border color.
700
     *
701
     * @return string Returns the border color.
702
     */
703
    public function getBorderColor() {
704
        return $this->borderColor;
705
    }
706
707
    /**
708
     * Get the border width.
709
     *
710
     * @return integer Returns the border width.
711
     */
712
    public function getBorderWidth() {
713
        return $this->borderWidth;
714
    }
715
716
    /**
717
     * Get the class name.
718
     *
719
     * @return string Returns the class name.
720
     */
721
    public function getClassName() {
722
        return $this->className;
723
    }
724
725
    /**
726
     * Get the color.
727
     *
728
     * @return string Returns the color.
729
     */
730
    public function getColor() {
731
        return $this->color;
732
    }
733
734
    /**
735
     * Get the color by point.
736
     *
737
     * @return boolean Returns the color by point.
738
     */
739
    public function getColorByPoint() {
740
        return $this->colorByPoint;
741
    }
742
743
    /**
744
     * Get the color index.
745
     *
746
     * @return integer Returns the color index.
747
     */
748
    public function getColorIndex() {
749
        return $this->colorIndex;
750
    }
751
752
    /**
753
     * Get the colors.
754
     *
755
     * @return array Returns the colors.
756
     */
757
    public function getColors() {
758
        return $this->colors;
759
    }
760
761
    /**
762
     * Get the crisp.
763
     *
764
     * @return boolean Returns the crisp.
765
     */
766
    public function getCrisp() {
767
        return $this->crisp;
768
    }
769
770
    /**
771
     * Get the crop threshold.
772
     *
773
     * @return integer Returns the crop threshold.
774
     */
775
    public function getCropThreshold() {
776
        return $this->cropThreshold;
777
    }
778
779
    /**
780
     * Get the cursor.
781
     *
782
     * @return string Returns the cursor.
783
     */
784
    public function getCursor() {
785
        return $this->cursor;
786
    }
787
788
    /**
789
     * Get the data.
790
     *
791
     * @return array Returns the data.
792
     */
793
    public function getData() {
794
        return $this->data;
795
    }
796
797
    /**
798
     * Get the data labels.
799
     *
800
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\Treemap\HighchartsDataLabels Returns the data labels.
801
     */
802
    public function getDataLabels() {
803
        return $this->dataLabels;
804
    }
805
806
    /**
807
     * Get the description.
808
     *
809
     * @return string Returns the description.
810
     */
811
    public function getDescription() {
812
        return $this->description;
813
    }
814
815
    /**
816
     * Get the enable mouse tracking.
817
     *
818
     * @return boolean Returns the enable mouse tracking.
819
     */
820
    public function getEnableMouseTracking() {
821
        return $this->enableMouseTracking;
822
    }
823
824
    /**
825
     * Get the events.
826
     *
827
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\Treemap\HighchartsEvents Returns the events.
828
     */
829
    public function getEvents() {
830
        return $this->events;
831
    }
832
833
    /**
834
     * Get the expose element to a11y.
835
     *
836
     * @return boolean Returns the expose element to a11y.
837
     */
838
    public function getExposeElementToA11y() {
839
        return $this->exposeElementToA11y;
840
    }
841
842
    /**
843
     * Get the find nearest point by.
844
     *
845
     * @return string Returns the find nearest point by.
846
     */
847
    public function getFindNearestPointBy() {
848
        return $this->findNearestPointBy;
849
    }
850
851
    /**
852
     * Get the get extremes from all.
853
     *
854
     * @return boolean Returns the get extremes from all.
855
     */
856
    public function getGetExtremesFromAll() {
857
        return $this->getExtremesFromAll;
858
    }
859
860
    /**
861
     * Get the id.
862
     *
863
     * @return string Returns the id.
864
     */
865
    public function getId() {
866
        return $this->id;
867
    }
868
869
    /**
870
     * Get the ignore hidden point.
871
     *
872
     * @return boolean Returns the ignore hidden point.
873
     */
874
    public function getIgnoreHiddenPoint() {
875
        return $this->ignoreHiddenPoint;
876
    }
877
878
    /**
879
     * Get the index.
880
     *
881
     * @return integer Returns the index.
882
     */
883
    public function getIndex() {
884
        return $this->index;
885
    }
886
887
    /**
888
     * Get the interact by leaf.
889
     *
890
     * @return boolean Returns the interact by leaf.
891
     */
892
    public function getInteractByLeaf() {
893
        return $this->interactByLeaf;
894
    }
895
896
    /**
897
     * Get the keys.
898
     *
899
     * @return array Returns the keys.
900
     */
901
    public function getKeys() {
902
        return $this->keys;
903
    }
904
905
    /**
906
     * Get the layout algorithm.
907
     *
908
     * @return string Returns the layout algorithm.
909
     */
910
    public function getLayoutAlgorithm() {
911
        return $this->layoutAlgorithm;
912
    }
913
914
    /**
915
     * Get the layout starting direction.
916
     *
917
     * @return string Returns the layout starting direction.
918
     */
919
    public function getLayoutStartingDirection() {
920
        return $this->layoutStartingDirection;
921
    }
922
923
    /**
924
     * Get the legend index.
925
     *
926
     * @return integer Returns the legend index.
927
     */
928
    public function getLegendIndex() {
929
        return $this->legendIndex;
930
    }
931
932
    /**
933
     * Get the level is constant.
934
     *
935
     * @return boolean Returns the level is constant.
936
     */
937
    public function getLevelIsConstant() {
938
        return $this->levelIsConstant;
939
    }
940
941
    /**
942
     * Get the levels.
943
     *
944
     * @return array Returns the levels.
945
     */
946
    public function getLevels() {
947
        return $this->levels;
948
    }
949
950
    /**
951
     * Get the linked to.
952
     *
953
     * @return string Returns the linked to.
954
     */
955
    public function getLinkedTo() {
956
        return $this->linkedTo;
957
    }
958
959
    /**
960
     * Get the max point width.
961
     *
962
     * @return integer Returns the max point width.
963
     */
964
    public function getMaxPointWidth() {
965
        return $this->maxPointWidth;
966
    }
967
968
    /**
969
     * Get the name.
970
     *
971
     * @return string Returns the name.
972
     */
973
    public function getName() {
974
        return $this->name;
975
    }
976
977
    /**
978
     * Get the opacity.
979
     *
980
     * @return integer Returns the opacity.
981
     */
982
    public function getOpacity() {
983
        return $this->opacity;
984
    }
985
986
    /**
987
     * Get the point.
988
     *
989
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\Treemap\HighchartsPoint Returns the point.
990
     */
991
    public function getPoint() {
992
        return $this->point;
993
    }
994
995
    /**
996
     * Get the point description formatter.
997
     *
998
     * @return string Returns the point description formatter.
999
     */
1000
    public function getPointDescriptionFormatter() {
1001
        return $this->pointDescriptionFormatter;
1002
    }
1003
1004
    /**
1005
     * Get the selected.
1006
     *
1007
     * @return boolean Returns the selected.
1008
     */
1009
    public function getSelected() {
1010
        return $this->selected;
1011
    }
1012
1013
    /**
1014
     * Get the shadow.
1015
     *
1016
     * @return boolean|array Returns the shadow.
1017
     */
1018
    public function getShadow() {
1019
        return $this->shadow;
1020
    }
1021
1022
    /**
1023
     * Get the show checkbox.
1024
     *
1025
     * @return boolean Returns the show checkbox.
1026
     */
1027
    public function getShowCheckbox() {
1028
        return $this->showCheckbox;
1029
    }
1030
1031
    /**
1032
     * Get the show in legend.
1033
     *
1034
     * @return boolean Returns the show in legend.
1035
     */
1036
    public function getShowInLegend() {
1037
        return $this->showInLegend;
1038
    }
1039
1040
    /**
1041
     * Get the skip keyboard navigation.
1042
     *
1043
     * @return boolean Returns the skip keyboard navigation.
1044
     */
1045
    public function getSkipKeyboardNavigation() {
1046
        return $this->skipKeyboardNavigation;
1047
    }
1048
1049
    /**
1050
     * Get the sort index.
1051
     *
1052
     * @return integer Returns the sort index.
1053
     */
1054
    public function getSortIndex() {
1055
        return $this->sortIndex;
1056
    }
1057
1058
    /**
1059
     * Get the states.
1060
     *
1061
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\Treemap\HighchartsStates Returns the states.
1062
     */
1063
    public function getStates() {
1064
        return $this->states;
1065
    }
1066
1067
    /**
1068
     * Get the sticky tracking.
1069
     *
1070
     * @return boolean Returns the sticky tracking.
1071
     */
1072
    public function getStickyTracking() {
1073
        return $this->stickyTracking;
1074
    }
1075
1076
    /**
1077
     * Get the tooltip.
1078
     *
1079
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\Treemap\HighchartsTooltip Returns the tooltip.
1080
     */
1081
    public function getTooltip() {
1082
        return $this->tooltip;
1083
    }
1084
1085
    /**
1086
     * Get the turbo threshold.
1087
     *
1088
     * @return integer Returns the turbo threshold.
1089
     */
1090
    public function getTurboThreshold() {
1091
        return $this->turboThreshold;
1092
    }
1093
1094
    /**
1095
     * Get the type.
1096
     *
1097
     * @return string Returns the type.
1098
     */
1099
    public function getType() {
1100
        return $this->type;
1101
    }
1102
1103
    /**
1104
     * Get the visible.
1105
     *
1106
     * @return boolean Returns the visible.
1107
     */
1108
    public function getVisible() {
1109
        return $this->visible;
1110
    }
1111
1112
    /**
1113
     * Get the x axis.
1114
     *
1115
     * @return integer|string Returns the x axis.
1116
     */
1117
    public function getXAxis() {
1118
        return $this->xAxis;
1119
    }
1120
1121
    /**
1122
     * Get the y axis.
1123
     *
1124
     * @return integer|string Returns the y axis.
1125
     */
1126
    public function getYAxis() {
1127
        return $this->yAxis;
1128
    }
1129
1130
    /**
1131
     * Get the z index.
1132
     *
1133
     * @return integer Returns the z index.
1134
     */
1135
    public function getZIndex() {
1136
        return $this->zIndex;
1137
    }
1138
1139
    /**
1140
     * Get the zone axis.
1141
     *
1142
     * @return string Returns the zone axis.
1143
     */
1144
    public function getZoneAxis() {
1145
        return $this->zoneAxis;
1146
    }
1147
1148
    /**
1149
     * Get the zones.
1150
     *
1151
     * @return array Returns the zones.
1152
     */
1153
    public function getZones() {
1154
        return $this->zones;
1155
    }
1156
1157
    /**
1158
     * Serialize this instance.
1159
     *
1160
     * @return array Returns an array representing this instance.
1161
     */
1162
    public function jsonSerialize() {
1163
        return $this->toArray();
1164
    }
1165
1166
    /**
1167
     * Create a new data labels.
1168
     *
1169
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\Treemap\HighchartsDataLabels Returns the data labels.
1170
     */
1171
    public function newDataLabels() {
1172
        $this->dataLabels = new \WBW\Bundle\HighchartsBundle\API\Chart\Series\Treemap\HighchartsDataLabels();
1173
        return $this->dataLabels;
1174
    }
1175
1176
    /**
1177
     * Create a new events.
1178
     *
1179
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\Treemap\HighchartsEvents Returns the events.
1180
     */
1181
    public function newEvents() {
1182
        $this->events = new \WBW\Bundle\HighchartsBundle\API\Chart\Series\Treemap\HighchartsEvents();
1183
        return $this->events;
1184
    }
1185
1186
    /**
1187
     * Create a new point.
1188
     *
1189
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\Treemap\HighchartsPoint Returns the point.
1190
     */
1191
    public function newPoint() {
1192
        $this->point = new \WBW\Bundle\HighchartsBundle\API\Chart\Series\Treemap\HighchartsPoint();
1193
        return $this->point;
1194
    }
1195
1196
    /**
1197
     * Create a new states.
1198
     *
1199
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\Treemap\HighchartsStates Returns the states.
1200
     */
1201
    public function newStates() {
1202
        $this->states = new \WBW\Bundle\HighchartsBundle\API\Chart\Series\Treemap\HighchartsStates();
1203
        return $this->states;
1204
    }
1205
1206
    /**
1207
     * Create a new tooltip.
1208
     *
1209
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\Treemap\HighchartsTooltip Returns the tooltip.
1210
     */
1211
    public function newTooltip() {
1212
        $this->tooltip = new \WBW\Bundle\HighchartsBundle\API\Chart\Series\Treemap\HighchartsTooltip();
1213
        return $this->tooltip;
1214
    }
1215
1216
    /**
1217
     * Set the allow drill to node.
1218
     *
1219
     * @param boolean $allowDrillToNode The allow drill to node.
1220
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1221
     */
1222
    public function setAllowDrillToNode($allowDrillToNode) {
1223
        switch ($allowDrillToNode) {
1224
            case "false":
1225
            case "true":
1226
            $this->allowDrillToNode = $allowDrillToNode;
1227
            break;
1228
        }
1229
        return $this;
1230
    }
1231
1232
    /**
1233
     * Set the allow point select.
1234
     *
1235
     * @param boolean $allowPointSelect The allow point select.
1236
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1237
     */
1238
    public function setAllowPointSelect($allowPointSelect) {
1239
        $this->allowPointSelect = $allowPointSelect;
1240
        return $this;
1241
    }
1242
1243
    /**
1244
     * Set the alternate starting direction.
1245
     *
1246
     * @param boolean $alternateStartingDirection The alternate starting direction.
1247
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1248
     */
1249
    public function setAlternateStartingDirection($alternateStartingDirection) {
1250
        $this->alternateStartingDirection = $alternateStartingDirection;
1251
        return $this;
1252
    }
1253
1254
    /**
1255
     * Set the animation.
1256
     *
1257
     * @param boolean $animation The animation.
1258
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1259
     */
1260
    public function setAnimation($animation) {
1261
        $this->animation = $animation;
1262
        return $this;
1263
    }
1264
1265
    /**
1266
     * Set the animation limit.
1267
     *
1268
     * @param integer $animationLimit The animation limit.
1269
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1270
     */
1271
    public function setAnimationLimit($animationLimit) {
1272
        $this->animationLimit = $animationLimit;
1273
        return $this;
1274
    }
1275
1276
    /**
1277
     * Set the border color.
1278
     *
1279
     * @param string $borderColor The border color.
1280
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1281
     */
1282
    public function setBorderColor($borderColor) {
1283
        $this->borderColor = $borderColor;
1284
        return $this;
1285
    }
1286
1287
    /**
1288
     * Set the border width.
1289
     *
1290
     * @param integer $borderWidth The border width.
1291
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1292
     */
1293
    public function setBorderWidth($borderWidth) {
1294
        $this->borderWidth = $borderWidth;
1295
        return $this;
1296
    }
1297
1298
    /**
1299
     * Set the class name.
1300
     *
1301
     * @param string $className The class name.
1302
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1303
     */
1304
    public function setClassName($className) {
1305
        $this->className = $className;
1306
        return $this;
1307
    }
1308
1309
    /**
1310
     * Set the color.
1311
     *
1312
     * @param string $color The color.
1313
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1314
     */
1315
    public function setColor($color) {
1316
        $this->color = $color;
1317
        return $this;
1318
    }
1319
1320
    /**
1321
     * Set the color by point.
1322
     *
1323
     * @param boolean $colorByPoint The color by point.
1324
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1325
     */
1326
    public function setColorByPoint($colorByPoint) {
1327
        $this->colorByPoint = $colorByPoint;
1328
        return $this;
1329
    }
1330
1331
    /**
1332
     * Set the color index.
1333
     *
1334
     * @param integer $colorIndex The color index.
1335
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1336
     */
1337
    public function setColorIndex($colorIndex) {
1338
        $this->colorIndex = $colorIndex;
1339
        return $this;
1340
    }
1341
1342
    /**
1343
     * Set the colors.
1344
     *
1345
     * @param array $colors The colors.
1346
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1347
     */
1348
    public function setColors(array $colors = null) {
1349
        $this->colors = $colors;
0 ignored issues
show
Documentation Bug introduced by
It seems like $colors can be null. However, the property $colors is declared as array. Maybe change the type of the property to array|null or add a type check?

Our type inference engine has found an assignment of a scalar value (like a string, an integer or null) to a property which is an array.

Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property.

To type hint that a parameter can be either an array or null, you can set a type hint of array and a default value of null. The PHP interpreter will then accept both an array or null for that parameter.

function aContainsB(array $needle = null, array  $haystack) {
    if (!$needle) {
        return false;
    }

    return array_intersect($haystack, $needle) == $haystack;
}

The function can be called with either null or an array for the parameter $needle but will only accept an array as $haystack.

Loading history...
1350
        return $this;
1351
    }
1352
1353
    /**
1354
     * Set the crisp.
1355
     *
1356
     * @param boolean $crisp The crisp.
1357
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1358
     */
1359
    public function setCrisp($crisp) {
1360
        $this->crisp = $crisp;
1361
        return $this;
1362
    }
1363
1364
    /**
1365
     * Set the crop threshold.
1366
     *
1367
     * @param integer $cropThreshold The crop threshold.
1368
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1369
     */
1370
    public function setCropThreshold($cropThreshold) {
1371
        $this->cropThreshold = $cropThreshold;
1372
        return $this;
1373
    }
1374
1375
    /**
1376
     * Set the cursor.
1377
     *
1378
     * @param string $cursor The cursor.
1379
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1380
     */
1381
    public function setCursor($cursor) {
1382
        switch ($cursor) {
1383
            case null:
1384
            case "crosshair":
1385
            case "default":
1386
            case "help":
1387
            case "none":
1388
            case "pointer":
1389
            $this->cursor = $cursor;
1390
            break;
1391
        }
1392
        return $this;
1393
    }
1394
1395
    /**
1396
     * Set the data.
1397
     *
1398
     * @param array $data The data.
1399
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1400
     */
1401
    public function setData(array $data = null) {
1402
        $this->data = $data;
0 ignored issues
show
Documentation Bug introduced by
It seems like $data can be null. However, the property $data is declared as array. Maybe change the type of the property to array|null or add a type check?

Our type inference engine has found an assignment of a scalar value (like a string, an integer or null) to a property which is an array.

Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property.

To type hint that a parameter can be either an array or null, you can set a type hint of array and a default value of null. The PHP interpreter will then accept both an array or null for that parameter.

function aContainsB(array $needle = null, array  $haystack) {
    if (!$needle) {
        return false;
    }

    return array_intersect($haystack, $needle) == $haystack;
}

The function can be called with either null or an array for the parameter $needle but will only accept an array as $haystack.

Loading history...
1403
        return $this;
1404
    }
1405
1406
    /**
1407
     * Set the data labels.
1408
     *
1409
     * @param \WBW\Bundle\HighchartsBundle\API\Chart\Series\Treemap\HighchartsDataLabels $dataLabels The data labels.
1410
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1411
     */
1412
    public function setDataLabels(\WBW\Bundle\HighchartsBundle\API\Chart\Series\Treemap\HighchartsDataLabels $dataLabels = null) {
1413
        $this->dataLabels = $dataLabels;
1414
        return $this;
1415
    }
1416
1417
    /**
1418
     * Set the description.
1419
     *
1420
     * @param string $description The description.
1421
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1422
     */
1423
    public function setDescription($description) {
1424
        $this->description = $description;
1425
        return $this;
1426
    }
1427
1428
    /**
1429
     * Set the enable mouse tracking.
1430
     *
1431
     * @param boolean $enableMouseTracking The enable mouse tracking.
1432
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1433
     */
1434
    public function setEnableMouseTracking($enableMouseTracking) {
1435
        $this->enableMouseTracking = $enableMouseTracking;
1436
        return $this;
1437
    }
1438
1439
    /**
1440
     * Set the events.
1441
     *
1442
     * @param \WBW\Bundle\HighchartsBundle\API\Chart\Series\Treemap\HighchartsEvents $events The events.
1443
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1444
     */
1445
    public function setEvents(\WBW\Bundle\HighchartsBundle\API\Chart\Series\Treemap\HighchartsEvents $events = null) {
1446
        $this->events = $events;
1447
        return $this;
1448
    }
1449
1450
    /**
1451
     * Set the expose element to a11y.
1452
     *
1453
     * @param boolean $exposeElementToA11y The expose element to a11y.
1454
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1455
     */
1456
    public function setExposeElementToA11y($exposeElementToA11y) {
1457
        $this->exposeElementToA11y = $exposeElementToA11y;
1458
        return $this;
1459
    }
1460
1461
    /**
1462
     * Set the find nearest point by.
1463
     *
1464
     * @param string $findNearestPointBy The find nearest point by.
1465
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1466
     */
1467
    public function setFindNearestPointBy($findNearestPointBy) {
1468
        switch ($findNearestPointBy) {
1469
            case "x":
1470
            case "xy":
1471
            $this->findNearestPointBy = $findNearestPointBy;
1472
            break;
1473
        }
1474
        return $this;
1475
    }
1476
1477
    /**
1478
     * Set the get extremes from all.
1479
     *
1480
     * @param boolean $getExtremesFromAll The get extremes from all.
1481
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1482
     */
1483
    public function setGetExtremesFromAll($getExtremesFromAll) {
1484
        $this->getExtremesFromAll = $getExtremesFromAll;
1485
        return $this;
1486
    }
1487
1488
    /**
1489
     * Set the id.
1490
     *
1491
     * @param string $id The id.
1492
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1493
     */
1494
    public function setId($id) {
1495
        $this->id = $id;
1496
        return $this;
1497
    }
1498
1499
    /**
1500
     * Set the ignore hidden point.
1501
     *
1502
     * @param boolean $ignoreHiddenPoint The ignore hidden point.
1503
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1504
     */
1505
    public function setIgnoreHiddenPoint($ignoreHiddenPoint) {
1506
        $this->ignoreHiddenPoint = $ignoreHiddenPoint;
1507
        return $this;
1508
    }
1509
1510
    /**
1511
     * Set the index.
1512
     *
1513
     * @param integer $index The index.
1514
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1515
     */
1516
    public function setIndex($index) {
1517
        $this->index = $index;
1518
        return $this;
1519
    }
1520
1521
    /**
1522
     * Set the interact by leaf.
1523
     *
1524
     * @param boolean $interactByLeaf The interact by leaf.
1525
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1526
     */
1527
    public function setInteractByLeaf($interactByLeaf) {
1528
        switch ($interactByLeaf) {
1529
            case false:
1530
            case true:
1531
            $this->interactByLeaf = $interactByLeaf;
1532
            break;
1533
        }
1534
        return $this;
1535
    }
1536
1537
    /**
1538
     * Set the keys.
1539
     *
1540
     * @param array $keys The keys.
1541
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1542
     */
1543
    public function setKeys(array $keys = null) {
1544
        $this->keys = $keys;
0 ignored issues
show
Documentation Bug introduced by
It seems like $keys can be null. However, the property $keys is declared as array. Maybe change the type of the property to array|null or add a type check?

Our type inference engine has found an assignment of a scalar value (like a string, an integer or null) to a property which is an array.

Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property.

To type hint that a parameter can be either an array or null, you can set a type hint of array and a default value of null. The PHP interpreter will then accept both an array or null for that parameter.

function aContainsB(array $needle = null, array  $haystack) {
    if (!$needle) {
        return false;
    }

    return array_intersect($haystack, $needle) == $haystack;
}

The function can be called with either null or an array for the parameter $needle but will only accept an array as $haystack.

Loading history...
1545
        return $this;
1546
    }
1547
1548
    /**
1549
     * Set the layout algorithm.
1550
     *
1551
     * @param string $layoutAlgorithm The layout algorithm.
1552
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1553
     */
1554
    public function setLayoutAlgorithm($layoutAlgorithm) {
1555
        switch ($layoutAlgorithm) {
1556
            case "sliceAndDice":
1557
            case "squarified":
1558
            case "strip":
1559
            case "stripes":
1560
            $this->layoutAlgorithm = $layoutAlgorithm;
1561
            break;
1562
        }
1563
        return $this;
1564
    }
1565
1566
    /**
1567
     * Set the layout starting direction.
1568
     *
1569
     * @param string $layoutStartingDirection The layout starting direction.
1570
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1571
     */
1572
    public function setLayoutStartingDirection($layoutStartingDirection) {
1573
        switch ($layoutStartingDirection) {
1574
            case "horizontal":
1575
            case "vertical":
1576
            $this->layoutStartingDirection = $layoutStartingDirection;
1577
            break;
1578
        }
1579
        return $this;
1580
    }
1581
1582
    /**
1583
     * Set the legend index.
1584
     *
1585
     * @param integer $legendIndex The legend index.
1586
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1587
     */
1588
    public function setLegendIndex($legendIndex) {
1589
        $this->legendIndex = $legendIndex;
1590
        return $this;
1591
    }
1592
1593
    /**
1594
     * Set the level is constant.
1595
     *
1596
     * @param boolean $levelIsConstant The level is constant.
1597
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1598
     */
1599
    public function setLevelIsConstant($levelIsConstant) {
1600
        switch ($levelIsConstant) {
1601
            case "false":
1602
            case "true":
1603
            $this->levelIsConstant = $levelIsConstant;
1604
            break;
1605
        }
1606
        return $this;
1607
    }
1608
1609
    /**
1610
     * Set the levels.
1611
     *
1612
     * @param array $levels The levels.
1613
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1614
     */
1615
    public function setLevels(array $levels = null) {
1616
        $this->levels = $levels;
0 ignored issues
show
Documentation Bug introduced by
It seems like $levels can be null. However, the property $levels is declared as array. Maybe change the type of the property to array|null or add a type check?

Our type inference engine has found an assignment of a scalar value (like a string, an integer or null) to a property which is an array.

Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property.

To type hint that a parameter can be either an array or null, you can set a type hint of array and a default value of null. The PHP interpreter will then accept both an array or null for that parameter.

function aContainsB(array $needle = null, array  $haystack) {
    if (!$needle) {
        return false;
    }

    return array_intersect($haystack, $needle) == $haystack;
}

The function can be called with either null or an array for the parameter $needle but will only accept an array as $haystack.

Loading history...
1617
        return $this;
1618
    }
1619
1620
    /**
1621
     * Set the linked to.
1622
     *
1623
     * @param string $linkedTo The linked to.
1624
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1625
     */
1626
    public function setLinkedTo($linkedTo) {
1627
        $this->linkedTo = $linkedTo;
1628
        return $this;
1629
    }
1630
1631
    /**
1632
     * Set the max point width.
1633
     *
1634
     * @param integer $maxPointWidth The max point width.
1635
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1636
     */
1637
    public function setMaxPointWidth($maxPointWidth) {
1638
        $this->maxPointWidth = $maxPointWidth;
1639
        return $this;
1640
    }
1641
1642
    /**
1643
     * Set the name.
1644
     *
1645
     * @param string $name The name.
1646
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1647
     */
1648
    public function setName($name) {
1649
        $this->name = $name;
1650
        return $this;
1651
    }
1652
1653
    /**
1654
     * Set the opacity.
1655
     *
1656
     * @param integer $opacity The opacity.
1657
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1658
     */
1659
    public function setOpacity($opacity) {
1660
        $this->opacity = $opacity;
1661
        return $this;
1662
    }
1663
1664
    /**
1665
     * Set the point.
1666
     *
1667
     * @param \WBW\Bundle\HighchartsBundle\API\Chart\Series\Treemap\HighchartsPoint $point The point.
1668
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1669
     */
1670
    public function setPoint(\WBW\Bundle\HighchartsBundle\API\Chart\Series\Treemap\HighchartsPoint $point = null) {
1671
        $this->point = $point;
1672
        return $this;
1673
    }
1674
1675
    /**
1676
     * Set the point description formatter.
1677
     *
1678
     * @param string $pointDescriptionFormatter The point description formatter.
1679
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1680
     */
1681
    public function setPointDescriptionFormatter($pointDescriptionFormatter) {
1682
        $this->pointDescriptionFormatter = $pointDescriptionFormatter;
1683
        return $this;
1684
    }
1685
1686
    /**
1687
     * Set the selected.
1688
     *
1689
     * @param boolean $selected The selected.
1690
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1691
     */
1692
    public function setSelected($selected) {
1693
        $this->selected = $selected;
1694
        return $this;
1695
    }
1696
1697
    /**
1698
     * Set the shadow.
1699
     *
1700
     * @param boolean|array $shadow The shadow.
1701
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1702
     */
1703
    public function setShadow($shadow) {
1704
        $this->shadow = $shadow;
1705
        return $this;
1706
    }
1707
1708
    /**
1709
     * Set the show checkbox.
1710
     *
1711
     * @param boolean $showCheckbox The show checkbox.
1712
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1713
     */
1714
    public function setShowCheckbox($showCheckbox) {
1715
        $this->showCheckbox = $showCheckbox;
1716
        return $this;
1717
    }
1718
1719
    /**
1720
     * Set the show in legend.
1721
     *
1722
     * @param boolean $showInLegend The show in legend.
1723
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1724
     */
1725
    public function setShowInLegend($showInLegend) {
1726
        $this->showInLegend = $showInLegend;
1727
        return $this;
1728
    }
1729
1730
    /**
1731
     * Set the skip keyboard navigation.
1732
     *
1733
     * @param boolean $skipKeyboardNavigation The skip keyboard navigation.
1734
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1735
     */
1736
    public function setSkipKeyboardNavigation($skipKeyboardNavigation) {
1737
        $this->skipKeyboardNavigation = $skipKeyboardNavigation;
1738
        return $this;
1739
    }
1740
1741
    /**
1742
     * Set the sort index.
1743
     *
1744
     * @param integer $sortIndex The sort index.
1745
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1746
     */
1747
    public function setSortIndex($sortIndex) {
1748
        $this->sortIndex = $sortIndex;
1749
        return $this;
1750
    }
1751
1752
    /**
1753
     * Set the states.
1754
     *
1755
     * @param \WBW\Bundle\HighchartsBundle\API\Chart\Series\Treemap\HighchartsStates $states The states.
1756
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1757
     */
1758
    public function setStates(\WBW\Bundle\HighchartsBundle\API\Chart\Series\Treemap\HighchartsStates $states = null) {
1759
        $this->states = $states;
1760
        return $this;
1761
    }
1762
1763
    /**
1764
     * Set the sticky tracking.
1765
     *
1766
     * @param boolean $stickyTracking The sticky tracking.
1767
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1768
     */
1769
    public function setStickyTracking($stickyTracking) {
1770
        $this->stickyTracking = $stickyTracking;
1771
        return $this;
1772
    }
1773
1774
    /**
1775
     * Set the tooltip.
1776
     *
1777
     * @param \WBW\Bundle\HighchartsBundle\API\Chart\Series\Treemap\HighchartsTooltip $tooltip The tooltip.
1778
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1779
     */
1780
    public function setTooltip(\WBW\Bundle\HighchartsBundle\API\Chart\Series\Treemap\HighchartsTooltip $tooltip = null) {
1781
        $this->tooltip = $tooltip;
1782
        return $this;
1783
    }
1784
1785
    /**
1786
     * Set the turbo threshold.
1787
     *
1788
     * @param integer $turboThreshold The turbo threshold.
1789
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1790
     */
1791
    public function setTurboThreshold($turboThreshold) {
1792
        $this->turboThreshold = $turboThreshold;
1793
        return $this;
1794
    }
1795
1796
    /**
1797
     * Set the type.
1798
     *
1799
     * @param string $type The type.
1800
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1801
     */
1802
    public function setType($type) {
1803
        switch ($type) {
1804
            case null:
1805
            case "area":
1806
            case "arearange":
1807
            case "areaspline":
1808
            case "areasplinerange":
1809
            case "boxplot":
1810
            case "bubble":
1811
            case "column":
1812
            case "columnrange":
1813
            case "errorbar":
1814
            case "funnel":
1815
            case "gauge":
1816
            case "line":
1817
            case "pie":
1818
            case "scatter":
1819
            case "spline":
1820
            case "waterfall":
1821
            $this->type = $type;
1822
            break;
1823
        }
1824
        return $this;
1825
    }
1826
1827
    /**
1828
     * Set the visible.
1829
     *
1830
     * @param boolean $visible The visible.
1831
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1832
     */
1833
    public function setVisible($visible) {
1834
        $this->visible = $visible;
1835
        return $this;
1836
    }
1837
1838
    /**
1839
     * Set the x axis.
1840
     *
1841
     * @param integer|string $xAxis The x axis.
1842
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1843
     */
1844
    public function setXAxis($xAxis) {
1845
        $this->xAxis = $xAxis;
1846
        return $this;
1847
    }
1848
1849
    /**
1850
     * Set the y axis.
1851
     *
1852
     * @param integer|string $yAxis The y axis.
1853
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1854
     */
1855
    public function setYAxis($yAxis) {
1856
        $this->yAxis = $yAxis;
1857
        return $this;
1858
    }
1859
1860
    /**
1861
     * Set the z index.
1862
     *
1863
     * @param integer $zIndex The z index.
1864
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1865
     */
1866
    public function setZIndex($zIndex) {
1867
        $this->zIndex = $zIndex;
1868
        return $this;
1869
    }
1870
1871
    /**
1872
     * Set the zone axis.
1873
     *
1874
     * @param string $zoneAxis The zone axis.
1875
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1876
     */
1877
    public function setZoneAxis($zoneAxis) {
1878
        $this->zoneAxis = $zoneAxis;
1879
        return $this;
1880
    }
1881
1882
    /**
1883
     * Set the zones.
1884
     *
1885
     * @param array $zones The zones.
1886
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsTreemap Returns the highcharts treemap.
1887
     */
1888
    public function setZones(array $zones = null) {
1889
        $this->zones = $zones;
0 ignored issues
show
Documentation Bug introduced by
It seems like $zones can be null. However, the property $zones is declared as array. Maybe change the type of the property to array|null or add a type check?

Our type inference engine has found an assignment of a scalar value (like a string, an integer or null) to a property which is an array.

Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property.

To type hint that a parameter can be either an array or null, you can set a type hint of array and a default value of null. The PHP interpreter will then accept both an array or null for that parameter.

function aContainsB(array $needle = null, array  $haystack) {
    if (!$needle) {
        return false;
    }

    return array_intersect($haystack, $needle) == $haystack;
}

The function can be called with either null or an array for the parameter $needle but will only accept an array as $haystack.

Loading history...
1890
        return $this;
1891
    }
1892
1893
    /**
1894
     * Convert into an array representing this instance.
1895
     *
1896
     * @return array Returns an array representing this instance.
1897
     */
1898
    public function toArray() {
1899
1900
        // Initialize the output.
1901
        $output = [];
1902
1903
        // Set the allow drill to node.
1904
        ArrayUtility::set($output, "allowDrillToNode", $this->allowDrillToNode, [null]);
1905
1906
        // Set the allow point select.
1907
        ArrayUtility::set($output, "allowPointSelect", $this->allowPointSelect, [null]);
1908
1909
        // Set the alternate starting direction.
1910
        ArrayUtility::set($output, "alternateStartingDirection", $this->alternateStartingDirection, [null]);
1911
1912
        // Set the animation.
1913
        ArrayUtility::set($output, "animation", $this->animation, [null]);
1914
1915
        // Set the animation limit.
1916
        ArrayUtility::set($output, "animationLimit", $this->animationLimit, [null]);
1917
1918
        // Set the border color.
1919
        ArrayUtility::set($output, "borderColor", $this->borderColor, [null]);
1920
1921
        // Set the border width.
1922
        ArrayUtility::set($output, "borderWidth", $this->borderWidth, [null]);
1923
1924
        // Set the class name.
1925
        ArrayUtility::set($output, "className", $this->className, [null]);
1926
1927
        // Set the color.
1928
        ArrayUtility::set($output, "color", $this->color, [null]);
1929
1930
        // Set the color by point.
1931
        ArrayUtility::set($output, "colorByPoint", $this->colorByPoint, [null]);
1932
1933
        // Set the color index.
1934
        ArrayUtility::set($output, "colorIndex", $this->colorIndex, [null]);
1935
1936
        // Set the colors.
1937
        ArrayUtility::set($output, "colors", $this->colors, [null]);
1938
1939
        // Set the crisp.
1940
        ArrayUtility::set($output, "crisp", $this->crisp, [null]);
1941
1942
        // Set the crop threshold.
1943
        ArrayUtility::set($output, "cropThreshold", $this->cropThreshold, [null]);
1944
1945
        // Set the cursor.
1946
        ArrayUtility::set($output, "cursor", $this->cursor, [null]);
1947
1948
        // Set the data.
1949
        ArrayUtility::set($output, "data", $this->data, [null]);
1950
1951
        // Set the data labels.
1952
        if (null !== $this->dataLabels) {
1953
            ArrayUtility::set($output, "dataLabels", $this->dataLabels->toArray(), []);
1954
        }
1955
1956
        // Set the description.
1957
        ArrayUtility::set($output, "description", $this->description, [null]);
1958
1959
        // Set the enable mouse tracking.
1960
        ArrayUtility::set($output, "enableMouseTracking", $this->enableMouseTracking, [null]);
1961
1962
        // Set the events.
1963
        if (null !== $this->events) {
1964
            ArrayUtility::set($output, "events", $this->events->toArray(), []);
1965
        }
1966
1967
        // Set the expose element to a11y.
1968
        ArrayUtility::set($output, "exposeElementToA11y", $this->exposeElementToA11y, [null]);
1969
1970
        // Set the find nearest point by.
1971
        ArrayUtility::set($output, "findNearestPointBy", $this->findNearestPointBy, [null]);
1972
1973
        // Set the get extremes from all.
1974
        ArrayUtility::set($output, "getExtremesFromAll", $this->getExtremesFromAll, [null]);
1975
1976
        // Set the id.
1977
        ArrayUtility::set($output, "id", $this->id, [null]);
1978
1979
        // Set the ignore hidden point.
1980
        ArrayUtility::set($output, "ignoreHiddenPoint", $this->ignoreHiddenPoint, [null]);
1981
1982
        // Set the index.
1983
        ArrayUtility::set($output, "index", $this->index, [null]);
1984
1985
        // Set the interact by leaf.
1986
        ArrayUtility::set($output, "interactByLeaf", $this->interactByLeaf, [null]);
1987
1988
        // Set the keys.
1989
        ArrayUtility::set($output, "keys", $this->keys, [null]);
1990
1991
        // Set the layout algorithm.
1992
        ArrayUtility::set($output, "layoutAlgorithm", $this->layoutAlgorithm, [null]);
1993
1994
        // Set the layout starting direction.
1995
        ArrayUtility::set($output, "layoutStartingDirection", $this->layoutStartingDirection, [null]);
1996
1997
        // Set the legend index.
1998
        ArrayUtility::set($output, "legendIndex", $this->legendIndex, [null]);
1999
2000
        // Set the level is constant.
2001
        ArrayUtility::set($output, "levelIsConstant", $this->levelIsConstant, [null]);
2002
2003
        // Set the levels.
2004
        ArrayUtility::set($output, "levels", $this->levels, [null]);
2005
2006
        // Set the linked to.
2007
        ArrayUtility::set($output, "linkedTo", $this->linkedTo, [null]);
2008
2009
        // Set the max point width.
2010
        ArrayUtility::set($output, "maxPointWidth", $this->maxPointWidth, [null]);
2011
2012
        // Set the name.
2013
        ArrayUtility::set($output, "name", $this->name, [null]);
2014
2015
        // Set the opacity.
2016
        ArrayUtility::set($output, "opacity", $this->opacity, [null]);
2017
2018
        // Set the point.
2019
        if (null !== $this->point) {
2020
            ArrayUtility::set($output, "point", $this->point->toArray(), []);
2021
        }
2022
2023
        // Set the point description formatter.
2024
        ArrayUtility::set($output, "pointDescriptionFormatter", $this->pointDescriptionFormatter, [null]);
2025
2026
        // Set the selected.
2027
        ArrayUtility::set($output, "selected", $this->selected, [null]);
2028
2029
        // Set the shadow.
2030
        ArrayUtility::set($output, "shadow", $this->shadow, [null]);
2031
2032
        // Set the show checkbox.
2033
        ArrayUtility::set($output, "showCheckbox", $this->showCheckbox, [null]);
2034
2035
        // Set the show in legend.
2036
        ArrayUtility::set($output, "showInLegend", $this->showInLegend, [null]);
2037
2038
        // Set the skip keyboard navigation.
2039
        ArrayUtility::set($output, "skipKeyboardNavigation", $this->skipKeyboardNavigation, [null]);
2040
2041
        // Set the sort index.
2042
        ArrayUtility::set($output, "sortIndex", $this->sortIndex, [null]);
2043
2044
        // Set the states.
2045
        if (null !== $this->states) {
2046
            ArrayUtility::set($output, "states", $this->states->toArray(), []);
2047
        }
2048
2049
        // Set the sticky tracking.
2050
        ArrayUtility::set($output, "stickyTracking", $this->stickyTracking, [null]);
2051
2052
        // Set the tooltip.
2053
        if (null !== $this->tooltip) {
2054
            ArrayUtility::set($output, "tooltip", $this->tooltip->toArray(), []);
2055
        }
2056
2057
        // Set the turbo threshold.
2058
        ArrayUtility::set($output, "turboThreshold", $this->turboThreshold, [null]);
2059
2060
        // Set the type.
2061
        ArrayUtility::set($output, "type", $this->type, [null]);
2062
2063
        // Set the visible.
2064
        ArrayUtility::set($output, "visible", $this->visible, [null]);
2065
2066
        // Set the x axis.
2067
        ArrayUtility::set($output, "xAxis", $this->xAxis, [null]);
2068
2069
        // Set the y axis.
2070
        ArrayUtility::set($output, "yAxis", $this->yAxis, [null]);
2071
2072
        // Set the z index.
2073
        ArrayUtility::set($output, "zIndex", $this->zIndex, [null]);
2074
2075
        // Set the zone axis.
2076
        ArrayUtility::set($output, "zoneAxis", $this->zoneAxis, [null]);
2077
2078
        // Set the zones.
2079
        ArrayUtility::set($output, "zones", $this->zones, [null]);
2080
2081
        // Return the output.
2082
        return $output;
2083
    }
2084
2085
}
2086