win32utils-devel@rubyforge.org
2004-Apr-02 21:57 UTC
[Win32utils-devel] Futzing with TaskScheduler
Hi all, Thought I should say something - it''s been a little while. :) Anyway, I''m still futzing with how I want the Ruby API to look. The more I look at the Perl version, the more I think it was too faithful to the C API. Right now I''m looking at the trigger() method. For example, I don''t see any reason to make the "type" key take a hash as an argument (thus creating a nested hash) when none of the keys are duplicate. We should just DTRT (do the right thing). Also, I mostly dislike camel case and I''m not sure what logic MS used when it chose "BeginX" versus "StartX". I''m just going to use "start". So for now I''m looking at something like this: t = Trigger.new(task_name,some_host) t.trigger = { :start_year => 2004 :start_month => 4 :start_day => 25 :start_hour => 23 :start_minute => 5 :trigger_type => DAILY :week => FIRST | LAST :dow => MONDAY | TUESDAY | WEDNESDAY :months => JANUARY | FEBRUARY | MARCH } How''s that look? Dan _________________________________________________________________ MSN Toolbar provides one-click access to Hotmail from any Web page – FREE download! http://toolbar.msn.com/go/onm00200413ave/direct/01/
win32utils-devel@rubyforge.org
2004-Apr-02 22:47 UTC
[Win32utils-devel] Futzing with TaskScheduler
Hi,> Hi all, > > Thought I should say something - it''s been a little while. :) > > Anyway, I''m still futzing with how I want the Ruby API to look. The moreI> look at the Perl version, the more I think it was too faithful to the CAPI.> Right now I''m looking at the trigger() method. For example, I don''t see > any reason to make the "type" key take a hash as an argument (thuscreating> a nested hash) when none of the keys are duplicate. We should just DTRT(do> the right thing). > > Also, I mostly dislike camel case and I''m not sure what logic MS used when > it chose "BeginX" versus "StartX". I''m just going to use "start". So for > now I''m looking at something like this: > > t = Trigger.new(task_name,some_host) > t.trigger = { > :start_year => 2004 > :start_month => 4 > :start_day => 25 > :start_hour => 23 > :start_minute => 5 > :trigger_type => DAILY > :week => FIRST | LAST > :dow => MONDAY | TUESDAY | WEDNESDAY > :months => JANUARY | FEBRUARY | MARCH > } > > How''s that look?I fully agree with you. I think the taskscheduler C API is too complicated and inconsistent in naming. Go ahead as you want. Cheers, Park Heesob
win32utils-devel@rubyforge.org
2004-Apr-02 23:55 UTC
[Win32utils-devel] Futzing with TaskScheduler
I agree ! Go right ahead ... ----- Original Message ----- From: <win32utils-devel@rubyforge.org> To: <win32utils-devel@rubyforge.org> Sent: Friday, April 02, 2004 9:27 PM Subject: Re: [Win32utils-devel] Futzing with TaskScheduler> Hi, > > > > Hi all, > > > > Thought I should say something - it''s been a little while. :) > > > > Anyway, I''m still futzing with how I want the Ruby API to look. Themore> I > > look at the Perl version, the more I think it was too faithful to the C > API. > > Right now I''m looking at the trigger() method. For example, I don''tsee> > any reason to make the "type" key take a hash as an argument (thus > creating > > a nested hash) when none of the keys are duplicate. We should just DTRT > (do > > the right thing). > > > > Also, I mostly dislike camel case and I''m not sure what logic MS usedwhen> > it chose "BeginX" versus "StartX". I''m just going to use "start". Sofor> > now I''m looking at something like this: > > > > t = Trigger.new(task_name,some_host) > > t.trigger = { > > :start_year => 2004 > > :start_month => 4 > > :start_day => 25 > > :start_hour => 23 > > :start_minute => 5 > > :trigger_type => DAILY > > :week => FIRST | LAST > > :dow => MONDAY | TUESDAY | WEDNESDAY > > :months => JANUARY | FEBRUARY | MARCH > > } > > > > How''s that look? > > I fully agree with you. > > I think the taskscheduler C API is too complicated and inconsistent in > naming. > > Go ahead as you want. > > Cheers, > > Park Heesob > > > _______________________________________________ > win32utils-devel mailing list > win32utils-devel@rubyforge.org > http://rubyforge.org/mailman/listinfo/win32utils-devel