Platforms to show: All Mac Windows Linux Cross-Platform

Back to ArchiveWriterMBS class.

ArchiveWriterMBS.SetFilterOption(Module as String, Option as String, Value as String)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Archive MBS Compression Plugin 19.0 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Apply option to the filter only.

Lasterror property is set.

ArchiveWriterMBS.SetFormat(FormatCode as Integer)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Archive MBS Compression Plugin 16.2 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Sets format by code.

Lasterror property is set.

ArchiveWriterMBS.SetFormat7Zip

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Archive MBS Compression Plugin 16.2 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Sets format to 7zip.

Lasterror property is set.
7zip support in MBS Plugin is very limited.

ArchiveWriterMBS.SetFormatArBsd

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Archive MBS Compression Plugin 16.2 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Sets format to ar bsd.

Lasterror property is set.

ArchiveWriterMBS.SetFormatArSvr4

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Archive MBS Compression Plugin 16.2 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Sets format to ar svr4.

Lasterror property is set.

ArchiveWriterMBS.SetFormatByExtension(FileName as String, defaultExtension as String = "")

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Archive MBS Compression Plugin 16.3 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Set file format by extension of filename.

e.g. pass "test.zip" for file name and ".zip" for default extension (if filename has none).
Lasterror property is set.

ArchiveWriterMBS.SetFormatByName(Name as String)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Archive MBS Compression Plugin 16.2 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Sets format by name.

Lasterror property is set.

ArchiveWriterMBS.SetFormatCpio

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Archive MBS Compression Plugin 16.2 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Sets format to cpio.

Lasterror property is set.

ArchiveWriterMBS.SetFormatCpioNewc

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Archive MBS Compression Plugin 16.2 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Sets format to cpio newc.

Lasterror property is set.

ArchiveWriterMBS.SetFormatGnutar

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Archive MBS Compression Plugin 16.2 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Sets format to gnu tape archive files.

Lasterror property is set.

ArchiveWriterMBS.SetFormatIso9660

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Archive MBS Compression Plugin 16.2 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Sets format to iso 9660.

Lasterror property is set.

ArchiveWriterMBS.SetFormatMTree

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Archive MBS Compression Plugin 16.2 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Sets format to mtree.

Lasterror property is set.

ArchiveWriterMBS.SetFormatMTreeClassic

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Archive MBS Compression Plugin 16.2 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Sets format to mtree classic.

Lasterror property is set.

ArchiveWriterMBS.SetFormatOption(Module as String, Option as String, Value as String)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Archive MBS Compression Plugin 19.0 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Apply option to the format only.

Lasterror property is set.

ArchiveWriterMBS.SetFormatPax

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Archive MBS Compression Plugin 16.2 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Sets format to pax.

Lasterror property is set.

ArchiveWriterMBS.SetFormatPaxRestricted

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Archive MBS Compression Plugin 16.2 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Sets format to pax restricted.

Lasterror property is set.

Some examples using this method:

ArchiveWriterMBS.SetFormatRaw

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Archive MBS Compression Plugin 16.3 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Sets raw format.

Lasterror property is set.

ArchiveWriterMBS.SetFormatShar

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Archive MBS Compression Plugin 16.2 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Sets format to shar.

Lasterror property is set.

ArchiveWriterMBS.SetFormatSharDump

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Archive MBS Compression Plugin 16.2 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Sets format to shar dump.

Lasterror property is set.

ArchiveWriterMBS.SetFormatUstar

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Archive MBS Compression Plugin 16.2 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Sets format to Unix Standard TAR.

Lasterror property is set.

ArchiveWriterMBS.SetFormatV7tar

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Archive MBS Compression Plugin 16.2 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Sets format to v7 tape archive files.

Lasterror property is set.

ArchiveWriterMBS.SetFormatWArc

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Archive MBS Compression Plugin 16.3 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Sets format to web archive.

Lasterror property is set.

ArchiveWriterMBS.SetFormatXar

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Archive MBS Compression Plugin 16.2 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Sets format to xar.

Lasterror property is set.

ArchiveWriterMBS.SetFormatZip

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Archive MBS Compression Plugin 16.2 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Sets format to zip.
Example
Var a as new ArchiveWriterMBS

a.SetFormatZip
a.ZipSetCompressionDeflate

Var f as FolderItem = SpecialFolder.Desktop.Child("test.zip")
if not a.CreateFile(f) then
break // failed

else

Var data as string = "Hello World test file. Hello World again."

Var e as new ArchiveEntryMBS
e.PathName = "Hello World.txt"
e.Size = lenb(data)
e.Permissions = &o0644
e.FileType = e.kFileTypeRegular

a.WriteHeader e
call a.WriteData data

a.FinishEntry

a.Close
end if

Lasterror property is set.

Some examples using this method:

ArchiveWriterMBS.SetOption(Module as String, Option as String, Value as String)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Archive MBS Compression Plugin 19.0 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Apply option to both the format and the filter.

Lasterror property is set.

ArchiveWriterMBS.SetOptions(Options as String)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Archive MBS Compression Plugin 19.0 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Apply option string to both the format and the filter.
Example
Var a as new ArchiveWriterMBS
a.SetOptions "hdrcharset=UTF-8" // for unicode file names

Lasterror property is set.

The options to pass to writer.
This is a comma-separated list of options. Option names can be prefixed with module name.

Sample options:
compression=9
zip:encryption=zipcrypt
zip:encryption=aes128
zip:encryption=aes256
zip64
gzip:compression-level=9
hdrcharset=UTF-8

ArchiveWriterMBS.SetPassphrase(Password as String)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Archive MBS Compression Plugin 16.3 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Sets the passphrase to use.
Example
Var a as new ArchiveWriterMBS

a.SetFormatZip
a.ZipSetCompressionDeflate

a.SetOptions "zip:encryption=zipcrypt" // enable encryption
a.SetPassphrase "HelloWorld" // set password

Alternatively you can use the Passphrase event.
Lasterror property is set.

Some examples using this method:

ArchiveWriterMBS.SetSkipFile(DeviceID as Int64, FileNo as Int64)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Archive MBS Compression Plugin 19.0 ✅ Yes ✅ Yes ✅ Yes ✅ Yes All
Record the dev/ino of a file that will not be written.

This is generally set to the dev/ino of the archive being written.
Lasterror property is set.

The items on this page are in the following plugins: MBS Compression Plugin.


The biggest plugin in space...