Files
plibreader/src/ASF/Object.php
svollbehr 906e2dc59d Add support for ASF
git-svn-id: http://php-reader.googlecode.com/svn/trunk@4 51a70ab9-7547-0410-9469-37e369ee0574
2008-03-03 11:48:28 +00:00

80 lines
2.6 KiB
PHP

<?php
/**
* $Id$
*
*
* Copyright (C) 2006, 2007 The Bearpaw Project Work Group. All Rights Reserved.
* Copyright (C) 2007, 2008 BEHR Software Systems. All Rights Reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* - Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
* - Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
* - Neither the name of the BEHR Software Systems nor the names of its
* contributors may be used to endorse or promote products derived from this
* software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
* LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
*
* @package php-reader
*/
/**
* The base class for all ASF objects.
*
* @package php-reader
* @author Sven Vollbehr <sven.vollbehr@behrss.eu>
* @copyright 2006, 2007 The Bearpaw Project Work Group
* @copyright 2007, 2008 BEHR Software Systems
* @license http://www.opensource.org/licenses/bsd-license.php New BSD License
* @version $Rev$
*/
class ASF_Object
{
/**
* @var Reader The reader associated with this object.
*/
protected $_reader;
/**
* @var string Object's ID
*/
private $_id;
/**
* @var integer Object size in bytes.
*/
protected $_size;
/**
* Constructs the object with the given parameters.
*/
public function __construct($reader, $id, $size)
{
$this->_reader = $reader;
$this->_id = $id;
$this->_size = $size;
}
/**
* Returns the GUID of the ASF object.
*
* @return string Returns the GUID of the ASF object.
*/
public function getID() { return $this->_id; }
}