C# Class LLDB.Value

Inheritance: IDisposable
ファイルを表示 Open project: tritao/LLDBSharp Class Usage Examples

Public Properties

Property Type Description
NativeToManagedMap Value>.System.Collections.Concurrent.ConcurrentDictionary

Protected Properties

Property Type Description
__OriginalVTables void*[]
__PointerAdjustment int
__ownsNativeInstance bool

Public Methods

Method Description
AddressOf ( ) : LLDB.Value
Cast ( LLDB type ) : LLDB.Value
Clear ( ) : void
CreateChildAtOffset ( string name, uint offset, LLDB type ) : LLDB.Value
CreateValueFromAddress ( string name, ulong address, LLDB type ) : LLDB.Value
CreateValueFromData ( string name, LLDB data, LLDB type ) : LLDB.Value
CreateValueFromExpression ( string name, string expression ) : LLDB.Value
CreateValueFromExpression ( string name, string expression, LLDB options ) : LLDB.Value
Dereference ( ) : LLDB.Value
Dispose ( ) : void
GetAddress ( ) : LLDB.Address
GetChildAtIndex ( uint idx ) : LLDB.Value
GetChildAtIndex ( uint idx, LLDB use_dynamic, bool can_create_synthetic ) : LLDB.Value

Get a child value by index from a value.

Structs, unions, classes, arrays and pointers have child

values that can be access by index.

Structs and unions access child members using a zero based index

for each child member. For

Classes reserve the first indexes for base classes that have

members (empty base classes are omitted), and all members of the

current class will then follow the base classes.

Pointers differ depending on what they point to. If the pointer

points to a simple type, the child at index zero

is the only child value available, unless

is

in which case the pointer will be used as an array

and can create 'synthetic' child values using positive or

negative indexes. If the pointer points to an aggregate type

(an array, class, union, struct), then the pointee is

transparently skipped and any children are going to be the indexes

of the child values within the aggregate type. For example if

we have a 'Point' type and we have a SBValue that contains a

pointer to a 'Point' type, then the child at index zero will be

the 'x' member, and the child at index 1 will be the 'y' member

