sqoop-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jar...@apache.org
Subject git commit: SQOOP-1100: Sqoop2: Missing setBoolean() method for MutableContext interface
Date Wed, 26 Jun 2013 19:27:09 GMT
Updated Branches:
  refs/heads/sqoop2 60a909f30 -> 344c6309c


SQOOP-1100: Sqoop2: Missing setBoolean() method for MutableContext interface

(Mengwei Ding via Jarek Jarcec Cecho)


Project: http://git-wip-us.apache.org/repos/asf/sqoop/repo
Commit: http://git-wip-us.apache.org/repos/asf/sqoop/commit/344c6309
Tree: http://git-wip-us.apache.org/repos/asf/sqoop/tree/344c6309
Diff: http://git-wip-us.apache.org/repos/asf/sqoop/diff/344c6309

Branch: refs/heads/sqoop2
Commit: 344c6309c84b0c06d65c258ce950b661f222ff40
Parents: 60a909f
Author: Jarek Jarcec Cecho <jarcec@cloudera.com>
Authored: Wed Jun 26 12:26:33 2013 -0700
Committer: Jarek Jarcec Cecho <jarcec@cloudera.com>
Committed: Wed Jun 26 12:26:33 2013 -0700

----------------------------------------------------------------------
 .../main/java/org/apache/sqoop/common/MutableContext.java    | 8 ++++++++
 .../main/java/org/apache/sqoop/common/MutableMapContext.java | 5 +++++
 2 files changed, 13 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/sqoop/blob/344c6309/common/src/main/java/org/apache/sqoop/common/MutableContext.java
----------------------------------------------------------------------
diff --git a/common/src/main/java/org/apache/sqoop/common/MutableContext.java b/common/src/main/java/org/apache/sqoop/common/MutableContext.java
index ecb97b5..ddf8af0 100644
--- a/common/src/main/java/org/apache/sqoop/common/MutableContext.java
+++ b/common/src/main/java/org/apache/sqoop/common/MutableContext.java
@@ -45,4 +45,12 @@ public interface MutableContext extends ImmutableContext {
    * @param value New value
    */
   public void setInteger(String key, int value);
+
+  /**
+   * Set boolean value for given key.
+   *
+   * @param key Key
+   * @param value New value
+   */
+  public void setBoolean(String key, boolean value);
 }

http://git-wip-us.apache.org/repos/asf/sqoop/blob/344c6309/common/src/main/java/org/apache/sqoop/common/MutableMapContext.java
----------------------------------------------------------------------
diff --git a/common/src/main/java/org/apache/sqoop/common/MutableMapContext.java b/common/src/main/java/org/apache/sqoop/common/MutableMapContext.java
index cb0c3e1..bb03ec0 100644
--- a/common/src/main/java/org/apache/sqoop/common/MutableMapContext.java
+++ b/common/src/main/java/org/apache/sqoop/common/MutableMapContext.java
@@ -53,6 +53,11 @@ public class MutableMapContext extends MapContext implements Iterable<Map.Entry<
   }
 
   @Override
+  public void setBoolean(String key, boolean value) {
+    getOptions().put(key, Boolean.toString(value));
+  }
+
+  @Override
   public Iterator<Map.Entry<String, String>> iterator() {
     return getOptions().entrySet().iterator();
   }


Mime
View raw message