com.aelitis.azureus.util
Class ImportExportUtils

java.lang.Object
  extended by com.aelitis.azureus.util.ImportExportUtils

public final class ImportExportUtils
extends java.lang.Object

Note: There's a similarly defined map processing utility class called MapUtils. Since there are differences in implementation, both have been kept until someone goes through each callee and check if it can be switched to use just one of them.


Constructor Summary
ImportExportUtils()
           
 
Method Summary
static void exportBoolean(java.util.Map map, java.lang.String key, boolean value)
           
static void exportFloat(java.util.Map map, java.lang.String key, float value)
           
static void exportInt(java.util.Map map, java.lang.String key, int value)
           
static void exportIntArray(java.util.Map map, java.lang.String key, int[] values)
           
static void exportJSONBoolean(java.util.Map map, java.lang.String key, boolean value)
           
static void exportJSONString(java.util.Map map, java.lang.String key, java.lang.String value)
           
static void exportJSONStringArray(java.util.Map map, java.lang.String key, java.lang.String[] data)
           
static void exportJSONURL(java.util.Map map, java.lang.String key, java.lang.String value)
           
static void exportLong(java.util.Map map, java.lang.String key, long value)
           
static void exportString(java.util.Map map, java.lang.String key, java.lang.String value)
           
static void exportStringArray(java.util.Map map, java.lang.String key, java.lang.String[] data)
           
static void exportURL(java.util.Map map, java.lang.String key, java.lang.String value)
           
static boolean importBoolean(java.util.Map map, java.lang.String key)
           
static boolean importBoolean(java.util.Map map, java.lang.String key, boolean def)
           
static float importFloat(java.util.Map map, java.lang.String key, float def)
           
static int importInt(java.util.Map map, java.lang.String key)
           
static int importInt(java.util.Map map, java.lang.String key, int def)
           
static int[] importIntArray(java.util.Map map, java.lang.String key)
           
static long importLong(java.util.Map map, java.lang.String key)
           
static long importLong(java.util.Map map, java.lang.String key, long def)
           
static java.lang.String importString(java.util.Map map, java.lang.String key)
           
static java.lang.String importString(java.util.Map map, java.lang.String key, java.lang.String def)
           
static java.lang.String[] importStringArray(java.util.Map map, java.lang.String key)
           
static java.lang.String importURL(java.util.Map map, java.lang.String key)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ImportExportUtils

public ImportExportUtils()
Method Detail

exportString

public static final void exportString(java.util.Map map,
                                      java.lang.String key,
                                      java.lang.String value)

exportJSONString

public static final void exportJSONString(java.util.Map map,
                                          java.lang.String key,
                                          java.lang.String value)

importString

public static final java.lang.String importString(java.util.Map map,
                                                  java.lang.String key,
                                                  java.lang.String def)

importString

public static final java.lang.String importString(java.util.Map map,
                                                  java.lang.String key)

importLong

public static final long importLong(java.util.Map map,
                                    java.lang.String key)

importLong

public static final long importLong(java.util.Map map,
                                    java.lang.String key,
                                    long def)

exportLong

public static final void exportLong(java.util.Map map,
                                    java.lang.String key,
                                    long value)

exportInt

public static final void exportInt(java.util.Map map,
                                   java.lang.String key,
                                   int value)

importInt

public static final int importInt(java.util.Map map,
                                  java.lang.String key)

importInt

public static final int importInt(java.util.Map map,
                                  java.lang.String key,
                                  int def)

exportFloat

public static final void exportFloat(java.util.Map map,
                                     java.lang.String key,
                                     float value)

importFloat

public static final float importFloat(java.util.Map map,
                                      java.lang.String key,
                                      float def)

exportBoolean

public static final void exportBoolean(java.util.Map map,
                                       java.lang.String key,
                                       boolean value)

importBoolean

public static final boolean importBoolean(java.util.Map map,
                                          java.lang.String key)

importBoolean

public static final boolean importBoolean(java.util.Map map,
                                          java.lang.String key,
                                          boolean def)

exportJSONBoolean

public static final void exportJSONBoolean(java.util.Map map,
                                           java.lang.String key,
                                           boolean value)

importURL

public static final java.lang.String importURL(java.util.Map map,
                                               java.lang.String key)

exportURL

public static final void exportURL(java.util.Map map,
                                   java.lang.String key,
                                   java.lang.String value)

exportJSONURL

public static final void exportJSONURL(java.util.Map map,
                                       java.lang.String key,
                                       java.lang.String value)

importStringArray

public static final java.lang.String[] importStringArray(java.util.Map map,
                                                         java.lang.String key)

exportStringArray

public static final void exportStringArray(java.util.Map map,
                                           java.lang.String key,
                                           java.lang.String[] data)

exportJSONStringArray

public static final void exportJSONStringArray(java.util.Map map,
                                               java.lang.String key,
                                               java.lang.String[] data)

exportIntArray

public static final void exportIntArray(java.util.Map map,
                                        java.lang.String key,
                                        int[] values)

importIntArray

public static final int[] importIntArray(java.util.Map map,
                                         java.lang.String key)