Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. ClassPatchInterface.php

interface ClassPatchInterface

Class patch interface. Class patches extend doubles functionality or help Prophecy to avoid some internal PHP bugs.

@author Konstantin Kudryashov <ever.zet@gmail.com>

Hierarchy

  • interface \Prophecy\Doubler\ClassPatch\ClassPatchInterface

Expanded class hierarchy of ClassPatchInterface

All classes that implement ClassPatchInterface

1 file declares its use of ClassPatchInterface
Doubler.php in vendor/phpspec/prophecy/src/Prophecy/Doubler/Doubler.php

File

vendor/phpspec/prophecy/src/Prophecy/Doubler/ClassPatch/ClassPatchInterface.php, line 23

Namespace

Prophecy\Doubler\ClassPatch
View source
interface ClassPatchInterface {
    
    /**
     * Checks if patch supports specific class node.
     *
     * @param ClassNode $node
     *
     * @return bool
     */
    public function supports(ClassNode $node);
    
    /**
     * Applies patch to the specific class node.
     *
     * @param ClassNode $node
     * @return void
     */
    public function apply(ClassNode $node);
    
    /**
     * Returns patch priority, which determines when patch will be applied.
     *
     * @return int Priority number (higher - earlier)
     */
    public function getPriority();

}

Members

Title Sort descending Modifiers Object type Summary Overrides
ClassPatchInterface::apply public function Applies patch to the specific class node. 8
ClassPatchInterface::getPriority public function Returns patch priority, which determines when patch will be applied. 8
ClassPatchInterface::supports public function Checks if patch supports specific class node. 8
RSS feed
Powered by Drupal