Skip to Content
0
Jan 20, 2017 at 01:15 PM

getting java.lang.UnsupportedOperationException while updating the existed values

107 Views

I have one item type, which has list of another items. I want to update the list of items in that item type, but getting the above error.

E.g

I have College Item Type -- which have List of Student Item Types.

While updating the College item type, i want to add new Student type to the existed list of Student types. But facing java.lang.UnsupportedOperationException.

college.getStudents().add(newStudent); -- This line giving error.

Any help will be appreciated. Thanks