class App42::AppTab::StorageUnit
An enum that contains the Storage
Unit to be mentioned in the Bill
.
Constants
- GB
- KB
- MB
- TB
Public Instance Methods
enum(string)
click to toggle source
Sets the value of the StorageUnit
.
@param string
- the string of StorageUnit
# File lib/appTab/StorageUnit.rb, line 28 def enum(string) return StorageUnit.const_get(string) end
isAvailable(string)
click to toggle source
Returns the value of the StorageUnit
.
@return the value of StorageUnit
.
# File lib/appTab/StorageUnit.rb, line 38 def isAvailable(string) if(string == "KB") return "KB" elsif(string == "MB") return "MB"; elsif(string == "GB") return "GB"; elsif(string == "TB") return "TB"; else return nil end end