Class: Neovim::DslBase::Plugins
Instance Attribute Summary collapse
-
#type ⇒ Object
readonly
Returns the value of attribute type.
Instance Method Summary collapse
- #get_handler(name) ⇒ Object
-
#initialize(type, setups, handlers) ⇒ Plugins
constructor
A new instance of Plugins.
- #options ⇒ Object
- #setup(client) ⇒ Object
- #specs ⇒ Object
Constructor Details
#initialize(type, setups, handlers) ⇒ Plugins
Returns a new instance of Plugins.
69 70 71 |
# File 'lib/neovim/handler.rb', line 69 def initialize type, setups, handlers @type, @setups, @handlers = type, setups, handlers end |
Instance Attribute Details
#type ⇒ Object (readonly)
Returns the value of attribute type.
67 68 69 |
# File 'lib/neovim/handler.rb', line 67 def type @type end |
Instance Method Details
#get_handler(name) ⇒ Object
77 78 79 |
# File 'lib/neovim/handler.rb', line 77 def get_handler name @handlers[ name] end |
#options ⇒ Object
85 86 87 |
# File 'lib/neovim/handler.rb', line 85 def @handlers.each { |name,handler| yield name, handler. } end |
#setup(client) ⇒ Object
73 74 75 |
# File 'lib/neovim/handler.rb', line 73 def setup client @setups.each { |b| b.call client } end |
#specs ⇒ Object
81 82 83 |
# File 'lib/neovim/handler.rb', line 81 def specs @handlers.map { |_,handler| handler.spec } end |