当前位置: 首页>>代码示例>>Golang>>正文


Golang queries.GetExecutor函数代码示例

本文整理汇总了Golang中github.com/vattle/sqlboiler/queries.GetExecutor函数的典型用法代码示例。如果您正苦于以下问题:Golang GetExecutor函数的具体用法?Golang GetExecutor怎么用?Golang GetExecutor使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了GetExecutor函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Golang代码示例。

示例1: All

// All returns all Tableinfo records from the query.
func (q tableinfoQuery) All() (TableinfoSlice, error) {
	var o TableinfoSlice

	err := q.Bind(&o)
	if err != nil {
		return nil, errors.Wrap(err, "chado: failed to assign all query results to Tableinfo slice")
	}

	if len(tableinfoAfterSelectHooks) != 0 {
		for _, obj := range o {
			if err := obj.doAfterSelectHooks(queries.GetExecutor(q.Query)); err != nil {
				return o, err
			}
		}
	}

	return o, nil
}
开发者ID:dictyBase,项目名称:Modware,代码行数:19,代码来源:tableinfo.go

示例2: All

// All returns all FeaturepropPub records from the query.
func (q featurepropPubQuery) All() (FeaturepropPubSlice, error) {
	var o FeaturepropPubSlice

	err := q.Bind(&o)
	if err != nil {
		return nil, errors.Wrap(err, "chado: failed to assign all query results to FeaturepropPub slice")
	}

	if len(featurepropPubAfterSelectHooks) != 0 {
		for _, obj := range o {
			if err := obj.doAfterSelectHooks(queries.GetExecutor(q.Query)); err != nil {
				return o, err
			}
		}
	}

	return o, nil
}
开发者ID:dictyBase,项目名称:Modware,代码行数:19,代码来源:featureprop_pub.go

示例3: All

// All returns all Download records from the query.
func (q downloadQuery) All() (DownloadSlice, error) {
	var o DownloadSlice

	err := q.Bind(&o)
	if err != nil {
		return nil, errors.Wrap(err, "models: failed to assign all query results to Download slice")
	}

	if len(downloadAfterSelectHooks) != 0 {
		for _, obj := range o {
			if err := obj.doAfterSelectHooks(queries.GetExecutor(q.Query)); err != nil {
				return o, err
			}
		}
	}

	return o, nil
}
开发者ID:zqzca,项目名称:back,代码行数:19,代码来源:downloads.go

示例4: All

// All returns all AuthUserRole records from the query.
func (q authUserRoleQuery) All() (AuthUserRoleSlice, error) {
	var o AuthUserRoleSlice

	err := q.Bind(&o)
	if err != nil {
		return nil, errors.Wrap(err, "chado: failed to assign all query results to AuthUserRole slice")
	}

	if len(authUserRoleAfterSelectHooks) != 0 {
		for _, obj := range o {
			if err := obj.doAfterSelectHooks(queries.GetExecutor(q.Query)); err != nil {
				return o, err
			}
		}
	}

	return o, nil
}
开发者ID:dictyBase,项目名称:Modware,代码行数:19,代码来源:auth_user_role.go

示例5: All

// All returns all CvtermDbxref records from the query.
func (q cvtermDbxrefQuery) All() (CvtermDbxrefSlice, error) {
	var o CvtermDbxrefSlice

	err := q.Bind(&o)
	if err != nil {
		return nil, errors.Wrap(err, "chado: failed to assign all query results to CvtermDbxref slice")
	}

	if len(cvtermDbxrefAfterSelectHooks) != 0 {
		for _, obj := range o {
			if err := obj.doAfterSelectHooks(queries.GetExecutor(q.Query)); err != nil {
				return o, err
			}
		}
	}

	return o, nil
}
开发者ID:dictyBase,项目名称:Modware,代码行数:19,代码来源:cvterm_dbxref.go

示例6: All

// All returns all Stockcollection records from the query.
func (q stockcollectionQuery) All() (StockcollectionSlice, error) {
	var o StockcollectionSlice

	err := q.Bind(&o)
	if err != nil {
		return nil, errors.Wrap(err, "chado: failed to assign all query results to Stockcollection slice")
	}

	if len(stockcollectionAfterSelectHooks) != 0 {
		for _, obj := range o {
			if err := obj.doAfterSelectHooks(queries.GetExecutor(q.Query)); err != nil {
				return o, err
			}
		}
	}

	return o, nil
}
开发者ID:dictyBase,项目名称:Modware,代码行数:19,代码来源:stockcollection.go

示例7: All

// All returns all PubRelationship records from the query.
func (q pubRelationshipQuery) All() (PubRelationshipSlice, error) {
	var o PubRelationshipSlice

	err := q.Bind(&o)
	if err != nil {
		return nil, errors.Wrap(err, "chado: failed to assign all query results to PubRelationship slice")
	}

	if len(pubRelationshipAfterSelectHooks) != 0 {
		for _, obj := range o {
			if err := obj.doAfterSelectHooks(queries.GetExecutor(q.Query)); err != nil {
				return o, err
			}
		}
	}

	return o, nil
}
开发者ID:dictyBase,项目名称:Modware,代码行数:19,代码来源:pub_relationship.go

示例8: All

