Home
last modified time | relevance | path

Searched refs:tnf (Results 1 - 5 of 5) sorted by relevance

/foundation/communication/nfc/test/fuzztest/tags_test/ndefmessage/ndefmessage_fuzzer/
H A Dndefmessage_fuzzer.cpp37 bool CheckTnf(short tnf, const std::string& tagRtdType, const std::string& id, const std::string& payload) in CheckTnf() argument
39 switch (tnf) { in CheckTnf()
64 std::shared_ptr<NdefRecord> CreateNdefRecord(short tnf, in CreateNdefRecord() argument
69 bool isValidTnf = OHOS::CheckTnf(tnf, tagRtdType, id, payload); in CreateNdefRecord()
74 ndefRecord->tnf_ = tnf; in CreateNdefRecord()
86 short tnf = static_cast<short>(data[0] % OHOS::MAX_TNF_NUMS); in FuzzGetNdefMessageByNdefRecord() local
95 std::shared_ptr<NdefRecord> ndefRecord = CreateNdefRecord(tnf, id, payload, tagRtdType); in FuzzGetNdefMessageByNdefRecord()
151 short tnf = static_cast<short>(data[0] % OHOS::MAX_TNF_NUMS); in FuzzMessageToString() local
160 std::shared_ptr<NdefRecord> ndefRecord = CreateNdefRecord(tnf, id, payload, tagRtdType); in FuzzMessageToString()
171 short tnf in FuzzNdefRecordToString() local
191 short tnf = static_cast<short>(data[0] % OHOS::MAX_TNF_NUMS); FuzzGetNdefRecords() local
[all...]
/foundation/communication/nfc/test/fuzztest/tags_test/ndeftag/ndeftag_fuzzer/
H A Dndeftag_fuzzer.cpp52 bool CheckTnf(short tnf, const std::string& tagRtdType, const std::string& id, const std::string& payload) in CheckTnf() argument
54 switch (tnf) { in CheckTnf()
79 std::shared_ptr<NdefRecord> CreateNdefRecord(short tnf, in CreateNdefRecord() argument
84 bool isValidTnf = OHOS::CheckTnf(tnf, tagRtdType, id, payload); in CreateNdefRecord()
89 ndefRecord->tnf_ = tnf; in CreateNdefRecord()
164 short tnf = static_cast<short>(data[0] % OHOS::MAX_TNF_NUMS); in FuzzReadNdef() local
173 std::shared_ptr<NdefRecord> ndefRecord = CreateNdefRecord(tnf, id, payload, tagRtdType); in FuzzReadNdef()
188 short tnf = static_cast<short>(data[0] % OHOS::MAX_TNF_NUMS); in FuzzWriteNdef() local
197 std::shared_ptr<NdefRecord> ndefRecord = CreateNdefRecord(tnf, id, payload, tagRtdType); in FuzzWriteNdef()
/foundation/communication/nfc/interfaces/inner_api/common/
H A Dndef_message.cpp188 uint32_t tnf = record.lock()->tnf_; in NdefRecordToString() local
192 bool il = (tnf == TNF_EMPTY) ? true : (NfcSdkCommon::GetHexStrBytesLen(id) > 0); in NdefRecordToString()
194 | (sr ? FLAG_SR : 0) | (il ? FLAG_IL : 0)) | (char)tnf; in NdefRecordToString()
218 layout.tnf = static_cast<short>(head & FLAG_TNF); in ParseRecordLayoutHead()
236 } else if (isChunkFound && layout.tnf != TNF_UNCHANGED) { in IsInvalidRecordLayoutHead()
237 ErrorLog("IsInvalidRecordLayoutHead, 5th error for tnf"); in IsInvalidRecordLayoutHead()
239 } else if (!isChunkFound && layout.tnf == TNF_UNCHANGED) { in IsInvalidRecordLayoutHead()
240 ErrorLog("IsInvalidRecordLayoutHead, 6th error for tnf"); in IsInvalidRecordLayoutHead()
278 if (layout.typeLength == 0 && layout.tnf != TNF_UNKNOWN) { in IsRecordLayoutLengthInvalid()
279 ErrorLog("IsInvalidRecordLayoutHead, 2nd error for typeLength and tnf"); in IsRecordLayoutLengthInvalid()
369 CreateNdefRecord(short tnf, const std::string& id, const std::string& payload, const std::string& tagRtdType) CreateNdefRecord() argument
385 CheckTnf(short tnf, const std::string& tagRtdType, const std::string& id, const std::string& payload) CheckTnf() argument
[all...]
H A Dndef_message.h40 short tnf; // type name format member
205 static std::shared_ptr<NdefRecord> CreateNdefRecord(short tnf, const std::string& id,
207 static bool CheckTnf(short tnf, const std::string& tagRtdType,
/foundation/communication/nfc/frameworks/js/napi/common/
H A Dnfc_napi_common_utils.cpp439 napi_value tnf; in ConvertAirTouchNdefRecordToJS() local
440 napi_create_int32(env, ndefRecord->tnf_, &tnf); in ConvertAirTouchNdefRecordToJS()
441 napi_set_named_property(env, result, "tnf", tnf); in ConvertAirTouchNdefRecordToJS()
486 napi_value tnf; in ConvertNdefRecordToJS() local
487 napi_create_int32(env, ndefRecord->tnf_, &tnf); in ConvertNdefRecordToJS()
488 napi_set_named_property(env, result, "tnf", tnf); in ConvertNdefRecordToJS()

Completed in 4 milliseconds