MCPcopy
hub / github.com/pallets/jinja / copy

Method copy

src/jinja2/utils.py:467–472  ·  view source on GitHub ↗

Return a shallow copy of the instance.

(self)

Source from the content-addressed store, hash-verified

465 return (self.capacity,)
466
467 def copy(self) -> "te.Self":
468 """Return a shallow copy of the instance."""
469 rv = self.__class__(self.capacity)
470 rv._mapping.update(self._mapping)
471 rv._queue.extend(self._queue)
472 return rv
473
474 def get(self, key: t.Any, default: t.Any = None) -> t.Any:
475 """Return an item from the cache dict or `default`"""

Callers 7

do_tojsonFunction · 0.45
get_template_localsFunction · 0.45
__init__Method · 0.45
__init__Method · 0.45
saveMethod · 0.45
test_undefined_copyFunction · 0.45
test_copy_missingFunction · 0.45

Calls 2

__class__Method · 0.80
extendMethod · 0.80

Tested by 2

test_undefined_copyFunction · 0.36
test_copy_missingFunction · 0.36