# Generated by the protocol buffer compiler.  DO NOT EDIT!
# Source: transfer.proto for package 'transfersdk'

require 'grpc'
require 'transfer_pb'

module Transfersdk
  module TransferService
    #
    # Transfer service definition. This service enables users to start, manage and monitor transfers.
    # You can also  get information about the transfer service settings and confirm the availability of
    # communication between the engine and a remote transfer server.
    class Service

      include ::GRPC::GenericService

      self.marshal_class_method = :encode
      self.unmarshal_class_method = :decode
      self.service_name = 'transfersdk.TransferService'

      #
      # Validate accepts a transfer spec string and a transfer type, and returns the validation result.
      rpc :Validate, ::Transfersdk::ValidationRequest, ::Transfersdk::ValidationResponse
      #
      # StartTransfer starts a new transfer and returns the transfer information required to manage and monitor the transfer.
      # This request doesn't close until the transfer is terminated or the request is canceled by the client.
      rpc :StartTransfer, ::Transfersdk::TransferRequest, ::Transfersdk::StartTransferResponse
      #
      # StartTransferWithMonitor starts a new transfer and streams back the transfer events.
      # The request doesn't return immediately, as it continues streaming responses to the client until the transfer is terminated or the request is canceled
      # by the client.
      rpc :StartTransferWithMonitor, ::Transfersdk::TransferRequest, stream(::Transfersdk::TransferResponse)
      #
      # QueryTransfer requests transfer data.
      rpc :QueryTransfer, ::Transfersdk::TransferInfoRequest, ::Transfersdk::QueryTransferResponse
      #
      # ModifyTransfer modifies an existing transfer.
      rpc :ModifyTransfer, ::Transfersdk::TransferModificationRequest, ::Transfersdk::TransferModificationResponse
      #
      # AddTransferPaths can be used with persistent transfer to add paths to an existing transfer.
      # (type TransferType.FILE_PERSISTENT).
      rpc :AddTransferPaths, ::Transfersdk::TransferPathRequest, ::Transfersdk::TransferPathResponse
      #
      # LockPersistentTransfer, used with persistent transfer, marks an existing persistent transfer as done.
      # Once the method is called, any subsequent call to AddTransferPaths results in an error.
      # (type TransferType.FILE_PERSISTENT).
      rpc :LockPersistentTransfer, ::Transfersdk::LockPersistentTransferRequest, ::Transfersdk::LockPersistentTransferResponse
      #
      # StopTransfer stops a transfer.
      rpc :StopTransfer, ::Transfersdk::StopTransferRequest, ::Transfersdk::StopTransferResponse
      #
      # MonitorTransfers monitors transfers matching the defined filters and streams back the transfer events.
      # The request doesn't return an immediate response because MonitorTransfers continues streaming
      # responses to the client until the client cancels the request.
      rpc :MonitorTransfers, ::Transfersdk::RegistrationRequest, stream(::Transfersdk::TransferResponse)
      #
      # GetAPIVersion gets the API version.
      rpc :GetAPIVersion, ::Transfersdk::APIVersionRequest, ::Transfersdk::APIVersionResponse
      #
      # GetInfo gets data about the Transfer SDK service instance.
      rpc :GetInfo, ::Transfersdk::InstanceInfoRequest, ::Transfersdk::InstanceInfoResponse
      #
      # IsPeerReachable confirms whether or not the peer endpoint is reachable.
      rpc :IsPeerReachable, ::Transfersdk::PeerCheckRequest, ::Transfersdk::PeerCheckResponse
      #
      # WriteStreamChunk writes chunks of streaming data for the specified in-progress
      # transfer of type PERSISTENT_STREAM_UPLOAD, at a specific offset.
      # When StopTransfer is called on the transfer, subsequent calls to this function will fail.
      rpc :WriteStreamChunk, stream(::Transfersdk::WriteStreamChunkRequest), ::Transfersdk::WriteStreamChunkResponse
      #
      # WriteStream writes chunks of streaming data for the specified in-progress transfer of type STREAM_TO_FILE_UPLOAD.
      # Once StopTransfer is called on the transfer, subsequent calls to this function will fail.
      rpc :WriteStream, stream(::Transfersdk::WriteStreamRequest), ::Transfersdk::WriteStreamResponse
      #
      # ReadStream reads chunks of streaming data from a specified in-progress transfer of type FILE_TO_STREAM_DOWNLOAD.
      # Once StopTransfer is called on this transfer, subsequent calls to this function will fail.
      rpc :ReadStream, ::Transfersdk::ReadStreamRequest, stream(::Transfersdk::ReadStreamResponse)
    end

    Stub = Service.rpc_stub_class
  end
end
