コード例 #1
0
    private static void Test8ByteHFA(PlatformDefaultMemberFunctionNative.C *instance)
    {
        PlatformDefaultMemberFunctionNative.SizeF result = instance->vtable->getSize(instance, 1234);

        Assert.AreEqual(instance->width, result.width);
        Assert.AreEqual(instance->height, result.height);
    }
コード例 #2
0
    private static void Test8ByteHFAUnmanagedCallersOnly()
    {
        PlatformDefaultMemberFunctionNative.C     c      = CreateCWithUnmanagedCallersOnlyVTable(2.0f, 3.0f);
        PlatformDefaultMemberFunctionNative.SizeF result = PlatformDefaultMemberFunctionNative.GetSizeFromManaged(&c);

        Assert.AreEqual(c.width, result.width);
        Assert.AreEqual(c.height, result.height);
    }