Browse Source

Update CppParser bindings.

pull/195/head
Øystein Krog 12 years ago
parent
commit
24a6c7a430
  1. 5509
      src/CppParser/Bindings/CLI/AST.cpp
  2. 3613
      src/CppParser/Bindings/CLI/AST.h
  3. 868
      src/CppParser/Bindings/CLI/CppParser.cpp
  4. 558
      src/CppParser/Bindings/CLI/CppParser.h

5509
src/CppParser/Bindings/CLI/AST.cpp

File diff suppressed because it is too large Load Diff

3613
src/CppParser/Bindings/CLI/AST.h

File diff suppressed because it is too large Load Diff

868
src/CppParser/Bindings/CLI/CppParser.cpp

@ -1,434 +1,434 @@
#include "CppParser.h" #include "CppParser.h"
#include "AST.h" #include "AST.h"
using namespace System; using namespace System;
using namespace System::Runtime::InteropServices; using namespace System::Runtime::InteropServices;
CppSharp::Parser::ParserOptions::ParserOptions(::CppSharp::CppParser::ParserOptions* native) CppSharp::Parser::ParserOptions::ParserOptions(::CppSharp::CppParser::ParserOptions* native)
{ {
NativePtr = native; NativePtr = native;
} }
CppSharp::Parser::ParserOptions::ParserOptions(System::IntPtr native) CppSharp::Parser::ParserOptions::ParserOptions(System::IntPtr native)
{ {
auto __native = (::CppSharp::CppParser::ParserOptions*)native.ToPointer(); auto __native = (::CppSharp::CppParser::ParserOptions*)native.ToPointer();
NativePtr = __native; NativePtr = __native;
} }
CppSharp::Parser::ParserOptions::ParserOptions() CppSharp::Parser::ParserOptions::ParserOptions()
{ {
NativePtr = new ::CppSharp::CppParser::ParserOptions(); NativePtr = new ::CppSharp::CppParser::ParserOptions();
} }
System::String^ CppSharp::Parser::ParserOptions::getArguments(unsigned int i) System::String^ CppSharp::Parser::ParserOptions::getArguments(unsigned int i)
{ {
auto __ret = ((::CppSharp::CppParser::ParserOptions*)NativePtr)->getArguments(i); auto __ret = ((::CppSharp::CppParser::ParserOptions*)NativePtr)->getArguments(i);
if (__ret == nullptr) return nullptr; if (__ret == nullptr) return nullptr;
return clix::marshalString<clix::E_UTF8>(__ret); return clix::marshalString<clix::E_UTF8>(__ret);
} }
void CppSharp::Parser::ParserOptions::addArguments(System::String^ s) void CppSharp::Parser::ParserOptions::addArguments(System::String^ s)
{ {
auto _arg0 = clix::marshalString<clix::E_UTF8>(s); auto _arg0 = clix::marshalString<clix::E_UTF8>(s);
auto arg0 = _arg0.c_str(); auto arg0 = _arg0.c_str();
((::CppSharp::CppParser::ParserOptions*)NativePtr)->addArguments(arg0); ((::CppSharp::CppParser::ParserOptions*)NativePtr)->addArguments(arg0);
} }
System::String^ CppSharp::Parser::ParserOptions::getIncludeDirs(unsigned int i) System::String^ CppSharp::Parser::ParserOptions::getIncludeDirs(unsigned int i)
{ {
auto __ret = ((::CppSharp::CppParser::ParserOptions*)NativePtr)->getIncludeDirs(i); auto __ret = ((::CppSharp::CppParser::ParserOptions*)NativePtr)->getIncludeDirs(i);
if (__ret == nullptr) return nullptr; if (__ret == nullptr) return nullptr;
return clix::marshalString<clix::E_UTF8>(__ret); return clix::marshalString<clix::E_UTF8>(__ret);
} }
void CppSharp::Parser::ParserOptions::addIncludeDirs(System::String^ s) void CppSharp::Parser::ParserOptions::addIncludeDirs(System::String^ s)
{ {
auto _arg0 = clix::marshalString<clix::E_UTF8>(s); auto _arg0 = clix::marshalString<clix::E_UTF8>(s);
auto arg0 = _arg0.c_str(); auto arg0 = _arg0.c_str();
((::CppSharp::CppParser::ParserOptions*)NativePtr)->addIncludeDirs(arg0); ((::CppSharp::CppParser::ParserOptions*)NativePtr)->addIncludeDirs(arg0);
} }
System::String^ CppSharp::Parser::ParserOptions::getSystemIncludeDirs(unsigned int i) System::String^ CppSharp::Parser::ParserOptions::getSystemIncludeDirs(unsigned int i)
{ {
auto __ret = ((::CppSharp::CppParser::ParserOptions*)NativePtr)->getSystemIncludeDirs(i); auto __ret = ((::CppSharp::CppParser::ParserOptions*)NativePtr)->getSystemIncludeDirs(i);
if (__ret == nullptr) return nullptr; if (__ret == nullptr) return nullptr;
return clix::marshalString<clix::E_UTF8>(__ret); return clix::marshalString<clix::E_UTF8>(__ret);
} }
void CppSharp::Parser::ParserOptions::addSystemIncludeDirs(System::String^ s) void CppSharp::Parser::ParserOptions::addSystemIncludeDirs(System::String^ s)
{ {
auto _arg0 = clix::marshalString<clix::E_UTF8>(s); auto _arg0 = clix::marshalString<clix::E_UTF8>(s);
auto arg0 = _arg0.c_str(); auto arg0 = _arg0.c_str();
((::CppSharp::CppParser::ParserOptions*)NativePtr)->addSystemIncludeDirs(arg0); ((::CppSharp::CppParser::ParserOptions*)NativePtr)->addSystemIncludeDirs(arg0);
} }
System::String^ CppSharp::Parser::ParserOptions::getDefines(unsigned int i) System::String^ CppSharp::Parser::ParserOptions::getDefines(unsigned int i)
{ {
auto __ret = ((::CppSharp::CppParser::ParserOptions*)NativePtr)->getDefines(i); auto __ret = ((::CppSharp::CppParser::ParserOptions*)NativePtr)->getDefines(i);
if (__ret == nullptr) return nullptr; if (__ret == nullptr) return nullptr;
return clix::marshalString<clix::E_UTF8>(__ret); return clix::marshalString<clix::E_UTF8>(__ret);
} }
void CppSharp::Parser::ParserOptions::addDefines(System::String^ s) void CppSharp::Parser::ParserOptions::addDefines(System::String^ s)
{ {
auto _arg0 = clix::marshalString<clix::E_UTF8>(s); auto _arg0 = clix::marshalString<clix::E_UTF8>(s);
auto arg0 = _arg0.c_str(); auto arg0 = _arg0.c_str();
((::CppSharp::CppParser::ParserOptions*)NativePtr)->addDefines(arg0); ((::CppSharp::CppParser::ParserOptions*)NativePtr)->addDefines(arg0);
} }
System::String^ CppSharp::Parser::ParserOptions::getLibraryDirs(unsigned int i) System::String^ CppSharp::Parser::ParserOptions::getLibraryDirs(unsigned int i)
{ {
auto __ret = ((::CppSharp::CppParser::ParserOptions*)NativePtr)->getLibraryDirs(i); auto __ret = ((::CppSharp::CppParser::ParserOptions*)NativePtr)->getLibraryDirs(i);
if (__ret == nullptr) return nullptr; if (__ret == nullptr) return nullptr;
return clix::marshalString<clix::E_UTF8>(__ret); return clix::marshalString<clix::E_UTF8>(__ret);
} }
void CppSharp::Parser::ParserOptions::addLibraryDirs(System::String^ s) void CppSharp::Parser::ParserOptions::addLibraryDirs(System::String^ s)
{ {
auto _arg0 = clix::marshalString<clix::E_UTF8>(s); auto _arg0 = clix::marshalString<clix::E_UTF8>(s);
auto arg0 = _arg0.c_str(); auto arg0 = _arg0.c_str();
((::CppSharp::CppParser::ParserOptions*)NativePtr)->addLibraryDirs(arg0); ((::CppSharp::CppParser::ParserOptions*)NativePtr)->addLibraryDirs(arg0);
} }
System::IntPtr CppSharp::Parser::ParserOptions::__Instance::get() System::IntPtr CppSharp::Parser::ParserOptions::__Instance::get()
{ {
return System::IntPtr(NativePtr); return System::IntPtr(NativePtr);
} }
void CppSharp::Parser::ParserOptions::__Instance::set(System::IntPtr object) void CppSharp::Parser::ParserOptions::__Instance::set(System::IntPtr object)
{ {
NativePtr = (::CppSharp::CppParser::ParserOptions*)object.ToPointer(); NativePtr = (::CppSharp::CppParser::ParserOptions*)object.ToPointer();
} }
unsigned int CppSharp::Parser::ParserOptions::ArgumentsCount::get() unsigned int CppSharp::Parser::ParserOptions::ArgumentsCount::get()
{ {
auto __ret = ((::CppSharp::CppParser::ParserOptions*)NativePtr)->getArgumentsCount(); auto __ret = ((::CppSharp::CppParser::ParserOptions*)NativePtr)->getArgumentsCount();
return __ret; return __ret;
} }
System::String^ CppSharp::Parser::ParserOptions::FileName::get() System::String^ CppSharp::Parser::ParserOptions::FileName::get()
{ {
auto __ret = ((::CppSharp::CppParser::ParserOptions*)NativePtr)->getFileName(); auto __ret = ((::CppSharp::CppParser::ParserOptions*)NativePtr)->getFileName();
if (__ret == nullptr) return nullptr; if (__ret == nullptr) return nullptr;
return clix::marshalString<clix::E_UTF8>(__ret); return clix::marshalString<clix::E_UTF8>(__ret);
} }
void CppSharp::Parser::ParserOptions::FileName::set(System::String^ value) void CppSharp::Parser::ParserOptions::FileName::set(System::String^ value)
{ {
auto s = value; auto s = value;
auto _arg0 = clix::marshalString<clix::E_UTF8>(s); auto _arg0 = clix::marshalString<clix::E_UTF8>(s);
auto arg0 = _arg0.c_str(); auto arg0 = _arg0.c_str();
((::CppSharp::CppParser::ParserOptions*)NativePtr)->setFileName(arg0); ((::CppSharp::CppParser::ParserOptions*)NativePtr)->setFileName(arg0);
} }
unsigned int CppSharp::Parser::ParserOptions::IncludeDirsCount::get() unsigned int CppSharp::Parser::ParserOptions::IncludeDirsCount::get()
{ {
auto __ret = ((::CppSharp::CppParser::ParserOptions*)NativePtr)->getIncludeDirsCount(); auto __ret = ((::CppSharp::CppParser::ParserOptions*)NativePtr)->getIncludeDirsCount();
return __ret; return __ret;
} }
unsigned int CppSharp::Parser::ParserOptions::SystemIncludeDirsCount::get() unsigned int CppSharp::Parser::ParserOptions::SystemIncludeDirsCount::get()
{ {
auto __ret = ((::CppSharp::CppParser::ParserOptions*)NativePtr)->getSystemIncludeDirsCount(); auto __ret = ((::CppSharp::CppParser::ParserOptions*)NativePtr)->getSystemIncludeDirsCount();
return __ret; return __ret;
} }
unsigned int CppSharp::Parser::ParserOptions::DefinesCount::get() unsigned int CppSharp::Parser::ParserOptions::DefinesCount::get()
{ {
auto __ret = ((::CppSharp::CppParser::ParserOptions*)NativePtr)->getDefinesCount(); auto __ret = ((::CppSharp::CppParser::ParserOptions*)NativePtr)->getDefinesCount();
return __ret; return __ret;
} }
unsigned int CppSharp::Parser::ParserOptions::LibraryDirsCount::get() unsigned int CppSharp::Parser::ParserOptions::LibraryDirsCount::get()
{ {
auto __ret = ((::CppSharp::CppParser::ParserOptions*)NativePtr)->getLibraryDirsCount(); auto __ret = ((::CppSharp::CppParser::ParserOptions*)NativePtr)->getLibraryDirsCount();
return __ret; return __ret;
} }
System::String^ CppSharp::Parser::ParserOptions::TargetTriple::get() System::String^ CppSharp::Parser::ParserOptions::TargetTriple::get()
{ {
auto __ret = ((::CppSharp::CppParser::ParserOptions*)NativePtr)->getTargetTriple(); auto __ret = ((::CppSharp::CppParser::ParserOptions*)NativePtr)->getTargetTriple();
if (__ret == nullptr) return nullptr; if (__ret == nullptr) return nullptr;
return clix::marshalString<clix::E_UTF8>(__ret); return clix::marshalString<clix::E_UTF8>(__ret);
} }
void CppSharp::Parser::ParserOptions::TargetTriple::set(System::String^ value) void CppSharp::Parser::ParserOptions::TargetTriple::set(System::String^ value)
{ {
auto s = value; auto s = value;
auto _arg0 = clix::marshalString<clix::E_UTF8>(s); auto _arg0 = clix::marshalString<clix::E_UTF8>(s);
auto arg0 = _arg0.c_str(); auto arg0 = _arg0.c_str();
((::CppSharp::CppParser::ParserOptions*)NativePtr)->setTargetTriple(arg0); ((::CppSharp::CppParser::ParserOptions*)NativePtr)->setTargetTriple(arg0);
} }
CppSharp::Parser::AST::ASTContext^ CppSharp::Parser::ParserOptions::ASTContext::get() CppSharp::Parser::AST::ASTContext^ CppSharp::Parser::ParserOptions::ASTContext::get()
{ {
return gcnew CppSharp::Parser::AST::ASTContext((::CppSharp::CppParser::AST::ASTContext*)((::CppSharp::CppParser::ParserOptions*)NativePtr)->ASTContext); return gcnew CppSharp::Parser::AST::ASTContext((::CppSharp::CppParser::AST::ASTContext*)((::CppSharp::CppParser::ParserOptions*)NativePtr)->ASTContext);
} }
void CppSharp::Parser::ParserOptions::ASTContext::set(CppSharp::Parser::AST::ASTContext^ value) void CppSharp::Parser::ParserOptions::ASTContext::set(CppSharp::Parser::AST::ASTContext^ value)
{ {
((::CppSharp::CppParser::ParserOptions*)NativePtr)->ASTContext = (::CppSharp::CppParser::AST::ASTContext*)value->NativePtr; ((::CppSharp::CppParser::ParserOptions*)NativePtr)->ASTContext = (::CppSharp::CppParser::AST::ASTContext*)value->NativePtr;
} }
int CppSharp::Parser::ParserOptions::ToolSetToUse::get() int CppSharp::Parser::ParserOptions::ToolSetToUse::get()
{ {
return ((::CppSharp::CppParser::ParserOptions*)NativePtr)->ToolSetToUse; return ((::CppSharp::CppParser::ParserOptions*)NativePtr)->ToolSetToUse;
} }
void CppSharp::Parser::ParserOptions::ToolSetToUse::set(int value) void CppSharp::Parser::ParserOptions::ToolSetToUse::set(int value)
{ {
((::CppSharp::CppParser::ParserOptions*)NativePtr)->ToolSetToUse = value; ((::CppSharp::CppParser::ParserOptions*)NativePtr)->ToolSetToUse = value;
} }
CppSharp::Parser::AST::CppAbi CppSharp::Parser::ParserOptions::Abi::get() CppSharp::Parser::AST::CppAbi CppSharp::Parser::ParserOptions::Abi::get()
{ {
return (CppSharp::Parser::AST::CppAbi)((::CppSharp::CppParser::ParserOptions*)NativePtr)->Abi; return (CppSharp::Parser::AST::CppAbi)((::CppSharp::CppParser::ParserOptions*)NativePtr)->Abi;
} }
void CppSharp::Parser::ParserOptions::Abi::set(CppSharp::Parser::AST::CppAbi value) void CppSharp::Parser::ParserOptions::Abi::set(CppSharp::Parser::AST::CppAbi value)
{ {
((::CppSharp::CppParser::ParserOptions*)NativePtr)->Abi = (::CppSharp::CppParser::AST::CppAbi)value; ((::CppSharp::CppParser::ParserOptions*)NativePtr)->Abi = (::CppSharp::CppParser::AST::CppAbi)value;
} }
bool CppSharp::Parser::ParserOptions::NoStandardIncludes::get() bool CppSharp::Parser::ParserOptions::NoStandardIncludes::get()
{ {
return ((::CppSharp::CppParser::ParserOptions*)NativePtr)->NoStandardIncludes; return ((::CppSharp::CppParser::ParserOptions*)NativePtr)->NoStandardIncludes;
} }
void CppSharp::Parser::ParserOptions::NoStandardIncludes::set(bool value) void CppSharp::Parser::ParserOptions::NoStandardIncludes::set(bool value)
{ {
((::CppSharp::CppParser::ParserOptions*)NativePtr)->NoStandardIncludes = value; ((::CppSharp::CppParser::ParserOptions*)NativePtr)->NoStandardIncludes = value;
} }
bool CppSharp::Parser::ParserOptions::NoBuiltinIncludes::get() bool CppSharp::Parser::ParserOptions::NoBuiltinIncludes::get()
{ {
return ((::CppSharp::CppParser::ParserOptions*)NativePtr)->NoBuiltinIncludes; return ((::CppSharp::CppParser::ParserOptions*)NativePtr)->NoBuiltinIncludes;
} }
void CppSharp::Parser::ParserOptions::NoBuiltinIncludes::set(bool value) void CppSharp::Parser::ParserOptions::NoBuiltinIncludes::set(bool value)
{ {
((::CppSharp::CppParser::ParserOptions*)NativePtr)->NoBuiltinIncludes = value; ((::CppSharp::CppParser::ParserOptions*)NativePtr)->NoBuiltinIncludes = value;
} }
bool CppSharp::Parser::ParserOptions::MicrosoftMode::get() bool CppSharp::Parser::ParserOptions::MicrosoftMode::get()
{ {
return ((::CppSharp::CppParser::ParserOptions*)NativePtr)->MicrosoftMode; return ((::CppSharp::CppParser::ParserOptions*)NativePtr)->MicrosoftMode;
} }
void CppSharp::Parser::ParserOptions::MicrosoftMode::set(bool value) void CppSharp::Parser::ParserOptions::MicrosoftMode::set(bool value)
{ {
((::CppSharp::CppParser::ParserOptions*)NativePtr)->MicrosoftMode = value; ((::CppSharp::CppParser::ParserOptions*)NativePtr)->MicrosoftMode = value;
} }
bool CppSharp::Parser::ParserOptions::Verbose::get() bool CppSharp::Parser::ParserOptions::Verbose::get()
{ {
return ((::CppSharp::CppParser::ParserOptions*)NativePtr)->Verbose; return ((::CppSharp::CppParser::ParserOptions*)NativePtr)->Verbose;
} }
void CppSharp::Parser::ParserOptions::Verbose::set(bool value) void CppSharp::Parser::ParserOptions::Verbose::set(bool value)
{ {
((::CppSharp::CppParser::ParserOptions*)NativePtr)->Verbose = value; ((::CppSharp::CppParser::ParserOptions*)NativePtr)->Verbose = value;
} }
CppSharp::Parser::ParserDiagnostic::ParserDiagnostic(::CppSharp::CppParser::ParserDiagnostic* native) CppSharp::Parser::ParserDiagnostic::ParserDiagnostic(::CppSharp::CppParser::ParserDiagnostic* native)
{ {
NativePtr = native; NativePtr = native;
} }
CppSharp::Parser::ParserDiagnostic::ParserDiagnostic(System::IntPtr native) CppSharp::Parser::ParserDiagnostic::ParserDiagnostic(System::IntPtr native)
{ {
auto __native = (::CppSharp::CppParser::ParserDiagnostic*)native.ToPointer(); auto __native = (::CppSharp::CppParser::ParserDiagnostic*)native.ToPointer();
NativePtr = __native; NativePtr = __native;
} }
CppSharp::Parser::ParserDiagnostic::ParserDiagnostic() CppSharp::Parser::ParserDiagnostic::ParserDiagnostic()
{ {
NativePtr = new ::CppSharp::CppParser::ParserDiagnostic(); NativePtr = new ::CppSharp::CppParser::ParserDiagnostic();
} }
System::IntPtr CppSharp::Parser::ParserDiagnostic::__Instance::get() System::IntPtr CppSharp::Parser::ParserDiagnostic::__Instance::get()
{ {
return System::IntPtr(NativePtr); return System::IntPtr(NativePtr);
} }
void CppSharp::Parser::ParserDiagnostic::__Instance::set(System::IntPtr object) void CppSharp::Parser::ParserDiagnostic::__Instance::set(System::IntPtr object)
{ {
NativePtr = (::CppSharp::CppParser::ParserDiagnostic*)object.ToPointer(); NativePtr = (::CppSharp::CppParser::ParserDiagnostic*)object.ToPointer();
} }
System::String^ CppSharp::Parser::ParserDiagnostic::FileName::get() System::String^ CppSharp::Parser::ParserDiagnostic::FileName::get()
{ {
auto __ret = ((::CppSharp::CppParser::ParserDiagnostic*)NativePtr)->getFileName(); auto __ret = ((::CppSharp::CppParser::ParserDiagnostic*)NativePtr)->getFileName();
if (__ret == nullptr) return nullptr; if (__ret == nullptr) return nullptr;
return clix::marshalString<clix::E_UTF8>(__ret); return clix::marshalString<clix::E_UTF8>(__ret);
} }
void CppSharp::Parser::ParserDiagnostic::FileName::set(System::String^ value) void CppSharp::Parser::ParserDiagnostic::FileName::set(System::String^ value)
{ {
auto s = value; auto s = value;
auto _arg0 = clix::marshalString<clix::E_UTF8>(s); auto _arg0 = clix::marshalString<clix::E_UTF8>(s);
auto arg0 = _arg0.c_str(); auto arg0 = _arg0.c_str();
((::CppSharp::CppParser::ParserDiagnostic*)NativePtr)->setFileName(arg0); ((::CppSharp::CppParser::ParserDiagnostic*)NativePtr)->setFileName(arg0);
} }
System::String^ CppSharp::Parser::ParserDiagnostic::Message::get() System::String^ CppSharp::Parser::ParserDiagnostic::Message::get()
{ {
auto __ret = ((::CppSharp::CppParser::ParserDiagnostic*)NativePtr)->getMessage(); auto __ret = ((::CppSharp::CppParser::ParserDiagnostic*)NativePtr)->getMessage();
if (__ret == nullptr) return nullptr; if (__ret == nullptr) return nullptr;
return clix::marshalString<clix::E_UTF8>(__ret); return clix::marshalString<clix::E_UTF8>(__ret);
} }
void CppSharp::Parser::ParserDiagnostic::Message::set(System::String^ value) void CppSharp::Parser::ParserDiagnostic::Message::set(System::String^ value)
{ {
auto s = value; auto s = value;
auto _arg0 = clix::marshalString<clix::E_UTF8>(s); auto _arg0 = clix::marshalString<clix::E_UTF8>(s);
auto arg0 = _arg0.c_str(); auto arg0 = _arg0.c_str();
((::CppSharp::CppParser::ParserDiagnostic*)NativePtr)->setMessage(arg0); ((::CppSharp::CppParser::ParserDiagnostic*)NativePtr)->setMessage(arg0);
} }
CppSharp::Parser::ParserDiagnosticLevel CppSharp::Parser::ParserDiagnostic::Level::get() CppSharp::Parser::ParserDiagnosticLevel CppSharp::Parser::ParserDiagnostic::Level::get()
{ {
return (CppSharp::Parser::ParserDiagnosticLevel)((::CppSharp::CppParser::ParserDiagnostic*)NativePtr)->Level; return (CppSharp::Parser::ParserDiagnosticLevel)((::CppSharp::CppParser::ParserDiagnostic*)NativePtr)->Level;
} }
void CppSharp::Parser::ParserDiagnostic::Level::set(CppSharp::Parser::ParserDiagnosticLevel value) void CppSharp::Parser::ParserDiagnostic::Level::set(CppSharp::Parser::ParserDiagnosticLevel value)
{ {
((::CppSharp::CppParser::ParserDiagnostic*)NativePtr)->Level = (::CppSharp::CppParser::ParserDiagnosticLevel)value; ((::CppSharp::CppParser::ParserDiagnostic*)NativePtr)->Level = (::CppSharp::CppParser::ParserDiagnosticLevel)value;
} }
int CppSharp::Parser::ParserDiagnostic::LineNumber::get() int CppSharp::Parser::ParserDiagnostic::LineNumber::get()
{ {
return ((::CppSharp::CppParser::ParserDiagnostic*)NativePtr)->LineNumber; return ((::CppSharp::CppParser::ParserDiagnostic*)NativePtr)->LineNumber;
} }
void CppSharp::Parser::ParserDiagnostic::LineNumber::set(int value) void CppSharp::Parser::ParserDiagnostic::LineNumber::set(int value)
{ {
((::CppSharp::CppParser::ParserDiagnostic*)NativePtr)->LineNumber = value; ((::CppSharp::CppParser::ParserDiagnostic*)NativePtr)->LineNumber = value;
} }
int CppSharp::Parser::ParserDiagnostic::ColumnNumber::get() int CppSharp::Parser::ParserDiagnostic::ColumnNumber::get()
{ {
return ((::CppSharp::CppParser::ParserDiagnostic*)NativePtr)->ColumnNumber; return ((::CppSharp::CppParser::ParserDiagnostic*)NativePtr)->ColumnNumber;
} }
void CppSharp::Parser::ParserDiagnostic::ColumnNumber::set(int value) void CppSharp::Parser::ParserDiagnostic::ColumnNumber::set(int value)
{ {
((::CppSharp::CppParser::ParserDiagnostic*)NativePtr)->ColumnNumber = value; ((::CppSharp::CppParser::ParserDiagnostic*)NativePtr)->ColumnNumber = value;
} }
CppSharp::Parser::ParserResult::ParserResult(::CppSharp::CppParser::ParserResult* native) CppSharp::Parser::ParserResult::ParserResult(::CppSharp::CppParser::ParserResult* native)
{ {
NativePtr = native; NativePtr = native;
} }
CppSharp::Parser::ParserResult::ParserResult(System::IntPtr native) CppSharp::Parser::ParserResult::ParserResult(System::IntPtr native)
{ {
auto __native = (::CppSharp::CppParser::ParserResult*)native.ToPointer(); auto __native = (::CppSharp::CppParser::ParserResult*)native.ToPointer();
NativePtr = __native; NativePtr = __native;
} }
CppSharp::Parser::ParserResult::ParserResult() CppSharp::Parser::ParserResult::ParserResult()
{ {
NativePtr = new ::CppSharp::CppParser::ParserResult(); NativePtr = new ::CppSharp::CppParser::ParserResult();
} }
CppSharp::Parser::ParserDiagnostic^ CppSharp::Parser::ParserResult::getDiagnostics(unsigned int i) CppSharp::Parser::ParserDiagnostic^ CppSharp::Parser::ParserResult::getDiagnostics(unsigned int i)
{ {
auto __ret = ((::CppSharp::CppParser::ParserResult*)NativePtr)->getDiagnostics(i); auto __ret = ((::CppSharp::CppParser::ParserResult*)NativePtr)->getDiagnostics(i);
auto ____ret = new ::CppSharp::CppParser::ParserDiagnostic(__ret); auto ____ret = new ::CppSharp::CppParser::ParserDiagnostic(__ret);
return gcnew CppSharp::Parser::ParserDiagnostic((::CppSharp::CppParser::ParserDiagnostic*)____ret); return gcnew CppSharp::Parser::ParserDiagnostic((::CppSharp::CppParser::ParserDiagnostic*)____ret);
} }
void CppSharp::Parser::ParserResult::addDiagnostics(CppSharp::Parser::ParserDiagnostic^ s) void CppSharp::Parser::ParserResult::addDiagnostics(CppSharp::Parser::ParserDiagnostic^ s)
{ {
auto &arg0 = *(::CppSharp::CppParser::ParserDiagnostic*)s->NativePtr; auto &arg0 = *(::CppSharp::CppParser::ParserDiagnostic*)s->NativePtr;
((::CppSharp::CppParser::ParserResult*)NativePtr)->addDiagnostics(arg0); ((::CppSharp::CppParser::ParserResult*)NativePtr)->addDiagnostics(arg0);
} }
System::IntPtr CppSharp::Parser::ParserResult::__Instance::get() System::IntPtr CppSharp::Parser::ParserResult::__Instance::get()
{ {
return System::IntPtr(NativePtr); return System::IntPtr(NativePtr);
} }
void CppSharp::Parser::ParserResult::__Instance::set(System::IntPtr object) void CppSharp::Parser::ParserResult::__Instance::set(System::IntPtr object)
{ {
NativePtr = (::CppSharp::CppParser::ParserResult*)object.ToPointer(); NativePtr = (::CppSharp::CppParser::ParserResult*)object.ToPointer();
} }
unsigned int CppSharp::Parser::ParserResult::DiagnosticsCount::get() unsigned int CppSharp::Parser::ParserResult::DiagnosticsCount::get()
{ {
auto __ret = ((::CppSharp::CppParser::ParserResult*)NativePtr)->getDiagnosticsCount(); auto __ret = ((::CppSharp::CppParser::ParserResult*)NativePtr)->getDiagnosticsCount();
return __ret; return __ret;
} }
CppSharp::Parser::ParserResultKind CppSharp::Parser::ParserResult::Kind::get() CppSharp::Parser::ParserResultKind CppSharp::Parser::ParserResult::Kind::get()
{ {
return (CppSharp::Parser::ParserResultKind)((::CppSharp::CppParser::ParserResult*)NativePtr)->Kind; return (CppSharp::Parser::ParserResultKind)((::CppSharp::CppParser::ParserResult*)NativePtr)->Kind;
} }
void CppSharp::Parser::ParserResult::Kind::set(CppSharp::Parser::ParserResultKind value) void CppSharp::Parser::ParserResult::Kind::set(CppSharp::Parser::ParserResultKind value)
{ {
((::CppSharp::CppParser::ParserResult*)NativePtr)->Kind = (::CppSharp::CppParser::ParserResultKind)value; ((::CppSharp::CppParser::ParserResult*)NativePtr)->Kind = (::CppSharp::CppParser::ParserResultKind)value;
} }
CppSharp::Parser::AST::ASTContext^ CppSharp::Parser::ParserResult::ASTContext::get() CppSharp::Parser::AST::ASTContext^ CppSharp::Parser::ParserResult::ASTContext::get()
{ {
return gcnew CppSharp::Parser::AST::ASTContext((::CppSharp::CppParser::AST::ASTContext*)((::CppSharp::CppParser::ParserResult*)NativePtr)->ASTContext); return gcnew CppSharp::Parser::AST::ASTContext((::CppSharp::CppParser::AST::ASTContext*)((::CppSharp::CppParser::ParserResult*)NativePtr)->ASTContext);
} }
void CppSharp::Parser::ParserResult::ASTContext::set(CppSharp::Parser::AST::ASTContext^ value) void CppSharp::Parser::ParserResult::ASTContext::set(CppSharp::Parser::AST::ASTContext^ value)
{ {
((::CppSharp::CppParser::ParserResult*)NativePtr)->ASTContext = (::CppSharp::CppParser::AST::ASTContext*)value->NativePtr; ((::CppSharp::CppParser::ParserResult*)NativePtr)->ASTContext = (::CppSharp::CppParser::AST::ASTContext*)value->NativePtr;
} }
CppSharp::Parser::AST::NativeLibrary^ CppSharp::Parser::ParserResult::Library::get() CppSharp::Parser::AST::NativeLibrary^ CppSharp::Parser::ParserResult::Library::get()
{ {
return gcnew CppSharp::Parser::AST::NativeLibrary((::CppSharp::CppParser::AST::NativeLibrary*)((::CppSharp::CppParser::ParserResult*)NativePtr)->Library); return gcnew CppSharp::Parser::AST::NativeLibrary((::CppSharp::CppParser::AST::NativeLibrary*)((::CppSharp::CppParser::ParserResult*)NativePtr)->Library);
} }
void CppSharp::Parser::ParserResult::Library::set(CppSharp::Parser::AST::NativeLibrary^ value) void CppSharp::Parser::ParserResult::Library::set(CppSharp::Parser::AST::NativeLibrary^ value)
{ {
((::CppSharp::CppParser::ParserResult*)NativePtr)->Library = (::CppSharp::CppParser::AST::NativeLibrary*)value->NativePtr; ((::CppSharp::CppParser::ParserResult*)NativePtr)->Library = (::CppSharp::CppParser::AST::NativeLibrary*)value->NativePtr;
} }
CppSharp::Parser::ClangParser::ClangParser(::CppSharp::CppParser::ClangParser* native) CppSharp::Parser::ClangParser::ClangParser(::CppSharp::CppParser::ClangParser* native)
{ {
NativePtr = native; NativePtr = native;
} }
CppSharp::Parser::ClangParser::ClangParser(System::IntPtr native) CppSharp::Parser::ClangParser::ClangParser(System::IntPtr native)
{ {
auto __native = (::CppSharp::CppParser::ClangParser*)native.ToPointer(); auto __native = (::CppSharp::CppParser::ClangParser*)native.ToPointer();
NativePtr = __native; NativePtr = __native;
} }
CppSharp::Parser::ParserResult^ CppSharp::Parser::ClangParser::ParseHeader(CppSharp::Parser::ParserOptions^ Opts) CppSharp::Parser::ParserResult^ CppSharp::Parser::ClangParser::ParseHeader(CppSharp::Parser::ParserOptions^ Opts)
{ {
auto arg0 = (::CppSharp::CppParser::ParserOptions*)Opts->NativePtr; auto arg0 = (::CppSharp::CppParser::ParserOptions*)Opts->NativePtr;
auto __ret = ::CppSharp::CppParser::ClangParser::ParseHeader(arg0); auto __ret = ::CppSharp::CppParser::ClangParser::ParseHeader(arg0);
if (__ret == nullptr) return nullptr; if (__ret == nullptr) return nullptr;
return gcnew CppSharp::Parser::ParserResult((::CppSharp::CppParser::ParserResult*)__ret); return gcnew CppSharp::Parser::ParserResult((::CppSharp::CppParser::ParserResult*)__ret);
} }
CppSharp::Parser::ParserResult^ CppSharp::Parser::ClangParser::ParseLibrary(CppSharp::Parser::ParserOptions^ Opts) CppSharp::Parser::ParserResult^ CppSharp::Parser::ClangParser::ParseLibrary(CppSharp::Parser::ParserOptions^ Opts)
{ {
auto arg0 = (::CppSharp::CppParser::ParserOptions*)Opts->NativePtr; auto arg0 = (::CppSharp::CppParser::ParserOptions*)Opts->NativePtr;
auto __ret = ::CppSharp::CppParser::ClangParser::ParseLibrary(arg0); auto __ret = ::CppSharp::CppParser::ClangParser::ParseLibrary(arg0);
if (__ret == nullptr) return nullptr; if (__ret == nullptr) return nullptr;
return gcnew CppSharp::Parser::ParserResult((::CppSharp::CppParser::ParserResult*)__ret); return gcnew CppSharp::Parser::ParserResult((::CppSharp::CppParser::ParserResult*)__ret);
} }
CppSharp::Parser::ClangParser::ClangParser() CppSharp::Parser::ClangParser::ClangParser()
{ {
NativePtr = new ::CppSharp::CppParser::ClangParser(); NativePtr = new ::CppSharp::CppParser::ClangParser();
} }
System::IntPtr CppSharp::Parser::ClangParser::__Instance::get() System::IntPtr CppSharp::Parser::ClangParser::__Instance::get()
{ {
return System::IntPtr(NativePtr); return System::IntPtr(NativePtr);
} }
void CppSharp::Parser::ClangParser::__Instance::set(System::IntPtr object) void CppSharp::Parser::ClangParser::__Instance::set(System::IntPtr object)
{ {
NativePtr = (::CppSharp::CppParser::ClangParser*)object.ToPointer(); NativePtr = (::CppSharp::CppParser::ClangParser*)object.ToPointer();
} }