// All returns all EnvironmentCvterm records from the query.
func (q environmentCvtermQuery) All() (EnvironmentCvtermSlice, error) {
	var o EnvironmentCvtermSlice

	err := q.Bind(&o)
	if err != nil {
		return nil, errors.Wrap(err, "chado: failed to assign all query results to EnvironmentCvterm slice")
	}

	if len(environmentCvtermAfterSelectHooks) != 0 {
		for _, obj := range o {
			if err := obj.doAfterSelectHooks(queries.GetExecutor(q.Query)); err != nil {
				return o, err
			}
		}
	}

	return o, nil
}
开发者ID:dictyBase,项目名称:Modware,代码行数:19,代码来源:environment_cvterm.go

示例9: All

// All returns all JbrowseOrganism records from the query.
func (q jbrowseOrganismQuery) All() (JbrowseOrganismSlice, error) {
	var o JbrowseOrganismSlice

	err := q.Bind(&o)
	if err != nil {
		return nil, errors.Wrap(err, "chado: failed to assign all query results to JbrowseOrganism slice")
	}

	if len(jbrowseOrganismAfterSelectHooks) != 0 {
		for _, obj := range o {
			if err := obj.doAfterSelectHooks(queries.GetExecutor(q.Query)); err != nil {
				return o, err
			}
		}
	}

	return o, nil
}
开发者ID:dictyBase,项目名称:Modware,代码行数:19,代码来源:jbrowse_organism.go

示例10: One

// One returns a single file record from the query.
func (q fileQuery) One() (*File, error) {
	o := &File{}

	queries.SetLimit(q.Query, 1)

	err := q.Bind(o)
	if err != nil {
		if errors.Cause(err) == sql.ErrNoRows {
			return nil, sql.ErrNoRows
		}
		return nil, errors.Wrap(err, "models: failed to execute a one query for files")
	}

	if err := o.doAfterSelectHooks(queries.GetExecutor(q.Query)); err != nil {
		return o, err
	}

	return o, nil
}
开发者ID:zqzca,项目名称:back,代码行数:20,代码来源:files.go

示例11: One

// One returns a single tableinfo record from the query.
func (q tableinfoQuery) One() (*Tableinfo, error) {
	o := &Tableinfo{}

	queries.SetLimit(q.Query, 1)

	err := q.Bind(o)
	if err != nil {
		if errors.Cause(err) == sql.ErrNoRows {
			return nil, sql.ErrNoRows
		}
		return nil, errors.Wrap(err, "chado: failed to execute a one query for tableinfo")
	}

	if err := o.doAfterSelectHooks(queries.GetExecutor(q.Query)); err != nil {
		return o, err
	}

	return o, nil
}
开发者ID:dictyBase,项目名称:Modware,代码行数:20,代码来源:tableinfo.go

示例12: One

// One returns a single authUserRole record from the query.
func (q authUserRoleQuery) One() (*AuthUserRole, error) {
	o := &AuthUserRole{}

	queries.SetLimit(q.Query, 1)

	err := q.Bind(o)
	if err != nil {
		if errors.Cause(err) == sql.ErrNoRows {
			return nil, sql.ErrNoRows
		}
		return nil, errors.Wrap(err, "chado: failed to execute a one query for auth_user_role")
	}

	if err := o.doAfterSelectHooks(queries.GetExecutor(q.Query)); err != nil {
		return o, err
	}

	return o, nil
}
开发者ID:dictyBase,项目名称:Modware,代码行数:20,代码来源:auth_user_role.go

示例13: One

// One returns a single cvtermDbxref record from the query.
func (q cvtermDbxrefQuery) One() (*CvtermDbxref, error) {
	o := &CvtermDbxref{}

	queries.SetLimit(q.Query, 1)

	err := q.Bind(o)
	if err != nil {
		if errors.Cause(err) == sql.ErrNoRows {
			return nil, sql.ErrNoRows
		}
		return nil, errors.Wrap(err, "chado: failed to execute a one query for cvterm_dbxref")
	}

	if err := o.doAfterSelectHooks(queries.GetExecutor(q.Query)); err != nil {
		return o, err
	}

	return o, nil
}
开发者ID:dictyBase,项目名称:Modware,代码行数:20,代码来源:cvterm_dbxref.go

示例14: One

// One returns a single featurepropPub record from the query.
func (q featurepropPubQuery) One() (*FeaturepropPub, error) {
	o := &FeaturepropPub{}

	queries.SetLimit(q.Query, 1)

	err := q.Bind(o)
	if err != nil {
		if errors.Cause(err) == sql.ErrNoRows {
			return nil, sql.ErrNoRows
		}
		return nil, errors.Wrap(err, "chado: failed to execute a one query for featureprop_pub")
	}

	if err := o.doAfterSelectHooks(queries.GetExecutor(q.Query)); err != nil {
		return o, err
	}

	return o, nil
}
开发者ID:dictyBase,项目名称:Modware,代码行数:20,代码来源:featureprop_pub.go

示例15: One

// One returns a single pubRelationship record from the query.
func (q pubRelationshipQuery) One() (*PubRelationship, error) {
	o := &PubRelationship{}

	queries.SetLimit(q.Query, 1)

	err := q.Bind(o)
	if err != nil {
		if errors.Cause(err) == sql.ErrNoRows {
			return nil, sql.ErrNoRows
		}
		return nil, errors.Wrap(err, "chado: failed to execute a one query for pub_relationship")
	}

	if err := o.doAfterSelectHooks(queries.GetExecutor(q.Query)); err != nil {
		return o, err
	}

	return o, nil
}
开发者ID:dictyBase,项目名称:Modware,代码行数:20,代码来源:pub_relationship.go


注:本文中的github.com/vattle/sqlboiler/queries.GetExecutor函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。