@Override public String getAlias(Object instance) { return removeCglibClassSuffix(super.getAlias(instance)); }
/** {@inheritDoc} */ public Object getValue(Object instance, String propertyName) { if (instance == null || propertyName == null) return null; BeanProperty bp = getBeanProperty(instance, propertyName); if (bp != null) return getBeanValue(instance, bp); SerializationContext context = getSerializationContext(); if (!ignorePropertyErrors(context)) { // Property '{propertyName}' not found on class '{alias}'. MessageException ex = new MessageException(); ex.setMessage(UNKNOWN_PROPERTY_ERROR, new Object[] {propertyName, getAlias(instance)}); throw ex; } return null; }
/** {@inheritDoc} */ public Object getValue(Object instance, String propertyName) { if (instance == null || propertyName == null) return null; BeanProperty bp = getBeanProperty(instance, propertyName); if (bp != null) return getBeanValue(instance, bp); SerializationContext context = getSerializationContext(); if (!ignorePropertyErrors(context)) { // Property '{propertyName}' not found on class '{alias}'. MessageException ex = new MessageException(); ex.setMessage(UNKNOWN_PROPERTY_ERROR, new Object[] {propertyName, getAlias(instance)}); throw ex; } return null; }
/** {@inheritDoc} */ public Object getValue(Object instance, String propertyName) { if (instance == null || propertyName == null) return null; BeanProperty bp = getBeanProperty(instance, propertyName); if (bp != null) { return getBeanValue(instance, bp); } else { SerializationContext context = getSerializationContext(); if (!ignorePropertyErrors(context)) { // Property '{propertyName}' not found on class '{alias}'. MessageException ex = new MessageException(); ex.setMessage(UNKNOWN_PROPERTY_ERROR, new Object[] {propertyName, getAlias(instance)}); throw ex; } } return null; }
new Object[] {propertyName, getAlias(instance)}, e); ex.setMessage(FAILED_PROPERTY_WRITE_ERROR, new Object[] {propertyName, getAlias(instance)}); ex.setRootCause(e); throw ex; new Object[] {propertyName, getAlias(instance)}); ex.setMessage(NON_WRITABLE_PROPERTY_ERROR, new Object[] {propertyName, getAlias(instance)}); throw ex; new Object[] {propertyName, getAlias(instance)}); ex.setMessage(UNKNOWN_PROPERTY_ERROR, new Object[] {propertyName, getAlias(instance)}); throw ex;
new Object[] {propertyName, getAlias(instance)}, e); ex.setMessage(FAILED_PROPERTY_WRITE_ERROR, new Object[] {propertyName, getAlias(instance)}); ex.setRootCause(e); throw ex; new Object[] {propertyName, getAlias(instance)}); ex.setMessage(NON_WRITABLE_PROPERTY_ERROR, new Object[] {propertyName, getAlias(instance)}); throw ex; new Object[] {propertyName, getAlias(instance)}); ex.setMessage(UNKNOWN_PROPERTY_ERROR, new Object[] {propertyName, getAlias(instance)}); throw ex;
new Object[] {propertyName, getAlias(instance)}, e); ex.setMessage(FAILED_PROPERTY_WRITE_ERROR, new Object[] {propertyName, getAlias(instance)}); ex.setRootCause(e); throw ex; new Object[] {propertyName, getAlias(instance)}); ex.setMessage(NON_WRITABLE_PROPERTY_ERROR, new Object[] {propertyName, getAlias(instance)}); throw ex; new Object[] {propertyName, getAlias(instance)}); ex.setMessage(UNKNOWN_PROPERTY_ERROR, new Object[] {propertyName, getAlias(instance)}); throw ex;