# FileEntity

Implements \NPS\Entity\IEntity

File entity

author | Lukas Korinek
ORM\Entity |
ORM\Table | (name="`file`")
package | Default

### Methods

## __construct

    __construct()

## Constructs an object with a predefined set of properties Properties arrays contains keys of camel cased property names and their respective values

    create(array $properties) : self

inherited static

### Arguments

#### $properties

`array`

### Response

`self`

## Gets the ID

    getId() : integer

inherited

### Response

`integer`

### Properties

## dateCreated

    dateCreated : \DateTime

ORM\Column | (type="datetime", name="date_created", length=250, nullable=false)
var |

### Type(s)

`\DateTime`

## uploader

    uploader : \NPS\Entity\UserEntity

ORM\ManyToOne | (targetEntity="UserEntity")
ORM\JoinColumn | (name="user_id", referencedColumnName="id", nullable=true)
var |

### Type(s)

`\NPS\Entity\UserEntity`

## Web path to the file (not including base url which can vary)

    path : string

ORM\Column | (type="string", name="path", length=400, nullable=false)
var |

### Type(s)

`string`

## Real path to the file

    realpath : string

ORM\Column | (type="string", name="realpath", length=400, nullable=false)
var |

### Type(s)

`string`

## Original filename of the uploaded file

    filename : string

ORM\Column | (type="string", name="filename", length=400, nullable=false)
var |

### Type(s)

`string`

## Type of the file

    type : string

ORM\Column | (type="integer", name="type", nullable=false)
var |

### Type(s)

`string`

## File description / note

    note : string

ORM\Column | (type="text", name="note", length=400, nullable=true)
var |

### Type(s)

`string`

## Tags for the file entity, determining its purpose accross the app

    tags : array

ORM\Column | (type="simple_array", name="tags", nullable=false)
var |

### Type(s)

`array`

## id

    id :

inherited

ORM\Id |
ORM\Column | (type="integer", name="id")
ORM\GeneratedValue | (strategy="AUTO")

### Type(s)

``