structure

package
v0.0.0-...-2d8c99f Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 21, 2022 License: MIT Imports: 0 Imported by: 0

Documentation

Overview

DO NOT EDIT THIS FILE. File generated by constructor. https://github.com/bannzai/constructor

Index

Constants

View Source
const TagKeyword = "constructor"
View Source
const TemplateFileName = "constructor.tpl"

Variables

View Source
var ReservedWords = []string{
	"break",
	"default",
	"func",
	"interface",
	"select",
	"case",
	"defer",
	"go",
	"map",
	"struct",
	"chan",
	"else",
	"goto",
	"package",
	"switch",
	"const",
	"fallthrough",
	"if",
	"range",
	"type",
	"continue",
	"for",
	"import",
	"return",
	"var",
}

ReservedWords reference from: https://golang.ir/ref/spec#Keywords

Functions

This section is empty.

Types

type Code

type Code struct {
	FilePath Path
	Structs  []Struct
}

Code is presentation of .go file content.

func NewCodeStructure

func NewCodeStructure(
	filePath Path,
	structs []Struct,
) Code

NewCodeStructure insitanciate Code

type Field

type Field struct {
	Name string
	Type string
}

func NewFieldStructure

func NewFieldStructure(
	name string,
	_type string,
) Field

NewFieldStructure insitanciate Field

type Path

type Path = string

Path for file path

type Struct

type Struct struct {
	Name   string
	Fields []Field
}

func NewStructStructure

func NewStructStructure(
	fields []Field,
	name string,
) Struct

NewStructStructure insitanciate Struct

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL