omar / ByteSize

ByteSize is a utility class that makes byte size representation in code easier by removing ambiguity of the value being represented. ByteSize is to bytes what System.TimeSpan is to time.
MIT License
558 stars 50 forks source link

Mebibytes #31

Closed MarkSFrancis closed 4 years ago

MarkSFrancis commented 7 years ago

The units being used in this project are actually kibibyte, mebibyte, gibibyte etc instead of kilobyte, megabyte, gigabyte (MiB for mebibyte, MB for megabyte) which may cause confusion. Kilobyte is 1000 bytes (power of 10), but a kibibyte is 1024 bytes (power of 2).

More info on what a kibibyte is: https://en.wikipedia.org/wiki/Kibibyte

omar commented 5 years ago

Track progress of this feature here #24

omar commented 4 years ago

v2 now supports this, see https://www.nuget.org/packages/ByteSize/2.0.0