public static void SetAttrib(IntPtr connectionHandle, Attribiutes attributeId, byte[] attributeData)
        {
            var retCode = SCardSetAttrib(connectionHandle, (int)attributeId, attributeData, attributeData.Length);

            if (SuccessCode != retCode)
            {
                throw ExceptionHelper.PrepareException(retCode, "SCardSetAttrib");
            }
        }
        public static void GetAttrib(IntPtr connectionHandle, Attribiutes attributeId, ref byte[] dataBuffer, out int dataSize)
        {
            var dataBufferSize = dataBuffer.Length;
            var retCode        = SCardGetAttrib(connectionHandle, (int)attributeId, dataBuffer, ref dataBufferSize);

            if (SuccessCode != retCode)
            {
                throw ExceptionHelper.PrepareException(retCode, "SCardGetAttrib");
            }

            dataSize = dataBufferSize;
        }
 public void SetAttribiute(Attribiutes attribiuteId, IReadOnlyList <byte> attribute)
 {
     WinSCardWrapper.SetAttrib(Handle, attribiuteId, attribute.ToArray());
 }
        public IReadOnlyList <byte> GetAttribiute(Attribiutes attribiuteId)
        {
            WinSCardWrapper.GetAttrib(Handle, attribiuteId, ref _buffer, out var dataSize);

            return((IReadOnlyList <byte>)_buffer.Take(dataSize));
        }