0
私は開発者としての初期段階にあり、以下のコードのフィールドの二重割り当てを示すソナーエラーを解決する助けが必要です。ソナーの正しさにエラーが発生しました - フィールドの二重割り当て
//Inside constructor
list1 = new ArrayList();
....
...
// in some method
if(description.equalsIgnoreCase(MAPPED_CATIA_MODELS)) {
tempList = new ArrayList();
tempList = list1 ; // gives error here as "Correctness - Double assignment of field."
addKey = true;
}
変更する必要があることをご提案ください。おかげさまで
入手しました。答えをありがとう。 List tempList = list1として作成します。上記の行を削除します。 – user1374266