Code example for JsonArray

Methods: add

0
    return jo;
  } 
 
  @Test(expected = UnsupportedOperationException.class) 
  public void testDeserializeArrayWithNull() { 
    JsonArray array = new JsonArray();
    array.add( JsonNull.INSTANCE );
 
    deserializer.deserialize( array, type, context );
  } 
 
  @Test(expected = UnsupportedOperationException.class) 
  public void testDeserializeArrayWithNullTarget() { 
    JsonArray array = new JsonArray();
    array.add( new JsonPrimitive( "create" ) );
    array.add( JsonNull.INSTANCE );
    array.add( new JsonPrimitive( "rwt.widgets.Shell" ) );
 
    deserializer.deserialize( array, type, context );
  }