[seam-issues] [JBoss JIRA] Resolved: (SEAMCRON-10) Rename CronEvent to improve readability?

Peter Royle (JIRA) jira-events at lists.jboss.org
Sun May 15 22:16:01 EDT 2011


     [ https://issues.jboss.org/browse/SEAMCRON-10?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Peter Royle resolved SEAMCRON-10.
---------------------------------

    Resolution: Done


Renamed CronEvent to Trigger, and now we also use Trigger for @Observes @Every(nth=4, HOUR) Trigger t (instead of using Second, Minute and Hour payloads)

> Rename CronEvent to improve readability?
> ----------------------------------------
>
>                 Key: SEAMCRON-10
>                 URL: https://issues.jboss.org/browse/SEAMCRON-10
>             Project: Seam Cron
>          Issue Type: Task
>            Reporter: Peter Royle
>            Assignee: Peter Royle
>            Priority: Minor
>             Fix For: 3.0.0.Alpha1
>
>
> Originally scheduled observer methods were quite readable, eg:
> public void doStuff(@Observes @Scheduled("10:00") Event e) { ... }
> However, due to possible confusion between cron.Event and javax.Event it became:
> public void doStuff(@Observes @Scheduled("10:00") CronEvent ce) { ... }
> which seems kind of awkward and redundant. Perhaps if we renamed CronEvent to Instant, which doesn't conflict with anything, the readability might be improved like so:
> public void doStuff(@Observes @Scheduled("10:00") Instant i) { ... }
> Also, Instant better represents the nature of the thing being passed in, as nothing has actually happened yet (so it's not much of an event). My main concern is that it's not as memorable as Event.
> Ohter alternatives might be: @Observes @Scheduled("10:00") Moment/Tick/Juncture/Appointment
> ... not sure ...

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the seam-issues mailing list