public static bool IsPublic(this ObfuscationAttribute attribute, bool isPublicDefault) { if (attribute != null) { return(attribute.Exclude); } return(isPublicDefault); }
public void StripAfterObfuscation_Set_GetReturnsExpected(bool value) { var attribute = new ObfuscationAttribute { StripAfterObfuscation = value }; Assert.Equal(value, attribute.StripAfterObfuscation); }
public void Feature_Set_GetReturnsExpected(string value) { var attribute = new ObfuscationAttribute { Feature = value }; Assert.Equal(value, attribute.Feature); }
public void Exclude_Set_GetReturnsExpected(bool value) { var attribute = new ObfuscationAttribute { Exclude = value }; Assert.Equal(value, attribute.Exclude); }
public void ApplyToMembers_Set_GetReturnsExpected(bool value) { var attribute = new ObfuscationAttribute { ApplyToMembers = value }; Assert.Equal(value, attribute.ApplyToMembers); }
public void Ctor_Default() { var attribute = new ObfuscationAttribute(); Assert.True(attribute.ApplyToMembers); Assert.True(attribute.Exclude); Assert.Equal("all", attribute.Feature); Assert.True(attribute.StripAfterObfuscation); }
private static void ShowObfuscation( ObfuscationAttribute ob, string target) { Console.WriteLine("\r\nObfuscationAttribute properties for: {0}", target); Console.WriteLine(" Exclude: {0}", ob.Exclude); Console.WriteLine(" Feature: {0}", ob.Feature); Console.WriteLine(" StripAfterObfuscation: {0}", ob.StripAfterObfuscation); Console.WriteLine(" ApplyToMembers: {0}", ob.ApplyToMembers); }