Page MenuHomeDevCentral

Get class name with or without namespace
ClosedPublic

Authored by dereckson on Jun 30 2023, 21:49.
Tags
None
Referenced Files
Unknown Object (File)
Fri, May 1, 02:02
Unknown Object (File)
Tue, Apr 28, 12:40
Unknown Object (File)
Tue, Apr 28, 06:44
Unknown Object (File)
Mon, Apr 27, 20:13
Unknown Object (File)
Sun, Apr 26, 07:36
Unknown Object (File)
Thu, Apr 23, 08:27
Unknown Object (File)
Sun, Apr 19, 16:46
Unknown Object (File)
Sun, Apr 19, 04:05
Subscribers
None

Details

Summary
  • CodeClass::getClassName allows to get class name with namespace
  • CodeClass::getShortClassName returns only the class name
Test Plan

This is used in Zed for XmlDocument serialization:

$key = CodeClass::from($value)->getShortClassName();

Unit tests provided.

Diff Detail

Repository
rKERUALD Keruald libraries development repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

dereckson created this revision.

Remove from static constructor

This revision is now accepted and ready to land.Jun 30 2023, 21:53