Golang bosun-org-_third_party-github.com-aws-aws-sdk-go-aws-awsutil.Prettify类(方法)实例源码

下面列出了Golang bosun-org-_third_party-github.com-aws-aws-sdk-go-aws-awsutil.Prettify 类(方法)源码代码实例,从而了解它的用法。

作者:eswd    项目:bosu   
func ExampleCopyOf() {
	type Foo struct {
		A int
		B []*string
	}

	// Create the initial value
	str1 := "hello"
	str2 := "bye bye"
	f1 := &Foo{A: 1, B: []*string{&str1, &str2}}

	// Do the copy
	v := awsutil.CopyOf(f1)
	var f2 *Foo = v.(*Foo)

	// Print the result
	fmt.Println(awsutil.Prettify(f2))

	// Output:
	// {
	//   A: 1,
	//   B: ["hello","bye bye"]
	// }
}

作者:eswd    项目:bosu   
// String returns the string representation
func (s ListMetricsOutput) String() string {
	return awsutil.Prettify(s)
}


问题


面经


文章

微信
公众号

扫码关注公众号