GrpcServer di gestione dispositivi

public class DeviceManagementGrpcServer
extends DeviceManagementGrpc.DeviceManagementImplBase

java.lang.Object
🎞 com.proto.tradefed.device.DeviceManagementGrpc.DeviceManagementImplBase
  🎞 com.android.tradefed.service.management.DeviceManagementGrpcServer


Server GRPC che consente di prenotare un dispositivo da Tradefed.

Riepilogo

Costruttori pubblici

DeviceManagementGrpcServer(int port, IDeviceManager deviceManager, ICommandScheduler scheduler)
DeviceManagementGrpcServer(ServerBuilder<?> serverBuilder, IDeviceManager deviceManager, ICommandScheduler scheduler)
DeviceManagementGrpcServer(Server server, IDeviceManager deviceManager, ICommandScheduler scheduler)

Metodi pubblici

ITestDevice getDeviceFromReservation(String reservationId)
void getDevicesStatus(GetDevicesStatusRequest request, StreamObserver<GetDevicesStatusResponse> responseObserver)
static Integer getPort()

Restituisce la porta utilizzata dal server.

void releaseReservation(ReleaseReservationRequest request, StreamObserver<ReleaseReservationResponse> responseObserver)
void reserveDevice(ReserveDeviceRequest request, StreamObserver<ReserveDeviceResponse> responseObserver)
void shutdown()

Arresta il server GRpc.

void start()

Avvia il server GRpc.

void stopLeasing(StopLeasingRequest request, StreamObserver<StopLeasingResponse> responseObserver)

Costruttori pubblici

GrpcServer di gestione dispositivi

public DeviceManagementGrpcServer (int port, 
                IDeviceManager deviceManager, 
                ICommandScheduler scheduler)

Parametri
port int

deviceManager IDeviceManager

scheduler ICommandScheduler

GrpcServer di gestione dispositivi

public DeviceManagementGrpcServer (ServerBuilder<?> serverBuilder, 
                IDeviceManager deviceManager, 
                ICommandScheduler scheduler)

Parametri
serverBuilder ServerBuilder

deviceManager IDeviceManager

scheduler ICommandScheduler

GrpcServer di gestione dispositivi

public DeviceManagementGrpcServer (Server server, 
                IDeviceManager deviceManager, 
                ICommandScheduler scheduler)

Parametri
server Server

deviceManager IDeviceManager

scheduler ICommandScheduler

Metodi pubblici

getDeviceFromReservation

public ITestDevice getDeviceFromReservation (String reservationId)

Parametri
reservationId String

Ritorni
ITestDevice

getDevicesStatus

public void getDevicesStatus (GetDevicesStatusRequest request, 
                StreamObserver<GetDevicesStatusResponse> responseObserver)

Parametri
request GetDevicesStatusRequest

responseObserver StreamObserver

getPort

public static Integer getPort ()

Restituisce la porta utilizzata dal server.

Ritorni
Integer

releasePrenotazione

public void releaseReservation (ReleaseReservationRequest request, 
                StreamObserver<ReleaseReservationResponse> responseObserver)

Parametri
request ReleaseReservationRequest

responseObserver StreamObserver

ReserveDevice

public void reserveDevice (ReserveDeviceRequest request, 
                StreamObserver<ReserveDeviceResponse> responseObserver)

Parametri
request ReserveDeviceRequest

responseObserver StreamObserver

chiusura

public void shutdown ()

Arresta il server GRpc.

partenza

public void start ()

Avvia il server GRpc.

stopLeasing

public void stopLeasing (StopLeasingRequest request, 
                StreamObserver<StopLeasingResponse> responseObserver)

Parametri
request StopLeasingRequest

responseObserver StreamObserver