5 has type => (is => 'ro', required => 1);
6 has data => (is => 'ro', required => 1);
8 sub flatten { $_[0]->type, @{$_[0]->data} }
12 $self->throw unless $self->type eq 'success';
13 return wantarray ? @{$self->data} : $self->data->[0];
23 $self->type.': '.join ' ', @{$self->data};