Added grpc++.h with mainpage docs.

Minor fixes to previously existing docs.
pull/3074/head
David Garcia Quintas 9 years ago
parent ca1bbd3c8c
commit 14111e9da1
  1. 2
      BUILD
  2. 2
      Makefile
  3. 1
      build.json
  4. 2
      examples/cpp/helloworld/greeter_async_client.cc
  5. 12
      include/grpc++/channel.h
  6. 6
      include/grpc++/completion_queue.h
  7. 64
      include/grpc++/grpc++.h
  8. 8
      include/grpc/grpc.h
  9. 1
      tools/doxygen/Doxyfile.c++
  10. 1
      tools/doxygen/Doxyfile.c++.internal
  11. 4
      tools/run_tests/sources_and_headers.json
  12. 1
      vsprojects/grpc++/grpc++.vcxproj
  13. 3
      vsprojects/grpc++/grpc++.vcxproj.filters
  14. 1
      vsprojects/grpc++_unsecure/grpc++_unsecure.vcxproj
  15. 3
      vsprojects/grpc++_unsecure/grpc++_unsecure.vcxproj.filters

@ -729,6 +729,7 @@ cc_library(
"include/grpc++/create_channel.h",
"include/grpc++/generic/async_generic_service.h",
"include/grpc++/generic/generic_stub.h",
"include/grpc++/grpc++.h",
"include/grpc++/impl/call.h",
"include/grpc++/impl/client_unary_call.h",
"include/grpc++/impl/grpc_library.h",
@ -819,6 +820,7 @@ cc_library(
"include/grpc++/create_channel.h",
"include/grpc++/generic/async_generic_service.h",
"include/grpc++/generic/generic_stub.h",
"include/grpc++/grpc++.h",
"include/grpc++/impl/call.h",
"include/grpc++/impl/client_unary_call.h",
"include/grpc++/impl/grpc_library.h",

@ -4593,6 +4593,7 @@ PUBLIC_HEADERS_CXX += \
include/grpc++/create_channel.h \
include/grpc++/generic/async_generic_service.h \
include/grpc++/generic/generic_stub.h \
include/grpc++/grpc++.h \
include/grpc++/impl/call.h \
include/grpc++/impl/client_unary_call.h \
include/grpc++/impl/grpc_library.h \
@ -4838,6 +4839,7 @@ PUBLIC_HEADERS_CXX += \
include/grpc++/create_channel.h \
include/grpc++/generic/async_generic_service.h \
include/grpc++/generic/generic_stub.h \
include/grpc++/grpc++.h \
include/grpc++/impl/call.h \
include/grpc++/impl/client_unary_call.h \
include/grpc++/impl/grpc_library.h \

@ -38,6 +38,7 @@
"include/grpc++/create_channel.h",
"include/grpc++/generic/async_generic_service.h",
"include/grpc++/generic/generic_stub.h",
"include/grpc++/grpc++.h",
"include/grpc++/impl/call.h",
"include/grpc++/impl/client_unary_call.h",
"include/grpc++/impl/grpc_library.h",

@ -75,7 +75,7 @@ class GreeterClient {
ClientContext context;
// The producer-consumer queue we use to communicate asynchronously with the
// gRPC runtmie.
// gRPC runtime.
CompletionQueue cq;
// Storage for the status of the RPC upon completion.

@ -72,12 +72,12 @@ class Channel GRPC_FINAL : public GrpcLibrary,
public:
~Channel();
/// Get the current channel state. If the channel is in IDLE and try_to_connect
/// is set to true, try to connect.
/// Get the current channel state. If the channel is in IDLE and
/// \a try_to_connect is set to true, try to connect.
grpc_connectivity_state GetState(bool try_to_connect);
/// Return the tag on cq when the channel state is changed or deadline expires.
/// GetState needs to called to get the current state.
/// Return the \a tag on \a cq when the channel state is changed or \a
/// deadline expires. \a GetState needs to called to get the current state.
template <typename T>
void NotifyOnStateChange(grpc_connectivity_state last_observed, T deadline,
CompletionQueue* cq, void* tag) {
@ -85,8 +85,8 @@ class Channel GRPC_FINAL : public GrpcLibrary,
NotifyOnStateChangeImpl(last_observed, deadline_tp.raw_time(), cq, tag);
}
/// Blocking wait for channel state change or deadline expiration.
/// GetState needs to called to get the current state.
/// Blocking wait for channel state change or \a deadline expiration.
/// \a GetState needs to called to get the current state.
template <typename T>
bool WaitForStateChange(grpc_connectivity_state last_observed, T deadline) {
TimePoint<T> deadline_tp(deadline);

@ -77,8 +77,8 @@ class Server;
class ServerBuilder;
class ServerContext;
// This class is a thin wrapper around \a grpc_completion_queue (see
// \a src/core/surface/completion_queue.h).
/// A thin wrapper around \a grpc_completion_queue (see / \a
/// src/core/surface/completion_queue.h).
class CompletionQueue : public GrpcLibrary {
public:
/// Default constructor. Implicitly creates a \a grpc_completion_queue
@ -86,7 +86,7 @@ class CompletionQueue : public GrpcLibrary {
CompletionQueue();
/// Wrap \a take, taking ownership of the instance.
///
///
/// \param take The completion queue instance to wrap. Ownership is taken.
explicit CompletionQueue(grpc_completion_queue* take);

@ -0,0 +1,64 @@
/*
*
* Copyright 2015, Google Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are
* met:
*
* * Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* * Redistributions in binary form must reproduce the above
* copyright notice, this list of conditions and the following disclaimer
* in the documentation and/or other materials provided with the
* distribution.
* * Neither the name of Google Inc. nor the names of its
* contributors may be used to endorse or promote products derived from
* this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
* A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
* OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
*/
/// \mainpage gRPC C++ API
///
/// The gRPC C++ API mainly consists of the following classes:
/// - grpc::Channel, which represents the connection to an endpoint. See [the
/// gRPC Concepts page](http://www.grpc.io/docs/guides/concepts.html) for more
/// details. Channels are created by the factory function grpc::CreateChannel.
/// - grpc::CompletionQueue, the producer-consumer queue used for all
/// asynchronous communication with the gRPC runtime.
/// - grpc::ClientContext and grpc::ServerContext, where optional configuration
/// for an RPC can be set, such as setting custom metadata to be conveyed to the
/// peer, compression settings, authentication, etc.
/// - grpc::Server, representing a gRPC server, created by grpc::ServerBuilder.
///
/// Refer to the [examples](https://github.com/grpc/grpc/blob/master/examples/cpp)
/// for code putting these pieces into play.
#ifndef GRPCXX_GRPCXX_H
#define GRPCXX_GRPCXX_H
#include <grpc/grpc.h>
#include <grpc++/channel.h>
#include <grpc++/client_context.h>
#include <grpc++/completion_queue.h>
#include <grpc++/create_channel.h>
#include <grpc++/server.h>
#include <grpc++/server_builder.h>
#include <grpc++/server_context.h>
#endif // GRPCXX_GRPCXX_H

@ -47,11 +47,9 @@ extern "C" {
/*! \mainpage GRPC Core
*
* \section intro_sec The GRPC Core library is a low-level library designed
* to be wrapped by higher level libraries.
*
* The top-level API is provided in grpc.h.
* Security related functionality lives in grpc_security.h.
* The GRPC Core library is a low-level library designed to be wrapped by higher
* level libraries. The top-level API is provided in grpc.h. Security related
* functionality lives in grpc_security.h.
*/
/** Completion Queues enable notification of the completion of asynchronous

@ -766,6 +766,7 @@ include/grpc++/completion_queue.h \
include/grpc++/create_channel.h \
include/grpc++/generic/async_generic_service.h \
include/grpc++/generic/generic_stub.h \
include/grpc++/grpc++.h \
include/grpc++/impl/call.h \
include/grpc++/impl/client_unary_call.h \
include/grpc++/impl/grpc_library.h \

@ -766,6 +766,7 @@ include/grpc++/completion_queue.h \
include/grpc++/create_channel.h \
include/grpc++/generic/async_generic_service.h \
include/grpc++/generic/generic_stub.h \
include/grpc++/grpc++.h \
include/grpc++/impl/call.h \
include/grpc++/impl/client_unary_call.h \
include/grpc++/impl/grpc_library.h \

@ -13094,6 +13094,7 @@
"include/grpc++/create_channel.h",
"include/grpc++/generic/async_generic_service.h",
"include/grpc++/generic/generic_stub.h",
"include/grpc++/grpc++.h",
"include/grpc++/impl/call.h",
"include/grpc++/impl/client_unary_call.h",
"include/grpc++/impl/grpc_library.h",
@ -13146,6 +13147,7 @@
"include/grpc++/create_channel.h",
"include/grpc++/generic/async_generic_service.h",
"include/grpc++/generic/generic_stub.h",
"include/grpc++/grpc++.h",
"include/grpc++/impl/call.h",
"include/grpc++/impl/client_unary_call.h",
"include/grpc++/impl/grpc_library.h",
@ -13276,6 +13278,7 @@
"include/grpc++/create_channel.h",
"include/grpc++/generic/async_generic_service.h",
"include/grpc++/generic/generic_stub.h",
"include/grpc++/grpc++.h",
"include/grpc++/impl/call.h",
"include/grpc++/impl/client_unary_call.h",
"include/grpc++/impl/grpc_library.h",
@ -13325,6 +13328,7 @@
"include/grpc++/create_channel.h",
"include/grpc++/generic/async_generic_service.h",
"include/grpc++/generic/generic_stub.h",
"include/grpc++/grpc++.h",
"include/grpc++/impl/call.h",
"include/grpc++/impl/client_unary_call.h",
"include/grpc++/impl/grpc_library.h",

@ -219,6 +219,7 @@
<ClInclude Include="..\..\include\grpc++\create_channel.h" />
<ClInclude Include="..\..\include\grpc++\generic\async_generic_service.h" />
<ClInclude Include="..\..\include\grpc++\generic\generic_stub.h" />
<ClInclude Include="..\..\include\grpc++\grpc++.h" />
<ClInclude Include="..\..\include\grpc++\impl\call.h" />
<ClInclude Include="..\..\include\grpc++\impl\client_unary_call.h" />
<ClInclude Include="..\..\include\grpc++\impl\grpc_library.h" />

@ -117,6 +117,9 @@
<ClInclude Include="..\..\include\grpc++\generic\generic_stub.h">
<Filter>include\grpc++\generic</Filter>
</ClInclude>
<ClInclude Include="..\..\include\grpc++\grpc++.h">
<Filter>include\grpc++</Filter>
</ClInclude>
<ClInclude Include="..\..\include\grpc++\impl\call.h">
<Filter>include\grpc++\impl</Filter>
</ClInclude>

@ -219,6 +219,7 @@
<ClInclude Include="..\..\include\grpc++\create_channel.h" />
<ClInclude Include="..\..\include\grpc++\generic\async_generic_service.h" />
<ClInclude Include="..\..\include\grpc++\generic\generic_stub.h" />
<ClInclude Include="..\..\include\grpc++\grpc++.h" />
<ClInclude Include="..\..\include\grpc++\impl\call.h" />
<ClInclude Include="..\..\include\grpc++\impl\client_unary_call.h" />
<ClInclude Include="..\..\include\grpc++\impl\grpc_library.h" />

@ -102,6 +102,9 @@
<ClInclude Include="..\..\include\grpc++\generic\generic_stub.h">
<Filter>include\grpc++\generic</Filter>
</ClInclude>
<ClInclude Include="..\..\include\grpc++\grpc++.h">
<Filter>include\grpc++</Filter>
</ClInclude>
<ClInclude Include="..\..\include\grpc++\impl\call.h">
<Filter>include\grpc++\impl</Filter>
</ClInclude>

Loading…
Cancel
Save