Update Serialization.java

Changed function name so it would be more appropriate to use it in multiple cases.