Skip to content

Latest commit

 

History

6 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Abstract Model Class Build Status

Abstract PHP class for models, using the Zend Filter Input class from the Zend Framework.

AbstractModel needs to be extended, then $_fields declared and optionally validators (and filters, although there's no way of actually getting the filtered inputs just yet).

Example:

class Document extends AbstractModel {

    protected $_fields = array('title', 'author');

    protected $_validators = array(
        'title' => array(
                    'Alnum',
                    'presence' => 'required'
        )
    );

}

Unit tests are for PHPUnit.

About

Abstract PHP class for representing data in a model.

Resources

Stars

2 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages