MCPcopy Index your code
hub / github.com/sqlmapproject/sqlmap / applyFunctionRecursively

Function applyFunctionRecursively

lib/core/common.py:4937–4950  ·  view source on GitHub ↗

Applies function recursively through list-like structures >>> applyFunctionRecursively([1, 2, [3, 4, [19]], -9], lambda _: _ > 0) [True, True, [True, True, [True]], False]

(value, function)

Source from the content-addressed store, hash-verified

4935 return kb.counters.get(technique, 0)
4936
4937def applyFunctionRecursively(value, function):
4938 """
4939 Applies function recursively through list-like structures
4940
4941 >>> applyFunctionRecursively([1, 2, [3, 4, [19]], -9], lambda _: _ > 0)
4942 [True, True, [True, True, [True]], False]
4943 """
4944
4945 if isListLike(value):
4946 retVal = [applyFunctionRecursively(_, function) for _ in value]
4947 else:
4948 retVal = function(value)
4949
4950 return retVal
4951
4952def decodeDbmsHexValue(value, raw=False):
4953 """

Callers 4

getValueFunction · 0.90
cleanReplaceUnicodeFunction · 0.85
parseUnionPageFunction · 0.85
decodeDbmsHexValueFunction · 0.85

Calls 1

isListLikeFunction · 0.70

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…