TiffUnknownType Class

Summary: The unknown tiff type. In case the tiff tag cannot be recognized this type is instantinated.

Module: aspose.imaging.fileformats.tiff.tifftagtypes

Full Name: aspose.imaging.fileformats.tiff.tifftagtypes.TiffUnknownType

Inheritance: TiffDataType

Aspose.Imaging Version: 24.7.0

Constructors

NameDescription
TiffUnknownType(stream, tag_type, tag_id, count, offset_or_value)Initializes a new instance of the TiffUnknownType class.

Properties

NameTypeAccessDescription
countulongrGets the count of elements.
data_sizeulongrGets the tag value size.
element_sizebyterGets the element size in bytes.
idushortrGets tag id as number.
is_validboolrGets a value indicating whether tag data is valid. The valid tag contains data which may be preserved. The invalid tag cannot be stored.
offset_or_valueulongrGets the offset value for an additional data or value itself in case count is 1.
streamTiffStreamReaderrGets the stream to read additional data from.
tag_idTiffTagsrGets the tag id.
tag_typeTiffDataTypesrGets the tag type.
valueobjectr/wGets or sets the value this data type contains.

Methods

NameDescription
compare_to(obj)Compares the current instance with another object of the same type and returns an integer that indicates whether the current instance precedes, follows, or occurs in the same position in the sort order as the other object.
deep_clone()Performs a deep clone of this instance.
get_additional_data_size(size_of_tag_value)Gets the additional tag value size in bytes (in case the tag can not fit the whole tag value).
get_aligned_data_size(size_of_tag_value)Gets the data size aligned in 4-byte (int) or 8-byte (long) boundary.
read_tag(data_stream, position)Reads the tag data.
write_additional_data(data_stream)Writes the additional tag data.
write_tag(data_stream, additional_data_offset)Writes the tag value or additional offset.

Constructor: TiffUnknownType(stream, tag_type, tag_id, count, offset_or_value)

 TiffUnknownType(stream, tag_type, tag_id, count, offset_or_value) 

Initializes a new instance of the TiffUnknownType class.

Parameters:

ParameterTypeDescription
streamTiffStreamReaderThe stream to read from.
tag_typeushortType of the tag.
tag_idushortThe tag id.
countulongThe count value.
offset_or_valueulongThe offset or value.

Method: compare_to(obj)

 compare_to(obj) 

Compares the current instance with another object of the same type and returns an integer that indicates whether the current instance precedes, follows, or occurs in the same position in the sort order as the other object.

Parameters:

ParameterTypeDescription
objobjectAn object to compare with this instance.

Returns

TypeDescription
intA 32-bit signed integer that indicates the relative order of the objects being compared. The return value has these meanings:
Value
Meaning
Less than zero
This instance is less than obj.
Zero
This instance is equal to obj.
Greater than zero
This instance is greater than obj.

Method: deep_clone()

 deep_clone() 

Performs a deep clone of this instance.

Returns

TypeDescription
TiffDataTypeA deep clone of the current instance.

Method: get_additional_data_size(size_of_tag_value)

 get_additional_data_size(size_of_tag_value) 

Gets the additional tag value size in bytes (in case the tag can not fit the whole tag value).

Parameters:

ParameterTypeDescription
size_of_tag_valuebyteSize of tag value: 4 or 8 for BigTiff.

Returns

TypeDescription
ulongThe additional data size in bytes.

Method: get_aligned_data_size(size_of_tag_value)

 get_aligned_data_size(size_of_tag_value) 

Gets the data size aligned in 4-byte (int) or 8-byte (long) boundary.

Parameters:

ParameterTypeDescription
size_of_tag_valuebyteSize of tag value.

Returns

TypeDescription
ulongThe aligned data size in bytes.

Method: read_tag(data_stream, position) [static]

 read_tag(data_stream, position) 

Reads the tag data.

Parameters:

ParameterTypeDescription
data_streamTiffStreamReaderThe data stream.
positionlongThe tag position.

Returns

TypeDescription
TiffDataTypeThe read tag.

Method: write_additional_data(data_stream)

 write_additional_data(data_stream) 

Writes the additional tag data.

Parameters:

ParameterTypeDescription
data_streamTiffStreamWriterThe data stream.

Returns

TypeDescription
longThe actual bytes written.

Method: write_tag(data_stream, additional_data_offset)

 write_tag(data_stream, additional_data_offset) 

Writes the tag value or additional offset.

Parameters:

ParameterTypeDescription
data_streamTiffStreamWriterThe data stream.
additional_data_offsetlongThe additional data offset.