NAME
Crashplan::Client - The great new Crashplan::Client!
VERSION
Version 0.01
SYNOPSIS
Crashplan::Client allow you to access an Crashplan PROe server (hopefully) in a easy way.
This version only provides a low level API matching part of the server REST API.
The main objective in a near future is to provide an additional higher level API (read 'syntaxic sugar') while enlarging the coverage of the lowlevel API.
Now you (still) must do
use Crashplan::Client;
my $client = Crashplan::Client->new();
$client->GET('/rest/orgs');
my @orgs = $client->parse_response;
my $org = shift @orgs;
...
It's planned to offer (NOT IMPLEMENTED YET) something more like :
use Crashplan::Client;
my $client = Crashplan::Client->new();
my @orgs = $client->orgs;
my $org = shift @orgs;
...
or even
use Crashplan::Client;
my $client = Crashplan::Client->new();
my $org = $client->orgs->first;
...
SUBROUTINES/METHODS
new
Constructor for the Crashplan::Client class
set_rest_header
Set a rest header
Input : header, value the name and the value of the header to be set
Output : None
unset_rest_header
Unset a rest header
Input : header the name and the value of the header to be unset
Output : None
request
Request against the rest API
Input : method
Output : None
responseContent
Get the response content (for the previous request)
Input : None
Output : None
responseCode
Get the response code (for the previous request)
Input : None
Output : None
default_header
Build a default header based on $self object attribute
Input : None
Output : A hash ref
GET
GET request against the REST server
Input : $url the url to be requested
Output : None
parse_response
Parse a server response to populate Crashplan objects
Input : None (use $self->responseContent)
Output : None
_populate
Return an array of Crashplan::Client object from a hash.
Input : Class name
Output : Array of object
TESTING
To enable testing against a Crashplan server, set the following environment variables before running 'make test' .
TEST_SERVER, TEST_USER, TEST_PASSWORD
AUTHOR
Arnaud (Arhuman) ASSAD, <arnaud.assad at jaguar-network.com>
BUGS
Please report any bugs or feature requests to bug-crashplan-client at rt.cpan.org
, or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=Crashplan-Client. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.
SUPPORT
You can find documentation for this module with the perldoc command.
perldoc Crashplan::Client
You can also look for information at:
RT: CPAN's request tracker
AnnoCPAN: Annotated CPAN documentation
CPAN Ratings
Search CPAN
ACKNOWLEDGEMENTS
LICENSE AND COPYRIGHT
Copyright 2011 Arnaud (Arhuman) ASSAD.
This program is free software; you can redistribute it and/or modify it under the terms of either: the GNU General Public License as published by the Free Software Foundation; or the Artistic License.
See http://dev.perl.org/licenses/ for more information.