共用方式為


SPSite members

Include protected members
Include inherited members

表示 Web 應用程式,包括最上層的網站和所有子網站中的網站集合。在 Web 應用程式中的所有網站集合的集合所組成的SPSiteCollection物件中的表示每個SPSite物件或網站集合。

The SPSite type exposes the following members.

Constructors

  Name Description
Public method SPSite(Guid) 初始化根據指定的識別碼,網站集合的SPSite類別的新執行個體。
Public method SPSite(String) 初始化根據指定的 URL 的SPSite類別的新執行個體。
Public method SPSite(Guid, SPUrlZone) 初始化根據指定的網站集合的 GUID 和 URL 區域的SPSite類別的新執行個體。
Public method SPSite(Guid, SPUserToken) 初始化根據指定的網站集合的 GUID 和使用者語彙基元的SPSite類別的新執行個體。
Public method SPSite(String, SPUserToken) 初始化根據指定的絕對 URL 和使用者語彙基元的SPSite類別的新執行個體。
Public method SPSite(Guid, SPUrlZone, SPUserToken) 初始化根據指定的網站集合的 GUID、 URL] 區域中,以及使用者語彙基元的SPSite類別的新執行個體。

Top

Properties

  Name Description
Public property AdministrationSiteType 表示支援的SharePoint Foundation的系統管理網站類型。
Public property AllowCreateDeclarativeWorkflow
Public property AllowDesigner 用來指定或擷取網站集合的Allow Designer屬性。
Public property AllowExternalEmbedding 設定此網站集合的嵌入該控制項外部網域
Public property AllowMasterPageEditing 用來指定或擷取可讓您編輯主版頁面的網站集合屬性。
Public property AllowRevertFromTemplate 用來指定或擷取可讓您從範本還原網站集合屬性。
Public property AllowRssFeeds 取得指定的網站集合是否允許 RSS 摘要的Boolean值。
Public property AllowSaveDeclarativeWorkflowAsTemplate
Public property AllowSavePublishDeclarativeWorkflow
Public property AllowSelfServiceUpgrade 版本升級是否允許此網站上。
Public property AllowSelfServiceUpgradeEvaluation 是否允許升級評估網站集合。
Public property AllowUnsafeUpdates 取得或設定指定是否允許更新到資料庫或不需要安全性驗證的結果GET要求的Boolean值。
Public property AllWebs 取得包含在網站集合,包括最上層的網站及子網站內的所有網站集合。
Public property ApplicationRightsMask 取得父網站集合的 Web 應用程式的權限遮罩。
Public property Archived 是否此網站位在封存的模式。
Public property Audit 取得附加至網站集合的稽核存放區。
Public property AuditLogTrimmingCallout 取得或設定執行稽核記錄裁剪的物件的類別名稱。
Public property AuditLogTrimmingRetention 取得或設定的稽核記錄檔的資料保留的天數。
Public property AverageResourceUsage 平均資源使用狀況設定視窗上面的網站集合,以天為單位。
Public property BrowserDocumentsEnabled 表示是否開啟瀏覽器中的文件或不。
Public property Cache 安全執行緒快取可能會用來儲存非常少量的這SPSite相關聯的資料。
Public property CanUpgrade 指出可以升級這個物件的屬性。
Public property CatchAccessDeniedException 保留給內部使用。請改用 [ CatchAccessDeniedException ] 屬性來指定是否SharePoint Foundation補漏白,並處理 「 拒絕存取 」 的例外狀況。
Public property CertificationDate 取得日期和時間的站台的使用確認集合之自動刪除。
Public property CompatibilityLevel 取得用於主要版本層級相容性檢查此網站集合的主要版本。
Public property ContentDatabase 取得與網站集合相關聯的內容資料庫。
Public property CurrentChangeToken 取得將用來記錄下一步] 變更至網站集合變更語彙基元。
Public property CurrentResourceUsage 表示目前的資源使用狀況,網站集合。
Public property DeadWebNotificationCount 取得已傳送有關網站網站集合中沒有使用的通知數目。
Public property DenyPermissionsMask 這個屬性會拒絕指定使用權限遮罩,包括網站集合管理員的網站集合的所有使用者的權限提高權限的處理序識別身份是具有完整權限的唯一例外
Public property EvalSiteId 升級評估網站集合,如果有的話識別建立使用此網站集合。否則,它會是空的 Guid 值。
Public property EventReceivers 提供在網站集合的範圍內發生的事件的事件接收器。
Public property ExpirationDate 指定要在其後升級評估網站集合會自動被刪除的日期。
Public property FeatureDefinitions 取得網站集合的功能定義的集合。
Public property Features 取得網站集合相關聯的SPFeature物件的集合。
Public property FileNotFoundUrl 取得 SPSite swerver 相對 Url 或檔案找不到網頁的絕對 URL。這個值當做 HTTP 要求重新導向 URL 位置可以找到的資源。
Public property GlobalPermMask Obsolete. 使用ApplicationRightsMask屬性來代替取得 Web 應用程式的權限遮罩。(在Windows SharePoint Services 2.0, GlobalPermMask屬性有不在虛擬伺服器全域使用的權限遮罩的權限)。
Public property HasAppPrincipalContext 是否此[SPSite]物件正在執行中應用程式主體內容。當應用程式主體內容中執行[SPSite]物件時,要求權限可能會受到應用程式主體的權限,即使[SPSite]物件建立與系統帳戶。
Public property HideSystemStatusBar 是否應隱藏站台的系統狀態] 列。
Public property HostHeaderIsSiteName 取得Boolean值,指定的主機標頭是否唯一識別 [網站集合使用而不是與伺服器相對的路徑。
Public property HostName 取得裝載的網站集合之伺服器的名稱。
Public property ID 取得識別網站集合的 GUID。
Public property IISAllowsAnonymous 取得Boolean值,指出在 Microsoft Internet Information Services (IIS) 時,是否要啟用匿名存取。
Public property Impersonating 取得Boolean值,指出SPSite物件的模擬狀態。
Public property InheritAllowSelfServiceUpgradeEvaluationSetting AllowSelfServiceUpgradeEvaluation 值是否繼承自父代。
Public property InheritAllowSelfServiceUpgradeSetting AllowSelfServiceUpgrade 值是否繼承自父代。
Public property IsEvalSite 表示網站集合或不是升級的評估網站集合
Public property IsPaired Obsolete. 取得Boolean值,指出是否要將網站集合成對隨其父代。
Public property IsReadLocked 設定或取得值,指定網站集合已經被鎖定,無法讀取存取。
Public property LastContentModifiedDate 取得日期和時間在國際標準時間 (UTC) 上次變更網站內容時。
Public property LastSecurityModifiedDate 取得日期和時間在國際標準時間 (UTC) 時上次變更在網站上的安全性。
Public property LockIssue 取得或設定使用的註解中鎖定網站集合。
Public property MaintenanceMode 站台是否處於維護模式
Public property NeedsUpgrade 指出這個物件需要升級的屬性。
Public property OutgoingEmailAddress
Public property Owner 取得或設定網站集合擁有人。(唯讀在沙箱化解決方案中。)
Public property Port 包含網站集合的虛擬伺服器上取得用於輸入和輸出的連接埠號碼。
Public property PortalName 取得或設定入口網站的名稱。(唯讀在沙箱化解決方案中。)
Public property PortalUrl 取得或設定入口網站的 URL。(唯讀在沙箱化解決方案中。)
Public property PrimaryUri
Public property Protocol 取得伺服器所使用的通訊協定。
Public property Quota 取得或設定網站集合的配額。
Public property ReadLocked 此成員是保留給內部使用,而不是用來直接從您的程式碼使用請改用 [ IsReadLocked ] 屬性。
Public property ReadOnly 取得或設定指定的網站集合是唯讀、 鎖定,且無法使用的寫入權限的Boolean值。
Public property RecycleBin 取得網站集合集合資源回收筒] 的項目。
Public property RequiredDesignerVersion
Public property ResourceQuotaExceeded 指出是否已經自最後的每日配額,重設或不超過這個網站集合資源配額限制。
Public property ResourceQuotaExceededNotificationSent 指出資源超出配額通知是否已傳送 (或沒有) 自最後的每日配額此網站集合重設。
Public property ResourceQuotaWarningNotificationSent 指示資源配額警告通知所傳送或沒有此網站集合的最後一個每日配額後重設。
Public property RootWeb 取得根網站的網站集合。
Public property SchemaVersion 取得此網站集合,為了更細緻的升級相容性檢查版本。
Public property ScriptSafeDomains 傳回的指令碼集合,此網站集合的安全外部網域
Public property ScriptSafePages 傳回的指令碼集合,此網站集合的安全內部頁面
Public property SearchServiceInstance 取得SPServiceInstance物件,表示相關聯的網站集合 SharePoint 搜尋服務執行個體。
Public property SecondaryContact 取得或設定用於網站集合的第二位連絡人。(唯讀在沙箱化解決方案中。)
Public property ServerRelativeUrl 網站集合中取得根 Web 站台的伺服器相對 URL。
Public property ShareByEmailEnabled True 表示該使用者將能夠授與權限,能為遊客網站集合內的資源時的 ShareByEmailEnabled
Public property ShareByLinkEnabled 屬性會指出是否該使用者將能夠共用可以不需登入存取的文件的連結
Public property ShowURLStructure 指出是否要顯示網站集合的 URL 結構。
Public property SiteSubscription 取得此網站集合所屬的訂閱。
Public property Solutions 取得網站集合中已啟動的使用者解決方案的集合。
Public property SourceSiteId 指定升級評估網站集合的來源站台 Id。
Public property SyndicationEnabled 取得或設定指定是否啟用網站集合的 rss 的Boolean值。
Public property SystemAccount Gets the system account of the site collection.
Public property TrimAuditLog 取得或設定值,指定是否要定期多餘從稽核記錄檔中移除。
Public property UIVersionConfigurationEnabled Obsolete. 取得或設定布林值,指定是否啟用視覺化升級的使用者介面 (UI) 來變更網站集合的 UI 版本。
Public property UpgradeContext 其他的升級內容屬性。
Public property UpgradeInfo
Public property UpgradeRedirectUri Obsolete. Gets an object representation of the upgrade redirect uniform resource identifier (URI) of the site collection.
Public property UpgradeReminderDate
Public property Upgrading 指定是否目前正在升級站台。
Public property Url Gets the full URL to the root Web site of the site collection, including host name, port number, and path.
Public property Usage Gets information about site usage, including bandwidth, storage, and number of visits to the site collection.
Public property UserAccountDirectoryPath Obsolete. 取得或設定網站集合的特定提供者的使用者帳戶目錄路徑。
Public property UserCodeEnabled 取得值,這個值,指出是否啟用網站集合的使用者程式碼服務。
Public property UserCustomActions 取得包含指派給這個站台的SPUserCustomAction物件清單的SPUserCustomActionCollection物件。
Public property UserDefinedWorkflowsEnabled 取得或設定布林值,這個值,指出是否啟用使用者定義的工作流程。
Public property UserIsSiteAdminInSystem 目前的使用者是否是網站集合系統管理員在系統 (唯讀模式前修剪套用)
Public property UserToken Gets the user token that is associated with the site collection.
Public property WarningNotificationSent Gets a Boolean value that indicates whether a warning notification has been sent.
Public property WebApplication Gets the SharePoint Foundation Web application to which the site collection belongs.
Public property WorkflowManager Gets the SPWorkflowManager object that is associated with the site collection, enabling you to centrally control the workflow templates and instances across the site collection.
Public property WriteLocked Gets or sets a Boolean value that specifies whether the site collection is locked and unavailable for Write access.
Public property Zone Gets the URL zone that was specified in the constructor that was used to create the current SPSite object.

