Skip to content

Commit

Permalink
Remove unnecessary method
Browse files Browse the repository at this point in the history
  • Loading branch information
Andrew Or committed May 12, 2016
1 parent d4b5a32 commit bc2a7bd
Showing 1 changed file with 3 additions and 8 deletions.
Expand Up @@ -951,7 +951,9 @@ class SparkSqlAstBuilder(conf: SQLConf) extends AstBuilder {
rowFormatCtx: RowFormatContext,
createFileFormatCtx: CreateFileFormatContext,
parentCtx: ParserRuleContext): Unit = {
val cff = createFileFormatContextString(createFileFormatCtx)
val cff = (0 until createFileFormatCtx.getChildCount)
.map { i => createFileFormatCtx.getChild(i).getText }
.mkString(" ")
(rowFormatCtx, createFileFormatCtx.fileFormat) match {
case (rf, null) => // only row format, no conflict
case (null, ff) => // only file format, no conflict
Expand All @@ -977,13 +979,6 @@ class SparkSqlAstBuilder(conf: SQLConf) extends AstBuilder {
}
}

/**
* Helper method to convert a [[CreateFileFormatContext]] to a human-readable form.
*/
private def createFileFormatContextString(ctx: CreateFileFormatContext): String = {
(0 until ctx.getChildCount).map { i => ctx.getChild(i).getText }.mkString(" ")
}

/**
* Create or replace a view. This creates a [[CreateViewCommand]] command.
*
Expand Down

0 comments on commit bc2a7bd

Please sign in to comment.