Subversion Repositories eFlore/Archives.eflore-consultation-v2

Rev

Rev 42 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 42 Rev 44
Line 16... Line 16...
16
   
16
   
17
    function affecterIdentifiant($identifiant)
17
    function affecterIdentifiant($identifiant)
18
    {
18
    {
19
        $this->identifiant = $identifiant;
19
        $this->identifiant = $identifiant;
-
 
20
    }
-
 
21
    
-
 
22
    function recupererIdentifiant()
-
 
23
    {
-
 
24
        return $this->identifiant;
Line 20... Line 25...
20
    }
25
    }
21
   
26
   
22
    function affecterDonnees($donnees)
27
    function affecterDonnees($donnees)
23
    {
28
    {
Line 57... Line 62...
57
    function recupererCollectionBlockFils()
62
    function recupererCollectionBlockFils()
58
    {
63
    {
59
        return $this->collectionBlocksfils;
64
        return $this->collectionBlocksfils;
60
    }
65
    }
Line 61... Line 66...
61
    
66
    
62
	function afficherPattern($chemin,$nom_fonction)
67
    function afficherPattern($chemin, $nom_fonction)
63
	{
-
 
64
		/*echo "identifiant: $this->identifiant</br>";
68
    {
65
		echo "chemin: $chemin</br>";
-
 
66
		echo "nom_fonction: $nom_fonction</br>";*/
-
 
67
		
69
        $retour = '';
68
		if($chemin==$this->identifiant)
-
 
69
		{
70
        if($chemin == $this->recupererIdentifiant()) {
70
			call_user_func($nom_fonction,$this->donnees);
-
 
71
		}
71
            $retour .= call_user_func($nom_fonction, $this->recupererDonnees());
72
		else
-
 
73
		{
-
 
74
			
72
        } else {
75
			$etape_chemin = explode('>',$chemin);
73
            $etape_chemin = explode('>', $chemin);
76
			if($this->identifiant==$etape_chemin[0])
74
            if($this->identifiant == $etape_chemin[0]) {
77
			{	//echo "collection</br>";
75
                $collection_block_fils = $this->recupererCollectionBlockFils();
78
				for($i=0;$i<count($this->collectionBlocksfils);$i++)
-
 
79
				{
76
                for($i = 0; $i < count($collection_block_fils); $i++) {
80
					$collection =$this->collectionBlocksfils[$i];
-
 
81
					//echo "collection2</br>";
77
                    $collection = $collection_block_fils[$i];
82
					if ($collection->recupererIdentifiant()==$etape_chemin[1])
-
 
83
					{
-
 
84
						echo "collection3</br>";
78
                    if ($collection->recupererIdentifiant() == $etape_chemin[1]) {
85
						array_shift($etape_chemin);
79
                        array_shift($etape_chemin);
86
						$collection->afficherPattern(implode('>',$etape_chemin),$nom_fonction);
80
                        $retour .= $collection->afficherPattern(implode('>', $etape_chemin), $nom_fonction);
87
					}			
81
                    }
88
				}
82
                }
89
			}
83
            }
-
 
84
        }
90
		}	
85
        return $retour;
Line 91... Line 86...
91
	}
86
    }
92
    
87
    
93
    function afficher()
88
    function afficher()
94
    {
89
    {