summaryrefslogtreecommitdiff
path: root/src/lib/eio
diff options
context:
space:
mode:
authorCedric BAIL <cedric@osg.samsung.com>2018-04-18 11:22:48 -0700
committerCedric BAIL <cedric@osg.samsung.com>2018-04-30 14:21:12 -0700
commitbba8fbe4495e3911284805c8ae93fbf186145e60 (patch)
tree8cb17b3e93a917d6148b237684acc1b183975fc6 /src/lib/eio
parent202f433476c80c3c2a013038fb39ffc1a775b34f (diff)
eio: improve efl.io.manager API by being const when not touching the object.
Diffstat (limited to 'src/lib/eio')
-rw-r--r--src/lib/eio/efl_io_manager.c14
-rw-r--r--src/lib/eio/efl_io_manager.eo18
2 files changed, 16 insertions, 16 deletions
diff --git a/src/lib/eio/efl_io_manager.c b/src/lib/eio/efl_io_manager.c
index cee58c873e..d350331bc2 100644
--- a/src/lib/eio/efl_io_manager.c
+++ b/src/lib/eio/efl_io_manager.c
@@ -108,7 +108,7 @@ _future_file_info_cb(void *data EINA_UNUSED, Eio_File *handler, Eina_Array *gath
108 108
109/* Method implementations */ 109/* Method implementations */
110static Eina_Future * 110static Eina_Future *
111_efl_io_manager_direct_ls(Eo *obj, 111_efl_io_manager_direct_ls(const Eo *obj,
112 Efl_Io_Manager_Data *pd EINA_UNUSED, 112 Efl_Io_Manager_Data *pd EINA_UNUSED,
113 const char *path, 113 const char *path,
114 Eina_Bool recursive, 114 Eina_Bool recursive,
@@ -151,7 +151,7 @@ _efl_io_manager_direct_ls(Eo *obj,
151} 151}
152 152
153static Eina_Future * 153static Eina_Future *
154_efl_io_manager_stat_ls(Eo *obj, 154_efl_io_manager_stat_ls(const Eo *obj,
155 Efl_Io_Manager_Data *pd EINA_UNUSED, 155 Efl_Io_Manager_Data *pd EINA_UNUSED,
156 const char *path, 156 const char *path,
157 Eina_Bool recursive, 157 Eina_Bool recursive,
@@ -194,7 +194,7 @@ _efl_io_manager_stat_ls(Eo *obj,
194} 194}
195 195
196static Eina_Future * 196static Eina_Future *
197_efl_io_manager_ls(Eo *obj, 197_efl_io_manager_ls(const Eo *obj,
198 Efl_Io_Manager_Data *pd EINA_UNUSED, 198 Efl_Io_Manager_Data *pd EINA_UNUSED,
199 const char *path, 199 const char *path,
200 void *paths_data, EflIoPath paths, Eina_Free_Cb paths_free_cb) 200 void *paths_data, EflIoPath paths, Eina_Free_Cb paths_free_cb)
@@ -247,7 +247,7 @@ _file_stat_done_cb(void *data, Eio_File *handle EINA_UNUSED, const Eina_Stat *st
247} 247}
248 248
249static Eina_Future * 249static Eina_Future *
250_efl_io_manager_stat(Eo *obj, 250_efl_io_manager_stat(const Eo *obj,
251 Efl_Io_Manager_Data *pd EINA_UNUSED, 251 Efl_Io_Manager_Data *pd EINA_UNUSED,
252 const char *path) 252 const char *path)
253{ 253{
@@ -275,7 +275,7 @@ _efl_io_manager_stat(Eo *obj,
275/* eXtended attribute manipulation */ 275/* eXtended attribute manipulation */
276 276
277static Eina_Future * 277static Eina_Future *
278_efl_io_manager_xattr_ls(Eo *obj, 278_efl_io_manager_xattr_ls(const Eo *obj,
279 Efl_Io_Manager_Data *pd EINA_UNUSED, 279 Efl_Io_Manager_Data *pd EINA_UNUSED,
280 const char *path, 280 const char *path,
281 void *paths_data, EflIoPath paths, Eina_Free_Cb paths_free_cb) 281 void *paths_data, EflIoPath paths, Eina_Free_Cb paths_free_cb)
@@ -395,7 +395,7 @@ _future_file_open_cb(void *data, Eio_File *handler EINA_UNUSED, Eina_File *file)
395} 395}
396 396
397static Eina_Future * 397static Eina_Future *
398_efl_io_manager_open(Eo *obj, 398_efl_io_manager_open(const Eo *obj,
399 Efl_Io_Manager_Data *pd EINA_UNUSED, 399 Efl_Io_Manager_Data *pd EINA_UNUSED,
400 const char *path, 400 const char *path,
401 Eina_Bool shared) 401 Eina_Bool shared)
@@ -422,7 +422,7 @@ _efl_io_manager_open(Eo *obj,
422} 422}
423 423
424static Eina_Future * 424static Eina_Future *
425_efl_io_manager_close(Eo *obj, 425_efl_io_manager_close(const Eo *obj,
426 Efl_Io_Manager_Data *pd EINA_UNUSED, 426 Efl_Io_Manager_Data *pd EINA_UNUSED,
427 Eina_File *file) 427 Eina_File *file)
428{ 428{
diff --git a/src/lib/eio/efl_io_manager.eo b/src/lib/eio/efl_io_manager.eo
index 030ef95052..6267fa230c 100644
--- a/src/lib/eio/efl_io_manager.eo
+++ b/src/lib/eio/efl_io_manager.eo
@@ -26,18 +26,18 @@ class Efl.Io.Manager (Efl.Loop_Consumer)
26 [[Class representing an asynchronous file operation.]] 26 [[Class representing an asynchronous file operation.]]
27 27
28 methods { 28 methods {
29 ls { 29 ls @const {
30 [[Lists entries in a given path. 30 [[Lists entries in a given path.
31 See \@ref eina_file_ls(). 31 See \@ref eina_file_ls().
32 ]] 32 ]]
33 params { 33 params {
34 @in path: string; [[Path we want to list entries for]] 34 @in path: string; [[Path we want to list entries for]]
35 paths: EflIoPath; [[Callback called for each packet of files found]] 35 paths: EflIoPath; [[Callback called for each packet of files found]]
36 } 36 }
37 return: ptr(Eina.Future) @owned; [[Amount of files found during the listing of the directory]] 37 return: ptr(Eina.Future) @owned; [[Amount of files found during the listing of the directory]]
38 } 38 }
39 39
40 direct_ls { 40 direct_ls @const {
41 [[Lists entries in a given path with more information.]] 41 [[Lists entries in a given path with more information.]]
42 params { 42 params {
43 @in path: string;[[Path we want to list entries for]] 43 @in path: string;[[Path we want to list entries for]]
@@ -47,7 +47,7 @@ class Efl.Io.Manager (Efl.Loop_Consumer)
47 return: ptr(Eina.Future) @owned; [[Amount of files found during the listing of the directory]] 47 return: ptr(Eina.Future) @owned; [[Amount of files found during the listing of the directory]]
48 } 48 }
49 49
50 stat_ls { 50 stat_ls @const {
51 [[Lists entries in a given path with stat information.]] 51 [[Lists entries in a given path with stat information.]]
52 params { 52 params {
53 @in path: string;[[Path we want to list entries for]] 53 @in path: string;[[Path we want to list entries for]]
@@ -58,16 +58,16 @@ class Efl.Io.Manager (Efl.Loop_Consumer)
58 } 58 }
59 59
60 // Extended attributes 60 // Extended attributes
61 xattr_ls { 61 xattr_ls @const {
62 [[Lists all extended attributes asynchronously.]] 62 [[Lists all extended attributes asynchronously.]]
63 params { 63 params {
64 @in path: string; [[Path we want to list entries for]] 64 @in path: string; [[Path we want to list entries for]]
65 paths: EflIoPath; [[Callback called for each packet of extended attributes found.]] 65 paths: EflIoPath; [[Callback called for each packet of extended attributes found.]]
66 } 66 }
67 return: ptr(Eina.Future) @owned; [[Amount of extended attributes found]] 67 return: ptr(Eina.Future) @owned; [[Amount of extended attributes found]]
68 } 68 }
69 69
70 stat { 70 stat @const {
71 [[Get stat info on a given file/directory.]] 71 [[Get stat info on a given file/directory.]]
72 params { 72 params {
73 @in path: string; [[Path we want to get stat information for]] 73 @in path: string; [[Path we want to get stat information for]]
@@ -95,7 +95,7 @@ class Efl.Io.Manager (Efl.Loop_Consumer)
95 } 95 }
96 96
97 // helper api 97 // helper api
98 open { 98 open @const {
99 [[Opens a file. 99 [[Opens a file.
100 100
101 The fulfilled value in the promise will be the Eina.File*.]] 101 The fulfilled value in the promise will be the Eina.File*.]]
@@ -105,7 +105,7 @@ class Efl.Io.Manager (Efl.Loop_Consumer)
105 } 105 }
106 return: ptr(Eina.Future) @owned; [[Eina file handle]] 106 return: ptr(Eina.Future) @owned; [[Eina file handle]]
107 } 107 }
108 close { 108 close @const {
109 [[Closes an open Eina.File.]] 109 [[Closes an open Eina.File.]]
110 params { 110 params {
111 @in file: ptr(Eina.File); [[Eina file handle]] 111 @in file: ptr(Eina.File); [[Eina file handle]]