Google App Engine requires me to make objects serializable before I can use it as a session bean. Now I have a Product class, I made this Product class serializable, but one of its const开发者_开发技巧ructors and some setters have checked exceptions, these checked exceptions are custom exceptions. My question is: should I serialize these custom exception classes?
If the Exceptions are not a field of your class, there is no need to make them serializable because they won´t be stored. By default Exception are serializable anyway
精彩评论