OpenAPISchema.string constructor

OpenAPISchema.string({
  1. String? format,
  2. String? description,
  3. String? pattern,
  4. int? minLength,
  5. int? maxLength,
  6. Map<String, Object?>? additional,
})

Creates a string schema.

Implementation

factory OpenAPISchema.string({
  String? format,
  String? description,
  String? pattern,
  int? minLength,
  int? maxLength,
  Map<String, Object?>? additional,
}) => OpenAPISchema._({
  ...?additional,
  'type': 'string',
  'format': ?format,
  'description': ?description,
  'pattern': ?pattern,
  'minLength': ?minLength,
  'maxLength': ?maxLength,
});