mirror of
https://github.com/DesignPatternsPHP/DesignPatternsPHP.git
synced 2025-07-26 01:31:20 +02:00
17 lines
323 B
PHP
17 lines
323 B
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
namespace DesignPatterns\Behavioral\Visitor;
|
|
|
|
/**
|
|
* Note: the visitor must not choose itself which method to
|
|
* invoke, it is the visited object that makes this decision
|
|
*/
|
|
interface RoleVisitor
|
|
{
|
|
public function visitUser(User $role);
|
|
|
|
public function visitGroup(Group $role);
|
|
}
|