AnyEvent-CouchDB

 view release on metacpan or  search on metacpan

lib/AnyEvent/CouchDB/Exceptions.pm  view on Meta::CPAN


__END__

=head1 NAME

AnyEvent::CouchDB::Exceptions - Exception::Class-based exceptions for AnyEvent::CouchDB

=head1 SYNOPSIS

  use feature 'switch';
  use Try::Tiny;
  use Data::Dump 'pp';
  use AnyEvent::CouchDB;

  my $db = couchdb("food");
  try {
    my $vegetables = $db->open_doc('vegetables')->recv;
  } 
  catch {
    when (ref eq 'AnyEvent::CouchDB::Exception::HTTPError') {
      # handle an HTTP error

lib/AnyEvent/CouchDB/Stream.pm  view on Meta::CPAN

package AnyEvent::CouchDB::Stream;

use strict;
use warnings;
use URI;
use AnyEvent::HTTP;
use Scalar::Util;
use JSON;
use Try::Tiny;
use MIME::Base64;

our $VERSION = '0.02';

sub new {
    my $class        = shift;
    my %args         = @_;
    my $server       = delete $args{url};
    my $db           = delete $args{database};
    my $timeout      = delete $args{timeout};



( run in 0.474 second using v1.01-cache-2.11-cpan-05444aca049 )