Class: FFI::Clang::CodeCompletion::Result
- Inherits:
-
Object
- Object
- FFI::Clang::CodeCompletion::Result
- Defined in:
- lib/ffi/clang/code_completion.rb
Overview
Represents a single code completion result.
Instance Method Summary collapse
-
#initialize(result) ⇒ Result
constructor
Initialize a completion result.
-
#inspect ⇒ Object
Get a string representation of this result.
-
#kind ⇒ Object
Get the kind of completion.
-
#string ⇒ Object
Get the completion string.
Constructor Details
#initialize(result) ⇒ Result
Initialize a completion result.
139 140 141 |
# File 'lib/ffi/clang/code_completion.rb', line 139 def initialize(result) @result = result end |
Instance Method Details
#inspect ⇒ Object
Get a string representation of this result.
157 158 159 |
# File 'lib/ffi/clang/code_completion.rb', line 157 def inspect "<#{kind.inspect} = #{string.inspect}>" end |
#kind ⇒ Object
Get the kind of completion.
145 146 147 |
# File 'lib/ffi/clang/code_completion.rb', line 145 def kind @result[:kind] end |
#string ⇒ Object
Get the completion string.
151 152 153 |
# File 'lib/ffi/clang/code_completion.rb', line 151 def string CodeCompletion::String.new @result[:string] end |