Please UseCodeTags when posting code. You have been where long enough to know that. You're not changing the value of the Integer. You are reassigning the reference that will point to another Integer with a value of 10. Try making the reference final and than to change the value.
"Any fool can write code that a computer can understand. Good programmers write code that humans can understand." --- Martin Fowler
Please correct my English.