Page MenuHomePhabricator

Simplify the implementation of `PhabricatorPolicyCapability` subclasses
ClosedPublic

Authored by joshuaspence on Jul 24 2014, 12:42 PM.
Tags
None
Referenced Files
Unknown Object (File)
Fri, Feb 7, 9:16 AM
Unknown Object (File)
Thu, Feb 6, 2:32 PM
Unknown Object (File)
Sun, Feb 2, 9:01 PM
Unknown Object (File)
Sun, Jan 26, 5:53 PM
Unknown Object (File)
Sat, Jan 25, 9:12 AM
Unknown Object (File)
Sat, Jan 25, 7:08 AM
Unknown Object (File)
Sat, Jan 11, 7:09 PM
Unknown Object (File)
Jan 3 2025, 1:31 AM

Details

Summary

Instead of implementing the getCapabilityKey method in all subclasses of PhabricatorPolicyCapability, provide a final implementation in the base class which uses reflection. See D9837 and D9985 for similar implementations.

Test Plan

N/A

Diff Detail

Repository
rP Phabricator
Branch
policy
Lint
Lint Passed
Unit
Test Failures
Build Status
Buildable 1875
Build 1876: [Placeholder Plan] Wait for 30 Seconds

Unit TestsFailed

TimeTest
0 mstestAllQueriesBelongToActualApplications
0 mstestAdminPolicy
0 mstestCustomPolicyRuleAdministrators
0 mstestCustomPolicyRuleLunarPhase
0 mstestCustomPolicyRuleUser
View Full Test Results (1 Failed · 18 Passed)

Event Timeline

joshuaspence retitled this revision from to Simplify the implementation of `PhabricatorPolicyCapability` subclasses.
joshuaspence updated this object.
joshuaspence edited the test plan for this revision. (Show Details)
joshuaspence added a reviewer: epriestley.
epriestley edited edge metadata.
This revision is now accepted and ready to land.Jul 24 2014, 1:26 PM