public static ConfigItems[] toConfigItemArray(ConfigPropertyVoCollection properties) { if (properties == null || properties.size() == 0) return null; ConfigItems[] items = new ConfigItems[properties.size()]; for (int i=0; i<properties.size(); i++) { ConfigPropertyVo prop= properties.get(i); ConfigItems item = new ConfigItems(prop.getPropertyName(), prop.getPropertyValue()); items[i] = item; } return items; }