Exemplo n.º 1
0
        public CloneTest(
            string myStringProperty,
            int myIntProperty,
            string protectedBackedProperty,
            string privateBackedProperty,
            CloneTest myDeepProperty = null,
            CloneTest publicDeep = null)
        {
            String = myStringProperty;
            Integer = myIntProperty;
            ProtectedDeep = myDeepProperty;
            PublicDeep = publicDeep;
            _myField = protectedBackedProperty;
            _myPrivateField = privateBackedProperty;
            var cloneTestBase = new CloneTestBase();
            cloneTestBase.TestSetString("clone-test-base");
            ObjByInterface = cloneTestBase;

            ViewLocationCache = null; // Leave null on purpose to test DeepCopy
        }
Exemplo n.º 2
0
        public CloneTest(
            string myStringProperty,
            int myIntProperty,
            string protectedBackedProperty,
            string privateBackedProperty,
            CloneTest myDeepProperty = null,
            CloneTest publicDeep     = null)
        {
            String          = myStringProperty;
            Integer         = myIntProperty;
            ProtectedDeep   = myDeepProperty;
            PublicDeep      = publicDeep;
            _myField        = protectedBackedProperty;
            _myPrivateField = privateBackedProperty;
            var cloneTestBase = new CloneTestBase();

            cloneTestBase.TestSetString("clone-test-base");
            ObjByInterface = cloneTestBase;

            ViewLocationCache = null; // Leave null on purpose to test DeepCopy
        }