com.github.dandelion.datatables.core.util
Class JavascriptUtils

java.lang.Object
  extended by com.github.dandelion.datatables.core.util.JavascriptUtils

public class JavascriptUtils
extends Object


Field Summary
static String INDENT
           
static char NEWLINE
           
 
Constructor Summary
JavascriptUtils()
           
 
Method Summary
static String toArray(Collection<String> collection)
           Converts a collection of Strings into a Javascript array.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

NEWLINE

public static final char NEWLINE
See Also:
Constant Field Values

INDENT

public static final String INDENT
See Also:
Constant Field Values
Constructor Detail

JavascriptUtils

public JavascriptUtils()
Method Detail

toArray

public static String toArray(Collection<String> collection)

Converts a collection of Strings into a Javascript array.

For example, the following collection: ("strint1", "string2", "string3") will be converted to: ['strint1', 'string2', 'string3']

Parameters:
collection - The collection of Strings to convert into a Javascript array.
Returns:
a String representing a Javascript array.


Copyright © 2013–2014 Dandelion Project. All rights reserved.