/** * Returns the String representation for the object. * <p> * * @return String representation for the object. * */ @Override public String toString() { return ToStringBean.toString(beanClass, this); }
private static void printArrayProperty(final StringBuffer sb, final String prefix, final Object array) { final int length = Array.getLength(array); for (int i = 0; i < length; i++) { final Object obj = Array.get(array, i); printProperty(sb, String.format("%s[%s]", prefix, i), obj); } }
printArrayProperty(sb, prefix, value);
default <T> Object makeROMEAllPropertyTrigger ( UtilFactory uf, Class<T> type, T obj ) throws Exception { ToStringBean item = new ToStringBean(type, obj); EqualsBean root = new EqualsBean(ToStringBean.class, item); return uf.makeHashCodeTrigger(root); } }
private static void printArrayProperty(final StringBuffer sb, final String prefix, final Object array) { final int length = Array.getLength(array); for (int i = 0; i < length; i++) { final Object obj = Array.get(array, i); printProperty(sb, String.format("%s[%s]", prefix, i), obj); } }
printArrayProperty(sb, prefix, value);
@Override public String toString() { return ToStringBean.toString(MediaContent.class, this); } }
/** * Returns the String representation of the bean given in the constructor. * <p> * * @param prefix to use for bean properties. * @return bean object String representation. * */ private static String toString(final Class<?> beanClass, final Object obj, final String prefix) { final StringBuffer sb = new StringBuffer(128); try { final List<PropertyDescriptor> propertyDescriptors = BeanIntrospector.getPropertyDescriptorsWithGetters(beanClass); for (final PropertyDescriptor propertyDescriptor : propertyDescriptors) { final String propertyName = propertyDescriptor.getName(); final Method getter = propertyDescriptor.getReadMethod(); final Object value = getter.invoke(obj, NO_PARAMS); printProperty(sb, prefix + "." + propertyName, value); } } catch (final Exception e) { LOG.error("Error while generating toString", e); final Class<?> clazz = obj.getClass(); final String errorMessage = e.getMessage(); sb.append(String.format("\n\nEXCEPTION: Could not complete %s.toString(): %s\n", clazz, errorMessage)); } return sb.toString(); }
@Override public String toString() { return ToStringBean.toString(Sort.class, this); } }
/** * Returns the String representation of the bean given in the constructor. * <p> * * @param prefix to use for bean properties. * @return bean object String representation. * */ private static String toString(final Class<?> beanClass, final Object obj, final String prefix) { final StringBuffer sb = new StringBuffer(128); try { final List<PropertyDescriptor> propertyDescriptors = BeanIntrospector.getPropertyDescriptorsWithGetters(beanClass); for (final PropertyDescriptor propertyDescriptor : propertyDescriptors) { final String propertyName = propertyDescriptor.getName(); final Method getter = propertyDescriptor.getReadMethod(); final Object value = getter.invoke(obj, NO_PARAMS); printProperty(sb, prefix + "." + propertyName, value); } } catch (final Exception e) { LOG.error("Error while generating toString", e); final Class<?> clazz = obj.getClass(); final String errorMessage = e.getMessage(); sb.append(String.format("\n\nEXCEPTION: Could not complete %s.toString(): %s\n", clazz, errorMessage)); } return sb.toString(); }
/** * Returns the String representation for the object. * <p> * * @return String representation for the object. * */ @Override public final String toString() { return ToStringBean.toString(DCModule.class, this); }
/** * Returns the String representation for the object. * <p> * * @return String representation for the object. * */ @Override public String toString() { return ToStringBean.toString(SyndEnclosure.class, this); }
/** * Returns the String representation for the object. * <p> * * @return String representation for the object. * */ @Override public String toString() { return ToStringBean.toString(beanClass, this); }
/** * Returns a String representation of the metadata object. * * @return Returns a String representation of the metadata object. */ @Override public String toString() { return ToStringBean.toString(Metadata.class, this); }
@Override public String toString() { return ToStringBean.toString(AtomLinkModuleImpl.class, this); } }
/** * Returns the String representation for the object. * <p> * * @return String representation for the object. * */ @Override public String toString() { return ToStringBean.toString(SyndContent.class, this); }
@Override public String toString() { return ToStringBean.toString(PodloveSimpleChapterModuleImpl.class, this); } }
@Override public String toString() { return ToStringBean.toString(Metadata.class, this); } }
/** * Returns the String representation for the object. * <p> * * @return String representation for the object. * */ @Override public String toString() { return ToStringBean.toString(beanClass, this); }
/** * Returns the String representation for the object. * <p> * * @return String representation for the object. * */ @Override public String toString() { return ToStringBean.toString(beanClass, this); }