Class UserGroup
- java.lang.Object
-
- com.avoka.component.sharepoint.AbstractService
-
- com.avoka.component.sharepoint.service.UserGroup
-
public class UserGroup extends AbstractService
Provides a UserGroup SharePoint web service class.User Group SharePoint Example
The Groovy script example below illustrates using the
UserGroup
service to create anUser
object representing User Info. In this example a login name is provided via theloginName
String.import com.avoka.component.sharepoint.SPClient import com.avoka.component.sharepoint.service.UserGroup import com.avoka.component.sharepoint.type.User // Create a SharePoint client using the service parameters map with the configured connection details def spClient = new SPClient(serviceParameters) // Create a UserGroup web service def userGroupService = spClient.getUserGroup() // Get a User object for the given login name def user = userGroupService.getUserInfo(loginName) // Get data from user object def login = user.getLoginName() def name = user.getName() def email = user.getEmail()
- Since:
- 3.5.0
-
-
Constructor Summary
Constructors Constructor Description UserGroup(SPConnection sharePointConnection)
Instantiate the UserGroup Interface wrapper with SharePoint Connection context
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
getServiceName()
Return the web service name.User
getUserInfo(String loginName)
Get information on a specific User.-
Methods inherited from class com.avoka.component.sharepoint.AbstractService
buildAttributeMap, getByteStream, getDocumentElement, getDocumentTagValue, getRequestMessage, getSPConnection, getWsdlUrl, loadProperty, postMessage, postMessage
-
-
-
-
Constructor Detail
-
UserGroup
public UserGroup(SPConnection sharePointConnection)
Instantiate the UserGroup Interface wrapper with SharePoint Connection context- Parameters:
sharePointConnection
- SharePoint connection context
-
-
Method Detail
-
getServiceName
public String getServiceName()
Return the web service name.- Specified by:
getServiceName
in classAbstractService
- Returns:
- the web service name
-
getUserInfo
public User getUserInfo(String loginName) throws SPException
Get information on a specific User.Groovy Example
The Groovy script example below illustrates using the
UserGroup
service to create anUser
object representing User Info. In this example a login name is provided via theloginName
String.import com.avoka.component.sharepoint.SPClient import com.avoka.component.sharepoint.service.UserGroup import com.avoka.component.sharepoint.type.User // Create a SharePoint client using the service parameters map with the configured connection details def spClient = new SPClient(serviceParameters) // Create a UserGroup web service def userGroupService = spClient.getUserGroup() // Get a User object for the given login name def user = userGroupService.getUserInfo(loginName) // Get data from user object def login = user.getLoginName() def name = user.getName() def email = user.getEmail()
Web Service Method
The Microsoft SharePoint Web Service SOAP Method:
http://schemas.microsoft.com/sharepoint/soap/GetUserInfo
- Parameters:
loginName
- User name (DOMAIN\User_Alias) of the user.- Returns:
- User representing the User Info.
- Throws:
SPException
- in case of SharePoint error response
-
-