File tree Expand file tree Collapse file tree 5 files changed +31
-8
lines changed
Resources/config/doctrine-model Expand file tree Collapse file tree 5 files changed +31
-8
lines changed Original file line number Diff line number Diff line change 1
1
Changelog
2
2
=========
3
3
4
+ * ** 2013-07-26** : [ Model] Deprecated setRouteContent and getRouteContent, use setContent and getContent instead.
4
5
* ** 2013-07-19** : [ Model] Separated database agnostic, doctrine generic and
5
6
PHPCR-ODM specific code to prepare for Doctrine ORM support.
6
7
* ** 2013-07-17** : [ FormType] Moved TermsFormType to CoreBundle and renamed it to CheckboxUrlLableFormType
Original file line number Diff line number Diff line change @@ -45,15 +45,15 @@ class RedirectRoute extends Route implements RedirectRouteInterface
45
45
*
46
46
* @throws LogicException
47
47
*/
48
- public function setRouteContent ($ document )
48
+ public function setContent ($ document )
49
49
{
50
50
throw new LogicException ('Do not set a content for the redirect route. It is its own content. ' );
51
51
}
52
52
53
53
/**
54
54
* {@inheritDoc}
55
55
*/
56
- public function getRouteContent ()
56
+ public function getContent ()
57
57
{
58
58
return $ this ;
59
59
}
Original file line number Diff line number Diff line change @@ -25,7 +25,7 @@ class Route extends SymfonyRoute implements RouteObjectInterface
25
25
*
26
26
* @var object
27
27
*/
28
- protected $ routeContent ;
28
+ protected $ content ;
29
29
30
30
/**
31
31
* Part of the URL that does not have parameters and thus can be used to
@@ -116,11 +116,22 @@ public function setStaticPrefix($prefix)
116
116
}
117
117
118
118
/**
119
- * Set the object this url points to
119
+ * @deprecated use setContent instead
120
120
*/
121
121
public function setRouteContent ($ object )
122
122
{
123
- $ this ->routeContent = $ object ;
123
+ $ this ->setContent ($ object );
124
+ }
125
+
126
+ /**
127
+ * Set the object this url points to
128
+ *
129
+ * @param mixed $object A content object that can be persisted by the
130
+ * storage layer.
131
+ */
132
+ public function setContent ($ object )
133
+ {
134
+ $ this ->content = $ object ;
124
135
125
136
return $ this ;
126
137
}
@@ -130,7 +141,15 @@ public function setRouteContent($object)
130
141
*/
131
142
public function getRouteContent ()
132
143
{
133
- return $ this ->routeContent ;
144
+ return $ this ->getContent ();
145
+ }
146
+
147
+ /**
148
+ * {@inheritDoc}
149
+ */
150
+ public function getContent ()
151
+ {
152
+ return $ this ->content ;
134
153
}
135
154
136
155
/**
Original file line number Diff line number Diff line change 9
9
<mapped-superclass name =" Symfony\Cmf\Bundle\RoutingBundle\Model\Route" referenceable =" true" >
10
10
<field name =" variablePattern" type =" string" />
11
11
<field name =" addFormatPattern" type =" boolean" />
12
- <reference-one name =" routeContent" />
12
+ <reference-one name =" content " property = " routeContent" />
13
13
</mapped-superclass >
14
14
15
15
</doctrine-mapping >
Original file line number Diff line number Diff line change @@ -16,4 +16,7 @@ PHPCR specific configurations moved into
16
16
17
17
You need to at least set ` phpcr_provider: ~ ` to have the PHPCR provider loaded.
18
18
19
- Dropped redundant unused ` routing_repositoryroot ` configuration.
19
+ Dropped redundant unused ` routing_repositoryroot ` configuration.
20
+
21
+ Deprecated the setRouteContent and getRouteContent methods. Use setContent and
22
+ getContent instead.
You can’t perform that action at this time.
0 commit comments