Exemplo n.º 1
0
 protected RawDevice(Manager manager, GioMetadataSource gioMetadata, UdevMetadataSource udevMetadata)
 {
     Manager      = manager;
     GioMetadata  = gioMetadata;
     UdevMetadata = udevMetadata;
     if (!string.IsNullOrEmpty(IdMediaPlayer))
     {
         MediaCapabilities = new DeviceMediaCapabilities(IdMediaPlayer);
     }
 }
Exemplo n.º 2
0
 static UdevMetadataSource ResolveUsingUsbBusAndPort(UdevMetadataSource metadata, bool recurse)
 {
     do
     {
         if (metadata.PropertyExists(UdevUsbBusNumber) && metadata.PropertyExists(UdevUsbDeviceNumber))
         {
             return(metadata);
         }
     } while (recurse && (metadata = metadata.Parent) != null);
     return(null);
 }
Exemplo n.º 3
0
        static UdevMetadataSource ResolveUsingBusType(UdevMetadataSource metadata, bool recurse)
        {
            var comparer = StringComparer.OrdinalIgnoreCase;

            do
            {
                if (metadata.PropertyExists("ID_BUS") && comparer.Equals("usb", metadata.GetPropertyString("ID_BUS")))
                {
                    return(metadata);
                }
            } while (recurse && (metadata = metadata.Parent) != null);
            return(null);
        }
Exemplo n.º 4
0
 public RawUsbDevice (Manager manager, GioMetadataSource gioMetadata, UdevMetadataSource udevMetadata)
     : base (manager, gioMetadata, udevMetadata)
 {
 }
Exemplo n.º 5
0
 public RawBlockDevice (GLib.Drive drive, Manager manager, GioDriveMetadetaSource gioMetadata, UdevMetadataSource udevMetadata)
     : base (manager, gioMetadata, udevMetadata)
 {
     Drive = drive;
 }
Exemplo n.º 6
0
 static UdevMetadataSource ResolveUsingBusType (UdevMetadataSource metadata, bool recurse)
 {
     var comparer = StringComparer.OrdinalIgnoreCase;
     do {
         if (metadata.PropertyExists ("ID_BUS") && comparer.Equals ("usb", metadata.GetPropertyString ("ID_BUS")))
             return metadata;
     } while (recurse && (metadata = metadata.Parent) != null);
     return null;
 }
Exemplo n.º 7
0
 static UdevMetadataSource ResolveUsingUsbBusAndPort (UdevMetadataSource metadata, bool recurse)
 {
     do {
         if (metadata.PropertyExists (UdevUsbBusNumber) && metadata.PropertyExists (UdevUsbDeviceNumber))
             return metadata;
     } while (recurse && (metadata = metadata.Parent) != null);
     return null;
 }
Exemplo n.º 8
0
 public RawVolume(GLib.IVolume volume, Manager manager, GioVolumeMetadataSource gioMetadata, UdevMetadataSource udevMetadata)
     : base(manager, gioMetadata, udevMetadata)
 {
     Volume = volume;
 }
 public RawBlockDevice(GLib.Drive drive, Manager manager, GioDriveMetadetaSource gioMetadata, UdevMetadataSource udevMetadata)
     : base(manager, gioMetadata, udevMetadata)
 {
     Drive = drive;
 }
Exemplo n.º 10
0
 public RawUsbDevice(Manager manager, GioMetadataSource gioMetadata, UdevMetadataSource udevMetadata)
     : base(manager, gioMetadata, udevMetadata)
 {
 }
Exemplo n.º 11
0
 public RawVolume(GLib.Volume volume, Manager manager, GioVolumeMetadataSource gioMetadata, UdevMetadataSource udevMetadata)
     : base(manager, gioMetadata, udevMetadata)
 {
     Volume = volume;
 }