How to trigger Jira custom event using Jira java API

Hi
our requirement is that we are generating some custom event in our plug-in and want to send mails to some recipient about that event. We want that custom java event to be listed on JIRA UI and want to associate a JIRA notification scheme that will be triggered when this event is published.
Please suggest the solution to meeting this requirement.

Following code, snippets show how we are creating (1) and publishing the event(2).

Any help will be much appreciated .

We want to trigger a custom event notification scheme via Jira java code.

1-Creating a custom java event.
public class CustomEvent extends AbstractEvent {
private Long eventTypeId = 1L;
public void setEventTypeId(Long eventTypeId) {
this.eventTypeId = eventTypeId;
}
public Long getEventTypeId() {
return eventTypeId;
}
}

2- publishing this event.
CustomEvent c = new CustomEvent();
eventPublisher.publish©;