func Wait(objectType reflect.Type) (object interface{}) {
	if objectType == nil {
		panic("nil objectType")
	}
	resultCh := make(chan cmd_wait_result)
	commandChannel <- cmd_wait{
		objectType: objectType,
		resultCh:   resultCh,
	}
	result := <-resultCh
	return result.object
}
Wait until an object of the specified type appears in the environment.

If the environment already contains the object,
this function returns immediately.

This function never returns nil.
package env
import "reflect"
func Publish(object interface{}) (PublishedObject, error) {
	if object == nil {
		panic("nil object")
	}
	resultCh := make(chan cmd_publish_result)
	commandChannel <- cmd_publish{
		name_orEmpty: "",
		object:       object,
		resultCh:     resultCh,
	}
	result := <-resultCh
	return result.pub, result.err
}
type PublishedObject interface {
	Remove()
}
func PublishName(name string, object interface{}) (PublishedObject, error) {
	if name == "" {
		panic("empty name")
	}
	if object == nil {
		panic("nil object")
	}
	resultCh := make(chan cmd_publish_result)
	commandChannel <- cmd_publish{
		name_orEmpty: name,
		object:       object,
		resultCh:     resultCh,
	}
	result := <-resultCh
	return result.pub, result.err
}
func Find(objectType reflect.Type) (object_orNil interface{}) {
	if objectType == nil {
		panic("nil objectType")
	}
	resultCh := make(chan cmd_find_result)
	commandChannel <- cmd_find{
		objectType: objectType,
		resultCh:   resultCh,
	}
	result := <-resultCh
	return result.object_orNil
}
func FindName(name string) (object_orNil interface{}) {
	if name == "" {
		panic("empty name")
	}
	resultCh := make(chan cmd_find_result)
	commandChannel <- cmd_findName{
		name:     name,
		resultCh: resultCh,
	}
	result := <-resultCh
	return result.object_orNil
}