Page 900 - 3-2
P. 900

case 1:dete=Integer.parseInt(det); break;
                                                            case 2:dete2=Integer.parseInt(det); break;
                                                            case 3:dete3=Integer.parseInt(det); break;
                                                    }
                                                    if(fire.equals("0"))
                                                            textArea3.setBackground(Color.green);
                                                    else textArea3.setBackground(Color.red);
                                                    if(ServerMain.cnt_s - ServerMain.cnt >=
                                                                                    Integer.parseInt(det))
                                                      textArea3.setBackground(new Color(192,192,192));


                                                    textArea3.setText(" 안방\n" + "\nspark = " +
                                                              spark + "\ngas = "+ gas +
                                                              "\ntemp = "+ temp + "\nfire = "+fire);
                                                    }break;
                                            }
                                    }
                                    stmt.close();
                                    conn.close();
                            }catch(SQLException se1){
                                    se1.printStackTrace();
                            }catch(Exception ex){
                                    ex.printStackTrace();
                            }finally{
                                    try{
                                            if(stmt!=null)
                                                    stmt.close();
                                    }catch(SQLException se2){
                                    }
                                    try{
                                            if(conn!=null)
                                                    conn.close();
                                    }catch(SQLException se){
                                            se.printStackTrace();
                                    }
                            }
                    }}




            /*
             *  클래스: Sedong
             *  생성자: Sedong()
             *  생성된 감지기의 상태들을 메인 서버에서 한눈에 볼 수 있게 함
             */




                                                         - 900 -
   895   896   897   898   899   900   901   902   903   904   905