Examples of Room


Examples of hotel.model.Room

  public boolean bookRoom(int orderid, String roomid, int days) {
    Connection conn = null;
    PreparedStatement ps = null;
    ResultSet rs = null;
    String sql = "insert into orderinfo (roomid,orderid,days,action,totalprices) values (?,?,?,?,?)";
    Room room = roomService.getRoom(roomid);
    float totalprices = room.getPrice() * days;
    if (!roomService.bookRoom(roomid)) {
      return false;
    }
    try {
      conn = JdbcUtil.getConnection();
View Full Code Here

Examples of hotel.model.Room

  public boolean directIn(int orderid, String roomid, int days) {
    Connection conn = null;
    PreparedStatement ps = null;
    ResultSet rs = null;
    String sql = "insert into orderinfo (roomid,orderid,days,action,totalprices) values (?,?,?,?,?)";
    Room room = roomService.getRoom(roomid);
    float totalprices = room.getPrice() * days;
    if (!roomService.checkInRoom(roomid)) {
      return false;
    }
    try {
      conn = JdbcUtil.getConnection();
View Full Code Here

Examples of it.freedomotic.environment.Room

    public final void setChanged(boolean value) {
        //update the room that can be reached
        for (EnvironmentLogic env : EnvironmentPersistence.getEnvironments()) {
            for (ZoneLogic z : env.getZones()) {
                if (z instanceof Room) {
                    final Room room = (Room) z;
                    //the gate is opened or closed we update the reachable rooms
                    room.visit();
                }
            }

            for (ZoneLogic z : env.getZones()) {
                if (z instanceof Room) {
                    final Room room = (Room) z;
                    room.updateDescription();
                }
            }
        }

        //then executeCommand the super which notifies the event
View Full Code Here

Examples of it.hotel.model.room.Room

    price2.setCalendarDate(CalendarUtils.GetGregorianCalendar(CalendarUtils.getTomorrowInddMMyyyy()));
    price2.setTypology_id(t1.getId());
    price2.setPrice(new BigDecimal(120));
    expectedPrices1.add(price2);
    t1.setPriceList(expectedPrices1);
    room1 = new Room();
    room1.setTypology(t1);
    Hotel h1 = new Hotel();
    h1.setId(4);
    room1.setStructure(h1);
   
View Full Code Here

Examples of labyrinth.Room

  /**
          * Put the character in another room
          * @param current the room where you want to put him
          */
  public void moveRandom() {
    Room choosen = currentRoom;
    int cpt = 0, maxLight = 0;
   
    // Find the brightest room (i.e. find the player if the monster sees the light).
    for (Room r : accessibleRooms)
    {
View Full Code Here

Examples of net.bytten.metazelda.Room

    public void drawEdges(Graphics2D g, double scale, double roomSize,
            IDungeon dungeon, Room room) {
        g.setColor(Color.BLACK);
       
        for (Edge edge: room.getEdges()) {
            Room nextRoom = dungeon.get(edge.getTargetRoomId());
            Coords coords = room.getCenter(),
                   nextCoords = nextRoom.getCenter();
           
            if (nextRoom.getParent() == room) {
                drawParentEdge(g, scale, roomSize, room, nextRoom);
            }
               
            double x1 = coords.x*scale + roomSize*scale,
                   y1 = coords.y*scale + roomSize*scale,
                   x2 = nextCoords.x*scale + roomSize*scale,
                   y2 = nextCoords.y*scale + roomSize*scale;
            double sdy = Math.signum(y2-y1), sdx = Math.signum(x2-x1);
            y1 += sdy * scale*roomSize/2;
            y2 -= sdy * scale*roomSize/2;
            x1 += sdx * scale*roomSize/2;
            x2 -= sdx * scale*roomSize/2;

            if (nextRoom != null && Symbol.equals(edge.getSymbol(),
                    nextRoom.getEdge(room.id).getSymbol())) {
                // Bidirectional edge
                // avoid drawing twice:
                if (coords.compareTo(nextCoords) > 0) continue;
               
                g.drawLine((int)x1, (int)y1, (int)x2, (int)y2);
View Full Code Here

Examples of net.sf.cannagrower.data.hardware.Room

      repository=new TrueZipRepository(new File(Messages.getMessage(Messages.cultureDemoName)+CannaGrower.extension));
      repository.open();
     
      culture=new Culture(repository);

      culture.getHardwares().store(new Room());
      culture.getHardwares().store(new Lamp());
      culture.getHardwares().store(new Intractor());
      culture.getHardwares().store(new Extractor());
      culture.getHardwares().store(new MediumSoil());
     
View Full Code Here

Examples of org.apache.olingo.odata2.annotation.processor.core.model.Room

    building.setName("Common Building");

    final int roomsCount = 11;
    List<Room> rooms = new ArrayList<Room>();
    for (int i = 0; i < roomsCount; i++) {
      Room room = new Room(i, "Room " + i);
      room.setBuilding(building);
      datasource.createData(roomsEntitySet, room);
      rooms.add(room);
    }

    // execute
    Object relatedData = datasource.readData(roomsEntitySet);

    // validate
    @SuppressWarnings("unchecked")
    Collection<Room> relatedRooms = (Collection<Room>) relatedData;
    Assert.assertEquals(roomsCount, relatedRooms.size());
    for (Room room : relatedRooms) {
      Assert.assertNotNull(room.getId());
      Assert.assertTrue(room.getName().matches("Room \\d*"));
      Assert.assertEquals("Common Building", room.getBuilding().getName());
    }
  }
View Full Code Here

Examples of org.apache.olingo.odata2.annotation.processor.ref.model.Room

    p.setImage(ResourceHelper.generateImage(format));
    return p;
  }

  private static Room createRoom(final String name, final int seats, final int version, final Building building) {
    Room r = new Room();
    r.setName(name);
    r.setSeats(seats);
    r.setVersion(version);
    r.setBuilding(building);

    building.addRoom(r);

    return r;
  }
View Full Code Here

Examples of org.apache.olingo.odata2.ref.model.Room

      employee.setLocation(new Location(null, null, null));
      return employee;
    } else if (ENTITYSET_1_2.equals(entitySet.getName())) {
      return dataContainer.createTeam();
    } else if (ENTITYSET_1_3.equals(entitySet.getName())) {
      Room room = dataContainer.createRoom();
      room.setSeats(0);
      room.setVersion(0);
      return room;
    } else if (ENTITYSET_1_4.equals(entitySet.getName())) {
      Manager manager = dataContainer.createManager();
      manager.setAge(0);
      manager.setLocation(new Location(null, null, null));
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.