Skip to content

ISelfDocumenting

Martin Halliday edited this page Jul 25, 2016 · 2 revisions

Middleware can optionally implement the ISelfDocumenting interface to provide documentation to application developers. This allows development tools to assist the application developer to get started quickly with a particular middleware. If the middleware developer chooses not to implement this interface then everything else about this middleware will still function as expected.

Consumers of middleware should never assume that middleware implements this interface.

The ISelfDocumenting interface defines these methods and properties.

Method or property Description
ShortDescription Returns a plain text user friendly name for this middleware. This can be used in drop-down lists and labels that are designed to fit on a single line without wrapping
LongDescription Returns a long, multi-line description of what this middleware does. Can contain simple HTML including lists, bold, italic, line and paragraph breaks. Should not include complex HTML elements like classes, styles, JavaScript etc
Endpoints Returns a list of the URLs that are handled by this middleware including optional elements such as query string parameters, request headers and supported methods.
GetDocumentation() Returns the URL for various kinds of documentation. These URLs can be serviced from within the middleware or point to external resources such as GitHub, BitBucket or a web site dedicated to this middleware

Clone this wiki locally