github.com/ydb-platform/ydb-go-sdk/v3@v3.57.0/internal/stack/function_id.go (about)

     1  package stack
     2  
     3  type caller interface {
     4  	FunctionID() string
     5  }
     6  
     7  var _ caller = functionID("")
     8  
     9  type functionID string
    10  
    11  func (id functionID) FunctionID() string {
    12  	return string(id)
    13  }
    14  
    15  func FunctionID(id string) caller {
    16  	if id != "" {
    17  		return functionID(id)
    18  	}
    19  
    20  	return Call(1)
    21  }