/// /// Copyright © 2014-2023 PDF Technologies, Inc. All Rights Reserved. /// /// THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW /// AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE ComPDFKit LICENSE AGREEMENT. /// UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES. /// This notice may not be removed from this file. class CPDFOutlineData { int level = 1; String title = ''; int pageIndex = 0; bool expanded = false; List? childOutline; CPDFOutlineData( {this.level = 1, this.title = '', this.pageIndex = 0, this.childOutline}); CPDFOutlineData.formJson(Map json) { level = json['level']; title = json['title']; pageIndex = json['pageIndex']; childOutline = parse(json['childOutline']); } List parse(List list) { List datas = List.empty(growable: true); for (var value in list) { datas.add(CPDFOutlineData.formJson(value)); } return datas; } @override String toString() { return 'title: $title, level: $level, pageIndex:$pageIndex, childOutline:${childOutline.toString()} '; } }