fieldbuilder

package
v0.0.0-...-eec0033 Latest Latest
Warning

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

Go to latest
Published: Mar 15, 2023 License: MIT Imports: 2 Imported by: 0

Documentation

Overview

Package fieldbuilder converts astorg types into digium busy lamp fields.

This package is experimental and is subject to breaking changes.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Builder

type Builder struct {
	// contains filtered or unexported fields
}

Builder constructs a slice of digium busy lamp field entries.

An empty field builder is ready for use.

func (*Builder) Add

func (builder *Builder) Add(fields ...digium.Field) (next int)

Add adds custom busy lamp field entries to the builder.

func (*Builder) AddPerson

func (builder *Builder) AddPerson(location string, index int, people ...astorg.Person) (next int)

AddPerson adds a busy lamp field entry for each person to the builder, starting at index. It returns the next index.

func (*Builder) AddPhoneRole

func (builder *Builder) AddPhoneRole(location string, index int, roles ...astorg.PhoneRole) (next int)

AddPhoneRole adds a busy lamp field entry for each phone role to the builder, starting at index. It returns the next index.

func (*Builder) Fields

func (builder *Builder) Fields() digium.FieldList

Fields returns a compiled field list from the builder.

func (*Builder) Reset

func (builder *Builder) Reset()

Reset purges the current field list from the builder.

Jump to

Keyboard shortcuts

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