saveInnerModule()

in lib/generator.js [194:212]


  saveInnerModule(ast) {
    const keys = ast.innerModule.keys();
    let data = keys.next();
    while (!data.done) {
      const aliasId = data.value;
      const moduleAst = ast.innerDep.get(aliasId);
      this.ast = ast;
      // this.modelPath = path.join(this.outputDir, this.config.package, 'models.py');
      // this.exceptionPath = path.join(this.outputDir, this.config.package, 'exceptions.py');
      const filepath = ast.innerModule.get(aliasId);
      this.className = this.getInnerClient(aliasId);
      this.modelPath = filepath.replace('.py', '_models');
      this.modelPackage = path.basename(this.modelPath);
      this.exceptionPath = filepath.replace('.py', '_exceptions');
      this.exceptionPackage = path.basename(this.exceptionPath);
      this.visitModule(moduleAst, filepath, false, 0);
      data = keys.next();
    }
  }