The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in BCP 14 [RFC2119] [RFC8174] when, and only when, they appear in all capitals, as shown here.
Covers functions matching ^get
. Requirements are as follows:
- MUST type-hint an appropriate return type, such as
string
orbool
. - MUST have exactly zero parameters.
- MUST NOT call
func_get_args()
, or otherwise accept input out-of-band (parameter list). - MUST NOT mutate any data in the class parameters (either this or parent).
Covers functions matching ^with
. Requirements are as follows:
- MUST exactly type-hint this return type:
self
- MUST have at-least one (1) parameter which SHOULD be type-hinted.
- MUST NOT call
func_get_args()
, or otherwise accept input out-of-band (parameter list). - MUST NOT mutate any data in the class parameters (either this or parent).
- MUST
clone $this
exactly once. - SHOULD do input verification of some kind, especially if the parameter wasn't type hinted.
Covers functions matching ^set
. Requirements are as follows:
- MUST exactly type-hint no return type (
void
). - MUST have at-least one (1) parameter which SHOULD be type-hinted.
- MUST NOT call
func_get_args()
, or otherwise accept input out-of-band (parameter list). - MUST mutate at-least one class parameter (either this or parent).
- SHOULD do input verification of some kind, especially if the parameter wasn't type hinted.
Covers functions matching ^is
, ^has
, ^was
, and ^did
. Requirements are as follows:
- MUST exactly type-hint this return type:
bool
. - MUST have exactly zero parameters.
- MUST NOT call
func_get_args()
, or otherwise accept input out-of-band (parameter list). - MUST NOT mutate any data in the class parameters (either this or parent).
- MUST read at-least one class parameter (either this or parent).