Instead, use an in memory hash table to cache the data and just keep a key to the data in the session.
相反地,应该使用内存中的哈希表来缓存数据,并且在会话中保存一个对此数据进行引用的键。
Each instance has to initialize its own cache, but it only caches the references it USES, and is able to access the reference directly rather than having to look it up in a hash map.
每个实例必须初始化其自身的缓存,但它只缓存那些它要使用的引用,并且可以直接访问引用而不是要到一个散列映射中去寻找。
If the hash key is calculated from those parameters, previously generated versions of the same view can be retrieved easily from the cache.
如果用这些参数计算散列键,则很容易在缓存中找到同一视图的旧版本。
应用推荐