// Proto file representing the EDB Structure3D class

syntax = "proto3";

// Package
package ansys.api.edb.v1;

// Imports
import "ansys/api/edb/v1/edb_messages.proto";
import "ansys/api/edb/v1/hierarchy_obj.proto";


enum Closure {
  OPEN_ENDED = 0;
  ENDS_CLOSED = 1;
  FILLED_CLOSED = 2;
  UNDEFINED_CLOSURE = -1;
}

// Structure3D service definition
service Structure3DService {
  // Create a structure3D
  rpc Create(ObjectNameInLayoutMessage) returns (EDBObjMessage) {}

  // Get material
  rpc GetMaterial(BoolPropertyMessage) returns (google.protobuf.StringValue) {}

  // Set material
  rpc SetMaterial(StringPropertyMessage) returns (google.protobuf.Empty) {}

  // Get thickness
  rpc GetThickness(EDBObjMessage) returns (ValueMessage) {}
  
  // Set thickness
  rpc SetThickness(ValuePropertyMessage) returns (google.protobuf.Empty) {}

  // Get mesh closure property
  rpc GetMeshClosureProp(EDBObjMessage) returns (ClosureMessage) {}

  // Set mesh closure property
  rpc SetMeshClosureProp(SetClosureMessage) returns (google.protobuf.Empty) {}
}


message ClosureMessage {
  Closure closure_type = 1;
}

message SetClosureMessage {
  EDBObjMessage target = 1;
  ClosureMessage closure_type = 2;
}



