コード例 #1
0
ファイル: CCDAPQ.class.php プロジェクト: fbone/mediboard4
 /**
  * Setter unit
  *
  * @param String $unit String
  *
  * @return void
  */
 public function setUnit($unit)
 {
     if (!$unit) {
         $this->unit = null;
         return;
     }
     $uni = new CCDA_base_cs();
     $uni->setData($unit);
     $this->unit = $uni;
 }
コード例 #2
0
ファイル: CCDAMO.class.php プロジェクト: fbone/mediboard4
 /**
  * Setter currency
  *
  * @param String $currency String
  *
  * @return void
  */
 public function setCurrency($currency)
 {
     if (!$currency) {
         $this->currency = null;
         return;
     }
     $cs = new CCDA_base_cs();
     $cs->setData($currency);
     $this->currency = $cs;
 }
コード例 #3
0
 /**
  * Setter ID
  *
  * @param String $inst String
  *
  * @return void
  */
 function setIdentifier($inst)
 {
     if (!$inst) {
         $this->identifier = null;
         return;
     }
     $cs = new CCDA_base_cs();
     $cs->setData($inst);
     $this->identifier = $cs;
 }
コード例 #4
0
ファイル: CCDACD.class.php プロジェクト: fbone/mediboard4
 /**
  * Setter Code
  *
  * @param String $code String
  *
  * @return void
  */
 public function setCode($code)
 {
     if (!$code) {
         $this->code = null;
         return;
     }
     $cod = new CCDA_base_cs();
     $cod->setData($code);
     $this->code = $cod;
 }
コード例 #5
0
 /**
  * Fonction qui teste si la classe est valide
  *
  * @return array()
  */
 function test()
 {
     $tabTest = parent::test();
     /**
      * Test avec une valeur correcte
      */
     if ($this->_enumeration) {
         $enum = $this->_enumeration;
         $this->setData($enum[0]);
         $tabTest[] = $this->sample("Test avec une valeur correcte", "Document valide");
     }
     /*-------------------------------------------------------------------------------------*/
     /**
      * Test avec une valeur correcte d'un union
      */
     $union = $this->getUnion();
     if ($union) {
         $unionName = "CCDA" . $union[0];
         /** @var CCDA_Datatype_Voc $unionClass */
         $unionClass = new $unionName();
         $unionEnum = $unionClass->getEnumeration(true);
         if ($unionEnum) {
             $this->setData($unionEnum[0]);
             $tabTest[] = $this->sample("Test avec une valeur correcte d'un union", "Document valide");
         }
     }
     /*-------------------------------------------------------------------------------------*/
     return $tabTest;
 }
コード例 #6
0
ファイル: CCDAED.class.php プロジェクト: fbone/mediboard4
 /**
  * Setter mediaType
  *
  * @param String $mediaType String
  *
  * @return void
  */
 public function setMediaType($mediaType)
 {
     if (!$mediaType) {
         $this->mediaType = null;
         return;
     }
     $media = new CCDA_base_cs();
     $media->setData($mediaType);
     $this->mediaType = $media;
 }