Examples of UserService


Examples of org.knopflerfish.cpaexample.service.user.UserService

  public void start(BundleContext bc) throws IOException
  {
    ServiceReference sRef =
      bc.getServiceReference(UserService.class.getName());
    if (sRef != null) {
      UserService us = (UserService) bc.getService(sRef);
      if (us != null) {
        us.login("joek");
      }
      bc.ungetService(sRef);
    }
  }
View Full Code Here

Examples of org.knopflerfish.cpaexample.service.user.UserService

  public void stop(BundleContext bc) throws IOException
  {
    ServiceReference sRef =
      bc.getServiceReference(UserService.class.getName());
    if (sRef != null) {
      UserService us = (UserService) bc.getService(sRef);
      if (us != null) {
        us.logout();
      }
      bc.ungetService(sRef);
    }
  }
View Full Code Here

Examples of org.openmeetings.app.remote.UserService

  }
 
  public void testUsers(){
   
    MainService mService = new MainService();
    UserService uService = new UserService();
    Sessiondata sessionData = mService.getsessiondata();
   
    Users us = (Users) mService.loginUser(sessionData.getSession_id(), "swagner", "test",false,null,-1L);
   
    SearchResult users = uService.getUserList(sessionData.getSession_id(), 0, 100, "firstname", false);
   
    log.error("Number of Users 1: "+users.getResult().size());
    log.error("Number of Users 2: "+users.getRecords());
   
    Users users2 = (Users) users.getResult().get(5);
View Full Code Here

Examples of org.springframework.integration.samples.enricher.service.UserService

    context.registerShutdownHook();

    final Scanner scanner = new Scanner(System.in);

    final UserService service = context.getBean(UserService.class);

    LOGGER.info(LINE_SEPARATOR
          + EMPTY_LINE
          + "\n    Please press 'q + Enter' to quit the application.                     "
          + EMPTY_LINE
          + LINE_SEPARATOR
          + EMPTY_LINE
          + "\n    This example illustrates the usage of the Content Enricher.           "
          + EMPTY_LINE
          + "\n    Usage: Please enter 1 or 2 or 3 + Enter                               "
          + EMPTY_LINE
          + "\n    3 different message flows are triggered. For sample 1+2 a             "
          + "\n    user object containing only the username is passed in.                "
          + "\n    For sample 3 a Map with the 'username' key is passed in and enriched  "
          + "\n    with the user object using the 'user' key.                            "
          + EMPTY_LINE
          + "\n    1: In the Enricher, pass the full User object to the request channel. "
          + "\n    2: In the Enricher, pass only the username to the request channel.    "
          + "\n    3: In the Enricher, pass only the username to the request channel.    "
          + EMPTY_LINE
          + LINE_SEPARATOR);

    while (!scanner.hasNext("q")) {

      final String input = scanner.nextLine();

      User user = new User("foo", null, null);

      if ("1".equals(input)) {

        final User fullUser = service.findUser(user);
        printUserInformation(fullUser);

      } else if ("2".equals(input)) {

        final User fullUser = service.findUserByUsername(user);
        printUserInformation(fullUser);

      } else if ("3".equals(input)) {

        final Map<String, Object> userData = new HashMap<String, Object>();
        userData.put("username", "foo_map");

        final Map<String, Object> enrichedUserData = service.findUserWithUsernameInMap(userData);

        final User fullUser = (User) enrichedUserData.get("user");

        printUserInformation(fullUser);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.