aboutsummaryrefslogtreecommitdiffstats
path: root/Plugins/SqlEnterpriseFormatter/formatorderby.cpp
blob: d7b2defa71b99a5f33f5e146c818d387e2e60a41 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
#include "formatorderby.h"
#include "parser/ast/sqliteorderby.h"
#include "parser/ast/sqliteexpr.h"

FormatOrderBy::FormatOrderBy(SqliteOrderBy* orderBy) :
    orderBy(orderBy)
{
}

void FormatOrderBy::formatInternal()
{
    withStatement(orderBy->expr);
    if (orderBy->order != SqliteSortOrder::null)
        withKeyword(sqliteSortOrder(orderBy->order));
}