/** * Method that can be used to replace an existing property with * a modified one. *<p> * NOTE: only ever use this method if you know what you are doing; * incorrect usage can break deserializer. * * @param original Property to replace * @param replacement Property to replace it with * * @since 2.1 */ public void replaceProperty(SettableBeanProperty original, SettableBeanProperty replacement) { _beanProperties.replace(original, replacement); }
/** * @since 2.8.8 */ protected void _replaceProperty(BeanPropertyMap props, SettableBeanProperty[] creatorProps, SettableBeanProperty origProp, SettableBeanProperty newProp) { props.replace(origProp, newProp); // [databind#795]: Make sure PropertyBasedCreator's properties stay in sync if (creatorProps != null) { // 18-May-2015, tatu: _Should_ start with consistent set. But can we really // fully count on this? May need to revisit in future; seems to hold for now. for (int i = 0, len = creatorProps.length; i < len; ++i) { if (creatorProps[i] == origProp) { creatorProps[i] = newProp; return; } } /* // ... as per above, it is possible we'd need to add this as fallback // if (but only if) identity check fails? for (int i = 0, len = creatorProps.length; i < len; ++i) { if (creatorProps[i].getName().equals(origProp.getName())) { creatorProps[i] = newProp; return; } } */ } }
/** * Method that can be used to replace an existing property with * a modified one. *<p> * NOTE: only ever use this method if you know what you are doing; * incorrect usage can break deserializer. * * @param original Property to replace * @param replacement Property to replace it with * * @since 2.1 */ public void replaceProperty(SettableBeanProperty original, SettableBeanProperty replacement) { _beanProperties.replace(original, replacement); }
/** * Method that can be used to replace an existing property with * a modified one. *<p> * NOTE: only ever use this method if you know what you are doing; * incorrect usage can break deserializer. * * @param original Property to replace * @param replacement Property to replace it with * * @since 2.1 */ public void replaceProperty(SettableBeanProperty original, SettableBeanProperty replacement) { _beanProperties.replace(replacement); }
/** * Method that can be used to replace an existing property with * a modified one. *<p> * NOTE: only ever use this method if you know what you are doing; * incorrect usage can break deserializer. * * @param original Property to replace * @param replacement Property to replace it with * * @since 2.1 */ public void replaceProperty(SettableBeanProperty original, SettableBeanProperty replacement) { _beanProperties.replace(replacement); }
/** * Method that can be used to replace an existing property with * a modified one. *<p> * NOTE: only ever use this method if you know what you are doing; * incorrect usage can break deserializer. * * @param original Property to replace * @param replacement Property to replace it with * * @since 2.1 */ public void replaceProperty(SettableBeanProperty original, SettableBeanProperty replacement) { _beanProperties.replace(replacement); }
/** * Method that can be used to replace an existing property with * a modified one. *<p> * NOTE: only ever use this method if you know what you are doing; * incorrect usage can break deserializer. * * @param original Property to replace * @param replacement Property to replace it with * * @since 2.1 */ public void replaceProperty(SettableBeanProperty original, SettableBeanProperty replacement) { _beanProperties.replace(replacement); }
/** * @since 2.8.8 */ protected void _replaceProperty(BeanPropertyMap props, SettableBeanProperty[] creatorProps, SettableBeanProperty origProp, SettableBeanProperty newProp) { props.replace(origProp, newProp); // [databind#795]: Make sure PropertyBasedCreator's properties stay in sync if (creatorProps != null) { // 18-May-2015, tatu: _Should_ start with consistent set. But can we really // fully count on this? May need to revisit in future; seems to hold for now. for (int i = 0, len = creatorProps.length; i < len; ++i) { if (creatorProps[i] == origProp) { creatorProps[i] = newProp; return; } } /* // ... as per above, it is possible we'd need to add this as fallback // if (but only if) identity check fails? for (int i = 0, len = creatorProps.length; i < len; ++i) { if (creatorProps[i].getName().equals(origProp.getName())) { creatorProps[i] = newProp; return; } } */ } }
/** * @since 2.8.8 */ protected void _replaceProperty(BeanPropertyMap props, SettableBeanProperty[] creatorProps, SettableBeanProperty origProp, SettableBeanProperty newProp) { props.replace(newProp); // [databind#795]: Make sure PropertyBasedCreator's properties stay in sync if (creatorProps != null) { // 18-May-2015, tatu: _Should_ start with consistent set. But can we really // fully count on this? May need to revisit in future; seems to hold for now. for (int i = 0, len = creatorProps.length; i < len; ++i) { if (creatorProps[i] == origProp) { creatorProps[i] = newProp; return; } } // ... as per above, it is possible we'd need to add this as fallback // if (but only if) identity check fails? /* if (creatorProps[i].getName().equals(prop.getName())) { creatorProps[i] = prop; break; } */ } }
newMap.replace(newProperty); return newMap;
newMap.replace(newProperty); return newMap;
newMap.replace(newProperty); return newMap;
newMap.replace(newProperty); return newMap;
_beanProperties.replace(prop);
_beanProperties.replace(prop);
_beanProperties.replace(prop);
_beanProperties.replace(prop);