Sha256: 5f651094d36eca466e719750c7a5710ca0c34df5fd0b73c18322583b34b588da

Contents?: true

Size: 489 Bytes

Versions: 43

Compression:

Stored size: 489 Bytes

Contents

#!/usr/bin/env ruby

# Rex::Struct2
module Rex
module Struct2

# this is a "constant" element.  It's not actually constant, you can set it
# via the constructor and value.  It doesn't do from_s/to_s, etc.

# what use is it? Well it's useful for doing constant restraints (like fix
# sized arrays), and probably not a ton more.

class Constant
	
	require 'rex/struct2/element'
	include Rex::Struct2::Element

	def initialize(value)
		self.value = value
	end

end

# end Rex::Struct2
end
end

Version data entries

43 entries across 43 versions & 1 rubygems

Version Path
librex-0.0.4 lib/rex/struct2/constant.rb
librex-0.0.3 lib/rex/struct2/constant.rb
librex-0.0.1 lib/rex/struct2/constant.rb