Examples of UserProfile


Examples of cn.edu.zju.acm.onlinejudge.bean.UserProfile

     * @return the UserProfile instance
     * @throws SQLException
     *             if any error occurs
     */
    private UserProfile populateUserProfile(ResultSet rs) throws SQLException {
        UserProfile profile = new UserProfile();

        profile.setId(rs.getLong(DatabaseConstants.USER_PROFILE_USER_PROFILE_ID));
        profile.setHandle(rs.getString(DatabaseConstants.USER_PROFILE_HANDLE));
        profile.setPassword(rs.getString(DatabaseConstants.USER_PROFILE_PASSWORD));
        profile.setEmail(rs.getString(DatabaseConstants.USER_PROFILE_EMAIL_ADDRESS));
        profile.setRegDate(rs.getTimestamp(DatabaseConstants.USER_PROFILE_REG_DATE));
        profile.setFirstName(rs.getString(DatabaseConstants.USER_PROFILE_FIRST_NAME));
        profile.setLastName(rs.getString(DatabaseConstants.USER_PROFILE_LAST_NAME));
        profile.setAddressLine1(rs.getString(DatabaseConstants.USER_PROFILE_ADDRESS_LINE1));
        profile.setAddressLine2(rs.getString(DatabaseConstants.USER_PROFILE_ADDRESS_LINE2));
        profile.setCity(rs.getString(DatabaseConstants.USER_PROFILE_CITY));
        profile.setState(rs.getString(DatabaseConstants.USER_PROFILE_STATE));
        profile.setCountry(new Country(rs.getLong(DatabaseConstants.USER_PROFILE_COUNTRY_ID), "foo"));
        profile.setZipCode(rs.getString(DatabaseConstants.USER_PROFILE_ZIP_CODE));
        profile.setPhoneNumber(rs.getString(DatabaseConstants.USER_PROFILE_PHONE_NUMBER));
        profile.setBirthDate(rs.getDate(DatabaseConstants.USER_PROFILE_BIRTH_DATE));
        String gender = rs.getString(DatabaseConstants.USER_PROFILE_GENDER);
        profile.setGender(gender == null || gender.length() == 0 ? ' ' : gender.charAt(0));
        profile.setSchool(rs.getString(DatabaseConstants.USER_PROFILE_SCHOOL));
        profile.setMajor(rs.getString(DatabaseConstants.USER_PROFILE_MAJOR));
        profile.setGraduateStudent(rs.getBoolean(DatabaseConstants.USER_PROFILE_GRADUATE_STUDENT));
        profile.setGraduationYear(rs.getInt(DatabaseConstants.USER_PROFILE_GRADUATION_YEAR));
        profile.setStudentNumber(rs.getString(DatabaseConstants.USER_PROFILE_STUDENT_NUMBER));
        profile.setConfirmed(rs.getBoolean(DatabaseConstants.USER_PROFILE_CONFIRMED));
        profile.setActive(rs.getBoolean(DatabaseConstants.USER_PROFILE_ACTIVE));
        profile.setNickName(rs.getString("nickname"));
        profile.setOldEmail(rs.getString("old_email"));
        return profile;
    }
View Full Code Here

Examples of com.atlassian.jira.functest.framework.UserProfile

  private void setUserLanguageToEnUk() {
    changeUserLanguageByValueOrName("en_UK", "angielski (UK)");
  }
 
  private void changeUserLanguageByValueOrName(String value, String name) {
    final UserProfile userProfile = navigation.userProfile();
    boolean fallbackToChangeByValue = false;
    try {
      Method changeUserLanguageByValue = userProfile.getClass().getMethod("changeUserLanguageByValue", String.class);
      changeUserLanguageByValue.invoke(userProfile, value);
    } catch (NoSuchMethodException e) {
      // fallbackToChangeByValue to value - for JIRA < 5.1
      fallbackToChangeByValue = true;
    } catch (InvocationTargetException e) {
      fallbackToChangeByValue = true;
    } catch (IllegalAccessException e) {
      fallbackToChangeByValue = true;
    }

    if (fallbackToChangeByValue) {
      userProfile.changeUserLanguage(name);
    }
  }
View Full Code Here

Examples of com.atlassian.sal.api.user.UserProfile

    public ReceivePack create(HttpServletRequest req, Repository repo) throws ServiceNotEnabledException, ServiceNotAuthorizedException
    {
        String user = userManager.getRemoteUsername(req);
        String pluginKey = repo.getWorkTree().getName();
        UserProfile userProfile = userManager.getUserProfile(user);

        final UserExtension userExtension = speakeasyService.getRemotePlugin(pluginKey, user);
        if (userExtension != null && !userExtension.isCanEdit())
        {
            throw new ServiceNotAuthorizedException();
View Full Code Here

Examples of com.ecyrd.jspwiki.auth.user.UserProfile

    }

    public void testResolveUsers() throws WikiException
    {
        // We should be able to resolve a user by login, user, or wiki name
        UserProfile profile = m_engine.getUserManager().getUserDatabase().newProfile();
        profile.setEmail( "authmanagertest@tester.net" );
        profile.setFullname( "AuthorizationManagerTest User" );
        profile.setLoginName( "authmanagertest" );
        try
        {
            m_engine.getUserManager().getUserDatabase().save( profile );
        }
        catch( WikiSecurityException e )
View Full Code Here

Examples of com.foxconn.gds.security.model.UserProfile

  @Test
  public void testCreateUserAccount() {
    try {
      IUserAccountServices accMgr = UserAccountServices.getInstance();
      UserAccount acc;
      UserProfile pfl;
      String accId;
      for (int i = 0; i < 500; i++) {
        pfl = new UserProfile(
            ("eId-" + i), //unique
            ("name-" + i),
            ("name-" + i+ "@foxconn.com"),
            ("861350000" + i)
        );
View Full Code Here

Examples of com.gadglet.data.UserProfile

        record.setGadgetPermissions(isEditor, isOwner, isOwner);

        if (!isOwner) {
          // send info about the owner
          UserProfile owner = UserProfilesUtils.getProfileById(item
              .getOwnerId());

          if (owner != null && !owner.isPrivate()) {
            if (owner.getNickName() != null)
              record.addItemField(ProfileFields.PROFILE_NICKNAME
                  .getParamName(), owner.getNickName());
            if (owner.getPhotoUrl() != null
                && owner.getPhotoUrl().length() > 0)
              record.addItemField(
                  ProfileFields.PROFILE_THUMBNAILURL
                      .getParamName(), owner
                      .getPhotoUrl());

          }

        }
View Full Code Here

Examples of com.google.api.ads.dfa.axis.v1_19.UserProfile

    // Request the login service from the service client factory.
    LoginRemote loginService = dfaServices.get(session, LoginRemote.class);

    // Authenticate.
    UserProfile userProfile = loginService.authenticate(username, password);

    // Display user profile token, DFA account name and ID.
    System.out.printf("User profile token is \"%s\", DFA account name is \"%s\", and DFA " +
        "account ID is \"%s\".%n", userProfile.getToken(), userProfile.getNetworkName(),
        userProfile.getNetworkId());
  }
View Full Code Here

Examples of com.google.api.ads.dfa.axis.v1_20.UserProfile

    // Request the login service from the service client factory.
    LoginRemote loginService = dfaServices.get(session, LoginRemote.class);

    // Authenticate.
    UserProfile userProfile = loginService.authenticate(username, password);

    // Display user profile token, DFA account name and ID.
    System.out.printf("User profile token is \"%s\", DFA account name is \"%s\", and DFA " +
        "account ID is \"%s\".%n", userProfile.getToken(), userProfile.getNetworkName(),
        userProfile.getNetworkId());
  }
View Full Code Here

Examples of com.impetus.client.oraclenosql.entities.UserProfile

    public void executeLOBTest()
    {
        // Save Record
        File file = new File("src/test/resources/nature.jpg");
        long fileSize = file.getTotalSpace();
        UserProfile userProfile = new UserProfile(1, "Amresh", file);
        persist(userProfile);

        // Find Record
        clearEm();
        UserProfile up = (UserProfile) find(UserProfile.class, 1);
        Assert.assertNotNull(up);
        Assert.assertEquals(1, up.getUserId());
        Assert.assertEquals("Amresh", up.getUserName());
        Assert.assertEquals(fileSize, up.getProfilePicture().getTotalSpace());

        // Delete Record
        clearEm();
        delete(up);
        Assert.assertNull(find(UserProfile.class, 1));
View Full Code Here

Examples of de.fhdw.ify208.ticketmaster.webapp.model.UserProfile

        boolean bIsRegistered = false;

        try {

            UserProfile profile = getNewUser();

            if (!profile.getChangePin().getNewPin().equals(profile.getChangePin().getRetryPin())) {

                bIsRegistered = false;

                msg = new FacesMessage(FacesMessage.SEVERITY_ERROR, "Password mismatch",
                        "Please make sure that your re-type your pin correctly!");
            } else {

                profile.getProfileData().setPassword(profile.getChangePin().getNewPin());

                CustomerDTO _customerDTO = _customerWebService.getCustomerServiceImplPort().registerCustomer(
                        profile.getProfileData());

                if (_customerDTO.getReturncode() == 0) {

                    bIsRegistered = true;

                    AddressDTO defaultAdr =_customerWebService.getCustomerServiceImplPort().maintainAddress(_customerDTO, profile.getBillingAddress());

                    if (defaultAdr.getReturncode() != 0) {
                   
                        msg = new FacesMessage(FacesMessage.SEVERITY_WARN, "Profile Data missing",
                                        "Could not store your billing address. Please check the data!");
                       
                        SystemController.redirectUrl(ctx, "userprofile");
                    }
                   
                    defaultAdr = _customerWebService.getCustomerServiceImplPort().maintainAddress(_customerDTO, profile.getShippingAddress());

                    if (defaultAdr.getReturncode() != 0) {

                        msg = new FacesMessage(FacesMessage.SEVERITY_WARN, "Profile Data missing",
                                "Could not store your shipping address. Please check the data!");
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.