// GetBody retrieves a block body (transactions and uncles) from the database by
// hash, caching it if found.
190032
func (bc *BlockChain) GetBody(hash common.Hash) *types.Body {
	// Short circuit if the body's already in the cache, retrieve otherwise
	if cached, ok := bc.bodyCache.Get(hash); ok {
		body := cached.(*types.Body)
		return body
	}
	number := bc.hc.GetBlockNumber(hash)
	if number == nil {
		return nil
	}
	body := rawdb.ReadBody(bc.db, hash, *number)
	if body == nil {
		return nil
	}
	// Cache the found body for next time and return
	bc.bodyCache.Add(hash, body)
	return body
}
667746
func (s *NeutrinoClient) GetBlock(hash *chainhash.Hash) (*wire.MsgBlock, error) {
	// TODO(roasbeef): add a block cache?
	//  * which evication strategy? depends on use case
	//  Should the block cache be INSIDE neutrino instead of in btcwallet?
	block, err := s.CS.GetBlock(*hash)
	if err != nil {
		return nil, err
	}
	return block.MsgBlock(), nil
}
919514
func (r *RepositoryComment) GetBody() string {
	if r == nil || r.Body == nil {
		return ""
	}
	return *r.Body
}
304361
func (db *PublicRecord) GetBlock(hash *wire.ShaHash) (*ombjson.Block, error) {
	row := db.selectBlock.QueryRow(hash.String())
	block, err := scanBlockHead(row)
	if err != nil {
		return &ombjson.Block{}, err
	}

	bltns, err := db.getBlockBltns(block.Head.Height)
	if err != nil {
		return &ombjson.Block{}, err
	}

	endos, err := db.getBlockEndos(block.Head.Height)
	if err != nil {
		return &ombjson.Block{}, err
	}

	block.Bulletins = bltns
	block.Endorsements = endos
	return block, nil
}
424888
func ReadBody(db ethdb.Reader, hash common.Hash, number uint64) *types.Body {
	data := ReadBodyRLP(db, hash, number)
	if len(data) == 0 {
		return nil
	}
	body := new(types.Body)
	if err := rlp.Decode(bytes.NewReader(data), body); err != nil {
		log.Error("Invalid block body RLP", "hash", hash, "err", err)
		return nil
	}
	return body
}
764347
func (s *DeleteByQueryService) Body(body string) *DeleteByQueryService {
	s.body = body
	return s
}
820024
func (m *WebsocketMessage) Body() *String {
	return &String{m.chain, string(m.content)}
}
11089
func (v *RPC) GetBody() (o []byte) {
	if v != nil && v.Body != nil {
		return v.Body
	}

	return
}
1232378
func (g *GistComment) GetBody() string {
	if g == nil || g.Body == nil {
		return ""
	}
	return *g.Body
}
500318
func decodeBody(resp *http.Response, out interface{}) error {

	body, err := ioutil.ReadAll(resp.Body)
	if err != nil {
		return err
	}

	// Unmarshal the XML.
	if err = xml.Unmarshal(body, &out); err != nil {
		return err
	}

	return nil
}
1210119
func HasBody(db ethdb.Reader, hash common.Hash, number uint64) bool {
	if has, err := db.Has(blockBodyKey(number, hash)); !has || err != nil {
		return false
	}
	return true
}
1198883
func (t *TeamDiscussion) GetBodyVersion() string {
	if t == nil || t.BodyVersion == nil {
		return ""
	}
	return *t.BodyVersion
}
941221
func (r *Request) Body(data interface{}) *Request {
	switch t := data.(type) {
	case string:
		bf := bytes.NewBufferString(t)
		r.req.Body = ioutil.NopCloser(bf)
		r.req.ContentLength = int64(len(t))
	case []byte:
		bf := bytes.NewBuffer(t)
		r.req.Body = ioutil.NopCloser(bf)
		r.req.ContentLength = int64(len(t))
	}
	return r
}
1247987
func (s *GetExportOutput) SetBody(v []byte) *GetExportOutput {
	s.Body = v
	return s
}
1086788
func (p *Project) GetBody() string {
	if p == nil || p.Body == nil {
		return ""
	}
	return *p.Body
}
1063930
func (p *PullRequestReview) GetBody() string {
	if p == nil || p.Body == nil {
		return ""
	}
	return *p.Body
}
788957
func (p *ProjectOptions) GetBody() string {
	if p == nil || p.Body == nil {
		return ""
	}
	return *p.Body
}