@@ -86,8 +86,8 @@ Here's a few really simple examples.
86
86
CDBuilder builder = new CDBuilder ();
87
87
builder. useJoliet = true ;
88
88
builder. volumeIdentifier = " A_SAMPLE_DISK" ;
89
- builder. addFile(" Folder \\ Hello.txt" , " Hello World!" . getBytes(Charset . forName(" ASCII" )));
90
- builder. build(" C: \\ temp \\ sample.iso" );
89
+ builder. addFile(" folder/ Hello.txt" , " Hello World!" . getBytes(Charset . forName(" ASCII" )));
90
+ builder. build(" /tmp/ sample.iso" );
91
91
```
92
92
93
93
You can add files as byte arrays (shown above), as files from the Windows filesystem, or as a Stream. By using a different form of Build, you can get a Stream to the ISO file, rather than writing it to the Windows filesystem.
@@ -96,9 +96,9 @@ You can add files as byte arrays (shown above), as files from the Windows filesy
96
96
### How to extract a file from an ISO:
97
97
98
98
``` Java
99
- try (FileStream isoStream = File . open(" C: \\ temp \\ sample.iso" )) {
99
+ try (FileStream isoStream = File . open(" /tmp/ sample.iso" )) {
100
100
CDReader cd = new CDReader (isoStream, true );
101
- Stream fileStream = cd. openFile(" Folder \\ Hello.txt" , FileMode . Open );
101
+ Stream fileStream = cd. openFile(" folder/ Hello.txt" , FileMode . Open );
102
102
// Use fileStream...
103
103
}
104
104
```
@@ -109,11 +109,11 @@ You can also browse through the directory hierarchy, starting at cd.Root.
109
109
110
110
``` Java
111
111
long diskSize = 30 * 1024 * 1024 ; // 30MB
112
- try (Stream vhdStream = File . create(" C: \\ TEMP \\ mydisk.vhd" )) {
112
+ try (Stream vhdStream = File . create(" /tmp/ mydisk.vhd" )) {
113
113
Disk disk = Disk . initializeDynamic(vhdStream, diskSize);
114
114
BiosPartitionTable . initialize(disk, WellKnownPartitionType . WindowsFat );
115
115
try (FatFileSystem fs = FatFileSystem . formatPartition(disk, 0 , null )) {
116
- fs. createDirectory(" TestDir\\ CHILD" );
116
+ fs. createDirectory(" TestDir/ CHILD" );
117
117
// do other things with the file system...
118
118
}
119
119
}
@@ -165,7 +165,7 @@ Automated CI builds are available on [Github](https://github.com/umjammer/vavi-n
165
165
* compile by jdk8
166
166
* ~~ https://github.com/AssafTzurEl/discUtils/commit/3853944811a16d6220dcb6e8d408561e05569e43 ~~
167
167
* img ... https://github.com/hessu/bchunk
168
- * file separator
168
+ * ~~ file separator~~
169
169
* pc98 partition (wip)
170
170
* d88 floppy disk
171
171
* qcow2
0 commit comments