| 864 | |
| 865 | |
| 866 | class CacheHook: |
| 867 | def __init__(self, cachinglm): |
| 868 | if cachinglm is None: |
| 869 | self.dbdict = None |
| 870 | return |
| 871 | |
| 872 | self.dbdict = cachinglm.dbdict |
| 873 | |
| 874 | def add_partial(self, attr, req, res): |
| 875 | if self.dbdict is None: |
| 876 | return |
| 877 | hsh = hash_args(attr, req) |
| 878 | self.dbdict[hsh] = res |
| 879 | |
| 880 | |
| 881 | class CachingLM: |
no outgoing calls
no test coverage detected