Commit Graph

63 Commits

Author SHA1 Message Date
Gustavo Sverzut Barbieri 7c0357ddeb welcome eina_model.
This is a simple to use generic hierarchical data access. It includes
properties, children, reference counting and notifications (callbacks).

It can be understood in the same lines as GObject or PyObject, but I
believe the best usage is just to provide data models, not generic
Object Oriented Programming in C.

It misses most of documentation, although the important bits are
there. Need help here :-/



SVN revision: 67405
2012-01-21 01:30:09 +00:00
Vincent Torri 9a76004770 Eina: Fix compilation of eina_semaphore_lock() (Windows port)
Patch by Shinwoo Kim


SVN revision: 67317
2012-01-19 06:33:42 +00:00
Gustavo Sverzut Barbieri c502186b3d make bastards happy
SVN revision: 67083
2012-01-11 14:06:07 +00:00
Gustavo Sverzut Barbieri 7a4e904566 add eina_value.
eina value is a generic value storage, it's quite efficient to space
(16 bytes) and speed (inlines for basic types).

It's basically a structure describing how to manage memory
(Eina_Value_Type), with default implementation for char, short, int,
long, int64_t (and unsigned variants), float, double, stringshare and
string.

If a type 'value_size' is smaller than 8 bytes, it's stored
inline. Otherwise a value is allocated and managed.

Most of the methods are inline, with special handling for char, short,
int... Then no extra calls are made, allowing the compiler to optimize
them.

For array of a single type it is recommend to use Eina_Value_Array, as
it will efficiently store and access members (just a char if subtype
is EINA_VALUE_TYPE_CHAR, etc).

It can copy itself, compare itself. Including arrays.

It would be nice to have something that converts between EET and this.



SVN revision: 67035
2012-01-11 02:20:26 +00:00
Gustavo Sverzut Barbieri 45b07ed02d add eina_inarray.
It is an inline array, that is, the members are actually in the
allocated buffer, as opposed to a pointer to its data.

It can be used to manage array of integers, floats or other structures
without fragmenting memory.

The lookups should be fast as memory is linear, then CPU prefetch can
kick in and bring data to cache before it's used.



SVN revision: 67003
2012-01-09 23:24:18 +00:00
Cedric BAIL edbee63134 eina: detect fault during Eina_File mmap memory access and improve Xattr functions.
SVN revision: 66799
2012-01-03 14:59:07 +00:00
Cedric BAIL fa3ca325d3 eina: let eina_hash_free behave like free.
SVN revision: 66694
2011-12-30 13:41:37 +00:00
Cedric BAIL d92a903ffe eina: add Eina_Semaphore API.
Patch by Vincent Torri.


SVN revision: 66693
2011-12-30 13:38:53 +00:00
Cedric BAIL d42f1a957c eina: forgotten ChangeLog update in trunk.
SVN revision: 66635
2011-12-29 14:03:42 +00:00
Cedric BAIL 4d01164eb6 eina: forgotten ChangeLog.
SVN revision: 66384
2011-12-20 11:09:53 +00:00
Tom Hacohen 66b3c08aff Eina bin/(u)strbuf: Added eina_*buf_manage_new_length.
Same as eina_*buf_manage_new except for the length parameter.

SVN revision: 66028
2011-12-08 13:10:57 +00:00
Mike Blumenkrantz 8ada55917a fix eina_log*level_check() to return the value that the docs claim will be returned
how did nobody catch this sooner?


SVN revision: 66013
2011-12-08 04:11:54 +00:00
Carsten Haitzler ac4c70ab7b fix changelogs to mention release.
SVN revision: 65860
2011-12-04 01:56:31 +00:00
Mike Blumenkrantz afdbaf8651 +eina_mempool_calloc
SVN revision: 65821
2011-12-02 15:27:35 +00:00
Boris Faure 15f0f3e044 eina: update news/changelog
SVN revision: 65268
2011-11-15 14:24:53 +00:00
Cedric BAIL 0c6ed213ad eina: add eina_xattr.{c,h}.
SVN revision: 63412
2011-09-15 15:37:28 +00:00
Tom Hacohen 98b5aa4b36 Eina (u)strbuf: Added eina_(u)strbuf_manage_new.
This lets us take a string and use it as the string buffer instead of
copying and allocating.

