There is an 'undocumented and smart' API to get get the value originally read for an Entity Attribute from the database. Thanks to Steve for sharing this. You may need to call EntityImpl::getAttribute(attrIndex,EntityImpl.ORIGINAL_VERSION) to get the original value of the attribute.
As you may be aware, there is a 'well known' protected method EntityImpl::getPostedAttribute(int index) also available for the same purpose. In this case, you may need to sub class the EntityImpl
to increase the visibility, if you want to use it in your business service implementation.
No comments:
Post a Comment