Functions are verbs. If they do some actions on the system, we use imperative verb. A single verb is preferred when possible. e.g.
$user->activate();
$order->confirm();
if the functions are handling and event just prefix the event name with on
.
$user->onFaiedLogin(); // it can be triggered by $user->login($parmas);
$order->onConfirm(); // it can be triggered by $order->confirm();
if the function returns a Boolean value and that is the result of an action (it has a dynamic nature) you can use none imprative form, most often simple past (expired), some times, continius present (expiring) and rarely times simple present (e.g. expires). e.g.
$user->validated(); // and not `isValid`
$order->confirmed(); // and not `isConfirmed`
$process->running();
If testing "ownership" of an attribute you can use "is + adjective" or "has + noun".
$user->isGeek();
$order->hasSurcharge();
use can use noune as an identifer for dynamic values when they are used as setter/getter.
$user->name(); // from the function signature its obvious that this is a getter.
$user->name("Reza"); // from the function signature its obvious that this is a setter.
We use adjective and nouns to name them.
if they are Boolean we use adjective or adverb
$user->happy=true; // and not "isHappy"
$order->expired; // and not "isExpired"
if not Boolean we use noun. e.g.
$user->name="Reza";
$user->height=175;
$order->tax=233;