How to get events(actions) menubar in libreoffice?

i have sample extension, i will get events menubar in main libreoffice when select that, for example event copy when click “copy” from menubar or event “copy” from right click.
how to get this events?
sample Extension:

Object xGlobalBroadCaster = m_xCmpCtx.getServiceManager().createInstanceWithContext(
“”, m_xCmpCtx);

XEventBroadcaster xEventBroad = (XEventBroadcaster)UnoRuntime.queryInterface(XEventBroadcaster.class,

synchronized (xEventBroad) {xEventBroad.addEventListener(new XEventListener() {
public void notifyEvent(EventObject oEvent) {
System.out.println("Event: " + oEvent.EventName);
public void disposing( e) {

i can not resive event copy or paste from menubar.
how to get this events menubar?

Where did you find this sample extension? More details and clarity are needed. Perhaps show example code as well. See my suggested guidelines for asking.

I withdrew my answer simply because each time I read the question I can interpret it differently. Jim K is correct in that you need to be more specific on what you are looking for.