Login   Register  
PHP Classes
elePHPant
Icontem

Constant Array 2: Enhanced declaration of array values as constants

Recommend this page to a friend!
Stumble It! Stumble It! Bookmark in del.icio.us Bookmark in del.icio.us
  Info   View files View files (1)   DownloadInstall with Composer Download .zip   Reputation   Support forum (2)   Blog    
Last Updated Ratings Unique User Downloads Download Rankings  
2011-12-27 (2 years ago) RSS 2.0 feedNot enough user ratingsTotal: 188 All time: 7,244 This week: 1,459Up
Version License PHP version Categories  
array-constant 2.0.5GNU General Public Lice...5.0PHP 5, Data types
Description Author  

This class can be used for declaration of array values as constants.

This class was inspired by a similarly named ("Constant Array") class written by Sourav Ray.

This class has at this point been refactored and augmented to the degree that little of the inspiring class remains beyond the concept.

This class provides the following features and enhancements as compared to Sourav Ray's original code:

- Returns booleans for non-associative array values when given (optional)
- Returns values for associative array keys when given (optional)
- Code added to validate individual keys and to retrieve values by individual keys
- Eliminates use of eval() for security and speed
- Fixes Exception handling
- Code has been reformatted

** See the class phpDoc Block for further details!

Picture of Ville Walveranta
Name: Ville Walveranta <contact>
Classes: 1 package by
Country: United States United States
Age: 44
All time rank: Not yet ranked
Week rank: 1756196 in United States United States

  Files folder image Files  
File Role Description
Plain text file ArrConst.class.php Class ArrConst class

 Version Control Unique User Downloads Download Rankings  
 0%Total:188All time:7,244
 This week:0This week:1,459Up
 User Comments (1)  
 
There are some problems with your code.
3 years ago (Artur Graniszewski)
32%StarStar