Documentation ¶
Overview ¶
* @Descripttion:配置相关基础函数 * @version: * @Author: lfzxs@qq.com * @Date: 2022-11-22 15:15:46 * @LastEditors: lfzxs@qq.com * @LastEditTime: 2022-11-25 15:24:30
* @Descripttion: nacos 配置 * 参考: https://gitee.com/chenfyu/beego/blob/develop/core/config/yaml/yaml.go * https://goframe.org/pages/viewpage.action?pageId=59864389 * @version: * @Author: lfzxs@qq.com * @Date: 2022-11-18 14:17:50 * @LastEditors: lfzxs@qq.com * @LastEditTime: 2022-11-25 15:47:09
* @Descripttion: YML解析 * @version: * @Author: lfzxs@qq.com * @Date: 2022-11-22 15:43:04 * @LastEditors: lfzxs@qq.com * @LastEditTime: 2023-03-24 15:50:08
Index ¶
- func CreateNacosCfg(cfg *nacosCfg) (err error)
- func ExpandExpEnv(env map[string]interface{}, exp string) (realValue string)
- func ExpandValueAnalysis(env map[string]interface{}, value string) (realValue string)
- func ParseYML(buf []byte) (data map[string]interface{}, err error)
- func ReplaceExp(env map[string]interface{}, content yaml.MapSlice) map[string]interface{}
- type YmlCfg
- func (self *YmlCfg) Available(ctx context.Context, resource ...string) (ok bool)
- func (self *YmlCfg) Data(ctx context.Context) (data map[string]interface{}, err error)
- func (self *YmlCfg) Get(ctx context.Context, pattern string) (value interface{}, err error)
- func (self *YmlCfg) GetValue(name string) interface{}
- func (self *YmlCfg) LoadData(data []byte) (err error)
- func (self *YmlCfg) LoadFromFile(filePath string) (err error)
- func (self *YmlCfg) LoadFromFolders(fileName string, searchFolds ...string) (err error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateNacosCfg ¶
func CreateNacosCfg(cfg *nacosCfg) (err error)
func ExpandExpEnv ¶
解析规则表达式
func ExpandValueAnalysis ¶
func ReplaceExp ¶
Types ¶
Click to show internal directories.
Click to hide internal directories.