Thursday, June 23, 2011

SharePoint FxCop Rules

http://sovfxcoprules.codeplex.com/

SP0001 - Dispose created SPSite or SPWeb objects
SP0002 - Dispose SPWeb returned from a method
SP0003 - Do not dispose SPSite.RootWeb and SPWeb.ParentWeb properties
SP0004 - Dispose SPSite returned from the SPSiteCollection.Add method
SP0005 - Dispose SPSite returned from the SPSiteCollection index operator
SP0006 - Dispose SPWeb returned from the SPSite.AllWebs.Add method
SP0007 - Dispose SPWeb returned from the SPSite.AllWebs index operator
SP0009 - Dispose SPWeb returned from the SPWeb.Webs.Add method
SP0010 - Dispose SPWeb returned from the SPWeb.Webs index operator
SP0011 - Dispose SPWeb returned from the Area.Web property
SP0012 - Dispose the SPLimitedWebPartManager.Web property
SP0013 - Do not dispose SPList.ParentWeb when using the SPList.BreakRoleInheritance method
SP0014 - Close PublishingWeb returned from the PublishingWeb.GetPublishingWebs index operator
SP0015 - Do not dispose SPSite and SPWeb returned from the GetContextSite and GetContextWeb methods
SP0017 - Do not dispose SPSite and SPWeb returned from the SPFeature.Parent property
SP0018 - Close PublishingWeb returned from the PublishingWeb.GetVariation method
SP0019 - Dispose SPSite returned from the UserProfiles.PersonalSite property
SP0008 - Do not dispose SPSite.RootWeb when using SPSite.LockIssue, SPSite.Owner or SPSite.SecondaryContact properties
SP0016 - Do not dispose SPSite and SPWeb returned from the SPContext.Current.Site, SPContext.Site, SPContext.Current.Web and SPContext.Web properties

No comments:

Post a Comment