feat: add ByteHelper
This commit is contained in:
parent
f3f511ad36
commit
c39fdd86ec
13
Base/ByteHelper.cs
Normal file
13
Base/ByteHelper.cs
Normal file
|
@ -0,0 +1,13 @@
|
|||
namespace FruityFoundation.Base;
|
||||
|
||||
public static class ByteHelper
|
||||
{
|
||||
public static long FromKilobytes(long kilobytes) =>
|
||||
kilobytes * 1024;
|
||||
|
||||
public static long FromMegabytes(long megabytes) =>
|
||||
megabytes * 1024 * 1024;
|
||||
|
||||
public static long FromGigabytes(long gigabytes) =>
|
||||
gigabytes * 1024 * 1024 * 1024;
|
||||
}
|
Loading…
Reference in New Issue
Block a user