* only generate actually used serializers (anything used in body or response)
* generate previously missing serializers for collection types
* improve formatting
* [dart-dio] Enable strong-mode and strict types
This will make it easier to eventually transition to NNBD. Also fix some formatting things.
* [dart-dio] Add implicit-casts: false to analysis options
* [dart-dio] Add dartanalyzer to integration tests
* raise minimum Dart version to 2.6 (to support spread collection)
* add header to all files for language version
* fix some missing imports that can be fixed (some remain due to missing inheritance support)
* [dart-dio] Generate default value builders
* return `null` when there is no default value instead of `"null"`
* use built_value's `_initializeBuilder` to set default values
* [dart-dio] Fix default value formatting in model doc
* [dart][dart-dio] Prevent name clashes with existing dart types
Can not use dart import aliases for now as this is not supported by built_value. This means we need to add potentially clashing names/classes to an `additionalReservedWords` exclusion list. Starting with a basic list of some http/io classes.
Correctly use `importMapping` and `defaultIncludes` this time around. Improve reserved word checking.
This now successfully generates `ModelList`, `ModelFile` and `ModelClient` models which previously were not generated at all or were wrong types.
* Address review comment
* Update generator docs
* Make header params with dynamic types
Otherwise this will generate code which is not compile-able. Like this:
```dart
Future<Response<List<StockItemProjectionDirect>>>getAllStockItems(Store storeId,{ int xXChunkNumber,int xXChunkSize,StockItemRequestFilterDto stockItemRequestFilterDto,CancelToken cancelToken, Map<String, String> headers, ProgressCallback onSendProgress, ProgressCallback onReceiveProgress,}) async {
String _path = "/api/store/{storeId}/stock".replaceAll("{" r'storeId' "}", storeId.toString());
Map<String, dynamic> queryParams = {};
Map<String, String> headerParams = Map.from(headers ?? {});
dynamic bodyData;
headerParams[r'XX-Chunk-Number'] = xXChunkNumber;
headerParams[r'XX-Chunk-Size'] = xXChunkSize;
```
See how the func recieves int argument which then assignes into a string... last 2 lines
* FIX: Dynamic header and sync with upstream
* DART-DIO new samples
Co-authored-by: William Cheng <wing328hk@gmail.com>
* Use system CA by default and remove certifi
See https://github.com/OpenAPITools/openapi-generator/issues/6506
* Use system CA by default in asyncio client
* Update README_onlypackage.mustache
* Result of ./bin/generate-samples.sh
* Add ssl_ca_cert argument for Configuration
* Result of ./bin/generate-samples.sh
* Remove certifi, use system CA by default
* Include description directly in python docstrings
mustache escaping the description make them render weirdly, including
sometimes unsupported characters in python.
* More parameters
* always add trailing commas in arrays and break each line
* make variables final
* improve API formatting (mainly leading spaces)
* remove empty lines and whitespaces
* fix formatting of datatype and description and docs
* consistently use single quotation marks (dart already does this)
* correctly generate enums from `mostInnerItems`
* use `datatypeWithEnum` which should always be he correct type
* dart generators prefix inner enums with the classname of the containing class, ensure datatypeWithEnum always matches
* only use `FormData.fromMap()` for multipart content, `FormData` does not work with `x-www-form-urlencoded`
* use a basic map for `x-www-form-urlencoded` content
* fix formatting
* [dart] Always use the correct enum data type
* use raw strings for enum string values
* [dart-dio] Use raw strings for built_value enums
`@BuiltValueEnumConst` does some wierd string handling in the generated code `r'\$'` becomes `'$'`. This is different compared to the wireName in `@BuiltValueField`
* [dart] Properly escape param/var names that clash with Dart types
* [dart] Add tests for var/enumVar names
* note: public and private are no keywords in Dart
* some tests are still wrong, some are commented out
* Fix typo
* [dart] Improve variable name escaping
* add more tests
* [dart] Fix operationId naming
* [dart] Fix upper case var name with leading underscore
* [dart] Correctly support model prefix/suffix
* [dart] Support spaces in property names
* Call super for empty operationId
* [dart] Fix and improve enumVar naming/generation
* use same handling for all 3 generators
* allow `updateEnumVarsWithExtensions` to have access to the data type
* improve `x-enum-values` handling and add supprt for other enum vendor extensions
* remove duplicate and outdated tests from `DartDioModelTest`
* add more tests to `DartModelTest`
* no longer force lowercase enums for plain dart generator (breaking)
* this change also removes the trailing underscore from plain dart generator (breaking)
* [dart-dio] Fix wrong escaped serializer names
* [dart-dio] Prevent enum name collisions in inlined enums
Prefix the private built_value instances with the enum class name. Prevents clashes when multiple inline enums contain the same value - for example `EnumTest`. No breaking changes here as all the changed fields/references are private and automatically re-generated with built_value.
* [dart] Configure and use import mapping
This prevents models from being generated which would clash with exisiting dart types, e.g. List.
* [dart] Fix decimal format not supported
* [dart-dio] Remove redundant modelToIgnore & ignore dart:core import
* modelToIgnore is now handled via importMappings the same way other generators do this
* choose not to import dart:core as this is available by default
* [dart-dio] EnumClass is a reserved word in built_value
* Review changes
* Fix regenerate docs
* Fixes issue 8014, _check_type flag not being honored.
Updated model_utils.mustache to pass the check_type flag into attempt_convert_item(). Failure to do so
results in type validation errors occurring when the user has specifically requested that they be disabled.
* regenerated samples
Co-authored-by: Frank Levine <frank.levine@blacklynx.tech>