ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sevdoki...@apache.org
Subject [05/52] [abbrv] incubator-ignite git commit: ignite-sql - moved classes
Date Wed, 28 Jan 2015 09:59:40 GMT
ignite-sql - moved classes


Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/b5b069ed
Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/b5b069ed
Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/b5b069ed

Branch: refs/heads/ignite-59
Commit: b5b069ed4f7f96cb4e2395bf154a8986b64332d4
Parents: 124c9de
Author: S.Vladykin <svladykin@gridgain.com>
Authored: Mon Jan 26 22:09:44 2015 +0300
Committer: S.Vladykin <svladykin@gridgain.com>
Committed: Mon Jan 26 22:09:44 2015 +0300

----------------------------------------------------------------------
 .../cache/query/GridCacheSqlQuery.java          | 99 ++++++++++++++++++++
 .../cache/query/GridCacheSqlResult.java         | 21 +++++
 .../cache/query/GridCacheTwoStepQuery.java      | 74 +++++++++++++++
 .../cache/query/GridCacheSqlQuery.java          | 99 --------------------
 .../cache/query/GridCacheSqlResult.java         | 21 -----
 .../cache/query/GridCacheTwoStepQuery.java      | 74 ---------------
 6 files changed, 194 insertions(+), 194 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/b5b069ed/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheSqlQuery.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheSqlQuery.java
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheSqlQuery.java
new file mode 100644
index 0000000..0500a75
--- /dev/null
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheSqlQuery.java
@@ -0,0 +1,99 @@
+/* @java.file.header */
+
+/*  _________        _____ __________________        _____
+ *  __  ____/___________(_)______  /__  ____/______ ____(_)_______
+ *  _  / __  __  ___/__  / _  __  / _  / __  _  __ `/__  / __  __ \
+ *  / /_/ /  _  /    _  /  / /_/ /  / /_/ /  / /_/ / _  /  _  / / /
+ *  \____/   /_/     /_/   \_,__/   \____/   \__,_/  /_/   /_/ /_/
+ */
+
+package org.apache.ignite.internal.processors.cache.query;
+
+import org.apache.ignite.internal.util.tostring.*;
+import org.apache.ignite.internal.util.typedef.*;
+import org.apache.ignite.internal.util.typedef.internal.*;
+
+import java.io.*;
+
+/**
+ * Query.
+ */
+public class GridCacheSqlQuery implements Externalizable {
+    /** */
+    private static final Object[] EMPTY_PARAMS = {};
+
+    /** */
+    String alias;
+
+    /** */
+    @GridToStringInclude
+    String qry;
+
+    /** */
+    @GridToStringInclude
+    Object[] params;
+
+    /**
+     * For {@link Externalizable}.
+     */
+    public GridCacheSqlQuery() {
+        // No-op.
+    }
+
+    /**
+     * @param alias Alias.
+     * @param qry Query.
+     * @param params Query parameters.
+     */
+    GridCacheSqlQuery(String alias, String qry, Object[] params) {
+        A.ensure(!F.isEmpty(qry), "qry must not be empty");
+
+        this.alias = alias;
+        this.qry = qry;
+
+        this.params = F.isEmpty(params) ? EMPTY_PARAMS : params;
+    }
+
+    /**
+     * @return Alias.
+     */
+    public String alias() {
+        return alias;
+    }
+
+    /**
+     * @return Query.
+     */
+    public String query() {
+        return qry;
+    }
+
+    /**
+     * @return Parameters.
+     */
+    public Object[] parameters() {
+        return params;
+    }
+
+    /** {@inheritDoc} */
+    @Override public void writeExternal(ObjectOutput out) throws IOException {
+        U.writeString(out, alias);
+        U.writeString(out, qry);
+        U.writeArray(out, params);
+    }
+
+    /** {@inheritDoc} */
+    @Override public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
{
+        alias = U.readString(in);
+        qry = U.readString(in);
+        params = U.readArray(in);
+
+        if (F.isEmpty(params))
+            params = EMPTY_PARAMS;
+    }
+
+    /** {@inheritDoc} */
+    @Override public String toString() {
+        return S.toString(GridCacheSqlQuery.class, this);
+    }
+}

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/b5b069ed/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheSqlResult.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheSqlResult.java
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheSqlResult.java
new file mode 100644
index 0000000..a8eb69b
--- /dev/null
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheSqlResult.java
@@ -0,0 +1,21 @@
+/* @java.file.header */
+
+/*  _________        _____ __________________        _____
+ *  __  ____/___________(_)______  /__  ____/______ ____(_)_______
+ *  _  / __  __  ___/__  / _  __  / _  / __  _  __ `/__  / __  __ \
+ *  / /_/ /  _  /    _  /  / /_/ /  / /_/ /  / /_/ / _  /  _  / / /
+ *  \____/   /_/     /_/   \_,__/   \____/   \__,_/  /_/   /_/ /_/
+ */
+
+package org.apache.ignite.internal.processors.cache.query;
+
+import java.util.*;
+
+/**
+ * TODO replace with {@link org.apache.ignite.cache.query.QueryCursor}
+ *
+ * SQL Query result.
+ */
+public interface GridCacheSqlResult extends AutoCloseable, Iterable<List<?>>
{
+    // No-op.
+}

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/b5b069ed/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheTwoStepQuery.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheTwoStepQuery.java
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheTwoStepQuery.java
new file mode 100644
index 0000000..650f486
--- /dev/null
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheTwoStepQuery.java
@@ -0,0 +1,74 @@
+/* @java.file.header */
+
+/*  _________        _____ __________________        _____
+ *  __  ____/___________(_)______  /__  ____/______ ____(_)_______
+ *  _  / __  __  ___/__  / _  __  / _  / __  _  __ `/__  / __  __ \
+ *  / /_/ /  _  /    _  /  / /_/ /  / /_/ /  / /_/ / _  /  _  / / /
+ *  \____/   /_/     /_/   \_,__/   \____/   \__,_/  /_/   /_/ /_/
+ */
+
+package org.apache.ignite.internal.processors.cache.query;
+
+import org.apache.ignite.*;
+import org.apache.ignite.internal.util.*;
+import org.apache.ignite.internal.util.tostring.*;
+import org.apache.ignite.internal.util.typedef.*;
+import org.apache.ignite.internal.util.typedef.internal.*;
+
+import java.io.*;
+import java.util.*;
+
+/**
+ * Two step map-reduce style query.
+ */
+public class GridCacheTwoStepQuery implements Serializable {
+    /** */
+    @GridToStringInclude
+    private Map<String, GridCacheSqlQuery> mapQrys;
+
+    /** */
+    @GridToStringInclude
+    private GridCacheSqlQuery reduce;
+
+    /**
+     * @param qry Reduce query.
+     * @param params Reduce query parameters.
+     */
+    public GridCacheTwoStepQuery(String qry, Object ... params) {
+        reduce = new GridCacheSqlQuery(null, qry, params);
+    }
+
+    /**
+     * @param alias Alias.
+     * @param qry SQL Query.
+     * @param params Query parameters.
+     */
+    public void addMapQuery(String alias, String qry, Object ... params) {
+        A.ensure(!F.isEmpty(alias), "alias must not be empty");
+
+        if (mapQrys == null)
+            mapQrys = new GridLeanMap<>();
+
+        if (mapQrys.put(alias, new GridCacheSqlQuery(alias, qry, params)) != null)
+            throw new IgniteException("Failed to add query, alias already exists: " + alias
+ ".");
+    }
+
+    /**
+     * @return Reduce query.
+     */
+    public GridCacheSqlQuery reduceQuery() {
+        return reduce;
+    }
+
+    /**
+     * @return Map queries.
+     */
+    public Collection<GridCacheSqlQuery> mapQueries() {
+        return mapQrys.values();
+    }
+
+    /** {@inheritDoc} */
+    @Override public String toString() {
+        return S.toString(GridCacheTwoStepQuery.class, this);
+    }
+}

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/b5b069ed/modules/core/src/main/java/org/gridgain/grid/kernal/processors/cache/query/GridCacheSqlQuery.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/gridgain/grid/kernal/processors/cache/query/GridCacheSqlQuery.java
b/modules/core/src/main/java/org/gridgain/grid/kernal/processors/cache/query/GridCacheSqlQuery.java
deleted file mode 100644
index 01a25bf..0000000
--- a/modules/core/src/main/java/org/gridgain/grid/kernal/processors/cache/query/GridCacheSqlQuery.java
+++ /dev/null
@@ -1,99 +0,0 @@
-/* @java.file.header */
-
-/*  _________        _____ __________________        _____
- *  __  ____/___________(_)______  /__  ____/______ ____(_)_______
- *  _  / __  __  ___/__  / _  __  / _  / __  _  __ `/__  / __  __ \
- *  / /_/ /  _  /    _  /  / /_/ /  / /_/ /  / /_/ / _  /  _  / / /
- *  \____/   /_/     /_/   \_,__/   \____/   \__,_/  /_/   /_/ /_/
- */
-
-package org.gridgain.grid.kernal.processors.cache.query;
-
-import org.apache.ignite.internal.util.tostring.*;
-import org.apache.ignite.internal.util.typedef.*;
-import org.apache.ignite.internal.util.typedef.internal.*;
-
-import java.io.*;
-
-/**
- * Query.
- */
-public class GridCacheSqlQuery implements Externalizable {
-    /** */
-    private static final Object[] EMPTY_PARAMS = {};
-
-    /** */
-    String alias;
-
-    /** */
-    @GridToStringInclude
-    String qry;
-
-    /** */
-    @GridToStringInclude
-    Object[] params;
-
-    /**
-     * For {@link Externalizable}.
-     */
-    public GridCacheSqlQuery() {
-        // No-op.
-    }
-
-    /**
-     * @param alias Alias.
-     * @param qry Query.
-     * @param params Query parameters.
-     */
-    GridCacheSqlQuery(String alias, String qry, Object[] params) {
-        A.ensure(!F.isEmpty(qry), "qry must not be empty");
-
-        this.alias = alias;
-        this.qry = qry;
-
-        this.params = F.isEmpty(params) ? EMPTY_PARAMS : params;
-    }
-
-    /**
-     * @return Alias.
-     */
-    public String alias() {
-        return alias;
-    }
-
-    /**
-     * @return Query.
-     */
-    public String query() {
-        return qry;
-    }
-
-    /**
-     * @return Parameters.
-     */
-    public Object[] parameters() {
-        return params;
-    }
-
-    /** {@inheritDoc} */
-    @Override public void writeExternal(ObjectOutput out) throws IOException {
-        U.writeString(out, alias);
-        U.writeString(out, qry);
-        U.writeArray(out, params);
-    }
-
-    /** {@inheritDoc} */
-    @Override public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
{
-        alias = U.readString(in);
-        qry = U.readString(in);
-        params = U.readArray(in);
-
-        if (F.isEmpty(params))
-            params = EMPTY_PARAMS;
-    }
-
-    /** {@inheritDoc} */
-    @Override public String toString() {
-        return S.toString(GridCacheSqlQuery.class, this);
-    }
-}

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/b5b069ed/modules/core/src/main/java/org/gridgain/grid/kernal/processors/cache/query/GridCacheSqlResult.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/gridgain/grid/kernal/processors/cache/query/GridCacheSqlResult.java
b/modules/core/src/main/java/org/gridgain/grid/kernal/processors/cache/query/GridCacheSqlResult.java
deleted file mode 100644
index a0be64d..0000000
--- a/modules/core/src/main/java/org/gridgain/grid/kernal/processors/cache/query/GridCacheSqlResult.java
+++ /dev/null
@@ -1,21 +0,0 @@
-/* @java.file.header */
-
-/*  _________        _____ __________________        _____
- *  __  ____/___________(_)______  /__  ____/______ ____(_)_______
- *  _  / __  __  ___/__  / _  __  / _  / __  _  __ `/__  / __  __ \
- *  / /_/ /  _  /    _  /  / /_/ /  / /_/ /  / /_/ / _  /  _  / / /
- *  \____/   /_/     /_/   \_,__/   \____/   \__,_/  /_/   /_/ /_/
- */
-
-package org.gridgain.grid.kernal.processors.cache.query;
-
-import java.util.*;
-
-/**
- * TODO replace with {@link org.apache.ignite.cache.query.QueryCursor}
- *
- * SQL Query result.
- */
-public interface GridCacheSqlResult extends AutoCloseable, Iterable<List<?>>
{
-    // No-op.
-}

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/b5b069ed/modules/core/src/main/java/org/gridgain/grid/kernal/processors/cache/query/GridCacheTwoStepQuery.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/gridgain/grid/kernal/processors/cache/query/GridCacheTwoStepQuery.java
b/modules/core/src/main/java/org/gridgain/grid/kernal/processors/cache/query/GridCacheTwoStepQuery.java
deleted file mode 100644
index 726f792..0000000
--- a/modules/core/src/main/java/org/gridgain/grid/kernal/processors/cache/query/GridCacheTwoStepQuery.java
+++ /dev/null
@@ -1,74 +0,0 @@
-/* @java.file.header */
-
-/*  _________        _____ __________________        _____
- *  __  ____/___________(_)______  /__  ____/______ ____(_)_______
- *  _  / __  __  ___/__  / _  __  / _  / __  _  __ `/__  / __  __ \
- *  / /_/ /  _  /    _  /  / /_/ /  / /_/ /  / /_/ / _  /  _  / / /
- *  \____/   /_/     /_/   \_,__/   \____/   \__,_/  /_/   /_/ /_/
- */
-
-package org.gridgain.grid.kernal.processors.cache.query;
-
-import org.apache.ignite.*;
-import org.apache.ignite.internal.util.*;
-import org.apache.ignite.internal.util.tostring.*;
-import org.apache.ignite.internal.util.typedef.*;
-import org.apache.ignite.internal.util.typedef.internal.*;
-
-import java.io.*;
-import java.util.*;
-
-/**
- * Two step map-reduce style query.
- */
-public class GridCacheTwoStepQuery implements Serializable {
-    /** */
-    @GridToStringInclude
-    private Map<String, GridCacheSqlQuery> mapQrys;
-
-    /** */
-    @GridToStringInclude
-    private GridCacheSqlQuery reduce;
-
-    /**
-     * @param qry Reduce query.
-     * @param params Reduce query parameters.
-     */
-    public GridCacheTwoStepQuery(String qry, Object ... params) {
-        reduce = new GridCacheSqlQuery(null, qry, params);
-    }
-
-    /**
-     * @param alias Alias.
-     * @param qry SQL Query.
-     * @param params Query parameters.
-     */
-    public void addMapQuery(String alias, String qry, Object ... params) {
-        A.ensure(!F.isEmpty(alias), "alias must not be empty");
-
-        if (mapQrys == null)
-            mapQrys = new GridLeanMap<>();
-
-        if (mapQrys.put(alias, new GridCacheSqlQuery(alias, qry, params)) != null)
-            throw new IgniteException("Failed to add query, alias already exists: " + alias
+ ".");
-    }
-
-    /**
-     * @return Reduce query.
-     */
-    public GridCacheSqlQuery reduceQuery() {
-        return reduce;
-    }
-
-    /**
-     * @return Map queries.
-     */
-    public Collection<GridCacheSqlQuery> mapQueries() {
-        return mapQrys.values();
-    }
-
-    /** {@inheritDoc} */
-    @Override public String toString() {
-        return S.toString(GridCacheTwoStepQuery.class, this);
-    }
-}


Mime
View raw message