Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance. Project price only 1 $
You can buy this project and download/modify it how often you want.
/*
* Copyright 2015, The Querydsl Team (http://www.querydsl.com/team)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
* http://www.apache.org/licenses/LICENSE-2.0
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package com.querydsl.jdo;
import java.util.*;
import java.util.Map.Entry;
import javax.annotation.Nullable;
import com.google.common.collect.ImmutableList;
import com.google.common.primitives.Primitives;
import com.querydsl.core.JoinExpression;
import com.querydsl.core.QueryMetadata;
import com.querydsl.core.support.SerializerBase;
import com.querydsl.core.types.*;
import com.querydsl.core.types.dsl.Param;
/**
* {@code JDOQLSerializer} serializes Querydsl queries and expressions into JDOQL strings
*
* @author tiwe
*
*/
public final class JDOQLSerializer extends SerializerBase {
private static final String COMMA = ", ";
private static final String FROM = "\nFROM ";
private static final String GROUP_BY = "\nGROUP BY ";
private static final String HAVING = "\nHAVING ";
private static final String ORDER_BY = "\nORDER BY ";
private static final String PARAMETERS = "\nPARAMETERS ";
private static final String RANGE = "\nRANGE ";
private static final String SELECT = "SELECT ";
private static final String SELECT_COUNT = "SELECT count(";
private static final String SELECT_COUNT_THIS = "SELECT count(this)\n";
private static final String SELECT_DISTINCT = "SELECT DISTINCT ";
private static final String SELECT_UNIQUE = "SELECT UNIQUE ";
private static final String THIS = "this";
private static final String VARIABLES = "\nVARIABLES ";
private static final String WHERE = "\nWHERE ";
private static Comparator> comparator = new Comparator>() {
@Override
public int compare(Entry