lib/util/router.js
function add(app, route, method, destination) {
        var methods;
        if (typeof(method) === 'string') {
            methods = method.split(',');
        } else if(typeof(method) === 'object') {  // array
            methods = method;
        } else {
            throw new Error(meta.module + '|add|EXCEPTION|unknown method:"' + typeof(method) + '"|expecter=string,object(array)');
        }
        for (var i = 0 ; i < methods.length ; ++i) {
            addRoute(app, route, methods[i], destination);
        }
    }
function add(app, route, method, destination) {
        var methods;
        if (typeof(method) === 'string') {
            methods = method.split(',');
        } else if(typeof(method) === 'object') {  // array
            methods = method;
        } else {
            throw new Error(meta.module + '|add|EXCEPTION|unknown method:"' + typeof(method) + '"|expecter=string,object(array)');
        }
        for (var i = 0 ; i < methods.length ; ++i) {
            addRoute(app, route, methods[i], destination);
        }
    }
add a route to an express application

@param app: an Express Application object
@param route: the URL route for that destination
@param method: can be either a string or an array of HTTP method separated
by a coma
@param destination: a function to handle that URL request