Class: TempmailSdk::GenerateEmailOptions
- Inherits:
-
Object
- Object
- TempmailSdk::GenerateEmailOptions
- Defined in:
- lib/tempmail_sdk/types.rb
Overview
创建临时邮箱的选项
Instance Attribute Summary collapse
-
#channel ⇒ Object
Returns the value of attribute channel.
-
#domain ⇒ Object
Returns the value of attribute domain.
-
#domains ⇒ Object
Returns the value of attribute domains.
-
#duration ⇒ Object
Returns the value of attribute duration.
-
#max_channels_tried ⇒ Object
Returns the value of attribute max_channels_tried.
-
#retry_config ⇒ Object
Returns the value of attribute retry_config.
-
#suffix ⇒ Object
Returns the value of attribute suffix.
-
#total_timeout ⇒ Object
Returns the value of attribute total_timeout.
Instance Method Summary collapse
-
#initialize(channel: nil, duration: 30, domain: nil, retry_config: nil, max_channels_tried: 20, total_timeout: 60.0, suffix: nil, domains: nil) ⇒ GenerateEmailOptions
constructor
rubocop:disable Metrics/ParameterLists.
Constructor Details
#initialize(channel: nil, duration: 30, domain: nil, retry_config: nil, max_channels_tried: 20, total_timeout: 60.0, suffix: nil, domains: nil) ⇒ GenerateEmailOptions
rubocop:disable Metrics/ParameterLists
124 125 126 127 128 129 130 131 132 133 134 |
# File 'lib/tempmail_sdk/types.rb', line 124 def initialize(channel: nil, duration: 30, domain: nil, retry_config: nil, max_channels_tried: 20, total_timeout: 60.0, suffix: nil, domains: nil) @channel = channel # 指定渠道,不指定则随机选择 @duration = duration # tempmail 渠道的有效期(分钟) @domain = domain # 部分渠道指定接入域名 @retry_config = retry_config # 重试配置 @max_channels_tried = max_channels_tried # 最大尝试渠道数 @total_timeout = total_timeout # 整体超时时间(秒) @suffix = suffix # 邮箱后缀筛选 @domains = domains # 多个目标域名 end |
Instance Attribute Details
#channel ⇒ Object
Returns the value of attribute channel.
120 121 122 |
# File 'lib/tempmail_sdk/types.rb', line 120 def channel @channel end |
#domain ⇒ Object
Returns the value of attribute domain.
120 121 122 |
# File 'lib/tempmail_sdk/types.rb', line 120 def domain @domain end |
#domains ⇒ Object
Returns the value of attribute domains.
120 121 122 |
# File 'lib/tempmail_sdk/types.rb', line 120 def domains @domains end |
#duration ⇒ Object
Returns the value of attribute duration.
120 121 122 |
# File 'lib/tempmail_sdk/types.rb', line 120 def duration @duration end |
#max_channels_tried ⇒ Object
Returns the value of attribute max_channels_tried.
120 121 122 |
# File 'lib/tempmail_sdk/types.rb', line 120 def max_channels_tried @max_channels_tried end |
#retry_config ⇒ Object
Returns the value of attribute retry_config.
120 121 122 |
# File 'lib/tempmail_sdk/types.rb', line 120 def retry_config @retry_config end |
#suffix ⇒ Object
Returns the value of attribute suffix.
120 121 122 |
# File 'lib/tempmail_sdk/types.rb', line 120 def suffix @suffix end |
#total_timeout ⇒ Object
Returns the value of attribute total_timeout.
120 121 122 |
# File 'lib/tempmail_sdk/types.rb', line 120 def total_timeout @total_timeout end |