Gnome.Vfs.VolumeMonitor Class
Abstraction for Removable devices.

See Also: VolumeMonitor Members

Syntax

public class VolumeMonitor : GLib.Object

Remarks

The VolumeMonitor offers a simple way to get removable devices: name, icon, type, etc and operations: Eject, Mount, Unmount and others.

In order to use, you need to execute the static method VolumeMonitor.Get. This method give you a pointer to VolumeMonitor, this is a singleton, which means that it will exists and be valid until Vfs.Shutdown

C# Example

	// This example show how to get all connected drives
	using System;
	using Gnome.Vfs;
	namespace TestGnomeVFS
	{
		public class Test()
		{
			public static void Main()
			{
				Vfs.Initialize();
				VolumeMonitor vMonitor = VolumeMonitor.Get();
				Drive[] drv = vMonitor.ConnectedDrives;
				foreach Drive d in drv) {
					Console.WriteLine(d.DisplayName);
				}
				Vfs.Shutdown();
			}
		}
	}
  

Requirements

Namespace: Gnome.Vfs
Assembly: gnome-vfs-sharp (in gnome-vfs-sharp.dll)
Assembly Versions: 2.20.0.0