sofa-boot icon indicating copy to clipboard operation
sofa-boot copied to clipboard

Add some enums for basic binding types.

Open irvingos opened this issue 4 years ago • 3 comments

  1. Add an enum type for basic binding types;
  2. Modify the use of some primitive binding types to adapt to changes;

不妥之处,望指点!

irvingos avatar Nov 22 '21 14:11 irvingos

Hi @IrvingOS, welcome to SOFAStack community, Please sign Contributor License Agreement!

After you signed CLA, we will automatically sync the status of this pull request in 3 minutes.

sofastack-bot[bot] avatar Nov 22 '21 14:11 sofastack-bot[bot]

@IrvingOS Thank you for your PR. Consider the situation that if I want to add a new binding type in my own project instead of sofaboot repo using the extensible ability of sofaboot and sofa-rpc. I can't inherit the enum class to create a new binding type.

OrezzerO avatar Nov 22 '21 17:11 OrezzerO

Therefore, I reserved BindingType and provided a method to convert from BindingTypeEnum to BindingType. If this is not feasible, how about providing some static constants? @OrezzerO

irvingos avatar Nov 23 '21 01:11 irvingos

这个改动会导致 API 不兼容,且降低了 type 的可扩展性,先关闭了。

HzjNeverStop avatar Dec 13 '22 09:12 HzjNeverStop