Command errors

This pull request adds in a form of more-detailed error reporting for commands.  Instead of a boolean success/failure return, they now return a `CommandResult`, which is just a fancy pair of status (success/invalid/failure) and message, with some logic to pump the results into a `ResourceSink`.

CommandResult is a bit of an instance of cracking a walnut with a sledgehammer, but I *did* try to keep things from going overly wacky, so there aren't a full range of `CommandResult` subclasses or anything silly like that.

Comments/critique very much appreciated.  After this this merged in, I think we'll start the process of cleaning up the code and making things ready for the first beta release.
Functions are special
On 10 Nov 2014 12:10, "Sam Willcocks" <notifications@github.com> wrote:

> In src/cmd_result.cpp:
>
> > +}
> > +
> > +CommandResult::CommandResult(CommandResult::Type type, const std::string &msg)
> > +    : type(type), msg(msg)
> > +{
> > +}
> > +
> > +bool CommandResult::IsSuccess()
> > +{
> > +	return this->type == Type::SUCCESS;
> > +}
> > +
> > +void CommandResult::Emit(const ResponseSink &sink,
> > +                         const std::vector<std::string> &cmd)
> > +{
> > +	switch(this->type) {
>
> I thought curly brackets on one line vs on a new line, *shrugs*
>
> —
> Reply to this email directly or view it on GitHub
> <https://github.com/UniversityRadioYork/ury-playd/pull/52/files#r20078287>
> .
>