Subversion Repositories eFlore/Applications.eflore-consultation

Rev

Rev 511 | Rev 1230 | Go to most recent revision | Only display areas with differences | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 511 Rev 749
1
<?php
1
<?php
2
class NomCourant {
2
class NomCourant {
3
	private $nns = null;
3
	private $nns = null;
4
	private $nnr = null;
4
	private $nnr = null;
5
	private $selectionne = null;
5
	private $selectionne = null;
6
	private $retenu = null;
6
	private $retenu = null;
7
 
7
 
8
	public function __construct($num_nom_selectionne, Noms $noms, Taxons $taxons) {
8
	public function __construct($num_nom_selectionne, Noms $noms, Taxons $taxons) {
9
		
9
		
10
		$this->nns = $num_nom_selectionne;
10
		$this->nns = $num_nom_selectionne;
11
		$this->selectionne = new Nom($noms->getNom($this->nns));
11
		$this->selectionne = new Nom($noms->getNom($this->nns));
12
		$this->retenu = new Nom($taxons->getTaxon($this->nns));
12
		$this->retenu = new Nom($taxons->getTaxon($this->nns));
13
		$this->nnr = $this->retenu->get('id');
13
		$this->nnr = $this->retenu->get('id');
14
		$this->retenu->setTaxonsSuperieurs($taxons->getTaxonsSup($this->nnr), $this->nnr);
-
 
15
		$taxons_sup = $taxons->getTaxonsSup($this->nnr);
14
		$taxons_sup = $taxons->getTaxonsSup($this->nnr);
16
		$this->taxons_sup = $taxons_sup[$this->nnr];
15
		$this->taxons_sup = $taxons_sup[$this->nnr];
-
 
16
		$this->retenu->setTaxonsSuperieurs($taxons_sup, $this->nnr);
17
	}
17
	}
18
 
18
 
19
	/**
19
	/**
20
	 * Retour le numéro du nom sélectionné courant.
20
	 * Retour le numéro du nom sélectionné courant.
21
	 *
21
	 *
22
	 * @return le numéro du nom sélectionné.
22
	 * @return le numéro du nom sélectionné.
23
	 */
23
	 */
24
	public function getNns() {
24
	public function getNns() {
25
		return $this->nns;
25
		return $this->nns;
26
	}
26
	}
27
	
27
	
28
	public function getNnr() {
28
	public function getNnr() {
29
		return $this->nnr;
29
		return $this->nnr;
30
	}
30
	}
31
	
31
	
32
 
32
 
33
	public function getNomSelectionne() {
33
	public function getNomSelectionne() {
34
		return $this->selectionne;
34
		return $this->selectionne;
35
	}
35
	}
36
 
36
 
37
	public function getNomRetenu() {
37
	public function getNomRetenu() {
38
		return $this->retenu;
38
		return $this->retenu;
39
	}
39
	}
40
	
40
	
41
	public function getNt() {
41
	public function getNt() {
42
		return $this->retenu->get('num_taxonomique');
42
		return $this->retenu->get('num_taxonomique');
43
	}
43
	}
44
 
44
 
45
}
45
}
46
?>
46
?>