module Cura::Component
The container module for components.
Public Class Methods
all()
click to toggle source
All {Component::Base} subclasses.
@return [<Class>]
# File lib/cura/component.rb, line 8 def all @all ||= [] end
find_by_type(value)
click to toggle source
Find a {Component::Base} subclass by it's type.
@param [#to_sym] value @return [nil, Class]
# File lib/cura/component.rb, line 16 def find_by_type(value) value = value.to_sym all.find { |component_class| component_class.type == value } end