@Test public void testGet(){ Card card = Cards.defaultCards().get("p7Tmfs2kxdGp2YN7LX2BMzEYCI2Q"); System.out.println(card.getCardType()); card = Cards.defaultCards().get("p7Tmfs0e7WUNurXRrEnaagja7SQs"); System.out.println(card.getCardType()); }
public Card get(String cardId) { String json = "{\"card_id\":\"%s\"}"; logger.debug("get card: {}", cardId); String url = WxEndpoint.get("url.card.get"); String response = wxClient.post(url, String.format(json, cardId)); CardWrapper cardWrapper = JsonMapper.defaultMapper().fromJson(response, CardWrapper.class); return cardWrapper.getCard(); }
Cards { public Card get(String cardId) { String json = "{\"card_id\":\"%s\"}"; logger.debug("get card: {}", cardId); String url = WxEndpoint.get("url.card.get"); String response = wxClient.post(url, String.format(json, cardId)); CardWrapper cardWrapper = JsonMapper.defaultMapper().fromJson(response, CardWrapper.class); return cardWrapper.getCard(); } }
Cards { public Card get(String cardId) { String json = "{\"card_id\":\"%s\"}"; logger.debug("get card: {}", cardId); String url = WxEndpoint.get("url.card.get"); String response = wxClient.post(url, String.format(json, cardId)); CardWrapper cardWrapper = JsonMapper.defaultMapper().fromJson(response, CardWrapper.class); return cardWrapper.getCard(); }  }
Cards { public Card get(String cardId) { String json = "{\"card_id\":\"%s\"}"; logger.debug("get card: {}", cardId); String url = WxEndpoint.get("url.card.get"); String response = wxClient.post(url, String.format(json, cardId)); CardWrapper cardWrapper = JsonMapper.defaultMapper().fromJson(response, CardWrapper.class); return cardWrapper.getCard(); }  static Cards defaultCards(); static Cards with(AppSetting appSetting); void setWxClient(WxClient wxClient); String groupon(Groupon groupon); String cash(Cash cash); String gift(Gift gift); String discount(Discount discount); String coupon(Coupon coupon); String member(Member member); int count(List<String> statusList); List<String> list(int offset, int count, List<String> statusList); Card get(String cardId); void setWhiteList(List<String> openIds, List<String> userNames); List<Color> listColors(); }
Cards { public Card get(String cardId) { String json = "{\"card_id\":\"%s\"}"; logger.debug("get card: {}", cardId); String url = WxEndpoint.get("url.card.get"); String response = wxClient.post(url, String.format(json, cardId)); CardWrapper cardWrapper = JsonMapper.defaultMapper().fromJson(response, CardWrapper.class); return cardWrapper.getCard(); }  static Cards defaultCards(); static Cards with(AppSetting appSetting); void setWxClient(WxClient wxClient); String groupon(Groupon groupon); String cash(Cash cash); String gift(Gift gift); String discount(Discount discount); String coupon(Coupon coupon); String member(Member member); int count(List<String> statusList); List<String> list(int offset, int count, List<String> statusList); Card get(String cardId); void setWhiteList(List<String> openIds, List<String> userNames); List<Color> listColors();  }