class Net::IMAP::ConnectionState
:nodoc:
def self.define(symbol, *attrs)
def self.define(symbol, *attrs) symbol => Symbol state = super(*attrs) state.const_set :NAME, symbol state end
def authenticated?; to_sym == :authenticated end
def authenticated?; to_sym == :authenticated end
def deconstruct; [symbol, *super] end
def deconstruct; [symbol, *super] end
def deconstruct_keys(names)
def deconstruct_keys(names) hash = super hash[:symbol] = symbol if names.nil? || names.include?(:symbol) hash[:name] = name if names.nil? || names.include?(:name) hash end
def logout?; to_sym == :logout end
def logout?; to_sym == :logout end
def name; self.class::NAME.name end
def name; self.class::NAME.name end
def not_authenticated?; to_sym == :not_authenticated end
def not_authenticated?; to_sym == :not_authenticated end
def selected?; to_sym == :selected end
def selected?; to_sym == :selected end
def symbol; self.class::NAME end
def symbol; self.class::NAME end
def to_h(&block)
def to_h(&block) hash = deconstruct_keys(nil) block ? hash.to_h(&block) : hash end