subgraph

package
v0.0.0-...-beab806 Latest Latest
Warning

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

Go to latest
Published: Jan 10, 2025 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Employees = []*model.Employee{
	{
		Details: &model.Details{
			Forename: "Jens",
			Location: &model.Country{
				Key: &model.CountryKey{
					Name: "Germany",
				},
			},
			PastLocations: []*model.City{
				&model.City{
					Type: "city",
					Name: "Ohio",
					Country: &model.Country{
						Key: &model.CountryKey{
							Name: "America",
						},
					},
				},
				&model.City{
					Type: "city",
					Name: "London",
					Country: &model.Country{
						Key: &model.CountryKey{
							Name: "England",
						},
					},
				},
			},
			Surname: "Neuse",
		},
		ID: 1,
		Role: model.Engineer{
			Departments:  []model.Department{model.DepartmentEngineering, model.DepartmentMarketing},
			EngineerType: model.EngineerTypeBackend,
			Title:        []string{"Founder", "CEO"},
		},
		Notes:     strPtr("Jens notes resolved by employees"),
		StartDate: "January 2020",
		UpdatedAt: "2021-09-01T00:00:00Z",
	},
	{
		Details: &model.Details{
			Forename: "Dustin",
			Location: &model.Country{
				Key: &model.CountryKey{
					Name: "Germany",
				},
			},
			PastLocations: []*model.City{
				&model.City{
					Type: "city",
					Name: "Ohio",
					Country: &model.Country{
						Key: &model.CountryKey{
							Name: "America",
						},
					},
				},
				&model.City{
					Type: "city",
					Name: "London",
					Country: &model.Country{
						Key: &model.CountryKey{
							Name: "England",
						},
					},
				},
			},
			Surname: "Deus",
		},
		ID: 2,
		Role: model.Engineer{
			Departments:  []model.Department{model.DepartmentEngineering},
			EngineerType: model.EngineerTypeFullstack,
			Title:        []string{"Co-founder", "Tech Lead"},
		},
		Notes:     strPtr("Dustin notes resolved by employees"),
		StartDate: "July 2022",
		UpdatedAt: "2021-09-01T00:00:00Z",
	},
	{
		Details: &model.Details{
			Forename: "Stefan",
			Location: &model.Country{
				Key: &model.CountryKey{
					Name: "America",
				},
			},
			PastLocations: []*model.City{
				&model.City{
					Type: "city",
					Name: "Ohio",
					Country: &model.Country{
						Key: &model.CountryKey{
							Name: "America",
						},
					},
				},
				&model.City{
					Type: "city",
					Name: "London",
					Country: &model.Country{
						Key: &model.CountryKey{
							Name: "England",
						},
					},
				},
			},
			Surname: "Avram",
		},
		ID: 3,
		Role: model.Marketer{
			Departments: []model.Department{model.DepartmentMarketing},
			Title:       []string{"Co-founder", "Head of Growth"},
		},
		Notes:     strPtr("Stefan notes resolved by employees"),
		StartDate: "June 2021",
		UpdatedAt: "2021-09-01T00:00:00Z",
	},
	{
		Details: &model.Details{
			Forename: "Björn",
			Location: &model.Country{
				Key: &model.CountryKey{
					Name: "Germany",
				},
			},
			PastLocations: []*model.City{
				&model.City{
					Type: "city",
					Name: "Ohio",
					Country: &model.Country{
						Key: &model.CountryKey{
							Name: "America",
						},
					},
				},
				&model.City{
					Type: "city",
					Name: "London",
					Country: &model.Country{
						Key: &model.CountryKey{
							Name: "England",
						},
					},
				},
			},
			Surname: "Schwenzer",
		},
		ID: 4,
		Role: model.Operator{
			Departments: []model.Department{model.DepartmentOperations, model.DepartmentMarketing},
			OperatorType: []model.OperationType{
				model.OperationTypeHumanResources, model.OperationTypeFinance,
			},
			Title: []string{"Co-founder", "COO"},
		},
		Notes:     strPtr("Björn notes resolved by employees"),
		StartDate: "July 2022",
		UpdatedAt: "2021-09-01T00:00:00Z",
	},
	{
		ID: 5,
		Details: &model.Details{
			Forename: "Sergiy",
			Location: &model.Country{
				Key: &model.CountryKey{
					Name: "Ukraine",
				},
			},
			PastLocations: []*model.City{
				&model.City{
					Type: "city",
					Name: "Ohio",
					Country: &model.Country{
						Key: &model.CountryKey{
							Name: "America",
						},
					},
				},
				&model.City{
					Type: "city",
					Name: "London",
					Country: &model.Country{
						Key: &model.CountryKey{
							Name: "England",
						},
					},
				},
			},
			Surname: "Petrunin",
		},
		Role: model.Engineer{
			Departments:  []model.Department{model.DepartmentEngineering},
			EngineerType: model.EngineerTypeBackend,
			Title:        []string{"Senior GO Engineer"},
		},
		Notes:     strPtr("Serigy notes resolved by employees"),
		StartDate: "July 2022",
		UpdatedAt: "2021-09-01T00:00:00Z",
	},
	{
		Details: &model.Details{
			Forename: "Suvij",
			Location: &model.Country{
				Key: &model.CountryKey{
					Name: "India",
				},
			},
			PastLocations: []*model.City{
				&model.City{
					Type: "city",
					Name: "Ohio",
					Country: &model.Country{
						Key: &model.CountryKey{
							Name: "America",
						},
					},
				},
				&model.City{
					Type: "city",
					Name: "London",
					Country: &model.Country{
						Key: &model.CountryKey{
							Name: "England",
						},
					},
				},
			},
			Surname: "Surya",
		},
		ID: 7,
		Role: model.Engineer{
			Departments:  []model.Department{model.DepartmentEngineering},
			EngineerType: model.EngineerTypeFullstack,
			Title:        []string{"Software Engineer"},
		},
		Notes:     strPtr("Suvij notes resolved by employees"),
		StartDate: "September 2022",
		UpdatedAt: "2021-09-01T00:00:00Z",
	},
	{
		Details: &model.Details{
			Forename: "Nithin",
			Location: &model.Country{
				Key: &model.CountryKey{
					Name: "India",
				},
			},
			PastLocations: []*model.City{
				&model.City{
					Type: "city",
					Name: "Ohio",
					Country: &model.Country{
						Key: &model.CountryKey{
							Name: "America",
						},
					},
				},
				&model.City{
					Type: "city",
					Name: "London",
					Country: &model.Country{
						Key: &model.CountryKey{
							Name: "England",
						},
					},
				},
			},
			Surname: "Kumar",
		},
		ID: 8,
		Role: model.Engineer{
			Departments:  []model.Department{model.DepartmentEngineering},
			EngineerType: model.EngineerTypeFullstack,
			Title:        []string{"Software Engineer"},
		},
		Notes:     strPtr("Nithin notes resolved by employees"),
		StartDate: "September 2022",
		UpdatedAt: "2021-09-01T00:00:00Z",
	},
	{
		Details: &model.Details{
			Forename: "Eelco",
			Location: &model.Country{
				Key: &model.CountryKey{
					Name: "Netherlands",
				},
			},
			PastLocations: []*model.City{
				&model.City{
					Type: "city",
					Name: "Ohio",
					Country: &model.Country{
						Key: &model.CountryKey{
							Name: "America",
						},
					},
				},
				&model.City{
					Type: "city",
					Name: "London",
					Country: &model.Country{
						Key: &model.CountryKey{
							Name: "England",
						},
					},
				},
			},
			Surname: "Wiersma",
		},
		ID: 10,
		Role: model.Engineer{
			Departments:  []model.Department{model.DepartmentEngineering},
			EngineerType: model.EngineerTypeFrontend,
			Title:        []string{"Senior Frontend Engineer"},
		},
		Notes:     strPtr("Eelco notes resolved by employees"),
		StartDate: "November 2022",
		UpdatedAt: "2021-09-01T00:00:00Z",
	},
	{
		Details: &model.Details{
			Forename: "Alexandra",
			Location: &model.Country{
				Key: &model.CountryKey{
					Name: "Germany",
				},
			},
			PastLocations: []*model.City{
				&model.City{
					Type: "city",
					Name: "Ohio",
					Country: &model.Country{
						Key: &model.CountryKey{
							Name: "America",
						},
					},
				},
				&model.City{
					Type: "city",
					Name: "London",
					Country: &model.Country{
						Key: &model.CountryKey{
							Name: "England",
						},
					},
				},
			},
			Surname: "Neuse",
		},
		ID: 11,
		Role: model.Operator{
			Departments: []model.Department{model.DepartmentOperations},
			OperatorType: []model.OperationType{
				model.OperationTypeFinance,
			},
			Title: []string{"Accounting & Finance"},
		},
		Notes:     strPtr("Alexandra notes resolved by employees"),
		StartDate: "November 2022",
		UpdatedAt: "2021-09-01T00:00:00Z",
	},
	{
		Details: &model.Details{
			Forename: "David",
			Location: &model.Country{
				Key: &model.CountryKey{
					Name: "England",
				},
			},
			PastLocations: []*model.City{
				&model.City{
					Type: "city",
					Name: "Ohio",
					Country: &model.Country{
						Key: &model.CountryKey{
							Name: "America",
						},
					},
				},
				&model.City{
					Type: "city",
					Name: "London",
					Country: &model.Country{
						Key: &model.CountryKey{
							Name: "England",
						},
					},
				},
			},
			Surname: "Stutt",
		},
		ID: 12,
		Role: model.Engineer{
			Departments:  []model.Department{model.DepartmentEngineering},
			EngineerType: model.EngineerTypeFullstack,
			Title:        []string{"Software Engineer"},
		},
		Notes:     strPtr("David notes resolved by employees"),
		StartDate: "December 2022",
		UpdatedAt: "2021-09-01T00:00:00Z",
	},
}
View Source
var TestOptions = EndpointOptions{
	EnableDebug: false,
}

