lib/ronin/arch.rb in ronin-1.0.0 vs lib/ronin/arch.rb in ronin-1.1.0.rc1

- old
+ new

@@ -59,16 +59,18 @@ # address_length # # => 4 # # @since 1.0.0 # + # @api public + # def to_ary [self.endian, self.address_length] end # - # Defines a new predefined Arch. + # Defines a new pre-defined Arch. # # @param [Symbol, String] name # The name of the architecture. # # @param [Hash] options @@ -78,32 +80,25 @@ # The endianness of the architecture. # # @option options [Integer] :address_length # The address-length of the architecture. # - # @example Defining a predefined Arch + # @example Defining a pre-defined Arch # Arch.predefine :alpha, :endian => :big, :address_length => 8 # - # @example Retrieving a predefined Arch + # @example Retrieving a pre-defined Arch # Arch.alpha # + # @api private + # def self.predefine(name,options={}) super(name,options.merge(:name => name)) end - # The i386 Architecture - predefine :i386, :endian => :little, :address_length => 4 + # The x86 Architecture + predefine :x86, :endian => :little, :address_length => 4 - # The i486 Architecture - predefine :i486, :endian => :little, :address_length => 4 - - # The i686 Architecture - predefine :i686, :endian => :little, :address_length => 4 - - # The i986 Architecture - predefine :i986, :endian => :little, :address_length => 4 - # The x86_64 Architecture predefine :x86_64, :endian => :little, :address_length => 8 # The ia64 Architecture predefine :ia64, :endian => :little, :address_length => 8 @@ -129,8 +124,38 @@ # The ARM (little-endian) Architecture predefine :arm_le, :endian => :little, :address_length => 4 # The ARM (big-endian) Architecture predefine :arm_be, :endian => :big, :address_length => 4 + + # + # @see x86 + # + def self.i386; x86; end + + # + # @see x86 + # + def self.i486; x86; end + + # + # @see x86 + # + def self.i686; x86; end + + # + # @see x86 + # + def self.i986; x86; end + + # + # @see mips_be + # + def self.mips; mips_be; end + + # + # @see arm_be + # + def self.arm; arm_be; end end end