Example #1
0
 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");
 }
Example #2
0
 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");
 }
Example #3
0
        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);
        }
Example #4
0
		public ItaniumTypeInfo (CppLibrary lib, string typeName, Type interfaceType, Type nativeLayout, Type/*?*/ wrapperType)
			: base (lib, typeName, interfaceType, nativeLayout, wrapperType)
		{
		}
Example #5
0
 public override CppTypeInfo MakeTypeInfo(CppLibrary lib, string typeName, Type interfaceType, Type layoutType /*?*/, Type /*?*/ wrapperType)
 {
     return(new ItaniumTypeInfo(lib, typeName, interfaceType, layoutType, wrapperType));
 }
Example #6
0
 public ItaniumTypeInfo(CppLibrary lib, string typeName, Type interfaceType, Type nativeLayout, Type /*?*/ wrapperType)
     : base(lib, typeName, interfaceType, nativeLayout, wrapperType)
 {
 }
Example #7
0
		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);
		}
Example #8
0
 public void TestCreateNullLibName()
 {
     CppLibrary cppl = new CppLibrary (null, new VirtualOnlyAbi ());
 }
Example #9
0
 public void TestCreateNullAbi()
 {
     CppLibrary cppl = new CppLibrary ("foo", null);
 }
Example #10
0
 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));
 }
Example #11
0
 public override CppTypeInfo MakeTypeInfo(CppLibrary lib, string typeName, Type interfaceType, Type layoutType/*?*/, Type/*?*/ wrapperType)
 {
     return new ItaniumTypeInfo (lib, typeName, interfaceType, layoutType, wrapperType);
 }