MCPcopy Create free account
hub / github.com/apache/trafficserver / map_start

Function map_start

lib/yamlcpp/test/create-emitter-tests.py:77–91  ·  view source on GitHub ↗
(tag='', anchor='', anchor_id=0, style='_')

Source from the content-addressed store, hash-verified

75 return {'emit': 'EndSeq', 'handle': 'OnSequenceEnd()'}
76
77def map_start(tag='', anchor='', anchor_id=0, style='_'):
78 emit = []
79 handle = []
80 if tag:
81 emit += ['VerbatimTag("%s")' % encode(tag)]
82 if anchor:
83 emit += ['Anchor("%s")' % encode(anchor)]
84 handle += ['OnAnchor(_, "%s")' % encode(anchor)]
85 if tag:
86 out_tag = encode(tag)
87 else:
88 out_tag = '?'
89 emit += ['BeginMap']
90 handle += ['OnMapStart(_, "%s", %s, %s)' % (out_tag, anchor_id, style)]
91 return {'emit': emit, 'handle': handle}
92
93def map_end():
94 return {'emit': 'EndMap', 'handle': 'OnMapEnd()'}

Callers 1

gen_templatesFunction · 0.85

Calls 1

encodeFunction · 0.85

Tested by

no test coverage detected