SVN revision: 63226
2011-09-06 10:58:53 +00:00
Cedric BAIL 6936745755 eina: add eina_inlist_sorted_state_insert and helper.
Note: this function help keep a jump table so we reduce
the need to walk over the complete list to insert one
element. It's of course doesn't make it an O(log(n)) in
access time, but it increase it's cost more slowly.
   With 10000 items, you can count around 50 pointers
dereferencing and with with 50000 items around 200 pointers
dereferencing.
   Of course the comparison stay in O(log(n)).


SVN revision: 63213
2011-09-05 20:15:12 +00:00
Carsten Haitzler 3705bda72b oooooh wowo! that prefix change broke stuff1 it looks ok on elm. revert!
SVN revision: 62813
2011-08-25 12:13:16 +00:00
Jérémy Zurcher c5606319d9 From: Jérémy Zurcher <jeremy@asynk.ch>
Subject: [E-devel] patch : eina_prefix + elementary_test

please find attached a small patch for eina_prefix

it prevent segfault when for instance
no elm_app_compile_*_dir_set is called prior to elm_app_info_set

and another one for elementary/src/bin/test*.c which tends to replace
usage of PACKAGE_DATA_DIR with elm_app_data_dir_get



SVN revision: 62795
2011-08-25 10:01:22 +00:00
Cedric BAIL 5a42968177 eina: fix eina_share_common_ref/del
patch by Myungjae Lee <mjae.lee@samsung.com>.


SVN revision: 62051
2011-08-03 12:00:46 +00:00
Cedric BAIL 2b574523d2 eina: add eina_main_loop_is.
SVN revision: 61896
2011-07-29 14:56:42 +00:00
Carsten Haitzler d926889559 add eina mmap safety handling.
SVN revision: 60976
2011-07-04 09:29:59 +00:00
Cedric BAIL a5fe2772c7 eina: add Eina_LockRW. more refactoring code comming.
SVN revision: 60628
2011-06-23 09:58:54 +00:00
Cedric BAIL c2d99295bd eina: rename eina_hash_free_set as eina_hash_free_cb_set.
SVN revision: 60439
2011-06-17 09:49:15 +00:00
Cedric BAIL eb976c2571 eina: disabling Eina_Object until 1.1 is released.
SVN revision: 60427
2011-06-17 08:48:02 +00:00
Cedric BAIL 7decbe6825 eina: +eina_hash_free_set.
SVN revision: 60354
2011-06-15 15:46:10 +00:00
Vincent Torri 3d4c2fb340 Eina: fix static linking with eina
Fix static linking with eina (iconv could potentially not be
passed to the linker)



SVN revision: 59914
2011-06-03 07:46:15 +00:00
Cedric BAIL a0ea6c5130 eina: fix eina_hash_set to act when data == NULL like eina_hash_del.
SVN revision: 59849
2011-05-31 16:43:40 +00:00
Cedric BAIL bc0e734f93 eina: add eina_condition_timedwait.
SVN revision: 59819
2011-05-30 15:24:06 +00:00
Cedric BAIL cde3148eca eina: add eina_inlist_sorted_insert.
SVN revision: 59654
2011-05-24 15:17:56 +00:00
Vincent Torri 9f2ac8d7e3 Eina: Implement eina_sched_prio_drop() on Windows
SVN revision: 59637
2011-05-24 06:29:58 +00:00
Cedric BAIL 42e460e3b6 eina: fix eina_share_common_init.
SVN revision: 59485
2011-05-18 07:56:11 +00:00
Tom Hacohen 8ca233f8cb Eina binbuf: Added eina_binbuff an auto resizing binary buffer.
SVN revision: 59468
2011-05-17 15:45:39 +00:00
Vincent Torri 4a6a5bd213 i'm not cedric
SVN revision: 59392
2011-05-14 21:23:03 +00:00
Vincent Torri 65892e65b7 Eina : eina_lock : make it compile on Windows
SVN revision: 59391
2011-05-14 21:19:36 +00:00
Cedric BAIL f97a64ca03 eina: Add refcounting macro helper.
SVN revision: 59038
2011-04-29 16:09:07 +00:00
Vincent Torri a288cd7af1 Eina: Fix static build of the buddy mempool
SVN revision: 58974
2011-04-27 17:00:36 +00:00
Vincent Torri 6acc7bce24 fix date
SVN revision: 58861
2011-04-24 09:14:12 +00:00
Vincent Torri 694a364ced Eina: Fix uninstallation of the mempools modules
SVN revision: 58859
2011-04-24 09:11:11 +00:00
Carsten Haitzler d576cdc68a chlog++
SVN revision: 58849
2011-04-24 07:35:52 +00:00
Vincent Torri 6e8d19b150 Eina: Add Eina_Lock API
Eina_Lock API is a small set of functions to manage in a
cross platform way mutual exclusion objects



