ProfilerSQLNode Class
Class representing each SQL query run
Constructor
ProfilerSQLNode
-
profiler
-
query
-
[profileNode=null]
Parameters:
-
profiler
ProfilerReference to the profiler object
-
query
Stringthe sql query for this node
-
[profileNode=null]
Boolean | ProfilerNode optionalreference to the step that this query is running within
Item Index
Methods
end
()
ProfilerSQLNode
End the timers for this sql node. Call this method when the sql query has finished running.
Returns:
return a reference to this query, for chaining.
getCallstack
()
Array
Return the call stack for this query. Reference the php documentation for {@link http://php.net/debug_backtrace debug_backtrace} for the structure of the return array.
Returns:
call stack for this query
getDuration
()
Number
Get the total execution duration for this query
Returns:
Execution duration for this query in milliseconds, rounded to 1 significant digit.
getQuery
()
String
Get the query for this SQLNode. Query is parsed so extraneous spaces are removed where required.
Returns:
Query for this node
Properties
callstack
Array
protected
Call stack backtrace of all methods/functions executed up until this SQL query is run