generator

command
v1.1.2 Latest Latest
Warning

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

Go to latest
Published: Feb 12, 2025 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Overview

The Generator package provides a way to generate code for collecting, transfering and saving resources in the agent and api. It also provides functions to fetc the resources.

go run build/generator/main.go

The package updates the files:

  • internal/controllers/resourcescontroller/resources_controller_read_generated.go
  • internal/apiservices/resourcesService/resourceServices_generated.go
  • internal/models/rorResources/extractResource.go
  • internal/mongodbrepo/repositories/resourcesmongodbrepo/resourcesinsertupdate_generated.go

The input of the package is the []rordefs.ApiResource provided by the "github.com/NorskHelsenett/ror/pkg/rorresources/rordefs" package rordefs in the variable Resources

If new structs are added to the resources, add new structs in the pkg/apicontracts/apiresourcecontracts/* files

TODO: Provide docslink

Jump to

Keyboard shortcuts

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