Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/fulltextsearch.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorMaxence Lange <maxence@artificial-owl.com>2018-05-18 19:40:01 +0300
committerMaxence Lange <maxence@artificial-owl.com>2018-05-18 19:40:01 +0300
commit35b98bfc683cda2943c7c8d899c2dab5e89bfc17 (patch)
tree51803082b05aa62969d5b00a68f141d31aa60c85 /lib
parentffe300e473c428b689eacd899b9f370ec5a5bfc9 (diff)
add Fields()
Signed-off-by: Maxence Lange <maxence@artificial-owl.com>
Diffstat (limited to 'lib')
-rw-r--r--lib/Model/SearchRequest.php33
1 files changed, 33 insertions, 0 deletions
diff --git a/lib/Model/SearchRequest.php b/lib/Model/SearchRequest.php
index 6da3747..35d1bbb 100644
--- a/lib/Model/SearchRequest.php
+++ b/lib/Model/SearchRequest.php
@@ -55,6 +55,9 @@ class SearchRequest implements \JsonSerializable {
private $parts = [];
/** @var array */
+ private $fields = [];
+
+ /** @var array */
private $wildcardQueries = [];
/** @var array */
@@ -206,6 +209,36 @@ class SearchRequest implements \JsonSerializable {
/**
+ * @return array
+ */
+ public function getFields() {
+ return $this->fields;
+ }
+
+ /**
+ * @param array $fields
+ *
+ * @return $this
+ */
+ public function setFields($fields) {
+ $this->fields = $fields;
+
+ return $this;
+ }
+
+ /**
+ * @param $field
+ *
+ * @return $this
+ */
+ public function addField($field) {
+ $this->fields[] = $field;
+
+ return $this;
+ }
+
+
+ /**
* @param string $tag
*/
public function addTag($tag) {