24 lines
562 B
Go
24 lines
562 B
Go
package app
|
|
|
|
import "code.tnxs.net/taxnexus/lib/api/geo/geo_models"
|
|
|
|
// UnMarshalDomain decodes swagger to first class object
|
|
func UnMarshalDomain(swag *geo_models.Domain) *Domain {
|
|
return &Domain{
|
|
Description: swag.Description,
|
|
Active: swag.Active,
|
|
ID: swag.ID,
|
|
Name: swag.Name,
|
|
}
|
|
}
|
|
|
|
// MarshalToSwagger encodes first class object
|
|
func (obj *Domain) MarshalToSwagger() *geo_models.Domain {
|
|
return &geo_models.Domain{
|
|
ID: obj.ID,
|
|
Active: obj.Active,
|
|
Description: obj.Description,
|
|
Name: obj.Name,
|
|
}
|
|
}
|