Re: DiskDevice API 2.2 remarks

"Ingo Weinhold" <bonefish-CFLBMwTPW48UNGrzBIF7/[email protected]>
Newsgroups gmane.os.openbeos.storage
Message-ID <6953081122-BeMail@graete>
Tyler Dauwalder <tyler-cyCl/[email protected]> wrote:
> On 2003-04-08 at 14:18:24 [-0700], Ingo Weinhold wrote:
[...]
> > IIRC, I
> > already proposed to add a B_DEVICE_JOB_PROGRESS notification 
> > "event"
> > field value and a respective event mask flag (can't find the mail -
> > -
> > maybe I was just dreaming).
> 
> I think you're thinking of your suggestion of 
> BDiskDeviceJob::Status() 
> and it's various codes, but maybe not.

Damn, there was a time when I was younger and didn't have these 
hallucinations. ;-)

> Either way, yes that's worth 
> adding.

Fine.

> > A B_DEVICE_JOB_DETAILED_PROGRESS plus 
> > event
> > mask flag could be added, too. 
> 
> Okay, that seems reasonable. And we can always get rid of it if it 
> ends up being overkill.

Agreed.

> > Moreover I start to feel, that a
> > BDiskDeviceRoster::StartWatching(BDiskDeviceJob*,...) version might
> > make sense. What do you think?
> 
> That's probably how we'd want to instigate watching for the 
> progressMessenger supplied to the job initiation functions anyway, so 
> why not? :-) How about StartWatchingJob() instead, though (since it's 
> more specific in function)? 

Sounds good.

> So how about these masks (different names, are they okay?):
> 
> B_DEVICE_REQUEST_JOB_SIMPLE_PROGRESS	= 0x0040, 	
>    // simple job progress (i.e. "% complete" only)
> B_DEVICE_REQUEST_JOB_EXTRA_PROGRESS		= 0x0080, 	
>    // extra info on job progress (no "% complete" info)
> B_DEVICE_REQUEST_JOB_COMPLETE_PROGRESS	= 0x00C0, 	
>    // complete job progress info
> 
> I have the first two mutually exclusive because I figured we'd need 
> to 
> have that split somewhere in the implementation anyway. And then:
> 
> status_t BDiskDeviceRoster::StartWatchingJob(BDiskDeviceJob *job, 
> BMessenger target, uint32 eventMask = 
> B_DEVICE_REQUEST_JOB_COMPLETE_PROGRESS);

Sounds good, too.

CU, Ingo
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.