|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.foxinmy.weixin4j.api.BaseApi
com.foxinmy.weixin4j.mp.api.MpApi
com.foxinmy.weixin4j.mp.api.MenuApi
public class MenuApi
菜单相关API
| Constructor Summary | |
|---|---|
MenuApi(TokenManager tokenManager)
|
|
| Method Summary | |
|---|---|
String |
createCustomMenu(List<Button> buttons,
MenuMatchRule matchRule)
创建个性化菜单 |
ApiResult |
createMenu(List<Button> buttons)
自定义菜单 |
ApiResult |
deleteCustomMenu(String menuId)
删除个性化菜单 |
ApiResult |
deleteMenu()
删除菜单 |
List<Menu> |
getAllMenu()
查询全部菜单(包含个性化菜单) |
List<Button> |
getMenu()
查询菜单 |
List<Button> |
matchCustomMenu(String userId)
测试个性化菜单匹配结果 |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public MenuApi(TokenManager tokenManager)
| Method Detail |
|---|
public ApiResult createMenu(List<Button> buttons)
throws WeixinException
buttons - 菜单列表
WeixinExceptionButton
public List<Button> getMenu()
throws WeixinException
WeixinExceptionButton
public List<Menu> getAllMenu()
throws WeixinException
WeixinExceptionButton,
Menu
public ApiResult deleteMenu()
throws WeixinException
WeixinException
public String createCustomMenu(List<Button> buttons,
MenuMatchRule matchRule)
throws WeixinException
buttons - 菜单列表matchRule - 匹配规则 至少要有一个匹配信息是不为空
WeixinExceptionButton
public ApiResult deleteCustomMenu(String menuId)
throws WeixinException
WeixinException
public List<Button> matchCustomMenu(String userId)
throws WeixinException
userId - 可以是粉丝的OpenID,也可以是粉丝的微信号。
WeixinExceptionButton
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||