You create an application from Microsoft Office SharePoint 2007 Server. You need to write code that retrieves all users for an audience named Audience1.
Which code segment should you use?
A.
Private audienceManager as AudienceManager = new AudienceManager() Private audiences as AudienceCollection = audienceManager.Audiences Private audience1 as Audience = audiences(“Audience1”)
B.
Private audienceManager as AudienceManager = new AudienceManager() Private membershipList as arrayList = audienceManager.Audiences(“Audience1”).GetMembership()
C.
Private audienceManager as AudienceManager = new AudienceManager() Private audience1 as AudienceCollection = audienceManager.Audiences
D.
Private site as SPSite = new SPSite(“http://servername/site/site1”) Private context as ServerContext = ServerContext.GetContext(“site”) Private audienceManager as AudienceManager = new AudienceManager(context) Private web as SPWeb = site.AllWebs(0)
Private audienceIDName as arrayList = audienceManager.GetUserAudienceIDs(“Audience1”, true, web)