func (client *Client) UpdateRoleContext(
	ctx context.Context, name string, prms *graylog.RoleUpdateParams,
) (*graylog.Role, *ErrorInfo, error) {
	if name == "" {
		return nil, nil, errors.New("name is empty")
	}
	if prms == nil {
		return nil, nil, fmt.Errorf("role is nil")
	}
	u, err := client.Endpoints().Role(name)
	if err != nil {
		return nil, nil, err
	}
	role := &graylog.Role{}
	ei, err := client.callPut(ctx, u.String(), prms, role)
	return role, ei, err
}
// UpdateRoleContext updates a given role with a context.
UpdateRoleContext updates a given role with a context.
// UpdateRoleContext updates a given role with a context .
func (client *Client) UpdateRoleContext(
	ctx context.Context, name string, prms *graylog.RoleUpdateParams,
) (*graylog.Role, *ErrorInfo, error) {
	if name == "" {
		return nil, nil, errors.New("name is empty")
	}
	if prms == nil {
		return nil, nil, fmt.Errorf("role is nil")
	}
	u, err := client.Endpoints().Role(name)
	if err != nil {
		return nil, nil, err
	}
	role := &graylog.Role{}
	ei, err := client.callPut(ctx, u.String(), prms, role)
	return role, ei, err
}
func ( client * Client ) UpdateRoleContext ( ctx context . Context , name string , prms * graylog . RoleUpdateParams , ) ( * graylog . Role , * ErrorInfo , error ) { if name == " " { return nil , nil , errors . New ( " " ) } if prms == nil { return nil , nil , fmt . Errorf ( " " ) } u , err := client . Endpoints ( ) . Role ( name ) if err != nil { return nil , nil , err } role := & graylog . Role { } ei , err := client . callPut ( ctx , u . String ( ) , prms , role ) return role , ei , err }
UpdateRoleContext updates a given role with a context.
UpdateRoleContext updates a given role with a context .