Class: Neovim::API::Function Private
This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.
Instance Attribute Summary collapse
- #name ⇒ Object readonly private
Instance Method Summary collapse
-
#call(session, *args) ⇒ Object
private
Apply this function to a running RPC session.
-
#initialize(attributes) ⇒ Function
constructor
private
A new instance of Function.
- #method_name ⇒ Object private
Constructor Details
#initialize(attributes) ⇒ Function
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns a new instance of Function.
74 75 76 |
# File 'lib/neovim/api.rb', line 74 def initialize(attributes) @name = attributes.fetch("name") end |
Instance Attribute Details
#name ⇒ Object (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
72 73 74 |
# File 'lib/neovim/api.rb', line 72 def name @name end |
Instance Method Details
#call(session, *args) ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Apply this function to a running RPC session.
83 84 85 |
# File 'lib/neovim/api.rb', line 83 def call(session, *args) session.request(name, *args) end |
#method_name ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
78 79 80 |
# File 'lib/neovim/api.rb', line 78 def method_name @name.sub(/^nvim_(win_|buf_|tabpage_)?/, "").to_sym end |