﻿<?xml version="1.0" encoding="utf-8"?><Type Name="CentralizePInvokesIntoNativeMethodsTypeRule" FullName="Gendarme.Rules.Interoperability.CentralizePInvokesIntoNativeMethodsTypeRule"><TypeSignature Language="C#" Value="public class CentralizePInvokesIntoNativeMethodsTypeRule : Gendarme.Framework.Rule, Gendarme.Framework.IMethodRule, Gendarme.Framework.ITypeRule" /><TypeSignature Language="ILAsm" Value=".class public auto ansi beforefieldinit CentralizePInvokesIntoNativeMethodsTypeRule extends Gendarme.Framework.Rule implements class Gendarme.Framework.IMethodRule, class Gendarme.Framework.IRule, class Gendarme.Framework.ITypeRule" /><AssemblyInfo><AssemblyName>Gendarme.Rules.Interoperability</AssemblyName><AssemblyVersion>4.2.0.0</AssemblyVersion></AssemblyInfo><Base><BaseTypeName>Gendarme.Framework.Rule</BaseTypeName></Base><Interfaces><Interface><InterfaceName>Gendarme.Framework.IMethodRule</InterfaceName></Interface><Interface><InterfaceName>Gendarme.Framework.ITypeRule</InterfaceName></Interface></Interfaces><Attributes><Attribute><AttributeName>Gendarme.Framework.FxCopCompatibility("Microsoft.Design", "CA1060:MovePInvokesToNativeMethodsClass")</AttributeName></Attribute><Attribute><AttributeName>Gendarme.Framework.Problem("A p/invoke declaration was found outside a *NativeMethods type.")</AttributeName></Attribute><Attribute><AttributeName>Gendarme.Framework.Solution("Move all p/invokes declarations into the right *NativeMethods type.")</AttributeName></Attribute></Attributes><Docs><summary>
             This rule will warn you if p/invoke declarations are found outside some
             specially named types. The convention makes it easier to know which type
             of security checks are done (at runtime) and how critical is a security 
             audit for them. In all cases the type should not be visible (i.e. <c>internal</c> 
             in C#) outside the assembly.
             
             Note that the type naming itself has no influence on security (either with 
             Code Access Security or with CoreCLR for Silverlight). The naming convention
             includes the presence or absence of the <c>[SuppressUnmanagedCodeSecurity]</c> 
             security attribute based on the type name.
             <list><item><description><c>NativeMethods</c> should not be decorated with a 
             <c>[SuppressUnmanagedCodeSecurity]</c>. This will let CAS do a stackwalk to 
             ensure the code can be...</description></item><item><description><c>SafeNativeMethods</c> should be decorated with a 
             <c>[SuppressUnmanagedCodeSecurity] attribute</c>. The attribute means that no 
             stackwalk will occurs.</description></item><item><description><c>UnsafeNativeMethods</c> should be decorated with a 
             <c>[SuppressUnmanagedCodeSecurity] attribute</c>. The attribute means that no 
             stackwalk will occurs. However since the p/invoke methods are named unsafe then
             the rule will warn an audit-level defect to review the code.</description></item></list></summary><remarks>This rule is available since Gendarme 2.8</remarks></Docs><Members><Member MemberName=".ctor"><MemberSignature Language="C#" Value="public CentralizePInvokesIntoNativeMethodsTypeRule ();" /><MemberSignature Language="ILAsm" Value=".method public hidebysig specialname rtspecialname instance void .ctor() cil managed" /><MemberType>Constructor</MemberType><AssemblyInfo><AssemblyVersion>4.2.0.0</AssemblyVersion></AssemblyInfo><Parameters /><Docs><summary>To be added.</summary><remarks>To be added.</remarks></Docs></Member><Member MemberName="CheckMethod"><MemberSignature Language="C#" Value="public Gendarme.Framework.RuleResult CheckMethod (Mono.Cecil.MethodDefinition method);" /><MemberSignature Language="ILAsm" Value=".method public hidebysig newslot virtual instance valuetype Gendarme.Framework.RuleResult CheckMethod(class Mono.Cecil.MethodDefinition method) cil managed" /><MemberType>Method</MemberType><AssemblyInfo><AssemblyVersion>4.2.0.0</AssemblyVersion></AssemblyInfo><ReturnValue><ReturnType>Gendarme.Framework.RuleResult</ReturnType></ReturnValue><Parameters><Parameter Name="method" Type="Mono.Cecil.MethodDefinition" /></Parameters><Docs><param name="method">To be added.</param><summary>To be added.</summary><returns>To be added.</returns><remarks>To be added.</remarks></Docs></Member><Member MemberName="CheckType"><MemberSignature Language="C#" Value="public Gendarme.Framework.RuleResult CheckType (Mono.Cecil.TypeDefinition type);" /><MemberSignature Language="ILAsm" Value=".method public hidebysig newslot virtual instance valuetype Gendarme.Framework.RuleResult CheckType(class Mono.Cecil.TypeDefinition type) cil managed" /><MemberType>Method</MemberType><AssemblyInfo><AssemblyVersion>4.2.0.0</AssemblyVersion></AssemblyInfo><ReturnValue><ReturnType>Gendarme.Framework.RuleResult</ReturnType></ReturnValue><Parameters><Parameter Name="type" Type="Mono.Cecil.TypeDefinition" /></Parameters><Docs><param name="type">To be added.</param><summary>To be added.</summary><returns>To be added.</returns><remarks>To be added.</remarks></Docs></Member></Members></Type>