expireTime property

int expireTime
final

~english Gets the time period(seconds) when the user attributes in the cache expire. If the interval between two callers is less than or equal to the value you set in the parameter, user attributes are obtained directly from the local cache; otherwise, they are obtained from the server. For example, if you set this parameter to 120(2 minutes), once this method is called again within 2 minutes, the SDK returns the attributes obtained last time. ~end

~chinese 获取缓存中的用户属性到期时的时间段(秒)。如果两个调用者之间的间隔小于或等于参数中设置的值,则直接从本地缓存获取用户属性; 否则,从服务器获取。例如,如果将该参数设置为120(2分钟),则在2分钟内再次调用该方法,SDK将返回上次获取的属性。 ~end

Implementation

final int expireTime = DateTime.now().millisecondsSinceEpoch;