tangra logo
   
[ class tree: tangra_lib ] [ index: tangra_lib ] [ all elements ]
 

Source for file tangra_module_release_relation.class.php

Documentation is available at tangra_module_release_relation.class.php

  1. <?php
  2. // $Id$
  3.  
  4. /**
  5.  * Contains class Tangra_Module_DBC
  6.  *
  7.  * @package  tangra_lib
  8.  * @subpackage  modules_manager
  9.  */
  10.  
  11. /**
  12.  * Tangra_Module_Release_Relation
  13.  *
  14.  * @package  tangra_lib
  15.  * @subpackage  modules_manager
  16.  */
  17.     /**
  18.      * Relation type "depends"
  19.      */
  20.     const TYPE_DEPENDS = 1;
  21.     /**
  22.      * Relation type "recommends"
  23.      */
  24.     const TYPE_RECOMMENDS = 2;
  25.     /**
  26.      * Relation type "suggests"
  27.      */
  28.     const TYPE_SUGGESTS = 3;
  29.     /**
  30.      * Relation type "enhances"
  31.      */
  32.     const TYPE_ENHANCES = 4;
  33.     /**
  34.      * Relation type "predepends"
  35.      */
  36.     const TYPE_PREDEPENDS = 5;
  37.     /**
  38.      * Relation type "conflicts"
  39.      */
  40.     const TYPE_CONFLICTS = 6;
  41.     /**
  42.      * Relation type "provides"
  43.      */
  44.     const TYPE_PROVIDES = 7;
  45.  
  46.  
  47.     /**
  48.      * ID
  49.      *
  50.      * @var integer 
  51.      * @internal
  52.      */
  53.     private $id;
  54.     /**
  55.      * Type ID
  56.      *
  57.      * @var integer 
  58.      * @internal
  59.      */
  60.     private $type;
  61.     /**
  62.      * Release ID
  63.      *
  64.      * @var integer 
  65.      * @internal
  66.      */
  67.     private $module_release;
  68.     /**
  69.      * Relation to module hid
  70.      *
  71.      * @var string 
  72.      * @internal
  73.      */
  74.     private $relation_to;
  75.     /**
  76.      * Version requirement
  77.      *
  78.      * @var string 
  79.      * @internal
  80.      */
  81.     private $version_requirement;
  82.  
  83.  
  84.     /**
  85.      * Sets ID
  86.      *
  87.      * @param integer $id 
  88.      */
  89.     public function set_id($id{
  90.         tangra_if_not_int_throw_e($id);
  91.  
  92.         $this->id = $id;
  93.     }
  94.  
  95.  
  96.     /**
  97.      * Gets ID
  98.      *
  99.      * @return integer 
  100.      */
  101.     public function get_id({
  102.         return $this->id;
  103.     }
  104.  
  105.  
  106.     /**
  107.      * Sets type ID
  108.      *
  109.      * @param integer $type 
  110.      */
  111.     public function set_type($type{
  112.         tangra_if_not_int_throw_e($type);
  113.  
  114.         $this->type = $type;
  115.     }
  116.  
  117.  
  118.     /**
  119.      * Gets type ID
  120.      *
  121.      * @return integer 
  122.      */
  123.     public function get_type({
  124.         return $this->type;
  125.     }
  126.  
  127.  
  128.     /**
  129.      * Sets module release ID
  130.      *
  131.      * @param intege $module_release 
  132.      */
  133.     public function set_module_release($module_release{
  134.         tangra_if_not_int_throw_e($module_release);
  135.  
  136.         $this->module_release = $module_release;
  137.     }
  138.  
  139.  
  140.     /**
  141.      * Gets module release ID
  142.      *
  143.      * @return integer 
  144.      */
  145.     public function get_module_release({
  146.         return $this->module_release;
  147.     }
  148.  
  149.  
  150.     /**
  151.      * Sets relation to hid
  152.      *
  153.      * @param string $relation_to 
  154.      */
  155.     public function set_relation_to($relation_to{
  156.         $this->relation_to = $relation_to;
  157.     }
  158.  
  159.  
  160.     /**
  161.      * Gets relation to hid
  162.      *
  163.      * @return string 
  164.      */
  165.     public function get_relation_to({
  166.         return $this->relation_to;
  167.     }
  168.  
  169.  
  170.     /**
  171.      * Sets version requirement
  172.      *
  173.      * @param string $version_requirement 
  174.      */
  175.     public function set_version_requirement($version_requirement{
  176.         $this->version_requirement = $version_requirement;
  177.     }
  178.  
  179.  
  180.     /**
  181.      * Gets version requirement
  182.      *
  183.      * @return string 
  184.      */
  185.     public function get_version_requirement({
  186.         return $this->version_requirement;
  187.     }
  188. }