Export (0) Print
Expand All

SPServerCollection Class

Windows SharePoint Services 3

Represents a collection of SPServer objects.

Namespace:  Microsoft.SharePoint.Administration
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)

[SharePointPermissionAttribute(SecurityAction.LinkDemand, ObjectModel = true)]
public sealed class SPServerCollection : SPPersistedChildCollection<SPServer>

Use either the Servers property of the SPFarm class, or the SPServerCollection constructor, to get the collection of servers that is used in the specified server farm.

Use an indexer to return a single server from the collection. For example, if the collection is assigned to a variable named myServers, use myServers[index] in C#, or myServers(index) in Visual Basic, where index is either the GUID or the name that identifies the service.

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Community Additions

ADD
Show:
© 2014 Microsoft