Java class object receiving entity values

Here Insert Picture Description
We can see that, when the value of Java backstage to accept, it is to receive a through a property, although it is only three properties, but if there are hundreds of properties to be received, is not to write very troublesome.

Solution

Here Insert Picture Description
Here Insert Picture Description
Console output:

TbSchool{, id=null, name=1111, type=2, phone=11111111111}

Reception values are passed by way of passing a background object, no matter how much value we do not need to be modified in the background.
If you need to use a value which we can be direct use by TbSchool. Value.
May be directly used directly by the object, as the case may

Published 24 original articles · won praise 32 · views 30000 +

Guess you like

Origin blog.csdn.net/weixin_45736927/article/details/104538935