Last active
August 29, 2015 14:20
-
-
Save gioele/a27355041c6f46a5ea17 to your computer and use it in GitHub Desktop.
Revisions
-
gioele revised this gist
Apr 28, 2015 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -16,7 +16,7 @@ Call fc.xml.diff.Diff.diff(InputStream ver0, InputStream ver1, OutputStream diff_result) Now the differences (in textual form) are in `diff_result`. ### Elaboration of the results -
gioele revised this gist
Apr 28, 2015 . 1 changed file with 2 additions and 2 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -3,8 +3,8 @@ First approximation ### Preparatory steps 1. serialize the base document (version 0) in the variable `String ver0_string`; 1. serialize the modified document (version 1) in the variable `String ver1_string`; 1. create a `ByteArrayOutputStream diff_result` object. ### The call -
gioele renamed this gist
Apr 28, 2015 . 1 changed file with 0 additions and 0 deletions.There are no files selected for viewing
File renamed without changes. -
gioele renamed this gist
Apr 28, 2015 . 1 changed file with 0 additions and 0 deletions.There are no files selected for viewing
File renamed without changes. -
gioele created this gist
Apr 28, 2015 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,27 @@ First approximation ------------------- ### Preparatory steps 1. serialize the base document (version 0) in the variable `ver0_string`; 1. serialize the modified document (version 1) in the variable `ver1_string`; 1. create a `ByteArrayOutputStream diff_result` object. ### The call Call InputStream ver0 = new ByteArrayInputStream(ver0_string.getBytes(StandardCharsets.UTF_8)); InputStream ver1 = new ByteArrayInputStream(ver1_string.getBytes(StandardCharsets.UTF_8)); fc.xml.diff.Diff.diff(InputStream ver0, InputStream ver1, OutputStream diff_result) Now the differences (in textual form) are in `diff_doc`. ### Elaboration of the results Get a string for the result calling String diff_result_string = diff_result.toString(StandardCharsets.UTF_8) Output `diff_result_string`.