Package org.datanucleus.store.mapped.expression

Examples of org.datanucleus.store.mapped.expression.NullLiteral


            if (allowNulls)
            {
                // Allow for null value of discriminator
                ScalarExpression expr = discriminatorMapping.newScalarExpression(stmt, discrimTableExpr);
                ScalarExpression val = new NullLiteral(stmt);
                BooleanExpression nullDiscExpr = expr.eq(val);
                discExpr = discExpr.ior(nullDiscExpr);
                if (!multipleDiscriminatorValues)
                {
                    multipleDiscriminatorValues = true;
View Full Code Here


                 * WHERE THIS.ELEM_ID IS NULL
                 */
                QueryExpression nullStmt = getQueryForElement(candidateFullClassName,
                    storeMgr.getDatastoreClass(candidateFullClassName, clr), true, candidateAlias);
                ScalarExpression elemIdExpr = sourceMapping.newScalarExpression(nullStmt, nullStmt.getMainTableExpression());
                nullStmt.andCondition(new NullLiteral(nullStmt).eq(elemIdExpr));
                stmt.union(nullStmt);
            }

            return stmt;
        }
View Full Code Here

                    ScalarExpression targetElementExpr =
                        targetElementMapping.newScalarExpression(stmt, stmt.getMainTableExpression());
                    targetSubElementTypeExpr = targetMapping.newScalarExpression(stmt, teTargetSubElementType);
                    stmt.leftOuterJoin(targetElementExpr,targetSubElementTypeExpr, teTargetSubElementType, true);
                    ScalarExpression seTargetSubElementType = targetMapping.newScalarExpression(targetQS, teTargetSubElementType);
                    stmt.andCondition(new NullLiteral(stmt).eq(seTargetSubElementType));
                }
            }
        }
    }
View Full Code Here

        if ((withMetadata == null && hasSubClasses) ||
            (withMetadata != null && withMetadata.booleanValue()))
        {
            if (allowNull)
            {
                NullLiteral nullLtl = new NullLiteral(stmt);
                nullLtl.as(MetaDataStringLiteral.QUERY_META_DATA);
                stmt.selectScalarExpression(nullLtl);
            }
            else
            {
                String classname = pcClass;
View Full Code Here

    {
    }
   
    public ScalarExpression newLiteral(QueryExpression qs, Object value)
    {
        return new NullLiteral(qs);
    }
View Full Code Here

        return new NullLiteral(qs);
    }

    public ScalarExpression newScalarExpression(QueryExpression qs, LogicSetExpression te)
    {
        return new NullLiteral(qs);
    }
View Full Code Here

TOP

Related Classes of org.datanucleus.store.mapped.expression.NullLiteral

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.