You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "Johnnie White (Jira)" <ji...@apache.org> on 2024/11/04 08:41:00 UTC
[jira] [Created] (BEANUTILS-572) Automatically fill the basic type value in the bean
Johnnie White created BEANUTILS-572:
---------------------------------------
Summary: Automatically fill the basic type value in the bean
Key: BEANUTILS-572
URL: https://issues.apache.org/jira/browse/BEANUTILS-572
Project: Commons BeanUtils
Issue Type: New Feature
Components: Bean / Property Utils
Affects Versions: 2.0.0
Reporter: Johnnie White
I am going to add a new function as {*}BeanUtils.{*}{*}fillBeanForTest{*}, it can automatically fill the basic type value for a bean's properties.
e.g. I want to build a bean _Bean1_ with value, if _Bean1_ has 10+ properties. Some are Integer/int/String, some are other custom {_}Bean2-N{_}, what's more _Bean2_ has a properties as a List/Map etc. The code to fill this _Bean1_ may cost 100+ lines( I came up with this function because I just manually built a very complex bean for test)
This function can iterately fill bean's properties by simple default value if it can write & reflect & basic type
--
This message was sent by Atlassian Jira
(v8.20.10#820010)