ppf

package
v0.0.0-...-121e11e Latest Latest
Warning

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

Go to latest
Published: Feb 14, 2024 License: GPL-3.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrInvalidMemberType = errors.New("invalid member type")

ErrInvalidMemberType is returned when the member type is invalid

Functions

This section is empty.

Types

type Member

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

Member represents a member of the film crew

func NewMember

func NewMember(name string, crewType MemberType, availability [][]time.Time) Member

NewMember creates a new member of the film crew given its name, type and availability

func ParseTimeTable

func ParseTimeTable(filePath string) (Member, error)

ParseTimeTable parses a time table into the data needed to create a crew member given its file path. filePath contains the filepath of the time table (a csv file). This function returns a Member object or an error if something goes wrong.

func (Member) GetAvailability

func (m Member) GetAvailability() [][]time.Time

GetAvailability returns the availability of the crew member

func (Member) GetCrewType

func (m Member) GetCrewType() MemberType

GetCrewType returns the type of the crew member

func (Member) GetName

func (m Member) GetName() string

GetName returns the name of the crew member

type MemberType

type MemberType int

MemberType represents the different kinds of crew members of the shooting plan

const (
	Actor MemberType = iota
	Crew
)

func MemberTypeFromString

func MemberTypeFromString(stringMemberType string) (MemberType, error)

MemberTypeFromString converts stringMemberType to a MemberType and returns an error if the string is invalid

type PlannedShot

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

PlannedShot represents a shot that is planned in the shooting plan

type ShootingPlan

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

ShootingPlan represents the shooting plan

type Shot

type Shot struct {
	EstimatedDuration time.Duration
	Cast              []Member
	Crew              []Member
	Setting           string
	Scene             string
	Id                string
	Details           string
}

Shot represents a shot in a the shooting plan

func NewShot

func NewShot(estimatedDuration time.Duration, cast []Member, crew []Member, setting, scene, id, details string) Shot

NewShot returns a new shot given its estimated duration, cast, crew, setting, scene, shot identifier and some details for that shot.

func ParseTechnicalGuide

func ParseTechnicalGuide(filePath string, members []Member) ([]Shot, error)

ParseTechnicalGuide parses a technical guide into the data needed to create a list of shots. Argument filePath contains the filepath of the technical guide (a csv file) and members is the list of Member objects that participate in those shots. This function returns a list containing the shots found on the file, or an error if something goes wrong.

Jump to

Keyboard shortcuts

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