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

添加自定义resftful接口 #13

Open
ShengyuanLu opened this issue Aug 13, 2020 · 0 comments
Open

添加自定义resftful接口 #13

ShengyuanLu opened this issue Aug 13, 2020 · 0 comments

Comments

@ShengyuanLu
Copy link

ShengyuanLu commented Aug 13, 2020

你好,我想确认一个问题:我想下面加一个自己的resftful接口,例如:/@in/api/abc
我目前的做法是新写一个类ABCHandler实现接口ViFunctionHandler,然后在VIApiHandler的构造方法里面添加注册:

 public VIApiHandler(){ 
         ...
        this.register(new CodeHandler());
        this.register(new ABCHandler()); // <-我添加的服务接口实现
 }

测试下来可以工作。请确认一下这种做法是不是合理?谢谢!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant