Skip to content

Commit

Permalink
commit configure input file
Browse files Browse the repository at this point in the history
  • Loading branch information
lia-viam committed Dec 18, 2024
1 parent 772efcb commit fc38fff
Showing 1 changed file with 55 additions and 0 deletions.
55 changes: 55 additions & 0 deletions src/viam/sdk/common/grpc_client_fwd.hpp.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
#pragma once

#cmakedefine VIAMCPPSDK_GRPCXX_LEGACY_CLIENT_FWD

#ifndef VIAMCPPSDK_GRPCXX_LEGACY_CLIENT_FWD

// Forward declaration file for grpc ClientContext and ClientReaderInterface<T>.
// This file provides includes for recent (>= 1.32.0) versions of grpc.

namespace grpc {

class ClientContext;

template <typename>
class ClientReaderInterface;

} // namespace grpc

namespace viam {
namespace sdk {

using GrpcClientContext = ::grpc::ClientContext;

template <typename T>
using GrpcClientReaderInterface = ::grpc::ClientReaderInterface<T>;

} // namespace sdk
} // namespace viam

#else

// Forward declaration file for grpc ClientContext and ClientReaderInterface<T>.
// This file provides includes for the oldest supported versions of grpc (< 1.32.0).

namespace grpc_impl {

class ClientContext;

template <typename>
class ClientReaderInterface;

} // namespace grpc_impl

namespace viam {
namespace sdk {

using GrpcClientContext = ::grpc_impl::ClientContext;

template <typename T>
using GrpcClientReaderInterface = ::grpc_impl::ClientReaderInterface<T>;

} // namespace sdk
} // namespace viam

#endif

0 comments on commit fc38fff

Please sign in to comment.