Package com.google.enterprise.connector.sharepoint.generated.userprofileservice

Examples of com.google.enterprise.connector.sharepoint.generated.userprofileservice.GetUserProfileByIndexResult


  public void setTimeout(final int timeout) {
  }

  @Override
  public GetUserProfileByIndexResult getUserProfileByIndex(int index) {
    return new GetUserProfileByIndexResult();
  }
View Full Code Here


    final boolean[] isSPS = new boolean[1];
    Util.makeWSRequest(sharepointClientContext, userProfileWS,
        new Util.RequestExecutor<GetUserProfileByIndexResult>() {
      public GetUserProfileByIndexResult onRequest(final BaseWS ws)
          throws Throwable {
        GetUserProfileByIndexResult result =
            ((UserProfile2007WS) ws).getUserProfileByIndex(0);
        isSPS[0] = true;
        return result;
      }
     
View Full Code Here

    // getting next profile and so on]
    // [End Loop]

    int index = 0;
    while (index >= 0) {
      final GetUserProfileByIndexResult result = getUserProfileByIndex(index);

      if ((result == null) || (result.getUserProfile() == null)) {
        break;
      }

      final PropertyData[] data = result.getUserProfile();
      if (data == null) {
        break;
      }

      String space = null;
      for (PropertyData element : data) {
        try {
          final String name = element.getName();
          if (collator.equals(personalSpaceTag, name)) {
            final ValueData[] vd = element.getValues();
            if ((vd == null) || (vd.length < 1)) {
              continue;
            }
            space = (String) vd[0].getValue();
            String strMySiteBaseURL = sharepointClientContext.getMySiteBaseURL();
            if (strMySiteBaseURL.endsWith(SPConstants.SLASH)) {
              strMySiteBaseURL = strMySiteBaseURL.substring(0, strMySiteBaseURL.lastIndexOf(SPConstants.SLASH));
            }
            String strURL = strMySiteBaseURL + space;
            if (strURL.endsWith(SPConstants.SLASH)) {
              strURL = strURL.substring(0, strURL.lastIndexOf(SPConstants.SLASH));
            }
            if (sharepointClientContext.isIncludedUrl(strURL, LOGGER)) {
              lstAllPersonalSites.add(strURL);
              LOGGER.log(Level.CONFIG, "Personal Site: " + strURL);
            }
          }
        } catch (final Exception e) {
          LOGGER.log(Level.WARNING, e.getMessage(), e);
          continue;
        }
      }
      final String next = result.getNextValue();
      index = Integer.parseInt(next);
    }

    if (lstAllPersonalSites.size() > 0) {
      LOGGER.info("Discovered " + lstAllPersonalSites.size()
View Full Code Here

   */
  public Set<String> getMyLinks() throws SharepointException {
    final Set<String> myLinksSet = new TreeSet<String>();
    int index = 0;
    while (index >= 0) {
      final GetUserProfileByIndexResult result = getUserProfileByIndex(index);

      if ((result == null) || (result.getUserProfile() == null)) {
        break;
      }

      final QuickLinkData[] links = result.getQuickLinks();

      if (links == null) {
        break;
      }
      String url = null;

      for (QuickLinkData element : links) {
        url = element.getUrl();
        if (sharepointClientContext.isIncludedUrl(url, LOGGER)) {
          myLinksSet.add(url);
        }
      }

      final String next = result.getNextValue();
      index = Integer.parseInt(next);
    }

    if (myLinksSet.size() > 0) {
      LOGGER.info(myLinksSet.size() + " MyLinks found.");
View Full Code Here

TOP

Related Classes of com.google.enterprise.connector.sharepoint.generated.userprofileservice.GetUserProfileByIndexResult

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.