Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
feeds
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
drupal.org
feeds
Commits
46d1119d
Commit
46d1119d
authored
9 years ago
by
megachriz
Committed by
MegaChriz
9 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Issue #2636342 by AndyF, MegaChriz: Improved documentation of FeedsConfigurable::__get().
parent
a885a625
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
includes/FeedsConfigurable.inc
+11
-2
11 additions, 2 deletions
includes/FeedsConfigurable.inc
with
11 additions
and
2 deletions
includes/FeedsConfigurable.inc
+
11
−
2
View file @
46d1119d
...
@@ -15,6 +15,10 @@ class FeedsNotExistingException extends Exception {
...
@@ -15,6 +15,10 @@ class FeedsNotExistingException extends Exception {
* Base class for configurable classes. Captures configuration handling, form
* Base class for configurable classes. Captures configuration handling, form
* handling and distinguishes between in-memory configuration and persistent
* handling and distinguishes between in-memory configuration and persistent
* configuration.
* configuration.
*
* Due to the magic method __get(), protected properties from this class and
* from classes that extend this class will be publicly readable (but not
* writeable).
*/
*/
abstract
class
FeedsConfigurable
{
abstract
class
FeedsConfigurable
{
...
@@ -139,8 +143,13 @@ abstract class FeedsConfigurable {
...
@@ -139,8 +143,13 @@ abstract class FeedsConfigurable {
}
}
/**
/**
* Override magic method __get(). Make sure that $this->config goes through
* Overrides magic method __get().
* getConfig().
*
* - Makes sure that external reads of FeedsConfigurable::config go through
* ::getConfig();
* - Makes private and protected properties from this class and protected
* properties from child classes publicly readable.
* - Prevents warnings when accessing non-existent properties.
*/
*/
public
function
__get
(
$name
)
{
public
function
__get
(
$name
)
{
if
(
$name
==
'config'
)
{
if
(
$name
==
'config'
)
{
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment