NAME
Backup::Datto::Device - A class representing a physical Datto appliance.
VERSION
This document describes Datto version 0.1. It is designed to be used by the DattoCollection class, and as a result, most of its interface is not public.
Information about the private interface is commented inline, and minimally here.
Note that and function starting with _priv is not guaranteed to remain in future releases.
SYNOPSIS
Note: This is not useful without something setting the values below. See Device.pm for more details
my $datto = new Backup::Datto::Device();
"Serial Number is " . $datto->get_serial_number(). "\n"; "Device hostname is " . $datto->get_hostname() . "\n"; "Device Model is " . $datto->get_model() . "\n"; "Free Space is " . $datto->get_free_space() . "\n"; "Used Space is " . $datto->get_used_space() . "\n"; "Device has been up for " . $datto->get_uptime() . " seconds\n"; "Internal IP is " . $datto->get_internal_ip() . "\n"; "Device last seen at " . $datto->get_last_seen() . "\n"; "Current transmit limit is " . $datto->get_tx_limit_kb() . "\n";
DESCRIPTION
This module represents a physical (or virtual) Datto appliance and is an OO way to represent its properties, such as hostname, IP, agents, etc.
METHODS
new
No arguments required. All fields are set to undef.
Returns undef if there was an error fetching the XML.
get_serial_number
Returns the device's serial number
get_hostname
Returns the device's hostname
get_model
Returns the devices' model
get_free_space
Returns the free space (in KB) on the device
get_used_space
Returns the used space (in KB) on the device
get_uptime
Returns the uptime (in seconds) of the device
get_internal_ip
Returns the internal IP as a string.
get_last_seen
Returns the last time the device was seen, as a date string
For example, this would return "2014-07-31 22:05:04"
get_tx_limit_kb
Returns the current offsite transmit limit in KB
All other functions
All other functions in this module start with _priv and are designed to be use within the module itself. They are documented inline, but not part of the public interface. They are not guaranteed to remain in future releases. The public functions are guaranteed to remain.
CONFIGURATION
Backup::Datto::Device requires no configuration files or environment variables.
BUGS AND LIMITATIONS
This module assumes EST time. Future versions will handle devices in multiple time zones
This module does not handle NAS Shares at this time.
There is very little error checking since this module is intended to be used within the DattoCollection module.
AUTHOR
Matthew Topper, topperm9@gmail.com
LICENSE AND COPYRIGHT
Copyright (C), Matthew Topper. All rights reserved.
This module is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.