C# 是否必须处置以下SharePoint对象?
我想确保SharePoint中没有内存泄漏,所以完成后是否需要为以下SharePoint对象调用dispose?我想我不应该这么做,因为我没有创建新的和使用GetCurrent,但是使用SharePoint很难说C# 是否必须处置以下SharePoint对象?,c#,sharepoint,sharepoint-2010,C#,Sharepoint,Sharepoint 2010,我想确保SharePoint中没有内存泄漏,所以完成后是否需要为以下SharePoint对象调用dispose?我想我不应该这么做,因为我没有创建新的和使用GetCurrent,但是使用SharePoint很难说 Microsoft.SharePoint.WebControls.SiteActions siteActions = SiteActions.GetCurrent(this.Page); Microsoft.SharePoint.WebControls.PageStateA
Microsoft.SharePoint.WebControls.SiteActions siteActions
= SiteActions.GetCurrent(this.Page);
Microsoft.SharePoint.WebControls.PageStateActionButton psab
= PageStateActionButton.GetCurrent(this.Page);
Microsoft.SharePoint.WebControls.SPRibbon ribbon
= Microsoft.SharePoint.WebControls.SPRibbon.GetCurrent(this.Page);