From: x2000coic Date: Thu, 25 Nov 2004 22:00:39 +0000 (+0000) Subject: some basic functions X-Git-Tag: xorg/old~779 X-Git-Url: http://git.polytechnique.org/?a=commitdiff_plain;h=305a2987cd9dc69dee4e87a698b87d41764ac37a;p=platal.git some basic functions --- diff --git a/include/exalead/exalead.class.php b/include/exalead/exalead.class.php index 4e19185..dfcd6dc 100644 --- a/include/exalead/exalead.class.php +++ b/include/exalead/exalead.class.php @@ -44,6 +44,19 @@ class ExaleadKeyword{ $exclude_href = ""; $reset_href = ""; } + + function is_normal(){ + return empty($this->reset_href); + } + + function is_refined(){ + return ( (!empty($this->reset_href)) && ($this->count > 0) ); + } + + function is_excluded(){ + return ( (!empty($this->reset_href)) && ($this->count == 0) ); + } + } class ExaleadGroup{ @@ -124,6 +137,18 @@ class ExaleadCategory{ $this->gcount = ""; } + function is_normal(){ + return empty($this->reset_href); + } + + function is_refined(){ + return ( (!empty($this->reset_href)) && ($this->count > 0) ); + } + + function is_excluded(){ + return ( (!empty($this->reset_href)) && ($this->count == 0) ); + } + } class ExaleadHit{