[oneway] void |
dispatch( |
[in] ::com::sun::star::util::URL |
URL, |
| [in] sequence< ::com::sun::star::beans::PropertyValue > |
Arguments ); |
- Description
- dispatches (executes) an URL asynchronously.
It is only allowed to dispatch URLs for which this XDispatch
was explicitely queried. Additional arguments ("'#..." or "?...") are allowed.
- Parameter URL
- fully parsed URL describing the feature which should be dispatched (=executed)
- Parameter Arguments
- optional arguments for this request.
They depend on the real implementation of the dipsatch object.
- Example
// some code for a click-handler (Java)
void myOnClick(String sURL,String sTargetFrame,com.sun.star.beans.PropertyValue[] lArguments)
{
com.sun.star.util.URL[] aURL = new com.sun.star.util.URL[1];
aURL[0] = new com.sun.star.util.URL();
aURL[0].Complete = sURL;
com.sun.star.util.XURLTransformer xParser = (com.sun.star.util.XURLTransformer)UnoRuntime.queryInterface(
com.sun.star.util.XURLTransformer.class,
mxServiceManager.createInstance("com.sun.star.util.URLTransformer"));
xParser.parseStrict(aURL);
com.sun.star.frame.XDispatch xDispatcher = mxFrame.queryDispatch(aURL[0], sTargetFrame, com.sun.star.frame.FrameSearchFlag.GLOBAL);
if(xDispatcher!=null)
xDispatcher.dispatch(aURL[0], lArguments);
}
|