public void TestGetClass() { VirtualOnlyAbi abi = new VirtualOnlyAbi (); CppLibrary cppl = new CppLibrary ("FooLib", abi); EmptyTestInterface klass = cppl.GetClass<EmptyTestInterface,EmptyTestStruct,CppMockObject> ("FooClass"); Assert.IsNotNull (klass, "#A1"); }
public void TestProperties() { VirtualOnlyAbi abi = new VirtualOnlyAbi (); CppLibrary cppl = new CppLibrary ("FooLib", abi); Assert.AreEqual ("FooLib", cppl.Name, "#A1"); Assert.AreSame (abi, cppl.Abi, "#A2"); }
static Libs() { string lib; CppAbi abi; if (Environment.OSVersion.Platform == PlatformID.Unix) { lib = "{0}.so"; abi = new ItaniumAbi (); } else if (Environment.OSVersion.Platform == PlatformID.Win32NT) { // for Windows... lib = "{0}d4.dll"; abi = new MsvcAbi (); } else { // for Mac... lib = "/Library/Frameworks/{0}.framework/Versions/Current/{0}"; abi = new ItaniumAbi (); } QtCore = new CppLibrary (string.Format(lib, "QtCore"), abi); QtGui = new CppLibrary (string.Format(lib, "QtGui"), abi); }
public ItaniumTypeInfo (CppLibrary lib, string typeName, Type interfaceType, Type nativeLayout, Type/*?*/ wrapperType) : base (lib, typeName, interfaceType, nativeLayout, wrapperType) { }
public override CppTypeInfo MakeTypeInfo(CppLibrary lib, string typeName, Type interfaceType, Type layoutType /*?*/, Type /*?*/ wrapperType) { return(new ItaniumTypeInfo(lib, typeName, interfaceType, layoutType, wrapperType)); }
public ItaniumTypeInfo(CppLibrary lib, string typeName, Type interfaceType, Type nativeLayout, Type /*?*/ wrapperType) : base(lib, typeName, interfaceType, nativeLayout, wrapperType) { }
public virtual CppTypeInfo MakeTypeInfo (CppLibrary lib, string typeName, Type interfaceType, Type layoutType/*?*/, Type/*?*/ wrapperType) { Debug.Assert (lib.Abi == this); return new CppTypeInfo (lib, typeName, interfaceType, layoutType ?? typeof (EmptyNativeLayout), wrapperType); }
public void TestCreateNullLibName() { CppLibrary cppl = new CppLibrary (null, new VirtualOnlyAbi ()); }
public void TestCreateNullAbi() { CppLibrary cppl = new CppLibrary ("foo", null); }
public virtual CppTypeInfo MakeTypeInfo(CppLibrary lib, string typeName, Type interfaceType, Type layoutType /*?*/, Type /*?*/ wrapperType) { Debug.Assert(lib.Abi == this); return(new CppTypeInfo(lib, typeName, interfaceType, layoutType ?? typeof(EmptyNativeLayout), wrapperType)); }
public override CppTypeInfo MakeTypeInfo(CppLibrary lib, string typeName, Type interfaceType, Type layoutType/*?*/, Type/*?*/ wrapperType) { return new ItaniumTypeInfo (lib, typeName, interfaceType, layoutType, wrapperType); }