/ohos5.0/commonlibrary/rust/ylong_json/src/ |
H A D | consts.rs | 15 pub(crate) const COLON: u8 = b':'; 16 pub(crate) const COMMA: u8 = b','; 21 pub(crate) const PLUS: u8 = b'+'; 27 pub(crate) const ONE: u8 = b'1'; 39 [SPACE, HT_UNICODE as u8, LF_UNICODE as u8, CR_UNICODE as u8]; 41 pub(crate) const BS: u8 = b'b'; 44 pub(crate) const HT: u8 = b't'; 47 pub(crate) const FF: u8 = b'f'; 50 pub(crate) const CR: u8 = b'r'; 53 pub(crate) const LF: u8 = b'n'; [all …]
|
/ohos5.0/commonlibrary/rust/ylong_http/ylong_http/src/body/mime/common/ |
H A D | mod.rs | 26 pub(crate) type BytesResult<'a> = Result<TokenStatus<(&'a [u8], &'a [u8]), &'a [u8]>, HttpError>; 38 pub(crate) const SP: u8 = b' '; 40 pub(crate) const CR: u8 = b'\r'; 87 pub(crate) fn trim_front_lwsp(buf: &[u8]) -> &[u8] { in trim_front_lwsp() argument 99 fn trim_back_lwsp(buf: &[u8]) -> &[u8] { in trim_back_lwsp() argument 112 pub(crate) fn trim_back_lwsp_if_end_with_lf(buf: &[u8]) -> &[u8] { in trim_back_lwsp_if_end_with_lf() argument 122 buf: &[u8], in consume_crlf() argument 147 pub(crate) fn get_crlf_contain(buf: &[u8]) -> TokenStatus<(&[u8], &[u8]), &[u8]> { in get_crlf_contain() argument 157 fn trim_ascii_start(mut bytes: &[u8]) -> &[u8] { in trim_ascii_start() argument 171 fn trim_ascii_end(mut bytes: &[u8]) -> &[u8] { in trim_ascii_end() argument [all …]
|
/ohos5.0/commonlibrary/rust/ylong_http/ylong_http/src/h3/ |
H A D | octets.rs | 41 buf: &'a [u8], 55 let bytes: [u8; len] = <[u8; len]>::try_from(self.buf[..len].as_ref()).unwrap(); in into_u8() 57 let res: u8 = u8::from_be_bytes(bytes); in into_u8() 60 let res: u8 = u8::from_le_bytes(bytes); in into_u8() 71 let bytes: [u8; len] = <[u8; len]>::try_from(self.buf[..len].as_ref()).unwrap(); in into_u16() 156 src: &'a [u8], 158 dst: &'a mut [u8], 162 fn new(src: &'a [u8], src_idx: &'a mut usize, dst: &'a mut [u8]) -> Self { in new() argument 180 src: &'a [u8], 182 dst: &'a mut [u8], [all …]
|
/ohos5.0/commonlibrary/rust/ylong_runtime/ylong_runtime/src/io/ |
H A D | read_buf.rs | 41 buf: unsafe { &mut *(buf as *mut [u8] as *mut [MaybeUninit<u8>]) }, in new() 50 buf: &'a mut [MaybeUninit<u8>], in create() argument 99 pub fn filled(&self) -> &[u8] { in filled() argument 100 unsafe { &*(&self.buf[..self.filled] as *const [MaybeUninit<u8>] as *const [u8]) } in filled() 106 unsafe { &mut *(&mut self.buf[..self.filled] as *mut [MaybeUninit<u8>] as *mut [u8]) } in filled_mut() 117 pub fn initialized(&self) -> &[u8] { in initialized() argument 118 unsafe { &*(&self.buf[..self.initialized] as *const [MaybeUninit<u8>] as *const [u8]) } in initialized() 124 unsafe { &mut *(&mut self.buf[..self.initialized] as *mut [MaybeUninit<u8>] as *mut [u8]) } in initialized_mut() 162 unsafe { &mut *(&mut self.buf[self.filled..end] as *mut [MaybeUninit<u8>] as *mut [u8]) } in initialize_unfilled_to() 230 pub fn append(&mut self, buf: &[u8]) { in append() argument [all …]
|
/ohos5.0/commonlibrary/rust/ylong_http/ylong_http/src/h1/response/ |
H A D | decoder.rs | 68 head_key: Vec<u8>, 70 rest: Vec<u8>, 133 type TokenResult<'a> = Result<TokenStatus<(&'a [u8], &'a [u8]), &'a [u8]>, HttpError>; 214 buf: &'a [u8], in decode() argument 229 buffer: &'a [u8], in version_phase() argument 256 buffer: &'a [u8], in status_code_phase() argument 277 buffer: &'a [u8], in reason_phase() argument 288 buffer: &'a [u8], in status_crlf_phase() argument 478 fn take_value(&mut self, value: &[u8]) -> Vec<u8> { in take_value() argument 547 fn decode_reason(buffer: &[u8]) -> Result<Option<&[u8]>, HttpError> { in decode_reason() argument [all …]
|
/ohos5.0/commonlibrary/rust/ylong_http/ylong_http/src/body/ |
H A D | chunk.rs | 131 fn chunk_encode(&mut self, src: &[u8], dst: &mut [u8]) -> usize { in chunk_encode() argument 197 buf: &mut [u8], in poll_partial() argument 271 buf: &mut [u8], in poll_data() argument 297 buf: &mut [u8], in poll_data() argument 402 chunk_buf: Vec<u8>, 615 fn encode(&mut self, src: &[u8], buf: &mut [u8]) -> Token<usize> { in encode() argument 622 src: &'a [u8], 624 dst: &'a mut [u8], 810 data: &'a [u8], 867 trailer: Vec<u8>, [all …]
|
/ohos5.0/commonlibrary/rust/ylong_http/ylong_http/src/h3/qpack/ |
H A D | integer.rs | 24 pub(crate) fn index(pre: u8, index: usize, mask: u8) -> Self { in index() argument 31 int: IntegerEncoder::new(u8::from(is_huffman), length, 0x7f), in length() 56 pub(crate) fn first_byte(byte: u8, mask: u8) -> Result<usize, Self> { in first_byte() argument 87 pre: u8, 89 mask: u8, 102 pub(crate) fn new(pre: u8, i: usize, mask: u8) -> Self { in new() argument 115 pub(crate) fn get_pre(&self) -> u8 { in get_pre() argument 121 pub(crate) fn next_byte(&mut self) -> Option<u8> { in next_byte() argument 126 return Some(self.pre | (self.i as u8)); in next_byte() 133 let res = (self.i & 0x7f) as u8; in next_byte() [all …]
|
/ohos5.0/foundation/distributeddatamgr/relational_store/test/js/relationalstore/unittest/src/ |
H A D | RdbstoreInsertJsunit.test.js | 71 "blobType": u8, 80 "blobType": u8, 89 "blobType": u8, 137 "blobType": u8, 166 "blobType": u8, 203 "blobType": u8, 239 "blobType": u8, 275 "blobType": u8, 480 "blobType": u8, 773 "blobType": u8, [all …]
|
H A D | RdbstoreInsertSyncJsUnit.test.js | 71 "blobType": u8, 80 "blobType": u8, 89 "blobType": u8, 137 "blobType": u8, 163 "blobType": u8, 193 "blobType": u8, 230 "blobType": u8, 268 "blobType": u8, 304 "blobType": u8, 466 "blobType": u8, [all …]
|
H A D | RdbstoreDeleteSyncJsunit.test.js | 67 "blobType": u8, 76 "blobType": u8, 85 "blobType": u8, 114 "blobType": u8, 123 "blobType": u8, 132 "blobType": u8, 163 "blobType": u8, 172 "blobType": u8, 216 "blobType": u8, 225 "blobType": u8, [all …]
|
H A D | RdbStoreTransJsunit.test.js | 48 "blobType": u8, 121 "blobType": u8, 158 "blobType": u8, 195 "blobType": u8, 235 "blobType": u8, 272 "blobType": u8, 309 "blobType": u8, 343 "blobType": u8, 380 "blobType": u8, 417 "blobType": u8, [all …]
|
H A D | RdbstoreDeleteJsunit.test.js | 67 "blobType": u8, 76 "blobType": u8, 85 "blobType": u8, 119 "blobType": u8, 128 "blobType": u8, 137 "blobType": u8, 173 "blobType": u8, 182 "blobType": u8, 231 "blobType": u8, 394 "blobType": u8, [all …]
|
H A D | RdbStoreTransInsertJsunit.test.js | 70 "blobType": u8, 100 "blobType": u8, 130 "blobType": u8, 160 "blobType": u8, 190 "blobType": u8, 220 "blobType": u8, 250 "blobType": u8, 281 "blobType": u8, 312 "blobType": u8, 343 "blobType": u8, [all …]
|
H A D | RdbstoreUpdateJsunit.test.js | 67 "blobType": u8, 81 "blobType": u8, 137 "blobType": u8, 184 "blobType": u8, 222 "blobType": u8, 262 "blobType": u8, 276 "blobType": u8, 317 "blobType": u8, 331 "blobType": u8, 371 "blobType": u8, [all …]
|
H A D | RdbstoreUpdateSyncJsunit.test.js | 67 "blobType": u8, 81 "blobType": u8, 137 "blobType": u8, 184 "blobType": u8, 222 "blobType": u8, 262 "blobType": u8, 276 "blobType": u8, 317 "blobType": u8, 331 "blobType": u8, 371 "blobType": u8, [all …]
|
H A D | RdbStoreDataShareJsunit.test.js | 69 "blobType": u8, 121 "blobType": u8, 125 u8 = new Uint8Array([4, 5, 6]) 130 "blobType": u8, 158 "blobType": u8, 162 u8 = new Uint8Array([4, 5, 6]) 167 "blobType": u8, 197 "blobType": u8, 226 "blobType": u8, 258 "blobType": u8, [all …]
|
H A D | RdbstoreTransactionJsunit.test.js | 67 var u8 = new Uint8Array([1, 2, 3]) 74 "blobType": u8, 111 "blobType": u8, 119 "blobType": u8, 128 "blobType": u8, 165 "blobType": u8, 173 "blobType": u8, 185 "blobType": u8, 216 "blobType": u8, 256 "blobType": u8, [all …]
|
/ohos5.0/base/security/asset/frameworks/utils/src/ |
H A D | hasher.rs | 38 fn expand_chunk(plain_chunk: [u8; BYTES_PER_CHUNK]) -> [u32; BYTES_PER_CHUNK] { 92 fn compress(input_bytes: &[u8]) -> [u32; 8] { in compress() 107 fn pre_process_msg(message: &[u8]) -> Vec<u8> { in pre_process_msg() argument 125 fn into_vec_u8(hash: &[u32; 8]) -> Vec<u8> { 128 ret[i * U8_PER_U32] = ((hash[i] >> 24) & LOWER_BYTES_MASK) as u8; 130 ret[i * U8_PER_U32 + 2] = ((hash[i] >> 8) & LOWER_BYTES_MASK) as u8; 131 ret[i * U8_PER_U32 + 3] = (hash[i] & LOWER_BYTES_MASK) as u8; 138 fn Sha256(input: *const u8, input_len: u32, output: *mut u8); in Sha256() argument 144 fn sha256_new(message: &[u8]) -> Vec<u8> { in sha256_new() argument 151 fn sha256_old(message: &[u8]) -> Vec<u8> { in sha256_old() argument [all …]
|
/ohos5.0/base/security/asset/test/unittest/inner_kits_rust/src/ |
H A D | common.rs | 53 pub(crate) fn remove_by_alias(alias: &[u8]) -> Result<()> { in remove_by_alias() 57 pub(crate) const SECRET: &[u8] = "all_tags_secret".as_bytes(); 58 pub(crate) const NORMAL_LABEL1: &[u8] = "all_tags_normal_label1".as_bytes(); 59 pub(crate) const NORMAL_LABEL2: &[u8] = "all_tags_normal_label2".as_bytes(); 60 pub(crate) const NORMAL_LABEL3: &[u8] = "all_tags_normal_label3".as_bytes(); 61 pub(crate) const NORMAL_LABEL4: &[u8] = "all_tags_normal_label4".as_bytes(); 75 pub(crate) fn query_all_by_alias(alias: &[u8]) -> Result<Vec<AssetMap>> { in query_all_by_alias() 82 pub(crate) fn query_attr_by_alias(alias: &[u8]) -> Result<Vec<AssetMap>> { in query_attr_by_alias() 89 pub(crate) fn add_default_asset(alias: &[u8], secret: &[u8]) -> Result<()> { in add_default_asset() argument 97 pub(crate) fn add_default_auth_asset(alias: &[u8], secret: &[u8]) -> Result<()> { in add_default_auth_asset() argument [all …]
|
/ohos5.0/foundation/distributeddatamgr/relational_store/test/js/rdb/unittest/src/ |
H A D | RdbstoreDeleteJsunit.test.js | 62 "blobType": u8, 71 "blobType": u8, 80 "blobType": u8, 112 "blobType": u8, 121 "blobType": u8, 130 "blobType": u8, 163 "blobType": u8, 172 "blobType": u8, 219 "blobType": u8, 228 "blobType": u8, [all …]
|
H A D | RdbstoreInsertJsunit.test.js | 66 "blobType": u8, 75 "blobType": u8, 194 "blobType": u8, 228 "blobType": u8, 262 "blobType": u8, 295 "blobType": u8, 330 "blobType": u8, 362 "blobType": u8, 368 "blobType": u8, 378 "blobType": u8, [all …]
|
H A D | RdbstoreTransactionJsunit.test.js | 61 var u8 = new Uint8Array([1, 2, 3]) 68 "blobType": u8, 102 "blobType": u8, 110 "blobType": u8, 119 "blobType": u8, 153 "blobType": u8, 161 "blobType": u8, 173 "blobType": u8, 202 "blobType": u8, 236 "blobType": u8, [all …]
|
H A D | RdbstoreUpdateJsunit.test.js | 62 "blobType": u8, 73 "blobType": u8, 122 "blobType": u8, 164 "blobType": u8, 196 "blobType": u8, 233 "blobType": u8, 244 "blobType": u8, 283 "blobType": u8, 294 "blobType": u8, 333 "blobType": u8, [all …]
|
H A D | RdbstoreStoreExcuteSqlJsunit.test.js | 62 "blobType": u8, 72 "blobType": u8, 82 "blobType": u8, 114 "blobType": u8, 124 "blobType": u8, 134 "blobType": u8, 166 "blobType": u8, 176 "blobType": u8, 186 "blobType": u8, 249 "blobType": u8, [all …]
|
/ohos5.0/commonlibrary/rust/ylong_http/ylong_http/src/h2/ |
H A D | encoder.rs | 425 buf: &mut [u8], in iterate_headers_header() argument 571 buf: &mut [u8], in iterate_data_header() argument 695 buf: &mut [u8], in iterate_goaway_header() argument 753 buf: &mut [u8], in iterate_goaway_payload() argument 813 buf: &mut [u8], in iterate_window_update_header() argument 912 buf: &mut [u8], in iterate_settings_header() argument 971 buf: &mut [u8], in iterate_settings_payload() argument 1036 buf: &mut [u8], in iterate_priority_header() argument 1095 buf: &mut [u8], in iterate_priority_payload() argument 1235 buf: &mut [u8], in iterate_ping_header() argument [all …]
|