(the child at index zero won't be a 'Point' instance).

If you actually need an SBValue that represents the type pointed

to by a SBValue for which GetType().IsPointeeType() returns true,

regardless of the pointee type, you can do that with SBValue::Dereference.

Arrays have a preset number of children that can be accessed by

index and will returns invalid child values for indexes that are

out of bounds unless the

is

In this

case the array can create 'synthetic' child values for indexes

that aren't in the array bounds using positive or negative

indexes.

GetChildMemberWithName ( string name ) : LLDB.Value
GetChildMemberWithName ( string name, LLDB use_dynamic ) : LLDB.Value
GetData ( ) : LLDB.Data

Get an SBData wrapping the contents of this SBValue.

This method will read the contents of this object in memory

and copy them into an SBData for future use.

GetDeclaration ( ) : LLDB.Declaration
GetDescription ( LLDB description ) : bool
GetDynamicValue ( LLDB use_dynamic ) : LLDB.Value
GetError ( ) : LLDB.Error
GetExpressionPath ( LLDB description ) : bool
GetExpressionPath ( LLDB description, bool qualify_cxx_base_classes ) : bool
GetFrame ( ) : LLDB.Frame
GetIndexOfChildWithName ( string name ) : uint
GetNonSyntheticValue ( ) : LLDB.Value
GetNumChildren ( uint max ) : uint
GetPointeeData ( uint item_idx, uint item_count ) : LLDB.Data

Get an SBData wrapping what this SBValue points to.

This method will dereference the current SBValue, if its

data type is a T* or T[], and extract item_count elements

of type T from it, copying their contents in an SBData.

GetProcess ( ) : LLDB.Process
GetStaticValue ( ) : LLDB.Value
GetSummary ( LLDB stream, LLDB options ) : string
GetTarget ( ) : LLDB.Target
GetThread ( ) : LLDB.Thread
GetType ( ) : LLDB.Type
GetTypeFilter ( ) : LLDB.TypeFilter
GetTypeFormat ( ) : LLDB.TypeFormat
GetTypeSummary ( ) : LLDB.TypeSummary
GetTypeSynthetic ( ) : LLDB.TypeSynthetic
GetValueAsSigned ( LLDB error, long fail_value ) : long
GetValueAsSigned ( long fail_value ) : long
GetValueAsUnsigned ( LLDB error, ulong fail_value ) : ulong
GetValueAsUnsigned ( ulong fail_value ) : ulong
GetValueForExpressionPath ( string expr_path ) : LLDB.Value
IsDynamic ( ) : bool
IsInScope ( ) : bool
IsRuntimeSupportValue ( ) : bool
IsSynthetic ( ) : bool
IsValid ( ) : bool
MightHaveChildren ( ) : bool

Find out if a SBValue might have children.

This call is much more efficient than GetNumChildren() as it

doesn't need to complete the underlying type. This is designed

to be used in a UI environment in order to detect if the

disclosure triangle should be displayed or not.

This function returns true for class, union, structure,

pointers, references, arrays and more. Again, it does so without

doing any expensive type completion.

Persist ( ) : LLDB.Value
SetData ( LLDB data, LLDB error ) : bool
SetValueFromCString ( string value_str ) : bool
SetValueFromCString ( string value_str, LLDB error ) : bool
TypeIsPointerType ( ) : bool
Value ( ) : System
Value ( LLDB rhs ) : System
Watch ( bool resolve_location, bool read, bool write ) : LLDB.Watchpoint
Watch ( bool resolve_location, bool read, bool write, LLDB error ) : LLDB.Watchpoint

Watch this value if it resides in memory.

Sets a watchpoint on the value.

WatchPointee ( bool resolve_location, bool read, bool write, LLDB error ) : LLDB.Watchpoint

Watch this value that this value points to in memory

Sets a watchpoint on the value.

__CreateInstance ( Value native, bool skipVTables = false ) : Value
__CreateInstance ( global native, bool skipVTables = false ) : Value

Protected Methods

Method Description
Dispose ( bool disposing ) : void
Value ( void native, bool skipVTables = false ) : System

Private Methods

Method Description
Value ( Value native, bool skipVTables = false ) : System
__CopyValue ( Value native ) : void*

Method Details

AddressOf() public method

public AddressOf ( ) : LLDB.Value
return LLDB.Value

Cast() public method

public Cast ( LLDB type ) : LLDB.Value
type LLDB
return LLDB.Value

Clear() public method

public Clear ( ) : void
return void

CreateChildAtOffset() public method

public CreateChildAtOffset ( string name, uint offset, LLDB type ) : LLDB.Value
name string
offset uint
type LLDB
return LLDB.Value

CreateValueFromAddress() public method

public CreateValueFromAddress ( string name, ulong address, LLDB type ) : LLDB.Value
name string
address ulong
type LLDB
return LLDB.Value

CreateValueFromData() public method

public CreateValueFromData ( string name, LLDB data, LLDB type ) : LLDB.Value
name string
data LLDB
type LLDB
return LLDB.Value

CreateValueFromExpression() public method

public CreateValueFromExpression ( string name, string expression ) : LLDB.Value
name string
expression string
return LLDB.Value

CreateValueFromExpression() public method

public CreateValueFromExpression ( string name, string expression, LLDB options ) : LLDB.Value
name string
expression string
options LLDB
return LLDB.Value

Dereference() public method

public Dereference ( ) : LLDB.Value
return LLDB.Value

Dispose() public method

public Dispose ( ) : void
return void

Dispose() protected method

protected Dispose ( bool disposing ) : void
disposing bool
return void

GetAddress() public method

public GetAddress ( ) : LLDB.Address
return LLDB.Address

GetChildAtIndex() public method

public GetChildAtIndex ( uint idx ) : LLDB.Value
idx uint
return LLDB.Value

GetChildAtIndex() public method

Get a child value by index from a value.

Structs, unions, classes, arrays and pointers have child

values that can be access by index.

Structs and unions access child members using a zero based index

for each child member. For

Classes reserve the first indexes for base classes that have

members (empty base classes are omitted), and all members of the

current class will then follow the base classes.

Pointers differ depending on what they point to. If the pointer

points to a simple type, the child at index zero

is the only child value available, unless

is

in which case the pointer will be used as an array

and can create 'synthetic' child values using positive or

negative indexes. If the pointer points to an aggregate type

(an array, class, union, struct), then the pointee is

transparently skipped and any children are going to be the indexes

of the child values within the aggregate type. For example if

we have a 'Point' type and we have a SBValue that contains a

pointer to a 'Point' type, then the child at index zero will be

the 'x' member, and the child at index 1 will be the 'y' member

(the child at index zero won't be a 'Point' instance).

If you actually need an SBValue that represents the type pointed

to by a SBValue for which GetType().IsPointeeType() returns true,

regardless of the pointee type, you can do that with SBValue::Dereference.

Arrays have a preset number of children that can be accessed by

index and will returns invalid child values for indexes that are

out of bounds unless the

is

In this

case the array can create 'synthetic' child values for indexes

that aren't in the array bounds using positive or negative

indexes.

public GetChildAtIndex ( uint idx, LLDB use_dynamic, bool can_create_synthetic ) : LLDB.Value
idx uint /// The index of the child value to get ///
use_dynamic LLDB /// An enumeration that specifies whether to get dynamic values, /// and also if the target can be run to figure out the dynamic /// type of the child value. ///
can_create_synthetic bool /// If /// then allow child values to be created by index /// for pointers and arrays for indexes that normally wouldn't /// be allowed. ///
return LLDB.Value

GetChildMemberWithName() public method

public GetChildMemberWithName ( string name ) : LLDB.Value
name string
return LLDB.Value

GetChildMemberWithName() public method

public GetChildMemberWithName ( string name, LLDB use_dynamic ) : LLDB.Value
name string
use_dynamic LLDB
return LLDB.Value

GetData() public method

Get an SBData wrapping the contents of this SBValue.

This method will read the contents of this object in memory

and copy them into an SBData for future use.

public GetData ( ) : LLDB.Data
return LLDB.Data

GetDeclaration() public method

public GetDeclaration ( ) : LLDB.Declaration
return LLDB.Declaration

GetDescription() public method

public GetDescription ( LLDB description ) : bool
description LLDB
return bool

GetDynamicValue() public method

public GetDynamicValue ( LLDB use_dynamic ) : LLDB.Value
use_dynamic LLDB
return LLDB.Value

GetError() public method

public GetError ( ) : LLDB.Error
return LLDB.Error

GetExpressionPath() public method

public GetExpressionPath ( LLDB description ) : bool
description LLDB
return bool

GetExpressionPath() public method

public GetExpressionPath ( LLDB description, bool qualify_cxx_base_classes ) : bool
description LLDB
qualify_cxx_base_classes bool
return bool

GetFrame() public method

public GetFrame ( ) : LLDB.Frame
return LLDB.Frame

GetIndexOfChildWithName() public method

public GetIndexOfChildWithName ( string name ) : uint
name string
return uint

GetNonSyntheticValue() public method

public GetNonSyntheticValue ( ) : LLDB.Value
return LLDB.Value

GetNumChildren() public method

public GetNumChildren ( uint max ) : uint
max uint
return uint

GetPointeeData() public method

Get an SBData wrapping what this SBValue points to.

This method will dereference the current SBValue, if its

data type is a T* or T[], and extract item_count elements

of type T from it, copying their contents in an SBData.

public GetPointeeData ( uint item_idx, uint item_count ) : LLDB.Data
item_idx uint /// The index of the first item to retrieve. For an array /// this is equivalent to array[item_idx], for a pointer /// to *(pointer + item_idx). In either case, the measurement /// unit for item_idx is the sizeof(T) rather than the byte ///
item_count uint /// How many items should be copied into the output. By default /// only one item is copied, but more can be asked for. ///
return LLDB.Data

GetProcess() public method

public GetProcess ( ) : LLDB.Process
return LLDB.Process

GetStaticValue() public method

public GetStaticValue ( ) : LLDB.Value
return LLDB.Value

GetSummary() public method

public GetSummary ( LLDB stream, LLDB options ) : string
stream LLDB
options LLDB
return string

GetTarget() public method

public GetTarget ( ) : LLDB.Target
return LLDB.Target

GetThread() public method

public GetThread ( ) : LLDB.Thread
return LLDB.Thread

GetType() public method

public GetType ( ) : LLDB.Type
return LLDB.Type

GetTypeFilter() public method

public GetTypeFilter ( ) : LLDB.TypeFilter
return LLDB.TypeFilter

GetTypeFormat() public method

public GetTypeFormat ( ) : LLDB.TypeFormat
return LLDB.TypeFormat

GetTypeSummary() public method

public GetTypeSummary ( ) : LLDB.TypeSummary
return LLDB.TypeSummary

GetTypeSynthetic() public method

public GetTypeSynthetic ( ) : LLDB.TypeSynthetic
return LLDB.TypeSynthetic

GetValueAsSigned() public method

public GetValueAsSigned ( LLDB error, long fail_value ) : long
error LLDB
fail_value long
return long

GetValueAsSigned() public method

public GetValueAsSigned ( long fail_value ) : long
fail_value long
return long

GetValueAsUnsigned() public method

public GetValueAsUnsigned ( LLDB error, ulong fail_value ) : ulong
error LLDB
fail_value ulong
return ulong

GetValueAsUnsigned() public method

public GetValueAsUnsigned ( ulong fail_value ) : ulong
fail_value ulong
return ulong

GetValueForExpressionPath() public method

public GetValueForExpressionPath ( string expr_path ) : LLDB.Value
expr_path string
return LLDB.Value

IsDynamic() public method

public IsDynamic ( ) : bool
return bool

IsInScope() public method

public IsInScope ( ) : bool
return bool

IsRuntimeSupportValue() public method

public IsRuntimeSupportValue ( ) : bool
return bool

IsSynthetic() public method

public IsSynthetic ( ) : bool
return bool

IsValid() public method

public IsValid ( ) : bool
return bool

MightHaveChildren() public method

Find out if a SBValue might have children.

This call is much more efficient than GetNumChildren() as it

doesn't need to complete the underlying type. This is designed

to be used in a UI environment in order to detect if the

disclosure triangle should be displayed or not.

This function returns true for class, union, structure,

pointers, references, arrays and more. Again, it does so without

doing any expensive type completion.

public MightHaveChildren ( ) : bool
return bool

Persist() public method

public Persist ( ) : LLDB.Value
return LLDB.Value

SetData() public method

public SetData ( LLDB data, LLDB error ) : bool
data LLDB
error LLDB
return bool

SetValueFromCString() public method

public SetValueFromCString ( string value_str ) : bool
value_str string
return bool

SetValueFromCString() public method

public SetValueFromCString ( string value_str, LLDB error ) : bool
value_str string
error LLDB
return bool

TypeIsPointerType() public method

public TypeIsPointerType ( ) : bool
return bool

Value() public method

public Value ( ) : System
return System

Value() public method

public Value ( LLDB rhs ) : System
rhs LLDB
return System

Value() protected method

protected Value ( void native, bool skipVTables = false ) : System
native void
skipVTables bool
return System

Watch() public method

public Watch ( bool resolve_location, bool read, bool write ) : LLDB.Watchpoint
resolve_location bool
read bool
write bool
return LLDB.Watchpoint

Watch() public method

Watch this value if it resides in memory.

Sets a watchpoint on the value.

public Watch ( bool resolve_location, bool read, bool write, LLDB error ) : LLDB.Watchpoint
resolve_location bool /// Resolve the location of this value once and watch its address. /// This value must currently be set to /// as watching all /// locations of a variable or a variable path is not yet supported, /// though we plan to support it in the future. ///
read bool /// Stop when this value is accessed. ///
write bool /// Stop when this value is modified ///
error LLDB /// An error object. Contains the reason if there is some failure. ///
return LLDB.Watchpoint

WatchPointee() public method

Watch this value that this value points to in memory

Sets a watchpoint on the value.

public WatchPointee ( bool resolve_location, bool read, bool write, LLDB error ) : LLDB.Watchpoint
resolve_location bool /// Resolve the location of this value once and watch its address. /// This value must currently be set to /// as watching all /// locations of a variable or a variable path is not yet supported, /// though we plan to support it in the future. ///
read bool /// Stop when this value is accessed. ///
write bool /// Stop when this value is modified ///
error LLDB /// An error object. Contains the reason if there is some failure. ///
return LLDB.Watchpoint

__CreateInstance() public static method

public static __CreateInstance ( Value native, bool skipVTables = false ) : Value
native Value
skipVTables bool
return Value

__CreateInstance() public static method

public static __CreateInstance ( global native, bool skipVTables = false ) : Value
native global
skipVTables bool
return Value

Property Details

NativeToManagedMap public_oe static_oe property

public static System.Collections.Concurrent.ConcurrentDictionary NativeToManagedMap
return Value>.System.Collections.Concurrent.ConcurrentDictionary

__OriginalVTables protected_oe property

protected void*[] __OriginalVTables
return void*[]

__PointerAdjustment protected_oe property

protected int __PointerAdjustment
return int

__ownsNativeInstance protected_oe property

protected bool __ownsNativeInstance
return bool