Commit 8fb570ba authored by Bas de Nooijer's avatar Bas de Nooijer

Lots of phpdoc fixes based on docblox error output

parent 8bf3dc1f
......@@ -58,10 +58,18 @@ class Solarium_Client extends Solarium_Configurable
{
/**
* Querytype definitions
* Querytype select
*/
const QUERYTYPE_SELECT = 'select';
/**
* Querytype update
*/
const QUERYTYPE_UPDATE = 'update';
/**
* Querytype ping
*/
const QUERYTYPE_PING = 'ping';
/**
......
......@@ -46,10 +46,18 @@ class Solarium_Client_Request extends Solarium_Configurable
{
/**
* Http request methods
* Request GET method
*/
const METHOD_GET = 'get';
/**
* Request POST method
*/
const METHOD_POST = 'post';
/**
* Request HEAD method
*/
const METHOD_HEAD = 'head';
/**
......
......@@ -169,7 +169,7 @@ abstract class Solarium_Plugin_Abstract extends Solarium_Configurable
/**
* preCreateQuery hook
*
* @param string $query
* @param string $type
* @param mixed $options
* @return void|Solarium_Query
*/
......@@ -180,7 +180,7 @@ abstract class Solarium_Plugin_Abstract extends Solarium_Configurable
/**
* postCreateQuery hook
*
* @param string $query
* @param string $type
* @param mixed $options
* @param Solarium_Query
* @return void
......
......@@ -50,18 +50,38 @@ class Solarium_Query_Select extends Solarium_Query
{
/**
* Solr sort modes
* Solr sort mode descending
*/
const SORT_DESC = 'desc';
/**
* Solr sort mode ascending
*/
const SORT_ASC = 'asc';
/**
* Query components
* Query component facetset
*/
const COMPONENT_FACETSET = 'facetset';
/**
* Query component dismax
*/
const COMPONENT_DISMAX = 'dismax';
/**
* Query component morelikethis
*/
const COMPONENT_MORELIKETHIS = 'morelikethis';
/**
* Query component highlighting
*/
const COMPONENT_HIGHLIGHTING = 'highlighting';
/**
* Query component grouping
*/
const COMPONENT_GROUPING = 'grouping';
/**
......
......@@ -110,9 +110,9 @@ abstract class Solarium_Query_Select_Component_Facet extends Solarium_Configurab
* @param string $tag
* @return Solarium_Query_Select_Component_Facet Provides fluent interface
*/
public function addExclude($exclude)
public function addExclude($tag)
{
$this->_excludes[$exclude] = true;
$this->_excludes[$tag] = true;
return $this;
}
......
......@@ -48,15 +48,23 @@ class Solarium_Query_Select_Component_Facet_Field extends Solarium_Query_Select_
{
/**
* Facet sort types
* Facet sort type index
*/
const SORT_INDEX = 'index';
/**
* Facet sort type count
*/
const SORT_COUNT = 'count';
/**
* Facet methods
* Facet method enum
*/
const METHOD_ENUM = 'enum';
/**
* Facet method fc
*/
const METHOD_FC = 'fc';
/**
......@@ -81,7 +89,7 @@ class Solarium_Query_Select_Component_Facet_Field extends Solarium_Query_Select_
/**
* Set the field name
*
* @param string $query
* @param string $field
* @return Solarium_Query_Select_Component_Facet_Field Provides fluent interface
*/
public function setField($field)
......@@ -188,7 +196,7 @@ class Solarium_Query_Select_Component_Facet_Field extends Solarium_Query_Select_
/**
* Set the facet mincount
*
* @param int $mincount
* @param int $minCount
* @return Solarium_Query_Select_Component_Facet_Field Provides fluent interface
*/
public function setMinCount($minCount)
......
......@@ -242,10 +242,10 @@ class Solarium_Query_Select_Component_Facet_MultiQuery extends Solarium_Query_Se
* @param string $tag
* @return Solarium_Query_Select_Component_Facet Provides fluent interface
*/
public function addExclude($exclude)
public function addExclude($tag)
{
foreach ($this->_facetQueries AS $facetQuery) {
$facetQuery->addExclude($exclude);
$facetQuery->addExclude($tag);
}
return parent::addExclude($exclude);
......
......@@ -48,21 +48,53 @@ class Solarium_Query_Select_Component_Facet_Range extends Solarium_Query_Select_
{
/**
* Values for the 'other' option
* Value for the 'other' option
*/
const OTHER_BEFORE = 'before';
/**
* Value for the 'other' option
*/
const OTHER_AFTER = 'after';
/**
* Value for the 'other' option
*/
const OTHER_BETWEEN = 'between';
/**
* Value for the 'other' option
*/
const OTHER_ALL = 'all';
/**
* Value for the 'other' option
*/
const OTHER_NONE = 'none';
/**
* Values for the 'include' option
* Value for the 'include' option
*/
const INCLUDE_LOWER = 'lower';
/**
* Value for the 'include' option
*/
const INCLUDE_UPPER = 'upper';
/**
* Value for the 'include' option
*/
const INCLUDE_EDGE = 'edge';
/**
* Value for the 'include' option
*/
const INCLUDE_OUTER = 'outer';
/**
* Value for the 'include' option
*/
const INCLUDE_ALL = 'all';
/**
......@@ -102,7 +134,7 @@ class Solarium_Query_Select_Component_Facet_Range extends Solarium_Query_Select_
/**
* Set the field name
*
* @param string $query
* @param string $field
* @return Solarium_Query_Select_Component_Facet_Range Provides fluent interface
*/
public function setField($field)
......
......@@ -48,11 +48,23 @@ class Solarium_Query_Select_Component_FacetSet extends Solarium_Query_Select_Com
{
/**
* Facet type keys
* Facet type field
*/
const FACET_FIELD = 'field';
/**
* Facet type query
*/
const FACET_QUERY = 'query';
/**
* Facet type multiquery
*/
const FACET_MULTIQUERY = 'multiquery';
/**
* Facet type range
*/
const FACET_RANGE = 'range';
/**
......@@ -191,7 +203,7 @@ class Solarium_Query_Select_Component_FacetSet extends Solarium_Query_Select_Com
*
* This is a global value for all facets in this facetset
*
* @param int $mincount
* @param int $minCount
* @return Solarium_Query_Select_Component_FacetSet Provides fluent interface
*/
public function setMinCount($minCount)
......
......@@ -53,9 +53,13 @@ class Solarium_Query_Select_Component_Grouping extends Solarium_Query_Select_Com
{
/**
* Values for format option
* Value for format grouped
*/
const FORMAT_GROUPED = 'grouped';
/**
* Value for format simple
*/
const FORMAT_SIMPLE = 'simple';
/**
......
......@@ -47,9 +47,13 @@
class Solarium_Query_Select_Component_Highlighting extends Solarium_Query_Select_Component
{
/**
* Values for fragmenter option
* Value for fragmenter option gap
*/
const FRAGMENTER_GAP = 'gap';
/**
* Value for fragmenter option regex
*/
const FRAGMENTER_REGEX = 'regex';
/**
......
......@@ -50,12 +50,28 @@ class Solarium_Query_Update extends Solarium_Query
{
/**
* Update command type names
* Update command add
*/
const COMMAND_ADD = 'add';
/**
* Update command delete
*/
const COMMAND_DELETE = 'delete';
/**
* Update command commit
*/
const COMMAND_COMMIT = 'commit';
/**
* Update command rollback
*/
const COMMAND_ROLLBACK = 'rollback';
/**
* Update command optimize
*/
const COMMAND_OPTIMIZE = 'optimize';
/**
......@@ -230,7 +246,6 @@ class Solarium_Query_Update extends Solarium_Query
* If you need more control, like choosing a key for the command you need to
* create you own command instance and use the add method.
*
* @param string $key
* @param array $queries
* @return Solarium_Query_Update Provides fluent interface
*/
......@@ -265,7 +280,7 @@ class Solarium_Query_Update extends Solarium_Query
* If you need more control, like choosing a key for the command you need to
* create you own command instance and use the add method.
*
* @param array $id
* @param array $ids
* @return Solarium_Query_Update Provides fluent interface
*/
public function addDeleteByIds($ids)
......@@ -287,10 +302,10 @@ class Solarium_Query_Update extends Solarium_Query
* @param int $commitWithin
* @return Solarium_Query_Update Provides fluent interface
*/
public function addDocument($document, $override = null,
public function addDocument($document, $overwrite = null,
$commitWithin = null)
{
return $this->addDocuments(array($document), $override, $commitWithin);
return $this->addDocuments(array($document), $overwrite, $commitWithin);
}
/**
......
......@@ -114,7 +114,7 @@ class Solarium_Query_Update_Command_Delete extends Solarium_Query_Update_Command
/**
* Add multiple IDs to the delete command
*
* @param array $id
* @param array $ids
* @return Solarium_Query_Update_Command_Delete Provides fluent interface
*/
public function addIds($ids)
......
......@@ -58,7 +58,7 @@ class Solarium_Result_Select_Facet_Query
/**
* Constructor
*
* @param array $values
* @param mixed $value
* @return void
*/
public function __construct($value)
......
......@@ -77,6 +77,9 @@ class Solarium_Result_Select_Facet_Range extends Solarium_Result_Select_Facet_Fi
* Constructor
*
* @param array $values
* @param int $before
* @param int $after
* @param int $between
* @return void
*/
public function __construct($values, $before, $after, $between)
......
......@@ -85,7 +85,11 @@ class Solarium_Result_Select_Grouping_QueryGroup implements IteratorAggregate, C
/**
* Constructor
*
* @param array $groups
* @param int $matches
* @param int $numFound
* @param int $start
* @param float $maximumScore
* @param array $documents
* @return void
*/
public function __construct($matches, $numFound, $start, $maximumScore, $documents)
......
......@@ -76,6 +76,7 @@ class Solarium_Result_Select_Highlighting_Result implements IteratorAggregate, C
/**
* Get highlights for a single field
*
* @param string $key
* @return array
*/
public function getField($key)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment