visuddhinanda 2 vuotta sitten
vanhempi
sitoutus
354da6fcdb

BIN
grpc/GPBMetadata/Tulip.php


+ 42 - 0
grpc/Mint/Tulip/V1/SearchClient.php

@@ -30,4 +30,46 @@ class SearchClient extends \Grpc\BaseStub {
         $metadata, $options);
     }
 
+    /**
+     * @param \Mint\Tulip\V1\UpdateRequest $argument input argument
+     * @param array $metadata metadata
+     * @param array $options call options
+     * @return \Grpc\UnaryCall
+     */
+    public function Update(\Mint\Tulip\V1\UpdateRequest $argument,
+      $metadata = [], $options = []) {
+        return $this->_simpleRequest('/mint.tulip.v1.Search/Update',
+        $argument,
+        ['\Mint\Tulip\V1\UpdateResponse', 'decode'],
+        $metadata, $options);
+    }
+
+    /**
+     * @param \Mint\Tulip\V1\UploadDictionaryRequest $argument input argument
+     * @param array $metadata metadata
+     * @param array $options call options
+     * @return \Grpc\UnaryCall
+     */
+    public function UploadDictionary(\Mint\Tulip\V1\UploadDictionaryRequest $argument,
+      $metadata = [], $options = []) {
+        return $this->_simpleRequest('/mint.tulip.v1.Search/UploadDictionary',
+        $argument,
+        ['\Mint\Tulip\V1\UploadDictionaryResponse', 'decode'],
+        $metadata, $options);
+    }
+
+    /**
+     * @param \Mint\Tulip\V1\UpdateIndexRequest $argument input argument
+     * @param array $metadata metadata
+     * @param array $options call options
+     * @return \Grpc\UnaryCall
+     */
+    public function UpdateIndex(\Mint\Tulip\V1\UpdateIndexRequest $argument,
+      $metadata = [], $options = []) {
+        return $this->_simpleRequest('/mint.tulip.v1.Search/UpdateIndex',
+        $argument,
+        ['\Mint\Tulip\V1\UpdateIndexResponse', 'decode'],
+        $metadata, $options);
+    }
+
 }

+ 12 - 12
grpc/Mint/Tulip/V1/SearchRequest.php

@@ -20,9 +20,9 @@ class SearchRequest extends \Google\Protobuf\Internal\Message
      */
     private $keywords;
     /**
-     * Generated from protobuf field <code>int32 book = 2;</code>
+     * Generated from protobuf field <code>repeated int32 books = 2;</code>
      */
-    protected $book = 0;
+    private $books;
     /**
      * Generated from protobuf field <code>optional .mint.tulip.v1.SearchRequest.Page page = 99;</code>
      */
@@ -35,7 +35,7 @@ class SearchRequest extends \Google\Protobuf\Internal\Message
      *     Optional. Data for populating the Message object.
      *
      *     @type array<string>|\Google\Protobuf\Internal\RepeatedField $keywords
-     *     @type int $book
+     *     @type array<int>|\Google\Protobuf\Internal\RepeatedField $books
      *     @type \Mint\Tulip\V1\SearchRequest\Page $page
      * }
      */
@@ -67,23 +67,23 @@ class SearchRequest extends \Google\Protobuf\Internal\Message
     }
 
     /**
-     * Generated from protobuf field <code>int32 book = 2;</code>
-     * @return int
+     * Generated from protobuf field <code>repeated int32 books = 2;</code>
+     * @return \Google\Protobuf\Internal\RepeatedField
      */
-    public function getBook()
+    public function getBooks()
     {
-        return $this->book;
+        return $this->books;
     }
 
     /**
-     * Generated from protobuf field <code>int32 book = 2;</code>
-     * @param int $var
+     * Generated from protobuf field <code>repeated int32 books = 2;</code>
+     * @param array<int>|\Google\Protobuf\Internal\RepeatedField $var
      * @return $this
      */
-    public function setBook($var)
+    public function setBooks($var)
     {
-        GPBUtil::checkInt32($var);
-        $this->book = $var;
+        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::INT32);
+        $this->books = $arr;
 
         return $this;
     }

+ 60 - 0
grpc/Mint/Tulip/V1/SearchStub.php

@@ -21,6 +21,48 @@ class SearchStub {
         return null;
     }
 
+    /**
+     * @param \Mint\Tulip\V1\UpdateRequest $request client request
+     * @param \Grpc\ServerContext $context server request context
+     * @return \Mint\Tulip\V1\UpdateResponse for response data, null if if error occured
+     *     initial metadata (if any) and status (if not ok) should be set to $context
+     */
+    public function Update(
+        \Mint\Tulip\V1\UpdateRequest $request,
+        \Grpc\ServerContext $context
+    ): ?\Mint\Tulip\V1\UpdateResponse {
+        $context->setStatus(\Grpc\Status::unimplemented());
+        return null;
+    }
+
+    /**
+     * @param \Mint\Tulip\V1\UploadDictionaryRequest $request client request
+     * @param \Grpc\ServerContext $context server request context
+     * @return \Mint\Tulip\V1\UploadDictionaryResponse for response data, null if if error occured
+     *     initial metadata (if any) and status (if not ok) should be set to $context
+     */
+    public function UploadDictionary(
+        \Mint\Tulip\V1\UploadDictionaryRequest $request,
+        \Grpc\ServerContext $context
+    ): ?\Mint\Tulip\V1\UploadDictionaryResponse {
+        $context->setStatus(\Grpc\Status::unimplemented());
+        return null;
+    }
+
+    /**
+     * @param \Mint\Tulip\V1\UpdateIndexRequest $request client request
+     * @param \Grpc\ServerContext $context server request context
+     * @return \Mint\Tulip\V1\UpdateIndexResponse for response data, null if if error occured
+     *     initial metadata (if any) and status (if not ok) should be set to $context
+     */
+    public function UpdateIndex(
+        \Mint\Tulip\V1\UpdateIndexRequest $request,
+        \Grpc\ServerContext $context
+    ): ?\Mint\Tulip\V1\UpdateIndexResponse {
+        $context->setStatus(\Grpc\Status::unimplemented());
+        return null;
+    }
+
     /**
      * Get the method descriptors of the service for server registration
      *
@@ -35,6 +77,24 @@ class SearchStub {
                 '\Mint\Tulip\V1\SearchRequest',
                 \Grpc\MethodDescriptor::UNARY_CALL
             ),
+            '/mint.tulip.v1.Search/Update' => new \Grpc\MethodDescriptor(
+                $this,
+                'Update',
+                '\Mint\Tulip\V1\UpdateRequest',
+                \Grpc\MethodDescriptor::UNARY_CALL
+            ),
+            '/mint.tulip.v1.Search/UploadDictionary' => new \Grpc\MethodDescriptor(
+                $this,
+                'UploadDictionary',
+                '\Mint\Tulip\V1\UploadDictionaryRequest',
+                \Grpc\MethodDescriptor::UNARY_CALL
+            ),
+            '/mint.tulip.v1.Search/UpdateIndex' => new \Grpc\MethodDescriptor(
+                $this,
+                'UpdateIndex',
+                '\Mint\Tulip\V1\UpdateIndexRequest',
+                \Grpc\MethodDescriptor::UNARY_CALL
+            ),
         ];
     }
 

+ 95 - 0
grpc/Mint/Tulip/V1/UpdateIndexRequest.php

@@ -0,0 +1,95 @@
+<?php
+# Generated by the protocol buffer compiler.  DO NOT EDIT!
+# source: tulip.proto
+
+namespace Mint\Tulip\V1;
+
+use Google\Protobuf\Internal\GPBType;
+use Google\Protobuf\Internal\RepeatedField;
+use Google\Protobuf\Internal\GPBUtil;
+
+/**
+ * Generated from protobuf message <code>mint.tulip.v1.UpdateIndexRequest</code>
+ */
+class UpdateIndexRequest extends \Google\Protobuf\Internal\Message
+{
+    /**
+     * Generated from protobuf field <code>int32 book = 1;</code>
+     */
+    protected $book = 0;
+    /**
+     * Generated from protobuf field <code>optional int32 paragraph = 2;</code>
+     */
+    protected $paragraph = null;
+
+    /**
+     * Constructor.
+     *
+     * @param array $data {
+     *     Optional. Data for populating the Message object.
+     *
+     *     @type int $book
+     *     @type int $paragraph
+     * }
+     */
+    public function __construct($data = NULL) {
+        \GPBMetadata\Tulip::initOnce();
+        parent::__construct($data);
+    }
+
+    /**
+     * Generated from protobuf field <code>int32 book = 1;</code>
+     * @return int
+     */
+    public function getBook()
+    {
+        return $this->book;
+    }
+
+    /**
+     * Generated from protobuf field <code>int32 book = 1;</code>
+     * @param int $var
+     * @return $this
+     */
+    public function setBook($var)
+    {
+        GPBUtil::checkInt32($var);
+        $this->book = $var;
+
+        return $this;
+    }
+
+    /**
+     * Generated from protobuf field <code>optional int32 paragraph = 2;</code>
+     * @return int
+     */
+    public function getParagraph()
+    {
+        return isset($this->paragraph) ? $this->paragraph : 0;
+    }
+
+    public function hasParagraph()
+    {
+        return isset($this->paragraph);
+    }
+
+    public function clearParagraph()
+    {
+        unset($this->paragraph);
+    }
+
+    /**
+     * Generated from protobuf field <code>optional int32 paragraph = 2;</code>
+     * @param int $var
+     * @return $this
+     */
+    public function setParagraph($var)
+    {
+        GPBUtil::checkInt32($var);
+        $this->paragraph = $var;
+
+        return $this;
+    }
+
+}
+

+ 58 - 0
grpc/Mint/Tulip/V1/UpdateIndexResponse.php

@@ -0,0 +1,58 @@
+<?php
+# Generated by the protocol buffer compiler.  DO NOT EDIT!
+# source: tulip.proto
+
+namespace Mint\Tulip\V1;
+
+use Google\Protobuf\Internal\GPBType;
+use Google\Protobuf\Internal\RepeatedField;
+use Google\Protobuf\Internal\GPBUtil;
+
+/**
+ * Generated from protobuf message <code>mint.tulip.v1.UpdateIndexResponse</code>
+ */
+class UpdateIndexResponse extends \Google\Protobuf\Internal\Message
+{
+    /**
+     * Generated from protobuf field <code>int32 error = 1;</code>
+     */
+    protected $error = 0;
+
+    /**
+     * Constructor.
+     *
+     * @param array $data {
+     *     Optional. Data for populating the Message object.
+     *
+     *     @type int $error
+     * }
+     */
+    public function __construct($data = NULL) {
+        \GPBMetadata\Tulip::initOnce();
+        parent::__construct($data);
+    }
+
+    /**
+     * Generated from protobuf field <code>int32 error = 1;</code>
+     * @return int
+     */
+    public function getError()
+    {
+        return $this->error;
+    }
+
+    /**
+     * Generated from protobuf field <code>int32 error = 1;</code>
+     * @param int $var
+     * @return $this
+     */
+    public function setError($var)
+    {
+        GPBUtil::checkInt32($var);
+        $this->error = $var;
+
+        return $this;
+    }
+
+}
+

+ 247 - 0
grpc/Mint/Tulip/V1/UpdateRequest.php

@@ -0,0 +1,247 @@
+<?php
+# Generated by the protocol buffer compiler.  DO NOT EDIT!
+# source: tulip.proto
+
+namespace Mint\Tulip\V1;
+
+use Google\Protobuf\Internal\GPBType;
+use Google\Protobuf\Internal\RepeatedField;
+use Google\Protobuf\Internal\GPBUtil;
+
+/**
+ * Generated from protobuf message <code>mint.tulip.v1.UpdateRequest</code>
+ */
+class UpdateRequest extends \Google\Protobuf\Internal\Message
+{
+    /**
+     * Generated from protobuf field <code>int32 book = 1;</code>
+     */
+    protected $book = 0;
+    /**
+     * Generated from protobuf field <code>int32 paragraph = 2;</code>
+     */
+    protected $paragraph = 0;
+    /**
+     * Generated from protobuf field <code>int32 level = 3;</code>
+     */
+    protected $level = 0;
+    /**
+     * Generated from protobuf field <code>string bold1 = 4;</code>
+     */
+    protected $bold1 = '';
+    /**
+     * Generated from protobuf field <code>string bold2 = 5;</code>
+     */
+    protected $bold2 = '';
+    /**
+     * Generated from protobuf field <code>string bold3 = 6;</code>
+     */
+    protected $bold3 = '';
+    /**
+     * Generated from protobuf field <code>string content = 7;</code>
+     */
+    protected $content = '';
+    /**
+     * Generated from protobuf field <code>int32 pcd_book_id = 8;</code>
+     */
+    protected $pcd_book_id = 0;
+
+    /**
+     * Constructor.
+     *
+     * @param array $data {
+     *     Optional. Data for populating the Message object.
+     *
+     *     @type int $book
+     *     @type int $paragraph
+     *     @type int $level
+     *     @type string $bold1
+     *     @type string $bold2
+     *     @type string $bold3
+     *     @type string $content
+     *     @type int $pcd_book_id
+     * }
+     */
+    public function __construct($data = NULL) {
+        \GPBMetadata\Tulip::initOnce();
+        parent::__construct($data);
+    }
+
+    /**
+     * Generated from protobuf field <code>int32 book = 1;</code>
+     * @return int
+     */
+    public function getBook()
+    {
+        return $this->book;
+    }
+
+    /**
+     * Generated from protobuf field <code>int32 book = 1;</code>
+     * @param int $var
+     * @return $this
+     */
+    public function setBook($var)
+    {
+        GPBUtil::checkInt32($var);
+        $this->book = $var;
+
+        return $this;
+    }
+
+    /**
+     * Generated from protobuf field <code>int32 paragraph = 2;</code>
+     * @return int
+     */
+    public function getParagraph()
+    {
+        return $this->paragraph;
+    }
+
+    /**
+     * Generated from protobuf field <code>int32 paragraph = 2;</code>
+     * @param int $var
+     * @return $this
+     */
+    public function setParagraph($var)
+    {
+        GPBUtil::checkInt32($var);
+        $this->paragraph = $var;
+
+        return $this;
+    }
+
+    /**
+     * Generated from protobuf field <code>int32 level = 3;</code>
+     * @return int
+     */
+    public function getLevel()
+    {
+        return $this->level;
+    }
+
+    /**
+     * Generated from protobuf field <code>int32 level = 3;</code>
+     * @param int $var
+     * @return $this
+     */
+    public function setLevel($var)
+    {
+        GPBUtil::checkInt32($var);
+        $this->level = $var;
+
+        return $this;
+    }
+
+    /**
+     * Generated from protobuf field <code>string bold1 = 4;</code>
+     * @return string
+     */
+    public function getBold1()
+    {
+        return $this->bold1;
+    }
+
+    /**
+     * Generated from protobuf field <code>string bold1 = 4;</code>
+     * @param string $var
+     * @return $this
+     */
+    public function setBold1($var)
+    {
+        GPBUtil::checkString($var, True);
+        $this->bold1 = $var;
+
+        return $this;
+    }
+
+    /**
+     * Generated from protobuf field <code>string bold2 = 5;</code>
+     * @return string
+     */
+    public function getBold2()
+    {
+        return $this->bold2;
+    }
+
+    /**
+     * Generated from protobuf field <code>string bold2 = 5;</code>
+     * @param string $var
+     * @return $this
+     */
+    public function setBold2($var)
+    {
+        GPBUtil::checkString($var, True);
+        $this->bold2 = $var;
+
+        return $this;
+    }
+
+    /**
+     * Generated from protobuf field <code>string bold3 = 6;</code>
+     * @return string
+     */
+    public function getBold3()
+    {
+        return $this->bold3;
+    }
+
+    /**
+     * Generated from protobuf field <code>string bold3 = 6;</code>
+     * @param string $var
+     * @return $this
+     */
+    public function setBold3($var)
+    {
+        GPBUtil::checkString($var, True);
+        $this->bold3 = $var;
+
+        return $this;
+    }
+
+    /**
+     * Generated from protobuf field <code>string content = 7;</code>
+     * @return string
+     */
+    public function getContent()
+    {
+        return $this->content;
+    }
+
+    /**
+     * Generated from protobuf field <code>string content = 7;</code>
+     * @param string $var
+     * @return $this
+     */
+    public function setContent($var)
+    {
+        GPBUtil::checkString($var, True);
+        $this->content = $var;
+
+        return $this;
+    }
+
+    /**
+     * Generated from protobuf field <code>int32 pcd_book_id = 8;</code>
+     * @return int
+     */
+    public function getPcdBookId()
+    {
+        return $this->pcd_book_id;
+    }
+
+    /**
+     * Generated from protobuf field <code>int32 pcd_book_id = 8;</code>
+     * @param int $var
+     * @return $this
+     */
+    public function setPcdBookId($var)
+    {
+        GPBUtil::checkInt32($var);
+        $this->pcd_book_id = $var;
+
+        return $this;
+    }
+
+}
+

+ 58 - 0
grpc/Mint/Tulip/V1/UpdateResponse.php

@@ -0,0 +1,58 @@
+<?php
+# Generated by the protocol buffer compiler.  DO NOT EDIT!
+# source: tulip.proto
+
+namespace Mint\Tulip\V1;
+
+use Google\Protobuf\Internal\GPBType;
+use Google\Protobuf\Internal\RepeatedField;
+use Google\Protobuf\Internal\GPBUtil;
+
+/**
+ * Generated from protobuf message <code>mint.tulip.v1.UpdateResponse</code>
+ */
+class UpdateResponse extends \Google\Protobuf\Internal\Message
+{
+    /**
+     * Generated from protobuf field <code>int32 count = 1;</code>
+     */
+    protected $count = 0;
+
+    /**
+     * Constructor.
+     *
+     * @param array $data {
+     *     Optional. Data for populating the Message object.
+     *
+     *     @type int $count
+     * }
+     */
+    public function __construct($data = NULL) {
+        \GPBMetadata\Tulip::initOnce();
+        parent::__construct($data);
+    }
+
+    /**
+     * Generated from protobuf field <code>int32 count = 1;</code>
+     * @return int
+     */
+    public function getCount()
+    {
+        return $this->count;
+    }
+
+    /**
+     * Generated from protobuf field <code>int32 count = 1;</code>
+     * @param int $var
+     * @return $this
+     */
+    public function setCount($var)
+    {
+        GPBUtil::checkInt32($var);
+        $this->count = $var;
+
+        return $this;
+    }
+
+}
+

+ 58 - 0
grpc/Mint/Tulip/V1/UploadDictionaryRequest.php

@@ -0,0 +1,58 @@
+<?php
+# Generated by the protocol buffer compiler.  DO NOT EDIT!
+# source: tulip.proto
+
+namespace Mint\Tulip\V1;
+
+use Google\Protobuf\Internal\GPBType;
+use Google\Protobuf\Internal\RepeatedField;
+use Google\Protobuf\Internal\GPBUtil;
+
+/**
+ * Generated from protobuf message <code>mint.tulip.v1.UploadDictionaryRequest</code>
+ */
+class UploadDictionaryRequest extends \Google\Protobuf\Internal\Message
+{
+    /**
+     * Generated from protobuf field <code>string data = 1;</code>
+     */
+    protected $data = '';
+
+    /**
+     * Constructor.
+     *
+     * @param array $data {
+     *     Optional. Data for populating the Message object.
+     *
+     *     @type string $data
+     * }
+     */
+    public function __construct($data = NULL) {
+        \GPBMetadata\Tulip::initOnce();
+        parent::__construct($data);
+    }
+
+    /**
+     * Generated from protobuf field <code>string data = 1;</code>
+     * @return string
+     */
+    public function getData()
+    {
+        return $this->data;
+    }
+
+    /**
+     * Generated from protobuf field <code>string data = 1;</code>
+     * @param string $var
+     * @return $this
+     */
+    public function setData($var)
+    {
+        GPBUtil::checkString($var, True);
+        $this->data = $var;
+
+        return $this;
+    }
+
+}
+

+ 58 - 0
grpc/Mint/Tulip/V1/UploadDictionaryResponse.php

@@ -0,0 +1,58 @@
+<?php
+# Generated by the protocol buffer compiler.  DO NOT EDIT!
+# source: tulip.proto
+
+namespace Mint\Tulip\V1;
+
+use Google\Protobuf\Internal\GPBType;
+use Google\Protobuf\Internal\RepeatedField;
+use Google\Protobuf\Internal\GPBUtil;
+
+/**
+ * Generated from protobuf message <code>mint.tulip.v1.UploadDictionaryResponse</code>
+ */
+class UploadDictionaryResponse extends \Google\Protobuf\Internal\Message
+{
+    /**
+     * Generated from protobuf field <code>int32 error = 1;</code>
+     */
+    protected $error = 0;
+
+    /**
+     * Constructor.
+     *
+     * @param array $data {
+     *     Optional. Data for populating the Message object.
+     *
+     *     @type int $error
+     * }
+     */
+    public function __construct($data = NULL) {
+        \GPBMetadata\Tulip::initOnce();
+        parent::__construct($data);
+    }
+
+    /**
+     * Generated from protobuf field <code>int32 error = 1;</code>
+     * @return int
+     */
+    public function getError()
+    {
+        return $this->error;
+    }
+
+    /**
+     * Generated from protobuf field <code>int32 error = 1;</code>
+     * @param int $var
+     * @return $this
+     */
+    public function setError($var)
+    {
+        GPBUtil::checkInt32($var);
+        $this->error = $var;
+
+        return $this;
+    }
+
+}
+