Examples of SeparatedStringBuilder


Examples of com.laamella.queryprutser.common.SeparatedStringBuilder

    add("ON " + joinOn);
    return this;
  }

  public FromClause using(final String... columns) {
    add(new SeparatedStringBuilder("USING (", ", ", ")").add(columns).toCharSequence());
    return this;
  }
View Full Code Here

Examples of com.laamella.queryprutser.common.SeparatedStringBuilder

    return subquery;
  }

  @Override
  public String toString() {
    final SeparatedStringBuilder locallCopy = new SeparatedStringBuilder(this);
    for (final Subquery builder : subqueries) {
      locallCopy.add(" " + builder.queryText() + " ");
    }
    return locallCopy.toString();
  }
View Full Code Here

Examples of com.laamella.queryprutser.common.SeparatedStringBuilder

    return subselect(rootClass, null);
  }

  @Override
  public String toString() {
    final SeparatedStringBuilder locallCopy = new SeparatedStringBuilder(this);
    for (final Subquery<?> builder : subqueries) {
      locallCopy.add(" " + builder.queryText() + " ");
    }
    return locallCopy.toString();
  }
View Full Code Here

Examples of com.laamella.queryprutser.common.SeparatedStringBuilder

public class SeparatedStringBuilderTest {

  @Test
  public void whenNotAppendingAnythingThenResultIsEmpty() {
    final SeparatedStringBuilder string = new SeparatedStringBuilder("pre", "in", "post");
    assertEquals("", string.toString());
  }
View Full Code Here

Examples of com.laamella.queryprutser.common.SeparatedStringBuilder

    assertEquals("", string.toString());
  }

  @Test
  public void whenAppendingOneThingThenPreAndPostfixAreAdded() {
    final SeparatedStringBuilder string = new SeparatedStringBuilder("pre", "in", "post");
    string.add("text");
    assertEquals("pretextpost", string.toString());
  }
View Full Code Here

Examples of com.laamella.queryprutser.common.SeparatedStringBuilder

    assertEquals("pretextpost", string.toString());
  }

  @Test
  public void whenAppendingSeveralThingsThenPreInAndPostfixAreAdded() {
    final SeparatedStringBuilder string = new SeparatedStringBuilder("pre", "in", "post");
    string.add("text1", "text2", "text3");
    assertEquals("pretext1intext2intext3post", string.toString());
  }
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.