Completed
Pull Request — master (#98)
by Christopher
05:13
created

Source::unsetContributor()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 4
Ratio 100 %

Importance

Changes 0
Metric Value
dl 4
loc 4
rs 10
c 0
b 0
f 0
cc 1
eloc 2
nc 1
nop 1
1
<?php
2
3
namespace AlgoWeb\ODataMetadata\Atom;
4
5
/**
6
 * Class representing Source
7
 */
8 View Code Duplication
class Source
0 ignored issues
show
Duplication introduced by
This class seems to be duplicated in your project.

Duplicated code is one of the most pungent code smells. If you need to duplicate the same code in three or more different places, we strongly encourage you to look into extracting the code into a single class or operation.

You can also find more detailed suggestions in the “Code” section of your repository.

Loading history...
9
{
10
11
    /**
12
     * @property string $base
13
     */
14
    private $base = null;
15
16
    /**
17
     * @property string $lang
18
     */
19
    private $lang = null;
20
21
    /**
22
     * @property \AlgoWeb\ODataMetadata\Atom\Author[] $author
23
     */
24
    private $author = array(
25
        
26
    );
27
28
    /**
29
     * @property \AlgoWeb\ODataMetadata\Atom\Category[] $category
30
     */
31
    private $category = array(
32
        
33
    );
34
35
    /**
36
     * @property \AlgoWeb\ODataMetadata\Atom\Contributor[] $contributor
37
     */
38
    private $contributor = array(
39
        
40
    );
41
42
    /**
43
     * @property \AlgoWeb\ODataMetadata\Atom\Generator[] $generator
44
     */
45
    private $generator = array(
46
        
47
    );
48
49
    /**
50
     * @property \AlgoWeb\ODataMetadata\Atom\Icon[] $icon
51
     */
52
    private $icon = array(
53
        
54
    );
55
56
    /**
57
     * @property \AlgoWeb\ODataMetadata\Atom\Id[] $id
58
     */
59
    private $id = array(
60
        
61
    );
62
63
    /**
64
     * @property \AlgoWeb\ODataMetadata\Atom\Link[] $link
65
     */
66
    private $link = array(
67
        
68
    );
69
70
    /**
71
     * @property \AlgoWeb\ODataMetadata\Atom\Logo[] $logo
72
     */
73
    private $logo = array(
74
        
75
    );
76
77
    /**
78
     * @property \AlgoWeb\ODataMetadata\Atom\Rights[] $rights
79
     */
80
    private $rights = array(
81
        
82
    );
83
84
    /**
85
     * @property \AlgoWeb\ODataMetadata\Atom\Subtitle[] $subtitle
86
     */
87
    private $subtitle = array(
88
        
89
    );
90
91
    /**
92
     * @property \AlgoWeb\ODataMetadata\Atom\Title[] $title
93
     */
94
    private $title = array(
95
        
96
    );
97
98
    /**
99
     * @property \AlgoWeb\ODataMetadata\Atom\Updated[] $updated
100
     */
101
    private $updated = array(
102
        
103
    );
104
105
    /**
106
     * Gets as base
107
     *
108
     * @return string
109
     */
110
    public function getBase()
111
    {
112
        return $this->base;
113
    }
114
115
    /**
116
     * Sets a new base
117
     *
118
     * @param string $base
119
     * @return self
120
     */
121
    public function setBase($base)
122
    {
123
        $this->base = $base;
124
        return $this;
125
    }
126
127
    /**
128
     * Gets as lang
129
     *
130
     * @return string
131
     */
132
    public function getLang()
133
    {
134
        return $this->lang;
135
    }
136
137
    /**
138
     * Sets a new lang
139
     *
140
     * @param string $lang
141
     * @return self
142
     */
143
    public function setLang($lang)
144
    {
145
        $this->lang = $lang;
146
        return $this;
147
    }
148
149
    /**
150
     * Adds as author
151
     *
152
     * @return self
153
     * @param \AlgoWeb\ODataMetadata\Atom\Author $author
154
     */
155
    public function addToAuthor(\AlgoWeb\ODataMetadata\Atom\Author $author)
156
    {
157
        $this->author[] = $author;
158
        return $this;
159
    }
160
161
    /**
162
     * isset author
163
     *
164
     * @param scalar $index
165
     * @return boolean
166
     */
167
    public function issetAuthor($index)
168
    {
169
        return isset($this->author[$index]);
170
    }
171
172
    /**
173
     * unset author
174
     *
175
     * @param scalar $index
176
     * @return void
177
     */
178
    public function unsetAuthor($index)
179
    {
180
        unset($this->author[$index]);
181
    }
182
183
    /**
184
     * Gets as author
185
     *
186
     * @return \AlgoWeb\ODataMetadata\Atom\Author[]
187
     */
188
    public function getAuthor()
189
    {
190
        return $this->author;
191
    }
192
193
    /**
194
     * Sets a new author
195
     *
196
     * @param \AlgoWeb\ODataMetadata\Atom\Author[] $author
197
     * @return self
198
     */
199
    public function setAuthor(array $author)
200
    {
201
        $this->author = $author;
202
        return $this;
203
    }
204
205
    /**
206
     * Adds as category
207
     *
208
     * @return self
209
     * @param \AlgoWeb\ODataMetadata\Atom\Category $category
210
     */
211
    public function addToCategory(\AlgoWeb\ODataMetadata\Atom\Category $category)
212
    {
213
        $this->category[] = $category;
214
        return $this;
215
    }
216
217
    /**
218
     * isset category
219
     *
220
     * @param scalar $index
221
     * @return boolean
222
     */
223
    public function issetCategory($index)
224
    {
225
        return isset($this->category[$index]);
226
    }
227
228
    /**
229
     * unset category
230
     *
231
     * @param scalar $index
232
     * @return void
233
     */
234
    public function unsetCategory($index)
235
    {
236
        unset($this->category[$index]);
237
    }
238
239
    /**
240
     * Gets as category
241
     *
242
     * @return \AlgoWeb\ODataMetadata\Atom\Category[]
243
     */
244
    public function getCategory()
245
    {
246
        return $this->category;
247
    }
248
249
    /**
250
     * Sets a new category
251
     *
252
     * @param \AlgoWeb\ODataMetadata\Atom\Category[] $category
253
     * @return self
254
     */
255
    public function setCategory(array $category)
256
    {
257
        $this->category = $category;
258
        return $this;
259
    }
260
261
    /**
262
     * Adds as contributor
263
     *
264
     * @return self
265
     * @param \AlgoWeb\ODataMetadata\Atom\Contributor $contributor
266
     */
267
    public function addToContributor(\AlgoWeb\ODataMetadata\Atom\Contributor $contributor)
268
    {
269
        $this->contributor[] = $contributor;
270
        return $this;
271
    }
272
273
    /**
274
     * isset contributor
275
     *
276
     * @param scalar $index
277
     * @return boolean
278
     */
279
    public function issetContributor($index)
280
    {
281
        return isset($this->contributor[$index]);
282
    }
283
284
    /**
285
     * unset contributor
286
     *
287
     * @param scalar $index
288
     * @return void
289
     */
290
    public function unsetContributor($index)
291
    {
292
        unset($this->contributor[$index]);
293
    }
294
295
    /**
296
     * Gets as contributor
297
     *
298
     * @return \AlgoWeb\ODataMetadata\Atom\Contributor[]
299
     */
300
    public function getContributor()
301
    {
302
        return $this->contributor;
303
    }
304
305
    /**
306
     * Sets a new contributor
307
     *
308
     * @param \AlgoWeb\ODataMetadata\Atom\Contributor[] $contributor
309
     * @return self
310
     */
311
    public function setContributor(array $contributor)
312
    {
313
        $this->contributor = $contributor;
314
        return $this;
315
    }
316
317
    /**
318
     * Adds as generator
319
     *
320
     * @return self
321
     * @param \AlgoWeb\ODataMetadata\Atom\Generator $generator
322
     */
323
    public function addToGenerator(\AlgoWeb\ODataMetadata\Atom\Generator $generator)
324
    {
325
        $this->generator[] = $generator;
326
        return $this;
327
    }
328
329
    /**
330
     * isset generator
331
     *
332
     * @param scalar $index
333
     * @return boolean
334
     */
335
    public function issetGenerator($index)
336
    {
337
        return isset($this->generator[$index]);
338
    }
339
340
    /**
341
     * unset generator
342
     *
343
     * @param scalar $index
344
     * @return void
345
     */
346
    public function unsetGenerator($index)
347
    {
348
        unset($this->generator[$index]);
349
    }
350
351
    /**
352
     * Gets as generator
353
     *
354
     * @return \AlgoWeb\ODataMetadata\Atom\Generator[]
355
     */
356
    public function getGenerator()
357
    {
358
        return $this->generator;
359
    }
360
361
    /**
362
     * Sets a new generator
363
     *
364
     * @param \AlgoWeb\ODataMetadata\Atom\Generator[] $generator
365
     * @return self
366
     */
367
    public function setGenerator(array $generator)
368
    {
369
        $this->generator = $generator;
370
        return $this;
371
    }
372
373
    /**
374
     * Adds as icon
375
     *
376
     * @return self
377
     * @param \AlgoWeb\ODataMetadata\Atom\Icon $icon
378
     */
379
    public function addToIcon(\AlgoWeb\ODataMetadata\Atom\Icon $icon)
380
    {
381
        $this->icon[] = $icon;
382
        return $this;
383
    }
384
385
    /**
386
     * isset icon
387
     *
388
     * @param scalar $index
389
     * @return boolean
390
     */
391
    public function issetIcon($index)
392
    {
393
        return isset($this->icon[$index]);
394
    }
395
396
    /**
397
     * unset icon
398
     *
399
     * @param scalar $index
400
     * @return void
401
     */
402
    public function unsetIcon($index)
403
    {
404
        unset($this->icon[$index]);
405
    }
406
407
    /**
408
     * Gets as icon
409
     *
410
     * @return \AlgoWeb\ODataMetadata\Atom\Icon[]
411
     */
412
    public function getIcon()
413
    {
414
        return $this->icon;
415
    }
416
417
    /**
418
     * Sets a new icon
419
     *
420
     * @param \AlgoWeb\ODataMetadata\Atom\Icon[] $icon
421
     * @return self
422
     */
423
    public function setIcon(array $icon)
424
    {
425
        $this->icon = $icon;
426
        return $this;
427
    }
428
429
    /**
430
     * Adds as id
431
     *
432
     * @return self
433
     * @param \AlgoWeb\ODataMetadata\Atom\Id $id
434
     */
435
    public function addToId(\AlgoWeb\ODataMetadata\Atom\Id $id)
436
    {
437
        $this->id[] = $id;
438
        return $this;
439
    }
440
441
    /**
442
     * isset id
443
     *
444
     * @param scalar $index
445
     * @return boolean
446
     */
447
    public function issetId($index)
448
    {
449
        return isset($this->id[$index]);
450
    }
451
452
    /**
453
     * unset id
454
     *
455
     * @param scalar $index
456
     * @return void
457
     */
458
    public function unsetId($index)
459
    {
460
        unset($this->id[$index]);
461
    }
462
463
    /**
464
     * Gets as id
465
     *
466
     * @return \AlgoWeb\ODataMetadata\Atom\Id[]
467
     */
468
    public function getId()
469
    {
470
        return $this->id;
471
    }
472
473
    /**
474
     * Sets a new id
475
     *
476
     * @param \AlgoWeb\ODataMetadata\Atom\Id[] $id
477
     * @return self
478
     */
479
    public function setId(array $id)
480
    {
481
        $this->id = $id;
482
        return $this;
483
    }
484
485
    /**
486
     * Adds as link
487
     *
488
     * @return self
489
     * @param \AlgoWeb\ODataMetadata\Atom\Link $link
490
     */
491
    public function addToLink(\AlgoWeb\ODataMetadata\Atom\Link $link)
492
    {
493
        $this->link[] = $link;
494
        return $this;
495
    }
496
497
    /**
498
     * isset link
499
     *
500
     * @param scalar $index
501
     * @return boolean
502
     */
503
    public function issetLink($index)
504
    {
505
        return isset($this->link[$index]);
506
    }
507
508
    /**
509
     * unset link
510
     *
511
     * @param scalar $index
512
     * @return void
513
     */
514
    public function unsetLink($index)
515
    {
516
        unset($this->link[$index]);
517
    }
518
519
    /**
520
     * Gets as link
521
     *
522
     * @return \AlgoWeb\ODataMetadata\Atom\Link[]
523
     */
524
    public function getLink()
525
    {
526
        return $this->link;
527
    }
528
529
    /**
530
     * Sets a new link
531
     *
532
     * @param \AlgoWeb\ODataMetadata\Atom\Link[] $link
533
     * @return self
534
     */
535
    public function setLink(array $link)
536
    {
537
        $this->link = $link;
538
        return $this;
539
    }
540
541
    /**
542
     * Adds as logo
543
     *
544
     * @return self
545
     * @param \AlgoWeb\ODataMetadata\Atom\Logo $logo
546
     */
547
    public function addToLogo(\AlgoWeb\ODataMetadata\Atom\Logo $logo)
548
    {
549
        $this->logo[] = $logo;
550
        return $this;
551
    }
552
553
    /**
554
     * isset logo
555
     *
556
     * @param scalar $index
557
     * @return boolean
558
     */
559
    public function issetLogo($index)
560
    {
561
        return isset($this->logo[$index]);
562
    }
563
564
    /**
565
     * unset logo
566
     *
567
     * @param scalar $index
568
     * @return void
569
     */
570
    public function unsetLogo($index)
571
    {
572
        unset($this->logo[$index]);
573
    }
574
575
    /**
576
     * Gets as logo
577
     *
578
     * @return \AlgoWeb\ODataMetadata\Atom\Logo[]
579
     */
580
    public function getLogo()
581
    {
582
        return $this->logo;
583
    }
584
585
    /**
586
     * Sets a new logo
587
     *
588
     * @param \AlgoWeb\ODataMetadata\Atom\Logo[] $logo
589
     * @return self
590
     */
591
    public function setLogo(array $logo)
592
    {
593
        $this->logo = $logo;
594
        return $this;
595
    }
596
597
    /**
598
     * Adds as rights
599
     *
600
     * @return self
601
     * @param \AlgoWeb\ODataMetadata\Atom\Rights $rights
602
     */
603
    public function addToRights(\AlgoWeb\ODataMetadata\Atom\Rights $rights)
604
    {
605
        $this->rights[] = $rights;
606
        return $this;
607
    }
608
609
    /**
610
     * isset rights
611
     *
612
     * @param scalar $index
613
     * @return boolean
614
     */
615
    public function issetRights($index)
616
    {
617
        return isset($this->rights[$index]);
618
    }
619
620
    /**
621
     * unset rights
622
     *
623
     * @param scalar $index
624
     * @return void
625
     */
626
    public function unsetRights($index)
627
    {
628
        unset($this->rights[$index]);
629
    }
630
631
    /**
632
     * Gets as rights
633
     *
634
     * @return \AlgoWeb\ODataMetadata\Atom\Rights[]
635
     */
636
    public function getRights()
637
    {
638
        return $this->rights;
639
    }
640
641
    /**
642
     * Sets a new rights
643
     *
644
     * @param \AlgoWeb\ODataMetadata\Atom\Rights[] $rights
645
     * @return self
646
     */
647
    public function setRights(array $rights)
648
    {
649
        $this->rights = $rights;
650
        return $this;
651
    }
652
653
    /**
654
     * Adds as subtitle
655
     *
656
     * @return self
657
     * @param \AlgoWeb\ODataMetadata\Atom\Subtitle $subtitle
658
     */
659
    public function addToSubtitle(\AlgoWeb\ODataMetadata\Atom\Subtitle $subtitle)
660
    {
661
        $this->subtitle[] = $subtitle;
662
        return $this;
663
    }
664
665
    /**
666
     * isset subtitle
667
     *
668
     * @param scalar $index
669
     * @return boolean
670
     */
671
    public function issetSubtitle($index)
672
    {
673
        return isset($this->subtitle[$index]);
674
    }
675
676
    /**
677
     * unset subtitle
678
     *
679
     * @param scalar $index
680
     * @return void
681
     */
682
    public function unsetSubtitle($index)
683
    {
684
        unset($this->subtitle[$index]);
685
    }
686
687
    /**
688
     * Gets as subtitle
689
     *
690
     * @return \AlgoWeb\ODataMetadata\Atom\Subtitle[]
691
     */
692
    public function getSubtitle()
693
    {
694
        return $this->subtitle;
695
    }
696
697
    /**
698
     * Sets a new subtitle
699
     *
700
     * @param \AlgoWeb\ODataMetadata\Atom\Subtitle[] $subtitle
701
     * @return self
702
     */
703
    public function setSubtitle(array $subtitle)
704
    {
705
        $this->subtitle = $subtitle;
706
        return $this;
707
    }
708
709
    /**
710
     * Adds as title
711
     *
712
     * @return self
713
     * @param \AlgoWeb\ODataMetadata\Atom\Title $title
714
     */
715
    public function addToTitle(\AlgoWeb\ODataMetadata\Atom\Title $title)
716
    {
717
        $this->title[] = $title;
718
        return $this;
719
    }
720
721
    /**
722
     * isset title
723
     *
724
     * @param scalar $index
725
     * @return boolean
726
     */
727
    public function issetTitle($index)
728
    {
729
        return isset($this->title[$index]);
730
    }
731
732
    /**
733
     * unset title
734
     *
735
     * @param scalar $index
736
     * @return void
737
     */
738
    public function unsetTitle($index)
739
    {
740
        unset($this->title[$index]);
741
    }
742
743
    /**
744
     * Gets as title
745
     *
746
     * @return \AlgoWeb\ODataMetadata\Atom\Title[]
747
     */
748
    public function getTitle()
749
    {
750
        return $this->title;
751
    }
752
753
    /**
754
     * Sets a new title
755
     *
756
     * @param \AlgoWeb\ODataMetadata\Atom\Title[] $title
757
     * @return self
758
     */
759
    public function setTitle(array $title)
760
    {
761
        $this->title = $title;
762
        return $this;
763
    }
764
765
    /**
766
     * Adds as updated
767
     *
768
     * @return self
769
     * @param \AlgoWeb\ODataMetadata\Atom\Updated $updated
770
     */
771
    public function addToUpdated(\AlgoWeb\ODataMetadata\Atom\Updated $updated)
772
    {
773
        $this->updated[] = $updated;
774
        return $this;
775
    }
776
777
    /**
778
     * isset updated
779
     *
780
     * @param scalar $index
781
     * @return boolean
782
     */
783
    public function issetUpdated($index)
784
    {
785
        return isset($this->updated[$index]);
786
    }
787
788
    /**
789
     * unset updated
790
     *
791
     * @param scalar $index
792
     * @return void
793
     */
794
    public function unsetUpdated($index)
795
    {
796
        unset($this->updated[$index]);
797
    }
798
799
    /**
800
     * Gets as updated
801
     *
802
     * @return \AlgoWeb\ODataMetadata\Atom\Updated[]
803
     */
804
    public function getUpdated()
805
    {
806
        return $this->updated;
807
    }
808
809
    /**
810
     * Sets a new updated
811
     *
812
     * @param \AlgoWeb\ODataMetadata\Atom\Updated[] $updated
813
     * @return self
814
     */
815
    public function setUpdated(array $updated)
816
    {
817
        $this->updated = $updated;
818
        return $this;
819
    }
820
}
821