Documentation ¶
Index ¶
- Constants
- Variables
- func EnvIndexFunction(L *lua.LState) int
- func FixPath(L *lua.LState) int
- func GoLuaTypeToCLuaType(t lua.LValueType) (int, string)
- func Hook(L *lua.LState) int
- func Loader(L *lua.LState) int
- func LuaError(L *lua.LState, msg string) int
- func ParsePathParts(file string, paths []string) []string
- func Preload(L *lua.LState)
- func TcpConnect(L *lua.LState) int
- type Ar
- type BreakPoint
- type Debugger
- func (d *Debugger) AddBreakPoint(bp *BreakPoint)
- func (d *Debugger) Attach(L *lua.LState)
- func (d *Debugger) CreateEnv(stackLevel int) (*lua.LTable, bool)
- func (d *Debugger) DoAction(action proto.DebugAction)
- func (d *Debugger) DoEval(evalContext *EvalContext) bool
- func (d *Debugger) EnterDebugMode(L *lua.LState)
- func (d *Debugger) Eval(ctx *EvalContext)
- func (d *Debugger) ExitDebugMode()
- func (d *Debugger) FindBreakPoint(L *lua.LState, ar *Ar) *BreakPoint
- func (d *Debugger) FindBreakPointByFile(file string, line int) *BreakPoint
- func (d *Debugger) GetFile(L *lua.LState, ar *Ar) string
- func (d *Debugger) GetStackLevel(L *lua.LState, skipGo bool) int
- func (d *Debugger) GetStacks(L *lua.LState) []*Stack
- func (d *Debugger) GetVariable(name string, value lua.LValue, depth int) *Variable
- func (d *Debugger) HandleBreak(L *lua.LState)
- func (d *Debugger) Hook(L *lua.LState, ar *Ar)
- func (d *Debugger) MatchFileName(chunkName string, fileName string) bool
- func (d *Debugger) RefreshLineSet()
- func (d *Debugger) RemoveAllBreakpoints()
- func (d *Debugger) RemoveBreakPoint(file string, line int)
- func (d *Debugger) SetHookState(L *lua.LState, newState HookStateInter)
- func (d *Debugger) Start(code string)
- func (d *Debugger) UpdateHook(L *lua.LState, mask string)
- type EvalContext
- type Facade
- func (f *Facade) HandleMsg(cmd int, req interface{})
- func (f *Facade) OnActionReq(req *proto.ActionReq)
- func (f *Facade) OnAddBreakPointReq(req *proto.AddBreakPointReq)
- func (f *Facade) OnBreak(L *lua.LState)
- func (f *Facade) OnEvalReq(req *proto.EvalReq)
- func (f *Facade) OnEvalResult(ctx *EvalContext)
- func (f *Facade) OnInitReq(req *proto.InitReq)
- func (f *Facade) OnReadyReq()
- func (f *Facade) OnRemoveBreakPointReq(req *proto.RemoveBreakPointReq)
- func (f *Facade) TcpConnect(L *lua.LState, host string, port int) error
- func (f *Facade) WaiteIDE(force bool)
- type HookState
- type HookStateBreak
- type HookStateContinue
- type HookStateInter
- type HookStateStepIn
- type HookStateStepOut
- type HookStateStepOver
- type HookStateStop
- type Stack
- type StackLevelBasedState
- type Transport
- type Variable
Constants ¶
View Source
const ( Lua_HookCall = iota Lua_HookRet Lua_HookLine Lua_HookCount )
View Source
const ( LUA_TNONE = iota - 1 LUA_TNIL LUA_TBOOLEAN LUA_TLIGHTUSERDATA LUA_TNUMBER LUA_TSTRING LUA_TTABLE LUA_TFUNCTION LUA_TUSERDATA LUA_TTHREAD )
Variables ¶
View Source
var Dbg = newDebugger()
View Source
var Fcd = newFacade()
Functions ¶
func EnvIndexFunction ¶
func GoLuaTypeToCLuaType ¶
func GoLuaTypeToCLuaType(t lua.LValueType) (int, string)
func ParsePathParts ¶
func TcpConnect ¶
Types ¶
type BreakPoint ¶
type Debugger ¶
type Debugger struct { SkipHook bool LineSet map[int]struct{} BreakPoints []*BreakPoint ExtNames []string CurrentState *lua.LState HelperCode string States map[*lua.LState]struct{} HookState HookStateInter // contains filtered or unexported fields }
func (*Debugger) AddBreakPoint ¶
func (d *Debugger) AddBreakPoint(bp *BreakPoint)
func (*Debugger) DoAction ¶
func (d *Debugger) DoAction(action proto.DebugAction)
func (*Debugger) DoEval ¶
func (d *Debugger) DoEval(evalContext *EvalContext) bool
func (*Debugger) EnterDebugMode ¶
func (*Debugger) Eval ¶
func (d *Debugger) Eval(ctx *EvalContext)
func (*Debugger) ExitDebugMode ¶
func (d *Debugger) ExitDebugMode()
func (*Debugger) FindBreakPoint ¶
func (d *Debugger) FindBreakPoint(L *lua.LState, ar *Ar) *BreakPoint
func (*Debugger) FindBreakPointByFile ¶
func (d *Debugger) FindBreakPointByFile(file string, line int) *BreakPoint
func (*Debugger) GetVariable ¶
func (*Debugger) HandleBreak ¶
func (*Debugger) MatchFileName ¶
func (*Debugger) RefreshLineSet ¶
func (d *Debugger) RefreshLineSet()
func (*Debugger) RemoveAllBreakpoints ¶
func (d *Debugger) RemoveAllBreakpoints()
func (*Debugger) RemoveBreakPoint ¶
func (*Debugger) SetHookState ¶
func (d *Debugger) SetHookState(L *lua.LState, newState HookStateInter)
type EvalContext ¶
type Facade ¶
type Facade struct {
// contains filtered or unexported fields
}
func (*Facade) OnActionReq ¶
func (*Facade) OnAddBreakPointReq ¶
func (f *Facade) OnAddBreakPointReq(req *proto.AddBreakPointReq)
func (*Facade) OnEvalResult ¶
func (f *Facade) OnEvalResult(ctx *EvalContext)
func (*Facade) OnReadyReq ¶
func (f *Facade) OnReadyReq()
func (*Facade) OnRemoveBreakPointReq ¶
func (f *Facade) OnRemoveBreakPointReq(req *proto.RemoveBreakPointReq)
type HookState ¶
type HookState struct {
// contains filtered or unexported fields
}
func (*HookState) ProcessHook ¶
type HookStateBreak ¶
type HookStateBreak struct {
HookState
}
func (*HookStateBreak) ProcessHook ¶
func (h *HookStateBreak) ProcessHook(debugger *Debugger, L *lua.LState, ar *Ar)
type HookStateContinue ¶
type HookStateContinue struct {
HookState
}
type HookStateInter ¶
type HookStateStepIn ¶
type HookStateStepIn struct { StackLevelBasedState // contains filtered or unexported fields }
func (*HookStateStepIn) ProcessHook ¶
func (h *HookStateStepIn) ProcessHook(debugger *Debugger, L *lua.LState, ar *Ar)
type HookStateStepOut ¶
type HookStateStepOut struct {
StackLevelBasedState
}
func (*HookStateStepOut) ProcessHook ¶
func (h *HookStateStepOut) ProcessHook(debugger *Debugger, L *lua.LState, ar *Ar)
type HookStateStepOver ¶
type HookStateStepOver struct { StackLevelBasedState // contains filtered or unexported fields }
func (*HookStateStepOver) ProcessHook ¶
func (h *HookStateStepOver) ProcessHook(debugger *Debugger, L *lua.LState, ar *Ar)
type HookStateStop ¶
type HookStateStop struct {
HookState
}
type StackLevelBasedState ¶
type StackLevelBasedState struct { HookState // contains filtered or unexported fields }
func (*StackLevelBasedState) Start ¶
func (h *StackLevelBasedState) Start(debugger *Debugger, current *lua.LState) bool
func (*StackLevelBasedState) UpdateStackLevel ¶
func (h *StackLevelBasedState) UpdateStackLevel(debugger *Debugger, L *lua.LState, ar *Ar)
Source Files ¶
Click to show internal directories.
Click to hide internal directories.