WebService::FindMyiPhone::Device - Device object for WebService::FindMyiPhone
use WebService::FindMyiPhone; my $fmiphone = WebService::FindMyiPhone->new( username => 'email@address', password => 'YaakovLOVE', ); my $iphone = $fmiphone->get_device_by( name => 'mmm cake'); my $location = $iphone->location(); $iphone->send_message(1, 'Where did I leave you?');
WebService::FindMyiPhone::Device is the class used for WebService::FindMyiPhone devices. See the documentation there for more information.
Device objects are stored as a blessed hashref, the _parent key is a reference to the WebService::FindMyiPhone object that created it. The rest of the keys are directly from Apple. You are incouraged to inspect the data there and make use of anything interesting to you.
_parent
Send a message to the device. $sound determines if a sound should be played with the message, a true value will cause a sound even if the phone or iPad is in silent mode. $message is the message to display. $subject is optional and defaults to 'Important Message'.
$sound
$message
$subject
Lock the device remotely and require $passcode to unlock.
$passcode
Returns a hashref with location data. Keys include latitude, longitude, horizontalAccuracy, positionType, isInaccurate, isOld , locationType, locationFinished, and timeStamp.
latitude
longitude
horizontalAccuracy
positionType
isInaccurate
isOld
locationType
locationFinished
timeStamp
If <locationFinished> is false, the method will sleep 2 seconds, call the parent's update_devices method and check again. It will try up to 3 times and then return what it has.
update_devices
Possible values for positionType are 'GPS' and 'Wifi'.
timeStamp is epoch time with milliseconds, divide by 1000 for standard time with milliseconds.
Mike Greb <michael@thegrebs.com>
Copyright 2013- Mike Greb
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
To install WebService::FindMyiPhone, copy and paste the appropriate command in to your terminal.
cpanm
cpanm WebService::FindMyiPhone
CPAN shell
perl -MCPAN -e shell install WebService::FindMyiPhone
For more information on module installation, please visit the detailed CPAN module installation guide.