Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
 /*
  * Copyright 2015-2015 Amazon Technologies, Inc.
  *
  * 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://aws.amazon.com/apache2.0
  *
 * This file 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.amazonaws.services.dynamodbv2.xspec;
Represents a Function condition in building condition expression.

Underlying grammar:

 function ::=
    attribute_exists (path)
  | attribute_not_exists (path)
  | begins_with (path, operand)
  | contains (path, operand)
 

This object is as immutable (or unmodifiable) as the underlying operand.

public final class FunctionCondition extends Condition {
    private final String functionId;
    private final PathOperand pathOperand;
    private final Operand operand;
    FunctionCondition(String functionIdPathOperand attribute) {
        this. = functionId;
        this. = attribute;
        this. = null;
    }
    FunctionCondition(String functionIdPathOperand attributeOperand operand) {
        this. = functionId;
        this. = attribute;
        this. = operand;
    }
    @Override
        StringBuilder sb = new StringBuilder().append("(").append(
                .asSubstituted(context));
        if ( != null)
            sb.append(", ").append(.asSubstituted(context));
        return sb.append(")").toString();
    }
    String getFunctionId() {
        return ;
    }
        return ;
    }
    Operand getOperand() {
        return ;
    }
    @Override
    boolean atomic() {
        return true;
    }
    @Override
    int precedence() {
        return ..value();
    }
New to GrepCode? Check out our FAQ X