Enlightenment CVS committal

Author  : lordchaos
Project : e17
Module  : apps/evfs

Dir     : e17/apps/evfs/src/include


Modified Files:
        Makefile.am evfs.h evfs_commands.h evfs_plugin.h 
        evfs_server_handle.h 
Added Files:
        evfs_client.h evfs_command.h evfs_filereference.h 


Log Message:
* Drastic changes allowing a more generic VFS structure, and also allowing file 
system operations between different file systems. This still needs a lot of 
work, but a basic 'copy' function is already working
* Fixed the non-generic smb-stat problem.  This will still be an issue with 
multiple-client locking, but we'll deal with that later

===================================================================
RCS file: /cvsroot/enlightenment/e17/apps/evfs/src/include/Makefile.am,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -3 -r1.1 -r1.2
--- Makefile.am 11 Oct 2005 00:49:28 -0000      1.1
+++ Makefile.am 16 Oct 2005 10:09:05 -0000      1.2
@@ -8,5 +8,9 @@
                        evfs_macros.h \
                        evfs_new.h \
                        evfs_plugin.h \
-                       evfs_server_handle.h
+                       evfs_server_handle.h \
+                       evfs_filereference.h \
+                       evfs_command.h \
+                       evfs_client.h 
+                       
 
===================================================================
RCS file: /cvsroot/enlightenment/e17/apps/evfs/src/include/evfs.h,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -3 -r1.16 -r1.17
--- evfs.h      9 Oct 2005 10:03:30 -0000       1.16
+++ evfs.h      16 Oct 2005 10:09:05 -0000      1.17
@@ -25,6 +25,7 @@
 #define TRUE 1
 #define URI_SEP "#"
 #define EVFS_META_DIR_NAME  ".e_meta"
+#define COPY_BLOCKSIZE 4096
 #define MAX_CLIENT 9999999
 
 #define EVFS_FUNCTION_MONITOR_START "evfs_monitor_start"
@@ -35,7 +36,7 @@
 #define EVFS_FUNCTION_FILE_STAT_GET "evfs_file_stat_get"
 
 
-
+#include "evfs_plugin.h"
 
 
 typedef enum
@@ -57,63 +58,20 @@
        int num_clients;
 };
 
-typedef enum evfs_file_type evfs_file_type;
-enum evfs_file_type {
-       EVFS_FILE_NORMAL = 1,
-       EVFS_FILE_DIRECTORY = 2
-};
 
 
-typedef struct evfs_filereference evfs_filereference;
-struct evfs_filereference {
-       char* plugin_uri;
-       evfs_file_type file_type;
-       char* path;
-};
 
-typedef struct evfs_file_uri_path evfs_file_uri_path;
-struct evfs_file_uri_path {
-       int num_files;
-       evfs_filereference** files;
-};
 
-/*Command structures*/
-typedef enum evfs_command_type
-{
-  EVFS_CMD_STARTMON_FILE = 1 ,
-  EVFS_CMD_STOPMON_FILE = 2,
-  EVFS_CMD_COPY_FILE = 3,
-  EVFS_CMD_MOVE_FILE = 4,
-  EVFS_CMD_RENAME_FILE = 5,
-  EVFS_CMD_REMOVE_FILE=6,
-  EVFS_CMD_LIST_DIR = 7,
-  EVFS_CMD_FILE_STAT = 8
-}
-evfs_command_type;
 
 
-typedef struct evfs_command_file {
-       evfs_command_type type;
-       int num_files;
-       evfs_filereference** files;
-}
-evfs_command_file;
 
-typedef union evfs_command {
-       evfs_command_type type;
-       evfs_command_file file_command;
-}
-evfs_command;
+
+
+
 
 /*-----------*/
 
 
-typedef struct evfs_client evfs_client;
-struct evfs_client {
-        Ecore_Ipc_Client* client;
-        evfs_command* prog_command;
-       unsigned long id;
-};
 
 
 
@@ -233,7 +191,7 @@
 #include <evfs_new.h>
 #include <evfs_event_helper.h>
 #include <evfs_server_handle.h>
