Class: FFIGen::PointerType
- Defined in:
- lib/ffi_gen.rb,
lib/ffi_gen/java_output.rb,
lib/ffi_gen/ruby_output.rb
Instance Attribute Summary collapse
-
#depth ⇒ Object
readonly
Returns the value of attribute depth.
-
#pointee_name ⇒ Object
readonly
Returns the value of attribute pointee_name.
Instance Method Summary collapse
-
#initialize(pointee_name, depth) ⇒ PointerType
constructor
A new instance of PointerType.
- #java_description ⇒ Object
- #java_jna_type ⇒ Object
- #java_name ⇒ Object
- #name ⇒ Object
- #ruby_description ⇒ Object
- #ruby_ffi_type ⇒ Object
- #ruby_name ⇒ Object
Constructor Details
#initialize(pointee_name, depth) ⇒ PointerType
Returns a new instance of PointerType.
235 236 237 238 |
# File 'lib/ffi_gen.rb', line 235 def initialize(pointee_name, depth) @pointee_name = pointee_name @depth = depth end |
Instance Attribute Details
#depth ⇒ Object (readonly)
Returns the value of attribute depth.
233 234 235 |
# File 'lib/ffi_gen.rb', line 233 def depth @depth end |
#pointee_name ⇒ Object (readonly)
Returns the value of attribute pointee_name.
233 234 235 |
# File 'lib/ffi_gen.rb', line 233 def pointee_name @pointee_name end |
Instance Method Details
#java_description ⇒ Object
248 249 250 |
# File 'lib/ffi_gen/java_output.rb', line 248 def java_description "FFI::Pointer(#{'*' * @depth}#{@pointee_name ? @pointee_name.to_java_classname : ''})" end |
#java_jna_type ⇒ Object
244 245 246 |
# File 'lib/ffi_gen/java_output.rb', line 244 def java_jna_type "Pointer" end |
#java_name ⇒ Object
240 241 242 |
# File 'lib/ffi_gen/java_output.rb', line 240 def java_name @pointee_name.to_java_downcase end |
#name ⇒ Object
240 241 242 |
# File 'lib/ffi_gen.rb', line 240 def name @pointee_name end |
#ruby_description ⇒ Object
269 270 271 |
# File 'lib/ffi_gen/ruby_output.rb', line 269 def ruby_description "FFI::Pointer(#{'*' * @depth}#{@pointee_name ? @pointee_name.to_ruby_classname : ''})" end |
#ruby_ffi_type ⇒ Object
265 266 267 |
# File 'lib/ffi_gen/ruby_output.rb', line 265 def ruby_ffi_type ":pointer" end |
#ruby_name ⇒ Object
261 262 263 |
# File 'lib/ffi_gen/ruby_output.rb', line 261 def ruby_name @pointee_name.to_ruby_downcase end |