-
Notifications
You must be signed in to change notification settings - Fork 0
/
Download.pm
70 lines (58 loc) · 1.56 KB
/
Download.pm
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
#!/usr/bin/perl
# $Id$
#
# WEB INTERFACE and Controll application for an headless squeezelite
# installation.
#
# Best used with Squeezelite-R2
# (https://github.com/marcoc1712/squeezelite/releases)
#
# Copyright 2016 Marco Curti, marcoc1712 at gmail dot com.
# Please visit www.marcoc1712.it
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License,
# version 3.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
################################################################################
package Download;
use strict;
use warnings;
use utf8;
sub new{
my $class = shift;
my $status = shift;
my $self = bless {
_status => $status,
}, $class;
return $self;
}
sub getStatus{
my $self = shift;
return $self->{_status};
}
sub getDownloadUrl{
my $self = shift;
return $self->getSettings()->{DOWNLOAD_URL};
}
sub getFolderInArchive{
my $self = shift;
return $self->getSettings()->{FOLDER_IN_ARCHIVE};
}
################################################################################
# tobe overidden
#
sub download{
my $self = shift;
$self->getStatus()->record('',5, "not implemented yet",'');
return 0;
}
################################################################################
#privates
#
1;