toJson method

Map<String, Object?> toJson()

Implementation

Map<String, Object?> toJson() {
  var admin = this.admin;
  var default$ = this.default$;
  var description = this.description;
  var id = this.id;
  var name = this.name;
  var roleConfigurable = this.roleConfigurable;
  var scope = this.scope;
  var self = this.self;
  var translatedName = this.translatedName;

  final json = <String, Object?>{};
  json[r'admin'] = admin;
  json[r'default'] = default$;
  if (description != null) {
    json[r'description'] = description;
  }
  if (id != null) {
    json[r'id'] = id;
  }
  if (name != null) {
    json[r'name'] = name;
  }
  json[r'roleConfigurable'] = roleConfigurable;
  if (scope != null) {
    json[r'scope'] = scope.toJson();
  }
  if (self != null) {
    json[r'self'] = self;
  }
  if (translatedName != null) {
    json[r'translatedName'] = translatedName;
  }
  return json;
}