Class: SDM::RemoteIdentityGroups
- Inherits:
-
Object
- Object
- SDM::RemoteIdentityGroups
- Extended by:
- Gem::Deprecate
- Defined in:
- lib/svc.rb
Overview
A RemoteIdentityGroup is a named grouping of Remote Identities for Accounts. An Account's relationship to a RemoteIdentityGroup is defined via RemoteIdentity objects.
See RemoteIdentityGroup.
Instance Method Summary collapse
-
#get(id, deadline: nil) ⇒ Object
Get reads one RemoteIdentityGroup by ID.
-
#initialize(channel, parent) ⇒ RemoteIdentityGroups
constructor
A new instance of RemoteIdentityGroups.
-
#list(filter, *args, deadline: nil) ⇒ Object
List gets a list of RemoteIdentityGroups matching a given set of criteria.
Constructor Details
#initialize(channel, parent) ⇒ RemoteIdentityGroups
Returns a new instance of RemoteIdentityGroups.
3896 3897 3898 3899 3900 3901 3902 3903 |
# File 'lib/svc.rb', line 3896 def initialize(channel, parent) begin @stub = V1::RemoteIdentityGroups::Stub.new(nil, nil, channel_override: channel) rescue => exception raise Plumbing::convert_error_to_porcelain(exception) end @parent = parent end |
Instance Method Details
#get(id, deadline: nil) ⇒ Object
Get reads one RemoteIdentityGroup by ID.
3906 3907 3908 3909 3910 3911 3912 3913 3914 3915 3916 3917 3918 3919 3920 3921 3922 3923 3924 3925 3926 3927 3928 3929 3930 3931 3932 3933 3934 3935 3936 3937 |
# File 'lib/svc.rb', line 3906 def get( id, deadline: nil ) req = V1::RemoteIdentityGroupGetRequest.new() if not @parent.snapshot_time.nil? req. = V1::GetRequestMetadata.new() req..snapshot_at = @parent.snapshot_time end req.id = (id) tries = 0 plumbing_response = nil loop do begin plumbing_response = @stub.get(req, metadata: @parent.("RemoteIdentityGroups.Get", req), deadline: deadline) rescue => exception if (@parent.shouldRetry(tries, exception)) tries + +@parent.jitterSleep(tries) next end raise Plumbing::convert_error_to_porcelain(exception) end break end resp = RemoteIdentityGroupGetResponse.new() resp. = Plumbing::(plumbing_response.) resp.rate_limit = Plumbing::(plumbing_response.rate_limit) resp.remote_identity_group = Plumbing::convert_remote_identity_group_to_porcelain(plumbing_response.remote_identity_group) resp end |
#list(filter, *args, deadline: nil) ⇒ Object
List gets a list of RemoteIdentityGroups matching a given set of criteria.
3940 3941 3942 3943 3944 3945 3946 3947 3948 3949 3950 3951 3952 3953 3954 3955 3956 3957 3958 3959 3960 3961 3962 3963 3964 3965 3966 3967 3968 3969 3970 3971 3972 3973 3974 3975 3976 |
# File 'lib/svc.rb', line 3940 def list( filter, *args, deadline: nil ) req = V1::RemoteIdentityGroupListRequest.new() req. = V1::ListRequestMetadata.new() if @parent.page_limit > 0 req..limit = @parent.page_limit end if not @parent.snapshot_time.nil? req..snapshot_at = @parent.snapshot_time end req.filter = Plumbing::quote_filter_args(filter, *args) resp = Enumerator::Generator.new { |g| tries = 0 loop do begin plumbing_response = @stub.list(req, metadata: @parent.("RemoteIdentityGroups.List", req), deadline: deadline) rescue => exception if (@parent.shouldRetry(tries, exception)) tries + +@parent.jitterSleep(tries) next end raise Plumbing::convert_error_to_porcelain(exception) end tries = 0 plumbing_response.remote_identity_groups.each do |plumbing_item| g.yield Plumbing::convert_remote_identity_group_to_porcelain(plumbing_item) end break if plumbing_response..next_cursor == "" req..cursor = plumbing_response..next_cursor end } resp end |