这个问题在这里已经有了答案:IteratingthroughaCollection,avoidingConcurrentModificationExceptionwhenremovingobjectsinaloop(30个回答)关闭7年前。我有以下代码:privateStringtoString(ListaDrugStrengthList){StringBuilderstr=newStringBuilder();for(DrugStrengthaDrugStrength:aDrugStrengthList){if(!aDrugStrength.isValidDrugDescriptio
这个问题在这里已经有了答案:IteratingthroughaCollection,avoidingConcurrentModificationExceptionwhenremovingobjectsinaloop(30个回答)关闭7年前。我有以下代码:privateStringtoString(ListaDrugStrengthList){StringBuilderstr=newStringBuilder();for(DrugStrengthaDrugStrength:aDrugStrengthList){if(!aDrugStrength.isValidDrugDescriptio