Exemple #1
0
 /// <summary>
 /// The to trits.
 /// </summary>
 /// <param name="value">
 /// The value.
 /// </param>
 /// <returns>
 /// The <see cref="int[]"/>.
 /// </returns>
 public static int[] ToTrits(this int value)
 {
     return(Converter.IntToTrits(value, 27));
 }
Exemple #2
0
 /// <summary>
 /// The to trytes.
 /// </summary>
 /// <param name="value">
 /// The value.
 /// </param>
 /// <param name="padding">
 /// The padding.
 /// </param>
 /// <returns>
 /// The <see cref="TryteString"/>.
 /// </returns>
 public static TryteString ToTrytes(this int value, int padding)
 {
     return(new TryteString(Converter.TritsToTrytes(Converter.IntToTrits(value, padding))));
 }
Exemple #3
0
 /// <summary>
 /// The to trytes.
 /// </summary>
 /// <param name="value">
 /// The value.
 /// </param>
 /// <param name="padding">
 /// The padding.
 /// </param>
 /// <returns>
 /// The <see cref="TryteString"/>.
 /// </returns>
 public static TryteString ToTrytes(this long value, int padding)
 {
     return(new TryteString(
                Converter.TritsToTrytes(Converter.ConvertBigIntToTrits(new BigInteger(value), padding))));
 }