List of usage examples for org.apache.solr.client.solrj.beans BindingException BindingException
public BindingException(String message, Throwable cause)
From source file:edu.vt.vbi.patric.common.DocumentMapBinder.java
License:Apache License
private <T> T getBean(Class<T> clazz, List<DocField> fields, Map solrDoc) { if (fields == null) { fields = getDocFields(clazz);//w w w . j a va 2s . c om } try { T obj = clazz.newInstance(); for (DocField docField : fields) { docField.inject(obj, solrDoc); } return obj; } catch (Exception e) { throw new BindingException("Could not instantiate object of " + clazz, e); } }