-#include "evfs_plugin.h"
+
 
 evfs_plugin* evfs_get_plugin_for_uri(char* uri_base);
 
===================================================================
RCS file: /cvsroot/enlightenment/e17/apps/evfs/src/include/evfs_commands.h,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -3 -r1.6 -r1.7
--- evfs_commands.h     9 Oct 2005 07:42:17 -0000       1.6
+++ evfs_commands.h     16 Oct 2005 10:09:05 -0000      1.7
@@ -7,6 +7,8 @@
 void evfs_client_file_rename(evfs_connection* conn, evfs_filereference* from, 
evfs_filereference* to);
 void evfs_client_file_stat(evfs_connection* conn, evfs_filereference* file);
 void evfs_client_dir_list(evfs_connection* conn, evfs_filereference* file);
+void evfs_client_file_open(evfs_connection* conn, evfs_filereference* file);
+void evfs_client_file_copy(evfs_connection* conn, evfs_filereference* from, 
evfs_filereference* to);
 
 #endif
 
===================================================================
RCS file: /cvsroot/enlightenment/e17/apps/evfs/src/include/evfs_plugin.h,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -3 -r1.6 -r1.7
--- evfs_plugin.h       11 Oct 2005 00:35:09 -0000      1.6
+++ evfs_plugin.h       16 Oct 2005 10:09:05 -0000      1.7
@@ -1,24 +1,36 @@
 #ifndef __EVFS_PLUGIN_H_
 #define __EVFS_PLUGIN_H_
 
-typedef struct evfs_plugin_functions evfs_plugin_functions;
-struct evfs_plugin_functions {
+#include "evfs_client.h"
+
+typedef struct evfs_plugin_functions {
        int (*evfs_file_remove)(char* path);
        int (*evfs_monitor_start)(evfs_client* client, evfs_command* command);
        int (*evfs_monitor_stop)(evfs_client* client, evfs_command* command);
        int (*evfs_file_rename)(evfs_client* client, evfs_command* command);
-       void (*evfs_file_stat)(evfs_client* client, evfs_command* command);
+       int (*evfs_file_stat)(evfs_command* command, struct stat* file_stat);
        void (*evfs_dir_list)(evfs_client* client, evfs_command* command);
-};
 
-typedef struct evfs_plugin evfs_plugin;
-struct evfs_plugin {
+       int (*evfs_file_open)(evfs_filereference* command);
+       int (*evfs_file_seek)(evfs_filereference* command, long offset, int 
whence);
+       int (*evfs_file_read)(evfs_filereference* command, char* bytes, long 
size);
+       int (*evfs_file_write)(evfs_filereference* command, char* bytes, long 
size);
+       int (*evfs_file_close)(evfs_filereference* command);
+       int (*evfs_file_create)(evfs_filereference* file);
+       
+
+} evfs_plugin_functions;
+
+
+typedef struct evfs_plugin {
        evfs_plugin_functions* functions;
        
        void* dl_ref;
        char* uri;
 
-};
+} evfs_plugin;
+
+
 
 
 #endif
===================================================================
RCS file: 
/cvsroot/enlightenment/e17/apps/evfs/src/include/evfs_server_handle.h,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -3 -r1.5 -r1.6
--- evfs_server_handle.h        9 Oct 2005 07:42:17 -0000       1.5
+++ evfs_server_handle.h        16 Oct 2005 10:09:05 -0000      1.6
@@ -4,3 +4,4 @@
 void evfs_handle_file_rename_command(evfs_client* client, evfs_command* 
command);
 void evfs_handle_file_stat_command(evfs_client* client, evfs_command* command);
 void evfs_handle_dir_list_command(evfs_client* client, evfs_command* command);
+void evfs_handle_file_copy(evfs_client* client, evfs_command* command);




-------------------------------------------------------
This SF.Net email is sponsored by:
Power Architecture Resource Center: Free content, downloads, discussions,
and more. http://solutions.newsforge.com/ibmarch.tmpl
_______________________________________________
enlightenment-cvs mailing list
enlightenment-cvs@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs

Reply via email to