public void MapWithCustomMap() { var c1 = new CustomMap1() { InnerString = "Hello" }; var c2 = c1.Map <CustomMap2>(); Assert.Equal("Hello", c2.InnerString); Assert.Equal(2, c2.CustomMap); var c3 = c1.Map <CustomMap2, CustomMapper>(); Assert.Null(c3.InnerString); FWMapperHelper.AddMap <CustomMap1, CustomMap2, CustomMapper>(); var c4 = c1.Map <CustomMap2>(); Assert.Null(c4.InnerString); }
static FWSecureInt() { FWMapperHelper.AddMap <FWSecureInt, int, FWSecureIntInjection>(); FWMapperHelper.AddMap <int, FWSecureInt, FWSecureIntInjection>(); }
static FWSecureLong() { FWMapperHelper.AddMap <FWSecureLong, long, FWSecureLongInjection>(); FWMapperHelper.AddMap <long, FWSecureLong, FWSecureLongInjection>(); }