Re: final keyword
| From: | Sebastian Schneider | Date: | Tue, 12 Feb 2008 14:39:49 +0000 |
| Subject: | Re: final keyword | ||
| References: | 1 2 3 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-35414@lists.php.net to get a copy of this message | ||
Sebastian Bergmann schrieb:
Sebastian Schneider schrieb:But doesn't work with arrays, e.g. public class Result {public static final $bar = "foobar's world";We have the const keyword for that.
const DECISION_PERMIT = 0;
const DECISION_DENY = 1;
const DECISION_INDETERMINATE = 2;
const DECISION_NOT_APPLICABLE = 3;
const DECISIONS = array( 'Permit', 'Deny', 'Indeterminate', NotApplicable' );//.... } thus you need to work around with private/protected statics, which seems to be incoherent to me.