class PhpDocStorage (View source)

Storage for raw PhpDoc comments, separated from main entity data.

Provides lazy loading and efficient access to PhpDoc by entity ID.

Methods

__construct(string $pathToJsonFile, bool $loadExisting = true)

No description

string|null
getPhpDoc(string $entityId)

Get PhpDoc by entity ID

void
setPhpDoc(string $entityId, string|null $phpDoc)

Set PhpDoc for entity ID

bool
hasPhpDoc(string $entityId)

Check if PhpDoc exists for entity ID

array
getAllPhpDocs()

Get all PhpDocs (for debugging/testing)

void
save()

Save PhpDocs to JSON file

void
load()

Load PhpDocs from JSON file

void
clear()

Clear all PhpDocs (for testing)

Details

__construct(string $pathToJsonFile, bool $loadExisting = true)

No description

Parameters

string $pathToJsonFile
bool $loadExisting

string|null getPhpDoc(string $entityId)

Get PhpDoc by entity ID

Parameters

string $entityId

Return Value

string|null

void setPhpDoc(string $entityId, string|null $phpDoc)

Set PhpDoc for entity ID

Parameters

string $entityId
string|null $phpDoc

Return Value

void

bool hasPhpDoc(string $entityId)

Check if PhpDoc exists for entity ID

Parameters

string $entityId

Return Value

bool

array getAllPhpDocs()

Get all PhpDocs (for debugging/testing)

Return Value

array

void save()

Save PhpDocs to JSON file

Return Value

void

void load()

Load PhpDocs from JSON file

Return Value

void

void clear()

Clear all PhpDocs (for testing)

Return Value

void