Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

实现Pojo配置数据源 #4

Open
oldratlee opened this issue Feb 12, 2013 · 0 comments
Open

实现Pojo配置数据源 #4

oldratlee opened this issue Feb 12, 2013 · 0 comments
Assignees
Labels
Milestone

Comments

@oldratlee
Copy link
Member

Pojo(强类型)是unicorn的首选使用方式,其它的数据源都是弱类型的。

使用getParameter返回Map可以用来表示弱类型数据。

即先读属性(getXxx),如果没有,再读getParameter中的值。

如果对应的Parameters中有属性名的Key,可以根据需要:

  • 日志 警告,因为推荐使用强类型配置。
  • 抛出异常,禁止这种不推荐的行为
@ghost ghost assigned oldratlee Feb 12, 2013
oldratlee added a commit that referenced this issue Feb 18, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant