Dialogflow API C++ Client 2.13.0
A C++ Client Library for the Dialogflow API
Loading...
Searching...
No Matches
Public Member Functions | List of all members
google::cloud::dialogflow_es_mocks::MockDocumentsConnection Class Reference

A class to mock DocumentsConnection. More...

#include <google/cloud/dialogflow_es/mocks/mock_documents_connection.h>

Public Member Functions

 MOCK_METHOD (Options, options,(),(override))
 
 MOCK_METHOD (StreamRange< google::cloud::dialogflow::v2::Document >, ListDocuments,(google::cloud::dialogflow::v2::ListDocumentsRequest request),(override))
 
 MOCK_METHOD (StatusOr< google::cloud::dialogflow::v2::Document >, GetDocument,(google::cloud::dialogflow::v2::GetDocumentRequest const &request),(override))
 
 MOCK_METHOD (future< StatusOr< google::cloud::dialogflow::v2::Document > >, CreateDocument,(google::cloud::dialogflow::v2::CreateDocumentRequest const &request),(override))
 
 MOCK_METHOD (future< StatusOr< google::cloud::dialogflow::v2::ImportDocumentsResponse > >, ImportDocuments,(google::cloud::dialogflow::v2::ImportDocumentsRequest const &request),(override))
 
 MOCK_METHOD (future< StatusOr< google::cloud::dialogflow::v2::KnowledgeOperationMetadata > >, DeleteDocument,(google::cloud::dialogflow::v2::DeleteDocumentRequest const &request),(override))
 
 MOCK_METHOD (future< StatusOr< google::cloud::dialogflow::v2::Document > >, UpdateDocument,(google::cloud::dialogflow::v2::UpdateDocumentRequest const &request),(override))
 
 MOCK_METHOD (future< StatusOr< google::cloud::dialogflow::v2::Document > >, ReloadDocument,(google::cloud::dialogflow::v2::ReloadDocumentRequest const &request),(override))
 
 MOCK_METHOD (future< StatusOr< google::cloud::dialogflow::v2::Document > >, ExportDocument,(google::cloud::dialogflow::v2::ExportDocumentRequest const &request),(override))
 
virtual Options options ()
 
virtual StreamRange< google::cloud::dialogflow::v2::Document > ListDocuments (google::cloud::dialogflow::v2::ListDocumentsRequest request)
 
virtual StatusOr< google::cloud::dialogflow::v2::Document > GetDocument (google::cloud::dialogflow::v2::GetDocumentRequest const &request)
 
virtual future< StatusOr< google::cloud::dialogflow::v2::Document > > CreateDocument (google::cloud::dialogflow::v2::CreateDocumentRequest const &request)
 
virtual future< StatusOr< google::cloud::dialogflow::v2::ImportDocumentsResponse > > ImportDocuments (google::cloud::dialogflow::v2::ImportDocumentsRequest const &request)
 
virtual future< StatusOr< google::cloud::dialogflow::v2::KnowledgeOperationMetadata > > DeleteDocument (google::cloud::dialogflow::v2::DeleteDocumentRequest const &request)
 
virtual future< StatusOr< google::cloud::dialogflow::v2::Document > > UpdateDocument (google::cloud::dialogflow::v2::UpdateDocumentRequest const &request)
 
virtual future< StatusOr< google::cloud::dialogflow::v2::Document > > ReloadDocument (google::cloud::dialogflow::v2::ReloadDocumentRequest const &request)
 
virtual future< StatusOr< google::cloud::dialogflow::v2::Document > > ExportDocument (google::cloud::dialogflow::v2::ExportDocumentRequest const &request)
 

Detailed Description

A class to mock DocumentsConnection.

Application developers may want to test their code with simulated responses, including errors, from an object of type DocumentsClient. To do so, construct an object of type DocumentsClient with an instance of this class. Then use the Google Test framework functions to program the behavior of this mock.

See also
This example for how to test your application with GoogleTest. While the example showcases types from the BigQuery library, the underlying principles apply for any pair of *Client and *Connection.

Member Function Documentation

◆ CreateDocument()

virtual future< StatusOr< google::cloud::dialogflow::v2::Document > > google::cloud::dialogflow_es::DocumentsConnection::CreateDocument ( google::cloud::dialogflow::v2::CreateDocumentRequest const &  request)
virtualinherited

◆ DeleteDocument()

virtual future< StatusOr< google::cloud::dialogflow::v2::KnowledgeOperationMetadata > > google::cloud::dialogflow_es::DocumentsConnection::DeleteDocument ( google::cloud::dialogflow::v2::DeleteDocumentRequest const &  request)
virtualinherited

◆ ExportDocument()

virtual future< StatusOr< google::cloud::dialogflow::v2::Document > > google::cloud::dialogflow_es::DocumentsConnection::ExportDocument ( google::cloud::dialogflow::v2::ExportDocumentRequest const &  request)
virtualinherited

◆ GetDocument()

virtual StatusOr< google::cloud::dialogflow::v2::Document > google::cloud::dialogflow_es::DocumentsConnection::GetDocument ( google::cloud::dialogflow::v2::GetDocumentRequest const &  request)
virtualinherited

◆ ImportDocuments()

virtual future< StatusOr< google::cloud::dialogflow::v2::ImportDocumentsResponse > > google::cloud::dialogflow_es::DocumentsConnection::ImportDocuments ( google::cloud::dialogflow::v2::ImportDocumentsRequest const &  request)
virtualinherited

◆ ListDocuments()

virtual StreamRange< google::cloud::dialogflow::v2::Document > google::cloud::dialogflow_es::DocumentsConnection::ListDocuments ( google::cloud::dialogflow::v2::ListDocumentsRequest  request)
virtualinherited

◆ MOCK_METHOD() [1/9]

google::cloud::dialogflow_es_mocks::MockDocumentsConnection::MOCK_METHOD ( future< StatusOr< google::cloud::dialogflow::v2::Document > >  ,
CreateDocument  ,
(google::cloud::dialogflow::v2::CreateDocumentRequest const &request)  ,
(override)   
)

◆ MOCK_METHOD() [2/9]

google::cloud::dialogflow_es_mocks::MockDocumentsConnection::MOCK_METHOD ( future< StatusOr< google::cloud::dialogflow::v2::Document > >  ,
ExportDocument  ,
(google::cloud::dialogflow::v2::ExportDocumentRequest const &request)  ,
(override)   
)

◆ MOCK_METHOD() [3/9]

google::cloud::dialogflow_es_mocks::MockDocumentsConnection::MOCK_METHOD ( future< StatusOr< google::cloud::dialogflow::v2::Document > >  ,
ReloadDocument  ,
(google::cloud::dialogflow::v2::ReloadDocumentRequest const &request)  ,
(override)   
)

◆ MOCK_METHOD() [4/9]

google::cloud::dialogflow_es_mocks::MockDocumentsConnection::MOCK_METHOD ( future< StatusOr< google::cloud::dialogflow::v2::Document > >  ,
UpdateDocument  ,
(google::cloud::dialogflow::v2::UpdateDocumentRequest const &request)  ,
(override)   
)

◆ MOCK_METHOD() [5/9]

google::cloud::dialogflow_es_mocks::MockDocumentsConnection::MOCK_METHOD ( future< StatusOr< google::cloud::dialogflow::v2::ImportDocumentsResponse > >  ,
ImportDocuments  ,
(google::cloud::dialogflow::v2::ImportDocumentsRequest const &request)  ,
(override)   
)

◆ MOCK_METHOD() [6/9]

google::cloud::dialogflow_es_mocks::MockDocumentsConnection::MOCK_METHOD ( future< StatusOr< google::cloud::dialogflow::v2::KnowledgeOperationMetadata > >  ,
DeleteDocument  ,
(google::cloud::dialogflow::v2::DeleteDocumentRequest const &request)  ,
(override)   
)

◆ MOCK_METHOD() [7/9]

google::cloud::dialogflow_es_mocks::MockDocumentsConnection::MOCK_METHOD ( Options  ,
options  ,
()  ,
(override)   
)

◆ MOCK_METHOD() [8/9]

google::cloud::dialogflow_es_mocks::MockDocumentsConnection::MOCK_METHOD ( StatusOr< google::cloud::dialogflow::v2::Document >  ,
GetDocument  ,
(google::cloud::dialogflow::v2::GetDocumentRequest const &request)  ,
(override)   
)

◆ MOCK_METHOD() [9/9]

google::cloud::dialogflow_es_mocks::MockDocumentsConnection::MOCK_METHOD ( StreamRange< google::cloud::dialogflow::v2::Document >  ,
ListDocuments  ,
(google::cloud::dialogflow::v2::ListDocumentsRequest request)  ,
(override)   
)

◆ options()

virtual Options google::cloud::dialogflow_es::DocumentsConnection::options ( )
inlinevirtualinherited

◆ ReloadDocument()

virtual future< StatusOr< google::cloud::dialogflow::v2::Document > > google::cloud::dialogflow_es::DocumentsConnection::ReloadDocument ( google::cloud::dialogflow::v2::ReloadDocumentRequest const &  request)
virtualinherited

◆ UpdateDocument()

virtual future< StatusOr< google::cloud::dialogflow::v2::Document > > google::cloud::dialogflow_es::DocumentsConnection::UpdateDocument ( google::cloud::dialogflow::v2::UpdateDocumentRequest const &  request)
virtualinherited