Load a supplement file and return it as a string. Takes two parameters:
directory and filename.
GetSupplement will always return a string with the content. If it fails to get the content, it prints an error-message and aborts the program.
Load a supplement file and return it as an array. Any comments or blank lines
will be removed. Takes two parameters: directory and filename.
GetSupplementLines will always return an array with the content. If it fails to get the content, it prints an error-message and aborts the program.
|GetSupplementFile||Get the supplement file from the local machine|
|GetSupplementUrl||Get the supplement file from a URL|
Get the base directory containing supplementary files.
Set the root directory for loading supplementary files.
|GetSupplementRoot||Get the root directory for loading supplementary files.|
The module stores all downloaded files in a cache. The cache is stored on disk in ~/.xmltv/supplement on Unix and in CSIDL_LOCAL_APPDATA//xmltv/supplement on Windows.
If a file has been downloaded less than 1 hour ago, the file from the cache is used without contacting the server. Otherwise, if the file has been downloaded more than 1 hour ago, then the module checks with the server to see if an updated file is available and downloads it if necessary.
If the server does not respond or returns an error-message, a warning is printed to STDERR and the file from the cache is used.
The XMLTV_SUPPLEMENT environment variable can be used to tell the module where the supplementary files are found.
The XMLTV_SUPPLEMENT_VERBOSE environment variable can be used to get more debug output from XMLTV::Supplement.
Copyright (C) 2007 Mattias Holmlund.
This program 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.
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.
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|perl v5.20.3||SUPPLEMENT (3)||2016-04-03|