|
retdec-cpp
|
Representation of a decompilation. More...
#include <decompilation.h>
Public Types | |
| enum | OnError { OnError::Throw, OnError::NoThrow } |
| What should the waiting member functions do when a decompilation fails? More... | |
| using | Callback = std::function< void(const Decompilation &decompilation)> |
| Type of a callback for waitUntilFinished(). More... | |
Public Member Functions | |
| ~Decompilation () | |
| Destructs the decompilation. More... | |
Querying | |
| std::string | getId () const |
| Returns the ID of the decompilation. More... | |
| bool | hasFinished () |
| Has the decompilation finished? More... | |
| bool | hasFinished () const noexcept |
| Has the decompilation finished? More... | |
| bool | hasSucceeded () |
| Has the decompilation succeeded? More... | |
| bool | hasSucceeded () const noexcept |
| Has the decompilation succeeded? More... | |
| bool | hasFailed () |
| Has the decompilation failed? More... | |
| bool | hasFailed () const noexcept |
| Has the decompilation failed? More... | |
| int | getCompletion () |
| Returns the completion status (in percentages, 0-100). More... | |
| int | getCompletion () const noexcept |
| Returns the completion status (in percentages, 0-100). More... | |
| std::string | getError () |
| Returns the error message (if any). More... | |
| std::string | getError () const |
| Returns the error message (if any). More... | |
Waiting For Decompilation To Finish | |
| void | waitUntilFinished (OnError onError=OnError::Throw) |
| Waits until the decompilation is finished. More... | |
| void | waitUntilFinished (const Callback &callback, OnError onError=OnError::Throw) |
| Waits and reports changes until the decompilation is finished. More... | |
Getting Outputs | |
| std::shared_ptr< File > | getOutputHllFile () |
| Returns the output HLL file (C, Python'). More... | |
| std::string | getOutputHll () |
| Returns the content of the output HLL file (C, Python'). More... | |
Disabled | |
| Decompilation (const Decompilation &)=delete | |
| Decompilation (Decompilation &&)=delete | |
| Decompilation & | operator= (const Decompilation &)=delete |
| Decompilation & | operator= (Decompilation &&)=delete |
Representation of a decompilation.
| using retdec::Decompilation::Callback = std::function<void (const Decompilation &decompilation)> |
Type of a callback for waitUntilFinished().
|
strong |
What should the waiting member functions do when a decompilation fails?
| Enumerator | |
|---|---|
| Throw |
Throw DecompilationError when a decompilation fails. |
| NoThrow |
Do not throw DecompilationError when a decompilation fails. |
|
default |
Destructs the decompilation.
|
delete |
|
delete |
| int retdec::Decompilation::getCompletion | ( | ) |
Returns the completion status (in percentages, 0-100).
May access the API.
|
noexcept |
Returns the completion status (in percentages, 0-100).
Does not access the API.
| std::string retdec::Decompilation::getError | ( | ) |
Returns the error message (if any).
The output from this function is meaningful only if hasFinished() returns true and hasFailed() returns true.
May access the API.
| std::string retdec::Decompilation::getError | ( | ) | const |
Returns the error message (if any).
The output from this function is meaningful only if hasFinished() returns true and hasFailed() returns true.
Does not access the API.
| std::string retdec::Decompilation::getId | ( | ) | const |
Returns the ID of the decompilation.
Does not access the API.
| std::string retdec::Decompilation::getOutputHll | ( | ) |
Returns the content of the output HLL file (C, Python').
This function should be called only after the decompilation has finished, i.e. hasFinished() returns true.
May access the API.
| std::shared_ptr< File > retdec::Decompilation::getOutputHllFile | ( | ) |
Returns the output HLL file (C, Python').
This function should be called only after the decompilation has finished, i.e. hasFinished() returns true.
May access the API.
| bool retdec::Decompilation::hasFailed | ( | ) |
Has the decompilation failed?
The output from this function is meaningful only if hasFinished() returns true.
May access the API.
|
noexcept |
Has the decompilation failed?
The output from this function is meaningful only if hasFinished() returns true.
Does not access the API.
| bool retdec::Decompilation::hasFinished | ( | ) |
Has the decompilation finished?
May access the API.
|
noexcept |
Has the decompilation finished?
Does not access the API.
| bool retdec::Decompilation::hasSucceeded | ( | ) |
Has the decompilation succeeded?
The output from this function is meaningful only if hasFinished() returns true.
May access the API.
|
noexcept |
Has the decompilation succeeded?
The output from this function is meaningful only if hasFinished() returns true.
Does not access the API.
|
delete |
|
delete |
| void retdec::Decompilation::waitUntilFinished | ( | OnError | onError = OnError::Throw | ) |
Waits until the decompilation is finished.
| [in] | onError | Should DecompilationError be thrown when the decompilation fails? |
May access the API.
| void retdec::Decompilation::waitUntilFinished | ( | const Callback & | callback, |
| OnError | onError = OnError::Throw |
||
| ) |
Waits and reports changes until the decompilation is finished.
| [in] | callback | Function to be called when the decompilation status changes. |
| [in] | onError | Should DecompilationError be thrown when the decompilation fails? |
May access the API.
1.8.10