func (termGroup *TermGroup) csomBuilderEntry() csom.Builder {
	b := termGroup.csomEntry.Clone()
	b.AddObject(csom.NewObjectMethod("GetGroup", []string{
		fmt.Sprintf(`<Parameter Type="String">%s</Parameter>`, termGroup.id),
	}), nil)
	return b
}
csomBuilderEntry gets CSOM builder entry
package api
import (
	"fmt"
	"strings"
	"github.com/koltyakov/gosip/csom"
)
type TermGroups struct {
	client   *HTTPClient
	config   *RequestConfig
	endpoint string
	csomEntry csom.Builder
}
func (termGroups *TermGroups) Get() ([]map[string]interface{}, error) {
	b := termGroups.csomEntry.Clone()
	b.AddAction(csom.NewQueryWithProps([]string{
		`<Property Name="Groups" SelectAll="true" />`,
	}), nil)
	return csomRespChildItemsInProp(termGroups.client, termGroups.endpoint, termGroups.config, b, "Groups")
}
func (termGroups *TermGroups) GetByID(groupGUID string) *TermGroup {
	return &TermGroup{
		client:   termGroups.client,
		endpoint: termGroups.endpoint,
		config:   termGroups.config,
		id:       trimTaxonomyGUID(groupGUID),
		csomEntry:   termGroups.csomEntry.Clone(),
		selectProps: []string{},
	}
}
func (termGroups *TermGroups) Add(name string, guid string) (map[string]interface{}, error) {
	b := termGroups.csomEntry.Clone()
	b.AddObject(csom.NewObjectMethod("CreateGroup", []string{
		fmt.Sprintf(`<Parameter Type="String">%s</Parameter>`, name),
		fmt.Sprintf(`<Parameter Type="String">%s</Parameter>`, guid),
	}), nil)
	b.AddAction(csom.NewQueryWithProps([]string{}), nil)
	return csomResponse(termGroups.client, termGroups.endpoint, termGroups.config, b)
}
type TermGroup struct {
	client   *HTTPClient
	config   *RequestConfig
	endpoint string
	id string
	csomEntry   csom.Builder
	termStore   *TermStore
	selectProps []string
}