Skip to content

Commit a5351f7

Browse files
committed
feat dart: add pubName to library name.
Otherwise projects may not use different apis generated by swagger, because library names must be unique.
1 parent 0d0d353 commit a5351f7

File tree

5 files changed

+5
-5
lines changed

5 files changed

+5
-5
lines changed

modules/swagger-codegen/src/main/resources/dart/api.mustache

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
part of api;
1+
part of {{pubName}}.api;
22

33
{{#operations}}
44

modules/swagger-codegen/src/main/resources/dart/api_exception.mustache

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
part of api;
1+
part of {{pubName}}.api;
22

33
class ApiException implements Exception {
44
int code = 0;

modules/swagger-codegen/src/main/resources/dart/api_helper.mustache

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
part of api;
1+
part of {{pubName}}.api;
22

33
const _delimiters = const {'csv': ',', 'ssv': ' ', 'tsv': '\t', 'pipes': '|'};
44

modules/swagger-codegen/src/main/resources/dart/apilib.mustache

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
library api;
1+
library {{pubName}}.api;
22

33
import 'dart:async';
44
import 'dart:convert';{{#browserClient}}

modules/swagger-codegen/src/main/resources/dart/model.mustache

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
part of api;
1+
part of {{pubName}}.api;
22

33
{{#models}}{{#model}}
44
@Entity()

0 commit comments

Comments
 (0)