Skip to content

Commit

Permalink
Refactor KernelDistSQLStatementVisitor (#33756)
Browse files Browse the repository at this point in the history
* Refactor usage of VariableSegment

* Refactor KernelDistSQLStatementVisitor
  • Loading branch information
terrymanu authored Nov 21, 2024
1 parent fbbbd85 commit 4633f9d
Showing 1 changed file with 1 addition and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,7 @@ public ASTNode visitImportDatabaseConfiguration(final ImportDatabaseConfiguratio

@Override
public ASTNode visitImportMetaData(final ImportMetaDataContext ctx) {
return new ImportMetaDataStatement(null == ctx.metaDataValue() ? null : getQuotedContent(ctx.metaDataValue()), getIdentifierValue(ctx.filePath()));
return new ImportMetaDataStatement(null == ctx.metaDataValue() ? null : QuoteCharacter.unwrapText(ctx.metaDataValue().getText()), getIdentifierValue(ctx.filePath()));
}

@Override
Expand Down Expand Up @@ -338,10 +338,6 @@ private String getIdentifierValue(final ParseTree context) {
return null == context ? null : new IdentifierValue(context.getText()).getValue();
}

private String getQuotedContent(final ParseTree context) {
return IdentifierValue.getQuotedContent(context.getText());
}

@Override
public ASTNode visitShowPluginImplementations(final ShowPluginImplementationsContext ctx) {
return new ShowPluginsStatement("COMMON", getIdentifierValue(ctx.pluginClass()));
Expand Down

0 comments on commit 4633f9d

Please sign in to comment.