From: Florian Forster Date: Mon, 15 Aug 2016 05:41:24 +0000 (+0200) Subject: GenericJMX plugin: Suppress "unchecked conversion" warning. X-Git-Tag: collectd-5.6.0~19 X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=a82b047a8dc968cd962948a6dbac0368cdbf2210;p=collectd.git GenericJMX plugin: Suppress "unchecked conversion" warning. The internet tells me there is no elegant way around this. --- diff --git a/bindings/java/org/collectd/java/GenericJMXConfValue.java b/bindings/java/org/collectd/java/GenericJMXConfValue.java index 25b70d4a..63b76282 100644 --- a/bindings/java/org/collectd/java/GenericJMXConfValue.java +++ b/bindings/java/org/collectd/java/GenericJMXConfValue.java @@ -313,9 +313,8 @@ class GenericJMXConfValue key = attrName.remove (0); - TabularData tabularData = (TabularData) parent; - Collection table = - (Collection)tabularData.values(); + @SuppressWarnings("unchecked") + Collection table = (Collection) parent.values(); for (CompositeData compositeData : table) { if (key.equals(compositeData.get("key")))