MCPcopy Create free account
hub / github.com/PierreGode/Ragnar / substrateFun

Method substrateFun

pager_lib/pyasn1/codec/ber/decoder.py:1829–1836  ·  view source on GitHub ↗

Legacy hack to keep the recursiveFlag=False option supported. The decode(..., substrateFun=userCallback) option was introduced in 0.1.4 as a generalization of the old recursiveFlag=False option. Users should pass their callback instead of using

(asn1Object, _substrate, _length, _options)

Source from the content-addressed store, hash-verified

1827 if state is stDecodeValue:
1828 if not options.get('recursiveFlag', True) and not substrateFun: # deprecate this
1829 def substrateFun(asn1Object, _substrate, _length, _options):
1830 """Legacy hack to keep the recursiveFlag=False option supported.
1831
1832 The decode(..., substrateFun=userCallback) option was introduced in 0.1.4 as a generalization
1833 of the old recursiveFlag=False option. Users should pass their callback instead of using
1834 recursiveFlag.
1835 """
1836 yield asn1Object
1837
1838 original_position = substrate.tell()
1839

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected