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/HighchartsFunnel.php (12 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 funnel.
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 HighchartsFunnel implements JsonSerializable {
26
27
    /**
28
     * Allow point select.
29
     *
30
     * @var boolean
31
     * @since 1.2.0
32
     */
33
    private $allowPointSelect = false;
34
35
    /**
36
     * Animation limit.
37
     *
38
     * @var integer
39
     */
40
    private $animationLimit;
41
42
    /**
43
     * Border color.
44
     *
45
     * @var string
46
     */
47
    private $borderColor = "#ffffff";
48
49
    /**
50
     * Border width.
51
     *
52
     * @var integer
53
     */
54
    private $borderWidth = 1;
55
56
    /**
57
     * Center.
58
     *
59
     * @var array
60
     * @since 3.0
61
     */
62
    private $center = ["50%", "50%"];
63
64
    /**
65
     * Class name.
66
     *
67
     * @var string
68
     * @since 5.0.0
69
     */
70
    private $className;
71
72
    /**
73
     * Color index.
74
     *
75
     * @var integer
76
     * @since 5.0.0
77
     */
78
    private $colorIndex;
79
80
    /**
81
     * Colors.
82
     *
83
     * @var array
84
     * @since 3.0
85
     */
86
    private $colors;
87
88
    /**
89
     * Cursor.
90
     *
91
     * @var string
92
     */
93
    private $cursor;
94
95
    /**
96
     * Data.
97
     *
98
     * @var array
99
     */
100
    private $data;
101
102
    /**
103
     * Data labels.
104
     *
105
     * @var \WBW\Bundle\HighchartsBundle\API\Chart\Series\Funnel\HighchartsDataLabels
106
     */
107
    private $dataLabels;
108
109
    /**
110
     * Depth.
111
     *
112
     * @var integer
113
     * @since 4.0
114
     */
115
    private $depth = 0;
116
117
    /**
118
     * Description.
119
     *
120
     * @var string
121
     * @since 5.0.0
122
     */
123
    private $description;
124
125
    /**
126
     * Enable mouse tracking.
127
     *
128
     * @var boolean
129
     */
130
    private $enableMouseTracking = true;
131
132
    /**
133
     * Events.
134
     *
135
     * @var \WBW\Bundle\HighchartsBundle\API\Chart\Series\Funnel\HighchartsEvents
136
     */
137
    private $events;
138
139
    /**
140
     * Expose element to a11y.
141
     *
142
     * @var boolean
143
     * @since 5.0.12
144
     */
145
    private $exposeElementToA11y;
146
147
    /**
148
     * Find nearest point by.
149
     *
150
     * @var string
151
     * @since 5.0.10
152
     */
153
    private $findNearestPointBy;
154
155
    /**
156
     * Get extremes from all.
157
     *
158
     * @var boolean
159
     * @since 4.1.6
160
     */
161
    private $getExtremesFromAll = false;
162
163
    /**
164
     * Height.
165
     *
166
     * @var integer|string
167
     * @since 3.0
168
     */
169
    private $height;
170
171
    /**
172
     * Id.
173
     *
174
     * @var string
175
     * @since 1.2.0
176
     */
177
    private $id;
178
179
    /**
180
     * Index.
181
     *
182
     * @var integer
183
     * @since 2.3.0
184
     */
185
    private $index;
186
187
    /**
188
     * Keys.
189
     *
190
     * @var array
191
     * @since 4.1.6
192
     */
193
    private $keys;
194
195
    /**
196
     * Legend index.
197
     *
198
     * @var integer
199
     */
200
    private $legendIndex;
201
202
    /**
203
     * Linked to.
204
     *
205
     * @var string
206
     * @since 3.0
207
     */
208
    private $linkedTo;
209
210
    /**
211
     * Min size.
212
     *
213
     * @var integer
214
     * @since 3.0
215
     */
216
    private $minSize = 80;
217
218
    /**
219
     * Name.
220
     *
221
     * @var string
222
     */
223
    private $name;
224
225
    /**
226
     * Neck height.
227
     *
228
     * @var integer|string
229
     */
230
    private $neckHeight = "25%";
231
232
    /**
233
     * Neck width.
234
     *
235
     * @var integer|string
236
     * @since 3.0
237
     */
238
    private $neckWidth = "30%";
239
240
    /**
241
     * Point.
242
     *
243
     * @var \WBW\Bundle\HighchartsBundle\API\Chart\Series\Funnel\HighchartsPoint
244
     */
245
    private $point;
246
247
    /**
248
     * Point description formatter.
249
     *
250
     * @var string
251
     * @since 5.0.12
252
     */
253
    private $pointDescriptionFormatter;
254
255
    /**
256
     * Reversed.
257
     *
258
     * @var boolean
259
     * @since 3.0.10
260
     */
261
    private $reversed = false;
262
263
    /**
264
     * Selected.
265
     *
266
     * @var boolean
267
     * @since 1.2.0
268
     */
269
    private $selected = false;
270
271
    /**
272
     * Shadow.
273
     *
274
     * @var boolean|array
275
     */
276
    private $shadow = false;
277
278
    /**
279
     * Show in legend.
280
     *
281
     * @var boolean
282
     */
283
    private $showInLegend = false;
284
285
    /**
286
     * Skip keyboard navigation.
287
     *
288
     * @var boolean
289
     * @since 5.0.12
290
     */
291
    private $skipKeyboardNavigation;
292
293
    /**
294
     * Sliced offset.
295
     *
296
     * @var integer
297
     */
298
    private $slicedOffset = 10;
299
300
    /**
301
     * States.
302
     *
303
     * @var \WBW\Bundle\HighchartsBundle\API\Chart\Series\Funnel\HighchartsStates
304
     */
305
    private $states;
306
307
    /**
308
     * Sticky tracking.
309
     *
310
     * @var boolean
311
     */
312
    private $stickyTracking = false;
313
314
    /**
315
     * Tooltip.
316
     *
317
     * @var array
318
     * @since 2.3
319
     */
320
    private $tooltip;
321
322
    /**
323
     * Type.
324
     *
325
     * @var string
326
     */
327
    private $type;
328
329
    /**
330
     * Visible.
331
     *
332
     * @var boolean
333
     */
334
    private $visible = true;
335
336
    /**
337
     * Width.
338
     *
339
     * @var integer|string
340
     * @since 3.0
341
     */
342
    private $width = "90%";
343
344
    /**
345
     * Z index.
346
     *
347
     * @var integer
348
     */
349
    private $zIndex;
350
351
    /**
352
     * Zone axis.
353
     *
354
     * @var string
355
     * @since 4.1.0
356
     */
357
    private $zoneAxis = "y";
358
359
    /**
360
     * Zones.
361
     *
362
     * @var array
363
     * @since 4.1.0
364
     */
365
    private $zones;
366
367
    /**
368
     * Constructor.
369
     *
370
     * @param boolean $ignoreDefaultValues Ignore the default values.
371
     */
372
    public function __construct($ignoreDefaultValues = true) {
373
        if (true === $ignoreDefaultValues) {
374
            $this->clear();
375
        }
376
    }
377
378
    /**
379
     * Clear.
380
     *
381
     * @return void
382
     */
383
    public function clear() {
384
385
        // Clear the allow point select.
386
        $this->allowPointSelect = null;
387
388
        // Clear the animation limit.
389
        $this->animationLimit = null;
390
391
        // Clear the border color.
392
        $this->borderColor = null;
393
394
        // Clear the border width.
395
        $this->borderWidth = null;
396
397
        // Clear the center.
398
        $this->center = 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 $center.

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...
399
400
        // Clear the class name.
401
        $this->className = null;
402
403
        // Clear the color index.
404
        $this->colorIndex = null;
405
406
        // Clear the colors.
407
        $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...
408
409
        // Clear the cursor.
410
        $this->cursor = null;
411
412
        // Clear the data.
413
        $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...
414
415
        // Clear the data labels.
416
        if (null !== $this->dataLabels) {
417
            $this->dataLabels->clear();
418
        }
419
420
        // Clear the depth.
421
        $this->depth = null;
422
423
        // Clear the description.
424
        $this->description = null;
425
426
        // Clear the enable mouse tracking.
427
        $this->enableMouseTracking = null;
428
429
        // Clear the events.
430
        if (null !== $this->events) {
431
            $this->events->clear();
432
        }
433
434
        // Clear the expose element to a11y.
435
        $this->exposeElementToA11y = null;
436
437
        // Clear the find nearest point by.
438
        $this->findNearestPointBy = null;
439
440
        // Clear the get extremes from all.
441
        $this->getExtremesFromAll = null;
442
443
        // Clear the height.
444
        $this->height = null;
445
446
        // Clear the id.
447
        $this->id = null;
448
449
        // Clear the index.
450
        $this->index = null;
451
452
        // Clear the keys.
453
        $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...
454
455
        // Clear the legend index.
456
        $this->legendIndex = null;
457
458
        // Clear the linked to.
459
        $this->linkedTo = null;
460
461
        // Clear the min size.
462
        $this->minSize = null;
463
464
        // Clear the name.
465
        $this->name = null;
466
467
        // Clear the neck height.
468
        $this->neckHeight = null;
469
470
        // Clear the neck width.
471
        $this->neckWidth = null;
472
473
        // Clear the point.
474
        if (null !== $this->point) {
475
            $this->point->clear();
476
        }
477
478
        // Clear the point description formatter.
479
        $this->pointDescriptionFormatter = null;
480
481
        // Clear the reversed.
482
        $this->reversed = null;
483
484
        // Clear the selected.
485
        $this->selected = null;
486
487
        // Clear the shadow.
488
        $this->shadow = null;
489
490
        // Clear the show in legend.
491
        $this->showInLegend = null;
492
493
        // Clear the skip keyboard navigation.
494
        $this->skipKeyboardNavigation = null;
495
496
        // Clear the sliced offset.
497
        $this->slicedOffset = null;
498
499
        // Clear the states.
500
        if (null !== $this->states) {
501
            $this->states->clear();
502
        }
503
504
        // Clear the sticky tracking.
505
        $this->stickyTracking = null;
506
507
        // Clear the tooltip.
508
        $this->tooltip = 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 $tooltip.

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 type.
511
        $this->type = null;
512
513
        // Clear the visible.
514
        $this->visible = null;
515
516
        // Clear the width.
517
        $this->width = null;
518
519
        // Clear the z index.
520
        $this->zIndex = null;
521
522
        // Clear the zone axis.
523
        $this->zoneAxis = null;
524
525
        // Clear the zones.
526
        $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...
527
    }
528
529
    /**
530
     * Get the allow point select.
531
     *
532
     * @return boolean Returns the allow point select.
533
     */
534
    public function getAllowPointSelect() {
535
        return $this->allowPointSelect;
536
    }
537
538
    /**
539
     * Get the animation limit.
540
     *
541
     * @return integer Returns the animation limit.
542
     */
543
    public function getAnimationLimit() {
544
        return $this->animationLimit;
545
    }
546
547
    /**
548
     * Get the border color.
549
     *
550
     * @return string Returns the border color.
551
     */
552
    public function getBorderColor() {
553
        return $this->borderColor;
554
    }
555
556
    /**
557
     * Get the border width.
558
     *
559
     * @return integer Returns the border width.
560
     */
561
    public function getBorderWidth() {
562
        return $this->borderWidth;
563
    }
564
565
    /**
566
     * Get the center.
567
     *
568
     * @return array Returns the center.
569
     */
570
    public function getCenter() {
571
        return $this->center;
572
    }
573
574
    /**
575
     * Get the class name.
576
     *
577
     * @return string Returns the class name.
578
     */
579
    public function getClassName() {
580
        return $this->className;
581
    }
582
583
    /**
584
     * Get the color index.
585
     *
586
     * @return integer Returns the color index.
587
     */
588
    public function getColorIndex() {
589
        return $this->colorIndex;
590
    }
591
592
    /**
593
     * Get the colors.
594
     *
595
     * @return array Returns the colors.
596
     */
597
    public function getColors() {
598
        return $this->colors;
599
    }
600
601
    /**
602
     * Get the cursor.
603
     *
604
     * @return string Returns the cursor.
605
     */
606
    public function getCursor() {
607
        return $this->cursor;
608
    }
609
610
    /**
611
     * Get the data.
612
     *
613
     * @return array Returns the data.
614
     */
615
    public function getData() {
616
        return $this->data;
617
    }
618
619
    /**
620
     * Get the data labels.
621
     *
622
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\Funnel\HighchartsDataLabels Returns the data labels.
623
     */
624
    public function getDataLabels() {
625
        return $this->dataLabels;
626
    }
627
628
    /**
629
     * Get the depth.
630
     *
631
     * @return integer Returns the depth.
632
     */
633
    public function getDepth() {
634
        return $this->depth;
635
    }
636
637
    /**
638
     * Get the description.
639
     *
640
     * @return string Returns the description.
641
     */
642
    public function getDescription() {
643
        return $this->description;
644
    }
645
646
    /**
647
     * Get the enable mouse tracking.
648
     *
649
     * @return boolean Returns the enable mouse tracking.
650
     */
651
    public function getEnableMouseTracking() {
652
        return $this->enableMouseTracking;
653
    }
654
655
    /**
656
     * Get the events.
657
     *
658
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\Funnel\HighchartsEvents Returns the events.
659
     */
660
    public function getEvents() {
661
        return $this->events;
662
    }
663
664
    /**
665
     * Get the expose element to a11y.
666
     *
667
     * @return boolean Returns the expose element to a11y.
668
     */
669
    public function getExposeElementToA11y() {
670
        return $this->exposeElementToA11y;
671
    }
672
673
    /**
674
     * Get the find nearest point by.
675
     *
676
     * @return string Returns the find nearest point by.
677
     */
678
    public function getFindNearestPointBy() {
679
        return $this->findNearestPointBy;
680
    }
681
682
    /**
683
     * Get the get extremes from all.
684
     *
685
     * @return boolean Returns the get extremes from all.
686
     */
687
    public function getGetExtremesFromAll() {
688
        return $this->getExtremesFromAll;
689
    }
690
691
    /**
692
     * Get the height.
693
     *
694
     * @return integer|string Returns the height.
695
     */
696
    public function getHeight() {
697
        return $this->height;
698
    }
699
700
    /**
701
     * Get the id.
702
     *
703
     * @return string Returns the id.
704
     */
705
    public function getId() {
706
        return $this->id;
707
    }
708
709
    /**
710
     * Get the index.
711
     *
712
     * @return integer Returns the index.
713
     */
714
    public function getIndex() {
715
        return $this->index;
716
    }
717
718
    /**
719
     * Get the keys.
720
     *
721
     * @return array Returns the keys.
722
     */
723
    public function getKeys() {
724
        return $this->keys;
725
    }
726
727
    /**
728
     * Get the legend index.
729
     *
730
     * @return integer Returns the legend index.
731
     */
732
    public function getLegendIndex() {
733
        return $this->legendIndex;
734
    }
735
736
    /**
737
     * Get the linked to.
738
     *
739
     * @return string Returns the linked to.
740
     */
741
    public function getLinkedTo() {
742
        return $this->linkedTo;
743
    }
744
745
    /**
746
     * Get the min size.
747
     *
748
     * @return integer Returns the min size.
749
     */
750
    public function getMinSize() {
751
        return $this->minSize;
752
    }
753
754
    /**
755
     * Get the name.
756
     *
757
     * @return string Returns the name.
758
     */
759
    public function getName() {
760
        return $this->name;
761
    }
762
763
    /**
764
     * Get the neck height.
765
     *
766
     * @return integer|string Returns the neck height.
767
     */
768
    public function getNeckHeight() {
769
        return $this->neckHeight;
770
    }
771
772
    /**
773
     * Get the neck width.
774
     *
775
     * @return integer|string Returns the neck width.
776
     */
777
    public function getNeckWidth() {
778
        return $this->neckWidth;
779
    }
780
781
    /**
782
     * Get the point.
783
     *
784
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\Funnel\HighchartsPoint Returns the point.
785
     */
786
    public function getPoint() {
787
        return $this->point;
788
    }
789
790
    /**
791
     * Get the point description formatter.
792
     *
793
     * @return string Returns the point description formatter.
794
     */
795
    public function getPointDescriptionFormatter() {
796
        return $this->pointDescriptionFormatter;
797
    }
798
799
    /**
800
     * Get the reversed.
801
     *
802
     * @return boolean Returns the reversed.
803
     */
804
    public function getReversed() {
805
        return $this->reversed;
806
    }
807
808
    /**
809
     * Get the selected.
810
     *
811
     * @return boolean Returns the selected.
812
     */
813
    public function getSelected() {
814
        return $this->selected;
815
    }
816
817
    /**
818
     * Get the shadow.
819
     *
820
     * @return boolean|array Returns the shadow.
821
     */
822
    public function getShadow() {
823
        return $this->shadow;
824
    }
825
826
    /**
827
     * Get the show in legend.
828
     *
829
     * @return boolean Returns the show in legend.
830
     */
831
    public function getShowInLegend() {
832
        return $this->showInLegend;
833
    }
834
835
    /**
836
     * Get the skip keyboard navigation.
837
     *
838
     * @return boolean Returns the skip keyboard navigation.
839
     */
840
    public function getSkipKeyboardNavigation() {
841
        return $this->skipKeyboardNavigation;
842
    }
843
844
    /**
845
     * Get the sliced offset.
846
     *
847
     * @return integer Returns the sliced offset.
848
     */
849
    public function getSlicedOffset() {
850
        return $this->slicedOffset;
851
    }
852
853
    /**
854
     * Get the states.
855
     *
856
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\Funnel\HighchartsStates Returns the states.
857
     */
858
    public function getStates() {
859
        return $this->states;
860
    }
861
862
    /**
863
     * Get the sticky tracking.
864
     *
865
     * @return boolean Returns the sticky tracking.
866
     */
867
    public function getStickyTracking() {
868
        return $this->stickyTracking;
869
    }
870
871
    /**
872
     * Get the tooltip.
873
     *
874
     * @return array Returns the tooltip.
875
     */
876
    public function getTooltip() {
877
        return $this->tooltip;
878
    }
879
880
    /**
881
     * Get the type.
882
     *
883
     * @return string Returns the type.
884
     */
885
    public function getType() {
886
        return $this->type;
887
    }
888
889
    /**
890
     * Get the visible.
891
     *
892
     * @return boolean Returns the visible.
893
     */
894
    public function getVisible() {
895
        return $this->visible;
896
    }
897
898
    /**
899
     * Get the width.
900
     *
901
     * @return integer|string Returns the width.
902
     */
903
    public function getWidth() {
904
        return $this->width;
905
    }
906
907
    /**
908
     * Get the z index.
909
     *
910
     * @return integer Returns the z index.
911
     */
912
    public function getZIndex() {
913
        return $this->zIndex;
914
    }
915
916
    /**
917
     * Get the zone axis.
918
     *
919
     * @return string Returns the zone axis.
920
     */
921
    public function getZoneAxis() {
922
        return $this->zoneAxis;
923
    }
924
925
    /**
926
     * Get the zones.
927
     *
928
     * @return array Returns the zones.
929
     */
930
    public function getZones() {
931
        return $this->zones;
932
    }
933
934
    /**
935
     * Serialize this instance.
936
     *
937
     * @return array Returns an array representing this instance.
938
     */
939
    public function jsonSerialize() {
940
        return $this->toArray();
941
    }
942
943
    /**
944
     * Create a new data labels.
945
     *
946
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\Funnel\HighchartsDataLabels Returns the data labels.
947
     */
948
    public function newDataLabels() {
949
        $this->dataLabels = new \WBW\Bundle\HighchartsBundle\API\Chart\Series\Funnel\HighchartsDataLabels();
950
        return $this->dataLabels;
951
    }
952
953
    /**
954
     * Create a new events.
955
     *
956
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\Funnel\HighchartsEvents Returns the events.
957
     */
958
    public function newEvents() {
959
        $this->events = new \WBW\Bundle\HighchartsBundle\API\Chart\Series\Funnel\HighchartsEvents();
960
        return $this->events;
961
    }
962
963
    /**
964
     * Create a new point.
965
     *
966
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\Funnel\HighchartsPoint Returns the point.
967
     */
968
    public function newPoint() {
969
        $this->point = new \WBW\Bundle\HighchartsBundle\API\Chart\Series\Funnel\HighchartsPoint();
970
        return $this->point;
971
    }
972
973
    /**
974
     * Create a new states.
975
     *
976
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\Funnel\HighchartsStates Returns the states.
977
     */
978
    public function newStates() {
979
        $this->states = new \WBW\Bundle\HighchartsBundle\API\Chart\Series\Funnel\HighchartsStates();
980
        return $this->states;
981
    }
982
983
    /**
984
     * Set the allow point select.
985
     *
986
     * @param boolean $allowPointSelect The allow point select.
987
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
988
     */
989
    public function setAllowPointSelect($allowPointSelect) {
990
        $this->allowPointSelect = $allowPointSelect;
991
        return $this;
992
    }
993
994
    /**
995
     * Set the animation limit.
996
     *
997
     * @param integer $animationLimit The animation limit.
998
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
999
     */
1000
    public function setAnimationLimit($animationLimit) {
1001
        $this->animationLimit = $animationLimit;
1002
        return $this;
1003
    }
1004
1005
    /**
1006
     * Set the border color.
1007
     *
1008
     * @param string $borderColor The border color.
1009
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1010
     */
1011
    public function setBorderColor($borderColor) {
1012
        $this->borderColor = $borderColor;
1013
        return $this;
1014
    }
1015
1016
    /**
1017
     * Set the border width.
1018
     *
1019
     * @param integer $borderWidth The border width.
1020
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1021
     */
1022
    public function setBorderWidth($borderWidth) {
1023
        $this->borderWidth = $borderWidth;
1024
        return $this;
1025
    }
1026
1027
    /**
1028
     * Set the center.
1029
     *
1030
     * @param array $center The center.
1031
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1032
     */
1033
    public function setCenter(array $center = null) {
1034
        $this->center = $center;
0 ignored issues
show
Documentation Bug introduced by
It seems like $center can be null. However, the property $center 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...
1035
        return $this;
1036
    }
1037
1038
    /**
1039
     * Set the class name.
1040
     *
1041
     * @param string $className The class name.
1042
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1043
     */
1044
    public function setClassName($className) {
1045
        $this->className = $className;
1046
        return $this;
1047
    }
1048
1049
    /**
1050
     * Set the color index.
1051
     *
1052
     * @param integer $colorIndex The color index.
1053
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1054
     */
1055
    public function setColorIndex($colorIndex) {
1056
        $this->colorIndex = $colorIndex;
1057
        return $this;
1058
    }
1059
1060
    /**
1061
     * Set the colors.
1062
     *
1063
     * @param array $colors The colors.
1064
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1065
     */
1066
    public function setColors(array $colors = null) {
1067
        $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...
1068
        return $this;
1069
    }
1070
1071
    /**
1072
     * Set the cursor.
1073
     *
1074
     * @param string $cursor The cursor.
1075
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1076
     */
1077
    public function setCursor($cursor) {
1078
        switch ($cursor) {
1079
            case null:
1080
            case "crosshair":
1081
            case "default":
1082
            case "help":
1083
            case "none":
1084
            case "pointer":
1085
            $this->cursor = $cursor;
1086
            break;
1087
        }
1088
        return $this;
1089
    }
1090
1091
    /**
1092
     * Set the data.
1093
     *
1094
     * @param array $data The data.
1095
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1096
     */
1097
    public function setData(array $data = null) {
1098
        $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...
1099
        return $this;
1100
    }
1101
1102
    /**
1103
     * Set the data labels.
1104
     *
1105
     * @param \WBW\Bundle\HighchartsBundle\API\Chart\Series\Funnel\HighchartsDataLabels $dataLabels The data labels.
1106
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1107
     */
1108
    public function setDataLabels(\WBW\Bundle\HighchartsBundle\API\Chart\Series\Funnel\HighchartsDataLabels $dataLabels = null) {
1109
        $this->dataLabels = $dataLabels;
1110
        return $this;
1111
    }
1112
1113
    /**
1114
     * Set the depth.
1115
     *
1116
     * @param integer $depth The depth.
1117
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1118
     */
1119
    public function setDepth($depth) {
1120
        $this->depth = $depth;
1121
        return $this;
1122
    }
1123
1124
    /**
1125
     * Set the description.
1126
     *
1127
     * @param string $description The description.
1128
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1129
     */
1130
    public function setDescription($description) {
1131
        $this->description = $description;
1132
        return $this;
1133
    }
1134
1135
    /**
1136
     * Set the enable mouse tracking.
1137
     *
1138
     * @param boolean $enableMouseTracking The enable mouse tracking.
1139
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1140
     */
1141
    public function setEnableMouseTracking($enableMouseTracking) {
1142
        $this->enableMouseTracking = $enableMouseTracking;
1143
        return $this;
1144
    }
1145
1146
    /**
1147
     * Set the events.
1148
     *
1149
     * @param \WBW\Bundle\HighchartsBundle\API\Chart\Series\Funnel\HighchartsEvents $events The events.
1150
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1151
     */
1152
    public function setEvents(\WBW\Bundle\HighchartsBundle\API\Chart\Series\Funnel\HighchartsEvents $events = null) {
1153
        $this->events = $events;
1154
        return $this;
1155
    }
1156
1157
    /**
1158
     * Set the expose element to a11y.
1159
     *
1160
     * @param boolean $exposeElementToA11y The expose element to a11y.
1161
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1162
     */
1163
    public function setExposeElementToA11y($exposeElementToA11y) {
1164
        $this->exposeElementToA11y = $exposeElementToA11y;
1165
        return $this;
1166
    }
1167
1168
    /**
1169
     * Set the find nearest point by.
1170
     *
1171
     * @param string $findNearestPointBy The find nearest point by.
1172
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1173
     */
1174
    public function setFindNearestPointBy($findNearestPointBy) {
1175
        switch ($findNearestPointBy) {
1176
            case "x":
1177
            case "xy":
1178
            $this->findNearestPointBy = $findNearestPointBy;
1179
            break;
1180
        }
1181
        return $this;
1182
    }
1183
1184
    /**
1185
     * Set the get extremes from all.
1186
     *
1187
     * @param boolean $getExtremesFromAll The get extremes from all.
1188
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1189
     */
1190
    public function setGetExtremesFromAll($getExtremesFromAll) {
1191
        $this->getExtremesFromAll = $getExtremesFromAll;
1192
        return $this;
1193
    }
1194
1195
    /**
1196
     * Set the height.
1197
     *
1198
     * @param integer|string $height The height.
1199
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1200
     */
1201
    public function setHeight($height) {
1202
        $this->height = $height;
1203
        return $this;
1204
    }
1205
1206
    /**
1207
     * Set the id.
1208
     *
1209
     * @param string $id The id.
1210
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1211
     */
1212
    public function setId($id) {
1213
        $this->id = $id;
1214
        return $this;
1215
    }
1216
1217
    /**
1218
     * Set the index.
1219
     *
1220
     * @param integer $index The index.
1221
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1222
     */
1223
    public function setIndex($index) {
1224
        $this->index = $index;
1225
        return $this;
1226
    }
1227
1228
    /**
1229
     * Set the keys.
1230
     *
1231
     * @param array $keys The keys.
1232
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1233
     */
1234
    public function setKeys(array $keys = null) {
1235
        $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...
1236
        return $this;
1237
    }
1238
1239
    /**
1240
     * Set the legend index.
1241
     *
1242
     * @param integer $legendIndex The legend index.
1243
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1244
     */
1245
    public function setLegendIndex($legendIndex) {
1246
        $this->legendIndex = $legendIndex;
1247
        return $this;
1248
    }
1249
1250
    /**
1251
     * Set the linked to.
1252
     *
1253
     * @param string $linkedTo The linked to.
1254
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1255
     */
1256
    public function setLinkedTo($linkedTo) {
1257
        $this->linkedTo = $linkedTo;
1258
        return $this;
1259
    }
1260
1261
    /**
1262
     * Set the min size.
1263
     *
1264
     * @param integer $minSize The min size.
1265
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1266
     */
1267
    public function setMinSize($minSize) {
1268
        $this->minSize = $minSize;
1269
        return $this;
1270
    }
1271
1272
    /**
1273
     * Set the name.
1274
     *
1275
     * @param string $name The name.
1276
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1277
     */
1278
    public function setName($name) {
1279
        $this->name = $name;
1280
        return $this;
1281
    }
1282
1283
    /**
1284
     * Set the neck height.
1285
     *
1286
     * @param integer|string $neckHeight The neck height.
1287
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1288
     */
1289
    public function setNeckHeight($neckHeight) {
1290
        $this->neckHeight = $neckHeight;
1291
        return $this;
1292
    }
1293
1294
    /**
1295
     * Set the neck width.
1296
     *
1297
     * @param integer|string $neckWidth The neck width.
1298
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1299
     */
1300
    public function setNeckWidth($neckWidth) {
1301
        $this->neckWidth = $neckWidth;
1302
        return $this;
1303
    }
1304
1305
    /**
1306
     * Set the point.
1307
     *
1308
     * @param \WBW\Bundle\HighchartsBundle\API\Chart\Series\Funnel\HighchartsPoint $point The point.
1309
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1310
     */
1311
    public function setPoint(\WBW\Bundle\HighchartsBundle\API\Chart\Series\Funnel\HighchartsPoint $point = null) {
1312
        $this->point = $point;
1313
        return $this;
1314
    }
1315
1316
    /**
1317
     * Set the point description formatter.
1318
     *
1319
     * @param string $pointDescriptionFormatter The point description formatter.
1320
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1321
     */
1322
    public function setPointDescriptionFormatter($pointDescriptionFormatter) {
1323
        $this->pointDescriptionFormatter = $pointDescriptionFormatter;
1324
        return $this;
1325
    }
1326
1327
    /**
1328
     * Set the reversed.
1329
     *
1330
     * @param boolean $reversed The reversed.
1331
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1332
     */
1333
    public function setReversed($reversed) {
1334
        $this->reversed = $reversed;
1335
        return $this;
1336
    }
1337
1338
    /**
1339
     * Set the selected.
1340
     *
1341
     * @param boolean $selected The selected.
1342
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1343
     */
1344
    public function setSelected($selected) {
1345
        $this->selected = $selected;
1346
        return $this;
1347
    }
1348
1349
    /**
1350
     * Set the shadow.
1351
     *
1352
     * @param boolean|array $shadow The shadow.
1353
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1354
     */
1355
    public function setShadow($shadow) {
1356
        $this->shadow = $shadow;
1357
        return $this;
1358
    }
1359
1360
    /**
1361
     * Set the show in legend.
1362
     *
1363
     * @param boolean $showInLegend The show in legend.
1364
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1365
     */
1366
    public function setShowInLegend($showInLegend) {
1367
        $this->showInLegend = $showInLegend;
1368
        return $this;
1369
    }
1370
1371
    /**
1372
     * Set the skip keyboard navigation.
1373
     *
1374
     * @param boolean $skipKeyboardNavigation The skip keyboard navigation.
1375
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1376
     */
1377
    public function setSkipKeyboardNavigation($skipKeyboardNavigation) {
1378
        $this->skipKeyboardNavigation = $skipKeyboardNavigation;
1379
        return $this;
1380
    }
1381
1382
    /**
1383
     * Set the sliced offset.
1384
     *
1385
     * @param integer $slicedOffset The sliced offset.
1386
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1387
     */
1388
    public function setSlicedOffset($slicedOffset) {
1389
        $this->slicedOffset = $slicedOffset;
1390
        return $this;
1391
    }
1392
1393
    /**
1394
     * Set the states.
1395
     *
1396
     * @param \WBW\Bundle\HighchartsBundle\API\Chart\Series\Funnel\HighchartsStates $states The states.
1397
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1398
     */
1399
    public function setStates(\WBW\Bundle\HighchartsBundle\API\Chart\Series\Funnel\HighchartsStates $states = null) {
1400
        $this->states = $states;
1401
        return $this;
1402
    }
1403
1404
    /**
1405
     * Set the sticky tracking.
1406
     *
1407
     * @param boolean $stickyTracking The sticky tracking.
1408
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1409
     */
1410
    public function setStickyTracking($stickyTracking) {
1411
        $this->stickyTracking = $stickyTracking;
1412
        return $this;
1413
    }
1414
1415
    /**
1416
     * Set the tooltip.
1417
     *
1418
     * @param array $tooltip The tooltip.
1419
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1420
     */
1421
    public function setTooltip(array $tooltip = null) {
1422
        $this->tooltip = $tooltip;
0 ignored issues
show
Documentation Bug introduced by
It seems like $tooltip can be null. However, the property $tooltip 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...
1423
        return $this;
1424
    }
1425
1426
    /**
1427
     * Set the type.
1428
     *
1429
     * @param string $type The type.
1430
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1431
     */
1432
    public function setType($type) {
1433
        switch ($type) {
1434
            case null:
1435
            case "area":
1436
            case "arearange":
1437
            case "areaspline":
1438
            case "areasplinerange":
1439
            case "boxplot":
1440
            case "bubble":
1441
            case "column":
1442
            case "columnrange":
1443
            case "errorbar":
1444
            case "funnel":
1445
            case "gauge":
1446
            case "line":
1447
            case "pie":
1448
            case "scatter":
1449
            case "spline":
1450
            case "waterfall":
1451
            $this->type = $type;
1452
            break;
1453
        }
1454
        return $this;
1455
    }
1456
1457
    /**
1458
     * Set the visible.
1459
     *
1460
     * @param boolean $visible The visible.
1461
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1462
     */
1463
    public function setVisible($visible) {
1464
        $this->visible = $visible;
1465
        return $this;
1466
    }
1467
1468
    /**
1469
     * Set the width.
1470
     *
1471
     * @param integer|string $width The width.
1472
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1473
     */
1474
    public function setWidth($width) {
1475
        $this->width = $width;
1476
        return $this;
1477
    }
1478
1479
    /**
1480
     * Set the z index.
1481
     *
1482
     * @param integer $zIndex The z index.
1483
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1484
     */
1485
    public function setZIndex($zIndex) {
1486
        $this->zIndex = $zIndex;
1487
        return $this;
1488
    }
1489
1490
    /**
1491
     * Set the zone axis.
1492
     *
1493
     * @param string $zoneAxis The zone axis.
1494
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1495
     */
1496
    public function setZoneAxis($zoneAxis) {
1497
        $this->zoneAxis = $zoneAxis;
1498
        return $this;
1499
    }
1500
1501
    /**
1502
     * Set the zones.
1503
     *
1504
     * @param array $zones The zones.
1505
     * @return \WBW\Bundle\HighchartsBundle\API\Chart\Series\HighchartsFunnel Returns the highcharts funnel.
1506
     */
1507
    public function setZones(array $zones = null) {
1508
        $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...
1509
        return $this;
1510
    }
1511
1512
    /**
1513
     * Convert into an array representing this instance.
1514
     *
1515
     * @return array Returns an array representing this instance.
1516
     */
1517
    public function toArray() {
1518
1519
        // Initialize the output.
1520
        $output = [];
1521
1522
        // Set the allow point select.
1523
        ArrayUtility::set($output, "allowPointSelect", $this->allowPointSelect, [null]);
1524
1525
        // Set the animation limit.
1526
        ArrayUtility::set($output, "animationLimit", $this->animationLimit, [null]);
1527
1528
        // Set the border color.
1529
        ArrayUtility::set($output, "borderColor", $this->borderColor, [null]);
1530
1531
        // Set the border width.
1532
        ArrayUtility::set($output, "borderWidth", $this->borderWidth, [null]);
1533
1534
        // Set the center.
1535
        ArrayUtility::set($output, "center", $this->center, [null]);
1536
1537
        // Set the class name.
1538
        ArrayUtility::set($output, "className", $this->className, [null]);
1539
1540
        // Set the color index.
1541
        ArrayUtility::set($output, "colorIndex", $this->colorIndex, [null]);
1542
1543
        // Set the colors.
1544
        ArrayUtility::set($output, "colors", $this->colors, [null]);
1545
1546
        // Set the cursor.
1547
        ArrayUtility::set($output, "cursor", $this->cursor, [null]);
1548
1549
        // Set the data.
1550
        ArrayUtility::set($output, "data", $this->data, [null]);
1551
1552
        // Set the data labels.
1553
        if (null !== $this->dataLabels) {
1554
            ArrayUtility::set($output, "dataLabels", $this->dataLabels->toArray(), []);
1555
        }
1556
1557
        // Set the depth.
1558
        ArrayUtility::set($output, "depth", $this->depth, [null]);
1559
1560
        // Set the description.
1561
        ArrayUtility::set($output, "description", $this->description, [null]);
1562
1563
        // Set the enable mouse tracking.
1564
        ArrayUtility::set($output, "enableMouseTracking", $this->enableMouseTracking, [null]);
1565
1566
        // Set the events.
1567
        if (null !== $this->events) {
1568
            ArrayUtility::set($output, "events", $this->events->toArray(), []);
1569
        }
1570
1571
        // Set the expose element to a11y.
1572
        ArrayUtility::set($output, "exposeElementToA11y", $this->exposeElementToA11y, [null]);
1573
1574
        // Set the find nearest point by.
1575
        ArrayUtility::set($output, "findNearestPointBy", $this->findNearestPointBy, [null]);
1576
1577
        // Set the get extremes from all.
1578
        ArrayUtility::set($output, "getExtremesFromAll", $this->getExtremesFromAll, [null]);
1579
1580
        // Set the height.
1581
        ArrayUtility::set($output, "height", $this->height, [null]);
1582
1583
        // Set the id.
1584
        ArrayUtility::set($output, "id", $this->id, [null]);
1585
1586
        // Set the index.
1587
        ArrayUtility::set($output, "index", $this->index, [null]);
1588
1589
        // Set the keys.
1590
        ArrayUtility::set($output, "keys", $this->keys, [null]);
1591
1592
        // Set the legend index.
1593
        ArrayUtility::set($output, "legendIndex", $this->legendIndex, [null]);
1594
1595
        // Set the linked to.
1596
        ArrayUtility::set($output, "linkedTo", $this->linkedTo, [null]);
1597
1598
        // Set the min size.
1599
        ArrayUtility::set($output, "minSize", $this->minSize, [null]);
1600
1601
        // Set the name.
1602
        ArrayUtility::set($output, "name", $this->name, [null]);
1603
1604
        // Set the neck height.
1605
        ArrayUtility::set($output, "neckHeight", $this->neckHeight, [null]);
1606
1607
        // Set the neck width.
1608
        ArrayUtility::set($output, "neckWidth", $this->neckWidth, [null]);
1609
1610
        // Set the point.
1611
        if (null !== $this->point) {
1612
            ArrayUtility::set($output, "point", $this->point->toArray(), []);
1613
        }
1614
1615
        // Set the point description formatter.
1616
        ArrayUtility::set($output, "pointDescriptionFormatter", $this->pointDescriptionFormatter, [null]);
1617
1618
        // Set the reversed.
1619
        ArrayUtility::set($output, "reversed", $this->reversed, [null]);
1620
1621
        // Set the selected.
1622
        ArrayUtility::set($output, "selected", $this->selected, [null]);
1623
1624
        // Set the shadow.
1625
        ArrayUtility::set($output, "shadow", $this->shadow, [null]);
1626
1627
        // Set the show in legend.
1628
        ArrayUtility::set($output, "showInLegend", $this->showInLegend, [null]);
1629
1630
        // Set the skip keyboard navigation.
1631
        ArrayUtility::set($output, "skipKeyboardNavigation", $this->skipKeyboardNavigation, [null]);
1632
1633
        // Set the sliced offset.
1634
        ArrayUtility::set($output, "slicedOffset", $this->slicedOffset, [null]);
1635
1636
        // Set the states.
1637
        if (null !== $this->states) {
1638
            ArrayUtility::set($output, "states", $this->states->toArray(), []);
1639
        }
1640
1641
        // Set the sticky tracking.
1642
        ArrayUtility::set($output, "stickyTracking", $this->stickyTracking, [null]);
1643
1644
        // Set the tooltip.
1645
        ArrayUtility::set($output, "tooltip", $this->tooltip, [null]);
1646
1647
        // Set the type.
1648
        ArrayUtility::set($output, "type", $this->type, [null]);
1649
1650
        // Set the visible.
1651
        ArrayUtility::set($output, "visible", $this->visible, [null]);
1652
1653
        // Set the width.
1654
        ArrayUtility::set($output, "width", $this->width, [null]);
1655
1656
        // Set the z index.
1657
        ArrayUtility::set($output, "zIndex", $this->zIndex, [null]);
1658
1659
        // Set the zone axis.
1660
        ArrayUtility::set($output, "zoneAxis", $this->zoneAxis, [null]);
1661
1662
        // Set the zones.
1663
        ArrayUtility::set($output, "zones", $this->zones, [null]);
1664
1665
        // Return the output.
1666
        return $output;
1667
    }
1668
1669
}
1670