Examples of Guest


Examples of org.fluxtream.core.domain.Guest

  }

    @RequestMapping(value = "/checkIn")
    public ModelAndView checkIn(HttpServletRequest request,
                                HttpServletResponse response) throws IOException, NoSuchAlgorithmException, URISyntaxException {
        final Guest guest = AuthHelper.getGuest();
        if (!hasTimezoneCookie(request)|| guest ==null)
            return new ModelAndView("redirect:/welcome");
        long guestId = guest.getId();
        checkIn(request, guestId);
        final HttpSessionRequestCache requestCache = new HttpSessionRequestCache();
        SavedRequest savedRequest =
                requestCache.getRequest(request, response);
        if (savedRequest!=null) {
View Full Code Here

Examples of org.gtugs.domain.Guest

  }

  @Override
  protected void onBind(HttpServletRequest request, Object command) throws
      Exception {
    Guest guest = (Guest) command;
    guest.setCachedLocation(guest.getLocation());
  }
View Full Code Here

Examples of org.gtugs.domain.Guest

    guest.setCachedLocation(guest.getLocation());
  }

  @Override
  public ModelAndView onSubmit(Object command) throws ServletException {
    Guest guest = (Guest) command;

    guestManager.storeGuest(guest);
    locationManager.incrementOrStoreLocation(guest.getLatitude(),
        guest.getLongitude());

    //return new ModelAndView(
        //new RedirectView("/signUp.jsp?cc=" + guest.getCountry()));
    return new ModelAndView(new RedirectView("/signUp.jsp"));
  }
View Full Code Here

Examples of org.gtugs.domain.Guest

  public boolean supports(Class c) {
    return Guest.class.equals(c);
  }

  public void validate(Object obj, Errors errors) {
    Guest guest = (Guest) obj;
    boolean locationErrors = false;

    if (guest == null) {
      errors.rejectValue("name", "error.name-required", null, "Required");
    }
    else {
      if (guest.getName() == null || guest.getName().equals("")) {
        errors.rejectValue("name", "error.name-required", null, "Required");
      }
      if (guest.getEmail() == null || guest.getEmail().equals("")) {
        errors.rejectValue("email", "error.email-required", null, "Required");
      } else if (!isValidEmail(guest.getEmail())) {
        errors.rejectValue("email", "error.invalid-email", null, "Invalid");
      }
      if (guest.getLocation() == null || guest.getLocation().equals("")) {
        errors.rejectValue("location", "error.location-required", null, "Required");
        locationErrors = true;
      }
      if (guest.getInterest() == null || guest.getInterest().equals("")) {
        errors.rejectValue("interest", "error.interest-required", null, "Required");
      }

      if (!locationErrors) {
        Point point = mapsService.getCoordinates(guest.getLocation(),
            guest.getCountry());
        if (point == null) {
          errors.rejectValue("location", "error.geocoding-failed", null, "Geocoding failed");
          errors.rejectValue("country", "error.geocoding-failed", null, "Geocoding failed");
        } else {
          guest.setLatitude(point.getLatitude());
          guest.setLongitude(point.getLongitude());
        }
      }
    }
  }
View Full Code Here

Examples of org.optaplanner.examples.dinnerparty.domain.Guest

        }

    }

    private ImageIcon determineGuestIcon(SeatDesignation seatDesignation) {
        Guest guest = seatDesignation.getGuest();
        if (guest == null) {
            return null;
        }
        List<ImageIcon> imageIconList = guest.getGender() == Gender.MALE ? maleImageIconList : femaleImageIconList;
        return imageIconList.get(guest.getId().intValue() % imageIconList.size());
    }
View Full Code Here

Examples of us.jyg.freshet.dao.model.Guest

  public void setBrowseGenresDisplay(FreshetForm ff, User user) {
    log.debug("entering setBrowseGenresDisplay");
    ff.setBrowseItems(new ArrayList<SongAttribute>(genreManager.getGenres()));
    ff.setBrowseType(""+Constants.BROWSE_GENRES);
    ff.setNextBrowseType(""+Constants.BROWSE_GENRE);
        ff.setUser((user==null)?new Guest():user);
        log.debug("exiting setBrowseGenresDisplay");
    }
View Full Code Here

Examples of us.jyg.freshet.dao.model.Guest

    log.debug("entering setBrowseGenreDisplay");
    Integer genreId = new Integer(ff.getBrowseId());
    ff.setBrowseItems(new ArrayList<SongAttribute>(artistManager.getArtistsbyGenre(genreId)));
    ff.setBrowseGenre(genreManager.getGenre(genreId));
    ff.setBrowseType(Constants.BROWSE_GENRE);
        ff.setUser((user==null)?new Guest():user);
        ff.setNextBrowseType(Constants.BROWSE_ARTIST);
  }
View Full Code Here

Examples of us.jyg.freshet.dao.model.Guest

 
  public void setBrowseArtistsDisplay(FreshetForm ff, User user) {
    log.debug("entering setBrowseArtistsDisplay");
    ff.setBrowseItems(new ArrayList<SongAttribute>(artistManager.getArtists()));
    ff.setBrowseType(Constants.BROWSE_ARTISTS);
        ff.setUser((user==null)?new Guest():user);
        ff.setNextBrowseType(Constants.BROWSE_ARTIST);
  }
View Full Code Here

Examples of us.jyg.freshet.dao.model.Guest

    ff.setBrowseArtist(artistManager.getArtist(artistId));
    Song song0 = (Song)songManager.getSongs(ff.getBrowseArtist()).get(0);
    ff.setBrowseGenre(song0.getGenre());
    ff.setBrowseItems(new ArrayList<SongAttribute>(albumManager.getAlbumsbyArtist(artistId)));
    ff.setBrowseType(Constants.BROWSE_ARTIST);
        ff.setUser((user==null)?new Guest():user);
        ff.setNextBrowseType(Constants.BROWSE_ALBUM);
  }
View Full Code Here

Examples of us.jyg.freshet.dao.model.Guest

    ff.setBrowseItems(songManager.getSongs(ff.getBrowseAlbum()));
    Song song0 = (Song)ff.getBrowseItems().get(0);
    ff.setBrowseGenre(song0.getGenre());
    ff.setBrowseArtist(song0.getArtist());
    ff.setBrowseType(Constants.BROWSE_ALBUM);
        ff.setUser((user==null)?new Guest():user);
        ff.setNextBrowseType(Constants.BROWSE_SONG);
  }
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.