Functions

func GraphQLEndpointHandler

func GraphQLEndpointHandler(opts EndpointOptions) http.Handler

Types

type EndpointOptions

type EndpointOptions struct {
	EnableDebug bool
}

type Resolver

type Resolver struct {
	NatsPubSubByProviderID map[string]pubsub_datasource.NatsPubSub
	EmployeesData          []*model.Employee
	// contains filtered or unexported fields
}

func (*Resolver) Employee

func (r *Resolver) Employee() generated.EmployeeResolver

Employee returns generated.EmployeeResolver implementation.

func (*Resolver) Employees

func (r *Resolver) Employees(ctx context.Context, obj model.RoleType) ([]*model.Employee, error)

func (*Resolver) Engineer

func (r *Resolver) Engineer() generated.EngineerResolver

Engineer returns generated.EngineerResolver implementation.

func (*Resolver) Entity

func (r *Resolver) Entity() generated.EntityResolver

Entity returns generated.EntityResolver implementation.

func (*Resolver) ErrorWrapper

func (r *Resolver) ErrorWrapper() generated.ErrorWrapperResolver

ErrorWrapper returns generated.ErrorWrapperResolver implementation.

func (*Resolver) Marketer

func (r *Resolver) Marketer() generated.MarketerResolver

Marketer returns generated.MarketerResolver implementation.

func (*Resolver) Mutation

func (r *Resolver) Mutation() generated.MutationResolver

Mutation returns generated.MutationResolver implementation.

func (*Resolver) Operator

func (r *Resolver) Operator() generated.OperatorResolver

Operator returns generated.OperatorResolver implementation.

func (*Resolver) Query

func (r *Resolver) Query() generated.QueryResolver

Query returns generated.QueryResolver implementation.

func (*Resolver) Subscription

func (r *Resolver) Subscription() generated.SubscriptionResolver

Subscription returns generated.SubscriptionResolver implementation.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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