1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
local method = {} local function init(name) method[name] = require('method.' .. name:gsub('/', '.')) end init 'initialize' init 'initialized' init 'shutdown' init 'textDocument/definition' init 'textDocument/didOpen' init 'textDocument/didChange' init 'textDocument/didClose' return method