Deprecation warning

Please note that this is outdated documentation for an older release of the Scandit Barcode Scanner SDK.

We are deprecating the 5.x API on all platforms (except Linux). Release 5.19 in April 2021 will be our final. Applications running 5.x will continue to work, and we will continue to release critical bug fixes and security patches only, for one year. We encourage you to migrate to 6.x and take advantage of our latest / advanced features and improved performance.

You'll find the updated documentation at: Data Capture SDK Documentation for Android

ScEncodingArray.h
Go to the documentation of this file.
1 
10 #ifndef SC_ENCODING_ARRAY_H_
11 #define SC_ENCODING_ARRAY_H_
12 
13 #include <Scandit/ScConfig.h>
14 
15 #if defined(__cplusplus)
16 extern "C" {
17 #endif
18 
22 typedef struct {
23  union {
24  const uint8_t *data;
25  const char* c_str;
26  };
27  uint32_t length;
28  uint16_t flags;
29 } ScData;
30 
36 SC_EXPORT void
37 sc_data_free(ScData data);
38 
46 typedef struct {
49  uint32_t start;
50  uint32_t end;
53 
62 SC_EXPORT void
64 
77 SC_EXPORT ScEncodingRange
78 sc_encoding_range_new(const char* c_str, uint32_t start, uint32_t end);
79 
87 typedef struct {
90  uint32_t size;
93 
104 SC_EXPORT ScEncodingArray
105 sc_encoding_array_new(uint32_t size);
106 
119 SC_EXPORT void
120 sc_encoding_array_assign(ScEncodingArray *array, uint32_t pos, const char * encoding, uint32_t start, uint32_t end);
121 
132 SC_EXPORT uint32_t
134 
146 SC_EXPORT ScEncodingRange
148 
157 SC_EXPORT void
159 
160 #if defined(__cplusplus)
161 }
162 #endif
163 
164 #endif // SC_BYTE_ARRAY_H_
uint16_t flags
for internal usage only
Definition: ScEncodingArray.h:28
Character encoding of a range of bytes.
Definition: ScEncodingArray.h:47
void sc_encoding_array_free(ScEncodingArray array)
Frees the data of the encoding array.
ScEncodingRange sc_encoding_array_get_item_at(ScEncodingArray array, uint32_t i)
Access an encoding range.
uint32_t sc_encoding_array_get_size(ScEncodingArray array)
Get the number of elements in the array.
void sc_encoding_range_free(ScEncodingRange encoding_range)
Frees the data of the encoding range.
uint32_t end
index after the last element in the data
Definition: ScEncodingArray.h:50
uint32_t start
start index in the data
Definition: ScEncodingArray.h:49
ScData encoding
encapsulates a charset encoding name as defined by IANA (http://www.iana.org/assignments/character-se...
Definition: ScEncodingArray.h:48
void sc_data_free(ScData data)
Free the data.
ScEncodingRange sc_encoding_range_new(const char *c_str, uint32_t start, uint32_t end)
Create new ScEncodingRange.
ScEncodingArray sc_encoding_array_new(uint32_t size)
Create new ScEncodingArray with given size.
Common definitions used throughout the ScanditSDK API.
void sc_encoding_array_assign(ScEncodingArray *array, uint32_t pos, const char *encoding, uint32_t start, uint32_t end)
Assigns the value of the element at index pos in the array.
An array of encoding ranges.
Definition: ScEncodingArray.h:88
ScEncodingRange * encodings
array of ranges
Definition: ScEncodingArray.h:89
Represents a binary blob of data, or a string of characters.
Definition: ScEncodingArray.h:22
uint32_t size
number of elements in the array
Definition: ScEncodingArray.h:90