All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.eworkcloud.wechat.WechatConfiguration Maven / Gradle / Ivy

There is a newer version: 1.1.8
Show newest version
package com.eworkcloud.wechat;

import com.eworkcloud.jackson.JacksonTemplate;
import com.eworkcloud.okhttp.OkHttpTemplate;
import org.springframework.boot.context.properties.EnableConfigurationProperties;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

import javax.annotation.Resource;

@Configuration
@EnableConfigurationProperties(WechatProperties.class)
public class WechatConfiguration {

    @Resource
    private WechatProperties wechatProperties;
    @Resource
    private OkHttpTemplate okHttpTemplate;
    @Resource
    private JacksonTemplate jacksonTemplate;

    @Bean
    public WechatTemplate wechatTemplate() {
        return new WechatTemplate(wechatProperties, okHttpTemplate, jacksonTemplate);
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy