PosSharp v1.2.0 API Reference
---
#### [PosSharp\.Core](PosSharp.Core 'PosSharp\.Core')
### [PosSharp\.Core](PosSharp.Core 'PosSharp\.Core').[UposDeviceBase](PosSharp.Core.UposDeviceBase 'PosSharp\.Core\.UposDeviceBase')
## UposDeviceBase\.ClaimAsync\(int, CancellationToken\) Method
Claims exclusive access to the device\.
```csharp
public System.Threading.Tasks.Task ClaimAsync(int timeout, System.Threading.CancellationToken ct=default(System.Threading.CancellationToken));
```
#### Parameters
`timeout` [System\.Int32](https://learn.microsoft.com/en-us/dotnet/api/system.int32 'System\.Int32')
Timeout in milliseconds\.
`ct` [System\.Threading\.CancellationToken](https://learn.microsoft.com/en-us/dotnet/api/system.threading.cancellationtoken 'System\.Threading\.CancellationToken')
A token to cancel the operation\.
Implements [ClaimAsync\(int, CancellationToken\)](https://learn.microsoft.com/en-us/dotnet/api/possharp.abstractions.iuposdevice.claimasync#possharp-abstractions-iuposdevice-claimasync(system-int32-system-threading-cancellationtoken) 'PosSharp\.Abstractions\.IUposDevice\.ClaimAsync\(System\.Int32,System\.Threading\.CancellationToken\)')
#### Returns
[System\.Threading\.Tasks\.Task](https://learn.microsoft.com/en-us/dotnet/api/system.threading.tasks.task 'System\.Threading\.Tasks\.Task')
A task representing the asynchronous operation\.