blob: 5fb9256232a7f810aa113feeee2e86cca8576faf [file] [log] [blame]
// Copyright 2016 The Vanadium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
// This file was auto-generated by the vanadium vdl tool.
// Package: util
package util
import (
"v.io/v23/context"
"v.io/v23/i18n"
"v.io/v23/verror"
)
var _ = __VDLInit() // Must be first; see __VDLInit comments for details.
//////////////////////////////////////////////////
// Error definitions
var (
ErrFoundMultipleAppUserBlessings = verror.Register("v.io/v23/syncbase/util.FoundMultipleAppUserBlessings", verror.NoRetry, "{1:}{2:} found multiple app:user blessings for different apps or users: {3} and {4}")
ErrFoundMultipleUserBlessings = verror.Register("v.io/v23/syncbase/util.FoundMultipleUserBlessings", verror.NoRetry, "{1:}{2:} found multiple user blessings for different users: {3} and {4}")
ErrFoundNoConventionalBlessings = verror.Register("v.io/v23/syncbase/util.FoundNoConventionalBlessings", verror.NoRetry, "{1:}{2:} found no blessings matching app:user or user conventions")
)
// NewErrFoundMultipleAppUserBlessings returns an error with the ErrFoundMultipleAppUserBlessings ID.
func NewErrFoundMultipleAppUserBlessings(ctx *context.T, au1 string, au2 string) error {
return verror.New(ErrFoundMultipleAppUserBlessings, ctx, au1, au2)
}
// NewErrFoundMultipleUserBlessings returns an error with the ErrFoundMultipleUserBlessings ID.
func NewErrFoundMultipleUserBlessings(ctx *context.T, u1 string, u2 string) error {
return verror.New(ErrFoundMultipleUserBlessings, ctx, u1, u2)
}
// NewErrFoundNoConventionalBlessings returns an error with the ErrFoundNoConventionalBlessings ID.
func NewErrFoundNoConventionalBlessings(ctx *context.T) error {
return verror.New(ErrFoundNoConventionalBlessings, ctx)
}
var __VDLInitCalled bool
// __VDLInit performs vdl initialization. It is safe to call multiple times.
// If you have an init ordering issue, just insert the following line verbatim
// into your source files in this package, right after the "package foo" clause:
//
// var _ = __VDLInit()
//
// The purpose of this function is to ensure that vdl initialization occurs in
// the right order, and very early in the init sequence. In particular, vdl
// registration and package variable initialization needs to occur before
// functions like vdl.TypeOf will work properly.
//
// This function returns a dummy value, so that it can be used to initialize the
// first var in the file, to take advantage of Go's defined init order.
func __VDLInit() struct{} {
if __VDLInitCalled {
return struct{}{}
}
__VDLInitCalled = true
// Set error format strings.
i18n.Cat().SetWithBase(i18n.LangID("en"), i18n.MsgID(ErrFoundMultipleAppUserBlessings.ID), "{1:}{2:} found multiple app:user blessings for different apps or users: {3} and {4}")
i18n.Cat().SetWithBase(i18n.LangID("en"), i18n.MsgID(ErrFoundMultipleUserBlessings.ID), "{1:}{2:} found multiple user blessings for different users: {3} and {4}")
i18n.Cat().SetWithBase(i18n.LangID("en"), i18n.MsgID(ErrFoundNoConventionalBlessings.ID), "{1:}{2:} found no blessings matching app:user or user conventions")
return struct{}{}
}