-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathResourceInterface.php
More file actions
65 lines (61 loc) · 1.58 KB
/
ResourceInterface.php
File metadata and controls
65 lines (61 loc) · 1.58 KB
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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
<?php
/**
* Resource Interface
*
* @package Resource
* @copyright 2014 Amy Stephen. All rights reserved.
* @license http://www.opensource.org/licenses/mit-license.html MIT License
*/
namespace CommonApi\Resource;
/**
* Resource Interface
*
* @package Resource
* @copyright 2014 Amy Stephen. All rights reserved.
* @license http://www.opensource.org/licenses/mit-license.html MIT License
* @since 1.0.0
*/
interface ResourceInterface
{
/**
* Set namespace prefix by mapping to the filesystem path
*
* @param string $namespace_prefix
* @param string $namespace_base_directory
* @param boolean $prepend
*
* @return $this
* @since 1.0.0
*/
public function setNamespace($namespace_prefix, $namespace_base_directory, $prepend = false);
/**
* Verify if resource namespace is defined
*
* @param string $resource_namespace
* @param array $options
*
* @return boolean
* @since 1.0.0
*/
public function exists($resource_namespace, array $options = array());
/**
* Get resource associated with namespace
*
* @param string $resource_namespace
* @param array $options
*
* @return void|mixed
* @since 1.0.0
*/
public function get($resource_namespace, array $options = array());
/**
* Retrieve collection for scheme
*
* @param string $scheme
* @param array $options
*
* @return mixed
* @since 1.0.0
*/
public function getCollection($scheme, array $options = array());
}