Class: Relyze::Plugin::Loader
- Defined in:
- C:/Program Files/Relyze/lib/relyze/core/plugin.rb
Instance Attribute Summary
Attributes inherited from Base
#autorun_model, #information, #relyze
Class Method Summary collapse
-
.query(buffer) ⇒ Hash, NilClass
A class method to query if this plugin can load the data in the buffer.
Instance Method Summary collapse
-
#initialize(_information) ⇒ Loader
constructor
A new instance of Loader.
-
#load ⇒ TrueClass, FalseClass
Perform the actual loading of a binary.
-
#main ⇒ TrueClass, ...
The loader plugins main method, automatically called by the application.
-
#type ⇒ Object
Get this plugin type.
Methods inherited from Base
#abort_analysis, #authors, #can_run?, #current_model, #description, #get_persistent_value, #guid, #license, #name, #options, #origin, #print_error, #print_exception, #print_message, #print_warning, #references, #remove_task, #require_files, #restart_analysis, #set_persistent_value, #task_status, #version, #version_major, #version_minor
Constructor Details
#initialize(_information) ⇒ Loader
Returns a new instance of Loader
679 680 681 |
# File 'C:/Program Files/Relyze/lib/relyze/core/plugin.rb', line 679 def initialize( _information ) super( _information ) end |
Class Method Details
.query(buffer) ⇒ Hash, NilClass
A class method to query if this plugin can load the data in the buffer.
714 715 716 |
# File 'C:/Program Files/Relyze/lib/relyze/core/plugin.rb', line 714 def self.query( buffer ) return nil end |
Instance Method Details
#load ⇒ TrueClass, FalseClass
Perform the actual loading of a binary.
721 722 723 |
# File 'C:/Program Files/Relyze/lib/relyze/core/plugin.rb', line 721 def load return false end |
#main ⇒ TrueClass, ...
The loader plugins main method, automatically called by the application.
728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 |
# File 'C:/Program Files/Relyze/lib/relyze/core/plugin.rb', line 728 def main result = nil if( self.can_run? ) begin result = self.load() rescue Relyze::AbortException print_warning( "Plugin '#{self.name}' aborting." ) result = nil rescue Relyze::RestartException print_warning( "Plugin '#{self.name}' forcing restart." ) result = nil rescue ::Exception => e print_exception( e ) result = nil end end self.remove_task return result end |
#type ⇒ Object
Get this plugin type.
684 685 686 |
# File 'C:/Program Files/Relyze/lib/relyze/core/plugin.rb', line 684 def type return :loader end |