ambulance_wl

package
v0.0.0-...-7a122a6 Latest Latest
Warning

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

Go to latest
Published: Mar 26, 2024 License: MIT Imports: 6 Imported by: 0

README

Go API Server for ambulance_wl

Ambulance Waiting List management for Web-In-Cloud system

Overview

This server was generated by the [openapi-generator] (https://openapi-generator.tech) project. By using the OpenAPI-Spec from a remote server, you can easily generate a server stub.

To see how to make this your own, look here:

README

  • API version: 1.0.0
  • Build date: 2024-03-26T10:31:35.948623967Z[Etc/UTC]
  • Generator version: 7.5.0-SNAPSHOT
Running the server

To run the server, follow these simple steps:

go run main.go

To run the server in a docker container

docker build --network=host -t ambulance_wl .

Once the image is built, just run

docker run --rm -it ambulance_wl
Known Issue

Endpoints sharing a common path may result in issues. For example, /v2/pet/findByTags and /v2/pet/:petId will result in an issue with the Gin framework. For more information about this known limitation, please refer to gin-gonic/gin#388 for more information.

A workaround is to manually update the path and handler. Please refer to gin-gonic/gin/issues/205#issuecomment-296155497 for more information.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddRoutes

func AddRoutes(engine *gin.Engine)

Types

type Ambulance

type Ambulance struct {

	// Unique identifier of the ambulance
	Id string `json:"id"`

	// Human readable display name of the ambulance
	Name string `json:"name"`

	RoomNumber string `json:"roomNumber"`

	WaitingList []WaitingListEntry `json:"waitingList,omitempty"`

	PredefinedConditions []Condition `json:"predefinedConditions,omitempty"`
}

type AmbulanceConditionsAPI

type AmbulanceConditionsAPI interface {

	// GetConditions - Provides the list of conditions associated with ambulance
	GetConditions(ctx *gin.Context)
	// contains filtered or unexported methods
}

type AmbulanceWaitingListAPI

type AmbulanceWaitingListAPI interface {

	// CreateWaitingListEntry - Saves new entry into waiting list
	CreateWaitingListEntry(ctx *gin.Context)

	// DeleteWaitingListEntry - Deletes specific entry
	DeleteWaitingListEntry(ctx *gin.Context)

	// GetWaitingListEntries - Provides the ambulance waiting list
	GetWaitingListEntries(ctx *gin.Context)

	// GetWaitingListEntry - Provides details about waiting list entry
	GetWaitingListEntry(ctx *gin.Context)

	// UpdateWaitingListEntry - Updates specific entry
	UpdateWaitingListEntry(ctx *gin.Context)
	// contains filtered or unexported methods
}

type AmbulancesAPI

type AmbulancesAPI interface {

	// CreateAmbulance - Saves new ambulance definition
	CreateAmbulance(ctx *gin.Context)

	// DeleteAmbulance - Deletes specific ambulance
	DeleteAmbulance(ctx *gin.Context)
	// contains filtered or unexported methods
}

type Condition

type Condition struct {
	Value string `json:"value"`

	Code string `json:"code,omitempty"`

	// Link to encyclopedical explanation of the patient's condition
	Reference string `json:"reference,omitempty"`

	TypicalDurationMinutes int32 `json:"typicalDurationMinutes,omitempty"`
}

Condition - Describes disease, symptoms, or other reasons of patient visit

type WaitingListEntry

type WaitingListEntry struct {

	// Unique id of the entry in this waiting list
	Id string `json:"id"`

	// Name of patient in waiting list
	Name string `json:"name,omitempty"`

	// Unique identifier of the patient known to Web-In-Cloud system
	PatientId string `json:"patientId"`

	// Timestamp since when the patient entered the waiting list
	WaitingSince time.Time `json:"waitingSince"`

	// Estimated time of entering ambulance. Ignored on post.
	EstimatedStart time.Time `json:"estimatedStart,omitempty"`

	// Estimated duration of ambulance visit. If not provided then it will be computed based on condition and ambulance settings
	EstimatedDurationMinutes int32 `json:"estimatedDurationMinutes"`

	Condition Condition `json:"condition,omitempty"`
}

Jump to

Keyboard shortcuts

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