VirtualBox

Changeset 90434 in vbox for trunk/src/VBox/Main/include


Ignore:
Timestamp:
Jul 30, 2021 3:56:44 PM (3 years ago)
Author:
vboxsync
Message:

Main/ovfreader.h: Forgotten check-in for string-based identifiers. Also touch-up of the OS list to match the official state from the DMTF.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Main/include/ovfreader.h

    r85222 r90434  
    283283
    284284enum ResourceType_T
    285 {   ResourceType_Other   = 1,
    286     ResourceType_ComputerSystem  = 2,
    287     ResourceType_Processor   = 3,
    288     ResourceType_Memory  = 4,
    289     ResourceType_IDEController   = 5,
    290     ResourceType_ParallelSCSIHBA = 6,
    291     ResourceType_FCHBA   = 7,
    292     ResourceType_iSCSIHBA    = 8,
    293     ResourceType_IBHCA   = 9,
    294     ResourceType_EthernetAdapter = 10,
    295     ResourceType_OtherNetworkAdapter = 11,
    296     ResourceType_IOSlot  = 12,
    297     ResourceType_IODevice    = 13,
    298     ResourceType_FloppyDrive = 14,
    299     ResourceType_CDDrive = 15,
    300     ResourceType_DVDDrive    = 16,
    301     ResourceType_HardDisk    = 17,
     285{
     286    ResourceType_Other  = 1,
     287    ResourceType_ComputerSystem = 2,
     288    ResourceType_Processor  = 3,
     289    ResourceType_Memory = 4,
     290    ResourceType_IDEController  = 5,
     291    ResourceType_ParallelSCSIHBA    = 6,
     292    ResourceType_FCHBA  = 7,
     293    ResourceType_iSCSIHBA   = 8,
     294    ResourceType_IBHCA  = 9,
     295    ResourceType_EthernetAdapter    = 10,
     296    ResourceType_OtherNetworkAdapter    = 11,
     297    ResourceType_IOSlot = 12,
     298    ResourceType_IODevice   = 13,
     299    ResourceType_FloppyDrive    = 14,
     300    ResourceType_CDDrive    = 15,
     301    ResourceType_DVDDrive   = 16,
     302    ResourceType_HardDisk   = 17,
     303    ResourceType_TapeDrive  = 18,
     304    ResourceType_StorageExtent  = 19,
    302305    ResourceType_OtherStorageDevice  = 20,
    303     ResourceType_USBController   = 23,
    304     ResourceType_SoundCard   = 35
     306    ResourceType_SerialPort = 21,
     307    ResourceType_ParallelPort   = 22,
     308    ResourceType_USBController  = 23,
     309    ResourceType_GraphicsController = 24,
     310    ResourceType_IEEE1394Controller = 25,
     311    ResourceType_PartitionableUnit  = 26,
     312    ResourceType_BasePartitionableUnit  = 27,
     313    ResourceType_Power  = 28,
     314    ResourceType_CoolingCapacity    = 29,
     315    ResourceType_EthernetSwitchPort = 30,
     316    ResourceType_LogicalDisk    = 31,
     317    ResourceType_StorageVolume  = 32,
     318    ResourceType_EthernetConnection = 33,
     319    ResourceType_SoundCard  = 35    /**< @todo r=klaus: Not part of OVF/CIM spec, should use "Other" or some value from 0x8000..0xffff. */
    305320};
    306321
     
    327342    RTCString strElementName;
    328343
    329     uint32_t ulInstanceID;
    330     uint32_t ulParent;
     344    RTCString strInstanceID;
     345    RTCString strParent;
    331346
    332347    ResourceType_T resourceType;
     
    361376
    362377    VirtualHardwareItem()
    363         : ulInstanceID(0)
    364         , fResourceRequired(false)
     378        : fResourceRequired(false)
    365379        , fAutomaticAllocation(false)
    366380        , fAutomaticDeallocation(false)
     
    542556struct HardDiskController
    543557{
    544     uint32_t                idController;       // instance ID (Item/InstanceId); this gets referenced from VirtualDisk
     558    RTCString               strIdController;    // instance ID (Item/InstanceId); this gets referenced from VirtualDisk
    545559
    546560    enum ControllerSystemType { IDE, SATA, SCSI, VIRTIOSCSI };
    547561    ControllerSystemType    system;             // one of IDE, SATA, SCSI, VIRTIOSCSI
    548562
    549     RTCString        strControllerType;
     563    RTCString               strControllerType;
    550564            // controller subtype (Item/ResourceSubType); e.g. "LsiLogic"; can be empty (esp. for IDE)
    551565            // note that we treat LsiLogicSAS as a SCSI controller (system == SCSI) even though VirtualBox
     
    558572
    559573    HardDiskController()
    560         : idController(0),
    561           lAddress(0),
     574        : lAddress(0),
    562575          fPrimary(true)
    563576    { }
    564577};
    565578
    566 typedef std::map<uint32_t, HardDiskController> ControllersMap;
     579typedef std::map<RTCString, HardDiskController> ControllersMap;
    567580
    568581struct VirtualDisk
    569582{
    570     uint32_t    idController;// SCSI (or IDE) controller this disk is connected to;
    571                              // this must match HardDiskController.idController and
    572                              // points into VirtualSystem.mapControllers
    573     uint32_t    ulAddressOnParent;// parsed strAddressOnParent of hardware item; will be 0 or 1 for IDE
    574                                   // and possibly higher for disks attached to SCSI controllers (untested)
    575     RTCString   strDiskId;// if the hard disk has an ovf:/disk/<id> reference,
    576                           // this receives the <id> component; points to one of the
    577                           // references in Appliance::Data.mapDisks
    578     bool        fEmpty;//true - empty disk, e.g. the component <rasd:HostResource>...</rasd:HostResource> is absent.
     583    RTCString   strIdController;    // SCSI (or IDE) controller this disk is connected to;
     584                                    // this must match HardDiskController.strIdController and
     585                                    // points into VirtualSystem.mapControllers
     586    uint32_t    ulAddressOnParent;  // parsed strAddressOnParent of hardware item; will be 0 or 1 for IDE
     587                                    // and possibly higher for disks attached to SCSI controllers (untested)
     588    RTCString   strDiskId;          // if the hard disk has an ovf:/disk/<id> reference,
     589                                    // this receives the <id> component; points to one of the
     590                                    // references in Appliance::Data.mapDisks
     591    bool        fEmpty; //true - empty disk, e.g. the component <rasd:HostResource>...</rasd:HostResource> is absent.
    579592};
    580593
     
    603616    RTCString    strDescription;         // copy of VirtualSystem/AnnotationSection content, if any
    604617
    605     CIMOSType_T         cimos;
     618    CIMOSType_T  cimos;
    606619    RTCString    strCimosDesc;           // readable description of the cimos type in the case of cimos = 0/1/102
    607620    RTCString    strTypeVBox;            // optional type from @vbox:ostype attribute (VirtualBox 4.0 or higher)
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette