Example #1
0
        public new StorageVolumeOptions GetOptions()
        {
            var options = new StorageVolumeOptions();

            CopyToOptions(options);
            return(options);
        }
Example #2
0
 public StorageVolume (string id, string parentId, StorageVolumeOptions options)
     : base (id, parentId, options)
 {
     StorageTotal = options.StorageTotal;
     StorageUsed = options.StorageUsed;
     StorageFree = options.StorageFree;
     StorageMedium = options.StorageMedium;
 }
Example #3
0
 public StorageVolume(string id, string parentId, StorageVolumeOptions options)
     : base(id, parentId, options)
 {
     StorageTotal  = options.StorageTotal;
     StorageUsed   = options.StorageUsed;
     StorageFree   = options.StorageFree;
     StorageMedium = options.StorageMedium;
 }
Example #4
0
        protected void CopyToOptions (StorageVolumeOptions options)
        {
            base.CopyToOptions (options);

            options.StorageTotal = StorageTotal;
            options.StorageUsed = StorageUsed;
            options.StorageFree = StorageFree;
            options.StorageMedium = StorageMedium;
        }
Example #5
0
        protected void CopyToOptions(StorageVolumeOptions options)
        {
            base.CopyToOptions(options);

            options.StorageTotal  = StorageTotal;
            options.StorageUsed   = StorageUsed;
            options.StorageFree   = StorageFree;
            options.StorageMedium = StorageMedium;
        }
Example #6
0
 static void AssertStorageVolume (StorageVolume storageVolume, StorageVolumeOptions options)
 {
     AssertContainer (storageVolume, options);
     Assert.AreEqual (storageVolume.StorageUsed, options.StorageUsed);
     Assert.AreEqual (storageVolume.StorageTotal, options.StorageTotal);
     Assert.AreEqual (storageVolume.StorageFree, options.StorageFree);
     Assert.AreEqual (storageVolume.StorageMedium, options.StorageMedium);
 }
Example #7
0
 static void SetStorageVolumeOptions (StorageVolumeOptions options)
 {
     SetStorageFolderOptions (options);
     options.StorageTotal = 54;
     options.StorageFree = 55;
     options.StorageMedium = "56";
 }
Example #8
0
 public void StorageVolumeInstantiation ()
 {
     var options = new StorageVolumeOptions ();
     SetStorageVolumeOptions (options);
     var storage_volume = new StorageVolume ("-1", "-1", options);
     AssertStorageVolume (storage_volume, options);
     AssertStorageVolume (storage_volume, storage_volume.GetOptions ());
 }
Example #9
0
 public new StorageVolumeOptions GetOptions ()
 {
     var options = new StorageVolumeOptions ();
     CopyToOptions (options);
     return options;
 }