mirror of
https://github.com/JasonYANG170/IOTConnect-Web.git
synced 2024-11-23 20:26:28 +00:00
12 lines
373 B
TypeScript
12 lines
373 B
TypeScript
import { IMessageIdProvider } from './default-message-id-provider';
|
|
export default class UniqueMessageIdProvider implements IMessageIdProvider {
|
|
private numberAllocator;
|
|
private lastId;
|
|
constructor();
|
|
allocate(): number;
|
|
getLastAllocated(): number;
|
|
register(messageId: number): boolean;
|
|
deallocate(messageId: number): void;
|
|
clear(): void;
|
|
}
|