CC-2166: Packaging Improvements. Moved the Zend app into airtime_mvc. It is now installed to /var/www/airtime. Storage is now set to /srv/airtime/stor. Utils are now installed to /usr/lib/airtime/utils/. Added install/airtime-dircheck.php as a simple test to see if everything is install/uninstalled correctly.
This commit is contained in:
parent
514777e8d2
commit
b11cbd8159
4546 changed files with 138 additions and 51 deletions
|
@ -0,0 +1,91 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* This file is part of the Propel package.
|
||||
* For the full copyright and license information, please view the LICENSE
|
||||
* file that was distributed with this source code.
|
||||
*
|
||||
* @license MIT License
|
||||
*/
|
||||
|
||||
/**
|
||||
* A class for holding a column default value.
|
||||
*
|
||||
* @author Hans Lellelid <hans@xmpl.org>
|
||||
* @version $Revision: 1612 $
|
||||
* @package propel.generator.model
|
||||
*/
|
||||
class ColumnDefaultValue
|
||||
{
|
||||
|
||||
const TYPE_VALUE = "value";
|
||||
const TYPE_EXPR = "expr";
|
||||
|
||||
/**
|
||||
* @var string The default value, as specified in the schema.
|
||||
*/
|
||||
private $value;
|
||||
|
||||
/**
|
||||
* @var string The type of value represented by this object (DefaultValue::TYPE_VALUE or DefaultValue::TYPE_EXPR).
|
||||
*/
|
||||
private $type = ColumnDefaultValue::TYPE_VALUE;
|
||||
|
||||
/**
|
||||
* Creates a new DefaultValue object.
|
||||
*
|
||||
* @param string $value The default value, as specified in the schema.
|
||||
* @param string $type The type of default value (DefaultValue::TYPE_VALUE or DefaultValue::TYPE_EXPR)
|
||||
*/
|
||||
public function __construct($value, $type = null)
|
||||
{
|
||||
$this->setValue($value);
|
||||
if ($type !== null) {
|
||||
$this->setType($type);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @return string The type of default value (DefaultValue::TYPE_VALUE or DefaultValue::TYPE_EXPR)
|
||||
*/
|
||||
public function getType()
|
||||
{
|
||||
return $this->type;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param string $type The type of default value (DefaultValue::TYPE_VALUE or DefaultValue::TYPE_EXPR)
|
||||
*/
|
||||
public function setType($type)
|
||||
{
|
||||
$this->type = $type;
|
||||
}
|
||||
|
||||
/**
|
||||
* Convenience method to indicate whether the value in this object is an expression (as opposed to simple value).
|
||||
*
|
||||
* @return boolean Whether value this object holds is an expression.
|
||||
*/
|
||||
public function isExpression()
|
||||
{
|
||||
return ($this->type == self::TYPE_EXPR);
|
||||
}
|
||||
|
||||
/**
|
||||
* @return string The value, as specified in the schema.
|
||||
*/
|
||||
public function getValue()
|
||||
{
|
||||
return $this->value;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param string $value The value, as specified in the schema.
|
||||
*/
|
||||
public function setValue($value)
|
||||
{
|
||||
$this->value = $value;
|
||||
}
|
||||
|
||||
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue