/// <summary> /// Initializes a new instance of the CkAesCtrParams class. /// </summary> /// <param name='counterBits'>The number of bits in the counter block (cb) that shall be incremented</param> /// <param name='cb'>Specifies the counter block (16 bytes)</param> public CkAesCtrParams(ulong counterBits, byte[] cb) { if (Platform.UnmanagedLongSize == 4) { if (Platform.StructPackingSize == 0) { _params40 = new HighLevelAPI40.MechanismParams.CkAesCtrParams(Convert.ToUInt32(counterBits), cb); } else { _params41 = new HighLevelAPI41.MechanismParams.CkAesCtrParams(Convert.ToUInt32(counterBits), cb); } } else { if (Platform.StructPackingSize == 0) { _params80 = new HighLevelAPI80.MechanismParams.CkAesCtrParams(counterBits, cb); } else { _params81 = new HighLevelAPI81.MechanismParams.CkAesCtrParams(counterBits, cb); } } }
/// <summary> /// Initializes a new instance of the CkAesCtrParams class. /// </summary> /// <param name='counterBits'>The number of bits in the counter block (cb) that shall be incremented</param> /// <param name='cb'>Specifies the counter block (16 bytes)</param> public CkAesCtrParams(ulong counterBits, byte[] cb) { if (Platform.UnmanagedLongSize == 4) { if (Platform.StructPackingSize == 0) _params40 = new HighLevelAPI40.MechanismParams.CkAesCtrParams(Convert.ToUInt32(counterBits), cb); else _params41 = new HighLevelAPI41.MechanismParams.CkAesCtrParams(Convert.ToUInt32(counterBits), cb); } else { if (Platform.StructPackingSize == 0) _params80 = new HighLevelAPI80.MechanismParams.CkAesCtrParams(counterBits, cb); else _params81 = new HighLevelAPI81.MechanismParams.CkAesCtrParams(counterBits, cb); } }