Package org.apache.hadoop.hbase.util
Class JRubyFormat
java.lang.Object
org.apache.hadoop.hbase.util.JRubyFormat
Utility class for converting objects to JRuby. It handles null, Boolean, Number, String, byte[],
List<Object>, Map<String, Object> structures.
E.g.
Map<String, Object> map = new LinkedHashMap<>(); map.put("null", null); map.put("boolean", true); map.put("number", 1); map.put("string", "str"); map.put("binary", new byte[] { 1, 2, 3 }); map.put("list", Lists.newArrayList(1, "2", true));
Calling print(Object)
method will result:
{ null => '', boolean => 'true', number => '1', string => 'str', binary => '010203', list => [ '1', '2', 'true' ] }
-
Field Summary
Modifier and TypeFieldDescriptionprivate static final org.apache.hbase.thirdparty.com.google.common.escape.Escaper
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprivate static void
appendJRuby
(StringBuilder builder, Object object) private static String
static String
-
Field Details
-
escaper
-
-
Constructor Details
-
JRubyFormat
private JRubyFormat()
-
-
Method Details
-
escape
-
appendJRuby
-
print
-