You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

41 lines
1.3 KiB

11 years ago
#ifndef COMPLETIONSTRING_H_
#define COMPLETIONSTRING_H_
#include <clang-c/Index.h>
#include <string>
#include <vector>
11 years ago
namespace clang {
enum CompletionChunkKind {
CompletionChunk_Optional, CompletionChunk_TypedText,
CompletionChunk_Text, CompletionChunk_Placeholder,
CompletionChunk_Informative, CompletionChunk_CurrentParameter,
CompletionChunk_LeftParen, CompletionChunk_RightParen,
CompletionChunk_LeftBracket, CompletionChunk_RightBracket,
CompletionChunk_LeftBrace, CompletionChunk_RightBrace,
CompletionChunk_LeftAngle, CompletionChunk_RightAngle,
CompletionChunk_Comma, CompletionChunk_ResultType,
CompletionChunk_Colon, CompletionChunk_SemiColon,
CompletionChunk_Equal, CompletionChunk_HorizontalSpace,
CompletionChunk_VerticalSpace
};
class CompletionChunk {
public:
CompletionChunk(std::string chunk, CompletionChunkKind kind);
11 years ago
std::string chunk;
CompletionChunkKind kind;
11 years ago
};
class CompletionString {
public:
explicit CompletionString(const CXCompletionString &cx_str);
bool available();
11 years ago
std::vector<CompletionChunk> get_chunks();
std::string get_brief_comments();
11 years ago
int get_num_chunks();
CXCompletionString cx_str;
11 years ago
};
} // namespace clang
#endif // COMPLETIONSTRING_H_