···
+
func (t *GitRefUpdate) MarshalCBOR(w io.Writer) error {
_, err := w.Write(cbg.CborNull)
···
cw := cbg.NewCborWriter(w)
+
if _, err := cw.Write([]byte{168}); err != nil {
+
// t.Ref (string) (string)
+
if len("ref") > 1000000 {
+
return xerrors.Errorf("Value in field \"ref\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("ref"))); err != nil {
+
if _, err := cw.WriteString(string("ref")); err != nil {
+
if len(t.Ref) > 1000000 {
+
return xerrors.Errorf("Value in field t.Ref was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len(t.Ref))); err != nil {
+
if _, err := cw.WriteString(string(t.Ref)); err != nil {
+
// t.Meta (tangled.GitRefUpdate_Meta) (struct)
+
if len("meta") > 1000000 {
+
return xerrors.Errorf("Value in field \"meta\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("meta"))); err != nil {
+
if _, err := cw.WriteString(string("meta")); err != nil {
+
if err := t.Meta.MarshalCBOR(cw); err != nil {
+
// t.LexiconTypeID (string) (string)
+
if len("$type") > 1000000 {
+
return xerrors.Errorf("Value in field \"$type\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("$type"))); err != nil {
+
if _, err := cw.WriteString(string("$type")); err != nil {
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("sh.tangled.git.refUpdate"))); err != nil {
+
if _, err := cw.WriteString(string("sh.tangled.git.refUpdate")); err != nil {
+
// t.NewSha (string) (string)
+
if len("newSha") > 1000000 {
+
return xerrors.Errorf("Value in field \"newSha\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("newSha"))); err != nil {
+
if _, err := cw.WriteString(string("newSha")); err != nil {
+
if len(t.NewSha) > 1000000 {
+
return xerrors.Errorf("Value in field t.NewSha was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len(t.NewSha))); err != nil {
+
if _, err := cw.WriteString(string(t.NewSha)); err != nil {
+
// t.OldSha (string) (string)
+
if len("oldSha") > 1000000 {
+
return xerrors.Errorf("Value in field \"oldSha\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("oldSha"))); err != nil {
+
if _, err := cw.WriteString(string("oldSha")); err != nil {
+
if len(t.OldSha) > 1000000 {
+
return xerrors.Errorf("Value in field t.OldSha was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len(t.OldSha))); err != nil {
+
if _, err := cw.WriteString(string(t.OldSha)); err != nil {
+
// t.RepoDid (string) (string)
+
if len("repoDid") > 1000000 {
+
return xerrors.Errorf("Value in field \"repoDid\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("repoDid"))); err != nil {
+
if _, err := cw.WriteString(string("repoDid")); err != nil {
+
if len(t.RepoDid) > 1000000 {
+
return xerrors.Errorf("Value in field t.RepoDid was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len(t.RepoDid))); err != nil {
+
if _, err := cw.WriteString(string(t.RepoDid)); err != nil {
+
// t.RepoName (string) (string)
+
if len("repoName") > 1000000 {
+
return xerrors.Errorf("Value in field \"repoName\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("repoName"))); err != nil {
+
if _, err := cw.WriteString(string("repoName")); err != nil {
+
if len(t.RepoName) > 1000000 {
+
return xerrors.Errorf("Value in field t.RepoName was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len(t.RepoName))); err != nil {
+
if _, err := cw.WriteString(string(t.RepoName)); err != nil {
+
// t.CommitterDid (string) (string)
+
if len("committerDid") > 1000000 {
+
return xerrors.Errorf("Value in field \"committerDid\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("committerDid"))); err != nil {
+
if _, err := cw.WriteString(string("committerDid")); err != nil {
+
if len(t.CommitterDid) > 1000000 {
+
return xerrors.Errorf("Value in field t.CommitterDid was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len(t.CommitterDid))); err != nil {
+
if _, err := cw.WriteString(string(t.CommitterDid)); err != nil {
+
func (t *GitRefUpdate) UnmarshalCBOR(r io.Reader) (err error) {
cr := cbg.NewCborReader(r)
···
if extra > cbg.MaxLength {
+
return fmt.Errorf("GitRefUpdate: map struct too large (%d)", extra)
+
nameBuf := make([]byte, 12)
for i := uint64(0); i < n; i++ {
nameLen, ok, err := cbg.ReadFullStringIntoBuf(cr, nameBuf, 1000000)
···
switch string(nameBuf[:nameLen]) {
+
// t.Ref (string) (string)
+
sval, err := cbg.ReadStringWithMax(cr, 1000000)
+
// t.Meta (tangled.GitRefUpdate_Meta) (struct)
+
b, err := cr.ReadByte()
+
if b != cbg.CborNull[0] {
+
if err := cr.UnreadByte(); err != nil {
+
t.Meta = new(GitRefUpdate_Meta)
+
if err := t.Meta.UnmarshalCBOR(cr); err != nil {
+
return xerrors.Errorf("unmarshaling t.Meta pointer: %w", err)
+
// t.LexiconTypeID (string) (string)
+
sval, err := cbg.ReadStringWithMax(cr, 1000000)
+
t.LexiconTypeID = string(sval)
+
// t.NewSha (string) (string)
+
sval, err := cbg.ReadStringWithMax(cr, 1000000)
+
t.NewSha = string(sval)
+
// t.OldSha (string) (string)
+
sval, err := cbg.ReadStringWithMax(cr, 1000000)
+
t.OldSha = string(sval)
+
// t.RepoDid (string) (string)
+
sval, err := cbg.ReadStringWithMax(cr, 1000000)
+
t.RepoDid = string(sval)
+
// t.RepoName (string) (string)
+
sval, err := cbg.ReadStringWithMax(cr, 1000000)
+
t.RepoName = string(sval)
+
// t.CommitterDid (string) (string)
+
sval, err := cbg.ReadStringWithMax(cr, 1000000)
+
t.CommitterDid = string(sval)
···
+
func (t *GitRefUpdate_Meta_CommitCount) MarshalCBOR(w io.Writer) error {
_, err := w.Write(cbg.CborNull)
cw := cbg.NewCborWriter(w)
+
if _, err := cw.Write(cbg.CborEncodeMajorType(cbg.MajMap, uint64(fieldCount))); err != nil {
+
// t.ByEmail ([]*tangled.GitRefUpdate_Meta_CommitCount_ByEmail_Elem) (slice)
+
if len("byEmail") > 1000000 {
+
return xerrors.Errorf("Value in field \"byEmail\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("byEmail"))); err != nil {
+
if _, err := cw.WriteString(string("byEmail")); err != nil {
+
if len(t.ByEmail) > 8192 {
+
return xerrors.Errorf("Slice value in field t.ByEmail was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajArray, uint64(len(t.ByEmail))); err != nil {
+
for _, v := range t.ByEmail {
+
if err := v.MarshalCBOR(cw); err != nil {
+
func (t *GitRefUpdate_Meta_CommitCount) UnmarshalCBOR(r io.Reader) (err error) {
+
*t = GitRefUpdate_Meta_CommitCount{}
+
cr := cbg.NewCborReader(r)
+
maj, extra, err := cr.ReadHeader()
+
err = io.ErrUnexpectedEOF
+
return fmt.Errorf("cbor input should be of type map")
+
if extra > cbg.MaxLength {
+
return fmt.Errorf("GitRefUpdate_Meta_CommitCount: map struct too large (%d)", extra)
+
nameBuf := make([]byte, 7)
+
for i := uint64(0); i < n; i++ {
+
nameLen, ok, err := cbg.ReadFullStringIntoBuf(cr, nameBuf, 1000000)
+
// Field doesn't exist on this type, so ignore it
+
if err := cbg.ScanForLinks(cr, func(cid.Cid) {}); err != nil {
+
switch string(nameBuf[:nameLen]) {
+
// t.ByEmail ([]*tangled.GitRefUpdate_Meta_CommitCount_ByEmail_Elem) (slice)
+
maj, extra, err = cr.ReadHeader()
+
return fmt.Errorf("t.ByEmail: array too large (%d)", extra)
+
if maj != cbg.MajArray {
+
return fmt.Errorf("expected cbor array")
+
t.ByEmail = make([]*GitRefUpdate_Meta_CommitCount_ByEmail_Elem, extra)
+
for i := 0; i < int(extra); i++ {
+
b, err := cr.ReadByte()
+
if b != cbg.CborNull[0] {
+
if err := cr.UnreadByte(); err != nil {
+
t.ByEmail[i] = new(GitRefUpdate_Meta_CommitCount_ByEmail_Elem)
+
if err := t.ByEmail[i].UnmarshalCBOR(cr); err != nil {
+
return xerrors.Errorf("unmarshaling t.ByEmail[i] pointer: %w", err)
+
// Field doesn't exist on this type, so ignore it
+
if err := cbg.ScanForLinks(r, func(cid.Cid) {}); err != nil {
+
func (t *GitRefUpdate_Meta_CommitCount_ByEmail_Elem) MarshalCBOR(w io.Writer) error {
+
_, err := w.Write(cbg.CborNull)
+
cw := cbg.NewCborWriter(w)
+
if _, err := cw.Write([]byte{162}); err != nil {
+
// t.Count (int64) (int64)
+
if len("count") > 1000000 {
+
return xerrors.Errorf("Value in field \"count\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("count"))); err != nil {
+
if _, err := cw.WriteString(string("count")); err != nil {
+
if err := cw.WriteMajorTypeHeader(cbg.MajUnsignedInt, uint64(t.Count)); err != nil {
+
if err := cw.WriteMajorTypeHeader(cbg.MajNegativeInt, uint64(-t.Count-1)); err != nil {
+
// t.Email (string) (string)
+
if len("email") > 1000000 {
+
return xerrors.Errorf("Value in field \"email\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("email"))); err != nil {
+
if _, err := cw.WriteString(string("email")); err != nil {
+
if len(t.Email) > 1000000 {
+
return xerrors.Errorf("Value in field t.Email was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len(t.Email))); err != nil {
+
if _, err := cw.WriteString(string(t.Email)); err != nil {
+
func (t *GitRefUpdate_Meta_CommitCount_ByEmail_Elem) UnmarshalCBOR(r io.Reader) (err error) {
+
*t = GitRefUpdate_Meta_CommitCount_ByEmail_Elem{}
cr := cbg.NewCborReader(r)
···
if extra > cbg.MaxLength {
+
return fmt.Errorf("GitRefUpdate_Meta_CommitCount_ByEmail_Elem: map struct too large (%d)", extra)
+
nameBuf := make([]byte, 5)
for i := uint64(0); i < n; i++ {
nameLen, ok, err := cbg.ReadFullStringIntoBuf(cr, nameBuf, 1000000)
···
switch string(nameBuf[:nameLen]) {
+
// t.Count (int64) (int64)
+
maj, extra, err := cr.ReadHeader()
+
case cbg.MajUnsignedInt:
+
return fmt.Errorf("int64 positive overflow")
+
case cbg.MajNegativeInt:
+
return fmt.Errorf("int64 negative overflow")
+
return fmt.Errorf("wrong type for int64 field: %d", maj)
+
t.Count = int64(extraI)
+
// t.Email (string) (string)
sval, err := cbg.ReadStringWithMax(cr, 1000000)
···
···
+
func (t *Pipeline) MarshalCBOR(w io.Writer) error {
_, err := w.Write(cbg.CborNull)
cw := cbg.NewCborWriter(w)
+
if _, err := cw.Write([]byte{163}); err != nil {
···
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("sh.tangled.pipeline"))); err != nil {
+
if _, err := cw.WriteString(string("sh.tangled.pipeline")); err != nil {
+
// t.Workflows ([]*tangled.Pipeline_Workflow) (slice)
+
if len("workflows") > 1000000 {
+
return xerrors.Errorf("Value in field \"workflows\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("workflows"))); err != nil {
+
if _, err := cw.WriteString(string("workflows")); err != nil {
+
if len(t.Workflows) > 8192 {
+
return xerrors.Errorf("Slice value in field t.Workflows was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajArray, uint64(len(t.Workflows))); err != nil {
+
for _, v := range t.Workflows {
+
if err := v.MarshalCBOR(cw); err != nil {
+
// t.TriggerMetadata (tangled.Pipeline_TriggerMetadata) (struct)
+
if len("triggerMetadata") > 1000000 {
+
return xerrors.Errorf("Value in field \"triggerMetadata\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("triggerMetadata"))); err != nil {
+
if _, err := cw.WriteString(string("triggerMetadata")); err != nil {
+
if err := t.TriggerMetadata.MarshalCBOR(cw); err != nil {
+
func (t *Pipeline) UnmarshalCBOR(r io.Reader) (err error) {
cr := cbg.NewCborReader(r)
···
if extra > cbg.MaxLength {
+
return fmt.Errorf("Pipeline: map struct too large (%d)", extra)
+
nameBuf := make([]byte, 15)
for i := uint64(0); i < n; i++ {
nameLen, ok, err := cbg.ReadFullStringIntoBuf(cr, nameBuf, 1000000)
···
t.LexiconTypeID = string(sval)
+
// t.Workflows ([]*tangled.Pipeline_Workflow) (slice)
+
maj, extra, err = cr.ReadHeader()
+
return fmt.Errorf("t.Workflows: array too large (%d)", extra)
+
if maj != cbg.MajArray {
+
return fmt.Errorf("expected cbor array")
+
t.Workflows = make([]*Pipeline_Workflow, extra)
+
for i := 0; i < int(extra); i++ {
+
b, err := cr.ReadByte()
+
if b != cbg.CborNull[0] {
+
if err := cr.UnreadByte(); err != nil {
+
t.Workflows[i] = new(Pipeline_Workflow)
+
if err := t.Workflows[i].UnmarshalCBOR(cr); err != nil {
+
return xerrors.Errorf("unmarshaling t.Workflows[i] pointer: %w", err)
+
// t.TriggerMetadata (tangled.Pipeline_TriggerMetadata) (struct)
+
case "triggerMetadata":
+
b, err := cr.ReadByte()
+
if b != cbg.CborNull[0] {
+
if err := cr.UnreadByte(); err != nil {
+
t.TriggerMetadata = new(Pipeline_TriggerMetadata)
+
if err := t.TriggerMetadata.UnmarshalCBOR(cr); err != nil {
+
return xerrors.Errorf("unmarshaling t.TriggerMetadata pointer: %w", err)
···
+
func (t *Pipeline_ManualTriggerData) MarshalCBOR(w io.Writer) error {
_, err := w.Write(cbg.CborNull)
cw := cbg.NewCborWriter(w)
+
if _, err := cw.Write(cbg.CborEncodeMajorType(cbg.MajMap, uint64(fieldCount))); err != nil {
+
// t.Inputs ([]*tangled.Pipeline_ManualTriggerData_Inputs_Elem) (slice)
+
if len("inputs") > 1000000 {
+
return xerrors.Errorf("Value in field \"inputs\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("inputs"))); err != nil {
+
if _, err := cw.WriteString(string("inputs")); err != nil {
+
if len(t.Inputs) > 8192 {
+
return xerrors.Errorf("Slice value in field t.Inputs was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajArray, uint64(len(t.Inputs))); err != nil {
+
for _, v := range t.Inputs {
+
if err := v.MarshalCBOR(cw); err != nil {
+
func (t *Pipeline_ManualTriggerData) UnmarshalCBOR(r io.Reader) (err error) {
+
*t = Pipeline_ManualTriggerData{}
cr := cbg.NewCborReader(r)
···
if extra > cbg.MaxLength {
+
return fmt.Errorf("Pipeline_ManualTriggerData: map struct too large (%d)", extra)
+
nameBuf := make([]byte, 6)
for i := uint64(0); i < n; i++ {
nameLen, ok, err := cbg.ReadFullStringIntoBuf(cr, nameBuf, 1000000)
···
switch string(nameBuf[:nameLen]) {
+
// t.Inputs ([]*tangled.Pipeline_ManualTriggerData_Inputs_Elem) (slice)
+
maj, extra, err = cr.ReadHeader()
+
return fmt.Errorf("t.Inputs: array too large (%d)", extra)
+
if maj != cbg.MajArray {
+
return fmt.Errorf("expected cbor array")
+
t.Inputs = make([]*Pipeline_ManualTriggerData_Inputs_Elem, extra)
+
for i := 0; i < int(extra); i++ {
+
b, err := cr.ReadByte()
+
if b != cbg.CborNull[0] {
+
if err := cr.UnreadByte(); err != nil {
+
t.Inputs[i] = new(Pipeline_ManualTriggerData_Inputs_Elem)
+
if err := t.Inputs[i].UnmarshalCBOR(cr); err != nil {
+
return xerrors.Errorf("unmarshaling t.Inputs[i] pointer: %w", err)
···
+
func (t *Pipeline_ManualTriggerData_Inputs_Elem) MarshalCBOR(w io.Writer) error {
_, err := w.Write(cbg.CborNull)
cw := cbg.NewCborWriter(w)
+
if _, err := cw.Write([]byte{162}); err != nil {
+
// t.Key (string) (string)
+
if len("key") > 1000000 {
+
return xerrors.Errorf("Value in field \"key\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("key"))); err != nil {
+
if _, err := cw.WriteString(string("key")); err != nil {
+
if len(t.Key) > 1000000 {
+
return xerrors.Errorf("Value in field t.Key was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len(t.Key))); err != nil {
+
if _, err := cw.WriteString(string(t.Key)); err != nil {
+
// t.Value (string) (string)
+
if len("value") > 1000000 {
+
return xerrors.Errorf("Value in field \"value\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("value"))); err != nil {
+
if _, err := cw.WriteString(string("value")); err != nil {
+
if len(t.Value) > 1000000 {
+
return xerrors.Errorf("Value in field t.Value was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len(t.Value))); err != nil {
+
if _, err := cw.WriteString(string(t.Value)); err != nil {
+
func (t *Pipeline_ManualTriggerData_Inputs_Elem) UnmarshalCBOR(r io.Reader) (err error) {
+
*t = Pipeline_ManualTriggerData_Inputs_Elem{}
cr := cbg.NewCborReader(r)
···
if extra > cbg.MaxLength {
+
return fmt.Errorf("Pipeline_ManualTriggerData_Inputs_Elem: map struct too large (%d)", extra)
+
nameBuf := make([]byte, 5)
for i := uint64(0); i < n; i++ {
nameLen, ok, err := cbg.ReadFullStringIntoBuf(cr, nameBuf, 1000000)
···
switch string(nameBuf[:nameLen]) {
+
// t.Key (string) (string)
+
sval, err := cbg.ReadStringWithMax(cr, 1000000)
+
// t.Value (string) (string)
+
sval, err := cbg.ReadStringWithMax(cr, 1000000)
···
+
func (t *PipelineStatus) MarshalCBOR(w io.Writer) error {
+
_, err := w.Write(cbg.CborNull)
+
cw := cbg.NewCborWriter(w)
+
if _, err := cw.Write(cbg.CborEncodeMajorType(cbg.MajMap, uint64(fieldCount))); err != nil {
+
// t.LexiconTypeID (string) (string)
+
if len("$type") > 1000000 {
+
return xerrors.Errorf("Value in field \"$type\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("$type"))); err != nil {
+
if _, err := cw.WriteString(string("$type")); err != nil {
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("sh.tangled.pipeline.status"))); err != nil {
+
if _, err := cw.WriteString(string("sh.tangled.pipeline.status")); err != nil {
+
// t.Error (string) (string)
+
if len("error") > 1000000 {
+
return xerrors.Errorf("Value in field \"error\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("error"))); err != nil {
+
if _, err := cw.WriteString(string("error")); err != nil {
+
if _, err := cw.Write(cbg.CborNull); err != nil {
+
if len(*t.Error) > 1000000 {
+
return xerrors.Errorf("Value in field t.Error was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len(*t.Error))); err != nil {
+
if _, err := cw.WriteString(string(*t.Error)); err != nil {
+
// t.Status (string) (string)
+
if len("status") > 1000000 {
+
return xerrors.Errorf("Value in field \"status\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("status"))); err != nil {
+
if _, err := cw.WriteString(string("status")); err != nil {
+
if len(t.Status) > 1000000 {
+
return xerrors.Errorf("Value in field t.Status was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len(t.Status))); err != nil {
+
if _, err := cw.WriteString(string(t.Status)); err != nil {
+
// t.ExitCode (int64) (int64)
+
if len("exitCode") > 1000000 {
+
return xerrors.Errorf("Value in field \"exitCode\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("exitCode"))); err != nil {
+
if _, err := cw.WriteString(string("exitCode")); err != nil {
+
if _, err := cw.Write(cbg.CborNull); err != nil {
+
if err := cw.WriteMajorTypeHeader(cbg.MajUnsignedInt, uint64(*t.ExitCode)); err != nil {
+
if err := cw.WriteMajorTypeHeader(cbg.MajNegativeInt, uint64(-*t.ExitCode-1)); err != nil {
+
// t.Pipeline (string) (string)
+
if len("pipeline") > 1000000 {
+
return xerrors.Errorf("Value in field \"pipeline\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("pipeline"))); err != nil {
+
if _, err := cw.WriteString(string("pipeline")); err != nil {
+
if len(t.Pipeline) > 1000000 {
+
return xerrors.Errorf("Value in field t.Pipeline was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len(t.Pipeline))); err != nil {
+
if _, err := cw.WriteString(string(t.Pipeline)); err != nil {
+
// t.Workflow (string) (string)
+
if len("workflow") > 1000000 {
+
return xerrors.Errorf("Value in field \"workflow\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("workflow"))); err != nil {
+
if _, err := cw.WriteString(string("workflow")); err != nil {
+
if len(t.Workflow) > 1000000 {
+
return xerrors.Errorf("Value in field t.Workflow was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len(t.Workflow))); err != nil {
+
if _, err := cw.WriteString(string(t.Workflow)); err != nil {
+
// t.CreatedAt (string) (string)
+
if len("createdAt") > 1000000 {
+
return xerrors.Errorf("Value in field \"createdAt\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("createdAt"))); err != nil {
+
if _, err := cw.WriteString(string("createdAt")); err != nil {
+
if len(t.CreatedAt) > 1000000 {
+
return xerrors.Errorf("Value in field t.CreatedAt was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len(t.CreatedAt))); err != nil {
+
if _, err := cw.WriteString(string(t.CreatedAt)); err != nil {
+
func (t *PipelineStatus) UnmarshalCBOR(r io.Reader) (err error) {
+
cr := cbg.NewCborReader(r)
+
maj, extra, err := cr.ReadHeader()
+
err = io.ErrUnexpectedEOF
+
return fmt.Errorf("cbor input should be of type map")
+
if extra > cbg.MaxLength {
+
return fmt.Errorf("PipelineStatus: map struct too large (%d)", extra)
+
nameBuf := make([]byte, 9)
+
for i := uint64(0); i < n; i++ {
+
nameLen, ok, err := cbg.ReadFullStringIntoBuf(cr, nameBuf, 1000000)
+
// Field doesn't exist on this type, so ignore it
+
if err := cbg.ScanForLinks(cr, func(cid.Cid) {}); err != nil {
+
switch string(nameBuf[:nameLen]) {
+
// t.LexiconTypeID (string) (string)
+
sval, err := cbg.ReadStringWithMax(cr, 1000000)
+
t.LexiconTypeID = string(sval)
+
// t.Error (string) (string)
+
b, err := cr.ReadByte()
+
if b != cbg.CborNull[0] {
+
if err := cr.UnreadByte(); err != nil {
+
sval, err := cbg.ReadStringWithMax(cr, 1000000)
+
t.Error = (*string)(&sval)
+
// t.Status (string) (string)
+
sval, err := cbg.ReadStringWithMax(cr, 1000000)
+
t.Status = string(sval)
+
// t.ExitCode (int64) (int64)
+
b, err := cr.ReadByte()
+
if b != cbg.CborNull[0] {
+
if err := cr.UnreadByte(); err != nil {
+
maj, extra, err := cr.ReadHeader()
+
case cbg.MajUnsignedInt:
+
return fmt.Errorf("int64 positive overflow")
+
case cbg.MajNegativeInt:
+
return fmt.Errorf("int64 negative overflow")
+
return fmt.Errorf("wrong type for int64 field: %d", maj)
+
t.ExitCode = (*int64)(&extraI)
+
// t.Pipeline (string) (string)
+
sval, err := cbg.ReadStringWithMax(cr, 1000000)
+
t.Pipeline = string(sval)
+
// t.Workflow (string) (string)
+
sval, err := cbg.ReadStringWithMax(cr, 1000000)
+
t.Workflow = string(sval)
+
// t.CreatedAt (string) (string)
+
sval, err := cbg.ReadStringWithMax(cr, 1000000)
+
t.CreatedAt = string(sval)
+
// Field doesn't exist on this type, so ignore it
+
if err := cbg.ScanForLinks(r, func(cid.Cid) {}); err != nil {
func (t *Pipeline_Step) MarshalCBOR(w io.Writer) error {
_, err := w.Write(cbg.CborNull)
···
func (t *Pipeline_Workflow) MarshalCBOR(w io.Writer) error {
_, err := w.Write(cbg.CborNull)
···
+
func (t *Pipeline_Workflow_Environment_Elem) MarshalCBOR(w io.Writer) error {
_, err := w.Write(cbg.CborNull)
···
cw := cbg.NewCborWriter(w)
+
if _, err := cw.Write([]byte{162}); err != nil {
+
// t.Key (string) (string)
+
if len("key") > 1000000 {
+
return xerrors.Errorf("Value in field \"key\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("key"))); err != nil {
+
if _, err := cw.WriteString(string("key")); err != nil {
+
if len(t.Key) > 1000000 {
+
return xerrors.Errorf("Value in field t.Key was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len(t.Key))); err != nil {
+
if _, err := cw.WriteString(string(t.Key)); err != nil {
+
// t.Value (string) (string)
+
if len("value") > 1000000 {
+
return xerrors.Errorf("Value in field \"value\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("value"))); err != nil {
+
if _, err := cw.WriteString(string("value")); err != nil {
+
if len(t.Value) > 1000000 {
+
return xerrors.Errorf("Value in field t.Value was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len(t.Value))); err != nil {
+
if _, err := cw.WriteString(string(t.Value)); err != nil {
+
func (t *Pipeline_Workflow_Environment_Elem) UnmarshalCBOR(r io.Reader) (err error) {
+
*t = Pipeline_Workflow_Environment_Elem{}
cr := cbg.NewCborReader(r)
···
if extra > cbg.MaxLength {
+
return fmt.Errorf("Pipeline_Workflow_Environment_Elem: map struct too large (%d)", extra)
+
nameBuf := make([]byte, 5)
for i := uint64(0); i < n; i++ {
nameLen, ok, err := cbg.ReadFullStringIntoBuf(cr, nameBuf, 1000000)
···
switch string(nameBuf[:nameLen]) {
+
// t.Key (string) (string)
sval, err := cbg.ReadStringWithMax(cr, 1000000)
···
+
// t.Value (string) (string)
+
sval, err := cbg.ReadStringWithMax(cr, 1000000)
···
+
func (t *Repo) MarshalCBOR(w io.Writer) error {
+
_, err := w.Write(cbg.CborNull)
+
cw := cbg.NewCborWriter(w)
+
if t.Description == nil {
+
if _, err := cw.Write(cbg.CborEncodeMajorType(cbg.MajMap, uint64(fieldCount))); err != nil {
+
// t.Knot (string) (string)
+
if len("knot") > 1000000 {
+
return xerrors.Errorf("Value in field \"knot\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("knot"))); err != nil {
+
if _, err := cw.WriteString(string("knot")); err != nil {
+
if len(t.Knot) > 1000000 {
+
return xerrors.Errorf("Value in field t.Knot was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len(t.Knot))); err != nil {
+
if _, err := cw.WriteString(string(t.Knot)); err != nil {
+
// t.Name (string) (string)
+
if len("name") > 1000000 {
+
return xerrors.Errorf("Value in field \"name\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("name"))); err != nil {
+
if _, err := cw.WriteString(string("name")); err != nil {
+
if len(t.Name) > 1000000 {
+
return xerrors.Errorf("Value in field t.Name was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len(t.Name))); err != nil {
+
if _, err := cw.WriteString(string(t.Name)); err != nil {
+
// t.LexiconTypeID (string) (string)
+
if len("$type") > 1000000 {
+
return xerrors.Errorf("Value in field \"$type\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("$type"))); err != nil {
+
if _, err := cw.WriteString(string("$type")); err != nil {
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("sh.tangled.repo"))); err != nil {
+
if _, err := cw.WriteString(string("sh.tangled.repo")); err != nil {
+
// t.Owner (string) (string)
+
if len("owner") > 1000000 {
+
return xerrors.Errorf("Value in field \"owner\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("owner"))); err != nil {
+
if _, err := cw.WriteString(string("owner")); err != nil {
+
if len(t.Owner) > 1000000 {
+
return xerrors.Errorf("Value in field t.Owner was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len(t.Owner))); err != nil {
+
if _, err := cw.WriteString(string(t.Owner)); err != nil {
+
// t.Source (string) (string)
+
if len("source") > 1000000 {
+
return xerrors.Errorf("Value in field \"source\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("source"))); err != nil {
+
if _, err := cw.WriteString(string("source")); err != nil {
+
if _, err := cw.Write(cbg.CborNull); err != nil {
+
if len(*t.Source) > 1000000 {
+
return xerrors.Errorf("Value in field t.Source was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len(*t.Source))); err != nil {
+
if _, err := cw.WriteString(string(*t.Source)); err != nil {
+
// t.Spindle (string) (string)
+
if len("spindle") > 1000000 {
+
return xerrors.Errorf("Value in field \"spindle\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("spindle"))); err != nil {
+
if _, err := cw.WriteString(string("spindle")); err != nil {
+
if _, err := cw.Write(cbg.CborNull); err != nil {
+
if len(*t.Spindle) > 1000000 {
+
return xerrors.Errorf("Value in field t.Spindle was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len(*t.Spindle))); err != nil {
+
if _, err := cw.WriteString(string(*t.Spindle)); err != nil {
+
// t.CreatedAt (string) (string)
+
if len("createdAt") > 1000000 {
+
return xerrors.Errorf("Value in field \"createdAt\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("createdAt"))); err != nil {
+
if _, err := cw.WriteString(string("createdAt")); err != nil {
+
if len(t.CreatedAt) > 1000000 {
+
return xerrors.Errorf("Value in field t.CreatedAt was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len(t.CreatedAt))); err != nil {
+
if _, err := cw.WriteString(string(t.CreatedAt)); err != nil {
+
// t.Description (string) (string)
+
if t.Description != nil {
+
if len("description") > 1000000 {
+
return xerrors.Errorf("Value in field \"description\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("description"))); err != nil {
+
if _, err := cw.WriteString(string("description")); err != nil {
+
if t.Description == nil {
+
if _, err := cw.Write(cbg.CborNull); err != nil {
+
if len(*t.Description) > 1000000 {
+
return xerrors.Errorf("Value in field t.Description was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len(*t.Description))); err != nil {
+
if _, err := cw.WriteString(string(*t.Description)); err != nil {
+
func (t *Repo) UnmarshalCBOR(r io.Reader) (err error) {
+
cr := cbg.NewCborReader(r)
+
maj, extra, err := cr.ReadHeader()
+
err = io.ErrUnexpectedEOF
+
return fmt.Errorf("cbor input should be of type map")
+
if extra > cbg.MaxLength {
+
return fmt.Errorf("Repo: map struct too large (%d)", extra)
+
nameBuf := make([]byte, 11)
+
for i := uint64(0); i < n; i++ {
+
nameLen, ok, err := cbg.ReadFullStringIntoBuf(cr, nameBuf, 1000000)
+
// Field doesn't exist on this type, so ignore it
+
if err := cbg.ScanForLinks(cr, func(cid.Cid) {}); err != nil {
+
switch string(nameBuf[:nameLen]) {
+
// t.Knot (string) (string)
+
sval, err := cbg.ReadStringWithMax(cr, 1000000)
+
// t.Name (string) (string)
+
sval, err := cbg.ReadStringWithMax(cr, 1000000)
+
// t.LexiconTypeID (string) (string)
+
sval, err := cbg.ReadStringWithMax(cr, 1000000)
+
t.LexiconTypeID = string(sval)
+
// t.Owner (string) (string)
+
sval, err := cbg.ReadStringWithMax(cr, 1000000)
+
// t.Source (string) (string)
+
b, err := cr.ReadByte()
+
if b != cbg.CborNull[0] {
+
if err := cr.UnreadByte(); err != nil {
+
sval, err := cbg.ReadStringWithMax(cr, 1000000)
+
t.Source = (*string)(&sval)
+
// t.Spindle (string) (string)
+
b, err := cr.ReadByte()
+
if b != cbg.CborNull[0] {
+
if err := cr.UnreadByte(); err != nil {
+
sval, err := cbg.ReadStringWithMax(cr, 1000000)
+
t.Spindle = (*string)(&sval)
+
// t.CreatedAt (string) (string)
+
sval, err := cbg.ReadStringWithMax(cr, 1000000)
+
t.CreatedAt = string(sval)
+
// t.Description (string) (string)
+
b, err := cr.ReadByte()
+
if b != cbg.CborNull[0] {
+
if err := cr.UnreadByte(); err != nil {
+
sval, err := cbg.ReadStringWithMax(cr, 1000000)
+
t.Description = (*string)(&sval)
+
// Field doesn't exist on this type, so ignore it
+
if err := cbg.ScanForLinks(r, func(cid.Cid) {}); err != nil {
func (t *RepoArtifact) MarshalCBOR(w io.Writer) error {
_, err := w.Write(cbg.CborNull)
···
+
func (t *RepoIssue) MarshalCBOR(w io.Writer) error {
+
_, err := w.Write(cbg.CborNull)
+
cw := cbg.NewCborWriter(w)
+
if _, err := cw.Write(cbg.CborEncodeMajorType(cbg.MajMap, uint64(fieldCount))); err != nil {
+
// t.Body (string) (string)
+
if len("body") > 1000000 {
+
return xerrors.Errorf("Value in field \"body\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("body"))); err != nil {
+
if _, err := cw.WriteString(string("body")); err != nil {
+
if _, err := cw.Write(cbg.CborNull); err != nil {
+
if len(*t.Body) > 1000000 {
+
return xerrors.Errorf("Value in field t.Body was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len(*t.Body))); err != nil {
+
if _, err := cw.WriteString(string(*t.Body)); err != nil {
+
// t.Repo (string) (string)
+
if len("repo") > 1000000 {
+
return xerrors.Errorf("Value in field \"repo\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("repo"))); err != nil {
+
if _, err := cw.WriteString(string("repo")); err != nil {
+
if len(t.Repo) > 1000000 {
+
return xerrors.Errorf("Value in field t.Repo was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len(t.Repo))); err != nil {
+
if _, err := cw.WriteString(string(t.Repo)); err != nil {
+
// t.LexiconTypeID (string) (string)
+
if len("$type") > 1000000 {
+
return xerrors.Errorf("Value in field \"$type\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("$type"))); err != nil {
+
if _, err := cw.WriteString(string("$type")); err != nil {
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("sh.tangled.repo.issue"))); err != nil {
+
if _, err := cw.WriteString(string("sh.tangled.repo.issue")); err != nil {
+
// t.Owner (string) (string)
+
if len("owner") > 1000000 {
+
return xerrors.Errorf("Value in field \"owner\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("owner"))); err != nil {
+
if _, err := cw.WriteString(string("owner")); err != nil {
+
if len(t.Owner) > 1000000 {
+
return xerrors.Errorf("Value in field t.Owner was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len(t.Owner))); err != nil {
+
if _, err := cw.WriteString(string(t.Owner)); err != nil {
+
// t.Title (string) (string)
+
if len("title") > 1000000 {
+
return xerrors.Errorf("Value in field \"title\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("title"))); err != nil {
+
if _, err := cw.WriteString(string("title")); err != nil {
+
if len(t.Title) > 1000000 {
+
return xerrors.Errorf("Value in field t.Title was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len(t.Title))); err != nil {
+
if _, err := cw.WriteString(string(t.Title)); err != nil {
+
// t.IssueId (int64) (int64)
+
if len("issueId") > 1000000 {
+
return xerrors.Errorf("Value in field \"issueId\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("issueId"))); err != nil {
+
if _, err := cw.WriteString(string("issueId")); err != nil {
+
if err := cw.WriteMajorTypeHeader(cbg.MajUnsignedInt, uint64(t.IssueId)); err != nil {
+
if err := cw.WriteMajorTypeHeader(cbg.MajNegativeInt, uint64(-t.IssueId-1)); err != nil {
+
// t.CreatedAt (string) (string)
+
if len("createdAt") > 1000000 {
+
return xerrors.Errorf("Value in field \"createdAt\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("createdAt"))); err != nil {
+
if _, err := cw.WriteString(string("createdAt")); err != nil {
+
if len(t.CreatedAt) > 1000000 {
+
return xerrors.Errorf("Value in field t.CreatedAt was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len(t.CreatedAt))); err != nil {
+
if _, err := cw.WriteString(string(t.CreatedAt)); err != nil {
+
func (t *RepoIssue) UnmarshalCBOR(r io.Reader) (err error) {
+
cr := cbg.NewCborReader(r)
+
maj, extra, err := cr.ReadHeader()
+
err = io.ErrUnexpectedEOF
+
return fmt.Errorf("cbor input should be of type map")
+
if extra > cbg.MaxLength {
+
return fmt.Errorf("RepoIssue: map struct too large (%d)", extra)
+
nameBuf := make([]byte, 9)
+
for i := uint64(0); i < n; i++ {
+
nameLen, ok, err := cbg.ReadFullStringIntoBuf(cr, nameBuf, 1000000)
+
// Field doesn't exist on this type, so ignore it
+
if err := cbg.ScanForLinks(cr, func(cid.Cid) {}); err != nil {
+
switch string(nameBuf[:nameLen]) {
+
// t.Body (string) (string)
+
b, err := cr.ReadByte()
+
if b != cbg.CborNull[0] {
+
if err := cr.UnreadByte(); err != nil {
+
sval, err := cbg.ReadStringWithMax(cr, 1000000)
+
t.Body = (*string)(&sval)
+
// t.Repo (string) (string)
+
sval, err := cbg.ReadStringWithMax(cr, 1000000)
+
// t.LexiconTypeID (string) (string)
+
sval, err := cbg.ReadStringWithMax(cr, 1000000)
+
t.LexiconTypeID = string(sval)
+
// t.Owner (string) (string)
+
sval, err := cbg.ReadStringWithMax(cr, 1000000)
+
// t.Title (string) (string)
+
sval, err := cbg.ReadStringWithMax(cr, 1000000)
+
// t.IssueId (int64) (int64)
+
maj, extra, err := cr.ReadHeader()
+
case cbg.MajUnsignedInt:
+
return fmt.Errorf("int64 positive overflow")
+
case cbg.MajNegativeInt:
+
return fmt.Errorf("int64 negative overflow")
+
return fmt.Errorf("wrong type for int64 field: %d", maj)
+
t.IssueId = int64(extraI)
+
// t.CreatedAt (string) (string)
+
sval, err := cbg.ReadStringWithMax(cr, 1000000)
+
t.CreatedAt = string(sval)
+
// Field doesn't exist on this type, so ignore it
+
if err := cbg.ScanForLinks(r, func(cid.Cid) {}); err != nil {
func (t *RepoIssueComment) MarshalCBOR(w io.Writer) error {
_, err := w.Write(cbg.CborNull)
···
+
func (t *RepoPull) MarshalCBOR(w io.Writer) error {
_, err := w.Write(cbg.CborNull)
cw := cbg.NewCborWriter(w)
···
// t.LexiconTypeID (string) (string)
if len("$type") > 1000000 {
return xerrors.Errorf("Value in field \"$type\" was too long")
···
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("sh.tangled.repo.pull"))); err != nil {
+
if _, err := cw.WriteString(string("sh.tangled.repo.pull")); err != nil {
+
// t.Patch (string) (string)
+
if len("patch") > 1000000 {
+
return xerrors.Errorf("Value in field \"patch\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("patch"))); err != nil {
+
if _, err := cw.WriteString(string("patch")); err != nil {
+
if len(t.Patch) > 1000000 {
+
return xerrors.Errorf("Value in field t.Patch was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len(t.Patch))); err != nil {
+
if _, err := cw.WriteString(string(t.Patch)); err != nil {
···
+
// t.PullId (int64) (int64)
+
if len("pullId") > 1000000 {
+
return xerrors.Errorf("Value in field \"pullId\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("pullId"))); err != nil {
+
if _, err := cw.WriteString(string("pullId")); err != nil {
+
if err := cw.WriteMajorTypeHeader(cbg.MajUnsignedInt, uint64(t.PullId)); err != nil {
+
if err := cw.WriteMajorTypeHeader(cbg.MajNegativeInt, uint64(-t.PullId-1)); err != nil {
+
// t.Source (tangled.RepoPull_Source) (struct)
+
if len("source") > 1000000 {
+
return xerrors.Errorf("Value in field \"source\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("source"))); err != nil {
+
if _, err := cw.WriteString(string("source")); err != nil {
+
if err := t.Source.MarshalCBOR(cw); err != nil {
···
if _, err := cw.WriteString(string(t.CreatedAt)); err != nil {
+
// t.TargetRepo (string) (string)
+
if len("targetRepo") > 1000000 {
+
return xerrors.Errorf("Value in field \"targetRepo\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("targetRepo"))); err != nil {
+
if _, err := cw.WriteString(string("targetRepo")); err != nil {
+
if len(t.TargetRepo) > 1000000 {
+
return xerrors.Errorf("Value in field t.TargetRepo was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len(t.TargetRepo))); err != nil {
+
if _, err := cw.WriteString(string(t.TargetRepo)); err != nil {
+
// t.TargetBranch (string) (string)
+
if len("targetBranch") > 1000000 {
+
return xerrors.Errorf("Value in field \"targetBranch\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("targetBranch"))); err != nil {
+
if _, err := cw.WriteString(string("targetBranch")); err != nil {
+
if len(t.TargetBranch) > 1000000 {
+
return xerrors.Errorf("Value in field t.TargetBranch was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len(t.TargetBranch))); err != nil {
+
if _, err := cw.WriteString(string(t.TargetBranch)); err != nil {
+
func (t *RepoPull) UnmarshalCBOR(r io.Reader) (err error) {
cr := cbg.NewCborReader(r)
···
if extra > cbg.MaxLength {
+
return fmt.Errorf("RepoPull: map struct too large (%d)", extra)
+
nameBuf := make([]byte, 12)
for i := uint64(0); i < n; i++ {
nameLen, ok, err := cbg.ReadFullStringIntoBuf(cr, nameBuf, 1000000)
···
t.Body = (*string)(&sval)
// t.LexiconTypeID (string) (string)
···
t.LexiconTypeID = string(sval)
+
// t.Patch (string) (string)
sval, err := cbg.ReadStringWithMax(cr, 1000000)
···
// t.Title (string) (string)
···
+
// t.PullId (int64) (int64)
maj, extra, err := cr.ReadHeader()
···
return fmt.Errorf("wrong type for int64 field: %d", maj)
+
t.PullId = int64(extraI)
+
// t.Source (tangled.RepoPull_Source) (struct)
+
b, err := cr.ReadByte()
+
if b != cbg.CborNull[0] {
+
if err := cr.UnreadByte(); err != nil {
+
t.Source = new(RepoPull_Source)
+
if err := t.Source.UnmarshalCBOR(cr); err != nil {
+
return xerrors.Errorf("unmarshaling t.Source pointer: %w", err)
// t.CreatedAt (string) (string)
···
t.CreatedAt = string(sval)
+
// t.TargetRepo (string) (string)
+
sval, err := cbg.ReadStringWithMax(cr, 1000000)
+
t.TargetRepo = string(sval)
+
// t.TargetBranch (string) (string)
+
sval, err := cbg.ReadStringWithMax(cr, 1000000)
+
t.TargetBranch = string(sval)
···
func (t *RepoPull_Source) MarshalCBOR(w io.Writer) error {
_, err := w.Write(cbg.CborNull)
···
+
func (t *RepoPullStatus) MarshalCBOR(w io.Writer) error {
_, err := w.Write(cbg.CborNull)
cw := cbg.NewCborWriter(w)
+
if _, err := cw.Write([]byte{163}); err != nil {
+
// t.Pull (string) (string)
+
if len("pull") > 1000000 {
+
return xerrors.Errorf("Value in field \"pull\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("pull"))); err != nil {
+
if _, err := cw.WriteString(string("pull")); err != nil {
+
if len(t.Pull) > 1000000 {
+
return xerrors.Errorf("Value in field t.Pull was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len(t.Pull))); err != nil {
+
if _, err := cw.WriteString(string(t.Pull)); err != nil {
+
// t.LexiconTypeID (string) (string)
+
if len("$type") > 1000000 {
+
return xerrors.Errorf("Value in field \"$type\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("$type"))); err != nil {
+
if _, err := cw.WriteString(string("$type")); err != nil {
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("sh.tangled.repo.pull.status"))); err != nil {
+
if _, err := cw.WriteString(string("sh.tangled.repo.pull.status")); err != nil {
+
// t.Status (string) (string)
+
if len("status") > 1000000 {
+
return xerrors.Errorf("Value in field \"status\" was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("status"))); err != nil {
+
if _, err := cw.WriteString(string("status")); err != nil {
+
if len(t.Status) > 1000000 {
+
return xerrors.Errorf("Value in field t.Status was too long")
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len(t.Status))); err != nil {
+
if _, err := cw.WriteString(string(t.Status)); err != nil {
+
func (t *RepoPullStatus) UnmarshalCBOR(r io.Reader) (err error) {
cr := cbg.NewCborReader(r)
···
if extra > cbg.MaxLength {
+
return fmt.Errorf("RepoPullStatus: map struct too large (%d)", extra)
+
nameBuf := make([]byte, 6)
for i := uint64(0); i < n; i++ {
nameLen, ok, err := cbg.ReadFullStringIntoBuf(cr, nameBuf, 1000000)
···
switch string(nameBuf[:nameLen]) {
+
// t.Pull (string) (string)
+
sval, err := cbg.ReadStringWithMax(cr, 1000000)
// t.LexiconTypeID (string) (string)
···
t.LexiconTypeID = string(sval)
+
// t.Status (string) (string)
sval, err := cbg.ReadStringWithMax(cr, 1000000)
···
+
t.Status = string(sval)
···
+
func (t *Spindle) MarshalCBOR(w io.Writer) error {
_, err := w.Write(cbg.CborNull)
cw := cbg.NewCborWriter(w)
+
if _, err := cw.Write([]byte{162}); err != nil {
···
+
if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("sh.tangled.spindle"))); err != nil {
+
if _, err := cw.WriteString(string("sh.tangled.spindle")); err != nil {
// t.CreatedAt (string) (string)
if len("createdAt") > 1000000 {
return xerrors.Errorf("Value in field \"createdAt\" was too long")
···
if _, err := cw.WriteString(string(t.CreatedAt)); err != nil {
+
func (t *Spindle) UnmarshalCBOR(r io.Reader) (err error) {
cr := cbg.NewCborReader(r)
···
if extra > cbg.MaxLength {
+
return fmt.Errorf("Spindle: map struct too large (%d)", extra)
+
nameBuf := make([]byte, 9)
for i := uint64(0); i < n; i++ {
nameLen, ok, err := cbg.ReadFullStringIntoBuf(cr, nameBuf, 1000000)
···
switch string(nameBuf[:nameLen]) {
+
// t.LexiconTypeID (string) (string)
···
t.LexiconTypeID = string(sval)
// t.CreatedAt (string) (string)
···
t.CreatedAt = string(sval)