4.2.31. Rename Class

Rename a class into another one.

The rename applies the new name to the class, and its usage : static calls, types, extends and instanceof.

4.2.31.1. Before

<?php
class x {}

function foo(x $a) {}

?>

4.2.31.2. After

<?php
class Y {}

function foo(Y $a) {}

?>

4.2.31.3. Parameters

Name

Default

Type

Description

origin

string

The class to rename

destination

string

The destination’s class name

4.2.31.4. Reverse Cobbler

4.2.31.5. Specs

Short Name

Classes/RenameClass

Exakat version

2.3.0

Available in