SetShareTarget sets the target of share claim. It panics if bb isn't a "share" claim type.
(t blob.Ref)
| 370 | // SetShareTarget sets the target of share claim. |
| 371 | // It panics if bb isn't a "share" claim type. |
| 372 | func (bb *Builder) SetShareTarget(t blob.Ref) *Builder { |
| 373 | if bb.Type() != TypeClaim || bb.ClaimType() != ShareClaim { |
| 374 | panic("called SetShareTarget on non-share") |
| 375 | } |
| 376 | bb.m["target"] = t.String() |
| 377 | return bb |
| 378 | } |
| 379 | |
| 380 | // SetShareSearch sets the search of share claim. |
| 381 | // q is assumed to be of type *search.SearchQuery. |