Examples of StringType


Examples of com.asakusafw.dmdl.thundergate.model.StringType

            .add(null, "TYPE_SHORT", PropertyTypeKind.SHORT)
            .add(null, "TYPE_INT", PropertyTypeKind.INT)
            .add(null, "TYPE_LONG", PropertyTypeKind.LONG)
            .add(null, "TYPE_DATE", PropertyTypeKind.DATE)
            .add(null, "TYPE_DATETIME", PropertyTypeKind.DATETIME)
            .add(null, "TYPE_TEXT", new StringType(255))
            .add(null, "TYPE_DECIMAL", new DecimalType(10, 10))
            .toDescription();
        emitDmdl(RecordModelGenerator.generate(table));

        ModelLoader loader = generateJava();
View Full Code Here

Examples of com.asakusafw.dmdl.thundergate.model.StringType

     */
    @Test
    public void primary_keys() {
        TableModelDescription table = new TableModelBuilder("SIMPLE")
            .add("SID", "SID", PropertyTypeKind.LONG, Attribute.PRIMARY_KEY)
            .add("comment", "VALUE", new StringType(255))
            .toDescription();
        emitDmdl(RecordModelGenerator.generate(table));

        ModelLoader loader = generateJava();
        loader.setNamespace(Constants.SOURCE_TABLE);
View Full Code Here

Examples of com.asakusafw.dmdl.thundergate.model.StringType

                case BIG_DECIMAL:
                    DecimalType decimalType = new DecimalType(numericPrecision, numericScale);
                    builder.add(columnComment, columnName, decimalType, attributes);
                    break;
                case STRING:
                    StringType stringType = new StringType((int) characterMaximumLength);
                    builder.add(columnComment, columnName, stringType, attributes);
                    break;
                default:
                    builder.add(columnComment, columnName, propertyType, attributes);
                    break;
View Full Code Here

Examples of com.asakusafw.modelgen.model.StringType

                case BIG_DECIMAL:
                    DecimalType decimalType = new DecimalType(numericPrecision, numericScale);
                    builder.add(columnComment, columnName, decimalType, attributes);
                    break;
                case STRING:
                    StringType stringType = new StringType((int) characterMaximumLength);
                    builder.add(columnComment, columnName, stringType, attributes);
                    break;
                default:
                    builder.add(columnComment, columnName, propertyType, attributes);
                    break;
View Full Code Here

Examples of com.asakusafw.modelgen.model.StringType

     */
    @Test
    public void simple() throws Throwable {
        TableModelDescription a = new TableModelBuilder("A")
            .add(null, "id", PropertyTypeKind.LONG)
            .add(null, "hoge", new StringType(255))
            .toDescription();
        TableModelDescription b = new TableModelBuilder("B")
            .add(null, "id", PropertyTypeKind.LONG)
            .add(null, "foo", new StringType(255))
            .toDescription();
        JoinedModelDescription j = new JoinedModelBuilder("J", a, "a", b, "b")
            .on("a.id", "b.id")
            .add("id", "a.id")
            .add("hoge", "a.hoge")
View Full Code Here

Examples of com.asakusafw.modelgen.model.StringType

    public void complex() throws Throwable {
        init("complex");

        TableModelDescription model = new TableModelBuilder("Model")
            .add(null, "id", PropertyTypeKind.LONG, Attribute.PRIMARY_KEY)
            .add(null, "value", new StringType(255))
            .add(null, "date", PropertyTypeKind.DATE)
            .add(null, "price", PropertyTypeKind.INT)
            .add(null, "flag", PropertyTypeKind.BOOLEAN)
            .toDescription();
View Full Code Here

Examples of com.asakusafw.modelgen.model.StringType

     */
    @Test
    public void simple() throws Throwable {
        TableModelDescription model = new TableModelBuilder("Hello")
            .add(null, "id", PropertyTypeKind.LONG, Attribute.PRIMARY_KEY)
            .add(null, "value", new StringType(255))
            .toDescription();

        new Table().emit(model);

        ClassLoader loader = compile();
View Full Code Here

Examples of com.asakusafw.modelgen.model.StringType

     */
    @Test
    public void writable() throws Throwable {
        TableModelDescription model = new TableModelBuilder("Hello")
            .add(null, "id", PropertyTypeKind.LONG, Attribute.PRIMARY_KEY)
            .add(null, "value", new StringType(255))
            .add(null, "nothing", new StringType(255))
            .toDescription();

        new Table().emit(model);

        ClassLoader loader = compile();
View Full Code Here

Examples of com.asakusafw.modelgen.model.StringType

    @Test
    public void namespace() throws Throwable {
        TableModelDescription model = new TableModelBuilder("Hello")
            .namespace("testing", "table")
            .add(null, "id", PropertyTypeKind.LONG, Attribute.PRIMARY_KEY)
            .add(null, "value", new StringType(255))
            .toDescription();

        new Table().emit(model);

        ClassLoader loader = compile();
View Full Code Here

Examples of com.asakusafw.modelgen.model.StringType

     */
    @Test
    public void complex() throws Throwable {
        TableModelDescription model = new TableModelBuilder("Model")
            .add(null, "id", PropertyTypeKind.LONG, Attribute.PRIMARY_KEY)
            .add(null, "value", new StringType(255))
            .add(null, "date", PropertyTypeKind.DATE)
            .add(null, "price", PropertyTypeKind.INT)
            .add(null, "flag", PropertyTypeKind.BOOLEAN)
            .toDescription();

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.