func (o Origin) CoreCharmOrigin() corecharm.Origin {
	var track string
	if o.Track != nil {
		track = *o.Track
	}
	var branch string
	if o.Branch != nil {
		branch = *o.Branch
	}
	var channel *charm.Channel
	if o.Risk != "" {
		channel = &charm.Channel{
			Risk:   charm.Risk(o.Risk),
			Track:  track,
			Branch: branch,
		}
	}
	return corecharm.Origin{
		Source:   corecharm.Source(o.Source),
		Type:     o.Type,
		ID:       o.ID,
		Hash:     o.Hash,
		Revision: o.Revision,
		Channel:  channel,
		Platform: corecharm.Platform{
			Architecture: o.Architecture,
			OS:           o.OS,
			Series:       o.Series,
		},
		InstanceKey: o.InstanceKey,
	}
}
// CoreCharmOrigin is a help method to get a core version of this structure.
CoreCharmOrigin is a help method to get a core version of this structure.
// CoreCharmOrigin is a help method to get a core version of this structure .
func (o Origin) CoreCharmOrigin() corecharm.Origin {
	var track string
	if o.Track != nil {
		track = *o.Track
	}
	var branch string
	if o.Branch != nil {
		branch = *o.Branch
	}
	var channel *charm.Channel
	if o.Risk != "" {
		channel = &charm.Channel{
			Risk:   charm.Risk(o.Risk),
			Track:  track,
			Branch: branch,
		}
	}
	return corecharm.Origin{
		Source:   corecharm.Source(o.Source),
		Type:     o.Type,
		ID:       o.ID,
		Hash:     o.Hash,
		Revision: o.Revision,
		Channel:  channel,
		Platform: corecharm.Platform{
			Architecture: o.Architecture,
			OS:           o.OS,
			Series:       o.Series,
		},
		InstanceKey: o.InstanceKey,
	}
}
func ( o Origin ) CoreCharmOrigin ( ) corecharm . Origin { var track string if o . Track != nil { track = * o . Track } var branch string if o . Branch != nil { branch = * o . Branch } var channel * charm . Channel if o . Risk != " " { channel = & charm . Channel { Risk : charm . Risk ( o . Risk ) , Track : track , Branch : branch , } } return corecharm . Origin { Source : corecharm . Source ( o . Source ) , Type : o . Type , ID : o . ID , Hash : o . Hash , Revision : o . Revision , Channel : channel , Platform : corecharm . Platform { Architecture : o . Architecture , OS : o . OS , Series : o . Series , } , InstanceKey : o . InstanceKey , } }
CoreCharmOrigin is a help method to get a core version of this structure.
CoreCharmOrigin is a help method to get a core version of this structure .