SVN revision: 58835
2011-04-22 21:26:36 +00:00
Cedric BAIL 8a8153bf2d eina: add Eina_File API.
NOTE: the purpose of this API is to replace mmap user in the
EFL, share cache and more code across them. The potential user
are eet, evas, efreet, eio and enlil. More patch are needed for
them to use this infra. Help welcome :-)

NOTE2: this API also need more test and is waiting for some
more pthread infra before being thread safe. But at the end
it will be thread safe if eina thread safety is requested.


SVN revision: 58637
2011-04-13 16:15:30 +00:00
Cedric BAIL 8b276b36c7 eina: add Eina_Object API.
This API is what could be used by all EFL library for their exposed
type (Evas_Object, Ecore_Timer, Ecore_Animator, Eio_File, ...). The
purpose of Eina_Object is to provide an "obscure" pointer that is
infact an ID with a generation count that will never be dereferenced
directly.
   This provide the benefit of always accessing a living object
with 1/256 chance to being the expected generation of it, that will
always be of the right type.
   It also provide asynchronous repacking ability (still highly
inefficient, but not really hard to improve), simple inheritance
with constructor/destructor and link between object.

All this implementation is highly open for comment, idea, review,
fix and change. I didn't got the time to write a sample test right
now. Maybe will come tomorrow. Same for docs.



SVN revision: 58562
2011-04-11 18:00:34 +00:00
Cedric BAIL 29639eea35 eina: add eina_mempool_repack.
WARNING: HIGHLY UNTESTED PIECE OF CODE ! USE IT AT YOUR OWN RISK !


SVN revision: 58554
2011-04-11 14:07:42 +00:00
Cedric BAIL ca83ca2ff4 eina: add eina_inlist_sort (merge sort based on eina_list code).
SVN revision: 58540
2011-04-11 09:55:27 +00:00
Cedric BAIL 30fda98e76 eina: add Eina_Simple_Xml parser by Gustavo.
TODO: fix docs (but today, eina doc need some love again)
      use iconv and handle encoding (can get entity-to-utf8 from evas)
      description of what to do at :
http://marc.info/?l=enlightenment-devel&m=129975452006699&w=3

NOTE: this mean this API is not stable yet and will be broken soon.


SVN revision: 58387
2011-04-06 10:14:03 +00:00
Mike Blumenkrantz f0ff4ed477 +EAPI Eina_Error eina_error_find(const char *msg)
SVN revision: 57863
2011-03-19 00:07:23 +00:00
Mike Blumenkrantz bb5a5a5ab4 use stringshare in eina_error
the only restriction here is that eina_error_msg_register cannot be used internally by eina prior to stringshare init, but since this does not happen currently there is no problem :)


SVN revision: 57861
2011-03-18 22:02:03 +00:00
Cedric BAIL e8ca19f09c eina: fix stat failure when size, blocks count or serial number didn't
fit in 32bits.


SVN revision: 57624
2011-03-09 14:49:35 +00:00