syntax = "proto3";

package dynamic_subclass;

import "commons.proto";
import "google/protobuf/empty.proto";

service DynamicSubclassService {
  rpc Setup(SetupRequest) returns (SetupResponse);
  rpc Call(CallRequest) returns (CallResponse);
  rpc Rest(google.protobuf.Empty) returns (RestResponse);
}

message SetupRequest {
  string className = 1;
  repeated commons.Argument instanceArguments = 2;
  repeated commons.KwArgument instanceKwArguments = 3;
}

message SetupResponse {
  commons.Status status = 1;
}

message CallRequest {
  string methodName = 1;
  repeated commons.Argument methodArguments = 2;
  repeated commons.KwArgument methodKwArguments = 3;
}

message CallResponse {
  commons.Status status = 1;
  commons.Variant methodResponse = 2;
}

message RestResponse {
  commons.Status status = 1;
}
