Documentation ¶
Index ¶
- func AddBuiltinPackages(s *symbols.SymbolTable)
- func Eval(symbols *symbols.SymbolTable, args []interface{}) (interface{}, error)
- func FormatSymbols(s *symbols.SymbolTable, args []interface{}) (interface{}, error)
- func GetDeclaration(fname string) *data.FunctionDeclaration
- func InitProfileDefaults() error
- func Pad(v interface{}, w int) string
- func Prompt(symbols *symbols.SymbolTable, args []interface{}) (interface{}, error)
- func ReadConsoleText(prompt string) string
- func SymbolTables(s *symbols.SymbolTable, args []interface{}) (interface{}, error)
- func TypeCompiler(t string) *data.Type
- type URLString
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddBuiltinPackages ¶
func AddBuiltinPackages(s *symbols.SymbolTable)
AddBuiltinPackages adds in the pre-defined package receivers for things like the table and rest systems.
func Eval ¶
func Eval(symbols *symbols.SymbolTable, args []interface{}) (interface{}, error)
Eval implements the eval() function which accepts a string representation of an expression and returns the expression result. This can also be used to convert string expressions of structs or arrays.
func FormatSymbols ¶
func FormatSymbols(s *symbols.SymbolTable, args []interface{}) (interface{}, error)
FormatSymbols implements the util.symbols() function. We skip over the current symbol table, which was created just for this function call and will always be empty.
func GetDeclaration ¶
func GetDeclaration(fname string) *data.FunctionDeclaration
func InitProfileDefaults ¶
func InitProfileDefaults() error
func Pad ¶
Pad the formatted value of a given object to the specified number of characters. Negative numbers are right-aligned, positive numbers are left-aligned.
func Prompt ¶
func Prompt(symbols *symbols.SymbolTable, args []interface{}) (interface{}, error)
Prompt implements the prompt() function, which uses the console reader.
func ReadConsoleText ¶
ReadConsoleText reads a line of text from the user's console.
func SymbolTables ¶
func SymbolTables(s *symbols.SymbolTable, args []interface{}) (interface{}, error)
func TypeCompiler ¶
Types ¶
type URLString ¶
type URLString struct {
// contains filtered or unexported fields
}
The object that knows how to semantically add values to a URL to forma a valid string. Note that this does not have to be a valid complete URL, but may consist of just the path and parameters.
func URLBuilder ¶
func URLBuilder(initialParts ...interface{}) *URLString
URLBuilder creates a new instance of a URLBuilder, and optionally populates it with the arguments provided. The parts are treated as a path name and optional path arguments. If no initial parts are provided in the call, then the URLString starts as an empty string.
func (*URLString) Parameter ¶
Parameter adds a parameter to the URL being constructed. The name string contains the parameter name. This is added to the URL being built. The arguments are optional additional arguments which follow the parameter value if specified.
func (*URLString) Path ¶
Path adds path eleemnts to the URL being constructed. The format string contains the literal text, and can contain standard Go format operators like %s or %d. The array of parts items is read to fill in the format operators in the format string. Any remaining items in the parts array are treated as URL parameter values to add to the URL.