Next:
Net::StarezServer::Games
Previous:
Net::StarezServer::DownloadServer
 [Table of Contents]

Net::StarezServer::Files



NAME

Net::StarezServer::Files - Manage files from the database for the clients

DESCRIPTION

Net::StarezServer::Files is the module that stores file information.

Files.pm assumes that a table with the name 'files' with at least these elements exists:

'fileid': int(10): auto_increment primary key, the files' id, only used internally.
'filename': varchar(200): the files' name, primarily for the downloadservers.
'filesize': bigint(20): file size in bytes.
'fileformat': the format of this file. Note that more formats may and probably will appear later:
enum('targz', 'tarbz2', 'tar', 'patch', 'rpm', 'deb', 'zip', 'gzip', 'bzip2', 'sqlite', 'http')

METHODS

See Net::StarezServer::BaseSQLModule for the interface on this file.

createTicket

This method creates a Ticket ID for the file indicated using TicketID.pm. It wants four arguments being the files' name, the cap in kilobytes, the servers' main alias for Database.pm, and a code reference to call when the generation is complete.

The return coderef will be called with a 'ticketid' element when the generation is complete, or 'error' if there's been an error. (Actually, it just copies the arguments it gets back from Net::StarezServer::TicketID).

AUTHOR

Written by Sjors Gielen <dazjorz@starez.org>


[Top] Generated by Marek::Pod::HTML 0.49 on Wed Jun 25 20:02:24 2008