558
src/CppParser/Bindings/CLI/CppParser.h

@ -1,279 +1,279 @@
#pragma once #pragma once
#include "CppSharp.h" #include "CppSharp.h"
#include <CppParser.h> #include <CppParser.h>
namespace CppSharp namespace CppSharp
{ {
namespace Parser namespace Parser
{ {
enum struct ParserDiagnosticLevel; enum struct ParserDiagnosticLevel;
enum struct ParserResultKind; enum struct ParserResultKind;
enum struct SourceLocationKind; enum struct SourceLocationKind;
ref class ClangParser; ref class ClangParser;
ref class ParserDiagnostic; ref class ParserDiagnostic;
ref class ParserOptions; ref class ParserOptions;
ref class ParserResult; ref class ParserResult;
namespace AST namespace AST
{ {
enum struct CppAbi; enum struct CppAbi;
ref class ASTContext; ref class ASTContext;
ref class NativeLibrary; ref class NativeLibrary;
} }
} }
} }
namespace CppSharp namespace CppSharp
{ {
namespace Parser namespace Parser
{ {
public enum struct ParserDiagnosticLevel public enum struct ParserDiagnosticLevel
{ {
Ignored = 0, Ignored = 0,
Note = 1, Note = 1,
Warning = 2, Warning = 2,
Error = 3, Error = 3,
Fatal = 4 Fatal = 4
}; };
public enum struct ParserResultKind public enum struct ParserResultKind
{ {
Success = 0, Success = 0,
Error = 1, Error = 1,
FileNotFound = 2 FileNotFound = 2
}; };
public enum struct SourceLocationKind public enum struct SourceLocationKind
{ {
Invalid = 0, Invalid = 0,
Builtin = 1, Builtin = 1,
CommandLine = 2, CommandLine = 2,
System = 3, System = 3,
User = 4 User = 4
}; };
public ref class ParserOptions : ICppInstance public ref class ParserOptions : ICppInstance
{ {
public: public:
property ::CppSharp::CppParser::ParserOptions* NativePtr; property ::CppSharp::CppParser::ParserOptions* NativePtr;
property System::IntPtr __Instance property System::IntPtr __Instance
{ {
virtual System::IntPtr get(); virtual System::IntPtr get();
virtual void set(System::IntPtr instance); virtual void set(System::IntPtr instance);
} }
ParserOptions(::CppSharp::CppParser::ParserOptions* native); ParserOptions(::CppSharp::CppParser::ParserOptions* native);
ParserOptions(System::IntPtr native); ParserOptions(System::IntPtr native);
ParserOptions(); ParserOptions();
property unsigned int ArgumentsCount property unsigned int ArgumentsCount
{ {
unsigned int get(); unsigned int get();
} }
property System::String^ FileName property System::String^ FileName
{ {
System::String^ get(); System::String^ get();
void set(System::String^); void set(System::String^);
} }
property unsigned int IncludeDirsCount property unsigned int IncludeDirsCount
{ {
unsigned int get(); unsigned int get();
} }
property unsigned int SystemIncludeDirsCount property unsigned int SystemIncludeDirsCount
{ {
unsigned int get(); unsigned int get();
} }
property unsigned int DefinesCount property unsigned int DefinesCount
{ {
unsigned int get(); unsigned int get();
} }
property unsigned int LibraryDirsCount property unsigned int LibraryDirsCount
{ {
unsigned int get(); unsigned int get();
} }
property System::String^ TargetTriple property System::String^ TargetTriple
{ {
System::String^ get(); System::String^ get();
void set(System::String^); void set(System::String^);
} }
property CppSharp::Parser::AST::ASTContext^ ASTContext property CppSharp::Parser::AST::ASTContext^ ASTContext
{ {
CppSharp::Parser::AST::ASTContext^ get(); CppSharp::Parser::AST::ASTContext^ get();
void set(CppSharp::Parser::AST::ASTContext^); void set(CppSharp::Parser::AST::ASTContext^);
} }
property int ToolSetToUse property int ToolSetToUse
{ {
int get(); int get();
void set(int); void set(int);
} }
property CppSharp::Parser::AST::CppAbi Abi property CppSharp::Parser::AST::CppAbi Abi
{ {
CppSharp::Parser::AST::CppAbi get(); CppSharp::Parser::AST::CppAbi get();
void set(CppSharp::Parser::AST::CppAbi); void set(CppSharp::Parser::AST::CppAbi);
} }
property bool NoStandardIncludes property bool NoStandardIncludes
{ {
bool get(); bool get();
void set(bool); void set(bool);
} }
property bool NoBuiltinIncludes property bool NoBuiltinIncludes
{ {
bool get(); bool get();
void set(bool); void set(bool);
} }
property bool MicrosoftMode property bool MicrosoftMode
{ {
bool get(); bool get();
void set(bool); void set(bool);
} }
property bool Verbose property bool Verbose
{ {
bool get(); bool get();
void set(bool); void set(bool);
} }
System::String^ getArguments(unsigned int i); System::String^ getArguments(unsigned int i);
void addArguments(System::String^ s); void addArguments(System::String^ s);
System::String^ getIncludeDirs(unsigned int i); System::String^ getIncludeDirs(unsigned int i);
void addIncludeDirs(System::String^ s); void addIncludeDirs(System::String^ s);
System::String^ getSystemIncludeDirs(unsigned int i); System::String^ getSystemIncludeDirs(unsigned int i);
void addSystemIncludeDirs(System::String^ s); void addSystemIncludeDirs(System::String^ s);
System::String^ getDefines(unsigned int i); System::String^ getDefines(unsigned int i);
void addDefines(System::String^ s); void addDefines(System::String^ s);
System::String^ getLibraryDirs(unsigned int i); System::String^ getLibraryDirs(unsigned int i);
void addLibraryDirs(System::String^ s); void addLibraryDirs(System::String^ s);
}; };
public ref class ParserDiagnostic : ICppInstance public ref class ParserDiagnostic : ICppInstance
{ {
public: public:
property ::CppSharp::CppParser::ParserDiagnostic* NativePtr; property ::CppSharp::CppParser::ParserDiagnostic* NativePtr;
property System::IntPtr __Instance property System::IntPtr __Instance
{ {
virtual System::IntPtr get(); virtual System::IntPtr get();
virtual void set(System::IntPtr instance); virtual void set(System::IntPtr instance);
} }
ParserDiagnostic(::CppSharp::CppParser::ParserDiagnostic* native); ParserDiagnostic(::CppSharp::CppParser::ParserDiagnostic* native);
ParserDiagnostic(System::IntPtr native); ParserDiagnostic(System::IntPtr native);
ParserDiagnostic(); ParserDiagnostic();
property System::String^ FileName property System::String^ FileName
{ {
System::String^ get(); System::String^ get();
void set(System::String^); void set(System::String^);
} }
property System::String^ Message property System::String^ Message
{ {
System::String^ get(); System::String^ get();
void set(System::String^); void set(System::String^);
} }
property CppSharp::Parser::ParserDiagnosticLevel Level property CppSharp::Parser::ParserDiagnosticLevel Level
{ {
CppSharp::Parser::ParserDiagnosticLevel get(); CppSharp::Parser::ParserDiagnosticLevel get();
void set(CppSharp::Parser::ParserDiagnosticLevel); void set(CppSharp::Parser::ParserDiagnosticLevel);
} }
property int LineNumber property int LineNumber
{ {
int get(); int get();
void set(int); void set(int);
} }
property int ColumnNumber property int ColumnNumber
{ {
int get(); int get();
void set(int); void set(int);
} }
}; };
public ref class ParserResult : ICppInstance public ref class ParserResult : ICppInstance
{ {
public: public:
property ::CppSharp::CppParser::ParserResult* NativePtr; property ::CppSharp::CppParser::ParserResult* NativePtr;
property System::IntPtr __Instance property System::IntPtr __Instance
{ {
virtual System::IntPtr get(); virtual System::IntPtr get();
virtual void set(System::IntPtr instance); virtual void set(System::IntPtr instance);
} }
ParserResult(::CppSharp::CppParser::ParserResult* native); ParserResult(::CppSharp::CppParser::ParserResult* native);
ParserResult(System::IntPtr native); ParserResult(System::IntPtr native);
ParserResult(); ParserResult();
property unsigned int DiagnosticsCount property unsigned int DiagnosticsCount
{ {
unsigned int get(); unsigned int get();
} }
property CppSharp::Parser::ParserResultKind Kind property CppSharp::Parser::ParserResultKind Kind
{ {
CppSharp::Parser::ParserResultKind get(); CppSharp::Parser::ParserResultKind get();
void set(CppSharp::Parser::ParserResultKind); void set(CppSharp::Parser::ParserResultKind);
} }
property CppSharp::Parser::AST::ASTContext^ ASTContext property CppSharp::Parser::AST::ASTContext^ ASTContext
{ {
CppSharp::Parser::AST::ASTContext^ get(); CppSharp::Parser::AST::ASTContext^ get();
void set(CppSharp::Parser::AST::ASTContext^); void set(CppSharp::Parser::AST::ASTContext^);
} }
property CppSharp::Parser::AST::NativeLibrary^ Library property CppSharp::Parser::AST::NativeLibrary^ Library
{ {
CppSharp::Parser::AST::NativeLibrary^ get(); CppSharp::Parser::AST::NativeLibrary^ get();
void set(CppSharp::Parser::AST::NativeLibrary^); void set(CppSharp::Parser::AST::NativeLibrary^);
} }
CppSharp::Parser::ParserDiagnostic^ getDiagnostics(unsigned int i); CppSharp::Parser::ParserDiagnostic^ getDiagnostics(unsigned int i);
void addDiagnostics(CppSharp::Parser::ParserDiagnostic^ s); void addDiagnostics(CppSharp::Parser::ParserDiagnostic^ s);
}; };
public ref class ClangParser : ICppInstance public ref class ClangParser : ICppInstance
{ {
public: public:
property ::CppSharp::CppParser::ClangParser* NativePtr; property ::CppSharp::CppParser::ClangParser* NativePtr;
property System::IntPtr __Instance property System::IntPtr __Instance
{ {
virtual System::IntPtr get(); virtual System::IntPtr get();
virtual void set(System::IntPtr instance); virtual void set(System::IntPtr instance);
} }
ClangParser(::CppSharp::CppParser::ClangParser* native); ClangParser(::CppSharp::CppParser::ClangParser* native);
ClangParser(System::IntPtr native); ClangParser(System::IntPtr native);
ClangParser(); ClangParser();
static CppSharp::Parser::ParserResult^ ParseHeader(CppSharp::Parser::ParserOptions^ Opts); static CppSharp::Parser::ParserResult^ ParseHeader(CppSharp::Parser::ParserOptions^ Opts);
static CppSharp::Parser::ParserResult^ ParseLibrary(CppSharp::Parser::ParserOptions^ Opts); static CppSharp::Parser::ParserResult^ ParseLibrary(CppSharp::Parser::ParserOptions^ Opts);
}; };
} }
} }

Loading…
Cancel
Save