1<?xml version="1.0" encoding="ascii"?>
2<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
3          "DTD/xhtml1-transitional.dtd">
4<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
5<head>
6  <title>lldb.SBSourceManager</title>
7  <link rel="stylesheet" href="epydoc.css" type="text/css" />
8  <script type="text/javascript" src="epydoc.js"></script>
9</head>
10
11<body bgcolor="white" text="black" link="blue" vlink="#204080"
12      alink="#204080">
13<!-- ==================== NAVIGATION BAR ==================== -->
14<table class="navbar" border="0" width="100%" cellpadding="0"
15       bgcolor="#a0c0ff" cellspacing="0">
16  <tr valign="middle">
17
18  <!-- Tree link -->
19      <th>&nbsp;&nbsp;&nbsp;<a
20        href="module-tree.html">Trees</a>&nbsp;&nbsp;&nbsp;</th>
21
22  <!-- Index link -->
23      <th>&nbsp;&nbsp;&nbsp;<a
24        href="identifier-index.html">Indices</a>&nbsp;&nbsp;&nbsp;</th>
25
26  <!-- Help link -->
27      <th>&nbsp;&nbsp;&nbsp;<a
28        href="help.html">Help</a>&nbsp;&nbsp;&nbsp;</th>
29
30  <!-- Project homepage -->
31      <th class="navbar" align="right" width="100%">
32        <table border="0" cellpadding="0" cellspacing="0">
33          <tr><th class="navbar" align="center"
34            ><a class="navbar" target="_top" href="http://lldb.llvm.org">LLDB python API</a></th>
35          </tr></table></th>
36  </tr>
37</table>
38<table width="100%" cellpadding="0" cellspacing="0">
39  <tr valign="top">
40    <td width="100%">
41      <span class="breadcrumbs">
42        <a href="lldb-module.html">Package&nbsp;lldb</a> ::
43        Class&nbsp;SBSourceManager
44      </span>
45    </td>
46    <td>
47      <table cellpadding="0" cellspacing="0">
48        <!-- hide/show private -->
49        <tr><td align="right"><span class="options">[<a href="javascript:void(0);" class="privatelink"
50    onclick="toggle_private();">hide&nbsp;private</a>]</span></td></tr>
51        <tr><td align="right"><span class="options"
52            >[<a href="frames.html" target="_top">frames</a
53            >]&nbsp;|&nbsp;<a href="lldb.SBSourceManager-class.html"
54            target="_top">no&nbsp;frames</a>]</span></td></tr>
55      </table>
56    </td>
57  </tr>
58</table>
59<!-- ==================== CLASS DESCRIPTION ==================== -->
60<h1 class="epydoc">Class SBSourceManager</h1><p class="nomargin-top"><span class="codelink"><a href="lldb-pysrc.html#SBSourceManager">source&nbsp;code</a></span></p>
61<center>
62<center>  <map id="uml_class_diagram_for_lldb_sbs_2" name="uml_class_diagram_for_lldb_sbs_2">
63<area shape="rect" id="node38" href="lldb.SBSourceManager-class.html#__swig_setmethods__" title="lldb.SBSourceManager.__swig_setmethods__" alt="" coords="17,31,312,49"/>
64<area shape="rect" id="node38" href="lldb.SBSourceManager-class.html#__swig_getmethods__" title="lldb.SBSourceManager.__swig_getmethods__" alt="" coords="17,49,312,68"/>
65<area shape="rect" id="node38" href="lldb.SBSourceManager-class.html#__setattr__" title="x.__setattr__(&#39;name&#39;, value) &lt;==&gt; x.name = value" alt="" coords="17,71,312,89"/>
66<area shape="rect" id="node38" href="lldb.SBSourceManager-class.html#__getattr__" title="lldb.SBSourceManager.__getattr__" alt="" coords="17,89,312,108"/>
67<area shape="rect" id="node38" href="lldb.SBSourceManager-class.html#__repr__" title="repr(x)" alt="" coords="17,108,312,127"/>
68<area shape="rect" id="node38" href="lldb.SBSourceManager-class.html#__init__" title="__init__(lldb::SBSourceManager self, SBSourceManager rhs) &#45;&gt; &#160;SBSourceManager" alt="" coords="17,127,312,145"/>
69<area shape="rect" id="node38" href="lldb.SBSourceManager-class.html#__swig_destroy__" title="delete_SBSourceManager(SBSourceManager self)" alt="" coords="17,145,312,164"/>
70<area shape="rect" id="node38" href="lldb.SBSourceManager-class.html#__del__" title="lldb.SBSourceManager.__del__" alt="" coords="17,164,312,183"/>
71<area shape="rect" id="node38" href="lldb.SBSourceManager-class.html#DisplaySourceLinesWithLineNumbers" title="DisplaySourceLinesWithLineNumbers(SBSourceManager self, SBFileSpec file, uint32_t line, uint32_t context_before, uint32_t context_after, ..." alt="" coords="17,183,312,201"/>
72<area shape="rect" id="node1" href="lldb.SBSourceManager-class.html" title="Represents a central authority for displaying source code." alt="" coords="5,6,323,207"/>
73</map>
74  <img src="uml_class_diagram_for_lldb_sbs_2.gif" alt='' usemap="#uml_class_diagram_for_lldb_sbs_2" ismap="ismap" class="graph-without-title" />
75</center>
76</center>
77<hr />
78<pre class="literalblock">
79
80    Represents a central authority for displaying source code.
81
82    For example (from test/source-manager/TestSourceManager.py),
83
84            # Create the filespec for 'main.c'.
85            filespec = lldb.SBFileSpec('main.c', False)
86            source_mgr = self.dbg.GetSourceManager()
87            # Use a string stream as the destination.
88            stream = lldb.SBStream()
89            source_mgr.DisplaySourceLinesWithLineNumbers(filespec,
90                                                         self.line,
91                                                         2, # context before
92                                                         2, # context after
93                                                         '=&gt;', # prefix for current line
94                                                         stream)
95
96            #    2
97            #    3    int main(int argc, char const *argv[]) {
98            # =&gt; 4        printf('Hello world.
99'); // Set break point at this line.
100            #    5        return 0;
101            #    6    }
102            self.expect(stream.GetData(), 'Source code displayed correctly',
103                        exe=False,
104                patterns = ['=&gt; %d.*Hello world' % self.line])
105
106
107
108</pre>
109
110<!-- ==================== INSTANCE METHODS ==================== -->
111<a name="section-InstanceMethods"></a>
112<table class="summary" border="1" cellpadding="3"
113       cellspacing="0" width="100%" bgcolor="white">
114<tr bgcolor="#70b0f0" class="table-header">
115  <td colspan="2" class="table-header">
116    <table border="0" cellpadding="0" cellspacing="0" width="100%">
117      <tr valign="top">
118        <td align="left"><span class="table-header">Instance Methods</span></td>
119        <td align="right" valign="top"
120         ><span class="options">[<a href="#section-InstanceMethods"
121         class="privatelink" onclick="toggle_private();"
122         >hide private</a>]</span></td>
123      </tr>
124    </table>
125  </td>
126</tr>
127<tr>
128    <td width="15%" align="right" valign="top" class="summary">
129      <span class="summary-type">&nbsp;</span>
130    </td><td class="summary">
131      <table width="100%" cellpadding="0" cellspacing="0" border="0">
132        <tr>
133          <td><span class="summary-sig"><a href="lldb.SBSourceManager-class.html#__setattr__" class="summary-sig-name">__setattr__</a>(<span class="summary-sig-arg">self</span>,
134        <span class="summary-sig-arg">name</span>,
135        <span class="summary-sig-arg">value</span>)</span><br />
136      x.__setattr__('name', value) &lt;==&gt; x.name = value</td>
137          <td align="right" valign="top">
138            <span class="codelink"><a href="lldb-pysrc.html#SBSourceManager.__setattr__">source&nbsp;code</a></span>
139
140          </td>
141        </tr>
142      </table>
143
144    </td>
145  </tr>
146<tr>
147    <td width="15%" align="right" valign="top" class="summary">
148      <span class="summary-type">&nbsp;</span>
149    </td><td class="summary">
150      <table width="100%" cellpadding="0" cellspacing="0" border="0">
151        <tr>
152          <td><span class="summary-sig"><a name="__getattr__"></a><span class="summary-sig-name">__getattr__</span>(<span class="summary-sig-arg">self</span>,
153        <span class="summary-sig-arg">name</span>)</span></td>
154          <td align="right" valign="top">
155            <span class="codelink"><a href="lldb-pysrc.html#SBSourceManager.__getattr__">source&nbsp;code</a></span>
156
157          </td>
158        </tr>
159      </table>
160
161    </td>
162  </tr>
163<tr>
164    <td width="15%" align="right" valign="top" class="summary">
165      <span class="summary-type">&nbsp;</span>
166    </td><td class="summary">
167      <table width="100%" cellpadding="0" cellspacing="0" border="0">
168        <tr>
169          <td><span class="summary-sig"><a href="lldb.SBSourceManager-class.html#__repr__" class="summary-sig-name">__repr__</a>(<span class="summary-sig-arg">self</span>)</span><br />
170      repr(x)</td>
171          <td align="right" valign="top">
172            <span class="codelink"><a href="lldb-pysrc.html#_swig_repr">source&nbsp;code</a></span>
173
174          </td>
175        </tr>
176      </table>
177
178    </td>
179  </tr>
180<tr>
181    <td width="15%" align="right" valign="top" class="summary">
182      <span class="summary-type">&nbsp;</span>
183    </td><td class="summary">
184      <table width="100%" cellpadding="0" cellspacing="0" border="0">
185        <tr>
186          <td><span class="summary-sig"><a href="lldb.SBSourceManager-class.html#__init__" class="summary-sig-name">__init__</a>(<span class="summary-sig-arg">self</span>,
187        <span class="summary-sig-arg">*args</span>)</span><br />
188      __init__(lldb::SBSourceManager self, SBSourceManager rhs) -&gt;
189      SBSourceManager</td>
190          <td align="right" valign="top">
191            <span class="codelink"><a href="lldb-pysrc.html#SBSourceManager.__init__">source&nbsp;code</a></span>
192
193          </td>
194        </tr>
195      </table>
196
197    </td>
198  </tr>
199<tr>
200    <td width="15%" align="right" valign="top" class="summary">
201      <span class="summary-type">&nbsp;</span>
202    </td><td class="summary">
203      <table width="100%" cellpadding="0" cellspacing="0" border="0">
204        <tr>
205          <td><span class="summary-sig"><a name="__swig_destroy__"></a><span class="summary-sig-name">__swig_destroy__</span>(<span class="summary-sig-arg">...</span>)</span><br />
206      delete_SBSourceManager(SBSourceManager self)</td>
207          <td align="right" valign="top">
208
209
210          </td>
211        </tr>
212      </table>
213
214    </td>
215  </tr>
216<tr>
217    <td width="15%" align="right" valign="top" class="summary">
218      <span class="summary-type">&nbsp;</span>
219    </td><td class="summary">
220      <table width="100%" cellpadding="0" cellspacing="0" border="0">
221        <tr>
222          <td><span class="summary-sig"><a name="__del__"></a><span class="summary-sig-name">__del__</span>(<span class="summary-sig-arg">self</span>)</span></td>
223          <td align="right" valign="top">
224            <span class="codelink"><a href="lldb-pysrc.html#SBSourceManager.__del__">source&nbsp;code</a></span>
225
226          </td>
227        </tr>
228      </table>
229
230    </td>
231  </tr>
232<tr>
233    <td width="15%" align="right" valign="top" class="summary">
234      <span class="summary-type">&nbsp;</span>
235    </td><td class="summary">
236      <table width="100%" cellpadding="0" cellspacing="0" border="0">
237        <tr>
238          <td><span class="summary-sig"><a href="lldb.SBSourceManager-class.html#DisplaySourceLinesWithLineNumbers" class="summary-sig-name">DisplaySourceLinesWithLineNumbers</a>(<span class="summary-sig-arg">self</span>,
239        <span class="summary-sig-arg">*args</span>)</span><br />
240      DisplaySourceLinesWithLineNumbers(SBSourceManager self, SBFileSpec file, uint32_t line, uint32_t context_before, uint32_t context_after, ...</td>
241          <td align="right" valign="top">
242            <span class="codelink"><a href="lldb-pysrc.html#SBSourceManager.DisplaySourceLinesWithLineNumbers">source&nbsp;code</a></span>
243
244          </td>
245        </tr>
246      </table>
247
248    </td>
249  </tr>
250  <tr>
251    <td colspan="2" class="summary">
252    <p class="indent-wrapped-lines"><b>Inherited from <code>object</code></b>:
253      <code>__delattr__</code>,
254      <code>__format__</code>,
255      <code>__getattribute__</code>,
256      <code>__hash__</code>,
257      <code>__new__</code>,
258      <code>__reduce__</code>,
259      <code>__reduce_ex__</code>,
260      <code>__sizeof__</code>,
261      <code>__str__</code>,
262      <code>__subclasshook__</code>
263      </p>
264    </td>
265  </tr>
266</table>
267<!-- ==================== CLASS VARIABLES ==================== -->
268<a name="section-ClassVariables"></a>
269<table class="summary" border="1" cellpadding="3"
270       cellspacing="0" width="100%" bgcolor="white">
271<tr bgcolor="#70b0f0" class="table-header">
272  <td colspan="2" class="table-header">
273    <table border="0" cellpadding="0" cellspacing="0" width="100%">
274      <tr valign="top">
275        <td align="left"><span class="table-header">Class Variables</span></td>
276        <td align="right" valign="top"
277         ><span class="options">[<a href="#section-ClassVariables"
278         class="privatelink" onclick="toggle_private();"
279         >hide private</a>]</span></td>
280      </tr>
281    </table>
282  </td>
283</tr>
284<tr>
285    <td width="15%" align="right" valign="top" class="summary">
286      <span class="summary-type">&nbsp;</span>
287    </td><td class="summary">
288        <a name="__swig_setmethods__"></a><span class="summary-name">__swig_setmethods__</span> = <code title="{}"><code class="variable-group">{</code><code class="variable-group">}</code></code>
289    </td>
290  </tr>
291<tr>
292    <td width="15%" align="right" valign="top" class="summary">
293      <span class="summary-type">&nbsp;</span>
294    </td><td class="summary">
295        <a name="__swig_getmethods__"></a><span class="summary-name">__swig_getmethods__</span> = <code title="{}"><code class="variable-group">{</code><code class="variable-group">}</code></code>
296    </td>
297  </tr>
298</table>
299<!-- ==================== PROPERTIES ==================== -->
300<a name="section-Properties"></a>
301<table class="summary" border="1" cellpadding="3"
302       cellspacing="0" width="100%" bgcolor="white">
303<tr bgcolor="#70b0f0" class="table-header">
304  <td colspan="2" class="table-header">
305    <table border="0" cellpadding="0" cellspacing="0" width="100%">
306      <tr valign="top">
307        <td align="left"><span class="table-header">Properties</span></td>
308        <td align="right" valign="top"
309         ><span class="options">[<a href="#section-Properties"
310         class="privatelink" onclick="toggle_private();"
311         >hide private</a>]</span></td>
312      </tr>
313    </table>
314  </td>
315</tr>
316  <tr>
317    <td colspan="2" class="summary">
318    <p class="indent-wrapped-lines"><b>Inherited from <code>object</code></b>:
319      <code>__class__</code>
320      </p>
321    </td>
322  </tr>
323</table>
324<!-- ==================== METHOD DETAILS ==================== -->
325<a name="section-MethodDetails"></a>
326<table class="details" border="1" cellpadding="3"
327       cellspacing="0" width="100%" bgcolor="white">
328<tr bgcolor="#70b0f0" class="table-header">
329  <td colspan="2" class="table-header">
330    <table border="0" cellpadding="0" cellspacing="0" width="100%">
331      <tr valign="top">
332        <td align="left"><span class="table-header">Method Details</span></td>
333        <td align="right" valign="top"
334         ><span class="options">[<a href="#section-MethodDetails"
335         class="privatelink" onclick="toggle_private();"
336         >hide private</a>]</span></td>
337      </tr>
338    </table>
339  </td>
340</tr>
341</table>
342<a name="__setattr__"></a>
343<div>
344<table class="details" border="1" cellpadding="3"
345       cellspacing="0" width="100%" bgcolor="white">
346<tr><td>
347  <table width="100%" cellpadding="0" cellspacing="0" border="0">
348  <tr valign="top"><td>
349  <h3 class="epydoc"><span class="sig"><span class="sig-name">__setattr__</span>(<span class="sig-arg">self</span>,
350        <span class="sig-arg">name</span>,
351        <span class="sig-arg">value</span>)</span>
352  </h3>
353  </td><td align="right" valign="top"
354    ><span class="codelink"><a href="lldb-pysrc.html#SBSourceManager.__setattr__">source&nbsp;code</a></span>&nbsp;
355    </td>
356  </tr></table>
357
358  <p>x.__setattr__('name', value) &lt;==&gt; x.name = value</p>
359  <dl class="fields">
360    <dt>Overrides:
361        object.__setattr__
362        <dd><em class="note">(inherited documentation)</em></dd>
363    </dt>
364  </dl>
365</td></tr></table>
366</div>
367<a name="__repr__"></a>
368<div>
369<table class="details" border="1" cellpadding="3"
370       cellspacing="0" width="100%" bgcolor="white">
371<tr><td>
372  <table width="100%" cellpadding="0" cellspacing="0" border="0">
373  <tr valign="top"><td>
374  <h3 class="epydoc"><span class="sig"><span class="sig-name">__repr__</span>(<span class="sig-arg">self</span>)</span>
375    <br /><em class="fname">(Representation operator)</em>
376  </h3>
377  </td><td align="right" valign="top"
378    ><span class="codelink"><a href="lldb-pysrc.html#_swig_repr">source&nbsp;code</a></span>&nbsp;
379    </td>
380  </tr></table>
381
382  <p>repr(x)</p>
383  <dl class="fields">
384    <dt>Overrides:
385        object.__repr__
386        <dd><em class="note">(inherited documentation)</em></dd>
387    </dt>
388  </dl>
389</td></tr></table>
390</div>
391<a name="__init__"></a>
392<div>
393<table class="details" border="1" cellpadding="3"
394       cellspacing="0" width="100%" bgcolor="white">
395<tr><td>
396  <table width="100%" cellpadding="0" cellspacing="0" border="0">
397  <tr valign="top"><td>
398  <h3 class="epydoc"><span class="sig"><span class="sig-name">__init__</span>(<span class="sig-arg">self</span>,
399        <span class="sig-arg">*args</span>)</span>
400    <br /><em class="fname">(Constructor)</em>
401  </h3>
402  </td><td align="right" valign="top"
403    ><span class="codelink"><a href="lldb-pysrc.html#SBSourceManager.__init__">source&nbsp;code</a></span>&nbsp;
404    </td>
405  </tr></table>
406
407  <p>__init__(lldb::SBSourceManager self, SBSourceManager rhs) -&gt;
408  SBSourceManager</p>
409  <dl class="fields">
410    <dt>Overrides:
411        object.__init__
412    </dt>
413  </dl>
414</td></tr></table>
415</div>
416<a name="DisplaySourceLinesWithLineNumbers"></a>
417<div>
418<table class="details" border="1" cellpadding="3"
419       cellspacing="0" width="100%" bgcolor="white">
420<tr><td>
421  <table width="100%" cellpadding="0" cellspacing="0" border="0">
422  <tr valign="top"><td>
423  <h3 class="epydoc"><span class="sig"><span class="sig-name">DisplaySourceLinesWithLineNumbers</span>(<span class="sig-arg">self</span>,
424        <span class="sig-arg">*args</span>)</span>
425  </h3>
426  </td><td align="right" valign="top"
427    ><span class="codelink"><a href="lldb-pysrc.html#SBSourceManager.DisplaySourceLinesWithLineNumbers">source&nbsp;code</a></span>&nbsp;
428    </td>
429  </tr></table>
430
431  <pre class="literalblock">
432
433DisplaySourceLinesWithLineNumbers(SBSourceManager self, SBFileSpec file, uint32_t line, uint32_t context_before, uint32_t context_after,
434    str const * current_line_cstr, SBStream s) -&gt; size_t
435
436</pre>
437  <dl class="fields">
438  </dl>
439</td></tr></table>
440</div>
441<br />
442<!-- ==================== NAVIGATION BAR ==================== -->
443<table class="navbar" border="0" width="100%" cellpadding="0"
444       bgcolor="#a0c0ff" cellspacing="0">
445  <tr valign="middle">
446
447  <!-- Tree link -->
448      <th>&nbsp;&nbsp;&nbsp;<a
449        href="module-tree.html">Trees</a>&nbsp;&nbsp;&nbsp;</th>
450
451  <!-- Index link -->
452      <th>&nbsp;&nbsp;&nbsp;<a
453        href="identifier-index.html">Indices</a>&nbsp;&nbsp;&nbsp;</th>
454
455  <!-- Help link -->
456      <th>&nbsp;&nbsp;&nbsp;<a
457        href="help.html">Help</a>&nbsp;&nbsp;&nbsp;</th>
458
459  <!-- Project homepage -->
460      <th class="navbar" align="right" width="100%">
461        <table border="0" cellpadding="0" cellspacing="0">
462          <tr><th class="navbar" align="center"
463            ><a class="navbar" target="_top" href="http://lldb.llvm.org">LLDB python API</a></th>
464          </tr></table></th>
465  </tr>
466</table>
467<table border="0" cellpadding="0" cellspacing="0" width="100%%">
468  <tr>
469    <td align="left" class="footer">
470    Generated by Epydoc 3.0.1 on Fri Jul 19 13:22:35 2013
471    </td>
472    <td align="right" class="footer">
473      <a target="mainFrame" href="http://epydoc.sourceforge.net"
474        >http://epydoc.sourceforge.net</a>
475    </td>
476  </tr>
477</table>
478
479<script type="text/javascript">
480  <!--
481  // Private objects are initially displayed (because if
482  // javascript is turned off then we want them to be
483  // visible); but by default, we want to hide them.  So hide
484  // them unless we have a cookie that says to show them.
485  checkCookie();
486  // -->
487</script>
488</body>
489</html>
490