fromJSON static method

PermissionItem fromJSON(
  1. Map<String, dynamic> data
)

Implementation

static PermissionItem fromJSON(Map<String, dynamic> data) {
	if (data["kotlinType"] == null) {
		throw ArgumentError('Missing discriminator: kotlinType');
	}
	String discriminator = data["kotlinType"];
	switch (discriminator) {
		case "AlwaysPermissionItemDto":
			return AlwaysPermissionItem.fromJSON(data);
		default:
			throw ArgumentError('Invalid subclass $discriminator');
	}
}