github.com/df-mc/dragonfly@v0.9.13/server/cmd/source.go (about) 1 package cmd 2 3 import "github.com/df-mc/dragonfly/server/world" 4 5 // Source represents a source of a command execution. Commands may limit the sources that can run them by 6 // implementing the Allower interface. 7 // Source implements Target. A Source must always be able to target itself. 8 type Source interface { 9 Target 10 // SendCommandOutput sends a command output to the source. The way the output is applied, depends on what 11 // kind of source it is. 12 // SendCommandOutput is called by a Command automatically after being run. 13 SendCommandOutput(o *Output) 14 // World returns the world that the Source is in. 15 World() *world.World 16 }