共用方式為


Deflater.SetDictionary Method

Definition

Overloads

SetDictionary(Byte[], Int32, Int32)

Sets preset dictionary for compression.

SetDictionary(Byte[])

Sets preset dictionary for compression.

SetDictionary(ByteBuffer)

Sets preset dictionary for compression.

SetDictionary(Byte[], Int32, Int32)

Sets preset dictionary for compression.

[Android.Runtime.Register("setDictionary", "([BII)V", "GetSetDictionary_arrayBIIHandler")]
public virtual void SetDictionary (byte[]? b, int off, int len);
[Android.Runtime.Register("setDictionary", "([BII)V", "GetSetDictionary_arrayBIIHandler")]
public virtual void SetDictionary (byte[]? dictionary, int off, int len);
[<Android.Runtime.Register("setDictionary", "([BII)V", "GetSetDictionary_arrayBIIHandler")>]
abstract member SetDictionary : byte[] * int * int -> unit
override this.SetDictionary : byte[] * int * int -> unit

Parameters

bdictionary
Byte[]

the dictionary data bytes

off
Int32

the start offset of the data

len
Int32

the length of the data

Attributes

Remarks

Sets preset dictionary for compression. A preset dictionary is used when the history buffer can be predetermined. When the data is later uncompressed with Inflater.inflate(), Inflater.getAdler() can be called in order to get the Adler-32 value of the dictionary required for decompression.

Java documentation for java.util.zip.Deflater.setDictionary(byte[], int, int).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

SetDictionary(Byte[])

Sets preset dictionary for compression.

[Android.Runtime.Register("setDictionary", "([B)V", "GetSetDictionary_arrayBHandler")]
public virtual void SetDictionary (byte[]? b);
[Android.Runtime.Register("setDictionary", "([B)V", "GetSetDictionary_arrayBHandler")]
public virtual void SetDictionary (byte[]? dictionary);
[<Android.Runtime.Register("setDictionary", "([B)V", "GetSetDictionary_arrayBHandler")>]
abstract member SetDictionary : byte[] -> unit
override this.SetDictionary : byte[] -> unit

Parameters

bdictionary
Byte[]

the dictionary data bytes

Attributes

Remarks

Sets preset dictionary for compression. A preset dictionary is used when the history buffer can be predetermined. When the data is later uncompressed with Inflater.inflate(), Inflater.getAdler() can be called in order to get the Adler-32 value of the dictionary required for decompression.

Java documentation for java.util.zip.Deflater.setDictionary(byte[]).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

SetDictionary(ByteBuffer)

Sets preset dictionary for compression.

[Android.Runtime.Register("setDictionary", "(Ljava/nio/ByteBuffer;)V", "GetSetDictionary_Ljava_nio_ByteBuffer_Handler", ApiSince=35)]
public virtual void SetDictionary (Java.Nio.ByteBuffer? dictionary);
[<Android.Runtime.Register("setDictionary", "(Ljava/nio/ByteBuffer;)V", "GetSetDictionary_Ljava_nio_ByteBuffer_Handler", ApiSince=35)>]
abstract member SetDictionary : Java.Nio.ByteBuffer -> unit
override this.SetDictionary : Java.Nio.ByteBuffer -> unit

Parameters

dictionary
ByteBuffer

the dictionary data bytes

Attributes

Remarks

Sets preset dictionary for compression. A preset dictionary is used when the history buffer can be predetermined. When the data is later uncompressed with Inflater.inflate(), Inflater.getAdler() can be called in order to get the Adler-32 value of the dictionary required for decompression.

The bytes in given byte buffer will be fully consumed by this method. On return, its position will equal its limit.

Java documentation for java.util.zip.Deflater.setDictionary(java.nio.ByteBuffer).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to