Beispiel #1
0
        public void HasTypeReference(ModuleDefinition module)
        {
            Assert.IsTrue (module.HasTypeReference ("System.Attribute"));
            Assert.IsTrue (module.HasTypeReference ("mscorlib", "System.Attribute"));

            Assert.IsFalse (module.HasTypeReference ("System.Core", "System.Attribute"));
            Assert.IsFalse (module.HasTypeReference ("System.Linq.Enumerable"));
        }
Beispiel #2
0
		static bool HasNeededReference (ModuleDefinition module)
		{
			foreach (var type in types)
				if (module.HasTypeReference (type))
					return true;

			return false;
		}