Setting TimeOut for Web Service Consumers

A question,

I am using Web Service Consumers to fetching some data. In my Javaagent I am trying to set a timeout so if it is a delay and it is taking too long, the agent should stop. Do you have a suggestion to a nice approach to handle this? Does Domino provide tools for timeout for Web Services?

Thank you //K