Exemplo n.º 1
0
 public static void NetCodeGroupCallMethods()
 {
     Policy.NetCodeGroup ncg = new Policy.NetCodeGroup(new Policy.GacMembershipCondition());
     string teststring = Policy.NetCodeGroup.AbsentOriginScheme;
     teststring = Policy.NetCodeGroup.AnyOtherOriginScheme;
     ncg.AddConnectAccess("test", new Policy.CodeConnectAccess("test", 0));
     Policy.CodeGroup cg = ncg.Copy();
     bool equals = ncg.Equals(new object());
     System.Collections.DictionaryEntry[] de = ncg.GetConnectAccessRules();
     int hash = ncg.GetHashCode();
     ncg.ResetConnectAccess();
     Policy.PolicyStatement ps = ncg.Resolve(new Policy.Evidence());
     cg = ncg.ResolveMatchingCodeGroups(new Policy.Evidence());
 }
Exemplo n.º 2
0
        public static void NetCodeGroupCallMethods()
        {
            Policy.NetCodeGroup ncg = new Policy.NetCodeGroup(new Policy.GacMembershipCondition());
            string teststring       = Policy.NetCodeGroup.AbsentOriginScheme;

            teststring = Policy.NetCodeGroup.AnyOtherOriginScheme;
            ncg.AddConnectAccess("test", new Policy.CodeConnectAccess("test", 0));
            Policy.CodeGroup cg     = ncg.Copy();
            bool             equals = ncg.Equals(new object());

            System.Collections.DictionaryEntry[] de = ncg.GetConnectAccessRules();
            int hash = ncg.GetHashCode();

            ncg.ResetConnectAccess();
            Policy.PolicyStatement ps = ncg.Resolve(new Policy.Evidence());
            cg = ncg.ResolveMatchingCodeGroups(new Policy.Evidence());
        }