text:
Automatically generated by Mendeley Desktop 1.19.8
Any changes to this file will be lost if it is regenerated by Mendeley.

BibTeX export options can be customized via Options -> BibTeX in Mendeley Desktop

@misc{Software:MolSysMT,
author = {Prada-Gracia, Diego and Moreno-Vargas, Liliana M.},
keywords = {molsysmt,software},
mendeley-tags = {molsysmt,software},
publisher = {GitHub},
title = {{MolSysMT}},
url = {https://github.com/uibcdf/MolSysMT},
year = {2020}
}
@book{Rapaport2004,
author = {Rapaport, D. C.},
doi = {10.1017/CBO9780511816581},
file = {:home/diego/MendeleyDesktop/Rapaport/2004/Rapaport - 2004 - The Art of Molecular Dynamics Simulation.pdf:pdf},
isbn = {9780521825689},
keywords = {book,dynamics,molecular,simulation},
mendeley-tags = {book,dynamics,molecular,simulation},
month = {apr},
publisher = {Cambridge University Press},
title = {{The Art of Molecular Dynamics Simulation}},
url = {https://www.cambridge.org/core/product/identifier/9780511816581/type/book},
year = {2004}
}
@article{Cournia2020,
abstract = {Virtual high throughput screening (vHTS) in drug discovery is a powerful approach to identify hits: when applied successfully, it can be much faster and cheaper than experimental high-throughput screening approaches. However, mainstream vHTS tools have significant limitations: ligand-based methods depend on knowledge of existing chemical matter, while structure-based tools such as docking involve significant approximations that limit their accuracy. Recent advances in scientific methods coupled with dramatic speedups in computational processing with GPUs make this an opportune time to consider the role of more rigorous methods that could improve the predictive power of vHTS workflows. In this Perspective, we assert that alchemical binding free energy methods using all-atom molecular dynamics simulations have matured to the point where they can be applied in virtual screening campaigns as a final scoring stage to prioritize the top molecules for experimental testing. Specifically, we propose that alchemical absolute binding free energy (ABFE) calculations offer the most direct and computationally efficient approach within a rigorous statistical thermodynamic framework for computing binding energies of diverse molecules, as is required for virtual screening. ABFE calculations are particularly attractive for drug discovery at this point in time, where the confluence of large-scale genomics data and insights from chemical biology have unveiled a large number of promising disease targets for which no small molecule binders are known, precluding ligand-based approaches, and where traditional docking approaches have foundered to find progressible chemical matter.},
author = {Cournia, Zoe and Allen, Bryce K. and Beuming, Thijs and Pearlman, David A. and Radak, Brian K. and Sherman, Woody},
doi = {10.1021/acs.jcim.0c00116},
file = {:home/diego/MendeleyDesktop/Cournia et al/2020/Cournia et al. - 2020 - Rigorous free energy simulations in virtual screening.pdf:pdf},
issn = {15205142},
journal = {J. Chem. Inf. Model.},
keywords = {absolute,alchemistry,binding,docking,energy,free,methods,mmgbsa,virtual screening},
mendeley-tags = {absolute,alchemistry,binding,docking,energy,free,methods,mmgbsa,virtual screening},
number = {9},
pages = {4153--4169},
pmid = {32539386},
title = {{Rigorous free energy simulations in virtual screening}},
volume = {60},
year = {2020}
}
@article{Prada-Gracia2009a,
abstract = {Knowledge of the Free Energy Landscape topology is the essential key to understanding many biochemical processes. The determination of the conformers of a protein and their basins of attraction takes a central role for studying molecular isomerization reactions. In this work, we present a novel framework to unveil the features of a Free Energy Landscape answering questions such as how many meta-stable conformers there are, what the hierarchical relationship among them is, or what the structure and kinetics of the transition paths are. Exploring the landscape by molecular dynamics simulations, the microscopic data of the trajectory are encoded into a Conformational Markov Network. The structure of this graph reveals the regions of the conformational space corresponding to the basins of attraction. In addition, handling the Conformational Markov Network, relevant kinetic magnitudes as dwell times and rate constants, or hierarchical relationships among basins, completes the global picture of the landscape. We show the power of the analysis studying a toy model of a funnel-like potential and computing efficiently the conformers of a short peptide, dialanine, paving the way to a systematic study of the Free Energy Landscape in large peptides.},
archivePrefix = {arXiv},
arxivId = {0905.2071},
author = {Prada-Gracia, Diego and G{\'{o}}mez-Garde{\~{n}}es, Jes{\'{u}}s and Echenique, Pablo and Falo, Fernando},
doi = {10.1371/journal.pcbi.1000415},
eprint = {0905.2071},
file = {:home/diego/MendeleyDesktop/Prada-Gracia et al/2009/Prada-Gracia et al. - 2009 - Exploring the free energy landscape From dynamics to networks and back(2).pdf:pdf},
isbn = {1553-7358},
issn = {1553734X},
journal = {PLoS Comput. Biol.},
number = {6},
pages = {1--22},
pmid = {19557191},
title = {{Exploring the free energy landscape: From dynamics to networks and back}},
volume = {5},
year = {2009}
}
@phdthesis{Duarte2018,
abstract = {Free energy calculations play an essential role in the study of physical transformations and chemical reactions. Within the universe of free energy calculation applications, solvation free energies (Gsolv) have a leading role: they are easy to calculate and have a broad scope of applications, from the study distribution coefficients between two phases to solubility prediction. This dissertation discusses some of the uses of Gsolv as a tool for method development, as a way to calculate infinite dilution activity coefficients, and as a part of an effort to predict solubilities of molecular solids. In chapters 2 and 3, I discuss the general features of solvation free energy calculations and their applications. We also introduced an update of FreeSolv, a hydration free energy database, and the use of infinite activity coefficient calculations (IDACs) as assisting tools (or potentially substitutes) of hydration free energies in force field parameterization and method development. Chapter 4 discusses the reproducibility of relative alchemical free energies (RAFE) across different software (AMBER, GROMACS, SOMD, CHARMM). We demonstrated that Ghyd can be reproduced to within about +0.2 kcal /mol and we highlighted the differences and particularities of each code. I was responsible for running the simulations and analyzing the results of the GROMACS code. Chapter 5 discusses an application of free energy calculations to the prediction of solubilities. I attempted to predict the solubility of acetylsalicylic acid (ASA) by calculating the absolute chemical potentials of the most stable polymorph of ASA and of solutions of different concentrations. Despite not finding a result that agreed with experimental error, I outlined the strengths and weaknesses of the method used and suggested improvements for future attempts. Main Content},
author = {{Duarte Ramos Matos}, G.},
booktitle = {UC Irvine},
file = {:home/diego/MendeleyDesktop/Duarte Ramos Matos/2018/Duarte Ramos Matos - 2018 - Free Energy Calculations in Action Theory, Applications and Challenges of Solvation Free Energies(2).pdf:pdf},
keywords = {energy,free,methods,solvation,thesis},
mendeley-tags = {energy,free,methods,solvation,thesis},
title = {{Free Energy Calculations in Action: Theory, Applications and Challenges of Solvation Free Energies}},
url = {https://escholarship.org/uc/item/1tr0c2p0{\#}main},
year = {2018}
}
@article{Eastman2017OpenMM,
abstract = {OpenMM is a molecular dynamics simulation toolkit with a unique focus on extensibility. It allows users to easily add new features, including forces with novel functional forms, new integration algorithms, and new simulation protocols. Those features automatically work on all supported hardware types (including both CPUs and GPUs) and perform well on all of them. In many cases they require minimal coding, just a mathematical description of the desired function. They also require no modification to OpenMM itself and can be distributed independently of OpenMM. This makes it an ideal tool for researchers developing new simulation methods, and also allows those new methods to be immediately available to the larger community.},
author = {Eastman, Peter and Swails, Jason and Chodera, John D. and McGibbon, Robert T. and Zhao, Yutong and Beauchamp, Kyle A. and Wang, Lee-Ping and Simmonett, Andrew C. and Harrigan, Matthew P. and Stern, Chaya D. and Wiewiora, Rafal P. and Brooks, Bernard R. and Pande, Vijay S.},
doi = {10.1371/journal.pcbi.1005659},
editor = {Gentleman, Robert},
file = {:home/diego/MendeleyDesktop/Eastman et al/2017/Eastman et al. - 2017 - OpenMM 7 Rapid development of high performance algorithms for molecular dynamics.pdf:pdf},
isbn = {1111111111},
issn = {1553-7358},
journal = {PLOS Comput. Biol.},
keywords = {dynamics,molecular,simulation,software},
mendeley-tags = {dynamics,molecular,simulation,software},
month = {jul},
number = {7},
pages = {e1005659},
pmid = {28746339},
title = {{OpenMM 7: Rapid development of high performance algorithms for molecular dynamics}},
url = {http://dx.plos.org/10.1371/journal.pcbi.1005659},
volume = {13},
year = {2017}
}
@phdthesis{Gill2020,
author = {Gill, Samuel},
file = {:home/diego/MendeleyDesktop/Gill/2020/Gill - 2020 - Enhanced sampling of ligand binding modes through BLUES and molecular darting.pdf:pdf},
keywords = {binding,energy,free,modes,thesis},
mendeley-tags = {binding,energy,free,modes,thesis},
school = {UC Irvine},
title = {{Enhanced sampling of ligand binding modes through BLUES and molecular darting}},
url = {https://escholarship.org/uc/item/1tr0c2p0},
year = {2020}
}
@book{Shclick2013,
abstract = {In this paper, the Turing instability in reaction-diffusion models defined on complex networks is studied. Here, we focus on three types of models which generate complex networks, i.e. the Erd$\backslash$H{\{}o{\}}s-R$\backslash$'enyi, the Watts-Strogatz and the threshold network models. From analysis of the Laplacian matrices of graphs generated by these models, we reveal that the stable-unstable regions of a spatially homogeneous solution completely differ, depending on network structures. In particular, we approximately argue the existence of the stable-unstable regions in the cases of regular enhanced ring lattices which include regular circles, and networks generated by the threshold network model when the number of vertices is large enough.},
address = {New York, NY},
author = {Schlick, Tamar},
booktitle = {Comput. Math. with Appl.},
doi = {10.1007/978-1-4419-6351-2},
file = {:home/diego/MendeleyDesktop/Schlick/2010/Schlick - 2010 - Molecular Modeling and Simulation An Interdisciplinary Guide.pdf:pdf},
isbn = {978-1-4419-6350-5},
issn = {08981221},
keywords = {05c82,1,2010 msc,35k57,60g05,60j60,70k50,92c15,92c40,Amplitude equation,Cortical folding,Cross diffusion,Ginzburg-Landau equation,Growing domain,Linearised stability,Morphology,Nonlinear diffusion,Pattern formation,Quintic Stuart-Landau equation,Reaction-diffusion system,Turing bifurcation,Turing system,activator,ams subject classifications,and another for inhibitor,and diffusion,approaches to the mathematical,based,book,clo,compartment-based models,complex network,cross-diffusion,cross-diffusion systems,deterministic models which are,diffusion models,diffusion system,dynamics,epstein,growing domain,holling type-ii functional response,i,instability,introduction,le,lengyel,model,modelling of chemical reactions,molecular,non-constant positive steady state,pattern,pattern formation,reaction,reaction-diffusion,reaction-diffusion models on networks,reaction-diffusion processes,reaction-diffusion systems,self-organised spatial pattern,simulation,stationary patterns,stochastic processes,stochastic simulations,stochastic turing patterns,systems,there are two fundamental,turing instability,turing pattern,turing reaction,turing system},
mendeley-tags = {book,dynamics,molecular,simulation},
month = {nov},
number = {9},
pages = {1627--1642},
pmid = {15267983},
publisher = {Springer New York},
series = {Interdisciplinary Applied Mathematics},
title = {{Molecular Modeling and Simulation: An Interdisciplinary Guide}},
url = {http://link.springer.com/10.1140/epjb/e2013-40570-8{\%}5Cnhttp://arxiv.org/abs/1406.6401{\%}5Cnhttp://arxiv.org/abs/1204.1475{\%}5Cnhttp://link.aps.org/doi/10.1103/PhysRevLett.91.058302{\%}5Cnhttp://arxiv.org/abs/nlin/0111059{\%}5Cnhttp://link.aps.org/doi/10.1103/PhysRe},
volume = {21},
year = {2010}
}
@misc{web:PDB,
file = {:home/diego/MendeleyDesktop/Berman et al/2000/Berman et al. - 2000 - The Protein Data Bank.pdf:pdf},
title = {{Protein Data Bank}},
url = {https://www.rcsb.org/}
}

branch_name: refs/heads/main


text:
// Copyright 2023 Google LLC. All Rights Reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
//     http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
package compute

import (
	"context"
	"fmt"
	"github.com/GoogleCloudPlatform/declarative-resource-client-library/dcl"
	dclService "github.com/GoogleCloudPlatform/declarative-resource-client-library/services/google/compute"
	"github.com/GoogleCloudPlatform/declarative-resource-client-library/services/google/iam"
	"github.com/GoogleCloudPlatform/declarative-resource-client-library/unstructured"
	iamUnstruct "github.com/GoogleCloudPlatform/declarative-resource-client-library/unstructured/google/iam"
)

type Instance struct{}

func InstanceToUnstructured(r *dclService.Instance) *unstructured.Resource {
	u := &unstructured.Resource{
		STV: unstructured.ServiceTypeVersion{
			Service: "compute",
			Version: "ga",
			Type:    "Instance",
		},
		Object: make(map[string]interface{}),
	}
	if r.CanIPForward != nil {
		u.Object["canIPForward"] = *r.CanIPForward
	}
	if r.CpuPlatform != nil {
		u.Object["cpuPlatform"] = *r.CpuPlatform
	}
	if r.CreationTimestamp != nil {
		u.Object["creationTimestamp"] = *r.CreationTimestamp
	}
	if r.DeletionProtection != nil {
		u.Object["deletionProtection"] = *r.DeletionProtection
	}
	if r.Description != nil {
		u.Object["description"] = *r.Description
	}
	var rDisks []interface{}
	for _, rDisksVal := range r.Disks {
		rDisksObject := make(map[string]interface{})
		if rDisksVal.AutoDelete != nil {
			rDisksObject["autoDelete"] = *rDisksVal.AutoDelete
		}
		if rDisksVal.Boot != nil {
			rDisksObject["boot"] = *rDisksVal.Boot
		}
		if rDisksVal.DeviceName != nil {
			rDisksObject["deviceName"] = *rDisksVal.DeviceName
		}
		if rDisksVal.DiskEncryptionKey != nil && rDisksVal.DiskEncryptionKey != dclService.EmptyInstanceDisksDiskEncryptionKey {
			rDisksValDiskEncryptionKey := make(map[string]interface{})
			if rDisksVal.DiskEncryptionKey.RawKey != nil {
				rDisksValDiskEncryptionKey["rawKey"] = *rDisksVal.DiskEncryptionKey.RawKey
			}
			if rDisksVal.DiskEncryptionKey.RsaEncryptedKey != nil {
				rDisksValDiskEncryptionKey["rsaEncryptedKey"] = *rDisksVal.DiskEncryptionKey.RsaEncryptedKey
			}
			if rDisksVal.DiskEncryptionKey.Sha256 != nil {
				rDisksValDiskEncryptionKey["sha256"] = *rDisksVal.DiskEncryptionKey.Sha256
			}
			rDisksObject["diskEncryptionKey"] = rDisksValDiskEncryptionKey
		}
		if rDisksVal.Index != nil {
			rDisksObject["index"] = *rDisksVal.Index
		}
		if rDisksVal.InitializeParams != nil && rDisksVal.InitializeParams != dclService.EmptyInstanceDisksInitializeParams {
			rDisksValInitializeParams := make(map[string]interface{})
			if rDisksVal.InitializeParams.DiskName != nil {
				rDisksValInitializeParams["diskName"] = *rDisksVal.InitializeParams.DiskName
			}
			if rDisksVal.InitializeParams.DiskSizeGb != nil {
				rDisksValInitializeParams["diskSizeGb"] = *rDisksVal.InitializeParams.DiskSizeGb
			}
			if rDisksVal.InitializeParams.DiskType != nil {
				rDisksValInitializeParams["diskType"] = *rDisksVal.InitializeParams.DiskType
			}
			if rDisksVal.InitializeParams.SourceImage != nil {
				rDisksValInitializeParams["sourceImage"] = *rDisksVal.InitializeParams.SourceImage
			}
			if rDisksVal.InitializeParams.SourceImageEncryptionKey != nil && rDisksVal.InitializeParams.SourceImageEncryptionKey != dclService.EmptyInstanceDisksInitializeParamsSourceImageEncryptionKey {
				rDisksValInitializeParamsSourceImageEncryptionKey := make(map[string]interface{})
				if rDisksVal.InitializeParams.SourceImageEncryptionKey.RawKey != nil {
					rDisksValInitializeParamsSourceImageEncryptionKey["rawKey"] = *rDisksVal.InitializeParams.SourceImageEncryptionKey.RawKey
				}
				if rDisksVal.InitializeParams.SourceImageEncryptionKey.Sha256 != nil {
					rDisksValInitializeParamsSourceImageEncryptionKey["sha256"] = *rDisksVal.InitializeParams.SourceImageEncryptionKey.Sha256
				}
				rDisksValInitializeParams["sourceImageEncryptionKey"] = rDisksValInitializeParamsSourceImageEncryptionKey
			}
			rDisksObject["initializeParams"] = rDisksValInitializeParams
		}
		if rDisksVal.Interface != nil {
			rDisksObject["interface"] = string(*rDisksVal.Interface)
		}
		if rDisksVal.Mode != nil {
			rDisksObject["mode"] = string(*rDisksVal.Mode)
		}
		if rDisksVal.Source != nil {
			rDisksObject["source"] = *rDisksVal.Source
		}
		if rDisksVal.Type != nil {
			rDisksObject["type"] = string(*rDisksVal.Type)
		}
		rDisks = append(rDisks, rDisksObject)
	}
	u.Object["disks"] = rDisks
	var rGuestAccelerators []interface{}
	for _, rGuestAcceleratorsVal := range r.GuestAccelerators {
		rGuestAcceleratorsObject := make(map[string]interface{})
		if rGuestAcceleratorsVal.AcceleratorCount != nil {
			rGuestAcceleratorsObject["acceleratorCount"] = *rGuestAcceleratorsVal.AcceleratorCount
		}
		if rGuestAcceleratorsVal.AcceleratorType != nil {
			rGuestAcceleratorsObject["acceleratorType"] = *rGuestAcceleratorsVal.AcceleratorType
		}
		rGuestAccelerators = append(rGuestAccelerators, rGuestAcceleratorsObject)
	}
	u.Object["guestAccelerators"] = rGuestAccelerators
	if r.Hostname != nil {
		u.Object["hostname"] = *r.Hostname
	}
	if r.Id != nil {
		u.Object["id"] = *r.Id
	}
	if r.Labels != nil {
		rLabels := make(map[string]interface{})
		for k, v := range r.Labels {
			rLabels[k] = v
		}
		u.Object["labels"] = rLabels
	}
	if r.MachineType != nil {
		u.Object["machineType"] = *r.MachineType
	}
	if r.Metadata != nil {
		rMetadata := make(map[string]interface{})
		for k, v := range r.Metadata {
			rMetadata[k] = v
		}
		u.Object["metadata"] = rMetadata
	}
	if r.MinCpuPlatform != nil {
		u.Object["minCpuPlatform"] = *r.MinCpuPlatform
	}
	if r.Name != nil {
		u.Object["name"] = *r.Name
	}
	var rNetworkInterfaces []interface{}
	for _, rNetworkInterfacesVal := range r.NetworkInterfaces {
		rNetworkInterfacesObject := make(map[string]interface{})
		var rNetworkInterfacesValAccessConfigs []interface{}
		for _, rNetworkInterfacesValAccessConfigsVal := range rNetworkInterfacesVal.AccessConfigs {
			rNetworkInterfacesValAccessConfigsObject := make(map[string]interface{})
			if rNetworkInterfacesValAccessConfigsVal.ExternalIPv6 != nil {
				rNetworkInterfacesValAccessConfigsObject["externalIPv6"] = *rNetworkInterfacesValAccessConfigsVal.ExternalIPv6
			}
			if rNetworkInterfacesValAccessConfigsVal.ExternalIPv6PrefixLength != nil {
				rNetworkInterfacesValAccessConfigsObject["externalIPv6PrefixLength"] = *rNetworkInterfacesValAccessConfigsVal.ExternalIPv6PrefixLength
			}
			if rNetworkInterfacesValAccessConfigsVal.Name != nil {
				rNetworkInterfacesValAccessConfigsObject["name"] = *rNetworkInterfacesValAccessConfigsVal.Name
			}
			if rNetworkInterfacesValAccessConfigsVal.NatIP != nil {
				rNetworkInterfacesValAccessConfigsObject["natIP"] = *rNetworkInterfacesValAccessConfigsVal.NatIP
			}
			if rNetworkInterfacesValAccessConfigsVal.NetworkTier != nil {
				rNetworkInterfacesValAccessConfigsObject["networkTier"] = string(*rNetworkInterfacesValAccessConfigsVal.NetworkTier)
			}
			if rNetworkInterfacesValAccessConfigsVal.PublicPtrDomainName != nil {
				rNetworkInterfacesValAccessConfigsObject["publicPtrDomainName"] = *rNetworkInterfacesValAccessConfigsVal.PublicPtrDomainName
			}
			if rNetworkInterfacesValAccessConfigsVal.SetPublicPtr != nil {
				rNetworkInterfacesValAccessConfigsObject["setPublicPtr"] = *rNetworkInterfacesValAccessConfigsVal.SetPublicPtr
			}
			if rNetworkInterfacesValAccessConfigsVal.Type != nil {
				rNetworkInterfacesValAccessConfigsObject["type"] = string(*rNetworkInterfacesValAccessConfigsVal.Type)
			}
			rNetworkInterfacesValAccessConfigs = append(rNetworkInterfacesValAccessConfigs, rNetworkInterfacesValAccessConfigsObject)
		}
		rNetworkInterfacesObject["accessConfigs"] = rNetworkInterfacesValAccessConfigs
		var rNetworkInterfacesValAliasIPRanges []interface{}
		for _, rNetworkInterfacesValAliasIPRangesVal := range rNetworkInterfacesVal.AliasIPRanges {
			rNetworkInterfacesValAliasIPRangesObject := make(map[string]interface{})
			if rNetworkInterfacesValAliasIPRangesVal.IPCidrRange != nil {
				rNetworkInterfacesValAliasIPRangesObject["ipCidrRange"] = *rNetworkInterfacesValAliasIPRangesVal.IPCidrRange
			}
			if rNetworkInterfacesValAliasIPRangesVal.SubnetworkRangeName != nil {
				rNetworkInterfacesValAliasIPRangesObject["subnetworkRangeName"] = *rNetworkInterfacesValAliasIPRangesVal.SubnetworkRangeName
			}
			rNetworkInterfacesValAliasIPRanges = append(rNetworkInterfacesValAliasIPRanges, rNetworkInterfacesValAliasIPRangesObject)
		}
		rNetworkInterfacesObject["aliasIPRanges"] = rNetworkInterfacesValAliasIPRanges
		var rNetworkInterfacesValIPv6AccessConfigs []interface{}
		for _, rNetworkInterfacesValIPv6AccessConfigsVal := range rNetworkInterfacesVal.IPv6AccessConfigs {
			rNetworkInterfacesValIPv6AccessConfigsObject := make(map[string]interface{})
			if rNetworkInterfacesValIPv6AccessConfigsVal.ExternalIPv6 != nil {
				rNetworkInterfacesValIPv6AccessConfigsObject["externalIPv6"] = *rNetworkInterfacesValIPv6AccessConfigsVal.ExternalIPv6
			}
			if rNetworkInterfacesValIPv6AccessConfigsVal.ExternalIPv6PrefixLength != nil {
				rNetworkInterfacesValIPv6AccessConfigsObject["externalIPv6PrefixLength"] = *rNetworkInterfacesValIPv6AccessConfigsVal.ExternalIPv6PrefixLength
			}
			if rNetworkInterfacesValIPv6AccessConfigsVal.Name != nil {
				rNetworkInterfacesValIPv6AccessConfigsObject["name"] = *rNetworkInterfacesValIPv6AccessConfigsVal.Name
			}
			if rNetworkInterfacesValIPv6AccessConfigsVal.NatIP != nil {
				rNetworkInterfacesValIPv6AccessConfigsObject["natIP"] = *rNetworkInterfacesValIPv6AccessConfigsVal.NatIP
			}
			if rNetworkInterfacesValIPv6AccessConfigsVal.NetworkTier != nil {
				rNetworkInterfacesValIPv6AccessConfigsObject["networkTier"] = string(*rNetworkInterfacesValIPv6AccessConfigsVal.NetworkTier)
			}
			if rNetworkInterfacesValIPv6AccessConfigsVal.PublicPtrDomainName != nil {
				rNetworkInterfacesValIPv6AccessConfigsObject["publicPtrDomainName"] = *rNetworkInterfacesValIPv6AccessConfigsVal.PublicPtrDomainName
			}
			if rNetworkInterfacesValIPv6AccessConfigsVal.SetPublicPtr != nil {
				rNetworkInterfacesValIPv6AccessConfigsObject["setPublicPtr"] = *rNetworkInterfacesValIPv6AccessConfigsVal.SetPublicPtr
			}
			if rNetworkInterfacesValIPv6AccessConfigsVal.Type != nil {
				rNetworkInterfacesValIPv6AccessConfigsObject["type"] = string(*rNetworkInterfacesValIPv6AccessConfigsVal.Type)
			}
			rNetworkInterfacesValIPv6AccessConfigs = append(rNetworkInterfacesValIPv6AccessConfigs, rNetworkInterfacesValIPv6AccessConfigsObject)
		}
		rNetworkInterfacesObject["ipv6AccessConfigs"] = rNetworkInterfacesValIPv6AccessConfigs
		if rNetworkInterfacesVal.Name != nil {
			rNetworkInterfacesObject["name"] = *rNetworkInterfacesVal.Name
		}
		if rNetworkInterfacesVal.Network != nil {
			rNetworkInterfacesObject["network"] = *rNetworkInterfacesVal.Network
		}
		if rNetworkInterfacesVal.NetworkIP != nil {
			rNetworkInterfacesObject["networkIP"] = *rNetworkInterfacesVal.NetworkIP
		}
		if rNetworkInterfacesVal.Subnetwork != nil {
			rNetworkInterfacesObject["subnetwork"] = *rNetworkInterfacesVal.Subnetwork
		}
		rNetworkInterfaces = append(rNetworkInterfaces, rNetworkInterfacesObject)
	}
	u.Object["networkInterfaces"] = rNetworkInterfaces
	if r.Project != nil {
		u.Object["project"] = *r.Project
	}
	if r.Scheduling != nil && r.Scheduling != dclService.EmptyInstanceScheduling {
		rScheduling := make(map[string]interface{})
		if r.Scheduling.AutomaticRestart != nil {
			rScheduling["automaticRestart"] = *r.Scheduling.AutomaticRestart
		}
		if r.Scheduling.OnHostMaintenance != nil {
			rScheduling["onHostMaintenance"] = *r.Scheduling.OnHostMaintenance
		}
		if r.Scheduling.Preemptible != nil {
			rScheduling["preemptible"] = *r.Scheduling.Preemptible
		}
		u.Object["scheduling"] = rScheduling
	}
	if r.SelfLink != nil {
		u.Object["selfLink"] = *r.SelfLink
	}
	var rServiceAccounts []interface{}
	for _, rServiceAccountsVal := range r.ServiceAccounts {
		rServiceAccountsObject := make(map[string]interface{})
		if rServiceAccountsVal.Email != nil {
			rServiceAccountsObject["email"] = *rServiceAccountsVal.Email
		}
		var rServiceAccountsValScopes []interface{}
		for _, rServiceAccountsValScopesVal := range rServiceAccountsVal.Scopes {
			rServiceAccountsValScopes = append(rServiceAccountsValScopes, rServiceAccountsValScopesVal)
		}
		rServiceAccountsObject["scopes"] = rServiceAccountsValScopes
		rServiceAccounts = append(rServiceAccounts, rServiceAccountsObject)
	}
	u.Object["serviceAccounts"] = rServiceAccounts
	if r.ShieldedInstanceConfig != nil && r.ShieldedInstanceConfig != dclService.EmptyInstanceShieldedInstanceConfig {
		rShieldedInstanceConfig := make(map[string]interface{})
		if r.ShieldedInstanceConfig.EnableIntegrityMonitoring != nil {
			rShieldedInstanceConfig["enableIntegrityMonitoring"] = *r.ShieldedInstanceConfig.EnableIntegrityMonitoring
		}
		if r.ShieldedInstanceConfig.EnableSecureBoot != nil {
			rShieldedInstanceConfig["enableSecureBoot"] = *r.ShieldedInstanceConfig.EnableSecureBoot
		}
		if r.ShieldedInstanceConfig.EnableVtpm != nil {
			rShieldedInstanceConfig["enableVtpm"] = *r.ShieldedInstanceConfig.EnableVtpm
		}
		u.Object["shieldedInstanceConfig"] = rShieldedInstanceConfig
	}
	if r.Status != nil {
		u.Object["status"] = string(*r.Status)
	}
	if r.StatusMessage != nil {
		u.Object["statusMessage"] = *r.StatusMessage
	}
	var rTags []interface{}
	for _, rTagsVal := range r.Tags {
		rTags = append(rTags, rTagsVal)
	}
	u.Object["tags"] = rTags
	if r.Zone != nil {
		u.Object["zone"] = *r.Zone
	}
	return u
}

func UnstructuredToInstance(u *unstructured.Resource) (*dclService.Instance, error) {
	r := &dclService.Instance{}
	if _, ok := u.Object["canIPForward"]; ok {
		if b, ok := u.Object["canIPForward"].(bool); ok {
			r.CanIPForward = dcl.Bool(b)
		} else {
			return nil, fmt.Errorf("r.CanIPForward: expected bool")
		}
	}
	if _, ok := u.Object["cpuPlatform"]; ok {
		if s, ok := u.Object["cpuPlatform"].(string); ok {
			r.CpuPlatform = dcl.String(s)
		} else {
			return nil, fmt.Errorf("r.CpuPlatform: expected string")
		}
	}
	if _, ok := u.Object["creationTimestamp"]; ok {
		if s, ok := u.Object["creationTimestamp"].(string); ok {
			r.CreationTimestamp = dcl.String(s)
		} else {
			return nil, fmt.Errorf("r.CreationTimestamp: expected string")
		}
	}
	if _, ok := u.Object["deletionProtection"]; ok {
		if b, ok := u.Object["deletionProtection"].(bool); ok {
			r.DeletionProtection = dcl.Bool(b)
		} else {
			return nil, fmt.Errorf("r.DeletionProtection: expected bool")
		}
	}
	if _, ok := u.Object["description"]; ok {
		if s, ok := u.Object["description"].(string); ok {
			r.Description = dcl.String(s)
		} else {
			return nil, fmt.Errorf("r.Description: expected string")
		}
	}
	if _, ok := u.Object["disks"]; ok {
		if s, ok := u.Object["disks"].([]interface{}); ok {
			for _, o := range s {
				if objval, ok := o.(map[string]interface{}); ok {
					var rDisks dclService.InstanceDisks
					if _, ok := objval["autoDelete"]; ok {
						if b, ok := objval["autoDelete"].(bool); ok {
							rDisks.AutoDelete = dcl.Bool(b)
						} else {
							return nil, fmt.Errorf("rDisks.AutoDelete: expected bool")
						}
					}
					if _, ok := objval["boot"]; ok {
						if b, ok := objval["boot"].(bool); ok {
							rDisks.Boot = dcl.Bool(b)
						} else {
							return nil, fmt.Errorf("rDisks.Boot: expected bool")
						}
					}
					if _, ok := objval["deviceName"]; ok {
						if s, ok := objval["deviceName"].(string); ok {
							rDisks.DeviceName = dcl.String(s)
						} else {
							return nil, fmt.Errorf("rDisks.DeviceName: expected string")
						}
					}
					if _, ok := objval["diskEncryptionKey"]; ok {
						if rDisksDiskEncryptionKey, ok := objval["diskEncryptionKey"].(map[string]interface{}); ok {
							rDisks.DiskEncryptionKey = &dclService.InstanceDisksDiskEncryptionKey{}
							if _, ok := rDisksDiskEncryptionKey["rawKey"]; ok {
								if s, ok := rDisksDiskEncryptionKey["rawKey"].(string); ok {
									rDisks.DiskEncryptionKey.RawKey = dcl.String(s)
								} else {
									return nil, fmt.Errorf("rDisks.DiskEncryptionKey.RawKey: expected string")
								}
							}
							if _, ok := rDisksDiskEncryptionKey["rsaEncryptedKey"]; ok {
								if s, ok := rDisksDiskEncryptionKey["rsaEncryptedKey"].(string); ok {
									rDisks.DiskEncryptionKey.RsaEncryptedKey = dcl.String(s)
								} else {
									return nil, fmt.Errorf("rDisks.DiskEncryptionKey.RsaEncryptedKey: expected string")
								}
							}
							if _, ok := rDisksDiskEncryptionKey["sha256"]; ok {
								if s, ok := rDisksDiskEncryptionKey["sha256"].(string); ok {
									rDisks.DiskEncryptionKey.Sha256 = dcl.String(s)
								} else {
									return nil, fmt.Errorf("rDisks.DiskEncryptionKey.Sha256: expected string")
								}
							}
						} else {
							return nil, fmt.Errorf("rDisks.DiskEncryptionKey: expected map[string]interface{}")
						}
					}
					if _, ok := objval["index"]; ok {
						if i, ok := objval["index"].(int64); ok {
							rDisks.Index = dcl.Int64(i)
						} else {
							return nil, fmt.Errorf("rDisks.Index: expected int64")
						}
					}
					if _, ok := objval["initializeParams"]; ok {
						if rDisksInitializeParams, ok := objval["initializeParams"].(map[string]interface{}); ok {
							rDisks.InitializeParams = &dclService.InstanceDisksInitializeParams{}
							if _, ok := rDisksInitializeParams["diskName"]; ok {
								if s, ok := rDisksInitializeParams["diskName"].(string); ok {
									rDisks.InitializeParams.DiskName = dcl.String(s)
								} else {
									return nil, fmt.Errorf("rDisks.InitializeParams.DiskName: expected string")
								}
							}
							if _, ok := rDisksInitializeParams["diskSizeGb"]; ok {
								if i, ok := rDisksInitializeParams["diskSizeGb"].(int64); ok {
									rDisks.InitializeParams.DiskSizeGb = dcl.Int64(i)
								} else {
									return nil, fmt.Errorf("rDisks.InitializeParams.DiskSizeGb: expected int64")
								}
							}
							if _, ok := rDisksInitializeParams["diskType"]; ok {
								if s, ok := rDisksInitializeParams["diskType"].(string); ok {
									rDisks.InitializeParams.DiskType = dcl.String(s)
								} else {
									return nil, fmt.Errorf("rDisks.InitializeParams.DiskType: expected string")
								}
							}
							if _, ok := rDisksInitializeParams["sourceImage"]; ok {
								if s, ok := rDisksInitializeParams["sourceImage"].(string); ok {
									rDisks.InitializeParams.SourceImage = dcl.String(s)
								} else {
									return nil, fmt.Errorf("rDisks.InitializeParams.SourceImage: expected string")
								}
							}
							if _, ok := rDisksInitializeParams["sourceImageEncryptionKey"]; ok {
								if rDisksInitializeParamsSourceImageEncryptionKey, ok := rDisksInitializeParams["sourceImageEncryptionKey"].(map[string]interface{}); ok {
									rDisks.InitializeParams.SourceImageEncryptionKey = &dclService.InstanceDisksInitializeParamsSourceImageEncryptionKey{}
									if _, ok := rDisksInitializeParamsSourceImageEncryptionKey["rawKey"]; ok {
										if s, ok := rDisksInitializeParamsSourceImageEncryptionKey["rawKey"].(string); ok {
											rDisks.InitializeParams.SourceImageEncryptionKey.RawKey = dcl.String(s)
										} else {
											return nil, fmt.Errorf("rDisks.InitializeParams.SourceImageEncryptionKey.RawKey: expected string")
										}
									}
									if _, ok := rDisksInitializeParamsSourceImageEncryptionKey["sha256"]; ok {
										if s, ok := rDisksInitializeParamsSourceImageEncryptionKey["sha256"].(string); ok {
											rDisks.InitializeParams.SourceImageEncryptionKey.Sha256 = dcl.String(s)
										} else {
											return nil, fmt.Errorf("rDisks.InitializeParams.SourceImageEncryptionKey.Sha256: expected string")
										}
									}
								} else {
									return nil, fmt.Errorf("rDisks.InitializeParams.SourceImageEncryptionKey: expected map[string]interface{}")
								}
							}
						} else {
							return nil, fmt.Errorf("rDisks.InitializeParams: expected map[string]interface{}")
						}
					}
					if _, ok := objval["interface"]; ok {
						if s, ok := objval["interface"].(string); ok {
							rDisks.Interface = dclService.InstanceDisksInterfaceEnumRef(s)
						} else {
							return nil, fmt.Errorf("rDisks.Interface: expected string")
						}
					}
					if _, ok := objval["mode"]; ok {
						if s, ok := objval["mode"].(string); ok {
							rDisks.Mode = dclService.InstanceDisksModeEnumRef(s)
						} else {
							return nil, fmt.Errorf("rDisks.Mode: expected string")
						}
					}
					if _, ok := objval["source"]; ok {
						if s, ok := objval["source"].(string); ok {
							rDisks.Source = dcl.String(s)
						} else {
							return nil, fmt.Errorf("rDisks.Source: expected string")
						}
					}
					if _, ok := objval["type"]; ok {
						if s, ok := objval["type"].(string); ok {
							rDisks.Type = dclService.InstanceDisksTypeEnumRef(s)
						} else {
							return nil, fmt.Errorf("rDisks.Type: expected string")
						}
					}
					r.Disks = append(r.Disks, rDisks)
				}
			}
		} else {
			return nil, fmt.Errorf("r.Disks: expected []interface{}")
		}
	}
	if _, ok := u.Object["guestAccelerators"]; ok {
		if s, ok := u.Object["guestAccelerators"].([]interface{}); ok {
			for _, o := range s {
				if objval, ok := o.(map[string]interface{}); ok {
					var rGuestAccelerators dclService.InstanceGuestAccelerators
					if _, ok := objval["acceleratorCount"]; ok {
						if i, ok := objval["acceleratorCount"].(int64); ok {
							rGuestAccelerators.AcceleratorCount = dcl.Int64(i)
						} else {
							return nil, fmt.Errorf("rGuestAccelerators.AcceleratorCount: expected int64")
						}
					}
					if _, ok := objval["acceleratorType"]; ok {
						if s, ok := objval["acceleratorType"].(string); ok {
							rGuestAccelerators.AcceleratorType = dcl.String(s)
						} else {
							return nil, fmt.Errorf("rGuestAccelerators.AcceleratorType: expected string")
						}
					}
					r.GuestAccelerators = append(r.GuestAccelerators, rGuestAccelerators)
				}
			}
		} else {
			return nil, fmt.Errorf("r.GuestAccelerators: expected []interface{}")
		}
	}
	if _, ok := u.Object["hostname"]; ok {
		if s, ok := u.Object["hostname"].(string); ok {
			r.Hostname = dcl.String(s)
		} else {
			return nil, fmt.Errorf("r.Hostname: expected string")
		}
	}
	if _, ok := u.Object["id"]; ok {
		if s, ok := u.Object["id"].(string); ok {
			r.Id = dcl.String(s)
		} else {
			return nil, fmt.Errorf("r.Id: expected string")
		}
	}
	if _, ok := u.Object["labels"]; ok {
		if rLabels, ok := u.Object["labels"].(map[string]interface{}); ok {
			m := make(map[string]string)
			for k, v := range rLabels {
				if s, ok := v.(string); ok {
					m[k] = s
				}
			}
			r.Labels = m
		} else {
			return nil, fmt.Errorf("r.Labels: expected map[string]interface{}")
		}
	}
	if _, ok := u.Object["machineType"]; ok {
		if s, ok := u.Object["machineType"].(string); ok {
			r.MachineType = dcl.String(s)
		} else {
			return nil, fmt.Errorf("r.MachineType: expected string")
		}
	}
	if _, ok := u.Object["metadata"]; ok {
		if rMetadata, ok := u.Object["metadata"].(map[string]interface{}); ok {
			m := make(map[string]string)
			for k, v := range rMetadata {
				if s, ok := v.(string); ok {
					m[k] = s
				}
			}
			r.Metadata = m
		} else {
			return nil, fmt.Errorf("r.Metadata: expected map[string]interface{}")
		}
	}
	if _, ok := u.Object["minCpuPlatform"]; ok {
		if s, ok := u.Object["minCpuPlatform"].(string); ok {
			r.MinCpuPlatform = dcl.String(s)
		} else {
			return nil, fmt.Errorf("r.MinCpuPlatform: expected string")
		}
	}
	if _, ok := u.Object["name"]; ok {
		if s, ok := u.Object["name"].(string); ok {
			r.Name = dcl.String(s)
		} else {
			return nil, fmt.Errorf("r.Name: expected string")
		}
	}
	if _, ok := u.Object["networkInterfaces"]; ok {
		if s, ok := u.Object["networkInterfaces"].([]interface{}); ok {
			for _, o := range s {
				if objval, ok := o.(map[string]interface{}); ok {
					var rNetworkInterfaces dclService.InstanceNetworkInterfaces
					if _, ok := objval["accessConfigs"]; ok {
						if s, ok := objval["accessConfigs"].([]interface{}); ok {
							for _, o := range s {
								if objval, ok := o.(map[string]interface{}); ok {
									var rNetworkInterfacesAccessConfigs dclService.InstanceNetworkInterfacesAccessConfigs
									if _, ok := objval["externalIPv6"]; ok {
										if s, ok := objval["externalIPv6"].(string); ok {
											rNetworkInterfacesAccessConfigs.ExternalIPv6 = dcl.String(s)
										} else {
											return nil, fmt.Errorf("rNetworkInterfacesAccessConfigs.ExternalIPv6: expected string")
										}
									}
									if _, ok := objval["externalIPv6PrefixLength"]; ok {
										if s, ok := objval["externalIPv6PrefixLength"].(string); ok {
											rNetworkInterfacesAccessConfigs.ExternalIPv6PrefixLength = dcl.String(s)
										} else {
											return nil, fmt.Errorf("rNetworkInterfacesAccessConfigs.ExternalIPv6PrefixLength: expected string")
										}
									}
									if _, ok := objval["name"]; ok {
										if s, ok := objval["name"].(string); ok {
											rNetworkInterfacesAccessConfigs.Name = dcl.String(s)
										} else {
											return nil, fmt.Errorf("rNetworkInterfacesAccessConfigs.Name: expected string")
										}
									}
									if _, ok := objval["natIP"]; ok {
										if s, ok := objval["natIP"].(string); ok {
											rNetworkInterfacesAccessConfigs.NatIP = dcl.String(s)
										} else {
											return nil, fmt.Errorf("rNetworkInterfacesAccessConfigs.NatIP: expected string")
										}
									}
									if _, ok := objval["networkTier"]; ok {
										if s, ok := objval["networkTier"].(string); ok {
											rNetworkInterfacesAccessConfigs.NetworkTier = dclService.InstanceNetworkInterfacesAccessConfigsNetworkTierEnumRef(s)
										} else {
											return nil, fmt.Errorf("rNetworkInterfacesAccessConfigs.NetworkTier: expected string")
										}
									}
									if _, ok := objval["publicPtrDomainName"]; ok {
										if s, ok := objval["publicPtrDomainName"].(string); ok {
											rNetworkInterfacesAccessConfigs.PublicPtrDomainName = dcl.String(s)
										} else {
											return nil, fmt.Errorf("rNetworkInterfacesAccessConfigs.PublicPtrDomainName: expected string")
										}
									}
									if _, ok := objval["setPublicPtr"]; ok {
										if b, ok := objval["setPublicPtr"].(bool); ok {
											rNetworkInterfacesAccessConfigs.SetPublicPtr = dcl.Bool(b)
										} else {
											return nil, fmt.Errorf("rNetworkInterfacesAccessConfigs.SetPublicPtr: expected bool")
										}
									}
									if _, ok := objval["type"]; ok {
										if s, ok := objval["type"].(string); ok {
											rNetworkInterfacesAccessConfigs.Type = dclService.InstanceNetworkInterfacesAccessConfigsTypeEnumRef(s)
										} else {
											return nil, fmt.Errorf("rNetworkInterfacesAccessConfigs.Type: expected string")
										}
									}
									rNetworkInterfaces.AccessConfigs = append(rNetworkInterfaces.AccessConfigs, rNetworkInterfacesAccessConfigs)
								}
							}
						} else {
							return nil, fmt.Errorf("rNetworkInterfaces.AccessConfigs: expected []interface{}")
						}
					}
					if _, ok := objval["aliasIPRanges"]; ok {
						if s, ok := objval["aliasIPRanges"].([]interface{}); ok {
							for _, o := range s {
								if objval, ok := o.(map[string]interface{}); ok {
									var rNetworkInterfacesAliasIPRanges dclService.InstanceNetworkInterfacesAliasIPRanges
									if _, ok := objval["ipCidrRange"]; ok {
										if s, ok := objval["ipCidrRange"].(string); ok {
											rNetworkInterfacesAliasIPRanges.IPCidrRange = dcl.String(s)
										} else {
											return nil, fmt.Errorf("rNetworkInterfacesAliasIPRanges.IPCidrRange: expected string")
										}
									}
									if _, ok := objval["subnetworkRangeName"]; ok {
										if s, ok := objval["subnetworkRangeName"].(string); ok {
											rNetworkInterfacesAliasIPRanges.SubnetworkRangeName = dcl.String(s)
										} else {
											return nil, fmt.Errorf("rNetworkInterfacesAliasIPRanges.SubnetworkRangeName: expected string")
										}
									}
									rNetworkInterfaces.AliasIPRanges = append(rNetworkInterfaces.AliasIPRanges, rNetworkInterfacesAliasIPRanges)
								}
							}
						} else {
							return nil, fmt.Errorf("rNetworkInterfaces.AliasIPRanges: expected []interface{}")
						}
					}
					if _, ok := objval["ipv6AccessConfigs"]; ok {
						if s, ok := objval["ipv6AccessConfigs"].([]interface{}); ok {
							for _, o := range s {
								if objval, ok := o.(map[string]interface{}); ok {
									var rNetworkInterfacesIPv6AccessConfigs dclService.InstanceNetworkInterfacesIPv6AccessConfigs
									if _, ok := objval["externalIPv6"]; ok {
										if s, ok := objval["externalIPv6"].(string); ok {
											rNetworkInterfacesIPv6AccessConfigs.ExternalIPv6 = dcl.String(s)
										} else {
											return nil, fmt.Errorf("rNetworkInterfacesIPv6AccessConfigs.ExternalIPv6: expected string")
										}
									}
									if _, ok := objval["externalIPv6PrefixLength"]; ok {
										if s, ok := objval["externalIPv6PrefixLength"].(string); ok {
											rNetworkInterfacesIPv6AccessConfigs.ExternalIPv6PrefixLength = dcl.String(s)
										} else {
											return nil, fmt.Errorf("rNetworkInterfacesIPv6AccessConfigs.ExternalIPv6PrefixLength: expected string")
										}
									}
									if _, ok := objval["name"]; ok {
										if s, ok := objval["name"].(string); ok {
											rNetworkInterfacesIPv6AccessConfigs.Name = dcl.String(s)
										} else {
											return nil, fmt.Errorf("rNetworkInterfacesIPv6AccessConfigs.Name: expected string")
										}
									}
									if _, ok := objval["natIP"]; ok {
										if s, ok := objval["natIP"].(string); ok {
											rNetworkInterfacesIPv6AccessConfigs.NatIP = dcl.String(s)
										} else {
											return nil, fmt.Errorf("rNetworkInterfacesIPv6AccessConfigs.NatIP: expected string")
										}
									}
									if _, ok := objval["networkTier"]; ok {
										if s, ok := objval["networkTier"].(string); ok {
											rNetworkInterfacesIPv6AccessConfigs.NetworkTier = dclService.InstanceNetworkInterfacesIPv6AccessConfigsNetworkTierEnumRef(s)
										} else {
											return nil, fmt.Errorf("rNetworkInterfacesIPv6AccessConfigs.NetworkTier: expected string")
										}
									}
									if _, ok := objval["publicPtrDomainName"]; ok {
										if s, ok := objval["publicPtrDomainName"].(string); ok {
											rNetworkInterfacesIPv6AccessConfigs.PublicPtrDomainName = dcl.String(s)
										} else {
											return nil, fmt.Errorf("rNetworkInterfacesIPv6AccessConfigs.PublicPtrDomainName: expected string")
										}
									}
									if _, ok := objval["setPublicPtr"]; ok {
										if b, ok := objval["setPublicPtr"].(bool); ok {
											rNetworkInterfacesIPv6AccessConfigs.SetPublicPtr = dcl.Bool(b)
										} else {
											return nil, fmt.Errorf("rNetworkInterfacesIPv6AccessConfigs.SetPublicPtr: expected bool")
										}
									}
									if _, ok := objval["type"]; ok {
										if s, ok := objval["type"].(string); ok {
											rNetworkInterfacesIPv6AccessConfigs.Type = dclService.InstanceNetworkInterfacesIPv6AccessConfigsTypeEnumRef(s)
										} else {
											return nil, fmt.Errorf("rNetworkInterfacesIPv6AccessConfigs.Type: expected string")
										}
									}
									rNetworkInterfaces.IPv6AccessConfigs = append(rNetworkInterfaces.IPv6AccessConfigs, rNetworkInterfacesIPv6AccessConfigs)
								}
							}
						} else {
							return nil, fmt.Errorf("rNetworkInterfaces.IPv6AccessConfigs: expected []interface{}")
						}
					}
					if _, ok := objval["name"]; ok {
						if s, ok := objval["name"].(string); ok {
							rNetworkInterfaces.Name = dcl.String(s)
						} else {
							return nil, fmt.Errorf("rNetworkInterfaces.Name: expected string")
						}
					}
					if _, ok := objval["network"]; ok {
						if s, ok := objval["network"].(string); ok {
							rNetworkInterfaces.Network = dcl.String(s)
						} else {
							return nil, fmt.Errorf("rNetworkInterfaces.Network: expected string")
						}
					}
					if _, ok := objval["networkIP"]; ok {
						if s, ok := objval["networkIP"].(string); ok {
							rNetworkInterfaces.NetworkIP = dcl.String(s)
						} else {
							return nil, fmt.Errorf("rNetworkInterfaces.NetworkIP: expected string")
						}
					}
					if _, ok := objval["subnetwork"]; ok {
						if s, ok := objval["subnetwork"].(string); ok {
							rNetworkInterfaces.Subnetwork = dcl.String(s)
						} else {
							return nil, fmt.Errorf("rNetworkInterfaces.Subnetwork: expected string")
						}
					}
					r.NetworkInterfaces = append(r.NetworkInterfaces, rNetworkInterfaces)
				}
			}
		} else {
			return nil, fmt.Errorf("r.NetworkInterfaces: expected []interface{}")
		}
	}
	if _, ok := u.Object["project"]; ok {
		if s, ok := u.Object["project"].(string); ok {
			r.Project = dcl.String(s)
		} else {
			return nil, fmt.Errorf("r.Project: expected string")
		}
	}
	if _, ok := u.Object["scheduling"]; ok {
		if rScheduling, ok := u.Object["scheduling"].(map[string]interface{}); ok {
			r.Scheduling = &dclService.InstanceScheduling{}
			if _, ok := rScheduling["automaticRestart"]; ok {
				if b, ok := rScheduling["automaticRestart"].(bool); ok {
					r.Scheduling.AutomaticRestart = dcl.Bool(b)
				} else {
					return nil, fmt.Errorf("r.Scheduling.AutomaticRestart: expected bool")
				}
			}
			if _, ok := rScheduling["onHostMaintenance"]; ok {
				if s, ok := rScheduling["onHostMaintenance"].(string); ok {
					r.Scheduling.OnHostMaintenance = dcl.String(s)
				} else {
					return nil, fmt.Errorf("r.Scheduling.OnHostMaintenance: expected string")
				}
			}
			if _, ok := rScheduling["preemptible"]; ok {
				if b, ok := rScheduling["preemptible"].(bool); ok {
					r.Scheduling.Preemptible = dcl.Bool(b)
				} else {
					return nil, fmt.Errorf("r.Scheduling.Preemptible: expected bool")
				}
			}
		} else {
			return nil, fmt.Errorf("r.Scheduling: expected map[string]interface{}")
		}
	}
	if _, ok := u.Object["selfLink"]; ok {
		if s, ok := u.Object["selfLink"].(string); ok {
			r.SelfLink = dcl.String(s)
		} else {
			return nil, fmt.Errorf("r.SelfLink: expected string")
		}
	}
	if _, ok := u.Object["serviceAccounts"]; ok {
		if s, ok := u.Object["serviceAccounts"].([]interface{}); ok {
			for _, o := range s {
				if objval, ok := o.(map[string]interface{}); ok {
					var rServiceAccounts dclService.InstanceServiceAccounts
					if _, ok := objval["email"]; ok {
						if s, ok := objval["email"].(string); ok {
							rServiceAccounts.Email = dcl.String(s)
						} else {
							return nil, fmt.Errorf("rServiceAccounts.Email: expected string")
						}
					}
					if _, ok := objval["scopes"]; ok {
						if s, ok := objval["scopes"].([]interface{}); ok {
							for _, ss := range s {
								if strval, ok := ss.(string); ok {
									rServiceAccounts.Scopes = append(rServiceAccounts.Scopes, strval)
								}
							}
						} else {
							return nil, fmt.Errorf("rServiceAccounts.Scopes: expected []interface{}")
						}
					}
					r.ServiceAccounts = append(r.ServiceAccounts, rServiceAccounts)
				}
			}
		} else {
			return nil, fmt.Errorf("r.ServiceAccounts: expected []interface{}")
		}
	}
	if _, ok := u.Object["shieldedInstanceConfig"]; ok {
		if rShieldedInstanceConfig, ok := u.Object["shieldedInstanceConfig"].(map[string]interface{}); ok {
			r.ShieldedInstanceConfig = &dclService.InstanceShieldedInstanceConfig{}
			if _, ok := rShieldedInstanceConfig["enableIntegrityMonitoring"]; ok {
				if b, ok := rShieldedInstanceConfig["enableIntegrityMonitoring"].(bool); ok {
					r.ShieldedInstanceConfig.EnableIntegrityMonitoring = dcl.Bool(b)
				} else {
					return nil, fmt.Errorf("r.ShieldedInstanceConfig.EnableIntegrityMonitoring: expected bool")
				}
			}
			if _, ok := rShieldedInstanceConfig["enableSecureBoot"]; ok {
				if b, ok := rShieldedInstanceConfig["enableSecureBoot"].(bool); ok {
					r.ShieldedInstanceConfig.EnableSecureBoot = dcl.Bool(b)
				} else {
					return nil, fmt.Errorf("r.ShieldedInstanceConfig.EnableSecureBoot: expected bool")
				}
			}
			if _, ok := rShieldedInstanceConfig["enableVtpm"]; ok {
				if b, ok := rShieldedInstanceConfig["enableVtpm"].(bool); ok {
					r.ShieldedInstanceConfig.EnableVtpm = dcl.Bool(b)
				} else {
					return nil, fmt.Errorf("r.ShieldedInstanceConfig.EnableVtpm: expected bool")
				}
			}
		} else {
			return nil, fmt.Errorf("r.ShieldedInstanceConfig: expected map[string]interface{}")
		}
	}
	if _, ok := u.Object["status"]; ok {
		if s, ok := u.Object["status"].(string); ok {
			r.Status = dclService.InstanceStatusEnumRef(s)
		} else {
			return nil, fmt.Errorf("r.Status: expected string")
		}
	}
	if _, ok := u.Object["statusMessage"]; ok {
		if s, ok := u.Object["statusMessage"].(string); ok {
			r.StatusMessage = dcl.String(s)
		} else {
			return nil, fmt.Errorf("r.StatusMessage: expected string")
		}
	}
	if _, ok := u.Object["tags"]; ok {
		if s, ok := u.Object["tags"].([]interface{}); ok {
			for _, ss := range s {
				if strval, ok := ss.(string); ok {
					r.Tags = append(r.Tags, strval)
				}
			}
		} else {
			return nil, fmt.Errorf("r.Tags: expected []interface{}")
		}
	}
	if _, ok := u.Object["zone"]; ok {
		if s, ok := u.Object["zone"].(string); ok {
			r.Zone = dcl.String(s)
		} else {
			return nil, fmt.Errorf("r.Zone: expected string")
		}
	}
	return r, nil
}

func GetInstance(ctx context.Context, config *dcl.Config, u *unstructured.Resource) (*unstructured.Resource, error) {
	c := dclService.NewClient(config)
	r, err := UnstructuredToInstance(u)
	if err != nil {
		return nil, err
	}
	r, err = c.GetInstance(ctx, r)
	if err != nil {
		return nil, err
	}
	return InstanceToUnstructured(r), nil
}

func ListInstance(ctx context.Context, config *dcl.Config, project string, zone string) ([]*unstructured.Resource, error) {
	c := dclService.NewClient(config)
	l, err := c.ListInstance(ctx, project, zone)
	if err != nil {
		return nil, err
	}
	var resources []*unstructured.Resource
	for {
		for _, r := range l.Items {
			resources = append(resources, InstanceToUnstructured(r))
		}
		if !l.HasNext() {
			break
		}
		if err := l.Next(ctx, c); err != nil {
			return nil, err
		}
	}
	return resources, nil
}

func ApplyInstance(ctx context.Context, config *dcl.Config, u *unstructured.Resource, opts ...dcl.ApplyOption) (*unstructured.Resource, error) {
	c := dclService.NewClient(config)
	r, err := UnstructuredToInstance(u)
	if err != nil {
		return nil, err
	}
	if ush := unstructured.FetchStateHint(opts); ush != nil {
		sh, err := UnstructuredToInstance(ush)
		if err != nil {
			return nil, err
		}
		opts = append(opts, dcl.WithStateHint(sh))
	}
	r, err = c.ApplyInstance(ctx, r, opts...)
	if err != nil {
		return nil, err
	}
	return InstanceToUnstructured(r), nil
}

func InstanceHasDiff(ctx context.Context, config *dcl.Config, u *unstructured.Resource, opts ...dcl.ApplyOption) (bool, error) {
	c := dclService.NewClient(config)
	r, err := UnstructuredToInstance(u)
	if err != nil {
		return false, err
	}
	if ush := unstructured.FetchStateHint(opts); ush != nil {
		sh, err := UnstructuredToInstance(ush)
		if err != nil {
			return false, err
		}
		opts = append(opts, dcl.WithStateHint(sh))
	}
	opts = append(opts, dcl.WithLifecycleParam(dcl.BlockDestruction), dcl.WithLifecycleParam(dcl.BlockCreation), dcl.WithLifecycleParam(dcl.BlockModification))
	_, err = c.ApplyInstance(ctx, r, opts...)
	if err != nil {
		if _, ok := err.(dcl.ApplyInfeasibleError); ok {
			return true, nil
		}
		return false, err
	}
	return false, nil
}

func DeleteInstance(ctx context.Context, config *dcl.Config, u *unstructured.Resource) error {
	c := dclService.NewClient(config)
	r, err := UnstructuredToInstance(u)
	if err != nil {
		return err
	}
	return c.DeleteInstance(ctx, r)
}

func InstanceID(u *unstructured.Resource) (string, error) {
	r, err := UnstructuredToInstance(u)
	if err != nil {
		return "", err
	}
	return r.ID()
}

func (r *Instance) STV() unstructured.ServiceTypeVersion {
	return unstructured.ServiceTypeVersion{
		"compute",
		"Instance",
		"ga",
	}
}

func SetPolicyInstance(ctx context.Context, config *dcl.Config, u *unstructured.Resource, p *unstructured.Resource) (*unstructured.Resource, error) {
	r, err := UnstructuredToInstance(u)
	if err != nil {
		return nil, err
	}
	policy, err := iamUnstruct.UnstructuredToPolicy(p)
	if err != nil {
		return nil, err
	}
	policy.Resource = r
	iamClient := iam.NewClient(config)
	newPolicy, err := iamClient.SetPolicy(ctx, policy)
	if err != nil {
		return nil, err
	}
	return iamUnstruct.PolicyToUnstructured(newPolicy), nil
}

func SetPolicyWithEtagInstance(ctx context.Context, config *dcl.Config, u *unstructured.Resource, p *unstructured.Resource) (*unstructured.Resource, error) {
	r, err := UnstructuredToInstance(u)
	if err != nil {
		return nil, err
	}
	policy, err := iamUnstruct.UnstructuredToPolicy(p)
	if err != nil {
		return nil, err
	}
	policy.Resource = r
	iamClient := iam.NewClient(config)
	newPolicy, err := iamClient.SetPolicyWithEtag(ctx, policy)
	if err != nil {
		return nil, err
	}
	return iamUnstruct.PolicyToUnstructured(newPolicy), nil
}

func GetPolicyInstance(ctx context.Context, config *dcl.Config, u *unstructured.Resource) (*unstructured.Resource, error) {
	r, err := UnstructuredToInstance(u)
	if err != nil {
		return nil, err
	}
	iamClient := iam.NewClient(config)
	policy, err := iamClient.GetPolicy(ctx, r)
	if err != nil {
		return nil, err
	}
	return iamUnstruct.PolicyToUnstructured(policy), nil
}

func SetPolicyMemberInstance(ctx context.Context, config *dcl.Config, u *unstructured.Resource, m *unstructured.Resource) (*unstructured.Resource, error) {
	r, err := UnstructuredToInstance(u)
	if err != nil {
		return nil, err
	}
	member, err := iamUnstruct.UnstructuredToMember(m)
	if err != nil {
		return nil, err
	}
	member.Resource = r
	iamClient := iam.NewClient(config)
	policy, err := iamClient.SetMember(ctx, member)
	if err != nil {
		return nil, err
	}
	return iamUnstruct.PolicyToUnstructured(policy), nil
}

func GetPolicyMemberInstance(ctx context.Context, config *dcl.Config, u *unstructured.Resource, role, member string) (*unstructured.Resource, error) {
	r, err := UnstructuredToInstance(u)
	if err != nil {
		return nil, err
	}
	iamClient := iam.NewClient(config)
	policyMember, err := iamClient.GetMember(ctx, r, role, member)
	if err != nil {
		return nil, err
	}
	return iamUnstruct.MemberToUnstructured(policyMember), nil
}

func DeletePolicyMemberInstance(ctx context.Context, config *dcl.Config, u *unstructured.Resource, m *unstructured.Resource) error {
	r, err := UnstructuredToInstance(u)
	if err != nil {
		return err
	}
	member, err := iamUnstruct.UnstructuredToMember(m)
	if err != nil {
		return err
	}
	member.Resource = r
	iamClient := iam.NewClient(config)
	if err := iamClient.DeleteMember(ctx, member); err != nil {
		return err
	}
	return nil
}

func (r *Instance) SetPolicyMember(ctx context.Context, config *dcl.Config, resource *unstructured.Resource, member *unstructured.Resource) (*unstructured.Resource, error) {
	return SetPolicyMemberInstance(ctx, config, resource, member)
}

func (r *Instance) GetPolicyMember(ctx context.Context, config *dcl.Config, resource *unstructured.Resource, role, member string) (*unstructured.Resource, error) {
	return GetPolicyMemberInstance(ctx, config, resource, role, member)
}

func (r *Instance) DeletePolicyMember(ctx context.Context, config *dcl.Config, resource *unstructured.Resource, member *unstructured.Resource) error {
	return DeletePolicyMemberInstance(ctx, config, resource, member)
}

func (r *Instance) SetPolicy(ctx context.Context, config *dcl.Config, resource *unstructured.Resource, policy *unstructured.Resource) (*unstructured.Resource, error) {
	return SetPolicyInstance(ctx, config, resource, policy)
}

func (r *Instance) SetPolicyWithEtag(ctx context.Context, config *dcl.Config, resource *unstructured.Resource, policy *unstructured.Resource) (*unstructured.Resource, error) {
	return SetPolicyWithEtagInstance(ctx, config, resource, policy)
}

func (r *Instance) GetPolicy(ctx context.Context, config *dcl.Config, resource *unstructured.Resource) (*unstructured.Resource, error) {
	return GetPolicyInstance(ctx, config, resource)
}

func (r *Instance) Get(ctx context.Context, config *dcl.Config, resource *unstructured.Resource) (*unstructured.Resource, error) {
	return GetInstance(ctx, config, resource)
}

func (r *Instance) Apply(ctx context.Context, config *dcl.Config, resource *unstructured.Resource, opts ...dcl.ApplyOption) (*unstructured.Resource, error) {
	return ApplyInstance(ctx, config, resource, opts...)
}

func (r *Instance) HasDiff(ctx context.Context, config *dcl.Config, resource *unstructured.Resource, opts ...dcl.ApplyOption) (bool, error) {
	return InstanceHasDiff(ctx, config, resource, opts...)
}

func (r *Instance) Delete(ctx context.Context, config *dcl.Config, resource *unstructured.Resource) error {
	return DeleteInstance(ctx, config, resource)
}

func (r *Instance) ID(resource *unstructured.Resource) (string, error) {
	return InstanceID(resource)
}

func init() {
	unstructured.Register(&Instance{})
}

license_type: permissive

gha_language: Go

extension: go


text:
package testutil

import (
	"math/rand"
	"net"
	"time"

	"github.com/chrisruffalo/gudgeon/util"
)

var tlds = []string{".com", ".org", ".net"}
var runes = []rune("abcdefghijklmnopqrstuvwxyz")

func init() {
	rand.Seed(time.Now().UnixNano())
}

func RandomDomain() string {
	domainLen := rand.Intn(10) + 5
	domain := make([]rune, domainLen)
	for idx := range domain {
		domain[idx] = runes[rand.Intn(len(runes))]
	}
	return string(domain) + tlds[rand.Intn(len(tlds))]
}

func ReverseIpString(ip string) string {
	ipObj := net.ParseIP(ip)
	return util.ReverseLookupDomain(&ipObj)
}

license: MIT

repository: ksharpdabu/gudgeon

repo_name: ksharpdabu/gudgeon

branch_name: refs/heads/master


text:
@article{asscheman2011long,
  title={Transgender Men Who Experienced Pregnancy After Female-to-Male Gender Transitioning.},
  author={Light, Alexis D and Obedin-Maliver, Juno and Sevelius, Jae M. and Kerns, Jennifer L},
  journal={Obstetrics & Gynecology},
  year={2014},
  doi={10.1530/EJE-10-1038},
  fulltext={http://journals.lww.com/greenjournal/Fulltext/publishahead/Transgender_Men_Who_Experienced_Pregnancy_After.99291.aspx},
  sample={41 Transgender Men},
  conclusion={"Transgender men are achieving pregnancy after having socially, medically, or both transitioned. Themes from this study can be used to develop transgender-appropriate services and interventions that may improve the health and health care experiences of transgender men."}
}

repository: transcience/paper-dex

repo_name: transcience/paper-dex

extension: bib


text:
// Copyright 2021 VMware, Inc. All Rights Reserved.
// SPDX-License-Identifier: Apache-2.0

// Package vc ...
package vc

import (
	"context"

	"github.com/vmware-tanzu-private/core/pkg/v1/tkg/tkgconfigreaderwriter"
	tkgtypes "github.com/vmware-tanzu-private/core/pkg/v1/tkg/types"
	"github.com/vmware-tanzu-private/core/pkg/v1/tkg/web/server/models"
)

// vCenter Managed Object Type Names
const (
	TypeCluster         = "ClusterComputeResource"
	TypeComputeResource = "ComputeResource"
	TypeHostGroup       = "HostGroup"
	TypeResourcePool    = "ResourcePool"
	TypeDatacenter      = "Datacenter"
	TypeFolder          = "Folder"
	TypeDatastore       = "Datastore"
	TypeHost            = "HostSystem"
	TypeNetwork         = "Network"
	TypeOpaqueNetwork   = "OpaqueNetwork"
	TypeVirtualMachine  = "VirtualMachine"
)

//go:generate counterfeiter -o ../fakes/vcclient.go --fake-name VCClient . Client

// Client represents a vCenter client
type Client interface {
	// Login authenticates with Virtual Center using user/password
	Login(ctx context.Context, user, password string) (string, error)

	// AcquireTicket acquires a new session ticket for the user associated with
	// the authenticated client.
	AcquireTicket() (string, error)

	// CheckUserSessionActive check if a user session is Active
	CheckUserSessionActive() (bool, error)

	// GetDatastores returns a list of datastores for the given datacenter
	GetDatastores(ctx context.Context, datacenterMOID string) ([]*models.VSphereDatastore, error)

	// GetDatacenters returns a list of all datacenters in the vSphere inventory.
	GetDatacenters(ctx context.Context) ([]*models.VSphereDatacenter, error)

	// GetDataCenterMOID returns the MOID of the datacenter
	GetDataCenterMOID(ctx context.Context, dcName string) (string, error)

	// GetNetworks returns list of network in the given datacenter
	GetNetworks(ctx context.Context, datacenterMOID string) ([]*models.VSphereNetwork, error)

	// GetResourcePools returns list of resource pools in the given datacenter
	GetResourcePools(ctx context.Context, datacenterMOID string) ([]*models.VSphereResourcePool, error)

	// GetVSphereVersion returns the vSphere version, and the build number
	GetVSphereVersion() (string, string, error)

	// GetVirtualMachine gets vms under given datacenter
	GetVirtualMachines(ctx context.Context, datacenterMOID string) ([]*models.VSphereVirtualMachine, error)

	// GetVirtualMachineImages gets vm templates for kubernetes
	GetVirtualMachineImages(ctx context.Context, datacenterMOID string) ([]*tkgtypes.VSphereVirtualMachine, error)

	// DetectPacific detects if project pacific is enabled on vSphere
	DetectPacific(ctx context.Context) (bool, error)

	// GetFolders gets all folders under a datacenter
	GetFolders(ctx context.Context, datacenterMOID string) ([]*models.VSphereFolder, error)

	// GetComputeResources gets resource pools and their ancestors
	GetComputeResources(ctx context.Context, datacenterMOID string) ([]*models.VSphereManagementObject, error)
	// FindResourcePool find the vSphere resource pool from path, return moid
	FindResourcePool(ctx context.Context, path, dcPath string) (string, error)
	// FindFolder find the vSphere folder from path, return moid
	FindFolder(ctx context.Context, path, dcPath string) (string, error)
	// FindVirtualMachine find the vSphere virtual machine from path, return moid
	FindVirtualMachine(ctx context.Context, path, dcPath string) (string, error)
	// FindDataCenter find the vSphere datacenter from path, return moid
	FindDataCenter(ctx context.Context, path string) (string, error)
	// FindDatastore find the vSphere datastore from path, return moid
	FindDatastore(ctx context.Context, path, dcPath string) (string, error)
	// GetAndValidateVirtualMachineTemplateForK8sVersion validates and returns valid virtual machine template
	GetAndValidateVirtualMachineTemplate(ovaVersions []string, tkrName string, templateName, dc string, tkgConfigReaderWriter tkgconfigreaderwriter.TKGConfigReaderWriter) (*tkgtypes.VSphereVirtualMachine, error)
}


text:
// Code generated by goa v3.12.4, DO NOT EDIT.
//
// api_key_service endpoints
//
// Command:
// $ goa gen goa.design/examples/security/hierarchy/design -o security/hierarchy

package apikeyservice

import (
	"context"

	goa "goa.design/goa/v3/pkg"
	"goa.design/goa/v3/security"
)

// Endpoints wraps the "api_key_service" service endpoints.
type Endpoints struct {
	Default  goa.Endpoint
	Secure   goa.Endpoint
	Unsecure goa.Endpoint
}

// NewEndpoints wraps the methods of the "api_key_service" service with
// endpoints.
func NewEndpoints(s Service) *Endpoints {
	// Casting service to Auther interface
	a := s.(Auther)
	return &Endpoints{
		Default:  NewDefaultEndpoint(s, a.APIKeyAuth),
		Secure:   NewSecureEndpoint(s, a.JWTAuth),
		Unsecure: NewUnsecureEndpoint(s),
	}
}

// Use applies the given middleware to all the "api_key_service" service
// endpoints.
func (e *Endpoints) Use(m func(goa.Endpoint) goa.Endpoint) {
	e.Default = m(e.Default)
	e.Secure = m(e.Secure)
	e.Unsecure = m(e.Unsecure)
}

// NewDefaultEndpoint returns an endpoint function that calls the method
// "default" of service "api_key_service".
func NewDefaultEndpoint(s Service, authAPIKeyFn security.AuthAPIKeyFunc) goa.Endpoint {
	return func(ctx context.Context, req any) (any, error) {
		p := req.(*DefaultPayload)
		var err error
		sc := security.APIKeyScheme{
			Name:           "api_key",
			Scopes:         []string{},
			RequiredScopes: []string{},
		}
		ctx, err = authAPIKeyFn(ctx, p.Key, &sc)
		if err != nil {
			return nil, err
		}
		return nil, s.Default(ctx, p)
	}
}

// NewSecureEndpoint returns an endpoint function that calls the method
// "secure" of service "api_key_service".
func NewSecureEndpoint(s Service, authJWTFn security.AuthJWTFunc) goa.Endpoint {
	return func(ctx context.Context, req any) (any, error) {
		p := req.(*SecurePayload)
		var err error
		sc := security.JWTScheme{
			Name:           "jwt",
			Scopes:         []string{},
			RequiredScopes: []string{},
		}
		ctx, err = authJWTFn(ctx, p.Token, &sc)
		if err != nil {
			return nil, err
		}
		return nil, s.Secure(ctx, p)
	}
}

// NewUnsecureEndpoint returns an endpoint function that calls the method
// "unsecure" of service "api_key_service".
func NewUnsecureEndpoint(s Service) goa.Endpoint {
	return func(ctx context.Context, req any) (any, error) {
		return nil, s.Unsecure(ctx)
	}
}

repository: goadesign/examples

repo_name: goadesign/examples

gha_license_id: MIT


text:
import {WeView} from '../confirm/src/weview.js';
import {ConfirmOptions} from "./src/confirm.js";
import {isArray, isString, deepAssign} from "../src/utils/util.js";

const Confirm = {

  WeView: WeView,

  install(Vue, {use = WeView, alias = "$confirm", options} = {use: WeView, alias: "$confirm"}) {
    deepAssign(ConfirmOptions, options);
    let alt = new use();

    let confirm = function (...opts) {
      return alt.open(opts);
    };
    confirm.open = function (...opts) {
      return alt.open(opts);
    };
    confirm.close = function (instance) {
      alt.close(instance);
    };
    confirm.closeAll = function () {
      alt.closeAll();
    };

    if (isString(alias)) {
      Vue.prototype[alias] = confirm;
    } else if (isArray(alias)) {
      for (let idx in alias) {
        Vue.prototype[alias[idx]] = confirm;
      }
    }
  }
};

export default Confirm;

extension: js


text:
inherit autotools

DEFAULT_PREFERENCE = "-1"

SECTION = "x11/games"
DESCRIPTION = "DGen/SDL is a Sega Genesis/Mega-drive emulator."
DEPENDS = "virtual/libsdl"
SRC_URI = "http://pknet.com/~joe/${PN}-${PV}.tar.gz \
	   file://fix-configure-and-make.patch;patch=1"

EXTRA_OECONF = " --disable-sdltest --without-x --without-opengl --without-nasm --without-mmx --without-star"

do_compile () {
	oe_runmake 'HOSTCC=${BUILD_CC}'
}

repository: jdegges/gumstix-pip-oe

repo_name: jdegges/gumstix-pip-oe


text:
SUMMARY = "Library for QtQuick apps with Material Design"
LICENSE = "MPLv2"
LIC_FILES_CHKSUM = " \
    file://LICENSE.MPL2;md5=815ca599c9df247a0c7f619bab123dad \
"

inherit liri gtk-icon-cache

PV = "1.2.0+git${SRCPV}"
SRCREV = "a99dc04a067abeb9110664f5427e9a701e6744d4"
S = "${WORKDIR}/git"

DEPENDS += " \
    qtgraphicaleffects \
    qtquickcontrols2 \
    qtsvg \
"

do_configure_prepend() {
    (cd ${S} && ./scripts/fetch_icons.sh)
}

# docs -> qdocs -> clang-native
EXTRA_OECMAKE += " \
    -DFLUID_WITH_DOCUMENTATION=OFF \
"

FILES_${PN} += " \
    ${OE_QMAKE_PATH_QML} \
"
FILES_${PN}-dev += " \
    ${datadir}/icons \
    ${datadir}/metainfo \
    ${OE_QMAKE_PATH_QT_ARCHDATA}/mkspecs \
"

RDEPENDS_${PN} += " \
    qtsvg-plugins \
"

branch_name: refs/heads/nilrt/master/hardknott

gha_language: BitBake

extension: bb