async generate(asyncapiDocument, parseOptions = {}) {
    this.validateAsyncAPIDocument(asyncapiDocument);
    await this.setupOutput();
    this.setLogLevel();

    await this.installAndSetupTemplate();
    await this.configureTemplateWorkflow(parseOptions);
    await this.handleEntrypoint();
    await this.executeAfterHook();
  }
Generates files from a given template and an AsyncAPIDocument object.

@async
@example
await generator.generate(myAsyncAPIdocument);
console.log('Done!');

@example
generator
  .generate(myAsyncAPIdocument)
  .then(() => {
    console.log('Done!');
  })
  .catch(console.error);

@example <caption>Using async/await</caption>
try {
  await generator.generate(myAsyncAPIdocument);
  console.log('Done!');
} catch (e) {
  console.error(e);
}

@param {AsyncAPIDocument | string} asyncapiDocument - AsyncAPIDocument object to use as source.
@param {Object} [parseOptions={}] - AsyncAPI Parser parse options.
  Check out {@link https://www.github.com/asyncapi/parser-js|@asyncapi/parser} for more information.
  Remember to use the right options for the right parser depending on the template you are using.
@return {Promise<void>} A Promise that resolves when the generation is completed.