Methods
#
N
R
Attributes
[R] symbol
Class Public methods
[](type)
# File actionview/lib/action_view/template/types.rb, line 17
def self.[](type)
  return type if type.is_a?(self)

  if type.is_a?(Symbol) || types.member?(type.to_s)
    new(type)
  end
end
new(symbol)
# File actionview/lib/action_view/template/types.rb, line 27
def initialize(symbol)
  @symbol = symbol.to_sym
end
register(*t)
# File actionview/lib/action_view/template/types.rb, line 11
def self.register(*t)
  types.merge(t.map { |type| type.to_s })
end
Instance Public methods
==(type)
# File actionview/lib/action_view/template/types.rb, line 38
def ==(type)
  return false if type.blank?
  symbol.to_sym == type.to_sym
end
ref()
# File actionview/lib/action_view/template/types.rb, line 34
def ref
  to_sym || to_s
end