NonResourcePolicyRule.fromJson constructor

NonResourcePolicyRule.fromJson(
  1. Map<String, dynamic> json
)

Creates a NonResourcePolicyRule from JSON data.

Implementation

factory NonResourcePolicyRule.fromJson(Map<String, dynamic> json) {
  final tempNonResourceURLsJson = json['nonResourceURLs'];
  final tempVerbsJson = json['verbs'];

  final List<String> tempNonResourceURLs =
      List<String>.from(tempNonResourceURLsJson);
  final List<String> tempVerbs = List<String>.from(tempVerbsJson);

  return NonResourcePolicyRule(
    nonResourceURLs: tempNonResourceURLs,
    verbs: tempVerbs,
  );
}