Examples of KSPropDefs


Examples of org.apache.cassandra.cql3.statements.KSPropDefs

        read(end);
        return false;
    }

    private KSPropDefs parseKSPropDefs() {
        KSPropDefs defs = new KSPropDefs();
        try {
            read("WITH");
            do {
                String name = readUniqueIdentifier().toLowerCase(Locale.US);
                read("=");
                if (readIf("{")) {
                    defs.addProperty(name, parseMap());
                } else {
                    Expression value = readExpression();
                    defs.addProperty(name, value.optimize(session).getValue(session).toString());
                }
            } while (readIf("AND"));

            defs.validate();
        } catch (SyntaxException e) {
            throw getSyntaxError();
        }
        return defs;
    }
View Full Code Here

Examples of org.apache.cassandra.cql3.statements.KSPropDefs

        if (readIf("AUTHORIZATION")) {
            command.setAuthorization(readUniqueIdentifier());
        } else {
            command.setAuthorization(session.getUser().getName());
        }
        KSPropDefs defs = parseKSPropDefs();
        command.setKSPropDefs(defs);
        return command;
    }
View Full Code Here

Examples of org.apache.cassandra.cql3.statements.KSPropDefs

    protected Prepared parseAlterKeyspace() {
        AlterKeyspace command = new AlterKeyspace(session);
        command.setKeyspaceName(readUniqueIdentifier());

        KSPropDefs defs = parseKSPropDefs();
        command.setKSPropDefs(defs);
        command.validate();
        return command;
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.