Trait CodebaseRpcServer

Source
pub trait CodebaseRpcServer:
    Sized
    + Send
    + Sync
    + 'static {
    // Required methods
    fn process_local_codebase<'life0, 'async_trait>(
        &'life0 self,
        request: ProcessLocalRequest,
    ) -> Pin<Box<dyn Future<Output = RpcResult<ProcessLocalResponse>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn process_remote_repo<'life0, 'async_trait>(
        &'life0 self,
        request: ProcessRemoteRequest,
    ) -> Pin<Box<dyn Future<Output = RpcResult<ProcessRemoteResponse>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn get_file_metadata<'life0, 'async_trait>(
        &'life0 self,
        request: GetFileMetadataRequest,
    ) -> Pin<Box<dyn Future<Output = RpcResult<GetFileMetadataResponse>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn search_codebase<'life0, 'async_trait>(
        &'life0 self,
        request: SearchCodebaseRequest,
    ) -> Pin<Box<dyn Future<Output = RpcResult<SearchCodebaseResponse>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn diff_files<'life0, 'async_trait>(
        &'life0 self,
        request: DiffFilesRequest,
    ) -> Pin<Box<dyn Future<Output = RpcResult<DiffFilesResponse>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn semantic_search<'life0, 'async_trait>(
        &'life0 self,
        request: SemanticSearchRequest,
    ) -> Pin<Box<dyn Future<Output = RpcResult<SemanticSearchResponse>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;

    // Provided method
    fn into_rpc(self) -> RpcModule<Self> { ... }
}
Expand description

Server trait implementation for the CodebaseRpc RPC API.

Required Methods§

Source

fn process_local_codebase<'life0, 'async_trait>( &'life0 self, request: ProcessLocalRequest, ) -> Pin<Box<dyn Future<Output = RpcResult<ProcessLocalResponse>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Process a local codebase directory

Source

fn process_remote_repo<'life0, 'async_trait>( &'life0 self, request: ProcessRemoteRequest, ) -> Pin<Box<dyn Future<Output = RpcResult<ProcessRemoteResponse>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Process a remote repository

Source

fn get_file_metadata<'life0, 'async_trait>( &'life0 self, request: GetFileMetadataRequest, ) -> Pin<Box<dyn Future<Output = RpcResult<GetFileMetadataResponse>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get metadata for a specific file

Source

fn search_codebase<'life0, 'async_trait>( &'life0 self, request: SearchCodebaseRequest, ) -> Pin<Box<dyn Future<Output = RpcResult<SearchCodebaseResponse>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Search codebase for a query string

Source

fn diff_files<'life0, 'async_trait>( &'life0 self, request: DiffFilesRequest, ) -> Pin<Box<dyn Future<Output = RpcResult<DiffFilesResponse>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get diff between two files

Perform semantic search across codebase

Provided Methods§

Source

fn into_rpc(self) -> RpcModule<Self>

Collects all the methods and subscriptions defined in the trait and adds them into a single RpcModule.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§