Home
last modified time | relevance | path

Searched refs:SchemaType (Results 1 – 21 of 21) sorted by relevance

/ohos5.0/foundation/distributeddatamgr/kv_store/frameworks/libs/distributeddb/common/include/
H A Dischema.h26 enum class SchemaType : uint8_t { enum
34 inline SchemaType ReadSchemaType(uint8_t inType) in ReadSchemaType()
36 if (inType >= static_cast<uint8_t>(SchemaType::UNRECOGNIZED)) { in ReadSchemaType()
37 return SchemaType::UNRECOGNIZED; in ReadSchemaType()
39 return static_cast<SchemaType>(inType); in ReadSchemaType()
57 virtual SchemaType GetSchemaType() const = 0;
H A Dschema_object.h45 static std::string GetExtractFuncName(SchemaType inSchemaType);
46 …static std::string GenerateExtractSQL(SchemaType inSchemaType, const FieldPath &inFieldpath, Field…
66 SchemaType GetSchemaType() const override;
199 SchemaType schemaType_ = SchemaType::NONE; // Default NONE
H A Dschema_utils.h49 static std::string SchemaTypeString(SchemaType inType);
/ohos5.0/foundation/distributeddatamgr/kv_store/frameworks/libs/distributeddb/common/src/
H A Dschema_negotiate.cpp31SchemaType localType = localSchema.GetSchemaType(); // An invalid schemaObject will return SchemaT… in MakeLocalSyncOpinion()
32 SchemaType remoteType = ReadSchemaType(remoteSchemaType); in MakeLocalSyncOpinion()
35 if (remoteType == SchemaType::UNRECOGNIZED) { in MakeLocalSyncOpinion()
40 if (localType == SchemaType::NONE) { in MakeLocalSyncOpinion()
45 if (remoteType == SchemaType::NONE) { in MakeLocalSyncOpinion()
129 SchemaType localType = localSchema.GetSchemaType(); in MakeLocalSyncOpinion()
130 SchemaType remoteType = ReadSchemaType(remoteSchemaType); in MakeLocalSyncOpinion()
131 if (remoteType == SchemaType::UNRECOGNIZED) { in MakeLocalSyncOpinion()
136 if (remoteType != SchemaType::RELATIVE) { in MakeLocalSyncOpinion()
H A Dschema_object.cpp47 std::string SchemaObject::GetExtractFuncName(SchemaType inSchemaType) in GetExtractFuncName()
49 if (inSchemaType == SchemaType::JSON) { in GetExtractFuncName()
121 schemaType_ = SchemaType::NONE; // Default NONE in SchemaObject()
135 SchemaType estimateType = SchemaType::JSON; // Estimate as JSON type firstly in ParseFromSchemaString()
138 estimateType = SchemaType::FLATBUFFER; in ParseFromSchemaString()
148 if (estimateType == SchemaType::FLATBUFFER) { in ParseFromSchemaString()
154 schemaType_ = SchemaType::FLATBUFFER; in ParseFromSchemaString()
157 DisplaySchemaLineByLine(SchemaType::JSON, oriSchema); in ParseFromSchemaString()
168 schemaType_ = SchemaType::JSON; in ParseFromSchemaString()
181 SchemaType SchemaObject::GetSchemaType() const in GetSchemaType()
[all …]
H A Dschema_utils.cpp483 std::string SchemaUtils::SchemaTypeString(SchemaType inType) in SchemaTypeString()
485 static std::map<SchemaType, std::string> schemaTypeMapString { in SchemaTypeString()
486 {SchemaType::NONE, "NONE"}, in SchemaTypeString()
487 {SchemaType::JSON, "JSON-SCHEMA"}, in SchemaTypeString()
488 {SchemaType::FLATBUFFER, "FLATBUFFER-SCHEMA"}, in SchemaTypeString()
489 {SchemaType::RELATIVE, "RELATIVE"}, in SchemaTypeString()
490 {SchemaType::UNRECOGNIZED, "UNRECOGNIZED"}, in SchemaTypeString()
H A Dflatbuffer_schema.cpp975 owner_.schemaType_ = SchemaType::FLATBUFFER; // For fix compile warning in ParseFlatBufferSchema()
/ohos5.0/foundation/distributeddatamgr/kv_store/frameworks/libs/distributeddb/common/include/relational/
H A Drelational_schema_object.h35 SchemaType GetSchemaType() const override;
114 SchemaType schemaType_ = SchemaType::RELATIVE; // Default RELATIVE
/ohos5.0/foundation/distributeddatamgr/kv_store/frameworks/libs/distributeddb/test/unittest/common/common/
H A Ddistributeddb_relational_schema_object_test.cpp307 static_cast<uint8_t>(SchemaType::RELATIVE));
502 static_cast<uint8_t>(SchemaType::RELATIVE));
522 static_cast<uint8_t>(SchemaType::RELATIVE));
542 static_cast<uint8_t>(SchemaType::RELATIVE));
560 static_cast<uint8_t>(SchemaType::RELATIVE));
579 static_cast<uint8_t>(SchemaType::RELATIVE));
H A Ddistributeddb_schema_object_test.cpp1105 std::string str1 = schema.GetExtractFuncName(SchemaType::NONE);
1114 …std::string str2 = schema.GenerateExtractSQL(SchemaType::JSON, inFieldpath1, FieldType::LEAF_FIELD…
1126 …str2 = schema.GenerateExtractSQL(SchemaType::JSON, inFieldpath2, FieldType::LEAF_FIELD_NULL, 0, ""…
/ohos5.0/foundation/distributeddatamgr/kv_store/frameworks/libs/distributeddb/storage/src/sqlite/
H A Dsqlite_single_ver_natural_store_extend.cpp333 …if (localSchema.GetSchemaType() != SchemaType::NONE && localSchema.GetSchemaType() != SchemaType::… in CheckAndInitQueryCondition()
454 …if (localSchema.GetSchemaType() != SchemaType::NONE && localSchema.GetSchemaType() != SchemaType::… in IsSupportSubscribe()
H A Dsqlite_single_ver_schema_database_upgrader.cpp150 if (context->schema.GetSchemaType() == SchemaType::JSON) { in CheckValueOrGetAmendValue()
205 SchemaType theType = newSchema_.GetSchemaType(); in UpgradeIndexes()
H A Dsqlite_utils.h121 …static int IncreaseIndex(sqlite3 *db, const IndexName &name, const IndexInfo &info, SchemaType typ…
124 … static int ChangeIndex(sqlite3 *db, const IndexName &name, const IndexInfo &info, SchemaType type,
H A Dsqlite_utils.cpp1298 …iteUtils::IncreaseIndex(sqlite3 *db, const IndexName &name, const IndexInfo &info, SchemaType type, in IncreaseIndex()
1327 int SQLiteUtils::ChangeIndex(sqlite3 *db, const IndexName &name, const IndexInfo &info, SchemaType in ChangeIndex()
1722 …if (heapSchemaObj->GetSchemaType() != SchemaType::FLATBUFFER) { // Do not need to register FlatBuf… in RegisterFlatBufferFunction()
1727 …errCode = sqlite3_create_function_v2(db, SchemaObject::GetExtractFuncName(SchemaType::FLATBUFFER).… in RegisterFlatBufferFunction()
1946 (schema->GetSchemaType() != SchemaType::FLATBUFFER)) { // LCOV_EXCL_BR_LINE in FlatBufferExtractByPath()
H A Dsqlite_single_ver_natural_store.cpp309 if (schemaObjRef.GetSchemaType() == SchemaType::JSON) { // LCOV_EXCL_BR_LINE in CheckValueAndAmendIfNeed()
1571 … if (!localSchema.IsSchemaValid() || schema.empty() || ReadSchemaType(type) == SchemaType::NONE) { in CheckCompatible()
1989 if (schemaType != SchemaType::NONE) { in CheckSchemaSupportForCloudSync()
/ohos5.0/foundation/distributeddatamgr/kv_store/frameworks/libs/distributeddb/syncer/src/device/
H A Dability_sync.cpp1350 bool AbilitySync::IsBothKvAndOptAbilitySync(uint32_t remoteVersion, SchemaType localType, uint8_t r… in IsBothKvAndOptAbilitySync()
1352 return remoteVersion >= SOFTWARE_VERSION_RELEASE_8_0 && localType == SchemaType::NONE && in IsBothKvAndOptAbilitySync()
1353 static_cast<SchemaType>(remoteType) == SchemaType::NONE; in IsBothKvAndOptAbilitySync()
H A Dability_sync.h263 …static bool IsBothKvAndOptAbilitySync(uint32_t remoteVersion, SchemaType localType, uint8_t remote…
/ohos5.0/foundation/distributeddatamgr/kv_store/frameworks/libs/distributeddb/common/src/relational/
H A Drelational_schema_object.cpp31 SchemaType RelationalSchemaObject::GetSchemaType() const in GetSchemaType()
64 schemaType_ = SchemaType::RELATIVE; in ParseFromSchemaString()
568 schemaType_ = SchemaType::RELATIVE; in ParseCheckSchemaType()
/ohos5.0/foundation/distributeddatamgr/kv_store/frameworks/libs/distributeddb/test/unittest/common/syncer/
H A Ddistributeddb_ability_sync_test.cpp594 packet.SetSchemaType(static_cast<uint32_t>(SchemaType::RELATIVE));
H A Dvirtual_single_ver_sync_db_Interface.cpp161 if (schema_.empty() && schema.empty() && ReadSchemaType(type) != SchemaType::UNRECOGNIZED) { in CheckCompatible()
/ohos5.0/foundation/distributeddatamgr/kv_store/frameworks/libs/distributeddb/storage/src/relational/
H A Drelational_sync_able_storage.cpp857 return !schema.empty() && ReadSchemaType(type) == SchemaType::RELATIVE; in CheckCompatible()
932 if (ReadSchemaType(type) != SchemaType::RELATIVE) { in SaveRemoteDeviceSchema()