Skip to content

interface IConsentStore

cangjie
public interface IConsentStore

功能:定义用户同意存储接口。

成员概览

成员功能
func store(Consent)存储用户同意记录。
func find(String, String)根据主体和客户端查找同意记录。
func remove(String, String)删除指定主体和客户端的同意记录。

cangjie
func store(consent: Consent): Unit

功能:存储用户同意记录。

参数:

  • consent: Consent - 用户同意对象。

返回值:

  • Unit

func find(String, String)

cangjie
func find(sub: String, clientId: String): ?Consent

功能:根据主体和客户端查找同意记录。

参数:

  • sub: String - 主体标识。
  • clientId: String - 客户端标识。

返回值:

  • ?Consent - 返回匹配的同意记录;不存在时返回空。

func remove(String, String)

cangjie
func remove(sub: String, clientId: String): Unit

功能:删除指定主体和客户端的同意记录。

参数:

  • sub: String - 主体标识。
  • clientId: String - 客户端标识。

返回值:

  • Unit