### Home Classes Methods

### In Files

- ext/ffi_c/ffi.c

### Parent

FFI::Struct::InlineArray

### Methods

- #to_s
- #to_str

### Files

- Makefile
- ChangeLog
- LICENSE
- README
- compile
- configure
- depcomp
- stamp-vti
- install-sh
- libtool-version
- mdate-sh
- missing

### Class/Module Index

Quicksearch

- FFI
- FFI::AbstractMemory
- FFI::ArrayType
- FFI::AutoPointer
- FFI::AutoPointer::CallableReleaser
- FFI::AutoPointer::DefaultReleaser
- FFI::AutoPointer::Releaser
- FFI::ConstGenerator
- FFI::ConstGenerator::Constant
- FFI::DynamicLibrary
- FFI::DynamicLibrary::Symbol
- FFI::Enum
- FFI::Enums
- FFI::FunctionType
- FFI::Generator
- FFI::Generator::Task
- FFI::IO
- FFI::LastError
- FFI::Library
- FFI::ManagedStruct
- FFI::NotFoundError
- FFI::NullPointerError
- FFI::Platform
- FFI::PlatformError
- FFI::Pointer
- FFI::StrPtrConverter
- FFI::Struct
- FFI::Struct::InlineArray
- FFI::Struct::ManagedStructConverter
- FFI::StructByReference
- FFI::StructByValue
- FFI::StructGenerator
- FFI::StructGenerator::Field
- FFI::StructLayout
- FFI::StructLayout::Array
- FFI::StructLayout::CharArray
- FFI::StructLayout::Enum
- FFI::StructLayout::Field
- FFI::StructLayout::Function
- FFI::StructLayout::InnerStruct
- FFI::StructLayout::Mapped
- FFI::StructLayout::Number
- FFI::StructLayout::Pointer
- FFI::StructLayout::String
- FFI::StructLayoutBuilder
- FFI::TypesGenerator
- FFI::Union
- FFI::VariadicInvoker

No matching classes.

# FFI::StructLayout::CharArray

### Public Instance Methods

to_s click to toggle source
@return [String]
Convert +self+ to a string.

    static VALUE
    inline_array_to_s(VALUE self)
    {
        InlineArray* array;
        VALUE argv[2];

        Data_Get_Struct(self, InlineArray, array);

        if (array->componentType->nativeType != NATIVE_INT8 && array->componentType->nativeType != NATIVE_UINT8) {
            VALUE dummy = Qnil;
            return rb_call_super(0, &dummy);
        }

        argv[0] = UINT2NUM(array->field->offset);
        argv[1] = UINT2NUM(array->length);

        return rb_funcall2(array->rbMemory, rb_intern("get_string"), 2, argv);
    }

Also aliased as: to_str
to_str() click to toggle source
Alias for: to_s

[Validate]

Generated with the Darkfish Rdoc Generator 2.