Passed
Pull Request — master (#631)
by ANTHONIUS
08:16
created

File::getMetadata()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 1
Metric Value
eloc 1
dl 0
loc 3
rs 10
c 1
b 0
f 1
cc 1
nc 1
nop 0
1
<?php
2
3
declare(strict_types=1);
4
5
namespace Core\Entity;
6
7
use Doctrine\ODM\MongoDB\Mapping\Annotations as ODM;
8
9
/**
10
 * Class File
11
 *
12
 * @author Anthonius Munthi <[email protected]>
13
 * @since 0.36
14
 * @package Core\Entity
15
 */
16
abstract class File implements FileInterface
17
{
18
    use FileTrait;
19
20
    /**
21
     * @ODM\File\Metadata(targetDocument="Core\Entity\FileMetadata")
22
     */
23
    protected FileMetadataInterface $metadata;
24
25
    public function setMetadata(FileMetadataInterface $metadata)
26
    {
27
        $this->metadata = $metadata;
28
        return $this;
29
    }
30
31
    public function getMetadata()
32
    {
33
        return $this->metadata;
34
    }
35
}