MCPcopy Create free account
hub / github.com/ReAPI-com/mcp-openapi / get

Method get

src/core/Cache.ts:66–77  ·  view source on GitHub ↗
(key: K)

Source from the content-addressed store, hash-verified

64 }
65
66 get(key: K): V | undefined {
67 const entry = this.cache.get(key);
68 if (!entry) return undefined;
69
70 // Check if entry has expired
71 if (Date.now() - entry.timestamp > this.ttl) {
72 this.cache.delete(key);
73 return undefined;
74 }
75
76 return entry.value;
77 }
78
79 clear(): void {
80 this.cache.clear();

Callers 1

loadSpecMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected