com.github.sd4324530.fastweixin.company.message.QYMpNewsMsg Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of fastweixin Show documentation
Show all versions of fastweixin Show documentation
quickly department weixin server
package com.github.sd4324530.fastweixin.company.message;/**
* Created by Nottyjay on 2015/6/12.
*/
import com.alibaba.fastjson.annotation.JSONField;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
/**
* ====================================================================
* 上海聚攒软件开发有限公司
* --------------------------------------------------------------------
*
* @author wwj
* @version 1.0.beta
* ====================================================================
*/
public class QYMpNewsMsg extends QYBaseMsg {
private static final Integer MAX_ARTICLE_COUNT = 10;
@JSONField(name = "mpnews")
private Map news;
public QYMpNewsMsg() {
news = new HashMap();
}
public Map getNews() {
return news;
}
public void setNews(Map news) {
this.news = news;
}
public void setMpArticles(List articles){
if(articles.size() > MAX_ARTICLE_COUNT){
articles = articles.subList(0, MAX_ARTICLE_COUNT);
}
news.put("articles", articles);
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy