MCPcopy Create free account
hub / github.com/nodejs/node / Dispatch

Method Dispatch

tools/gyp/pylib/gyp/mac_tool.py:35–41  ·  view source on GitHub ↗

Dispatches a string command to a method.

(self, args)

Source from the content-addressed store, hash-verified

33 executed directly, or dispatched from an argument list."""
34
35 def Dispatch(self, args):
36 """Dispatches a string command to a method."""
37 if len(args) < 1:
38 raise Exception("Not enough arguments")
39
40 method = "Exec%s" % self._CommandifyName(args[0])
41 return getattr(self, method)(*args[1:])
42
43 def _CommandifyName(self, name_string):
44 """Transforms a tool name like copy-info-plist to CopyInfoPlist"""

Callers 1

mainFunction · 0.95

Calls 1

_CommandifyNameMethod · 0.95

Tested by

no test coverage detected