Beispiel #1
0
 public static byte[] ToByteArray(this uint v, int length)
 {
     return(ExtensionHelper.BlockCopy(BitConverter.GetBytes(v), length));
 }
Beispiel #2
0
 public static byte[] ToByteArray(this byte[] a, int length)
 {
     return(ExtensionHelper.BlockCopy(a, length));
 }
Beispiel #3
0
 public static byte[] ToByteArray(this string s, int length)
 {
     return(ExtensionHelper.BlockCopy(s.ToCharArray(), length));
 }