// ToRawInfo returns a description of Document suitable for JSON or YAML export.
349793
func (m *Document) ToRawInfo() interface{} {
	info := yaml.MapSlice{}
	if m.Kind != "" {
		info = append(info, yaml.MapItem{Key: "kind", Value: m.Kind})
	}
	if m.DiscoveryVersion != "" {
		info = append(info, yaml.MapItem{Key: "discoveryVersion", Value: m.DiscoveryVersion})
	}
	if m.Id != "" {
		info = append(info, yaml.MapItem{Key: "id", Value: m.Id})
	}
	if m.Name != "" {
		info = append(info, yaml.MapItem{Key: "name", Value: m.Name})
	}
	if m.Version != "" {
		info = append(info, yaml.MapItem{Key: "version", Value: m.Version})
	}
	if m.Revision != "" {
		info = append(info, yaml.MapItem{Key: "revision", Value: m.Revision})
	}
	if m.Title != "" {
		info = append(info, yaml.MapItem{Key: "title", Value: m.Title})
	}
	if m.Description != "" {
		info = append(info, yaml.MapItem{Key: "description", Value: m.Description})
	}
	if m.Icons != nil {
		info = append(info, yaml.MapItem{Key: "icons", Value: m.Icons.ToRawInfo()})
	}
	// &{Name:icons Type:Icons StringEnumValues:[] MapType: Repeated:false Pattern: Implicit:false Description:}
	if m.DocumentationLink != "" {
		info = append(info, yaml.MapItem{Key: "documentationLink", Value: m.DocumentationLink})
	}
	if len(m.Labels) != 0 {
		info = append(info, yaml.MapItem{Key: "labels", Value: m.Labels})
	}
	if m.Protocol != "" {
		info = append(info, yaml.MapItem{Key: "protocol", Value: m.Protocol})
	}
	if m.BaseUrl != "" {
		info = append(info, yaml.MapItem{Key: "baseUrl", Value: m.BaseUrl})
	}
	if m.BasePath != "" {
		info = append(info, yaml.MapItem{Key: "basePath", Value: m.BasePath})
	}
	if m.RootUrl != "" {
		info = append(info, yaml.MapItem{Key: "rootUrl", Value: m.RootUrl})
	}
	if m.ServicePath != "" {
		info = append(info, yaml.MapItem{Key: "servicePath", Value: m.ServicePath})
	}
	if m.BatchPath != "" {
		info = append(info, yaml.MapItem{Key: "batchPath", Value: m.BatchPath})
	}
	if m.Parameters != nil {
		info = append(info, yaml.MapItem{Key: "parameters", Value: m.Parameters.ToRawInfo()})
	}
	// &{Name:parameters Type:Parameters StringEnumValues:[] MapType: Repeated:false Pattern: Implicit:false Description:}
	if m.Auth != nil {
		info = append(info, yaml.MapItem{Key: "auth", Value: m.Auth.ToRawInfo()})
	}
	// &{Name:auth Type:Auth StringEnumValues:[] MapType: Repeated:false Pattern: Implicit:false Description:}
	if len(m.Features) != 0 {
		info = append(info, yaml.MapItem{Key: "features", Value: m.Features})
	}
	if m.Schemas != nil {
		info = append(info, yaml.MapItem{Key: "schemas", Value: m.Schemas.ToRawInfo()})
	}
	// &{Name:schemas Type:Schemas StringEnumValues:[] MapType: Repeated:false Pattern: Implicit:false Description:}
	if m.Methods != nil {
		info = append(info, yaml.MapItem{Key: "methods", Value: m.Methods.ToRawInfo()})
	}
	// &{Name:methods Type:Methods StringEnumValues:[] MapType: Repeated:false Pattern: Implicit:false Description:}
	if m.Resources != nil {
		info = append(info, yaml.MapItem{Key: "resources", Value: m.Resources.ToRawInfo()})
	}
	// &{Name:resources Type:Resources StringEnumValues:[] MapType: Repeated:false Pattern: Implicit:false Description:}
	if m.Etag != "" {
		info = append(info, yaml.MapItem{Key: "etag", Value: m.Etag})
	}
	if m.OwnerDomain != "" {
		info = append(info, yaml.MapItem{Key: "ownerDomain", Value: m.OwnerDomain})
	}
	if m.OwnerName != "" {
		info = append(info, yaml.MapItem{Key: "ownerName", Value: m.OwnerName})
	}
	if m.VersionModule != false {
		info = append(info, yaml.MapItem{Key: "version_module", Value: m.VersionModule})
	}
	if m.CanonicalName != "" {
		info = append(info, yaml.MapItem{Key: "canonicalName", Value: m.CanonicalName})
	}
	if m.FullyEncodeReservedExpansion != false {
		info = append(info, yaml.MapItem{Key: "fullyEncodeReservedExpansion", Value: m.FullyEncodeReservedExpansion})
	}
	if m.PackagePath != "" {
		info = append(info, yaml.MapItem{Key: "packagePath", Value: m.PackagePath})
	}
	return info
}
950555
func (m *PathItem) ToRawInfo() interface{} {
	info := yaml.MapSlice{}
	if m == nil {
		return info
	}
	if m.XRef != "" {
		info = append(info, yaml.MapItem{Key: "$ref", Value: m.XRef})
	}
	if m.Summary != "" {
		info = append(info, yaml.MapItem{Key: "summary", Value: m.Summary})
	}
	if m.Description != "" {
		info = append(info, yaml.MapItem{Key: "description", Value: m.Description})
	}
	if m.Get != nil {
		info = append(info, yaml.MapItem{Key: "get", Value: m.Get.ToRawInfo()})
	}
	// &{Name:get Type:Operation StringEnumValues:[] MapType: Repeated:false Pattern: Implicit:false Description:}
	if m.Put != nil {
		info = append(info, yaml.MapItem{Key: "put", Value: m.Put.ToRawInfo()})
	}
	// &{Name:put Type:Operation StringEnumValues:[] MapType: Repeated:false Pattern: Implicit:false Description:}
	if m.Post != nil {
		info = append(info, yaml.MapItem{Key: "post", Value: m.Post.ToRawInfo()})
	}
	// &{Name:post Type:Operation StringEnumValues:[] MapType: Repeated:false Pattern: Implicit:false Description:}
	if m.Delete != nil {
		info = append(info, yaml.MapItem{Key: "delete", Value: m.Delete.ToRawInfo()})
	}
	// &{Name:delete Type:Operation StringEnumValues:[] MapType: Repeated:false Pattern: Implicit:false Description:}
	if m.Options != nil {
		info = append(info, yaml.MapItem{Key: "options", Value: m.Options.ToRawInfo()})
	}
	// &{Name:options Type:Operation StringEnumValues:[] MapType: Repeated:false Pattern: Implicit:false Description:}
	if m.Head != nil {
		info = append(info, yaml.MapItem{Key: "head", Value: m.Head.ToRawInfo()})
	}
	// &{Name:head Type:Operation StringEnumValues:[] MapType: Repeated:false Pattern: Implicit:false Description:}
	if m.Patch != nil {
		info = append(info, yaml.MapItem{Key: "patch", Value: m.Patch.ToRawInfo()})
	}
	// &{Name:patch Type:Operation StringEnumValues:[] MapType: Repeated:false Pattern: Implicit:false Description:}
	if m.Trace != nil {
		info = append(info, yaml.MapItem{Key: "trace", Value: m.Trace.ToRawInfo()})
	}
	// &{Name:trace Type:Operation StringEnumValues:[] MapType: Repeated:false Pattern: Implicit:false Description:}
	if len(m.Servers) != 0 {
		items := make([]interface{}, 0)
		for _, item := range m.Servers {
			items = append(items, item.ToRawInfo())
		}
		info = append(info, yaml.MapItem{Key: "servers", Value: items})
	}
	// &{Name:servers Type:Server StringEnumValues:[] MapType: Repeated:true Pattern: Implicit:false Description:}
	if len(m.Parameters) != 0 {
		items := make([]interface{}, 0)
		for _, item := range m.Parameters {
			items = append(items, item.ToRawInfo())
		}
		info = append(info, yaml.MapItem{Key: "parameters", Value: items})
	}
	// &{Name:parameters Type:ParameterOrReference StringEnumValues:[] MapType: Repeated:true Pattern: Implicit:false Description:}
	if m.SpecificationExtension != nil {
		for _, item := range m.SpecificationExtension {
			info = append(info, yaml.MapItem{Key: item.Name, Value: item.Value.ToRawInfo()})
		}
	}
	// &{Name:SpecificationExtension Type:NamedAny StringEnumValues:[] MapType:Any Repeated:true Pattern:^x- Implicit:true Description:}
	return info
}
1278423
func (m *SchemaOrReference) ToRawInfo() interface{} {
	// ONE OF WRAPPER
	// SchemaOrReference
	// {Name:schema Type:Schema StringEnumValues:[] MapType: Repeated:false Pattern: Implicit:false Description:}
	v0 := m.GetSchema()
	if v0 != nil {
		return v0.ToRawInfo()
	}
	// {Name:reference Type:Reference StringEnumValues:[] MapType: Repeated:false Pattern: Implicit:false Description:}
	v1 := m.GetReference()
	if v1 != nil {
		return v1.ToRawInfo()
	}
	return nil
}
649993
func (m *AdditionalPropertiesItem) ToRawInfo() interface{} {
	// ONE OF WRAPPER
	// AdditionalPropertiesItem
	// {Name:schema Type:Schema StringEnumValues:[] MapType: Repeated:false Pattern: Implicit:false Description:}
	v0 := m.GetSchema()
	if v0 != nil {
		return v0.ToRawInfo()
	}
	// {Name:boolean Type:bool StringEnumValues:[] MapType: Repeated:false Pattern: Implicit:false Description:}
	if v1, ok := m.GetOneof().(*AdditionalPropertiesItem_Boolean); ok {
		return v1.Boolean
	}
	return nil
}
839047
func (m *ServerVariable) ToRawInfo() interface{} {
	info := yaml.MapSlice{}
	if m == nil {
		return info
	}
	if len(m.Enum) != 0 {
		info = append(info, yaml.MapItem{Key: "enum", Value: m.Enum})
	}
	// always include this required field.
	info = append(info, yaml.MapItem{Key: "default", Value: m.Default})
	if m.Description != "" {
		info = append(info, yaml.MapItem{Key: "description", Value: m.Description})
	}
	if m.SpecificationExtension != nil {
		for _, item := range m.SpecificationExtension {
			info = append(info, yaml.MapItem{Key: item.Name, Value: item.Value.ToRawInfo()})
		}
	}
	// &{Name:SpecificationExtension Type:NamedAny StringEnumValues:[] MapType:Any Repeated:true Pattern:^x- Implicit:true Description:}
	return info
}
877074
func (m *MockConfig) MongoInfo() (*mongo.MongoInfo, bool) {
	ret := m.ctrl.Call(m, "MongoInfo")
	ret0, _ := ret[0].(*mongo.MongoInfo)
	ret1, _ := ret[1].(bool)
	return ret0, ret1
}
638120
func (m *NamedString) ToRawInfo() interface{} {
	info := yaml.MapSlice{}
	if m == nil {
		return info
	}
	if m.Name != "" {
		info = append(info, yaml.MapItem{Key: "name", Value: m.Name})
	}
	if m.Value != "" {
		info = append(info, yaml.MapItem{Key: "value", Value: m.Value})
	}
	return info
}
448500
func (ld LogDescription) Info(exp time.Time) (string, string, error) {
	if ld.TemporalSet == nil {
		return ld.URI, ld.Key, nil
	}
	shard, err := ld.TemporalSet.pick(exp)
	if err != nil {
		return "", "", err
	}
	return shard.URI, shard.Key, nil
}
1333619
func (m *Response) ToRawInfo() interface{} {
	info := yaml.MapSlice{}
	if m == nil {
		return info
	}
	// always include this required field.
	info = append(info, yaml.MapItem{Key: "description", Value: m.Description})
	if m.Headers != nil {
		info = append(info, yaml.MapItem{Key: "headers", Value: m.Headers.ToRawInfo()})
	}
	// &{Name:headers Type:HeadersOrReferences StringEnumValues:[] MapType: Repeated:false Pattern: Implicit:false Description:}
	if m.Content != nil {
		info = append(info, yaml.MapItem{Key: "content", Value: m.Content.ToRawInfo()})
	}
	// &{Name:content Type:MediaTypes StringEnumValues:[] MapType: Repeated:false Pattern: Implicit:false Description:}
	if m.Links != nil {
		info = append(info, yaml.MapItem{Key: "links", Value: m.Links.ToRawInfo()})
	}
	// &{Name:links Type:LinksOrReferences StringEnumValues:[] MapType: Repeated:false Pattern: Implicit:false Description:}
	if m.SpecificationExtension != nil {
		for _, item := range m.SpecificationExtension {
			info = append(info, yaml.MapItem{Key: item.Name, Value: item.Value.ToRawInfo()})
		}
	}
	// &{Name:SpecificationExtension Type:NamedAny StringEnumValues:[] MapType:Any Repeated:true Pattern:^x- Implicit:true Description:}
	return info
}
639145
func (obj *GenericObject) GetInfoRaw(ctx context.Context) (json.RawMessage, error) {
	result := &struct {
		Info json.RawMessage	`json:"qInfo"`
	} {}
	err := obj.rpc(ctx, "GetInfo", result)
	return result.Info, err 
}
1344926
func (m *Discriminator) ToRawInfo() interface{} {
	info := yaml.MapSlice{}
	if m == nil {
		return info
	}
	// always include this required field.
	info = append(info, yaml.MapItem{Key: "propertyName", Value: m.PropertyName})
	if m.Mapping != nil {
		info = append(info, yaml.MapItem{Key: "mapping", Value: m.Mapping.ToRawInfo()})
	}
	// &{Name:mapping Type:Strings StringEnumValues:[] MapType: Repeated:false Pattern: Implicit:false Description:}
	return info
}
796995
func (m *FileSchema) ToRawInfo() interface{} {
	info := yaml.MapSlice{}
	if m == nil {
		return info
	}
	if m.Format != "" {
		info = append(info, yaml.MapItem{Key: "format", Value: m.Format})
	}
	if m.Title != "" {
		info = append(info, yaml.MapItem{Key: "title", Value: m.Title})
	}
	if m.Description != "" {
		info = append(info, yaml.MapItem{Key: "description", Value: m.Description})
	}
	if m.Default != nil {
		info = append(info, yaml.MapItem{Key: "default", Value: m.Default.ToRawInfo()})
	}
	// &{Name:default Type:Any StringEnumValues:[] MapType: Repeated:false Pattern: Implicit:false Description:}
	if len(m.Required) != 0 {
		info = append(info, yaml.MapItem{Key: "required", Value: m.Required})
	}
	// always include this required field.
	info = append(info, yaml.MapItem{Key: "type", Value: m.Type})
	if m.ReadOnly != false {
		info = append(info, yaml.MapItem{Key: "readOnly", Value: m.ReadOnly})
	}
	if m.ExternalDocs != nil {
		info = append(info, yaml.MapItem{Key: "externalDocs", Value: m.ExternalDocs.ToRawInfo()})
	}
	// &{Name:externalDocs Type:ExternalDocs StringEnumValues:[] MapType: Repeated:false Pattern: Implicit:false Description:}
	if m.Example != nil {
		info = append(info, yaml.MapItem{Key: "example", Value: m.Example.ToRawInfo()})
	}
	// &{Name:example Type:Any StringEnumValues:[] MapType: Repeated:false Pattern: Implicit:false Description:}
	if m.VendorExtension != nil {
		for _, item := range m.VendorExtension {
			info = append(info, yaml.MapItem{Key: item.Name, Value: item.Value.ToRawInfo()})
		}
	}
	// &{Name:VendorExtension Type:NamedAny StringEnumValues:[] MapType:Any Repeated:true Pattern:^x- Implicit:true Description:}
	return info
}
465813
func (m *Example) ToRawInfo() interface{} {
	info := yaml.MapSlice{}
	if m == nil {
		return info
	}
	if m.Summary != "" {
		info = append(info, yaml.MapItem{Key: "summary", Value: m.Summary})
	}
	if m.Description != "" {
		info = append(info, yaml.MapItem{Key: "description", Value: m.Description})
	}
	// &{Name:value Type:Any StringEnumValues:[] MapType: Repeated:false Pattern: Implicit:false Description:}
	if m.ExternalValue != "" {
		info = append(info, yaml.MapItem{Key: "externalValue", Value: m.ExternalValue})
	}
	if m.SpecificationExtension != nil {
		for _, item := range m.SpecificationExtension {
			info = append(info, yaml.MapItem{Key: item.Name, Value: item.Value.ToRawInfo()})
		}
	}
	// &{Name:SpecificationExtension Type:NamedAny StringEnumValues:[] MapType:Any Repeated:true Pattern:^x- Implicit:true Description:}
	return info
}
231236
func (m *Any) ToRawInfo() interface{} {
	var err error
	var info1 []yaml.MapSlice
	err = yaml.Unmarshal([]byte(m.Yaml), &info1)
	if err == nil {
		return info1
	}
	var info2 yaml.MapSlice
	err = yaml.Unmarshal([]byte(m.Yaml), &info2)
	if err == nil {
		return info2
	}
	var info3 interface{}
	err = yaml.Unmarshal([]byte(m.Yaml), &info3)
	if err == nil {
		return info3
	}
	return nil
}
609575
func (m *Encoding) ToRawInfo() interface{} {
	info := yaml.MapSlice{}
	if m == nil {
		return info
	}
	if m.ContentType != "" {
		info = append(info, yaml.MapItem{Key: "contentType", Value: m.ContentType})
	}
	if m.Headers != nil {
		info = append(info, yaml.MapItem{Key: "headers", Value: m.Headers.ToRawInfo()})
	}
	// &{Name:headers Type:HeadersOrReferences StringEnumValues:[] MapType: Repeated:false Pattern: Implicit:false Description:}
	if m.Style != "" {
		info = append(info, yaml.MapItem{Key: "style", Value: m.Style})
	}
	if m.Explode != false {
		info = append(info, yaml.MapItem{Key: "explode", Value: m.Explode})
	}
	if m.AllowReserved != false {
		info = append(info, yaml.MapItem{Key: "allowReserved", Value: m.AllowReserved})
	}
	if m.SpecificationExtension != nil {
		for _, item := range m.SpecificationExtension {
			info = append(info, yaml.MapItem{Key: item.Name, Value: item.Value.ToRawInfo()})
		}
	}
	// &{Name:SpecificationExtension Type:NamedAny StringEnumValues:[] MapType:Any Repeated:true Pattern:^x- Implicit:true Description:}
	return info
}
539579
func (m *LinkOrReference) ToRawInfo() interface{} {
	// ONE OF WRAPPER
	// LinkOrReference
	// {Name:link Type:Link StringEnumValues:[] MapType: Repeated:false Pattern: Implicit:false Description:}
	v0 := m.GetLink()
	if v0 != nil {
		return v0.ToRawInfo()
	}
	// {Name:reference Type:Reference StringEnumValues:[] MapType: Repeated:false Pattern: Implicit:false Description:}
	v1 := m.GetReference()
	if v1 != nil {
		return v1.ToRawInfo()
	}
	return nil
}
794220
func (store FileStore) writeInfo(id string, info tusd.FileInfo) error {
	data, err := json.Marshal(info)
	if err != nil {
		return err
	}
	return ioutil.WriteFile(store.infoPath(id), data, defaultFilePerm)
}