# Interface CRUDFileProcessorInterface

This interface is used to handle file uploads.

#### Direct known implementers

CRUDlex\CRUDSimpleFilesystemFileProcessor
Namespace: CRUDlex
Located at CRUDFileProcessorInterface.php

Methods summary
`public` | # `createFile( Symfony\Component\HttpFoundation\Request $request, `CRUDlex\CRUDEntity` $entity, string $entityName, string $field )` Creates the uploaded file of a newly created entity. Creates the uploaded file of a newly created entity. #### Parameters $request the HTTP request containing the file data $entity the just created entity $entityName the name of the entity as this class here is not aware of it $field the file field
`public` | # `updateFile( Symfony\Component\HttpFoundation\Request $request, `CRUDlex\CRUDEntity` $entity, string $entityName, string $field )` Updates the uploaded file of an updated entity. Updates the uploaded file of an updated entity. #### Parameters $request the HTTP request containing the file data $entity the updated entity $entityName the name of the entity as this class here is not aware of it $field the file field
`public` | # `deleteFile( `CRUDlex\CRUDEntity` $entity, string $entityName, string $field )` Deletes a specific file from an existing entity. Deletes a specific file from an existing entity. #### Parameters $entity the entity to delete the file from $entityName the name of the entity as this class here is not aware of it $field the field of the entity containing the file to be deleted
`public Response` | # `renderFile( `CRUDlex\CRUDEntity` $entity, string $entityName, string $field )` Renders (outputs) a file of an entity. This includes setting headers like the file size, mimetype and name, too. Renders (outputs) a file of an entity. This includes setting headers like the file size, mimetype and name, too. #### Parameters $entity the entity to render the file from $entityName the name of the entity as this class here is not aware of it $field the field of the entity containing the file to be rendered #### Returns `Response` the HTTP response, likely to be a streamed one