MCPcopy Create free account
hub / github.com/webpy/webpy / read_defwith

Method read_defwith

web/template.py:94–100  ·  view source on GitHub ↗
(self, text)

Source from the content-addressed store, hash-verified

92 return DefwithNode(defwith, suite)
93
94 def read_defwith(self, text):
95 if text.startswith("$def with"):
96 defwith, text = splitline(text)
97 defwith = defwith[1:].strip() # strip $ and spaces
98 return defwith, text
99 else:
100 return "", text
101
102 def read_section(self, text):
103 r"""Reads one section from the given text.

Callers 1

parseMethod · 0.95

Calls 1

splitlineFunction · 0.85

Tested by

no test coverage detected