Решил задачу но непонятно, что мы указываем в скобках [...]? return Thread.currentThread().getStackTrace()[2].getLineNumber();