CakePHP
  • Documentation
    • Book
    • API
    • Videos
    • Logos & Trademarks
  • Business Solutions
  • Swag
  • Road Trip
  • Team
  • Community
    • Community
    • Team
    • Issues (Github)
    • YouTube Channel
    • Get Involved
    • Bakery
    • Featured Resources
    • Newsletter
    • Certification
    • My CakePHP
    • CakeFest
    • Facebook
    • Twitter
    • Help & Support
    • Forum
    • Stack Overflow
    • IRC
    • Slack
    • Paid Support
CakePHP

C CakePHP 3.8 Red Velvet API

  • Overview
  • Tree
  • Deprecated
  • Version:
    • 3.8
      • 3.8
      • 3.7
      • 3.6
      • 3.5
      • 3.4
      • 3.3
      • 3.2
      • 3.1
      • 3.0
      • 2.10
      • 2.9
      • 2.8
      • 2.7
      • 2.6
      • 2.5
      • 2.4
      • 2.3
      • 2.2
      • 2.1
      • 2.0
      • 1.3
      • 1.2

Namespaces

  • Cake
    • Auth
      • Storage
    • Cache
      • Engine
    • Collection
      • Iterator
    • Command
    • Console
      • Exception
    • Controller
      • Component
      • Exception
    • Core
      • Configure
        • Engine
      • Exception
      • Retry
    • Database
      • Driver
      • Exception
      • Expression
      • Schema
      • Statement
      • Type
    • Datasource
      • Exception
    • Error
      • Middleware
    • Event
      • Decorator
    • Filesystem
    • Form
    • Http
      • Client
        • Adapter
        • Auth
      • Cookie
      • Exception
      • Middleware
      • Session
    • I18n
      • Formatter
      • Middleware
      • Parser
    • Log
      • Engine
    • Mailer
      • Exception
      • Transport
    • Network
      • Exception
    • ORM
      • Association
      • Behavior
        • Translate
      • Exception
      • Locator
      • Rule
    • Routing
      • Exception
      • Filter
      • Middleware
      • Route
    • Shell
      • Helper
      • Task
    • TestSuite
      • Fixture
      • Stub
    • Utility
      • Exception
    • Validation
    • View
      • Exception
      • Form
      • Helper
      • Widget
  • None

Classes

  • Hash
  • Inflector
  • Security
  • Text
  • Xml

Traits

  • CookieCryptTrait
  • MergeVariablesTrait

Trait MergeVariablesTrait

Provides features for merging object properties recursively with parent classes.

Direct Users

  • Cake\Console\Shell
  • Cake\Controller\Controller

Indirect Users

  • Cake\Controller\ErrorController
  • Cake\Shell\CacheShell
  • Cake\Shell\Task\AssetsTask
  • Cake\Shell\Task\CommandTask
  • Cake\Shell\Task\ExtractTask
  • Cake\Shell\Task\LoadTask
  • Cake\Shell\Task\UnloadTask
  • Cake\Shell\CommandListShell
  • Cake\Shell\CompletionShell
  • Cake\Shell\I18nShell
  • Cake\Shell\OrmCacheShell
  • Cake\Shell\PluginShell
  • Cake\Shell\RoutesShell
  • Cake\Shell\SchemaCacheShell
  • Cake\Shell\ServerShell
Namespace: Cake\Utility
Location: Utility/MergeVariablesTrait.php

Method Summary

  • _mergeProperty() protected
    Merge a single property with the values declared in all parent classes.
  • _mergePropertyData() protected
    Merge each of the keys in a property together.
  • _mergeVars() protected
    Merge the list of $properties with all parent classes of the current class.

Method Detail

_mergeProperty() protected ¶

_mergeProperty( string $property , array $parentClasses , array $options )

Merge a single property with the values declared in all parent classes.

Parameters
string $property
The name of the property being merged.
array $parentClasses
An array of classes you want to merge with.
array $options
Options for merging the property, see _mergeVars()

_mergePropertyData() protected ¶

_mergePropertyData( array $current , array $parent , boolean $isAssoc )

Merge each of the keys in a property together.

Parameters
array $current
The current merged value.
array $parent
The parent class' value.
boolean $isAssoc
Whether or not the merging should be done in associative mode.
Returns
mixed
The updated value.

_mergeVars() protected ¶

_mergeVars( string[] $properties , array $options = [] )

Merge the list of $properties with all parent classes of the current class.

Options:

  • associative - A list of properties that should be treated as associative arrays. Properties in this list will be passed through Hash::normalize() before merging.
Parameters
string[] $properties
An array of properties and the merge strategy for them.
array $options optional []
The options to use when merging properties.
Follow @CakePHP
#IRC
OpenHub
Rackspace
  • Business Solutions
  • Showcase
  • Documentation
  • Book
  • API
  • Videos
  • Logos & Trademarks
  • Community
  • Team
  • Issues (Github)
  • YouTube Channel
  • Get Involved
  • Bakery
  • Featured Resources
  • Newsletter
  • Certification
  • My CakePHP
  • CakeFest
  • Facebook
  • Twitter
  • Help & Support
  • Forum
  • Stack Overflow
  • IRC
  • Slack
  • Paid Support

Generated using CakePHP API Docs