// // AUTO-GENERATED FILE, DO NOT MODIFY! // // @dart=2.18 // ignore_for_file: unused_element, unused_import // ignore_for_file: always_put_required_named_parameters_first // ignore_for_file: constant_identifier_names // ignore_for_file: lines_longer_than_80_chars part of openapi.api; /// Ce qu'est le fond d'une visite : un panorama fixe, une video 360 qui tourne en /// boucle, ou une scene 3D. /// /// 0 = Pano 1 = Video360 2 = Scene3D class ImmersiveBackgroundKind { const ImmersiveBackgroundKind._(this.value); final int value; @override String toString() => value.toString(); int toJson() => value; /// Une image equirectangulaire : le cas le plus courant et le moins couteux. static const Pano = ImmersiveBackgroundKind._(0); /// Une video equirectangulaire, jouee en boucle et sans son. static const Video360 = ImmersiveBackgroundKind._(1); /// Un decor 3D. Prevu par le contrat, pas encore rendu en fond par le casque. static const Scene3D = ImmersiveBackgroundKind._(2); static const values = [Pano, Video360, Scene3D]; static ImmersiveBackgroundKind? fromJson(dynamic value) => ImmersiveBackgroundKindTypeTransformer().decode(value); static List listFromJson(dynamic json, {bool growable = false,}) { final result = []; if (json is List && json.isNotEmpty) { for (final row in json) { final value = ImmersiveBackgroundKind.fromJson(row); if (value != null) { result.add(value); } } } return result.toList(growable: growable); } } class ImmersiveBackgroundKindTypeTransformer { factory ImmersiveBackgroundKindTypeTransformer() => _instance ??= const ImmersiveBackgroundKindTypeTransformer._(); const ImmersiveBackgroundKindTypeTransformer._(); int encode(ImmersiveBackgroundKind data) => data.value; ImmersiveBackgroundKind? decode(dynamic data, {bool allowNull = true}) { if (data != null) { if (data.runtimeType == String) { switch (data.toString()) { case r'Pano': return ImmersiveBackgroundKind.Pano; case r'Video360': return ImmersiveBackgroundKind.Video360; case r'Scene3D': return ImmersiveBackgroundKind.Scene3D; default: if (!allowNull) { throw ArgumentError('Unknown enum value to decode: $data'); } } } else if (data.runtimeType == int) { switch (data) { case 0: return ImmersiveBackgroundKind.Pano; case 1: return ImmersiveBackgroundKind.Video360; case 2: return ImmersiveBackgroundKind.Scene3D; default: if (!allowNull) { throw ArgumentError('Unknown enum value to decode: $data'); } } } } return null; } static ImmersiveBackgroundKindTypeTransformer? _instance; }