forked from dustin10/VichUploaderBundle
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathStorageInterface.php
More file actions
37 lines (33 loc) · 805 Bytes
/
StorageInterface.php
File metadata and controls
37 lines (33 loc) · 805 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
<?php
namespace Vich\UploaderBundle\Storage;
/**
* StorageInterface.
*
* @author Dustin Dobervich <ddobervich@gmail.com>
*/
interface StorageInterface
{
/**
* Uploads the files in the uploadable fields of the
* specified object according to the property configuration.
*
* @param object $obj The object.
*/
function upload($obj);
/**
* Removes the files associated with the object if configured to
* do so.
*
* @param object $obj The object.
*/
function remove($obj);
/**
* Resolves the path for a file based on the specified object
* and field name.
*
* @param object $obj The object.
* @param string $field The field.
* @return string The path.
*/
function resolvePath($obj, $field);
}