-
Notifications
You must be signed in to change notification settings - Fork 7
Expand file tree
/
Copy pathConnectionInterface.php
More file actions
67 lines (57 loc) · 1.54 KB
/
ConnectionInterface.php
File metadata and controls
67 lines (57 loc) · 1.54 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
66
67
<?php
namespace Kitano\ConnectionBundle\Model;
interface ConnectionInterface
{
const DIRECTION_ONE_WAY = 'one-way';
const DIRECTION_TWO_WAYS = 'two-ways';
/**
* Returns the Node from where the Connection (edge) start
*
* @return \Kitano\ConnectionBundle\Model\NodeInterface
*/
public function getSource();
/**
* Sets the Node from where the Connection start
*
* @param NodeInterface $node
*/
public function setSource(NodeInterface $node);
/**
* Returns the Node to which the Connection is directed
*
* @return \Kitano\ConnectionBundle\Model\NodeInterface
*/
public function getDestination();
/**
* Sets the Node to which the Connection is directed
*
* @param NodeInterface $node
*/
public function setDestination(NodeInterface $node);
/**
* Returns the "type" of this connection (user defined)
* This type is used to identify the kind of connection which is linking a Node
* to another (i.e: "like", "follow", ...)
*
* @return mixed
*/
public function getType();
/**
* Sets the connection type
*
* @param string $type
*/
public function setType($type);
/**
* Returns the date the connection was initially created at
*
* @return \DateTime
*/
public function getCreatedAt();
/**
* Set the date the connection was initially created at
*
* @param \DateTime $createdAt
*/
public function setCreatedAt(\DateTime $createdAt);
}