Get JavaScript Recipes: A Problem-Solution Approach 1st Edition Russ Ferguson Free All Chapters
Get JavaScript Recipes: A Problem-Solution Approach 1st Edition Russ Ferguson Free All Chapters
com
https://textbookfull.com/product/javascript-
recipes-a-problem-solution-approach-1st-edition-
russ-ferguson/
https://textbookfull.com/product/android-recipes-a-problem-
solution-approach-dave-smith/
https://textbookfull.com/product/raku-recipes-a-problem-solution-
approach-j-j-merelo/
https://textbookfull.com/product/c-recipes-a-problem-solution-
approach-1st-edition-shirish-chavan/
https://textbookfull.com/product/wxpython-recipes-a-problem-
solution-approach-1st-edition-mike-driscoll/
MATLAB Recipes: a problem-solution approach 2nd Edition
Michael Paluszek
https://textbookfull.com/product/matlab-recipes-a-problem-
solution-approach-2nd-edition-michael-paluszek/
https://textbookfull.com/product/prestashop-recipes-a-problem-
solution-approach-1st-edition-arnaldo-perez-castano-auth/
https://textbookfull.com/product/java-ee-7-recipes-a-problem-
solution-approach-1st-edition-juneau-josh/
https://textbookfull.com/product/java-9-recipes-a-problem-
solution-approach-3rd-edition-josh-juneau/
https://textbookfull.com/product/spring-5-recipes-a-problem-
solution-approach-4th-edition-marten-deinum/
JavaScript
Recipes
A Problem-Solution Approach
—
Russ Ferguson
Keith Cirkel
JavaScript Recipes
A Problem-Solution Approach
Russ Ferguson
Keith Cirkel
JavaScript Recipes: A Problem-Solution Approach
Russ Ferguson Keith Cirkel
Ocean, New Jersey, USA London, United Kingdom
ISBN-13 (pbk): 978-1-4302-6106-3 ISBN-13 (electronic): 978-1-4302-6107-0
DOI 10.1007/978-1-4302-6107-0
Library of Congress Control Number: 2016960744
Copyright © 2017 by Russ Ferguson and Keith Cirkel
This work is subject to copyright. All rights are reserved by the Publisher, whether the whole or part of the
material is concerned, specifically the rights of translation, reprinting, reuse of illustrations, recitation,
broadcasting, reproduction on microfilms or in any other physical way, and transmission or information storage
and retrieval, electronic adaptation, computer software, or by similar or dissimilar methodology now known or
hereafter developed.
Trademarked names, logos, and images may appear in this book. Rather than use a trademark symbol with
every occurrence of a trademarked name, logo, or image we use the names, logos, and images only in an
editorial fashion and to the benefit of the trademark owner, with no intention of infringement of the trademark.
The use in this publication of trade names, trademarks, service marks, and similar terms, even if they are
not identified as such, is not to be taken as an expression of opinion as to whether or not they are subject to
proprietary rights.
While the advice and information in this book are believed to be true and accurate at the date of publication,
neither the authors nor the editors nor the publisher can accept any legal responsibility for any errors or
omissions that may be made. The publisher makes no warranty, express or implied, with respect to the
material contained herein.
Managing Director: Welmoed Spahr
Acquisitions Editor: Louise Corrigan
Technical Reviewer: Luca Mezzalira
Editorial Board: Steve Anglin, Pramila Balan, Laura Berendson, Aaron Black, Louise Corrigan,
Jonathan Gennick, Todd Green, Robert Hutchinson, Celestin Suresh John, Nikhil Karkal,
James Markham, Susan McDermott, Matthew Moodie, Natalie Pao, Gwenan Spearing
Coordinating Editor: Nancy Chen
Copy Editor: Kezia Endsley
Compositor: SPi Global
Indexer: SPi Global
Artist: SPi Global
Distributed to the book trade worldwide by Springer Science+Business Media New York,
233 Spring Street, 6th Floor, New York, NY 10013. Phone 1-800-SPRINGER, fax (201) 348-4505, e-mail
orders-ny@springer-sbm.com, or visit www.springer.com. Apress Media, LLC is a California LLC and the sole
member (owner) is Springer Science + Business Media Finance Inc (SSBM Finance Inc). SSBM Finance Inc is
a Delaware corporation.
For information on translations, please e-mail rights@apress.com, or visit www.apress.com.
Apress and friends of ED books may be purchased in bulk for academic, corporate, or promotional use.
eBook versions and licenses are also available for most titles. For more information, reference our Special
Bulk Sales–eBook Licensing web page at www.apress.com/bulk-sales.
Any source code or other supplementary materials referenced by the author in this text are available to
readers at www.apress.com. For detailed information about how to locate your book’s source code, go to
www.apress.com/source-code/. Readers can also access source code at SpringerLink in the Supplementary
Material section for each chapter.
Printed on acid-free paper
This space is always reserved for my brother Rodd and my Dad.
You guys are severely missed.
—Russ
Contents at a Glance
■
■Chapter 1: Working with JavaScript Datatypes����������������������������������������������������� 1
■
■Chapter 2: Working with Expressions����������������������������������������������������������������� 49
■
■Chapter 3: Working with Strings������������������������������������������������������������������������� 91
■
■Chapter 4: Working with Numbers and Math���������������������������������������������������� 137
■
■Chapter 5: Working with Bitwise Operations Against 32-Bit Integers�������������� 151
■
■Chapter 6: Dates and Times������������������������������������������������������������������������������� 173
■
■Chapter 7: Working with Arrays������������������������������������������������������������������������ 181
■
■Chapter 8: Working with Arrays in Loops���������������������������������������������������������� 195
■
■Chapter 9: Working with Objects����������������������������������������������������������������������� 207
■
■Chapter 10: Working with Sets�������������������������������������������������������������������������� 225
■
■Chapter 11: Working with Maps������������������������������������������������������������������������ 233
■
■Chapter 12: Working with Functions����������������������������������������������������������������� 239
■
■Chapter 13: Working with Generators��������������������������������������������������������������� 255
■
■Chapter 15: Working with Symbols������������������������������������������������������������������� 267
■
■Chapter 16: Working with Proxies��������������������������������������������������������������������� 277
v
■ Contents at a Glance
■
■Chapter 17: Working with Classes�������������������������������������������������������������������� 281
■
■Chapter 18: Working with Events���������������������������������������������������������������������� 289
■
■Chapter 19: Debugging and Handling Exceptions���������������������������������������������� 295
■
■Chapter 20: Working with Regular Expressions������������������������������������������������ 301
■
■Chapter 21: Working with Asynchronous Control Flow and Promises�������������� 309
Index��������������������������������������������������������������������������������������������������������������������� 341
vi
Contents
■
■Chapter 1: Working with JavaScript Datatypes����������������������������������������������������� 1
Assigning Variables with the var Statement��������������������������������������������������������������������� 1
Problem�������������������������������������������������������������������������������������������������������������������������������������������������� 1
Solution�������������������������������������������������������������������������������������������������������������������������������������������������� 1
The Code������������������������������������������������������������������������������������������������������������������������������������������������� 1
How It Works������������������������������������������������������������������������������������������������������������������������������������������� 1
vii
■ Contents
viii
■ Contents
ix
■ Contents
x
■ Contents
xi
■ Contents
■
■Chapter 2: Working with Expressions����������������������������������������������������������������� 49
Performing an Addition with the + Operator������������������������������������������������������������������ 49
Problem������������������������������������������������������������������������������������������������������������������������������������������������ 49
Solution������������������������������������������������������������������������������������������������������������������������������������������������ 49
xii
■ Contents
The Code����������������������������������������������������������������������������������������������������������������������������������������������� 49
How It Works����������������������������������������������������������������������������������������������������������������������������������������� 50
Performing a Subtraction with the - Operator���������������������������������������������������������������� 50
Problem������������������������������������������������������������������������������������������������������������������������������������������������ 50
Solution������������������������������������������������������������������������������������������������������������������������������������������������ 50
The Code����������������������������������������������������������������������������������������������������������������������������������������������� 50
How It Works����������������������������������������������������������������������������������������������������������������������������������������� 51
Performing Multiplication with the * Operator��������������������������������������������������������������� 51
Problem������������������������������������������������������������������������������������������������������������������������������������������������ 51
Solution������������������������������������������������������������������������������������������������������������������������������������������������ 51
The Code����������������������������������������������������������������������������������������������������������������������������������������������� 51
How It Works����������������������������������������������������������������������������������������������������������������������������������������� 52
Performing Division with the / Operator������������������������������������������������������������������������� 52
Problem������������������������������������������������������������������������������������������������������������������������������������������������ 52
Solution������������������������������������������������������������������������������������������������������������������������������������������������ 52
The Code����������������������������������������������������������������������������������������������������������������������������������������������� 52
How It Works����������������������������������������������������������������������������������������������������������������������������������������� 52
Getting the Remainder of a Division Operation with the Modulo (%) Operator�������������� 53
Problem������������������������������������������������������������������������������������������������������������������������������������������������ 53
Solution������������������������������������������������������������������������������������������������������������������������������������������������ 53
The Code����������������������������������������������������������������������������������������������������������������������������������������������� 53
How It Works����������������������������������������������������������������������������������������������������������������������������������������� 53
Determining If a Value Is Less Than Another with the < Operator���������������������������������� 54
Problem������������������������������������������������������������������������������������������������������������������������������������������������ 54
Solution������������������������������������������������������������������������������������������������������������������������������������������������ 54
The Code����������������������������������������������������������������������������������������������������������������������������������������������� 54
How It Works����������������������������������������������������������������������������������������������������������������������������������������� 55
Determining If a Value Is Greater than Another with the > Operator������������������������������ 55
Problem������������������������������������������������������������������������������������������������������������������������������������������������ 55
Solution������������������������������������������������������������������������������������������������������������������������������������������������ 55
The Code����������������������������������������������������������������������������������������������������������������������������������������������� 55
How It Works����������������������������������������������������������������������������������������������������������������������������������������� 56
xiii
■ Contents
Determining If a Value Is Less than or Equal to Another with the <= Operator����������� 56
Problem������������������������������������������������������������������������������������������������������������������������������������������������ 56
Solution������������������������������������������������������������������������������������������������������������������������������������������������ 56
The Code����������������������������������������������������������������������������������������������������������������������������������������������� 56
How It Works����������������������������������������������������������������������������������������������������������������������������������������� 57
Determining If a Value Is Greater than or Equal to Another with the >= Operator��������� 57
Problem������������������������������������������������������������������������������������������������������������������������������������������������ 57
Solution������������������������������������������������������������������������������������������������������������������������������������������������ 57
The Code����������������������������������������������������������������������������������������������������������������������������������������������� 58
How It Works����������������������������������������������������������������������������������������������������������������������������������������� 58
Determining If a Value Is Strictly Not Equal to Another Using the !== Operator������������ 66
Problem������������������������������������������������������������������������������������������������������������������������������������������������ 66
Solution������������������������������������������������������������������������������������������������������������������������������������������������ 66
The Code����������������������������������������������������������������������������������������������������������������������������������������������� 67
How It Works����������������������������������������������������������������������������������������������������������������������������������������� 68
xiv
■ Contents
Using the Increment (++) Operator to Increase the Value of a Number Variable����������� 69
Problem������������������������������������������������������������������������������������������������������������������������������������������������ 69
Solution������������������������������������������������������������������������������������������������������������������������������������������������ 69
The Code����������������������������������������������������������������������������������������������������������������������������������������������� 70
How It Works����������������������������������������������������������������������������������������������������������������������������������������� 70
Using the Decrement (--) Operator to Decrease the Value of a Number Variable����������� 70
Problem������������������������������������������������������������������������������������������������������������������������������������������������ 70
Solution������������������������������������������������������������������������������������������������������������������������������������������������ 71
The Code����������������������������������������������������������������������������������������������������������������������������������������������� 71
How It Works����������������������������������������������������������������������������������������������������������������������������������������� 71
Using the Unary Subtraction (-) Operator to Flip the Sign of a Number������������������������� 72
Problem������������������������������������������������������������������������������������������������������������������������������������������������ 72
Solution������������������������������������������������������������������������������������������������������������������������������������������������ 73
The Code����������������������������������������������������������������������������������������������������������������������������������������������� 73
How It Works����������������������������������������������������������������������������������������������������������������������������������������� 73
xv
■ Contents
xvi
■ Contents
■
■Chapter 3: Working with Strings������������������������������������������������������������������������� 91
Understanding Unicode Strings�������������������������������������������������������������������������������������� 91
Problem������������������������������������������������������������������������������������������������������������������������������������������������ 91
Solution������������������������������������������������������������������������������������������������������������������������������������������������ 91
The Code����������������������������������������������������������������������������������������������������������������������������������������������� 91
How It Works����������������������������������������������������������������������������������������������������������������������������������������� 92
xvii
■ Contents
Getting a Single Character’s UTF Code Unit from a String with charCodeAt( )������������� 100
Problem���������������������������������������������������������������������������������������������������������������������������������������������� 100
Solution���������������������������������������������������������������������������������������������������������������������������������������������� 101
The Code��������������������������������������������������������������������������������������������������������������������������������������������� 101
How It Works��������������������������������������������������������������������������������������������������������������������������������������� 101
Getting a Single Character’s UTF Code Point from a string with codePointAt( )����������� 102
Problem���������������������������������������������������������������������������������������������������������������������������������������������� 102
Solution���������������������������������������������������������������������������������������������������������������������������������������������� 102
The Code��������������������������������������������������������������������������������������������������������������������������������������������� 102
How It Works��������������������������������������������������������������������������������������������������������������������������������������� 103
xviii
■ Contents
xix
■ Contents
Finding the Index of the Last Occurrence of a Substring with lastIndexOf( )���������������� 113
Problem���������������������������������������������������������������������������������������������������������������������������������������������� 113
Solution���������������������������������������������������������������������������������������������������������������������������������������������� 113
The Code��������������������������������������������������������������������������������������������������������������������������������������������� 113
How It Works��������������������������������������������������������������������������������������������������������������������������������������� 114
xx
■ Contents
xxi
■ Contents
■
■Chapter 4: Working with Numbers and Math���������������������������������������������������� 137
Converting Strings to Numbers������������������������������������������������������������������������������������ 137
Problem���������������������������������������������������������������������������������������������������������������������������������������������� 137
Solution���������������������������������������������������������������������������������������������������������������������������������������������� 137
The Code��������������������������������������������������������������������������������������������������������������������������������������������� 137
How It Works��������������������������������������������������������������������������������������������������������������������������������������� 138
Creating a Number Object�������������������������������������������������������������������������������������������� 138
Problem���������������������������������������������������������������������������������������������������������������������������������������������� 138
Solution���������������������������������������������������������������������������������������������������������������������������������������������� 138
The Code��������������������������������������������������������������������������������������������������������������������������������������������� 138
How It Works��������������������������������������������������������������������������������������������������������������������������������������� 138
xxiii
■ Contents
xxiv
■ Contents
■
■Chapter 5: Working with Bitwise Operations Against 32-Bit Integers�������������� 151
What Are 32-Bit Integers?�������������������������������������������������������������������������������������������� 151
Problem���������������������������������������������������������������������������������������������������������������������������������������������� 151
Solution���������������������������������������������������������������������������������������������������������������������������������������������� 151
The Code��������������������������������������������������������������������������������������������������������������������������������������������� 151
How It Works��������������������������������������������������������������������������������������������������������������������������������������� 151
Multiplying by Powers of 2 with the Left Shift (<<) Operator�������������������������������������� 152
Problem���������������������������������������������������������������������������������������������������������������������������������������������� 152
Solution���������������������������������������������������������������������������������������������������������������������������������������������� 152
The Code��������������������������������������������������������������������������������������������������������������������������������������������� 152
How It Works��������������������������������������������������������������������������������������������������������������������������������������� 152
Dividing by Powers of 2 with the Sign-Propagating Right Shift (>>) Operator������������ 154
Problem���������������������������������������������������������������������������������������������������������������������������������������������� 154
Solution���������������������������������������������������������������������������������������������������������������������������������������������� 154
The Code��������������������������������������������������������������������������������������������������������������������������������������������� 154
How It Works��������������������������������������������������������������������������������������������������������������������������������������� 155
Using the Zero-Fill Right Shift (>>>) Operator to Ensure a Variable
Is a 32-Bit Unsigned Integer����������������������������������������������������������������������������������������� 156
Problem���������������������������������������������������������������������������������������������������������������������������������������������� 156
Solution���������������������������������������������������������������������������������������������������������������������������������������������� 156
The Code��������������������������������������������������������������������������������������������������������������������������������������������� 156
How It Works��������������������������������������������������������������������������������������������������������������������������������������� 157
Using the Bitwise NOT (~) Operator to Swap All Binary Bits in a 32-Bit Integer���������� 158
Problem���������������������������������������������������������������������������������������������������������������������������������������������� 158
Solution���������������������������������������������������������������������������������������������������������������������������������������������� 158
The Code��������������������������������������������������������������������������������������������������������������������������������������������� 158
How It Works��������������������������������������������������������������������������������������������������������������������������������������� 158
xxv
■ Contents
Using Bitwise AND (&) Operator to Get a Value of All Equal Bits in a 32-Bit Integer����� 159
Problem���������������������������������������������������������������������������������������������������������������������������������������������� 159
Solution���������������������������������������������������������������������������������������������������������������������������������������������� 160
The Code��������������������������������������������������������������������������������������������������������������������������������������������� 160
How It Works��������������������������������������������������������������������������������������������������������������������������������������� 160
Using Bitwise OR (|) Operator to Get a Value Positive Bits on One or Both Operands�� 161
Problem���������������������������������������������������������������������������������������������������������������������������������������������� 161
Solution���������������������������������������������������������������������������������������������������������������������������������������������� 161
The Code��������������������������������������������������������������������������������������������������������������������������������������������� 162
How It Works��������������������������������������������������������������������������������������������������������������������������������������� 162
Using the Bitwise XOR (^) Operator to Get a Value of Differing Bits in Each Operand�������� 163
Problem���������������������������������������������������������������������������������������������������������������������������������������������� 163
Solution���������������������������������������������������������������������������������������������������������������������������������������������� 163
The Code��������������������������������������������������������������������������������������������������������������������������������������������� 163
How It Works��������������������������������������������������������������������������������������������������������������������������������������� 164
Converting RGB Color to Hexadecimal and Back Using
the Bitwise Signed Shift (>>, <<) Operators and the Bitwise AND (&) Operator��������� 165
Problem���������������������������������������������������������������������������������������������������������������������������������������������� 165
Solution���������������������������������������������������������������������������������������������������������������������������������������������� 165
The Code��������������������������������������������������������������������������������������������������������������������������������������������� 165
How It Works��������������������������������������������������������������������������������������������������������������������������������������� 166
Creating, Editing, and Testing a Bit Field Flag Set Using Bitwise Operators����������������� 169
Problem���������������������������������������������������������������������������������������������������������������������������������������������� 169
Solution���������������������������������������������������������������������������������������������������������������������������������������������� 169
The Code��������������������������������������������������������������������������������������������������������������������������������������������� 169
How It Works��������������������������������������������������������������������������������������������������������������������������������������� 170
■
■Chapter 6: Dates and Times������������������������������������������������������������������������������� 173
Using the Date Object��������������������������������������������������������������������������������������������������� 173
Problem���������������������������������������������������������������������������������������������������������������������������������������������� 173
Solution���������������������������������������������������������������������������������������������������������������������������������������������� 173
The Code��������������������������������������������������������������������������������������������������������������������������������������������� 173
How It Works��������������������������������������������������������������������������������������������������������������������������������������� 173
xxvi
■ Contents
Using the HTML5 Date Input Field to Make a Date Object�������������������������������������������� 175
Problem���������������������������������������������������������������������������������������������������������������������������������������������� 175
Solution���������������������������������������������������������������������������������������������������������������������������������������������� 175
The Code��������������������������������������������������������������������������������������������������������������������������������������������� 176
How It Works��������������������������������������������������������������������������������������������������������������������������������������� 176
xxvii
■ Contents
■
■Chapter 7: Working with Arrays������������������������������������������������������������������������ 181
What Is an Array?��������������������������������������������������������������������������������������������������������� 181
Problem���������������������������������������������������������������������������������������������������������������������������������������������� 181
Solution���������������������������������������������������������������������������������������������������������������������������������������������� 181
The Code��������������������������������������������������������������������������������������������������������������������������������������������� 181
How It Works��������������������������������������������������������������������������������������������������������������������������������������� 181
xxviii
■ Contents
xxix
Another random document with
no related content on Scribd:
Pietarin kirkossa ja sen tulee olla avoinna kaikille tulijoille.»
»Bene!»
»Bene!»
»Bene!»
»Bene!»
»Anteeksi, poikani! Minä olen syyllisempi kuin sinä. Oli väärin, että
lähetin suusanallisen viestin kettujen luolaan. Pyhän isän ei pitäisi
olla missään tekemisissä sellaisten ihmisten kanssa. Mutta kaikki on
Jumalan kädessä. Jättäkäämme kaikki Pyhän Hengen valtaan.»
»En! Tai jos sen teen, saa hän tulla ainoastaan herransa
seurassa.»
»Kuninkaanko?»
»Niin.»
»Voi sinua Mirri! Sainpa sinut kiinni nyt… Taas säikäytit pientä
lintuemoraukkaa. Missähän sen pesä lienee?»
Pius P.P.X.»
Hän ajatteli tuota nuorta naista, joka oli käynyt hänen luonaan,
hänen kertomustaan, hänen rukoustaan, hänen kaihoavaa
katsettaan, hänen surullista ääntään.
Väki siellä oli enimmäkseen köyhää kansaa. Sitä oli tullut kaikista
kaupunginosista ja Campagnalta. Siellä oli kalpeita miehiä
rukousnauha kädessä ja naisia kantaen pieniä lapsia, joihin he
tekivät ristinmerkin vihkivedellä. Tuolla kulki kädettömiä, jalattomia
kerjäläisiä, ryömien, mutisten, polvistuen. Näin murehtivan kansan
virta tulvaili kirkon läpi kertoen kurjuudesta ja puutteesta.
Paavin hovi oli syystä ylpeä. Muutamat sen jäsenet eivät ollenkaan
koettaneetkaan salata iloaan siitä, että olivat voineet iskeä noin
tuntuvan iskun hallitseviin luokkiin. Mutta Roomassa oli sittenkin yksi
mies, joka ei tuntenut mitään iloa voitostaan. Se oli paavi.
Hän oli pessyt kahdentoista köyhän miehen jalat. Nämä miehet oli
otettu Rooman kaduilta edustamaan kahtatoista apostolia ja asetettu
istumaan valkoisissa puvuissa punaisella ja kullalla päällystetylle
istuimelle. Kynttilöitä kantavien pappien jälessä ja kamariherrain
sekä kardinaalien ympäröimänä hän oli astunut valtaistuimelle pyhän
Pietarin patsaan eteen, joka tilaisuutta varten oli puettu paavilliseen
pukuun kantaen mustassa päässään hiippaa ja mustassa sormessaan
sormusta. Kun hän sitten oli pessyt miesten jalat ja kuivannut ne
sekä suudellut kutakin jalkaa kansan riemuitessa raivokkaasti, palasi
hän huoneistoonsa ajatellen Kristusta, joka eli köyhien seassa ja
rakasti heitä.
»Ehkei minun olisi pitänyt mennä niin pitkälle — mutta kun tuo
anarkismin aalto uhkaa koko maailmaa… Uskotko, että Rossi
salaisesti on anarkisti?»
»Sääli, sääli!»
»Mitä nyt?»
»Eipä siltä, että pelkäisin», sanoi hän, »en pelkää itse. Mutta
tietysti minun täytyy ajatella muita — perhettäni — kansaani —
Italiaakin — ja jos teidän pyhyytenne… jos… teidän pyhyytenne…»
Paroni, joka oli seisonut toinen käsi rinnan yli ja toinen poskella,
puuttui nyt puheeseen.
»Hänen henkensä?»
»Entä sitten?»
»Entä sitten?»
»Ja sitten?»
»Jos teidän pyhyytenne voi saada tuon nuoren naisen
todistamaan, että hänen rakastajansa on sama, edellisestä
salaliitosta tuomittu mies, niin autatte häntä pelastamaan miehensä
hengen.»
»Kuinka niin?»
»Ja sitten?»
»Minä kuuntelen.»
»Kysymyksessä oleva mies on kirkon katkerin vihollinen. Olkoonpa
hän kuinka tekopyhä tahansa, tiedetään, että hän on ateisti ja
vapaamuurari, joka on vannonut, etteivät mitkään yksityiset asiat tai
tunteet, ei isänmaa eikä suku saa kääntää häntä pois päämäärästä,
joka on yhteiskunnan ja kirkon kukistaminen.»
»Ja sitten?»
»Ja sitten?»
»Minä kysyn.»
»Jatkakaa.»
»Jos rikos tapahtuu ja kuningas saa surmansa, minun, kuninkaan
ministerin, on pakko ilmaista — ja vaatia tämä munkki todistajaksi —
että paavi tiesi asiasta edeltäkäsin ja käsittämällä mitä jaloimmalla
tavalla kuolemattoman sielun salaisuuden pyhänä pitämisen kehoitti
kuninkaanmurhaan.»