Go to the FreeLists Home Page Home Signup Help Login
 



[openbeosstorage] || [Date Prev] [07-2003 Date Index] [Date Next] || [Thread Prev] [07-2003 Thread Index] [Thread Next]

[openbeosstorage] Re: Disk Device API: Some semantical questions

  • From: Tyler Dauwalder <tyler@xxxxxxxxxxxxx>
  • To: openbeosstorage@xxxxxxxxxxxxx
  • Date: Fri, 11 Jul 2003 01:04:21 -0700
On 2003-07-10 at 20:27:31 [-0700], Ingo Weinhold wrote:
> On Thu, 10 Jul 2003 14:08:18 -0700 Tyler Dauwalder 
> <tyler@xxxxxxxxxxxxx
> > wrote:
> [...]
> > > BTW, what kind of partitions does
> > > BDiskDeviceRoster::VisitEachInitializablePartition() visit, i.e.
> > > what
> > > is an initializable partition? Something like the device is not
> > > read-
> > > only and there exists a disk system for which the partition's
> > > CanInitialize() would return true? Sounds a bit complicated.
> > 
> > I think something more along the lines of "the device is not read-
> > only
> > and partition->Parent()->DiskSystem()->SupportsChildSystem() returns
> > true for some available disk system and there exists an available
> > disk
> > system such that
> > system->SupportsParentSystem(partition->Parent()->DiskSystem())
> > returns
> > true", again pretending BPartition::DiskSystem() exists instead of
> > BPartition::GetDiskSystem(). I guess the question is how useful it
> > is.
> > If we want to give a complete overview in DriveSetup of which
> > partitions
> > are initializable, we'll have to do something similar anyway. If we
> > want
> > to make the user check on a partition by partition basis if a given
> > partition is initializable (i.e. by right-clicking and seeing if an
> > "initialize" item is avaliable or something similar), then the
> > Visit...() function may not be all that necessary. I kind of like 
> > the
> > first ides better though.
> 
> I wonder whether we cross the line of what should be provided by the
> API and what can be implemented in DriveSetup here. The method will be
> relatively expensive if all these checks are done and DriveSetup will
> have to implement the functionality to get all disk systems a 
> partition
> can be initialized with, anyway.

That's a good point. I would say we could probably do without the 
"InitializablePartion" and "PartitionablePartition" versions. I think 
the mounting related ones make sense, and the other three are certainly 
reasonable.

What is the "device" parameter to VisitEachDevice() for? Is it intended 
to actually be a BDiskDevice** output parameter, a la the partition 
parameter for VisitEachPartition(), instead of BDiskDevice* as my copy 
is labeled? For VisitEachPartition(), the "device" parameter allows you 
to specify a single device on which to visit all partitions, IIRC, but 
that doesn't make much sense for VisitEachDevice().

-Tyler





[ Home | Signup | Help | Login | Archives | Lists ]

All trademarks and copyrights within the FreeLists archives are owned by their respective owners.
Everything else ©2007 Avenir Technologies, LLC.