github.com/keybase/client/go@v0.0.0-20240309051027-028f7c731f8b/protocol/chat1/common.go (about)

     1  // Auto-generated to Go types and interfaces using avdl-compiler v1.4.10 (https://github.com/keybase/node-avdl-compiler)
     2  //   Input file: avdl/chat1/common.avdl
     3  
     4  package chat1
     5  
     6  import (
     7  	"errors"
     8  	"fmt"
     9  	gregor1 "github.com/keybase/client/go/protocol/gregor1"
    10  	keybase1 "github.com/keybase/client/go/protocol/keybase1"
    11  	stellar1 "github.com/keybase/client/go/protocol/stellar1"
    12  	"github.com/keybase/go-framed-msgpack-rpc/rpc"
    13  )
    14  
    15  type ThreadID []byte
    16  
    17  func (o ThreadID) DeepCopy() ThreadID {
    18  	return (func(x []byte) []byte {
    19  		if x == nil {
    20  			return nil
    21  		}
    22  		return append([]byte{}, x...)
    23  	})(o)
    24  }
    25  
    26  type MessageID uint
    27  
    28  func (o MessageID) DeepCopy() MessageID {
    29  	return o
    30  }
    31  
    32  type TLFConvOrdinal uint
    33  
    34  func (o TLFConvOrdinal) DeepCopy() TLFConvOrdinal {
    35  	return o
    36  }
    37  
    38  type TopicID []byte
    39  
    40  func (o TopicID) DeepCopy() TopicID {
    41  	return (func(x []byte) []byte {
    42  		if x == nil {
    43  			return nil
    44  		}
    45  		return append([]byte{}, x...)
    46  	})(o)
    47  }
    48  
    49  type ConversationID []byte
    50  
    51  func (o ConversationID) DeepCopy() ConversationID {
    52  	return (func(x []byte) []byte {
    53  		if x == nil {
    54  			return nil
    55  		}
    56  		return append([]byte{}, x...)
    57  	})(o)
    58  }
    59  
    60  type TLFID []byte
    61  
    62  func (o TLFID) DeepCopy() TLFID {
    63  	return (func(x []byte) []byte {
    64  		if x == nil {
    65  			return nil
    66  		}
    67  		return append([]byte{}, x...)
    68  	})(o)
    69  }
    70  
    71  type Hash []byte
    72  
    73  func (o Hash) DeepCopy() Hash {
    74  	return (func(x []byte) []byte {
    75  		if x == nil {
    76  			return nil
    77  		}
    78  		return append([]byte{}, x...)
    79  	})(o)
    80  }
    81  
    82  type InboxVers uint64
    83  
    84  func (o InboxVers) DeepCopy() InboxVers {
    85  	return o
    86  }
    87  
    88  type LocalConversationVers uint64
    89  
    90  func (o LocalConversationVers) DeepCopy() LocalConversationVers {
    91  	return o
    92  }
    93  
    94  type ConversationVers uint64
    95  
    96  func (o ConversationVers) DeepCopy() ConversationVers {
    97  	return o
    98  }
    99  
   100  type OutboxID []byte
   101  
   102  func (o OutboxID) DeepCopy() OutboxID {
   103  	return (func(x []byte) []byte {
   104  		if x == nil {
   105  			return nil
   106  		}
   107  		return append([]byte{}, x...)
   108  	})(o)
   109  }
   110  
   111  type TopicNameState []byte
   112  
   113  func (o TopicNameState) DeepCopy() TopicNameState {
   114  	return (func(x []byte) []byte {
   115  		if x == nil {
   116  			return nil
   117  		}
   118  		return append([]byte{}, x...)
   119  	})(o)
   120  }
   121  
   122  type FlipGameID []byte
   123  
   124  func (o FlipGameID) DeepCopy() FlipGameID {
   125  	return (func(x []byte) []byte {
   126  		if x == nil {
   127  			return nil
   128  		}
   129  		return append([]byte{}, x...)
   130  	})(o)
   131  }
   132  
   133  type ArchiveJobID string
   134  
   135  func (o ArchiveJobID) DeepCopy() ArchiveJobID {
   136  	return o
   137  }
   138  
   139  type InboxVersInfo struct {
   140  	Uid  gregor1.UID `codec:"uid" json:"uid"`
   141  	Vers InboxVers   `codec:"vers" json:"vers"`
   142  }
   143  
   144  func (o InboxVersInfo) DeepCopy() InboxVersInfo {
   145  	return InboxVersInfo{
   146  		Uid:  o.Uid.DeepCopy(),
   147  		Vers: o.Vers.DeepCopy(),
   148  	}
   149  }
   150  
   151  type ConversationExistence int
   152  
   153  const (
   154  	ConversationExistence_ACTIVE    ConversationExistence = 0
   155  	ConversationExistence_ARCHIVED  ConversationExistence = 1
   156  	ConversationExistence_DELETED   ConversationExistence = 2
   157  	ConversationExistence_ABANDONED ConversationExistence = 3
   158  )
   159  
   160  func (o ConversationExistence) DeepCopy() ConversationExistence { return o }
   161  
   162  var ConversationExistenceMap = map[string]ConversationExistence{
   163  	"ACTIVE":    0,
   164  	"ARCHIVED":  1,
   165  	"DELETED":   2,
   166  	"ABANDONED": 3,
   167  }
   168  
   169  var ConversationExistenceRevMap = map[ConversationExistence]string{
   170  	0: "ACTIVE",
   171  	1: "ARCHIVED",
   172  	2: "DELETED",
   173  	3: "ABANDONED",
   174  }
   175  
   176  func (e ConversationExistence) String() string {
   177  	if v, ok := ConversationExistenceRevMap[e]; ok {
   178  		return v
   179  	}
   180  	return fmt.Sprintf("%v", int(e))
   181  }
   182  
   183  type ConversationMembersType int
   184  
   185  const (
   186  	ConversationMembersType_KBFS           ConversationMembersType = 0
   187  	ConversationMembersType_TEAM           ConversationMembersType = 1
   188  	ConversationMembersType_IMPTEAMNATIVE  ConversationMembersType = 2
   189  	ConversationMembersType_IMPTEAMUPGRADE ConversationMembersType = 3
   190  )
   191  
   192  func (o ConversationMembersType) DeepCopy() ConversationMembersType { return o }
   193  
   194  var ConversationMembersTypeMap = map[string]ConversationMembersType{
   195  	"KBFS":           0,
   196  	"TEAM":           1,
   197  	"IMPTEAMNATIVE":  2,
   198  	"IMPTEAMUPGRADE": 3,
   199  }
   200  
   201  var ConversationMembersTypeRevMap = map[ConversationMembersType]string{
   202  	0: "KBFS",
   203  	1: "TEAM",
   204  	2: "IMPTEAMNATIVE",
   205  	3: "IMPTEAMUPGRADE",
   206  }
   207  
   208  func (e ConversationMembersType) String() string {
   209  	if v, ok := ConversationMembersTypeRevMap[e]; ok {
   210  		return v
   211  	}
   212  	return fmt.Sprintf("%v", int(e))
   213  }
   214  
   215  type SyncInboxResType int
   216  
   217  const (
   218  	SyncInboxResType_CURRENT     SyncInboxResType = 0
   219  	SyncInboxResType_INCREMENTAL SyncInboxResType = 1
   220  	SyncInboxResType_CLEAR       SyncInboxResType = 2
   221  )
   222  
   223  func (o SyncInboxResType) DeepCopy() SyncInboxResType { return o }
   224  
   225  var SyncInboxResTypeMap = map[string]SyncInboxResType{
   226  	"CURRENT":     0,
   227  	"INCREMENTAL": 1,
   228  	"CLEAR":       2,
   229  }
   230  
   231  var SyncInboxResTypeRevMap = map[SyncInboxResType]string{
   232  	0: "CURRENT",
   233  	1: "INCREMENTAL",
   234  	2: "CLEAR",
   235  }
   236  
   237  func (e SyncInboxResType) String() string {
   238  	if v, ok := SyncInboxResTypeRevMap[e]; ok {
   239  		return v
   240  	}
   241  	return fmt.Sprintf("%v", int(e))
   242  }
   243  
   244  type MessageType int
   245  
   246  const (
   247  	MessageType_NONE               MessageType = 0
   248  	MessageType_TEXT               MessageType = 1
   249  	MessageType_ATTACHMENT         MessageType = 2
   250  	MessageType_EDIT               MessageType = 3
   251  	MessageType_DELETE             MessageType = 4
   252  	MessageType_METADATA           MessageType = 5
   253  	MessageType_TLFNAME            MessageType = 6
   254  	MessageType_HEADLINE           MessageType = 7
   255  	MessageType_ATTACHMENTUPLOADED MessageType = 8
   256  	MessageType_JOIN               MessageType = 9
   257  	MessageType_LEAVE              MessageType = 10
   258  	MessageType_SYSTEM             MessageType = 11
   259  	MessageType_DELETEHISTORY      MessageType = 12
   260  	MessageType_REACTION           MessageType = 13
   261  	MessageType_SENDPAYMENT        MessageType = 14
   262  	MessageType_REQUESTPAYMENT     MessageType = 15
   263  	MessageType_UNFURL             MessageType = 16
   264  	MessageType_FLIP               MessageType = 17
   265  	MessageType_PIN                MessageType = 18
   266  )
   267  
   268  func (o MessageType) DeepCopy() MessageType { return o }
   269  
   270  var MessageTypeMap = map[string]MessageType{
   271  	"NONE":               0,
   272  	"TEXT":               1,
   273  	"ATTACHMENT":         2,
   274  	"EDIT":               3,
   275  	"DELETE":             4,
   276  	"METADATA":           5,
   277  	"TLFNAME":            6,
   278  	"HEADLINE":           7,
   279  	"ATTACHMENTUPLOADED": 8,
   280  	"JOIN":               9,
   281  	"LEAVE":              10,
   282  	"SYSTEM":             11,
   283  	"DELETEHISTORY":      12,
   284  	"REACTION":           13,
   285  	"SENDPAYMENT":        14,
   286  	"REQUESTPAYMENT":     15,
   287  	"UNFURL":             16,
   288  	"FLIP":               17,
   289  	"PIN":                18,
   290  }
   291  
   292  var MessageTypeRevMap = map[MessageType]string{
   293  	0:  "NONE",
   294  	1:  "TEXT",
   295  	2:  "ATTACHMENT",
   296  	3:  "EDIT",
   297  	4:  "DELETE",
   298  	5:  "METADATA",
   299  	6:  "TLFNAME",
   300  	7:  "HEADLINE",
   301  	8:  "ATTACHMENTUPLOADED",
   302  	9:  "JOIN",
   303  	10: "LEAVE",
   304  	11: "SYSTEM",
   305  	12: "DELETEHISTORY",
   306  	13: "REACTION",
   307  	14: "SENDPAYMENT",
   308  	15: "REQUESTPAYMENT",
   309  	16: "UNFURL",
   310  	17: "FLIP",
   311  	18: "PIN",
   312  }
   313  
   314  type TopicType int
   315  
   316  const (
   317  	TopicType_NONE         TopicType = 0
   318  	TopicType_CHAT         TopicType = 1
   319  	TopicType_DEV          TopicType = 2
   320  	TopicType_KBFSFILEEDIT TopicType = 3
   321  	TopicType_EMOJI        TopicType = 4
   322  	TopicType_EMOJICROSS   TopicType = 5
   323  )
   324  
   325  func (o TopicType) DeepCopy() TopicType { return o }
   326  
   327  var TopicTypeMap = map[string]TopicType{
   328  	"NONE":         0,
   329  	"CHAT":         1,
   330  	"DEV":          2,
   331  	"KBFSFILEEDIT": 3,
   332  	"EMOJI":        4,
   333  	"EMOJICROSS":   5,
   334  }
   335  
   336  var TopicTypeRevMap = map[TopicType]string{
   337  	0: "NONE",
   338  	1: "CHAT",
   339  	2: "DEV",
   340  	3: "KBFSFILEEDIT",
   341  	4: "EMOJI",
   342  	5: "EMOJICROSS",
   343  }
   344  
   345  type TeamType int
   346  
   347  const (
   348  	TeamType_NONE    TeamType = 0
   349  	TeamType_SIMPLE  TeamType = 1
   350  	TeamType_COMPLEX TeamType = 2
   351  )
   352  
   353  func (o TeamType) DeepCopy() TeamType { return o }
   354  
   355  var TeamTypeMap = map[string]TeamType{
   356  	"NONE":    0,
   357  	"SIMPLE":  1,
   358  	"COMPLEX": 2,
   359  }
   360  
   361  var TeamTypeRevMap = map[TeamType]string{
   362  	0: "NONE",
   363  	1: "SIMPLE",
   364  	2: "COMPLEX",
   365  }
   366  
   367  func (e TeamType) String() string {
   368  	if v, ok := TeamTypeRevMap[e]; ok {
   369  		return v
   370  	}
   371  	return fmt.Sprintf("%v", int(e))
   372  }
   373  
   374  type NotificationKind int
   375  
   376  const (
   377  	NotificationKind_GENERIC   NotificationKind = 0
   378  	NotificationKind_ATMENTION NotificationKind = 1
   379  )
   380  
   381  func (o NotificationKind) DeepCopy() NotificationKind { return o }
   382  
   383  var NotificationKindMap = map[string]NotificationKind{
   384  	"GENERIC":   0,
   385  	"ATMENTION": 1,
   386  }
   387  
   388  var NotificationKindRevMap = map[NotificationKind]string{
   389  	0: "GENERIC",
   390  	1: "ATMENTION",
   391  }
   392  
   393  type GlobalAppNotificationSetting int
   394  
   395  const (
   396  	GlobalAppNotificationSetting_NEWMESSAGES        GlobalAppNotificationSetting = 0
   397  	GlobalAppNotificationSetting_PLAINTEXTMOBILE    GlobalAppNotificationSetting = 1
   398  	GlobalAppNotificationSetting_PLAINTEXTDESKTOP   GlobalAppNotificationSetting = 2
   399  	GlobalAppNotificationSetting_DEFAULTSOUNDMOBILE GlobalAppNotificationSetting = 3
   400  	GlobalAppNotificationSetting_DISABLETYPING      GlobalAppNotificationSetting = 4
   401  )
   402  
   403  func (o GlobalAppNotificationSetting) DeepCopy() GlobalAppNotificationSetting { return o }
   404  
   405  var GlobalAppNotificationSettingMap = map[string]GlobalAppNotificationSetting{
   406  	"NEWMESSAGES":        0,
   407  	"PLAINTEXTMOBILE":    1,
   408  	"PLAINTEXTDESKTOP":   2,
   409  	"DEFAULTSOUNDMOBILE": 3,
   410  	"DISABLETYPING":      4,
   411  }
   412  
   413  var GlobalAppNotificationSettingRevMap = map[GlobalAppNotificationSetting]string{
   414  	0: "NEWMESSAGES",
   415  	1: "PLAINTEXTMOBILE",
   416  	2: "PLAINTEXTDESKTOP",
   417  	3: "DEFAULTSOUNDMOBILE",
   418  	4: "DISABLETYPING",
   419  }
   420  
   421  func (e GlobalAppNotificationSetting) String() string {
   422  	if v, ok := GlobalAppNotificationSettingRevMap[e]; ok {
   423  		return v
   424  	}
   425  	return fmt.Sprintf("%v", int(e))
   426  }
   427  
   428  type GlobalAppNotificationSettings struct {
   429  	Settings map[GlobalAppNotificationSetting]bool `codec:"settings" json:"settings"`
   430  }
   431  
   432  func (o GlobalAppNotificationSettings) DeepCopy() GlobalAppNotificationSettings {
   433  	return GlobalAppNotificationSettings{
   434  		Settings: (func(x map[GlobalAppNotificationSetting]bool) map[GlobalAppNotificationSetting]bool {
   435  			if x == nil {
   436  				return nil
   437  			}
   438  			ret := make(map[GlobalAppNotificationSetting]bool, len(x))
   439  			for k, v := range x {
   440  				kCopy := k.DeepCopy()
   441  				vCopy := v
   442  				ret[kCopy] = vCopy
   443  			}
   444  			return ret
   445  		})(o.Settings),
   446  	}
   447  }
   448  
   449  type ConversationStatus int
   450  
   451  const (
   452  	ConversationStatus_UNFILED  ConversationStatus = 0
   453  	ConversationStatus_FAVORITE ConversationStatus = 1
   454  	ConversationStatus_IGNORED  ConversationStatus = 2
   455  	ConversationStatus_BLOCKED  ConversationStatus = 3
   456  	ConversationStatus_MUTED    ConversationStatus = 4
   457  	ConversationStatus_REPORTED ConversationStatus = 5
   458  )
   459  
   460  func (o ConversationStatus) DeepCopy() ConversationStatus { return o }
   461  
   462  var ConversationStatusMap = map[string]ConversationStatus{
   463  	"UNFILED":  0,
   464  	"FAVORITE": 1,
   465  	"IGNORED":  2,
   466  	"BLOCKED":  3,
   467  	"MUTED":    4,
   468  	"REPORTED": 5,
   469  }
   470  
   471  var ConversationStatusRevMap = map[ConversationStatus]string{
   472  	0: "UNFILED",
   473  	1: "FAVORITE",
   474  	2: "IGNORED",
   475  	3: "BLOCKED",
   476  	4: "MUTED",
   477  	5: "REPORTED",
   478  }
   479  
   480  func (e ConversationStatus) String() string {
   481  	if v, ok := ConversationStatusRevMap[e]; ok {
   482  		return v
   483  	}
   484  	return fmt.Sprintf("%v", int(e))
   485  }
   486  
   487  type ConversationMember struct {
   488  	Uid       gregor1.UID    `codec:"uid" json:"uid"`
   489  	ConvID    ConversationID `codec:"convID" json:"convID"`
   490  	TopicType TopicType      `codec:"topicType" json:"topicType"`
   491  }
   492  
   493  func (o ConversationMember) DeepCopy() ConversationMember {
   494  	return ConversationMember{
   495  		Uid:       o.Uid.DeepCopy(),
   496  		ConvID:    o.ConvID.DeepCopy(),
   497  		TopicType: o.TopicType.DeepCopy(),
   498  	}
   499  }
   500  
   501  type ConversationIDMessageIDPair struct {
   502  	ConvID ConversationID `codec:"convID" json:"convID"`
   503  	MsgID  MessageID      `codec:"msgID" json:"msgID"`
   504  }
   505  
   506  func (o ConversationIDMessageIDPair) DeepCopy() ConversationIDMessageIDPair {
   507  	return ConversationIDMessageIDPair{
   508  		ConvID: o.ConvID.DeepCopy(),
   509  		MsgID:  o.MsgID.DeepCopy(),
   510  	}
   511  }
   512  
   513  type ConversationIDMessageIDPairs struct {
   514  	Pairs []ConversationIDMessageIDPair `codec:"pairs" json:"pairs"`
   515  }
   516  
   517  func (o ConversationIDMessageIDPairs) DeepCopy() ConversationIDMessageIDPairs {
   518  	return ConversationIDMessageIDPairs{
   519  		Pairs: (func(x []ConversationIDMessageIDPair) []ConversationIDMessageIDPair {
   520  			if x == nil {
   521  				return nil
   522  			}
   523  			ret := make([]ConversationIDMessageIDPair, len(x))
   524  			for i, v := range x {
   525  				vCopy := v.DeepCopy()
   526  				ret[i] = vCopy
   527  			}
   528  			return ret
   529  		})(o.Pairs),
   530  	}
   531  }
   532  
   533  type ChannelNameMention struct {
   534  	ConvID    ConversationID `codec:"convID" json:"convID"`
   535  	TopicName string         `codec:"topicName" json:"topicName"`
   536  }
   537  
   538  func (o ChannelNameMention) DeepCopy() ChannelNameMention {
   539  	return ChannelNameMention{
   540  		ConvID:    o.ConvID.DeepCopy(),
   541  		TopicName: o.TopicName,
   542  	}
   543  }
   544  
   545  type KBFSPath struct {
   546  	StartIndex   int                   `codec:"startIndex" json:"startIndex"`
   547  	RawPath      string                `codec:"rawPath" json:"rawPath"`
   548  	StandardPath string                `codec:"standardPath" json:"standardPath"`
   549  	PathInfo     keybase1.KBFSPathInfo `codec:"pathInfo" json:"pathInfo"`
   550  }
   551  
   552  func (o KBFSPath) DeepCopy() KBFSPath {
   553  	return KBFSPath{
   554  		StartIndex:   o.StartIndex,
   555  		RawPath:      o.RawPath,
   556  		StandardPath: o.StandardPath,
   557  		PathInfo:     o.PathInfo.DeepCopy(),
   558  	}
   559  }
   560  
   561  type ConversationMemberStatus int
   562  
   563  const (
   564  	ConversationMemberStatus_ACTIVE       ConversationMemberStatus = 0
   565  	ConversationMemberStatus_REMOVED      ConversationMemberStatus = 1
   566  	ConversationMemberStatus_LEFT         ConversationMemberStatus = 2
   567  	ConversationMemberStatus_PREVIEW      ConversationMemberStatus = 3
   568  	ConversationMemberStatus_RESET        ConversationMemberStatus = 4
   569  	ConversationMemberStatus_NEVER_JOINED ConversationMemberStatus = 5
   570  )
   571  
   572  func (o ConversationMemberStatus) DeepCopy() ConversationMemberStatus { return o }
   573  
   574  var ConversationMemberStatusMap = map[string]ConversationMemberStatus{
   575  	"ACTIVE":       0,
   576  	"REMOVED":      1,
   577  	"LEFT":         2,
   578  	"PREVIEW":      3,
   579  	"RESET":        4,
   580  	"NEVER_JOINED": 5,
   581  }
   582  
   583  var ConversationMemberStatusRevMap = map[ConversationMemberStatus]string{
   584  	0: "ACTIVE",
   585  	1: "REMOVED",
   586  	2: "LEFT",
   587  	3: "PREVIEW",
   588  	4: "RESET",
   589  	5: "NEVER_JOINED",
   590  }
   591  
   592  func (e ConversationMemberStatus) String() string {
   593  	if v, ok := ConversationMemberStatusRevMap[e]; ok {
   594  		return v
   595  	}
   596  	return fmt.Sprintf("%v", int(e))
   597  }
   598  
   599  type Pagination struct {
   600  	Next           []byte `codec:"next,omitempty" json:"next,omitempty"`
   601  	Previous       []byte `codec:"previous,omitempty" json:"previous,omitempty"`
   602  	Num            int    `codec:"num" json:"num"`
   603  	Last           bool   `codec:"last,omitempty" json:"last,omitempty"`
   604  	ForceFirstPage bool   `codec:"forceFirstPage,omitempty" json:"forceFirstPage,omitempty"`
   605  }
   606  
   607  func (o Pagination) DeepCopy() Pagination {
   608  	return Pagination{
   609  		Next: (func(x []byte) []byte {
   610  			if x == nil {
   611  				return nil
   612  			}
   613  			return append([]byte{}, x...)
   614  		})(o.Next),
   615  		Previous: (func(x []byte) []byte {
   616  			if x == nil {
   617  				return nil
   618  			}
   619  			return append([]byte{}, x...)
   620  		})(o.Previous),
   621  		Num:            o.Num,
   622  		Last:           o.Last,
   623  		ForceFirstPage: o.ForceFirstPage,
   624  	}
   625  }
   626  
   627  type RateLimit struct {
   628  	Name           string `codec:"name" json:"name"`
   629  	CallsRemaining int    `codec:"callsRemaining" json:"callsRemaining"`
   630  	WindowReset    int    `codec:"windowReset" json:"windowReset"`
   631  	MaxCalls       int    `codec:"maxCalls" json:"maxCalls"`
   632  }
   633  
   634  func (o RateLimit) DeepCopy() RateLimit {
   635  	return RateLimit{
   636  		Name:           o.Name,
   637  		CallsRemaining: o.CallsRemaining,
   638  		WindowReset:    o.WindowReset,
   639  		MaxCalls:       o.MaxCalls,
   640  	}
   641  }
   642  
   643  type InboxParticipantsMode int
   644  
   645  const (
   646  	InboxParticipantsMode_ALL        InboxParticipantsMode = 0
   647  	InboxParticipantsMode_SKIP_TEAMS InboxParticipantsMode = 1
   648  )
   649  
   650  func (o InboxParticipantsMode) DeepCopy() InboxParticipantsMode { return o }
   651  
   652  var InboxParticipantsModeMap = map[string]InboxParticipantsMode{
   653  	"ALL":        0,
   654  	"SKIP_TEAMS": 1,
   655  }
   656  
   657  var InboxParticipantsModeRevMap = map[InboxParticipantsMode]string{
   658  	0: "ALL",
   659  	1: "SKIP_TEAMS",
   660  }
   661  
   662  func (e InboxParticipantsMode) String() string {
   663  	if v, ok := InboxParticipantsModeRevMap[e]; ok {
   664  		return v
   665  	}
   666  	return fmt.Sprintf("%v", int(e))
   667  }
   668  
   669  type GetInboxQuery struct {
   670  	ConvID            *ConversationID            `codec:"convID,omitempty" json:"convID,omitempty"`
   671  	TopicType         *TopicType                 `codec:"topicType,omitempty" json:"topicType,omitempty"`
   672  	TlfID             *TLFID                     `codec:"tlfID,omitempty" json:"tlfID,omitempty"`
   673  	TlfVisibility     *keybase1.TLFVisibility    `codec:"tlfVisibility,omitempty" json:"tlfVisibility,omitempty"`
   674  	Before            *gregor1.Time              `codec:"before,omitempty" json:"before,omitempty"`
   675  	After             *gregor1.Time              `codec:"after,omitempty" json:"after,omitempty"`
   676  	OneChatTypePerTLF *bool                      `codec:"oneChatTypePerTLF,omitempty" json:"oneChatTypePerTLF,omitempty"`
   677  	TopicName         *string                    `codec:"topicName,omitempty" json:"topicName,omitempty"`
   678  	Status            []ConversationStatus       `codec:"status" json:"status"`
   679  	MemberStatus      []ConversationMemberStatus `codec:"memberStatus" json:"memberStatus"`
   680  	Existences        []ConversationExistence    `codec:"existences" json:"existences"`
   681  	MembersTypes      []ConversationMembersType  `codec:"membersTypes" json:"membersTypes"`
   682  	ConvIDs           []ConversationID           `codec:"convIDs" json:"convIDs"`
   683  	UnreadOnly        bool                       `codec:"unreadOnly" json:"unreadOnly"`
   684  	ReadOnly          bool                       `codec:"readOnly" json:"readOnly"`
   685  	ComputeActiveList bool                       `codec:"computeActiveList" json:"computeActiveList"`
   686  	SummarizeMaxMsgs  bool                       `codec:"summarizeMaxMsgs" json:"summarizeMaxMsgs"`
   687  	ParticipantsMode  InboxParticipantsMode      `codec:"participantsMode" json:"participantsMode"`
   688  	SkipBgLoads       bool                       `codec:"skipBgLoads" json:"skipBgLoads"`
   689  	AllowUnseenQuery  bool                       `codec:"allowUnseenQuery" json:"allowUnseenQuery"`
   690  }
   691  
   692  func (o GetInboxQuery) DeepCopy() GetInboxQuery {
   693  	return GetInboxQuery{
   694  		ConvID: (func(x *ConversationID) *ConversationID {
   695  			if x == nil {
   696  				return nil
   697  			}
   698  			tmp := (*x).DeepCopy()
   699  			return &tmp
   700  		})(o.ConvID),
   701  		TopicType: (func(x *TopicType) *TopicType {
   702  			if x == nil {
   703  				return nil
   704  			}
   705  			tmp := (*x).DeepCopy()
   706  			return &tmp
   707  		})(o.TopicType),
   708  		TlfID: (func(x *TLFID) *TLFID {
   709  			if x == nil {
   710  				return nil
   711  			}
   712  			tmp := (*x).DeepCopy()
   713  			return &tmp
   714  		})(o.TlfID),
   715  		TlfVisibility: (func(x *keybase1.TLFVisibility) *keybase1.TLFVisibility {
   716  			if x == nil {
   717  				return nil
   718  			}
   719  			tmp := (*x).DeepCopy()
   720  			return &tmp
   721  		})(o.TlfVisibility),
   722  		Before: (func(x *gregor1.Time) *gregor1.Time {
   723  			if x == nil {
   724  				return nil
   725  			}
   726  			tmp := (*x).DeepCopy()
   727  			return &tmp
   728  		})(o.Before),
   729  		After: (func(x *gregor1.Time) *gregor1.Time {
   730  			if x == nil {
   731  				return nil
   732  			}
   733  			tmp := (*x).DeepCopy()
   734  			return &tmp
   735  		})(o.After),
   736  		OneChatTypePerTLF: (func(x *bool) *bool {
   737  			if x == nil {
   738  				return nil
   739  			}
   740  			tmp := (*x)
   741  			return &tmp
   742  		})(o.OneChatTypePerTLF),
   743  		TopicName: (func(x *string) *string {
   744  			if x == nil {
   745  				return nil
   746  			}
   747  			tmp := (*x)
   748  			return &tmp
   749  		})(o.TopicName),
   750  		Status: (func(x []ConversationStatus) []ConversationStatus {
   751  			if x == nil {
   752  				return nil
   753  			}
   754  			ret := make([]ConversationStatus, len(x))
   755  			for i, v := range x {
   756  				vCopy := v.DeepCopy()
   757  				ret[i] = vCopy
   758  			}
   759  			return ret
   760  		})(o.Status),
   761  		MemberStatus: (func(x []ConversationMemberStatus) []ConversationMemberStatus {
   762  			if x == nil {
   763  				return nil
   764  			}
   765  			ret := make([]ConversationMemberStatus, len(x))
   766  			for i, v := range x {
   767  				vCopy := v.DeepCopy()
   768  				ret[i] = vCopy
   769  			}
   770  			return ret
   771  		})(o.MemberStatus),
   772  		Existences: (func(x []ConversationExistence) []ConversationExistence {
   773  			if x == nil {
   774  				return nil
   775  			}
   776  			ret := make([]ConversationExistence, len(x))
   777  			for i, v := range x {
   778  				vCopy := v.DeepCopy()
   779  				ret[i] = vCopy
   780  			}
   781  			return ret
   782  		})(o.Existences),
   783  		MembersTypes: (func(x []ConversationMembersType) []ConversationMembersType {
   784  			if x == nil {
   785  				return nil
   786  			}
   787  			ret := make([]ConversationMembersType, len(x))
   788  			for i, v := range x {
   789  				vCopy := v.DeepCopy()
   790  				ret[i] = vCopy
   791  			}
   792  			return ret
   793  		})(o.MembersTypes),
   794  		ConvIDs: (func(x []ConversationID) []ConversationID {
   795  			if x == nil {
   796  				return nil
   797  			}
   798  			ret := make([]ConversationID, len(x))
   799  			for i, v := range x {
   800  				vCopy := v.DeepCopy()
   801  				ret[i] = vCopy
   802  			}
   803  			return ret
   804  		})(o.ConvIDs),
   805  		UnreadOnly:        o.UnreadOnly,
   806  		ReadOnly:          o.ReadOnly,
   807  		ComputeActiveList: o.ComputeActiveList,
   808  		SummarizeMaxMsgs:  o.SummarizeMaxMsgs,
   809  		ParticipantsMode:  o.ParticipantsMode.DeepCopy(),
   810  		SkipBgLoads:       o.SkipBgLoads,
   811  		AllowUnseenQuery:  o.AllowUnseenQuery,
   812  	}
   813  }
   814  
   815  type ConversationIDTriple struct {
   816  	Tlfid     TLFID     `codec:"tlfid" json:"tlfid"`
   817  	TopicType TopicType `codec:"topicType" json:"topicType"`
   818  	TopicID   TopicID   `codec:"topicID" json:"topicID"`
   819  }
   820  
   821  func (o ConversationIDTriple) DeepCopy() ConversationIDTriple {
   822  	return ConversationIDTriple{
   823  		Tlfid:     o.Tlfid.DeepCopy(),
   824  		TopicType: o.TopicType.DeepCopy(),
   825  		TopicID:   o.TopicID.DeepCopy(),
   826  	}
   827  }
   828  
   829  type ConversationFinalizeInfo struct {
   830  	ResetUser      string       `codec:"resetUser" json:"resetUser"`
   831  	ResetDate      string       `codec:"resetDate" json:"resetDate"`
   832  	ResetFull      string       `codec:"resetFull" json:"resetFull"`
   833  	ResetTimestamp gregor1.Time `codec:"resetTimestamp" json:"resetTimestamp"`
   834  }
   835  
   836  func (o ConversationFinalizeInfo) DeepCopy() ConversationFinalizeInfo {
   837  	return ConversationFinalizeInfo{
   838  		ResetUser:      o.ResetUser,
   839  		ResetDate:      o.ResetDate,
   840  		ResetFull:      o.ResetFull,
   841  		ResetTimestamp: o.ResetTimestamp.DeepCopy(),
   842  	}
   843  }
   844  
   845  type ConversationResolveInfo struct {
   846  	NewTLFName string `codec:"newTLFName" json:"newTLFName"`
   847  }
   848  
   849  func (o ConversationResolveInfo) DeepCopy() ConversationResolveInfo {
   850  	return ConversationResolveInfo{
   851  		NewTLFName: o.NewTLFName,
   852  	}
   853  }
   854  
   855  type Expunge struct {
   856  	Upto  MessageID `codec:"upto" json:"upto"`
   857  	Basis MessageID `codec:"basis" json:"basis"`
   858  }
   859  
   860  func (o Expunge) DeepCopy() Expunge {
   861  	return Expunge{
   862  		Upto:  o.Upto.DeepCopy(),
   863  		Basis: o.Basis.DeepCopy(),
   864  	}
   865  }
   866  
   867  type ConversationMetadata struct {
   868  	IdTriple       ConversationIDTriple      `codec:"idTriple" json:"idTriple"`
   869  	ConversationID ConversationID            `codec:"conversationID" json:"conversationID"`
   870  	Visibility     keybase1.TLFVisibility    `codec:"visibility" json:"visibility"`
   871  	Status         ConversationStatus        `codec:"status" json:"status"`
   872  	MembersType    ConversationMembersType   `codec:"membersType" json:"membersType"`
   873  	TeamType       TeamType                  `codec:"teamType" json:"teamType"`
   874  	Existence      ConversationExistence     `codec:"existence" json:"existence"`
   875  	Version        ConversationVers          `codec:"version" json:"version"`
   876  	LocalVersion   LocalConversationVers     `codec:"localVersion" json:"localVersion"`
   877  	FinalizeInfo   *ConversationFinalizeInfo `codec:"finalizeInfo,omitempty" json:"finalizeInfo,omitempty"`
   878  	Supersedes     []ConversationMetadata    `codec:"supersedes" json:"supersedes"`
   879  	SupersededBy   []ConversationMetadata    `codec:"supersededBy" json:"supersededBy"`
   880  	ActiveList     []gregor1.UID             `codec:"activeList" json:"activeList"`
   881  	AllList        []gregor1.UID             `codec:"allList" json:"allList"`
   882  	ResetList      []gregor1.UID             `codec:"resetList" json:"resetList"`
   883  	IsDefaultConv  bool                      `codec:"d" json:"isDefaultConv"`
   884  }
   885  
   886  func (o ConversationMetadata) DeepCopy() ConversationMetadata {
   887  	return ConversationMetadata{
   888  		IdTriple:       o.IdTriple.DeepCopy(),
   889  		ConversationID: o.ConversationID.DeepCopy(),
   890  		Visibility:     o.Visibility.DeepCopy(),
   891  		Status:         o.Status.DeepCopy(),
   892  		MembersType:    o.MembersType.DeepCopy(),
   893  		TeamType:       o.TeamType.DeepCopy(),
   894  		Existence:      o.Existence.DeepCopy(),
   895  		Version:        o.Version.DeepCopy(),
   896  		LocalVersion:   o.LocalVersion.DeepCopy(),
   897  		FinalizeInfo: (func(x *ConversationFinalizeInfo) *ConversationFinalizeInfo {
   898  			if x == nil {
   899  				return nil
   900  			}
   901  			tmp := (*x).DeepCopy()
   902  			return &tmp
   903  		})(o.FinalizeInfo),
   904  		Supersedes: (func(x []ConversationMetadata) []ConversationMetadata {
   905  			if x == nil {
   906  				return nil
   907  			}
   908  			ret := make([]ConversationMetadata, len(x))
   909  			for i, v := range x {
   910  				vCopy := v.DeepCopy()
   911  				ret[i] = vCopy
   912  			}
   913  			return ret
   914  		})(o.Supersedes),
   915  		SupersededBy: (func(x []ConversationMetadata) []ConversationMetadata {
   916  			if x == nil {
   917  				return nil
   918  			}
   919  			ret := make([]ConversationMetadata, len(x))
   920  			for i, v := range x {
   921  				vCopy := v.DeepCopy()
   922  				ret[i] = vCopy
   923  			}
   924  			return ret
   925  		})(o.SupersededBy),
   926  		ActiveList: (func(x []gregor1.UID) []gregor1.UID {
   927  			if x == nil {
   928  				return nil
   929  			}
   930  			ret := make([]gregor1.UID, len(x))
   931  			for i, v := range x {
   932  				vCopy := v.DeepCopy()
   933  				ret[i] = vCopy
   934  			}
   935  			return ret
   936  		})(o.ActiveList),
   937  		AllList: (func(x []gregor1.UID) []gregor1.UID {
   938  			if x == nil {
   939  				return nil
   940  			}
   941  			ret := make([]gregor1.UID, len(x))
   942  			for i, v := range x {
   943  				vCopy := v.DeepCopy()
   944  				ret[i] = vCopy
   945  			}
   946  			return ret
   947  		})(o.AllList),
   948  		ResetList: (func(x []gregor1.UID) []gregor1.UID {
   949  			if x == nil {
   950  				return nil
   951  			}
   952  			ret := make([]gregor1.UID, len(x))
   953  			for i, v := range x {
   954  				vCopy := v.DeepCopy()
   955  				ret[i] = vCopy
   956  			}
   957  			return ret
   958  		})(o.ResetList),
   959  		IsDefaultConv: o.IsDefaultConv,
   960  	}
   961  }
   962  
   963  type ConversationNotificationInfo struct {
   964  	ChannelWide bool                                              `codec:"channelWide" json:"channelWide"`
   965  	Settings    map[keybase1.DeviceType]map[NotificationKind]bool `codec:"settings" json:"settings"`
   966  }
   967  
   968  func (o ConversationNotificationInfo) DeepCopy() ConversationNotificationInfo {
   969  	return ConversationNotificationInfo{
   970  		ChannelWide: o.ChannelWide,
   971  		Settings: (func(x map[keybase1.DeviceType]map[NotificationKind]bool) map[keybase1.DeviceType]map[NotificationKind]bool {
   972  			if x == nil {
   973  				return nil
   974  			}
   975  			ret := make(map[keybase1.DeviceType]map[NotificationKind]bool, len(x))
   976  			for k, v := range x {
   977  				kCopy := k.DeepCopy()
   978  				vCopy := (func(x map[NotificationKind]bool) map[NotificationKind]bool {
   979  					if x == nil {
   980  						return nil
   981  					}
   982  					ret := make(map[NotificationKind]bool, len(x))
   983  					for k, v := range x {
   984  						kCopy := k.DeepCopy()
   985  						vCopy := v
   986  						ret[kCopy] = vCopy
   987  					}
   988  					return ret
   989  				})(v)
   990  				ret[kCopy] = vCopy
   991  			}
   992  			return ret
   993  		})(o.Settings),
   994  	}
   995  }
   996  
   997  type ConversationReaderInfo struct {
   998  	Mtime             gregor1.Time                 `codec:"mtime" json:"mtime"`
   999  	ReadMsgid         MessageID                    `codec:"readMsgid" json:"readMsgid"`
  1000  	MaxMsgid          MessageID                    `codec:"maxMsgid" json:"maxMsgid"`
  1001  	Status            ConversationMemberStatus     `codec:"status" json:"status"`
  1002  	UntrustedTeamRole keybase1.TeamRole            `codec:"untrustedTeamRole" json:"untrustedTeamRole"`
  1003  	LastSendTime      gregor1.Time                 `codec:"l" json:"l"`
  1004  	Journeycard       *ConversationJourneycardInfo `codec:"jc,omitempty" json:"jc,omitempty"`
  1005  }
  1006  
  1007  func (o ConversationReaderInfo) DeepCopy() ConversationReaderInfo {
  1008  	return ConversationReaderInfo{
  1009  		Mtime:             o.Mtime.DeepCopy(),
  1010  		ReadMsgid:         o.ReadMsgid.DeepCopy(),
  1011  		MaxMsgid:          o.MaxMsgid.DeepCopy(),
  1012  		Status:            o.Status.DeepCopy(),
  1013  		UntrustedTeamRole: o.UntrustedTeamRole.DeepCopy(),
  1014  		LastSendTime:      o.LastSendTime.DeepCopy(),
  1015  		Journeycard: (func(x *ConversationJourneycardInfo) *ConversationJourneycardInfo {
  1016  			if x == nil {
  1017  				return nil
  1018  			}
  1019  			tmp := (*x).DeepCopy()
  1020  			return &tmp
  1021  		})(o.Journeycard),
  1022  	}
  1023  }
  1024  
  1025  type ConversationJourneycardInfo struct {
  1026  	WelcomeEligible bool `codec:"w" json:"w"`
  1027  }
  1028  
  1029  func (o ConversationJourneycardInfo) DeepCopy() ConversationJourneycardInfo {
  1030  	return ConversationJourneycardInfo{
  1031  		WelcomeEligible: o.WelcomeEligible,
  1032  	}
  1033  }
  1034  
  1035  type ConversationCreatorInfo struct {
  1036  	Ctime gregor1.Time `codec:"ctime" json:"ctime"`
  1037  	Uid   gregor1.UID  `codec:"uid" json:"uid"`
  1038  }
  1039  
  1040  func (o ConversationCreatorInfo) DeepCopy() ConversationCreatorInfo {
  1041  	return ConversationCreatorInfo{
  1042  		Ctime: o.Ctime.DeepCopy(),
  1043  		Uid:   o.Uid.DeepCopy(),
  1044  	}
  1045  }
  1046  
  1047  type ConversationCreatorInfoLocal struct {
  1048  	Ctime    gregor1.Time `codec:"ctime" json:"ctime"`
  1049  	Username string       `codec:"username" json:"username"`
  1050  }
  1051  
  1052  func (o ConversationCreatorInfoLocal) DeepCopy() ConversationCreatorInfoLocal {
  1053  	return ConversationCreatorInfoLocal{
  1054  		Ctime:    o.Ctime.DeepCopy(),
  1055  		Username: o.Username,
  1056  	}
  1057  }
  1058  
  1059  type ConversationMinWriterRoleInfo struct {
  1060  	Uid  gregor1.UID       `codec:"uid" json:"uid"`
  1061  	Role keybase1.TeamRole `codec:"role" json:"role"`
  1062  }
  1063  
  1064  func (o ConversationMinWriterRoleInfo) DeepCopy() ConversationMinWriterRoleInfo {
  1065  	return ConversationMinWriterRoleInfo{
  1066  		Uid:  o.Uid.DeepCopy(),
  1067  		Role: o.Role.DeepCopy(),
  1068  	}
  1069  }
  1070  
  1071  type ConversationSettings struct {
  1072  	MinWriterRoleInfo *ConversationMinWriterRoleInfo `codec:"mwr,omitempty" json:"mwr,omitempty"`
  1073  }
  1074  
  1075  func (o ConversationSettings) DeepCopy() ConversationSettings {
  1076  	return ConversationSettings{
  1077  		MinWriterRoleInfo: (func(x *ConversationMinWriterRoleInfo) *ConversationMinWriterRoleInfo {
  1078  			if x == nil {
  1079  				return nil
  1080  			}
  1081  			tmp := (*x).DeepCopy()
  1082  			return &tmp
  1083  		})(o.MinWriterRoleInfo),
  1084  	}
  1085  }
  1086  
  1087  type Conversation struct {
  1088  	Metadata        ConversationMetadata          `codec:"metadata" json:"metadata"`
  1089  	ReaderInfo      *ConversationReaderInfo       `codec:"readerInfo,omitempty" json:"readerInfo,omitempty"`
  1090  	Notifications   *ConversationNotificationInfo `codec:"notifications,omitempty" json:"notifications,omitempty"`
  1091  	MaxMsgs         []MessageBoxed                `codec:"maxMsgs" json:"maxMsgs"`
  1092  	MaxMsgSummaries []MessageSummary              `codec:"maxMsgSummaries" json:"maxMsgSummaries"`
  1093  	CreatorInfo     *ConversationCreatorInfo      `codec:"creatorInfo,omitempty" json:"creatorInfo,omitempty"`
  1094  	PinnedMsg       *MessageID                    `codec:"pinnedMsg,omitempty" json:"pinnedMsg,omitempty"`
  1095  	Expunge         Expunge                       `codec:"expunge" json:"expunge"`
  1096  	ConvRetention   *RetentionPolicy              `codec:"convRetention,omitempty" json:"convRetention,omitempty"`
  1097  	TeamRetention   *RetentionPolicy              `codec:"teamRetention,omitempty" json:"teamRetention,omitempty"`
  1098  	ConvSettings    *ConversationSettings         `codec:"cs,omitempty" json:"cs,omitempty"`
  1099  }
  1100  
  1101  func (o Conversation) DeepCopy() Conversation {
  1102  	return Conversation{
  1103  		Metadata: o.Metadata.DeepCopy(),
  1104  		ReaderInfo: (func(x *ConversationReaderInfo) *ConversationReaderInfo {
  1105  			if x == nil {
  1106  				return nil
  1107  			}
  1108  			tmp := (*x).DeepCopy()
  1109  			return &tmp
  1110  		})(o.ReaderInfo),
  1111  		Notifications: (func(x *ConversationNotificationInfo) *ConversationNotificationInfo {
  1112  			if x == nil {
  1113  				return nil
  1114  			}
  1115  			tmp := (*x).DeepCopy()
  1116  			return &tmp
  1117  		})(o.Notifications),
  1118  		MaxMsgs: (func(x []MessageBoxed) []MessageBoxed {
  1119  			if x == nil {
  1120  				return nil
  1121  			}
  1122  			ret := make([]MessageBoxed, len(x))
  1123  			for i, v := range x {
  1124  				vCopy := v.DeepCopy()
  1125  				ret[i] = vCopy
  1126  			}
  1127  			return ret
  1128  		})(o.MaxMsgs),
  1129  		MaxMsgSummaries: (func(x []MessageSummary) []MessageSummary {
  1130  			if x == nil {
  1131  				return nil
  1132  			}
  1133  			ret := make([]MessageSummary, len(x))
  1134  			for i, v := range x {
  1135  				vCopy := v.DeepCopy()
  1136  				ret[i] = vCopy
  1137  			}
  1138  			return ret
  1139  		})(o.MaxMsgSummaries),
  1140  		CreatorInfo: (func(x *ConversationCreatorInfo) *ConversationCreatorInfo {
  1141  			if x == nil {
  1142  				return nil
  1143  			}
  1144  			tmp := (*x).DeepCopy()
  1145  			return &tmp
  1146  		})(o.CreatorInfo),
  1147  		PinnedMsg: (func(x *MessageID) *MessageID {
  1148  			if x == nil {
  1149  				return nil
  1150  			}
  1151  			tmp := (*x).DeepCopy()
  1152  			return &tmp
  1153  		})(o.PinnedMsg),
  1154  		Expunge: o.Expunge.DeepCopy(),
  1155  		ConvRetention: (func(x *RetentionPolicy) *RetentionPolicy {
  1156  			if x == nil {
  1157  				return nil
  1158  			}
  1159  			tmp := (*x).DeepCopy()
  1160  			return &tmp
  1161  		})(o.ConvRetention),
  1162  		TeamRetention: (func(x *RetentionPolicy) *RetentionPolicy {
  1163  			if x == nil {
  1164  				return nil
  1165  			}
  1166  			tmp := (*x).DeepCopy()
  1167  			return &tmp
  1168  		})(o.TeamRetention),
  1169  		ConvSettings: (func(x *ConversationSettings) *ConversationSettings {
  1170  			if x == nil {
  1171  				return nil
  1172  			}
  1173  			tmp := (*x).DeepCopy()
  1174  			return &tmp
  1175  		})(o.ConvSettings),
  1176  	}
  1177  }
  1178  
  1179  type MessageSummary struct {
  1180  	MsgID       MessageID    `codec:"msgID" json:"msgID"`
  1181  	MessageType MessageType  `codec:"messageType" json:"messageType"`
  1182  	TlfName     string       `codec:"tlfName" json:"tlfName"`
  1183  	TlfPublic   bool         `codec:"tlfPublic" json:"tlfPublic"`
  1184  	Ctime       gregor1.Time `codec:"ctime" json:"ctime"`
  1185  }
  1186  
  1187  func (o MessageSummary) DeepCopy() MessageSummary {
  1188  	return MessageSummary{
  1189  		MsgID:       o.MsgID.DeepCopy(),
  1190  		MessageType: o.MessageType.DeepCopy(),
  1191  		TlfName:     o.TlfName,
  1192  		TlfPublic:   o.TlfPublic,
  1193  		Ctime:       o.Ctime.DeepCopy(),
  1194  	}
  1195  }
  1196  
  1197  type Reaction struct {
  1198  	Ctime         gregor1.Time `codec:"ctime" json:"ctime"`
  1199  	ReactionMsgID MessageID    `codec:"reactionMsgID" json:"reactionMsgID"`
  1200  }
  1201  
  1202  func (o Reaction) DeepCopy() Reaction {
  1203  	return Reaction{
  1204  		Ctime:         o.Ctime.DeepCopy(),
  1205  		ReactionMsgID: o.ReactionMsgID.DeepCopy(),
  1206  	}
  1207  }
  1208  
  1209  type ReactionMap struct {
  1210  	Reactions map[string]map[string]Reaction `codec:"reactions" json:"reactions"`
  1211  }
  1212  
  1213  func (o ReactionMap) DeepCopy() ReactionMap {
  1214  	return ReactionMap{
  1215  		Reactions: (func(x map[string]map[string]Reaction) map[string]map[string]Reaction {
  1216  			if x == nil {
  1217  				return nil
  1218  			}
  1219  			ret := make(map[string]map[string]Reaction, len(x))
  1220  			for k, v := range x {
  1221  				kCopy := k
  1222  				vCopy := (func(x map[string]Reaction) map[string]Reaction {
  1223  					if x == nil {
  1224  						return nil
  1225  					}
  1226  					ret := make(map[string]Reaction, len(x))
  1227  					for k, v := range x {
  1228  						kCopy := k
  1229  						vCopy := v.DeepCopy()
  1230  						ret[kCopy] = vCopy
  1231  					}
  1232  					return ret
  1233  				})(v)
  1234  				ret[kCopy] = vCopy
  1235  			}
  1236  			return ret
  1237  		})(o.Reactions),
  1238  	}
  1239  }
  1240  
  1241  type MessageServerHeader struct {
  1242  	MessageID    MessageID     `codec:"messageID" json:"messageID"`
  1243  	SupersededBy MessageID     `codec:"supersededBy" json:"supersededBy"`
  1244  	ReactionIDs  []MessageID   `codec:"r" json:"r"`
  1245  	UnfurlIDs    []MessageID   `codec:"u" json:"u"`
  1246  	Replies      []MessageID   `codec:"replies" json:"replies"`
  1247  	Ctime        gregor1.Time  `codec:"ctime" json:"ctime"`
  1248  	Now          gregor1.Time  `codec:"n" json:"n"`
  1249  	Rtime        *gregor1.Time `codec:"rt,omitempty" json:"rt,omitempty"`
  1250  }
  1251  
  1252  func (o MessageServerHeader) DeepCopy() MessageServerHeader {
  1253  	return MessageServerHeader{
  1254  		MessageID:    o.MessageID.DeepCopy(),
  1255  		SupersededBy: o.SupersededBy.DeepCopy(),
  1256  		ReactionIDs: (func(x []MessageID) []MessageID {
  1257  			if x == nil {
  1258  				return nil
  1259  			}
  1260  			ret := make([]MessageID, len(x))
  1261  			for i, v := range x {
  1262  				vCopy := v.DeepCopy()
  1263  				ret[i] = vCopy
  1264  			}
  1265  			return ret
  1266  		})(o.ReactionIDs),
  1267  		UnfurlIDs: (func(x []MessageID) []MessageID {
  1268  			if x == nil {
  1269  				return nil
  1270  			}
  1271  			ret := make([]MessageID, len(x))
  1272  			for i, v := range x {
  1273  				vCopy := v.DeepCopy()
  1274  				ret[i] = vCopy
  1275  			}
  1276  			return ret
  1277  		})(o.UnfurlIDs),
  1278  		Replies: (func(x []MessageID) []MessageID {
  1279  			if x == nil {
  1280  				return nil
  1281  			}
  1282  			ret := make([]MessageID, len(x))
  1283  			for i, v := range x {
  1284  				vCopy := v.DeepCopy()
  1285  				ret[i] = vCopy
  1286  			}
  1287  			return ret
  1288  		})(o.Replies),
  1289  		Ctime: o.Ctime.DeepCopy(),
  1290  		Now:   o.Now.DeepCopy(),
  1291  		Rtime: (func(x *gregor1.Time) *gregor1.Time {
  1292  			if x == nil {
  1293  				return nil
  1294  			}
  1295  			tmp := (*x).DeepCopy()
  1296  			return &tmp
  1297  		})(o.Rtime),
  1298  	}
  1299  }
  1300  
  1301  type MessagePreviousPointer struct {
  1302  	Id   MessageID `codec:"id" json:"id"`
  1303  	Hash Hash      `codec:"hash" json:"hash"`
  1304  }
  1305  
  1306  func (o MessagePreviousPointer) DeepCopy() MessagePreviousPointer {
  1307  	return MessagePreviousPointer{
  1308  		Id:   o.Id.DeepCopy(),
  1309  		Hash: o.Hash.DeepCopy(),
  1310  	}
  1311  }
  1312  
  1313  type OutboxInfo struct {
  1314  	Prev        MessageID    `codec:"prev" json:"prev"`
  1315  	ComposeTime gregor1.Time `codec:"composeTime" json:"composeTime"`
  1316  }
  1317  
  1318  func (o OutboxInfo) DeepCopy() OutboxInfo {
  1319  	return OutboxInfo{
  1320  		Prev:        o.Prev.DeepCopy(),
  1321  		ComposeTime: o.ComposeTime.DeepCopy(),
  1322  	}
  1323  }
  1324  
  1325  type MsgEphemeralMetadata struct {
  1326  	Lifetime   gregor1.DurationSec   `codec:"l" json:"l"`
  1327  	Generation keybase1.EkGeneration `codec:"g" json:"g"`
  1328  	ExplodedBy *string               `codec:"u,omitempty" json:"u,omitempty"`
  1329  }
  1330  
  1331  func (o MsgEphemeralMetadata) DeepCopy() MsgEphemeralMetadata {
  1332  	return MsgEphemeralMetadata{
  1333  		Lifetime:   o.Lifetime.DeepCopy(),
  1334  		Generation: o.Generation.DeepCopy(),
  1335  		ExplodedBy: (func(x *string) *string {
  1336  			if x == nil {
  1337  				return nil
  1338  			}
  1339  			tmp := (*x)
  1340  			return &tmp
  1341  		})(o.ExplodedBy),
  1342  	}
  1343  }
  1344  
  1345  type EphemeralPurgeInfo struct {
  1346  	ConvID          ConversationID `codec:"c" json:"c"`
  1347  	IsActive        bool           `codec:"a" json:"a"`
  1348  	NextPurgeTime   gregor1.Time   `codec:"n" json:"n"`
  1349  	MinUnexplodedID MessageID      `codec:"e" json:"e"`
  1350  }
  1351  
  1352  func (o EphemeralPurgeInfo) DeepCopy() EphemeralPurgeInfo {
  1353  	return EphemeralPurgeInfo{
  1354  		ConvID:          o.ConvID.DeepCopy(),
  1355  		IsActive:        o.IsActive,
  1356  		NextPurgeTime:   o.NextPurgeTime.DeepCopy(),
  1357  		MinUnexplodedID: o.MinUnexplodedID.DeepCopy(),
  1358  	}
  1359  }
  1360  
  1361  type MessageClientHeader struct {
  1362  	Conv              ConversationIDTriple     `codec:"conv" json:"conv"`
  1363  	TlfName           string                   `codec:"tlfName" json:"tlfName"`
  1364  	TlfPublic         bool                     `codec:"tlfPublic" json:"tlfPublic"`
  1365  	MessageType       MessageType              `codec:"messageType" json:"messageType"`
  1366  	Supersedes        MessageID                `codec:"supersedes" json:"supersedes"`
  1367  	KbfsCryptKeysUsed *bool                    `codec:"kbfsCryptKeysUsed,omitempty" json:"kbfsCryptKeysUsed,omitempty"`
  1368  	Deletes           []MessageID              `codec:"deletes" json:"deletes"`
  1369  	Prev              []MessagePreviousPointer `codec:"prev" json:"prev"`
  1370  	DeleteHistory     *MessageDeleteHistory    `codec:"deleteHistory,omitempty" json:"deleteHistory,omitempty"`
  1371  	Sender            gregor1.UID              `codec:"sender" json:"sender"`
  1372  	SenderDevice      gregor1.DeviceID         `codec:"senderDevice" json:"senderDevice"`
  1373  	MerkleRoot        *MerkleRoot              `codec:"merkleRoot,omitempty" json:"merkleRoot,omitempty"`
  1374  	OutboxID          *OutboxID                `codec:"outboxID,omitempty" json:"outboxID,omitempty"`
  1375  	OutboxInfo        *OutboxInfo              `codec:"outboxInfo,omitempty" json:"outboxInfo,omitempty"`
  1376  	EphemeralMetadata *MsgEphemeralMetadata    `codec:"em,omitempty" json:"em,omitempty"`
  1377  	PairwiseMacs      map[keybase1.KID][]byte  `codec:"pm" json:"pm"`
  1378  	BotUID            *gregor1.UID             `codec:"b,omitempty" json:"b,omitempty"`
  1379  	TxID              *stellar1.TransactionID  `codec:"t,omitempty" json:"t,omitempty"`
  1380  }
  1381  
  1382  func (o MessageClientHeader) DeepCopy() MessageClientHeader {
  1383  	return MessageClientHeader{
  1384  		Conv:        o.Conv.DeepCopy(),
  1385  		TlfName:     o.TlfName,
  1386  		TlfPublic:   o.TlfPublic,
  1387  		MessageType: o.MessageType.DeepCopy(),
  1388  		Supersedes:  o.Supersedes.DeepCopy(),
  1389  		KbfsCryptKeysUsed: (func(x *bool) *bool {
  1390  			if x == nil {
  1391  				return nil
  1392  			}
  1393  			tmp := (*x)
  1394  			return &tmp
  1395  		})(o.KbfsCryptKeysUsed),
  1396  		Deletes: (func(x []MessageID) []MessageID {
  1397  			if x == nil {
  1398  				return nil
  1399  			}
  1400  			ret := make([]MessageID, len(x))
  1401  			for i, v := range x {
  1402  				vCopy := v.DeepCopy()
  1403  				ret[i] = vCopy
  1404  			}
  1405  			return ret
  1406  		})(o.Deletes),
  1407  		Prev: (func(x []MessagePreviousPointer) []MessagePreviousPointer {
  1408  			if x == nil {
  1409  				return nil
  1410  			}
  1411  			ret := make([]MessagePreviousPointer, len(x))
  1412  			for i, v := range x {
  1413  				vCopy := v.DeepCopy()
  1414  				ret[i] = vCopy
  1415  			}
  1416  			return ret
  1417  		})(o.Prev),
  1418  		DeleteHistory: (func(x *MessageDeleteHistory) *MessageDeleteHistory {
  1419  			if x == nil {
  1420  				return nil
  1421  			}
  1422  			tmp := (*x).DeepCopy()
  1423  			return &tmp
  1424  		})(o.DeleteHistory),
  1425  		Sender:       o.Sender.DeepCopy(),
  1426  		SenderDevice: o.SenderDevice.DeepCopy(),
  1427  		MerkleRoot: (func(x *MerkleRoot) *MerkleRoot {
  1428  			if x == nil {
  1429  				return nil
  1430  			}
  1431  			tmp := (*x).DeepCopy()
  1432  			return &tmp
  1433  		})(o.MerkleRoot),
  1434  		OutboxID: (func(x *OutboxID) *OutboxID {
  1435  			if x == nil {
  1436  				return nil
  1437  			}
  1438  			tmp := (*x).DeepCopy()
  1439  			return &tmp
  1440  		})(o.OutboxID),
  1441  		OutboxInfo: (func(x *OutboxInfo) *OutboxInfo {
  1442  			if x == nil {
  1443  				return nil
  1444  			}
  1445  			tmp := (*x).DeepCopy()
  1446  			return &tmp
  1447  		})(o.OutboxInfo),
  1448  		EphemeralMetadata: (func(x *MsgEphemeralMetadata) *MsgEphemeralMetadata {
  1449  			if x == nil {
  1450  				return nil
  1451  			}
  1452  			tmp := (*x).DeepCopy()
  1453  			return &tmp
  1454  		})(o.EphemeralMetadata),
  1455  		PairwiseMacs: (func(x map[keybase1.KID][]byte) map[keybase1.KID][]byte {
  1456  			if x == nil {
  1457  				return nil
  1458  			}
  1459  			ret := make(map[keybase1.KID][]byte, len(x))
  1460  			for k, v := range x {
  1461  				kCopy := k.DeepCopy()
  1462  				vCopy := (func(x []byte) []byte {
  1463  					if x == nil {
  1464  						return nil
  1465  					}
  1466  					return append([]byte{}, x...)
  1467  				})(v)
  1468  				ret[kCopy] = vCopy
  1469  			}
  1470  			return ret
  1471  		})(o.PairwiseMacs),
  1472  		BotUID: (func(x *gregor1.UID) *gregor1.UID {
  1473  			if x == nil {
  1474  				return nil
  1475  			}
  1476  			tmp := (*x).DeepCopy()
  1477  			return &tmp
  1478  		})(o.BotUID),
  1479  		TxID: (func(x *stellar1.TransactionID) *stellar1.TransactionID {
  1480  			if x == nil {
  1481  				return nil
  1482  			}
  1483  			tmp := (*x).DeepCopy()
  1484  			return &tmp
  1485  		})(o.TxID),
  1486  	}
  1487  }
  1488  
  1489  type MessageClientHeaderVerified struct {
  1490  	Conv              ConversationIDTriple     `codec:"conv" json:"conv"`
  1491  	TlfName           string                   `codec:"tlfName" json:"tlfName"`
  1492  	TlfPublic         bool                     `codec:"tlfPublic" json:"tlfPublic"`
  1493  	MessageType       MessageType              `codec:"messageType" json:"messageType"`
  1494  	Prev              []MessagePreviousPointer `codec:"prev" json:"prev"`
  1495  	Sender            gregor1.UID              `codec:"sender" json:"sender"`
  1496  	SenderDevice      gregor1.DeviceID         `codec:"senderDevice" json:"senderDevice"`
  1497  	KbfsCryptKeysUsed *bool                    `codec:"kbfsCryptKeysUsed,omitempty" json:"kbfsCryptKeysUsed,omitempty"`
  1498  	MerkleRoot        *MerkleRoot              `codec:"merkleRoot,omitempty" json:"merkleRoot,omitempty"`
  1499  	OutboxID          *OutboxID                `codec:"outboxID,omitempty" json:"outboxID,omitempty"`
  1500  	OutboxInfo        *OutboxInfo              `codec:"outboxInfo,omitempty" json:"outboxInfo,omitempty"`
  1501  	EphemeralMetadata *MsgEphemeralMetadata    `codec:"em,omitempty" json:"em,omitempty"`
  1502  	Rtime             gregor1.Time             `codec:"rt" json:"rt"`
  1503  	HasPairwiseMacs   bool                     `codec:"pm" json:"pm"`
  1504  	BotUID            *gregor1.UID             `codec:"b,omitempty" json:"b,omitempty"`
  1505  }
  1506  
  1507  func (o MessageClientHeaderVerified) DeepCopy() MessageClientHeaderVerified {
  1508  	return MessageClientHeaderVerified{
  1509  		Conv:        o.Conv.DeepCopy(),
  1510  		TlfName:     o.TlfName,
  1511  		TlfPublic:   o.TlfPublic,
  1512  		MessageType: o.MessageType.DeepCopy(),
  1513  		Prev: (func(x []MessagePreviousPointer) []MessagePreviousPointer {
  1514  			if x == nil {
  1515  				return nil
  1516  			}
  1517  			ret := make([]MessagePreviousPointer, len(x))
  1518  			for i, v := range x {
  1519  				vCopy := v.DeepCopy()
  1520  				ret[i] = vCopy
  1521  			}
  1522  			return ret
  1523  		})(o.Prev),
  1524  		Sender:       o.Sender.DeepCopy(),
  1525  		SenderDevice: o.SenderDevice.DeepCopy(),
  1526  		KbfsCryptKeysUsed: (func(x *bool) *bool {
  1527  			if x == nil {
  1528  				return nil
  1529  			}
  1530  			tmp := (*x)
  1531  			return &tmp
  1532  		})(o.KbfsCryptKeysUsed),
  1533  		MerkleRoot: (func(x *MerkleRoot) *MerkleRoot {
  1534  			if x == nil {
  1535  				return nil
  1536  			}
  1537  			tmp := (*x).DeepCopy()
  1538  			return &tmp
  1539  		})(o.MerkleRoot),
  1540  		OutboxID: (func(x *OutboxID) *OutboxID {
  1541  			if x == nil {
  1542  				return nil
  1543  			}
  1544  			tmp := (*x).DeepCopy()
  1545  			return &tmp
  1546  		})(o.OutboxID),
  1547  		OutboxInfo: (func(x *OutboxInfo) *OutboxInfo {
  1548  			if x == nil {
  1549  				return nil
  1550  			}
  1551  			tmp := (*x).DeepCopy()
  1552  			return &tmp
  1553  		})(o.OutboxInfo),
  1554  		EphemeralMetadata: (func(x *MsgEphemeralMetadata) *MsgEphemeralMetadata {
  1555  			if x == nil {
  1556  				return nil
  1557  			}
  1558  			tmp := (*x).DeepCopy()
  1559  			return &tmp
  1560  		})(o.EphemeralMetadata),
  1561  		Rtime:           o.Rtime.DeepCopy(),
  1562  		HasPairwiseMacs: o.HasPairwiseMacs,
  1563  		BotUID: (func(x *gregor1.UID) *gregor1.UID {
  1564  			if x == nil {
  1565  				return nil
  1566  			}
  1567  			tmp := (*x).DeepCopy()
  1568  			return &tmp
  1569  		})(o.BotUID),
  1570  	}
  1571  }
  1572  
  1573  type EncryptedData struct {
  1574  	V int    `codec:"v" json:"v"`
  1575  	E []byte `codec:"e" json:"e"`
  1576  	N []byte `codec:"n" json:"n"`
  1577  }
  1578  
  1579  func (o EncryptedData) DeepCopy() EncryptedData {
  1580  	return EncryptedData{
  1581  		V: o.V,
  1582  		E: (func(x []byte) []byte {
  1583  			if x == nil {
  1584  				return nil
  1585  			}
  1586  			return append([]byte{}, x...)
  1587  		})(o.E),
  1588  		N: (func(x []byte) []byte {
  1589  			if x == nil {
  1590  				return nil
  1591  			}
  1592  			return append([]byte{}, x...)
  1593  		})(o.N),
  1594  	}
  1595  }
  1596  
  1597  type SignEncryptedData struct {
  1598  	V int    `codec:"v" json:"v"`
  1599  	E []byte `codec:"e" json:"e"`
  1600  	N []byte `codec:"n" json:"n"`
  1601  }
  1602  
  1603  func (o SignEncryptedData) DeepCopy() SignEncryptedData {
  1604  	return SignEncryptedData{
  1605  		V: o.V,
  1606  		E: (func(x []byte) []byte {
  1607  			if x == nil {
  1608  				return nil
  1609  			}
  1610  			return append([]byte{}, x...)
  1611  		})(o.E),
  1612  		N: (func(x []byte) []byte {
  1613  			if x == nil {
  1614  				return nil
  1615  			}
  1616  			return append([]byte{}, x...)
  1617  		})(o.N),
  1618  	}
  1619  }
  1620  
  1621  type SealedData struct {
  1622  	V int    `codec:"v" json:"v"`
  1623  	E []byte `codec:"e" json:"e"`
  1624  	N []byte `codec:"n" json:"n"`
  1625  }
  1626  
  1627  func (o SealedData) DeepCopy() SealedData {
  1628  	return SealedData{
  1629  		V: o.V,
  1630  		E: (func(x []byte) []byte {
  1631  			if x == nil {
  1632  				return nil
  1633  			}
  1634  			return append([]byte{}, x...)
  1635  		})(o.E),
  1636  		N: (func(x []byte) []byte {
  1637  			if x == nil {
  1638  				return nil
  1639  			}
  1640  			return append([]byte{}, x...)
  1641  		})(o.N),
  1642  	}
  1643  }
  1644  
  1645  type SignatureInfo struct {
  1646  	V int    `codec:"v" json:"v"`
  1647  	S []byte `codec:"s" json:"s"`
  1648  	K []byte `codec:"k" json:"k"`
  1649  }
  1650  
  1651  func (o SignatureInfo) DeepCopy() SignatureInfo {
  1652  	return SignatureInfo{
  1653  		V: o.V,
  1654  		S: (func(x []byte) []byte {
  1655  			if x == nil {
  1656  				return nil
  1657  			}
  1658  			return append([]byte{}, x...)
  1659  		})(o.S),
  1660  		K: (func(x []byte) []byte {
  1661  			if x == nil {
  1662  				return nil
  1663  			}
  1664  			return append([]byte{}, x...)
  1665  		})(o.K),
  1666  	}
  1667  }
  1668  
  1669  type MerkleRoot struct {
  1670  	Seqno int64  `codec:"seqno" json:"seqno"`
  1671  	Hash  []byte `codec:"hash" json:"hash"`
  1672  }
  1673  
  1674  func (o MerkleRoot) DeepCopy() MerkleRoot {
  1675  	return MerkleRoot{
  1676  		Seqno: o.Seqno,
  1677  		Hash: (func(x []byte) []byte {
  1678  			if x == nil {
  1679  				return nil
  1680  			}
  1681  			return append([]byte{}, x...)
  1682  		})(o.Hash),
  1683  	}
  1684  }
  1685  
  1686  type InboxResType int
  1687  
  1688  const (
  1689  	InboxResType_VERSIONHIT InboxResType = 0
  1690  	InboxResType_FULL       InboxResType = 1
  1691  )
  1692  
  1693  func (o InboxResType) DeepCopy() InboxResType { return o }
  1694  
  1695  var InboxResTypeMap = map[string]InboxResType{
  1696  	"VERSIONHIT": 0,
  1697  	"FULL":       1,
  1698  }
  1699  
  1700  var InboxResTypeRevMap = map[InboxResType]string{
  1701  	0: "VERSIONHIT",
  1702  	1: "FULL",
  1703  }
  1704  
  1705  func (e InboxResType) String() string {
  1706  	if v, ok := InboxResTypeRevMap[e]; ok {
  1707  		return v
  1708  	}
  1709  	return fmt.Sprintf("%v", int(e))
  1710  }
  1711  
  1712  type InboxViewFull struct {
  1713  	Vers          InboxVers      `codec:"vers" json:"vers"`
  1714  	Conversations []Conversation `codec:"conversations" json:"conversations"`
  1715  	Pagination    *Pagination    `codec:"pagination,omitempty" json:"pagination,omitempty"`
  1716  }
  1717  
  1718  func (o InboxViewFull) DeepCopy() InboxViewFull {
  1719  	return InboxViewFull{
  1720  		Vers: o.Vers.DeepCopy(),
  1721  		Conversations: (func(x []Conversation) []Conversation {
  1722  			if x == nil {
  1723  				return nil
  1724  			}
  1725  			ret := make([]Conversation, len(x))
  1726  			for i, v := range x {
  1727  				vCopy := v.DeepCopy()
  1728  				ret[i] = vCopy
  1729  			}
  1730  			return ret
  1731  		})(o.Conversations),
  1732  		Pagination: (func(x *Pagination) *Pagination {
  1733  			if x == nil {
  1734  				return nil
  1735  			}
  1736  			tmp := (*x).DeepCopy()
  1737  			return &tmp
  1738  		})(o.Pagination),
  1739  	}
  1740  }
  1741  
  1742  type InboxView struct {
  1743  	Rtype__ InboxResType   `codec:"rtype" json:"rtype"`
  1744  	Full__  *InboxViewFull `codec:"full,omitempty" json:"full,omitempty"`
  1745  }
  1746  
  1747  func (o *InboxView) Rtype() (ret InboxResType, err error) {
  1748  	switch o.Rtype__ {
  1749  	case InboxResType_FULL:
  1750  		if o.Full__ == nil {
  1751  			err = errors.New("unexpected nil value for Full__")
  1752  			return ret, err
  1753  		}
  1754  	}
  1755  	return o.Rtype__, nil
  1756  }
  1757  
  1758  func (o InboxView) Full() (res InboxViewFull) {
  1759  	if o.Rtype__ != InboxResType_FULL {
  1760  		panic("wrong case accessed")
  1761  	}
  1762  	if o.Full__ == nil {
  1763  		return
  1764  	}
  1765  	return *o.Full__
  1766  }
  1767  
  1768  func NewInboxViewWithVersionhit() InboxView {
  1769  	return InboxView{
  1770  		Rtype__: InboxResType_VERSIONHIT,
  1771  	}
  1772  }
  1773  
  1774  func NewInboxViewWithFull(v InboxViewFull) InboxView {
  1775  	return InboxView{
  1776  		Rtype__: InboxResType_FULL,
  1777  		Full__:  &v,
  1778  	}
  1779  }
  1780  
  1781  func (o InboxView) DeepCopy() InboxView {
  1782  	return InboxView{
  1783  		Rtype__: o.Rtype__.DeepCopy(),
  1784  		Full__: (func(x *InboxViewFull) *InboxViewFull {
  1785  			if x == nil {
  1786  				return nil
  1787  			}
  1788  			tmp := (*x).DeepCopy()
  1789  			return &tmp
  1790  		})(o.Full__),
  1791  	}
  1792  }
  1793  
  1794  type RetentionPolicyType int
  1795  
  1796  const (
  1797  	RetentionPolicyType_NONE      RetentionPolicyType = 0
  1798  	RetentionPolicyType_RETAIN    RetentionPolicyType = 1
  1799  	RetentionPolicyType_EXPIRE    RetentionPolicyType = 2
  1800  	RetentionPolicyType_INHERIT   RetentionPolicyType = 3
  1801  	RetentionPolicyType_EPHEMERAL RetentionPolicyType = 4
  1802  )
  1803  
  1804  func (o RetentionPolicyType) DeepCopy() RetentionPolicyType { return o }
  1805  
  1806  var RetentionPolicyTypeMap = map[string]RetentionPolicyType{
  1807  	"NONE":      0,
  1808  	"RETAIN":    1,
  1809  	"EXPIRE":    2,
  1810  	"INHERIT":   3,
  1811  	"EPHEMERAL": 4,
  1812  }
  1813  
  1814  var RetentionPolicyTypeRevMap = map[RetentionPolicyType]string{
  1815  	0: "NONE",
  1816  	1: "RETAIN",
  1817  	2: "EXPIRE",
  1818  	3: "INHERIT",
  1819  	4: "EPHEMERAL",
  1820  }
  1821  
  1822  func (e RetentionPolicyType) String() string {
  1823  	if v, ok := RetentionPolicyTypeRevMap[e]; ok {
  1824  		return v
  1825  	}
  1826  	return fmt.Sprintf("%v", int(e))
  1827  }
  1828  
  1829  type RetentionPolicy struct {
  1830  	Typ__       RetentionPolicyType `codec:"typ" json:"typ"`
  1831  	Retain__    *RpRetain           `codec:"retain,omitempty" json:"retain,omitempty"`
  1832  	Expire__    *RpExpire           `codec:"expire,omitempty" json:"expire,omitempty"`
  1833  	Inherit__   *RpInherit          `codec:"inherit,omitempty" json:"inherit,omitempty"`
  1834  	Ephemeral__ *RpEphemeral        `codec:"ephemeral,omitempty" json:"ephemeral,omitempty"`
  1835  }
  1836  
  1837  func (o *RetentionPolicy) Typ() (ret RetentionPolicyType, err error) {
  1838  	switch o.Typ__ {
  1839  	case RetentionPolicyType_RETAIN:
  1840  		if o.Retain__ == nil {
  1841  			err = errors.New("unexpected nil value for Retain__")
  1842  			return ret, err
  1843  		}
  1844  	case RetentionPolicyType_EXPIRE:
  1845  		if o.Expire__ == nil {
  1846  			err = errors.New("unexpected nil value for Expire__")
  1847  			return ret, err
  1848  		}
  1849  	case RetentionPolicyType_INHERIT:
  1850  		if o.Inherit__ == nil {
  1851  			err = errors.New("unexpected nil value for Inherit__")
  1852  			return ret, err
  1853  		}
  1854  	case RetentionPolicyType_EPHEMERAL:
  1855  		if o.Ephemeral__ == nil {
  1856  			err = errors.New("unexpected nil value for Ephemeral__")
  1857  			return ret, err
  1858  		}
  1859  	}
  1860  	return o.Typ__, nil
  1861  }
  1862  
  1863  func (o RetentionPolicy) Retain() (res RpRetain) {
  1864  	if o.Typ__ != RetentionPolicyType_RETAIN {
  1865  		panic("wrong case accessed")
  1866  	}
  1867  	if o.Retain__ == nil {
  1868  		return
  1869  	}
  1870  	return *o.Retain__
  1871  }
  1872  
  1873  func (o RetentionPolicy) Expire() (res RpExpire) {
  1874  	if o.Typ__ != RetentionPolicyType_EXPIRE {
  1875  		panic("wrong case accessed")
  1876  	}
  1877  	if o.Expire__ == nil {
  1878  		return
  1879  	}
  1880  	return *o.Expire__
  1881  }
  1882  
  1883  func (o RetentionPolicy) Inherit() (res RpInherit) {
  1884  	if o.Typ__ != RetentionPolicyType_INHERIT {
  1885  		panic("wrong case accessed")
  1886  	}
  1887  	if o.Inherit__ == nil {
  1888  		return
  1889  	}
  1890  	return *o.Inherit__
  1891  }
  1892  
  1893  func (o RetentionPolicy) Ephemeral() (res RpEphemeral) {
  1894  	if o.Typ__ != RetentionPolicyType_EPHEMERAL {
  1895  		panic("wrong case accessed")
  1896  	}
  1897  	if o.Ephemeral__ == nil {
  1898  		return
  1899  	}
  1900  	return *o.Ephemeral__
  1901  }
  1902  
  1903  func NewRetentionPolicyWithRetain(v RpRetain) RetentionPolicy {
  1904  	return RetentionPolicy{
  1905  		Typ__:    RetentionPolicyType_RETAIN,
  1906  		Retain__: &v,
  1907  	}
  1908  }
  1909  
  1910  func NewRetentionPolicyWithExpire(v RpExpire) RetentionPolicy {
  1911  	return RetentionPolicy{
  1912  		Typ__:    RetentionPolicyType_EXPIRE,
  1913  		Expire__: &v,
  1914  	}
  1915  }
  1916  
  1917  func NewRetentionPolicyWithInherit(v RpInherit) RetentionPolicy {
  1918  	return RetentionPolicy{
  1919  		Typ__:     RetentionPolicyType_INHERIT,
  1920  		Inherit__: &v,
  1921  	}
  1922  }
  1923  
  1924  func NewRetentionPolicyWithEphemeral(v RpEphemeral) RetentionPolicy {
  1925  	return RetentionPolicy{
  1926  		Typ__:       RetentionPolicyType_EPHEMERAL,
  1927  		Ephemeral__: &v,
  1928  	}
  1929  }
  1930  
  1931  func (o RetentionPolicy) DeepCopy() RetentionPolicy {
  1932  	return RetentionPolicy{
  1933  		Typ__: o.Typ__.DeepCopy(),
  1934  		Retain__: (func(x *RpRetain) *RpRetain {
  1935  			if x == nil {
  1936  				return nil
  1937  			}
  1938  			tmp := (*x).DeepCopy()
  1939  			return &tmp
  1940  		})(o.Retain__),
  1941  		Expire__: (func(x *RpExpire) *RpExpire {
  1942  			if x == nil {
  1943  				return nil
  1944  			}
  1945  			tmp := (*x).DeepCopy()
  1946  			return &tmp
  1947  		})(o.Expire__),
  1948  		Inherit__: (func(x *RpInherit) *RpInherit {
  1949  			if x == nil {
  1950  				return nil
  1951  			}
  1952  			tmp := (*x).DeepCopy()
  1953  			return &tmp
  1954  		})(o.Inherit__),
  1955  		Ephemeral__: (func(x *RpEphemeral) *RpEphemeral {
  1956  			if x == nil {
  1957  				return nil
  1958  			}
  1959  			tmp := (*x).DeepCopy()
  1960  			return &tmp
  1961  		})(o.Ephemeral__),
  1962  	}
  1963  }
  1964  
  1965  type RpRetain struct {
  1966  }
  1967  
  1968  func (o RpRetain) DeepCopy() RpRetain {
  1969  	return RpRetain{}
  1970  }
  1971  
  1972  type RpExpire struct {
  1973  	Age gregor1.DurationSec `codec:"age" json:"age"`
  1974  }
  1975  
  1976  func (o RpExpire) DeepCopy() RpExpire {
  1977  	return RpExpire{
  1978  		Age: o.Age.DeepCopy(),
  1979  	}
  1980  }
  1981  
  1982  type RpInherit struct {
  1983  }
  1984  
  1985  func (o RpInherit) DeepCopy() RpInherit {
  1986  	return RpInherit{}
  1987  }
  1988  
  1989  type RpEphemeral struct {
  1990  	Age gregor1.DurationSec `codec:"age" json:"age"`
  1991  }
  1992  
  1993  func (o RpEphemeral) DeepCopy() RpEphemeral {
  1994  	return RpEphemeral{
  1995  		Age: o.Age.DeepCopy(),
  1996  	}
  1997  }
  1998  
  1999  type GetThreadReason int
  2000  
  2001  const (
  2002  	GetThreadReason_GENERAL            GetThreadReason = 0
  2003  	GetThreadReason_PUSH               GetThreadReason = 1
  2004  	GetThreadReason_FOREGROUND         GetThreadReason = 2
  2005  	GetThreadReason_BACKGROUNDCONVLOAD GetThreadReason = 3
  2006  	GetThreadReason_FIXRETRY           GetThreadReason = 4
  2007  	GetThreadReason_PREPARE            GetThreadReason = 5
  2008  	GetThreadReason_SEARCHER           GetThreadReason = 6
  2009  	GetThreadReason_INDEXED_SEARCH     GetThreadReason = 7
  2010  	GetThreadReason_KBFSFILEACTIVITY   GetThreadReason = 8
  2011  	GetThreadReason_COINFLIP           GetThreadReason = 9
  2012  	GetThreadReason_BOTCOMMANDS        GetThreadReason = 10
  2013  	GetThreadReason_EMOJISOURCE        GetThreadReason = 11
  2014  	GetThreadReason_FORWARDMSG         GetThreadReason = 12
  2015  	GetThreadReason_LOCALIZE           GetThreadReason = 13
  2016  	GetThreadReason_ARCHIVE            GetThreadReason = 14
  2017  )
  2018  
  2019  func (o GetThreadReason) DeepCopy() GetThreadReason { return o }
  2020  
  2021  var GetThreadReasonMap = map[string]GetThreadReason{
  2022  	"GENERAL":            0,
  2023  	"PUSH":               1,
  2024  	"FOREGROUND":         2,
  2025  	"BACKGROUNDCONVLOAD": 3,
  2026  	"FIXRETRY":           4,
  2027  	"PREPARE":            5,
  2028  	"SEARCHER":           6,
  2029  	"INDEXED_SEARCH":     7,
  2030  	"KBFSFILEACTIVITY":   8,
  2031  	"COINFLIP":           9,
  2032  	"BOTCOMMANDS":        10,
  2033  	"EMOJISOURCE":        11,
  2034  	"FORWARDMSG":         12,
  2035  	"LOCALIZE":           13,
  2036  	"ARCHIVE":            14,
  2037  }
  2038  
  2039  var GetThreadReasonRevMap = map[GetThreadReason]string{
  2040  	0:  "GENERAL",
  2041  	1:  "PUSH",
  2042  	2:  "FOREGROUND",
  2043  	3:  "BACKGROUNDCONVLOAD",
  2044  	4:  "FIXRETRY",
  2045  	5:  "PREPARE",
  2046  	6:  "SEARCHER",
  2047  	7:  "INDEXED_SEARCH",
  2048  	8:  "KBFSFILEACTIVITY",
  2049  	9:  "COINFLIP",
  2050  	10: "BOTCOMMANDS",
  2051  	11: "EMOJISOURCE",
  2052  	12: "FORWARDMSG",
  2053  	13: "LOCALIZE",
  2054  	14: "ARCHIVE",
  2055  }
  2056  
  2057  func (e GetThreadReason) String() string {
  2058  	if v, ok := GetThreadReasonRevMap[e]; ok {
  2059  		return v
  2060  	}
  2061  	return fmt.Sprintf("%v", int(e))
  2062  }
  2063  
  2064  type ReIndexingMode int
  2065  
  2066  const (
  2067  	ReIndexingMode_NONE            ReIndexingMode = 0
  2068  	ReIndexingMode_PRESEARCH_SYNC  ReIndexingMode = 1
  2069  	ReIndexingMode_POSTSEARCH_SYNC ReIndexingMode = 2
  2070  )
  2071  
  2072  func (o ReIndexingMode) DeepCopy() ReIndexingMode { return o }
  2073  
  2074  var ReIndexingModeMap = map[string]ReIndexingMode{
  2075  	"NONE":            0,
  2076  	"PRESEARCH_SYNC":  1,
  2077  	"POSTSEARCH_SYNC": 2,
  2078  }
  2079  
  2080  var ReIndexingModeRevMap = map[ReIndexingMode]string{
  2081  	0: "NONE",
  2082  	1: "PRESEARCH_SYNC",
  2083  	2: "POSTSEARCH_SYNC",
  2084  }
  2085  
  2086  func (e ReIndexingMode) String() string {
  2087  	if v, ok := ReIndexingModeRevMap[e]; ok {
  2088  		return v
  2089  	}
  2090  	return fmt.Sprintf("%v", int(e))
  2091  }
  2092  
  2093  type SearchOpts struct {
  2094  	IsRegex           bool            `codec:"isRegex" json:"isRegex"`
  2095  	SentBy            string          `codec:"sentBy" json:"sentBy"`
  2096  	SentTo            string          `codec:"sentTo" json:"sentTo"`
  2097  	MatchMentions     bool            `codec:"matchMentions" json:"matchMentions"`
  2098  	SentBefore        gregor1.Time    `codec:"sentBefore" json:"sentBefore"`
  2099  	SentAfter         gregor1.Time    `codec:"sentAfter" json:"sentAfter"`
  2100  	MaxHits           int             `codec:"maxHits" json:"maxHits"`
  2101  	MaxMessages       int             `codec:"maxMessages" json:"maxMessages"`
  2102  	BeforeContext     int             `codec:"beforeContext" json:"beforeContext"`
  2103  	AfterContext      int             `codec:"afterContext" json:"afterContext"`
  2104  	InitialPagination *Pagination     `codec:"initialPagination,omitempty" json:"initialPagination,omitempty"`
  2105  	ReindexMode       ReIndexingMode  `codec:"reindexMode" json:"reindexMode"`
  2106  	MaxConvsSearched  int             `codec:"maxConvsSearched" json:"maxConvsSearched"`
  2107  	MaxConvsHit       int             `codec:"maxConvsHit" json:"maxConvsHit"`
  2108  	ConvID            *ConversationID `codec:"convID,omitempty" json:"convID,omitempty"`
  2109  	MaxNameConvs      int             `codec:"maxNameConvs" json:"maxNameConvs"`
  2110  	MaxTeams          int             `codec:"maxTeams" json:"maxTeams"`
  2111  	MaxBots           int             `codec:"maxBots" json:"maxBots"`
  2112  	SkipBotCache      bool            `codec:"skipBotCache" json:"skipBotCache"`
  2113  }
  2114  
  2115  func (o SearchOpts) DeepCopy() SearchOpts {
  2116  	return SearchOpts{
  2117  		IsRegex:       o.IsRegex,
  2118  		SentBy:        o.SentBy,
  2119  		SentTo:        o.SentTo,
  2120  		MatchMentions: o.MatchMentions,
  2121  		SentBefore:    o.SentBefore.DeepCopy(),
  2122  		SentAfter:     o.SentAfter.DeepCopy(),
  2123  		MaxHits:       o.MaxHits,
  2124  		MaxMessages:   o.MaxMessages,
  2125  		BeforeContext: o.BeforeContext,
  2126  		AfterContext:  o.AfterContext,
  2127  		InitialPagination: (func(x *Pagination) *Pagination {
  2128  			if x == nil {
  2129  				return nil
  2130  			}
  2131  			tmp := (*x).DeepCopy()
  2132  			return &tmp
  2133  		})(o.InitialPagination),
  2134  		ReindexMode:      o.ReindexMode.DeepCopy(),
  2135  		MaxConvsSearched: o.MaxConvsSearched,
  2136  		MaxConvsHit:      o.MaxConvsHit,
  2137  		ConvID: (func(x *ConversationID) *ConversationID {
  2138  			if x == nil {
  2139  				return nil
  2140  			}
  2141  			tmp := (*x).DeepCopy()
  2142  			return &tmp
  2143  		})(o.ConvID),
  2144  		MaxNameConvs: o.MaxNameConvs,
  2145  		MaxTeams:     o.MaxTeams,
  2146  		MaxBots:      o.MaxBots,
  2147  		SkipBotCache: o.SkipBotCache,
  2148  	}
  2149  }
  2150  
  2151  type EmptyStruct struct {
  2152  }
  2153  
  2154  func (o EmptyStruct) DeepCopy() EmptyStruct {
  2155  	return EmptyStruct{}
  2156  }
  2157  
  2158  type ChatSearchMatch struct {
  2159  	StartIndex int    `codec:"startIndex" json:"startIndex"`
  2160  	EndIndex   int    `codec:"endIndex" json:"endIndex"`
  2161  	Match      string `codec:"match" json:"match"`
  2162  }
  2163  
  2164  func (o ChatSearchMatch) DeepCopy() ChatSearchMatch {
  2165  	return ChatSearchMatch{
  2166  		StartIndex: o.StartIndex,
  2167  		EndIndex:   o.EndIndex,
  2168  		Match:      o.Match,
  2169  	}
  2170  }
  2171  
  2172  type ChatSearchHit struct {
  2173  	BeforeMessages []UIMessage       `codec:"beforeMessages" json:"beforeMessages"`
  2174  	HitMessage     UIMessage         `codec:"hitMessage" json:"hitMessage"`
  2175  	AfterMessages  []UIMessage       `codec:"afterMessages" json:"afterMessages"`
  2176  	Matches        []ChatSearchMatch `codec:"matches" json:"matches"`
  2177  }
  2178  
  2179  func (o ChatSearchHit) DeepCopy() ChatSearchHit {
  2180  	return ChatSearchHit{
  2181  		BeforeMessages: (func(x []UIMessage) []UIMessage {
  2182  			if x == nil {
  2183  				return nil
  2184  			}
  2185  			ret := make([]UIMessage, len(x))
  2186  			for i, v := range x {
  2187  				vCopy := v.DeepCopy()
  2188  				ret[i] = vCopy
  2189  			}
  2190  			return ret
  2191  		})(o.BeforeMessages),
  2192  		HitMessage: o.HitMessage.DeepCopy(),
  2193  		AfterMessages: (func(x []UIMessage) []UIMessage {
  2194  			if x == nil {
  2195  				return nil
  2196  			}
  2197  			ret := make([]UIMessage, len(x))
  2198  			for i, v := range x {
  2199  				vCopy := v.DeepCopy()
  2200  				ret[i] = vCopy
  2201  			}
  2202  			return ret
  2203  		})(o.AfterMessages),
  2204  		Matches: (func(x []ChatSearchMatch) []ChatSearchMatch {
  2205  			if x == nil {
  2206  				return nil
  2207  			}
  2208  			ret := make([]ChatSearchMatch, len(x))
  2209  			for i, v := range x {
  2210  				vCopy := v.DeepCopy()
  2211  				ret[i] = vCopy
  2212  			}
  2213  			return ret
  2214  		})(o.Matches),
  2215  	}
  2216  }
  2217  
  2218  type ChatSearchInboxHit struct {
  2219  	ConvID   ConversationID  `codec:"convID" json:"convID"`
  2220  	TeamType TeamType        `codec:"teamType" json:"teamType"`
  2221  	ConvName string          `codec:"convName" json:"convName"`
  2222  	Query    string          `codec:"query" json:"query"`
  2223  	Time     gregor1.Time    `codec:"time" json:"time"`
  2224  	Hits     []ChatSearchHit `codec:"hits" json:"hits"`
  2225  }
  2226  
  2227  func (o ChatSearchInboxHit) DeepCopy() ChatSearchInboxHit {
  2228  	return ChatSearchInboxHit{
  2229  		ConvID:   o.ConvID.DeepCopy(),
  2230  		TeamType: o.TeamType.DeepCopy(),
  2231  		ConvName: o.ConvName,
  2232  		Query:    o.Query,
  2233  		Time:     o.Time.DeepCopy(),
  2234  		Hits: (func(x []ChatSearchHit) []ChatSearchHit {
  2235  			if x == nil {
  2236  				return nil
  2237  			}
  2238  			ret := make([]ChatSearchHit, len(x))
  2239  			for i, v := range x {
  2240  				vCopy := v.DeepCopy()
  2241  				ret[i] = vCopy
  2242  			}
  2243  			return ret
  2244  		})(o.Hits),
  2245  	}
  2246  }
  2247  
  2248  type ChatSearchInboxResults struct {
  2249  	Hits           []ChatSearchInboxHit `codec:"hits" json:"hits"`
  2250  	PercentIndexed int                  `codec:"percentIndexed" json:"percentIndexed"`
  2251  }
  2252  
  2253  func (o ChatSearchInboxResults) DeepCopy() ChatSearchInboxResults {
  2254  	return ChatSearchInboxResults{
  2255  		Hits: (func(x []ChatSearchInboxHit) []ChatSearchInboxHit {
  2256  			if x == nil {
  2257  				return nil
  2258  			}
  2259  			ret := make([]ChatSearchInboxHit, len(x))
  2260  			for i, v := range x {
  2261  				vCopy := v.DeepCopy()
  2262  				ret[i] = vCopy
  2263  			}
  2264  			return ret
  2265  		})(o.Hits),
  2266  		PercentIndexed: o.PercentIndexed,
  2267  	}
  2268  }
  2269  
  2270  type ChatSearchInboxDone struct {
  2271  	NumHits        int  `codec:"numHits" json:"numHits"`
  2272  	NumConvs       int  `codec:"numConvs" json:"numConvs"`
  2273  	PercentIndexed int  `codec:"percentIndexed" json:"percentIndexed"`
  2274  	Delegated      bool `codec:"delegated" json:"delegated"`
  2275  }
  2276  
  2277  func (o ChatSearchInboxDone) DeepCopy() ChatSearchInboxDone {
  2278  	return ChatSearchInboxDone{
  2279  		NumHits:        o.NumHits,
  2280  		NumConvs:       o.NumConvs,
  2281  		PercentIndexed: o.PercentIndexed,
  2282  		Delegated:      o.Delegated,
  2283  	}
  2284  }
  2285  
  2286  type ChatSearchIndexStatus struct {
  2287  	PercentIndexed int `codec:"percentIndexed" json:"percentIndexed"`
  2288  }
  2289  
  2290  func (o ChatSearchIndexStatus) DeepCopy() ChatSearchIndexStatus {
  2291  	return ChatSearchIndexStatus{
  2292  		PercentIndexed: o.PercentIndexed,
  2293  	}
  2294  }
  2295  
  2296  type AssetMetadataImage struct {
  2297  	Width     int       `codec:"width" json:"width"`
  2298  	Height    int       `codec:"height" json:"height"`
  2299  	AudioAmps []float64 `codec:"audioAmps" json:"audioAmps"`
  2300  }
  2301  
  2302  func (o AssetMetadataImage) DeepCopy() AssetMetadataImage {
  2303  	return AssetMetadataImage{
  2304  		Width:  o.Width,
  2305  		Height: o.Height,
  2306  		AudioAmps: (func(x []float64) []float64 {
  2307  			if x == nil {
  2308  				return nil
  2309  			}
  2310  			ret := make([]float64, len(x))
  2311  			for i, v := range x {
  2312  				vCopy := v
  2313  				ret[i] = vCopy
  2314  			}
  2315  			return ret
  2316  		})(o.AudioAmps),
  2317  	}
  2318  }
  2319  
  2320  type AssetMetadataVideo struct {
  2321  	Width      int  `codec:"width" json:"width"`
  2322  	Height     int  `codec:"height" json:"height"`
  2323  	DurationMs int  `codec:"durationMs" json:"durationMs"`
  2324  	IsAudio    bool `codec:"isAudio" json:"isAudio"`
  2325  }
  2326  
  2327  func (o AssetMetadataVideo) DeepCopy() AssetMetadataVideo {
  2328  	return AssetMetadataVideo{
  2329  		Width:      o.Width,
  2330  		Height:     o.Height,
  2331  		DurationMs: o.DurationMs,
  2332  		IsAudio:    o.IsAudio,
  2333  	}
  2334  }
  2335  
  2336  type AssetMetadataType int
  2337  
  2338  const (
  2339  	AssetMetadataType_NONE  AssetMetadataType = 0
  2340  	AssetMetadataType_IMAGE AssetMetadataType = 1
  2341  	AssetMetadataType_VIDEO AssetMetadataType = 2
  2342  )
  2343  
  2344  func (o AssetMetadataType) DeepCopy() AssetMetadataType { return o }
  2345  
  2346  var AssetMetadataTypeMap = map[string]AssetMetadataType{
  2347  	"NONE":  0,
  2348  	"IMAGE": 1,
  2349  	"VIDEO": 2,
  2350  }
  2351  
  2352  var AssetMetadataTypeRevMap = map[AssetMetadataType]string{
  2353  	0: "NONE",
  2354  	1: "IMAGE",
  2355  	2: "VIDEO",
  2356  }
  2357  
  2358  type AssetMetadata struct {
  2359  	AssetType__ AssetMetadataType   `codec:"assetType" json:"assetType"`
  2360  	Image__     *AssetMetadataImage `codec:"image,omitempty" json:"image,omitempty"`
  2361  	Video__     *AssetMetadataVideo `codec:"video,omitempty" json:"video,omitempty"`
  2362  }
  2363  
  2364  func (o *AssetMetadata) AssetType() (ret AssetMetadataType, err error) {
  2365  	switch o.AssetType__ {
  2366  	case AssetMetadataType_IMAGE:
  2367  		if o.Image__ == nil {
  2368  			err = errors.New("unexpected nil value for Image__")
  2369  			return ret, err
  2370  		}
  2371  	case AssetMetadataType_VIDEO:
  2372  		if o.Video__ == nil {
  2373  			err = errors.New("unexpected nil value for Video__")
  2374  			return ret, err
  2375  		}
  2376  	}
  2377  	return o.AssetType__, nil
  2378  }
  2379  
  2380  func (o AssetMetadata) Image() (res AssetMetadataImage) {
  2381  	if o.AssetType__ != AssetMetadataType_IMAGE {
  2382  		panic("wrong case accessed")
  2383  	}
  2384  	if o.Image__ == nil {
  2385  		return
  2386  	}
  2387  	return *o.Image__
  2388  }
  2389  
  2390  func (o AssetMetadata) Video() (res AssetMetadataVideo) {
  2391  	if o.AssetType__ != AssetMetadataType_VIDEO {
  2392  		panic("wrong case accessed")
  2393  	}
  2394  	if o.Video__ == nil {
  2395  		return
  2396  	}
  2397  	return *o.Video__
  2398  }
  2399  
  2400  func NewAssetMetadataWithImage(v AssetMetadataImage) AssetMetadata {
  2401  	return AssetMetadata{
  2402  		AssetType__: AssetMetadataType_IMAGE,
  2403  		Image__:     &v,
  2404  	}
  2405  }
  2406  
  2407  func NewAssetMetadataWithVideo(v AssetMetadataVideo) AssetMetadata {
  2408  	return AssetMetadata{
  2409  		AssetType__: AssetMetadataType_VIDEO,
  2410  		Video__:     &v,
  2411  	}
  2412  }
  2413  
  2414  func (o AssetMetadata) DeepCopy() AssetMetadata {
  2415  	return AssetMetadata{
  2416  		AssetType__: o.AssetType__.DeepCopy(),
  2417  		Image__: (func(x *AssetMetadataImage) *AssetMetadataImage {
  2418  			if x == nil {
  2419  				return nil
  2420  			}
  2421  			tmp := (*x).DeepCopy()
  2422  			return &tmp
  2423  		})(o.Image__),
  2424  		Video__: (func(x *AssetMetadataVideo) *AssetMetadataVideo {
  2425  			if x == nil {
  2426  				return nil
  2427  			}
  2428  			tmp := (*x).DeepCopy()
  2429  			return &tmp
  2430  		})(o.Video__),
  2431  	}
  2432  }
  2433  
  2434  type AssetTag int
  2435  
  2436  const (
  2437  	AssetTag_PRIMARY AssetTag = 0
  2438  )
  2439  
  2440  func (o AssetTag) DeepCopy() AssetTag { return o }
  2441  
  2442  var AssetTagMap = map[string]AssetTag{
  2443  	"PRIMARY": 0,
  2444  }
  2445  
  2446  var AssetTagRevMap = map[AssetTag]string{
  2447  	0: "PRIMARY",
  2448  }
  2449  
  2450  type Asset struct {
  2451  	Filename  string        `codec:"filename" json:"filename"`
  2452  	Region    string        `codec:"region" json:"region"`
  2453  	Endpoint  string        `codec:"endpoint" json:"endpoint"`
  2454  	Bucket    string        `codec:"bucket" json:"bucket"`
  2455  	Path      string        `codec:"path" json:"path"`
  2456  	Size      int64         `codec:"size" json:"size"`
  2457  	MimeType  string        `codec:"mimeType" json:"mimeType"`
  2458  	EncHash   Hash          `codec:"encHash" json:"encHash"`
  2459  	PtHash    Hash          `codec:"ptHash" json:"ptHash"`
  2460  	Key       []byte        `codec:"key" json:"key"`
  2461  	VerifyKey []byte        `codec:"verifyKey" json:"verifyKey"`
  2462  	Title     string        `codec:"title" json:"title"`
  2463  	Nonce     []byte        `codec:"nonce" json:"nonce"`
  2464  	Metadata  AssetMetadata `codec:"metadata" json:"metadata"`
  2465  	Tag       AssetTag      `codec:"tag" json:"tag"`
  2466  }
  2467  
  2468  func (o Asset) DeepCopy() Asset {
  2469  	return Asset{
  2470  		Filename: o.Filename,
  2471  		Region:   o.Region,
  2472  		Endpoint: o.Endpoint,
  2473  		Bucket:   o.Bucket,
  2474  		Path:     o.Path,
  2475  		Size:     o.Size,
  2476  		MimeType: o.MimeType,
  2477  		EncHash:  o.EncHash.DeepCopy(),
  2478  		PtHash:   o.PtHash.DeepCopy(),
  2479  		Key: (func(x []byte) []byte {
  2480  			if x == nil {
  2481  				return nil
  2482  			}
  2483  			return append([]byte{}, x...)
  2484  		})(o.Key),
  2485  		VerifyKey: (func(x []byte) []byte {
  2486  			if x == nil {
  2487  				return nil
  2488  			}
  2489  			return append([]byte{}, x...)
  2490  		})(o.VerifyKey),
  2491  		Title: o.Title,
  2492  		Nonce: (func(x []byte) []byte {
  2493  			if x == nil {
  2494  				return nil
  2495  			}
  2496  			return append([]byte{}, x...)
  2497  		})(o.Nonce),
  2498  		Metadata: o.Metadata.DeepCopy(),
  2499  		Tag:      o.Tag.DeepCopy(),
  2500  	}
  2501  }
  2502  
  2503  type BotCommandsAdvertisementTyp int
  2504  
  2505  const (
  2506  	BotCommandsAdvertisementTyp_PUBLIC        BotCommandsAdvertisementTyp = 0
  2507  	BotCommandsAdvertisementTyp_TLFID_MEMBERS BotCommandsAdvertisementTyp = 1
  2508  	BotCommandsAdvertisementTyp_TLFID_CONVS   BotCommandsAdvertisementTyp = 2
  2509  	BotCommandsAdvertisementTyp_CONV          BotCommandsAdvertisementTyp = 3
  2510  )
  2511  
  2512  func (o BotCommandsAdvertisementTyp) DeepCopy() BotCommandsAdvertisementTyp { return o }
  2513  
  2514  var BotCommandsAdvertisementTypMap = map[string]BotCommandsAdvertisementTyp{
  2515  	"PUBLIC":        0,
  2516  	"TLFID_MEMBERS": 1,
  2517  	"TLFID_CONVS":   2,
  2518  	"CONV":          3,
  2519  }
  2520  
  2521  var BotCommandsAdvertisementTypRevMap = map[BotCommandsAdvertisementTyp]string{
  2522  	0: "PUBLIC",
  2523  	1: "TLFID_MEMBERS",
  2524  	2: "TLFID_CONVS",
  2525  	3: "CONV",
  2526  }
  2527  
  2528  func (e BotCommandsAdvertisementTyp) String() string {
  2529  	if v, ok := BotCommandsAdvertisementTypRevMap[e]; ok {
  2530  		return v
  2531  	}
  2532  	return fmt.Sprintf("%v", int(e))
  2533  }
  2534  
  2535  type TeamMember struct {
  2536  	Uid    gregor1.UID               `codec:"uid" json:"uid"`
  2537  	Role   keybase1.TeamRole         `codec:"role" json:"role"`
  2538  	Status keybase1.TeamMemberStatus `codec:"status" json:"status"`
  2539  }
  2540  
  2541  func (o TeamMember) DeepCopy() TeamMember {
  2542  	return TeamMember{
  2543  		Uid:    o.Uid.DeepCopy(),
  2544  		Role:   o.Role.DeepCopy(),
  2545  		Status: o.Status.DeepCopy(),
  2546  	}
  2547  }
  2548  
  2549  type LastActiveStatus int
  2550  
  2551  const (
  2552  	LastActiveStatus_NONE            LastActiveStatus = 0
  2553  	LastActiveStatus_ACTIVE          LastActiveStatus = 1
  2554  	LastActiveStatus_RECENTLY_ACTIVE LastActiveStatus = 2
  2555  )
  2556  
  2557  func (o LastActiveStatus) DeepCopy() LastActiveStatus { return o }
  2558  
  2559  var LastActiveStatusMap = map[string]LastActiveStatus{
  2560  	"NONE":            0,
  2561  	"ACTIVE":          1,
  2562  	"RECENTLY_ACTIVE": 2,
  2563  }
  2564  
  2565  var LastActiveStatusRevMap = map[LastActiveStatus]string{
  2566  	0: "NONE",
  2567  	1: "ACTIVE",
  2568  	2: "RECENTLY_ACTIVE",
  2569  }
  2570  
  2571  func (e LastActiveStatus) String() string {
  2572  	if v, ok := LastActiveStatusRevMap[e]; ok {
  2573  		return v
  2574  	}
  2575  	return fmt.Sprintf("%v", int(e))
  2576  }
  2577  
  2578  type ChatMemberDetails struct {
  2579  	Uid      keybase1.UID      `codec:"uid" json:"uid"`
  2580  	Username string            `codec:"username" json:"username"`
  2581  	FullName keybase1.FullName `codec:"fullName" json:"fullName"`
  2582  }
  2583  
  2584  func (o ChatMemberDetails) DeepCopy() ChatMemberDetails {
  2585  	return ChatMemberDetails{
  2586  		Uid:      o.Uid.DeepCopy(),
  2587  		Username: o.Username,
  2588  		FullName: o.FullName.DeepCopy(),
  2589  	}
  2590  }
  2591  
  2592  type ChatMembersDetails struct {
  2593  	Owners         []ChatMemberDetails `codec:"owners" json:"owners"`
  2594  	Admins         []ChatMemberDetails `codec:"admins" json:"admins"`
  2595  	Writers        []ChatMemberDetails `codec:"writers" json:"writers"`
  2596  	Readers        []ChatMemberDetails `codec:"readers" json:"readers"`
  2597  	Bots           []ChatMemberDetails `codec:"bots" json:"bots"`
  2598  	RestrictedBots []ChatMemberDetails `codec:"restrictedBots" json:"restrictedBots"`
  2599  }
  2600  
  2601  func (o ChatMembersDetails) DeepCopy() ChatMembersDetails {
  2602  	return ChatMembersDetails{
  2603  		Owners: (func(x []ChatMemberDetails) []ChatMemberDetails {
  2604  			if x == nil {
  2605  				return nil
  2606  			}
  2607  			ret := make([]ChatMemberDetails, len(x))
  2608  			for i, v := range x {
  2609  				vCopy := v.DeepCopy()
  2610  				ret[i] = vCopy
  2611  			}
  2612  			return ret
  2613  		})(o.Owners),
  2614  		Admins: (func(x []ChatMemberDetails) []ChatMemberDetails {
  2615  			if x == nil {
  2616  				return nil
  2617  			}
  2618  			ret := make([]ChatMemberDetails, len(x))
  2619  			for i, v := range x {
  2620  				vCopy := v.DeepCopy()
  2621  				ret[i] = vCopy
  2622  			}
  2623  			return ret
  2624  		})(o.Admins),
  2625  		Writers: (func(x []ChatMemberDetails) []ChatMemberDetails {
  2626  			if x == nil {
  2627  				return nil
  2628  			}
  2629  			ret := make([]ChatMemberDetails, len(x))
  2630  			for i, v := range x {
  2631  				vCopy := v.DeepCopy()
  2632  				ret[i] = vCopy
  2633  			}
  2634  			return ret
  2635  		})(o.Writers),
  2636  		Readers: (func(x []ChatMemberDetails) []ChatMemberDetails {
  2637  			if x == nil {
  2638  				return nil
  2639  			}
  2640  			ret := make([]ChatMemberDetails, len(x))
  2641  			for i, v := range x {
  2642  				vCopy := v.DeepCopy()
  2643  				ret[i] = vCopy
  2644  			}
  2645  			return ret
  2646  		})(o.Readers),
  2647  		Bots: (func(x []ChatMemberDetails) []ChatMemberDetails {
  2648  			if x == nil {
  2649  				return nil
  2650  			}
  2651  			ret := make([]ChatMemberDetails, len(x))
  2652  			for i, v := range x {
  2653  				vCopy := v.DeepCopy()
  2654  				ret[i] = vCopy
  2655  			}
  2656  			return ret
  2657  		})(o.Bots),
  2658  		RestrictedBots: (func(x []ChatMemberDetails) []ChatMemberDetails {
  2659  			if x == nil {
  2660  				return nil
  2661  			}
  2662  			ret := make([]ChatMemberDetails, len(x))
  2663  			for i, v := range x {
  2664  				vCopy := v.DeepCopy()
  2665  				ret[i] = vCopy
  2666  			}
  2667  			return ret
  2668  		})(o.RestrictedBots),
  2669  	}
  2670  }
  2671  
  2672  type CommonInterface interface {
  2673  }
  2674  
  2675  func CommonProtocol(i CommonInterface) rpc.Protocol {
  2676  	return rpc.Protocol{
  2677  		Name:    "chat.1.common",
  2678  		Methods: map[string]rpc.ServeHandlerDescription{},
  2679  	}
  2680  }
  2681  
  2682  type CommonClient struct {
  2683  	Cli rpc.GenericClient
  2684  }