How to develop webservice plugin

Hello,EveryBody:

                 I want to put a webservice to a openfire plugin,but i don't know how to do it .If you known,please tell me and give me an example !!

                Any advice much appreciated. thanks!