sdg
Version:
pomelo ts
29 lines (28 loc) • 1.14 kB
TypeScript
import { FRONTEND_ID, IGroups, UID } from '..';
import ChannelService from '../common/service/channelService';
/**
* uid加入group
* @param uid
* @param frontendId
* @param groups
*/
export declare const add: (uid: UID, frontendId: FRONTEND_ID, groups: IGroups) => boolean;
/**
* 删除对应的uid
* @param uid
* @param frontendId
* @param groups
*/
export declare const leave: (uid: UID, frontendId: FRONTEND_ID, groups: IGroups) => boolean;
/**
*
* @param channelService
* @param key
* @param value
*/
export declare const addToStore: (channelService: ChannelService, key: string, value: string) => Promise<void>;
export declare const removeFromStore: (channelService: ChannelService, key: string, value: string) => Promise<void>;
export declare const loadAllFromStore: (channelService: ChannelService, key: string) => Promise<string[]>;
export declare const removeAllFromStore: (channelService: ChannelService, key: string) => Promise<boolean>;
export declare const genKey: (channelService: ChannelService, name?: string | undefined) => string;
export declare const genValue: (frontendId: FRONTEND_ID, uid: UID) => string;