Eiffel Wrapper Generator Library
Copyright (c) 1999, Andreas Leitner and others
Eiffel Forum License v2 (see license.txt)
-- Create a new pointer wrapper to a new memory area where
-- all bytes have been reset to zero.
-- Allocates as a_capacity bytes of new memory.
-- 'unshared' means if the Current object
-- gets collected by the garbage collector,
-- the allocated memory will
-- be freed as well.
-- Create a new pointer wrapper to a new memory area where
-- all bytes have been reset to zero.
-- Allocates as a_capacity bytes of new memory.
-- 'shared' means if the Current object
-- gets collected by the garbage collector,
-- the allocated memory will
-- not be freed as well.
-- Create a new pointer wrapper to a new memory area. Bytes
-- have a random value.
-- Allocates as a_capacity bytes of new memory.
-- 'unshared' means if the Current object
-- gets collected by the garbage collector,
-- the allocated memory will
-- be freed as well.
-- Create a new pointer wrapper to a new memory area. Bytes
-- have a random value.
-- Allocates as a_capacity bytes of new memory.
-- 'shared' means if the Current object
-- gets collected by the garbage collector,
-- the allocated memory will
-- not be freed as well.
-- Create a new pointer wrapper to an existing memory area.
-- a_item must be the pointer to the memory area to wrap.
-- a_capacity specifies how big the memory area is that
-- the pointer points to.
-- 'unshared' means if the Current object
-- gets collected by the garbage collector,
-- the allocated memory will
-- be freed as well.
-- Create a new pointer wrapper to an existing memory area.
-- a_item must be the pointer to the memory area to wrap.
-- a_capacity specifies how big the memory area is that
-- the pointer points to.
-- 'shared' means if the Current object
-- gets collected by the garbage collector,
-- the memory allocated for the struct will
-- not be freed as well.
-- Size of the memory area that the wrapped
-- pointer points to.
-- Is the contents of item referenced by other C or Eiffel code?
-- If is_shared is True then when the current object will be
-- collected by the garbage collector, the wrapped memory area will
-- also be freed.
-- This is a good idea, only if you can be sure that when the
-- Eiffel object gets collected, the C side does not have a reference
-- to the wrapped memory anymore.
-- Wrapped C pointer
-- Get the double at the a_pos-th
-- byte position of the wrapped memory
-- area.
-- Reads sizeof_double bytes.
-- Get the integer at the a_pos-th
-- byte position of the wrapped memory
-- area.
-- Reads sizeof_int bytes.
-- Get the pointer at the a_pos-th
-- byte position of the wrapped memory
-- area.
-- Reads sizeof_pointer bytes.
-- Get the real at the a_pos-th
-- byte position of the wrapped memory
-- area.
-- Reads sizeof_real bytes.
-- Put a_double at the a_pos-th byte position
-- of the wrapped memory area.
-- Writes sizeof_double bytes.
-- Put a_int at the a_pos-th byte position
-- of the wrapped memory area.
-- Writes sizeof_int bytes.
-- Put a_int at the a_pos-th byte position
-- of the wrapped memory area.
-- Writes 32 bits.
-- Put a_pointer at the a_pos-th byte position
-- of the wrapped memory area.
-- Writes sizeof_pointer bytes.
-- Put a_real at the a_pos-th byte position
-- of the wrapped memory area.
-- Writes sizeof_real bytes.
-- Returns the number of bytes a C double is broad
-- Returns the number of bytes a C int is broad
-- Returns the number of bytes a C pointer is broad
-- Returns the number of bytes a C float is broad
Wrapps a C pointer in a safe way