class Yoti::DynamicSharingService::WantedAnchorBuilder

Builder for WantedAnchor

Public Class Methods

new() click to toggle source
# File lib/yoti/dynamic_share_service/policy/wanted_anchor.rb, line 37
def initialize
  @anchor = WantedAnchor.new
end

Public Instance Methods

build() click to toggle source
# File lib/yoti/dynamic_share_service/policy/wanted_anchor.rb, line 51
def build
  Marshal.load Marshal.dump @anchor
end
with_sub_type(sub_type = nil) click to toggle source
# File lib/yoti/dynamic_share_service/policy/wanted_anchor.rb, line 46
def with_sub_type(sub_type = nil)
  @anchor.instance_variable_set(:@sub_type, sub_type)
  self
end
with_value(value) click to toggle source
# File lib/yoti/dynamic_share_service/policy/wanted_anchor.rb, line 41
def with_value(value)
  @anchor.instance_variable_set(:@value, value)
  self
end