@@ -2410,6 +2410,10 @@ void to_json(json& j, const std::shared_ptr<ExecutionWriterTarget>& p) {
2410
2410
j = *std::static_pointer_cast<CreateHandle>(p);
2411
2411
return ;
2412
2412
}
2413
+ if (type == " RefreshMaterializedViewHandle" ) {
2414
+ j = *std::static_pointer_cast<InsertHandle>(p);
2415
+ return ;
2416
+ }
2413
2417
if (type == " InsertHandle" ) {
2414
2418
j = *std::static_pointer_cast<InsertHandle>(p);
2415
2419
return ;
@@ -2418,10 +2422,6 @@ void to_json(json& j, const std::shared_ptr<ExecutionWriterTarget>& p) {
2418
2422
j = *std::static_pointer_cast<DeleteHandle>(p);
2419
2423
return ;
2420
2424
}
2421
- if (type == "RefreshMaterializedViewHandle") {
2422
- j = *std::static_pointer_cast<RefreshMaterializedViewHandle>(p);
2423
- return;
2424
- }
2425
2425
2426
2426
throw TypeError (type + " no abstract type ExecutionWriterTarget " );
2427
2427
}
@@ -2442,21 +2442,20 @@ void from_json(const json& j, std::shared_ptr<ExecutionWriterTarget>& p) {
2442
2442
p = std::static_pointer_cast<ExecutionWriterTarget>(k);
2443
2443
return ;
2444
2444
}
2445
- if (type == "InsertHandle ") {
2445
+ if (type == " RefreshMaterializedViewHandle " ) {
2446
2446
std::shared_ptr<InsertHandle> k = std::make_shared<InsertHandle>();
2447
2447
j.get_to (*k);
2448
2448
p = std::static_pointer_cast<ExecutionWriterTarget>(k);
2449
2449
return ;
2450
2450
}
2451
- if (type == "DeleteHandle ") {
2452
- std::shared_ptr<DeleteHandle > k = std::make_shared<DeleteHandle >();
2451
+ if (type == " InsertHandle " ) {
2452
+ std::shared_ptr<InsertHandle > k = std::make_shared<InsertHandle >();
2453
2453
j.get_to (*k);
2454
2454
p = std::static_pointer_cast<ExecutionWriterTarget>(k);
2455
2455
return ;
2456
2456
}
2457
- if (type == "RefreshMaterializedViewHandle") {
2458
- std::shared_ptr<RefreshMaterializedViewHandle> k =
2459
- std::make_shared<RefreshMaterializedViewHandle>();
2457
+ if (type == " DeleteHandle" ) {
2458
+ std::shared_ptr<DeleteHandle> k = std::make_shared<DeleteHandle>();
2460
2459
j.get_to (*k);
2461
2460
p = std::static_pointer_cast<ExecutionWriterTarget>(k);
2462
2461
return ;
@@ -8461,13 +8460,9 @@ void from_json(const json& j, Range& p) {
8461
8460
}
8462
8461
} // namespace facebook::presto::protocol
8463
8462
namespace facebook ::presto::protocol {
8464
- RefreshMaterializedViewHandle::RefreshMaterializedViewHandle() noexcept {
8465
- _type = "RefreshMaterializedViewHandle";
8466
- }
8467
8463
8468
8464
void to_json (json& j, const RefreshMaterializedViewHandle& p) {
8469
8465
j = json::object ();
8470
- j["@type"] = "RefreshMaterializedViewHandle";
8471
8466
to_json_key (
8472
8467
j,
8473
8468
" handle" ,
@@ -8485,7 +8480,6 @@ void to_json(json& j, const RefreshMaterializedViewHandle& p) {
8485
8480
}
8486
8481
8487
8482
void from_json (const json& j, RefreshMaterializedViewHandle& p) {
8488
- p._type = j["@type"];
8489
8483
from_json_key (
8490
8484
j,
8491
8485
" handle" ,
0 commit comments