MCPcopy Create free account
hub / github.com/Vector35/binaryninja-api / LinearViewObject

Class LinearViewObject

python/lineardisassembly.py:168–500  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

166
167
168class LinearViewObject:
169 def __init__(self, handle, parent=None):
170 self.handle = handle
171 self._parent = parent
172
173 def __del__(self):
174 if core is not None:
175 core.BNFreeLinearViewObject(self.handle)
176
177 def __repr__(self):
178 return "<LinearViewObject: " + str(self) + ">"
179
180 def __len__(self):
181 return self.end - self.start
182
183 def __str__(self):
184 result = str(self.identifier)
185 if self._parent is not None:
186 result = str(self._parent) + "/" + result
187 return result
188
189 @property
190 def first_child(self):
191 result = core.BNGetFirstLinearViewObjectChild(self.handle)
192 if not result:
193 return None
194 return LinearViewObject(result, self)
195
196 @property
197 def last_child(self):
198 result = core.BNGetLastLinearViewObjectChild(self.handle)
199 if not result:
200 return None
201 return LinearViewObject(result, self)
202
203 @property
204 def previous(self):
205 if self._parent is None:
206 return None
207 result = core.BNGetPreviousLinearViewObjectChild(self._parent.handle, self.handle)
208 if not result:
209 return None
210 return LinearViewObject(result, self._parent)
211
212 @property
213 def next(self):
214 if self._parent is None:
215 return None
216 result = core.BNGetNextLinearViewObjectChild(self._parent.handle, self.handle)
217 if not result:
218 return None
219 return LinearViewObject(result, self._parent)
220
221 @property
222 def start(self):
223 return core.BNGetLinearViewObjectStart(self.handle)
224
225 @property

Callers 15

first_childMethod · 0.70
last_childMethod · 0.70
previousMethod · 0.70
nextMethod · 0.70
child_for_addressMethod · 0.70
child_for_identifierMethod · 0.70
disassemblyMethod · 0.70
lifted_ilMethod · 0.70
llilMethod · 0.70
llil_ssa_formMethod · 0.70
mlilMethod · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected