// fixContent updates the fantasy data with content that can't be unmarshalled
// directly from XML
345821
func fixContent(c *FantasyContent) *FantasyContent {
	fixTeam(&c.Team)
	for i := range c.League.Teams {
		fixTeam(&c.League.Teams[i])
	}
	for i := range c.League.Standings {
		fixTeam(&c.League.Standings[i])
	}
	for i := range c.League.Players {
		fixPoints(&c.League.Players[i].PlayerPoints)
	}
	for i := range c.League.Scoreboard.Matchups {
		fixTeam(&c.League.Scoreboard.Matchups[i].Teams[0])
		fixTeam(&c.League.Scoreboard.Matchups[i].Teams[1])
	}
	return c
}
319241
func (builder *StoreValueCommandBuilder) WithContent(object *Object) *StoreValueCommandBuilder {
	setProtobufFromValue(builder.protobuf, object)
	builder.value = object
	return builder
}
962599
func WriteContent(target io.Writer, content Content, deps WriteContentDeps) error {
	checker := deps.NewChecker(content)
	source := checker.WrapReader(content.Data)

	if err := deps.Copy(target, source); err != nil {
		return errors.Annotate(err, "could not write resource to file")
	}

	if err := checker.Verify(); err != nil {
		return errors.Trace(err)
	}

	return nil
}
284439
func (b *BuilderFile) XMLContent() []byte {
	c := bytes.Join(bytes.Fields(XMLHeader), []byte(" "))
	c = append(append(c, b.Content()...), XMLFooter...)

	return c
}
89129
func (b *Binary) SetContent(c []byte) error {
	buff := &bytes.Buffer{}
	writer := base64.NewEncoder(base64.StdEncoding, buff)
	if b.Compressed {
		writer = gzip.NewWriter(writer)
	}
	_, err := writer.Write(c)
	if err != nil {
		return err
	}
	if err := writer.Close(); err != nil {
		return err
	}
	b.Content = buff.Bytes()
	return nil
}
1228711
func (s *Comment) SetContent(v string) *Comment {
	s.Content = &v
	return s
}
246843
func (s *CreateMultipartUploadInput) SetContentDisposition(v string) *CreateMultipartUploadInput {
	s.ContentDisposition = &v
	return s
}
152834
func (c *Client) GetFantasyContent(url string) (*FantasyContent, error) {
	return c.Provider.Get(url)
}
413687
func (s *GetSdkOutput) SetContentDisposition(v string) *GetSdkOutput {
	s.ContentDisposition = &v
	return s
}
787733
func (l *LanguageOpts) FormatContent(name string, content []byte) ([]byte, error) {
	if l.formatFunc != nil {
		return l.formatFunc(name, content)
	}
	return content, nil
}
1058839
func (d *driver) PutContent(ctx context.Context, path string, contents []byte) error {
	// max size for block blobs uploaded via single "Put Blob" for version after "2016-05-31"
	// https://docs.microsoft.com/en-us/rest/api/storageservices/put-blob#remarks
	const limit = 256 * 1024 * 1024
	if len(contents) > limit {
		return fmt.Errorf("uploading %d bytes with PutContent is not supported; limit: %d bytes", len(contents), limit)
	}

	// Historically, blobs uploaded via PutContent used to be of type AppendBlob
	// (https://github.com/docker/distribution/pull/1438). We can't replace
	// these blobs atomically via a single "Put Blob" operation without
	// deleting them first. Once we detect they are BlockBlob type, we can
	// overwrite them with an atomically "Put Blob" operation.
	//
	// While we delete the blob and create a new one, there will be a small
	// window of inconsistency and if the Put Blob fails, we may end up with
	// losing the existing data while migrating it to BlockBlob type. However,
	// expectation is the clients pushing will be retrying when they get an error
	// response.
	blobRef := d.client.GetContainerReference(d.container).GetBlobReference(path)
	err := blobRef.GetProperties(nil)
	if err != nil && !is404(err) {
		return fmt.Errorf("failed to get blob properties: %v", err)
	}
	if err == nil && blobRef.Properties.BlobType != azure.BlobTypeBlock {
		if err := blobRef.Delete(nil); err != nil {
			return fmt.Errorf("failed to delete legacy blob (%s): %v", blobRef.Properties.BlobType, err)
		}
	}

	r := bytes.NewReader(contents)
	// reset properties to empty before doing overwrite
	blobRef.Properties = azure.BlobProperties{}
	return blobRef.CreateBlockBlobFromReader(r, nil)
}
123879
func (s *PutFileInput) SetFileContent(v []byte) *PutFileInput {
	s.FileContent = v
	return s
}
572242
func NewContent(contentType string, value string) *Content {
	return &Content{
		Type:  contentType,
		Value: value,
	}
}
1371923
func (s *SendAnnouncementInput) SetContent(v *Content) *SendAnnouncementInput {
	s.Content = v
	return s
}
965379
func (s *GetObjectOutput) SetContentDisposition(v string) *GetObjectOutput {
	s.ContentDisposition = &v
	return s
}
1269089
func (s SourceFilesystems) IsContent(filename string) bool {
	return s.Content.Contains(filename)
}
382244
func (s *GetCredentialReportOutput) SetContent(v []byte) *GetCredentialReportOutput {
	s.Content = v
	return s
}