public long idGenerator(){
			long id = 0;
			try {
				connection = Conexao.getInstance().obterConexao();
				connection.setAutoCommit(false);
				statement = connection.createStatement();
		 
				resultSet = statement.executeQuery("SELECT Count(*) numMax FROM TB_ENDERECO");
				resultSet.next();
				id = resultSet.getInt("numMax");
				System.out.println(id);
		 
			} catch (Exception e) {
				// TODO: handle exception
				try {
					if (connection != null && !connection.isClosed()) {
						connection.rollback();
					}
				} catch (SQLException e2) {
					// TODO: handle exception
					e2.printStackTrace();
				} finally{
					try {
						if (resultSet != null) {
							resultSet.close();
						}
						if (statement != null) {
							statement.close();
						}
						if (connection != null) {
							connection.close();
						}
					} catch (Exception e3) {
						// TODO: handle exception
					}
				}
			}
			return id + 1;
		}