Page MenuHomePhabricator

Simplify the implementation of `PhabricatorPHIDType` subclasses
ClosedPublic

Authored by joshuaspence on Jul 19 2014, 6:35 AM.
Tags
None
Referenced Files
F14838060: D9985.diff
Fri, Jan 31, 1:15 PM
F14837977: D9985.id23994.diff
Fri, Jan 31, 12:42 PM
F14836179: D9985.id.diff
Fri, Jan 31, 12:52 AM
Unknown Object (File)
Tue, Jan 28, 8:36 AM
Unknown Object (File)
Tue, Jan 28, 12:57 AM
Unknown Object (File)
Mon, Jan 27, 6:58 AM
Unknown Object (File)
Wed, Jan 22, 7:55 PM
Unknown Object (File)
Tue, Jan 21, 10:44 PM

Details

Summary

Instead of implementing the getTypeConstant method in all subclasses of PhabricatorPHIDType, provide a final implementation in the base class which uses reflection. See D9837 for a similar implementation.

Test Plan

Ran arc unit.

Diff Detail

Repository
rP Phabricator
Branch
phidtype-reflection
Lint
Lint Passed
Unit
Tests Passed
Build Status
Buildable 1783
Build 1784: [Placeholder Plan] Wait for 30 Seconds

Event Timeline

joshuaspence retitled this revision from to Simplify the implementation of `PhabricatorPHIDType` subclasses.
joshuaspence updated this object.
joshuaspence edited the test plan for this revision. (Show Details)
joshuaspence added a reviewer: epriestley.
joshuaspence edited edge metadata.
  • Simplify conditional by using preg_match
epriestley edited edge metadata.
This revision is now accepted and ready to land.Jul 21 2014, 2:03 PM
joshuaspence updated this revision to Diff 24031.

Closed by commit rP254542237a66 (authored by @joshuaspence).