Send xml file as a parameter to a session bean
I am required to send a xml file as a method paramet开发者_高级运维er to a bean with a remote interface. Which is the best way to do it?
Thanks
It really depends on how big the xml file will be. If you expect small xml files, just send the content of an xml file as string. If you want to preserve other file info like modification date etc create serializable POJO which will hold all the information regarding the file. If you expect large xmls, I would prefere to store the xml file somwhere on the network and just send as a parameter, the info on how to get the file (its location).
精彩评论