diff options
author | Paul Arthur <flowerysong00@yahoo.com> | 2013-01-14 16:42:17 -0500 |
---|---|---|
committer | Paul Arthur <flowerysong00@yahoo.com> | 2013-01-15 01:26:38 -0500 |
commit | 4818baade2f837154aa0a3e6aa6fb8e33f02708c (patch) | |
tree | 1ba50fda780a73fe7dd7b310c8b3212b6ad87340 /lib/class/localplay.abstract.php | |
parent | 7cd9fd9e08370d4fc0ef38420244c1c6b105c672 (diff) | |
download | ampache-4818baade2f837154aa0a3e6aa6fb8e33f02708c.tar.gz ampache-4818baade2f837154aa0a3e6aa6fb8e33f02708c.tar.bz2 ampache-4818baade2f837154aa0a3e6aa6fb8e33f02708c.zip |
Rename localplay.abstract.php
The actual class name is localplay_controller, the filename should
reflect that.
Diffstat (limited to 'lib/class/localplay.abstract.php')
-rw-r--r-- | lib/class/localplay.abstract.php | 121 |
1 files changed, 0 insertions, 121 deletions
diff --git a/lib/class/localplay.abstract.php b/lib/class/localplay.abstract.php deleted file mode 100644 index 5e9d8b3c..00000000 --- a/lib/class/localplay.abstract.php +++ /dev/null @@ -1,121 +0,0 @@ -<?php -/* vim:set tabstop=8 softtabstop=8 shiftwidth=8 noexpandtab: */ -/** - * localplay_controller Class - * - * - * LICENSE: GNU General Public License, version 2 (GPLv2) - * Copyright (c) 2001 - 2011 Ampache.org All Rights Reserved - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License v2 - * as published by the Free Software Foundation. - * - * 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., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. - * - * @package Ampache - * @copyright 2001 - 2011 Ampache.org - * @license http://opensource.org/licenses/gpl-2.0 GPLv2 - * @link http://www.ampache.org/ - */ - -/* - * localplay_controller Class - * - * This is the abstract class for any localplay controller - * - * @package Ampache - * @copyright 2001 - 2011 Ampache.org - * @license http://opensource.org/licenses/gpl-2.0 GPLv2 - * @link http://www.ampache.org/ - * @abstract - */ -abstract class localplay_controller { - - // Required Functions - abstract public function add($objects); // Takes an array of song_ids - abstract public function delete_track($object_id); // Takes a single object_id and removes it from the playlist - abstract public function play(); - abstract public function stop(); - abstract public function get(); - abstract public function connect(); - abstract public function status(); - abstract public function get_version(); // Returns the version of this plugin - abstract public function get_description(); // Returns the description - abstract public function is_installed(); // Returns an boolean t/f - abstract public function install(); - abstract public function uninstall(); - - // For display we need the following 'instance' functions - abstract public function add_instance($data); - abstract public function delete_instance($id); - abstract public function update_instance($id,$post); - abstract public function get_instances(); - abstract public function instance_fields(); - abstract public function set_active_instance($uid); - abstract public function get_active_instance(); - - /** - * get_url - * This returns the URL for the passed object - */ - public function get_url($object) { - - // This might not be an object! - if (!is_object($object)) { - // Stupiidly we'll just blindly add it for now - return $object; - } - - $class = get_class($object); - - $url = call_user_func(array($class,'play_url'),$object->id); - - return $url; - - } // get_url - - /** - * get_file - * This returns the Filename for the passed object, not - * always possible - */ - public function get_file($object) { - - - } // get_file - - /** - * parse_url - * This takes an Ampache URL and then returns the 'primary' part of it - * So that it's easier for localplay modules to return valid song information - */ - public function parse_url($url) { - - // Define possible 'primary' keys - $primary_array = array('oid','demo_id','random'); - $data = array(); - - $variables = parse_url($url,PHP_URL_QUERY); - parse_str($variables,$data); - - foreach ($primary_array as $pkey) { - if ($data[$pkey]) { - $data['primary_key'] = $pkey; - return $data; - } - - } // end foreach - - return $data; - - } // parse_url - -} // end localplay_controller interface |