module Normailize::Provider::ClassMethods

Public Instance Methods

domains() click to toggle source

Internal: Get domains that are associated with the provider

Returns an array of domains

# File lib/normailize/provider.rb, line 56
def domains
  @domains || []
end
set_domains(*domains) click to toggle source

Public: Set on or more domains for a provider

*domains - one or more domains

Returns nothing

# File lib/normailize/provider.rb, line 33
def set_domains(*domains)
  @domains = domains
end
set_modifications(*modifications) click to toggle source

Public: Set one or more modifications to be performed on email address belonging to the provider

*modifications - One or more modification symbols

Currently, the following modifications are supported:

- :lowercase         Lowercase characthers in username part
- :remove_dots       Removes all dots in username part
- :remove_plus_part  Removes everything after the first occurrence of a plus sign

Returns nothing

# File lib/normailize/provider.rb, line 49
def set_modifications(*modifications)
  self.modifications = modifications.map(&:to_sym)
end