この質問への回答 (リンク: How do I convert from int to Long in Java? ) を見て、次を使用して long 値 (newUpdate、lastUpdate) と int 値 (Interval) を比較しました。
if ((newUpdate - lastUpdate) > Long.valueOf(interval))
コンパイルできません。2 つの異なるタイプを比較する正しい方法は何ですか?
より詳しい情報:
[INFO] Trace org.apache.maven.BuildFailureException: Compilation failure [145,51] operator > cannot be applied to long,java.lang.Long
Interval のタイプはint
です。