モジュール org.nkjmlab.sorm4j

クラス SelectSql.Builder

  • 含まれているクラス:
    SelectSql

    public static class SelectSql.Builder
    extends Object
    • メソッドの詳細

      • build

        public String build()
        Creates a select SQL statement from the objects.
        戻り値:
      • from

        public SelectSql.Builder from​(String table)
        Creates from clause.

         from("player") returns "from player"
         
        パラメータ:
        table -
        戻り値:
      • groupBy

        public SelectSql.Builder groupBy​(String... columns)
        Creates group by clause.
        パラメータ:
        columns -
        戻り値:
      • having

        public SelectSql.Builder having​(String expr)
        Creates having clause.
        パラメータ:
        expr -
        戻り値:
      • limit

        public SelectSql.Builder limit​(int limit)
        Creates limit clause.
        パラメータ:
        limit -
        戻り値:
      • limit

        public SelectSql.Builder limit​(int limit,
                                       int offset)
        Creates limit clause with offset.
        パラメータ:
        limit -
        戻り値:
      • select

        public SelectSql.Builder select​(String... columns)
        Creates select clause. The default value is "*".

        For example,

         select("id","name","age") returns "select id, name, age"
         
        パラメータ:
        columns -
        戻り値:
      • toPrettyString

        public String toPrettyString()
        Creates prettified string.
        戻り値:
      • toPrettyString

        public String toPrettyString​(boolean prettyPrint)
        Creates prettified or plain string.
        パラメータ:
        prettyPrint -
        戻り値: