All Downloads are FREE. Search and download functionalities are using the official Maven repository.

golang.struct.ssp Maven / Gradle / Ivy

<%@ val cl: biz.lobachev.annette.data_dictionary.builder.rendering.golang.GoStruct %>
// Code generated by Data Dictionary Builder (c) Valery Lobachev (https://github.com/valerylobachev/data-dictionary-builder)

package ${cl.lastPkg}

#if (cl.imports.nonEmpty)import (
#for (imp <- cl.imports)
  "${imp}"
#end
)
#end

const (
  ${cl.entityName}TableName = "#if(cl.schemaName.isDefined)${cl.schemaName.get}.#end${cl.tableName}"
#for (c <- cl.constants)
  ${c.key} = "${c.value}"
#end
)


#for (comment <- cl.comments)
// ${comment}
#end
type ${cl.name} struct {
#for (member <- cl.members)
#for (comment <- member.comments)
    // ${comment}
#end
    ${member.name} ${member.datatype} `${member.tags}`
#end
}


#if(cl.isGorm)func (*${cl.name}) TableName() string {
	return ${cl.entityName}TableName
}
#end




© 2015 - 2024 Weber Informatics LLC | Privacy Policy