<h4> Arguments</h4>

<table class="doctable" border="1" style="padding-left: 20px;">
<tr>
<th>Argument </th>
<th> Description </th>
<th style="width: 100px;"> Default </th>
</tr>

<tr>
<td><code>path</code></td>
<td>
The path for which the middleware function is invoked; can be any of:
<ul>
<li>A string representing a path.</li>
<li>A path pattern.</li>
<li>A regular expression pattern to match paths.</li>
<li>An array of combinations of any of the above.</li>
</ul>

For examples, see <a href="#path-examples">Path examples</a>.
</td>
<td>'/' (root path)</td>
</tr>

<tr>
<td> <code>callback</code></td>
<td>
Callback functions; can be:
<ul>
<li>A middleware function.</li>
<li>A series of middleware functions (separated by commas).</li>
<li>An array of middleware functions.</li>
<li>A combination of all of the above.</li>
</ul>
<p>
You can provide multiple callback functions that behave just like middleware, except
that these callbacks can invoke <code>next('route')</code> to bypass
the remaining route callback(s). You can use this mechanism to impose pre-conditions
on a route, then pass control to subsequent routes if there is no reason to proceed with the current route.
</p><p>
Since <a href="#router">router</a> and <a href="#application">app</a> implement the middleware interface,
you can use them as you would any other middleware function.
</p><p>
For examples, see <a href="#middleware-callback-function-examples">Middleware callback function examples</a>.
</p>
</td>
<td> None </td>
</tr></table>
