lib/util/router.js
function addRoute(app, route, method, destination) {
        if (method === 'GET') {
            app.get(route, destination);
        } else if (method === 'POST') {
            app.post(route, destination);
        } else if (method === 'PUT') {
            app.put(route, destination);
        } else if (method === 'DELETE') {
            app.delete(route, destination);
        } else {
            throw new Error(meta.module + '|addRoute|EXCEPTION|unknown method:"' + method + '"|expecter=GET,POST,PUT,DELETE');
        }
        logger.log('debug', '%s|add|method=%s|route=%s', meta.module, method, route, meta);
    }
function addRoute(app, route, method, destination) {
        if (method === 'GET') {
            app.get(route, destination);
        } else if (method === 'POST') {
            app.post(route, destination);
        } else if (method === 'PUT') {
            app.put(route, destination);
        } else if (method === 'DELETE') {
            app.delete(route, destination);
        } else {
            throw new Error(meta.module + '|addRoute|EXCEPTION|unknown method:"' + method + '"|expecter=GET,POST,PUT,DELETE');
        }
        logger.log('debug', '%s|add|method=%s|route=%s', meta.module, method, route, meta);
    }
add a route to an express application

@param app: an Express Application object
@param route: the URL route for that destination
@param method: either GET, POST, PUT or DELETE
@param destination: a function to handle that URL request