Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
D
drupal
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Custom Issue Tracker
Custom Issue Tracker
Labels
Merge Requests
224
Merge Requests
224
Requirements
Requirements
List
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Analytics
Analytics
Code Review
Insights
Issue
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
project
drupal
Commits
94b0b70f
Commit
94b0b70f
authored
Jun 18, 2013
by
alexpott
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Issue
#2018323
by effulgentsia, yched: Make TypedData implement PluginInspectionInterface.
parent
9ee90ca1
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
1 deletion
+17
-1
core/lib/Drupal/Core/TypedData/TypedData.php
core/lib/Drupal/Core/TypedData/TypedData.php
+17
-1
No files found.
core/lib/Drupal/Core/TypedData/TypedData.php
View file @
94b0b70f
...
...
@@ -7,13 +7,15 @@
namespace
Drupal\Core\TypedData
;
use
Drupal\Component\Plugin\PluginInspectionInterface
;
/**
* The abstract base class for typed data.
*
* Classes deriving from this base class have to declare $value
* or override getValue() or setValue().
*/
abstract
class
TypedData
implements
TypedDataInterface
{
abstract
class
TypedData
implements
TypedDataInterface
,
PluginInspectionInterface
{
/**
* The data definition.
...
...
@@ -63,6 +65,20 @@ public function getType() {
return
$this
->
definition
[
'type'
];
}
/**
* {@inheritdoc}
*/
public
function
getPluginId
()
{
return
$this
->
definition
[
'type'
];
}
/**
* {@inheritdoc}
*/
public
function
getPluginDefinition
()
{
return
\
Drupal
::
typedData
()
->
getDefinition
(
$this
->
definition
[
'type'
]);
}
/**
* Implements \Drupal\Core\TypedData\TypedDataInterface::getDefinition().
*/
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment