Update MethodElement.java

Test for serialization.