Top

Methods

  Name Description
Public method AddWorkItem(Guid, DateTime, Guid, Guid, Guid, Int32, Boolean, Guid, Guid, Int32, [], String, Guid) Adds a work item to the site collection.
Public method AddWorkItem(Guid, DateTime, Guid, Guid, Guid, Int32, Boolean, Guid, Guid, Int32, [], String, Guid, Boolean) Adds a work item to the site collection.
Public method BypassUseRemoteApis Bypasses using SOAP, WebDAV, or Microsoft Office SharePoint Designer 2007 interfaces to access the site collection.
Public method CheckForPermissions Checks the permissions for a given set of rights and throws an Unauthorized Access exception if the permission check fails.
Public method Close Closes the site collection and releases resources.
Public method ConfirmUsage Certifies that the site collection is in use.
Public method CreatePreviewSPSite 建立暫存的評估洩憤這洩憤,為了判斷升級是否可能會成功。
Public method Delete() Deletes the site collection from the server.
Public method Delete(Boolean) Deletes the site collection from the server and removes the site collection users from Active Directory Domain Services (ADDS) if bDeleteADAccounts is true.
Public method Delete(Boolean, Boolean) 從伺服器刪除網站集合、 選擇性地移除網站集合使用者從現用目錄網域服務 (加入),並選擇性地使用計時器工作,然後逐漸刪除網站集合。
Public method Dispose Releases all unmanaged resources that are used by the site collection object.
Public method DoesUserHavePermissions(SPReusableAcl, SPBasePermissions) Returns a Boolean value indicates whether the user has permissions for the specified set of rights.
Public method DoesUserHavePermissions(SPReusableAcl, SPBasePermissions, SPWeb) Returns a Boolean value that indicates whether the user has permissions for the specified Web site and set of rights.
Public method Equals (Inherited from Object.)
Public methodStatic member Exists(Uri) Returns a Boolean value that indicates whether the specified site collection exists.
Public methodStatic member Exists(Uri, Boolean) 判斷具有指定之 uri 的網站是否存在。檢查設定 db 快取,此外,檢查內容資料庫,如果checkContentDb是,則為 true。
Public method ExtendUpgradeReminderDate WebApplication.UpgradeReminderDelay 在指定的天數來為這個 SPSite 擴充升級提醒日期
Protected method Finalize (Inherited from Object.)
Public method GetAllReusableAcls() Returns the reusable access control lists (ACLs) for the site collection.
Public method GetAllReusableAcls(Int32) 傳回符合指定限制的網站集合的可重複使用的存取控制清單 (Acl)。
Public method GetCatalog 從網站集合,包括由使用者定義的自訂組件庫會傳回清單範本庫、 範本藝廊網站、 網頁組件庫、 主版頁面圖庫] 中或其他程式庫。
Public method GetChanges() 傳回預設的網站集合的目前變更記錄檔中列出的變更數量。
Public method GetChanges(SPChangeQuery) 從變更記錄檔做為篩選依據指定的查詢會傳回一系列的變更。
Public method GetChanges(SPChangeToken) 傳回集合的變更,從變更記錄檔中的特定點開始。
Public method GetChanges(SPChangeToken, SPChangeToken) 傳回集合的一段指定時間登入的變更。
Public method GetCustomListTemplates 傳回指定之站台的使用者建立的自訂清單範本集合。
Public method GetCustomWebTemplates 傳回根據指定的地區設定識別碼 (LCID) 的網站集合的網站範本的集合。
Public method GetEffectiveRightsForAcl(SPReusableAcl) 傳回目前使用者具有 「 指定的存取控制清單 (ACL) 的實際權限。
Public method GetEffectiveRightsForAcl(SPReusableAcl, SPWeb) 傳回目前使用者具有指定的存取控制清單 (ACL) 的實際權限。
Public method GetFeaturesIfLoaded 如果站台已載入的功能,這會傳回它們。如果它們尚未完成載入,這個呼叫會傳回 null (且不會造成任何往返所產生)
Public method GetHashCode (Inherited from Object.)
Public method GetRecycleBinItems 傳回根據指定的查詢的資源回收筒] 項目集合。
Public method GetRecycleBinStatistics 取得項目數目,在 [資源回收筒] 和它的大小。
Public method GetReusableAclForScope 傳回指定範圍的可重複使用的存取控制清單 (ACL)。
Public method GetSelfServiceSiteCreationSettings 取得用於自助網站架設] 的設定。
Public method GetType (Inherited from Object.)
Public method GetUrls 擷取網站集合,包含主要 URL 與次要的所有 Url 的所有 Url
Public method GetVisualReport 擷取此網站集合和其對應的視覺化升級資料中的所有網站的SPSite.WebVisualReport物件清單。
Public method GetWebTemplates(UInt32) 傳回可用於建立網站集合內的 Web 站台的站台定義的集合。
Public method GetWebTemplates(UInt32, Int32) 傳回可用於建立網站集合內的 Web 站台的站台定義的集合。
Public method GetWorkItems Returns the individual work items, number of columns, and number of rows in the specified work item collection as output parameters.
Public method HasEvalSite 決定或不在網站集合是否有升級評估站台。
Public method Invalidate IUpgradable 介面實作
Public methodStatic member InvalidateCacheEntry Removes the specified cache entry and returns a Boolean value that indicates whether the entry was cached.
Public method IsScriptSafe 驗證指定的 uri,針對網站集合的指令碼安全設定,並傳回如果安全的則為 true false,如果不是
Public methodStatic member LookupUriInRemoteFarm Returns the Uniform Resource Identifier (URI) of a Web site in the specified remote server farm.
Public method MakeFullUrl Returns the full URL for the specified server-relative URL.
Protected method MemberwiseClone (Inherited from Object.)
Public method NeedsUpgradeByType true 如果物件需要升級。否則,false。
Public method OpenWeb() Returns the Web site that is associated with the URL that is used in an SPSite constructor.
Public method OpenWeb(Guid) Returns the Web site with the specified GUID.
Public method OpenWeb(String) Returns the Web site that is located at the specified server-relative or site-relative URL.
Public method OpenWeb(String, SPSiteOpenWebOptions) 傳回位於指定的伺服器相對於] 或 [網站相對 URL,並套用的網站指定給它的選項。
Public method OpenWeb(String, Boolean) Returns the Web site that is located at the specified server-relative or site-relative URL based on a Boolean value that specifies whether the exact URL must be supplied.
Public method QueryFeatures(Guid) 取得具有特定的定義識別項的功能部署此網站集合中的集合。
Public method QueryFeatures(Guid, Boolean) 取得具有特定的定義的識別項,包括或不需要升級功能的功能部署此網站集合中的集合。
Public method QueryFeatures(Guid, Version) 取得具有特定的定義識別項和特定版本的功能部署此網站集合中的集合。
Public method QueryFeatures(SPFeatureScope, Boolean) 取得在這個網站集合與網站或網頁範圍,其中包括唯一的功能或不需要升級中部署的功能集合。
Public method RecalculateStorageMetrics
Public method RecalculateStorageUsed Recalculates the storage that is used by the site collection.
Public method RefreshEmailEnabledObjects Refreshes the email–enabled objects of the site collection.
Public method RemoveUrl 這是從網站集合中移除第二個 URL 的主體。
Public method Rename 新的 url 將變更主機標頭名稱的網站集合的 URL。
Public method RunHealthCheck
Public method RunUpgradeSiteSession
Public method SelfServiceCreateSite(String, String, String, UInt32, String, String, String, String, String, String, String) Creates a site collection by using Self-Service Site Creation.
Public method SelfServiceCreateSite(String, String, String, UInt32, String, String, String, String, String, String, String, String) Creates a site collection by using Self-Service Site Creation based on the specified quota template and other information.
Public method SelfServiceCreateSite(String, String, String, UInt32, Int32, String, String, String, String, String, String, String, String)
Public method SelfServiceCreateSite(String, String, String, UInt32, String, String, String, String, String, String, String, String, SPSiteSubscription) 藉由使用 [自助網站架設] 根據指定的配額範本和其他指定的資訊建立網站集合 (請參閱參數清單)。
Public method SelfServiceCreateSite(String, String, String, UInt32, Int32, String, String, String, String, String, String, String, String, SPSiteSubscription) 使用 [自助網站架設] 根據指定的配額範本和其他資訊,以建立網站集合。
Public method SetUrl 設定次要的 URL 和網站集合的區域。如果 URL 存在網站集合,然後我們只更新區域的現有的 URL。如果 URL 不存在,我們將加入 URL 和網站集合的區域。
Public method StorageManagementInformation Obsolete. 傳回存放管理網站集合的相關資訊。
Public method ToString 傳回的網站集合的名稱。 (Overrides Object.ToString().)
Public method UpdateClientObjectModelUseRemoteAPIsPermissionSetting
Public method UpdateValidationKey 更新用來產生表單摘要式驗證的網站集合的索引鍵。
Public method Upgrade() 升級這個物件
Public method Upgrade(Boolean) 升級這個物件
Public methodStatic member ValidateDomainCompatibility(String, String) 確認兩個 Url 是否指向相同的網站集合,即使是不同的 Url 的網域部分。
Public methodStatic member ValidateDomainCompatibility(SPSite, SPSite) 確認兩個 Url 有相容的網域。
Public method VisualUpgradeWebs Obsolete. 新的 SharePoint ui 更新此網站中的所有網站。

Top

Fields

  Name Description
Public fieldStatic member MaxFullUrlLength 表示可以使用絕對 URL 中,網站集合的字元的最大數目。
Public fieldStatic member MaxWebNameLength 表示可用於網站集合的站台名稱的字元的最大數目。

Top

請參閱

參照

SPSite class

Microsoft.SharePoint namespace