github.com/distbuild/reclient@v0.0.0-20240401075343-3de72e395564/cmd/scandeps/server/scandeps.h (about)

     1  // Copyright 2023 Google LLC
     2  //
     3  // Licensed under the Apache License, Version 2.0 (the "License");
     4  // you may not use this file except in compliance with the License.
     5  // You may obtain a copy of the License at
     6  //
     7  //     http://www.apache.org/licenses/LICENSE-2.0
     8  //
     9  // Unless required by applicable law or agreed to in writing, software
    10  // distributed under the License is distributed on an "AS IS" BASIS,
    11  // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    12  // See the License for the specific language governing permissions and
    13  // limitations under the License.
    14  
    15  // Everything in this header must be implemented by the target dependency
    16  // scanner. Exactly one dependency scanner must be included in the deps of the
    17  // build file.
    18  #ifndef CMD_SCANDEPS_SERVER_SCANDEPS_H_
    19  #define CMD_SCANDEPS_SERVER_SCANDEPS_H_
    20  
    21  #include "api/scandeps/cppscandeps.grpc.pb.h"
    22  
    23  // newDepsScanner is responsible for creating the implemented dependency
    24  // scanner.
    25  // TODO (b/268656738): remove experimental_deadlock and experimental_segfault
    26  scandeps::CPPDepsScanner::Service* newDepsScanner(
    27      std::function<void()> shutdown_server, const char* process_name,
    28      const char* cache_dir, const char* log_dir, int deps_cache_max_mb,
    29      bool enable_deps_cache, uint32_t experimental_deadlock,
    30      uint32_t experimental_segfault);
    31  
    32  // deleteDepsScanner is responsible for destroying the implemented dependency
    33  // scanner.
    34  bool deleteDepsScanner(scandeps::CPPDepsScanner::Service* grpc_service_impl);
    35  
    36  #endif  // CMD_SCANDEPS_SERVER_SCANDEPS_H_