class FFI::Clang::CodeCompletion::String

Public Class Methods

new(ptr) click to toggle source
# File lib/ffi/clang/code_completion.rb, line 123
def initialize(ptr)
        @pointer = ptr
end

Public Instance Methods

annotation(i) click to toggle source
# File lib/ffi/clang/code_completion.rb, line 161
def annotation(i)
        Lib.extract_string Lib.get_completion_annotation(@pointer, i)
end
annotations() click to toggle source
# File lib/ffi/clang/code_completion.rb, line 165
def annotations
        num_annotations.times.map { |i|
                Lib.extract_string Lib.get_completion_annotation(@pointer, i)
        }
end
availability() click to toggle source
# File lib/ffi/clang/code_completion.rb, line 153
def availability
        Lib.get_completion_availability(@pointer)
end
chunk_completion(i) click to toggle source
# File lib/ffi/clang/code_completion.rb, line 135
def chunk_completion(i)
        CodeCompletion::String.new Lib.get_completion_chunk_completion_string(@pointer, i)
end
chunk_kind(i) click to toggle source
# File lib/ffi/clang/code_completion.rb, line 127
def chunk_kind(i)
        Lib.get_completion_chunk_kind(@pointer, i)
end
chunk_text(i) click to toggle source
# File lib/ffi/clang/code_completion.rb, line 131
def chunk_text(i)
        Lib.extract_string Lib.get_completion_text(@pointer, i)
end
chunks() click to toggle source
# File lib/ffi/clang/code_completion.rb, line 143
def chunks
        num_chunks.times.map { |i|
                { kind: chunk_kind(i), text: chunk_text(i), completion: chunk_completion(i) }
        }
end
comment() click to toggle source
# File lib/ffi/clang/code_completion.rb, line 175
def comment
        Lib.extract_string Lib.get_completion_brief_comment(@pointer)
end
num_annotations() click to toggle source
# File lib/ffi/clang/code_completion.rb, line 157
def num_annotations
        Lib.get_completion_num_annotations(@pointer)
end
num_chunks() click to toggle source
# File lib/ffi/clang/code_completion.rb, line 139
def num_chunks
        Lib.get_num_completion_chunks(@pointer)
end
parent() click to toggle source
# File lib/ffi/clang/code_completion.rb, line 171
def parent
        Lib.extract_string Lib.get_completion_parent(@pointer, nil)
end
priority() click to toggle source
# File lib/ffi/clang/code_completion.rb, line 149
def priority
        Lib.get_completion_priority(@pointer)
end