argon/model.js
function all(callback) {
        var Model = this;
        var request = {
            find : 'find',
            model : Model
        };
        
        this.dispatch('beforeAll'); 
        this.storage.find(request, function findCallback(data) {
            if (callback) {
                callback(data);
                Model.dispatch('afterAll');
            }
        });
        
        return this;
    }
function all(callback) {
        var Model = this;
        var request = {
            find : 'find',
            model : Model
        };
        
        this.dispatch('beforeAll'); 
        this.storage.find(request, function findCallback(data) {
            if (callback) {
                callback(data);
                Model.dispatch('afterAll');
            }
        });
        
        return this;
    }
function all ( callback ) { var Model = this ; var request = { find : 'find' , model : Model } ; this . dispatch ( 'beforeAll' ) ; this . storage . find ( request , function findCallback ( data ) { if ( callback ) { callback ( data ) ; Model . dispatch ( 'afterAll' ) ; } } ) ; return this ; }
Fetches all records of a given Model and creates the instances.
@method all <public, static>
@argument callback <optional> [Function] method to handle data.
@return [Argon.Model].
Fetches all records of a given Model and creates the instances .