The related package code includes all namespaced code where the
package identifier
segments are a case-insensitive subset prefix of the namespace
segments. This
page explains the two possible code categories.
On This Page
Lazy
The lazy category includes all the code for class
, trait
, enum
, and
interface
that is loadable on demand by a registered autoloader.
Let's take Fusion as an example. Based on the package identifier
valvoid/fusion
, the exact subset prefix namespace
of the main entry class
is as follows:
// exact subset prefix
namespace Valvoid\Fusion;
class Fusion {}
In addition to the package source root example above, the nested metadata
builder trait
has a superset namespace
that starts with the identifier
prefix, as shown below:
// superset
// starts with subset prefix
namespace Valvoid\Fusion\Metadata;
trait Builder {}
ASAP
The as soon as possible (ASAP) category includes all the preload code wrapped by the
namespace
and function
keywords, which cannot be loaded by a registered autoloader.
While Fusion does not contain this category, an example would look like this:
// superset
// starts with subset prefix
namespace Valvoid\Fusion\Util\Something
{
function doSomething(): void {}
}