Method: SDM::RoleAttachments#initialize

Defined in:
lib/svc.rb

#initialize(host, insecure, parent) ⇒ RoleAttachments

Returns a new instance of RoleAttachments.



1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
# File 'lib/svc.rb', line 1325

def initialize(host, insecure, parent)
  begin
    if insecure
      @stub = V1::RoleAttachments::Stub.new(host, :this_channel_is_insecure)
    else
      cred = GRPC::Core::ChannelCredentials.new()
      @stub = V1::RoleAttachments::Stub.new(host, cred)
    end
  rescue => exception
    raise Plumbing::convert_error_to_porcelain(exception)
  end
  @parent = parent
end