-code hygene
[oweals/gnunet.git] / src / include / gnunet_fs_service.h
index a13c3b91c110f345afb21dce78fc250e6b4ea392..f50166d326279aaf29ad458d4f1d583f00275a02 100644 (file)
@@ -337,7 +337,7 @@ GNUNET_FS_uri_test_sks (const struct GNUNET_FS_Uri *uri);
  * @return an FS URI for the given namespace and identifier
  */
 struct GNUNET_FS_Uri *
-GNUNET_FS_uri_sks_create (const struct GNUNET_CRYPTO_EccPublicSignKey *ns,
+GNUNET_FS_uri_sks_create (const struct GNUNET_CRYPTO_EcdsaPublicKey *ns,
                          const char *id);
 
 
@@ -351,7 +351,7 @@ GNUNET_FS_uri_sks_create (const struct GNUNET_CRYPTO_EccPublicSignKey *ns,
  */
 int
 GNUNET_FS_uri_sks_get_namespace (const struct GNUNET_FS_Uri *uri,
-                                 struct GNUNET_CRYPTO_EccPublicSignKey *pseudonym);
+                                 struct GNUNET_CRYPTO_EcdsaPublicKey *pseudonym);
 
 
 /**
@@ -685,7 +685,13 @@ enum GNUNET_FS_Status
    * Notification that the unindexing of this file
    * was stopped (final event for this action).
    */
-  GNUNET_FS_STATUS_UNINDEX_STOPPED = 36
+  GNUNET_FS_STATUS_UNINDEX_STOPPED = 36,
+
+  /**
+   * Notification that we are making progress sharing a directory.
+   */
+  GNUNET_FS_STATUS_PUBLISH_PROGRESS_DIRECTORY = 37
+
 };
 
 
@@ -842,6 +848,33 @@ struct GNUNET_FS_ProgressInfo
 
         } progress;
 
+        /**
+        * These values are only valid for
+        * #GNUNET_FS_STATUS_PUBLISH_PROGRESS_DIRECTORY events.
+        */
+        struct
+        {
+
+          /**
+          * How far are we along in the overall directory?
+          */
+          uint64_t completed;
+
+          /**
+          * How big do we estimate the entire directory to be?
+          */
+          uint64_t total;
+
+          /**
+           * At what time do we expect to finish the upload of the
+           * CONTENTS of the directory. (The direcory itself will take
+           * extra time, indicated with the "eta" member at the
+           * "publish"-level of this struct.)
+           */
+          struct GNUNET_TIME_Relative eta;
+
+        } progress_directory;
+
         /**
         * These values are only valid for
         * #GNUNET_FS_STATUS_PUBLISH_RESUME events.
@@ -1377,7 +1410,7 @@ struct GNUNET_FS_ProgressInfo
           /**
           * Public key of the namespace.
           */
-          struct GNUNET_CRYPTO_EccPublicSignKey pseudonym;
+          struct GNUNET_CRYPTO_EcdsaPublicKey pseudonym;
 
         } ns;
 
@@ -1962,7 +1995,7 @@ enum GNUNET_FS_PublishOptions
 struct GNUNET_FS_PublishContext *
 GNUNET_FS_publish_start (struct GNUNET_FS_Handle *h,
                          struct GNUNET_FS_FileInformation *fi,
-                         const struct GNUNET_CRYPTO_EccPrivateKey *ns,
+                         const struct GNUNET_CRYPTO_EcdsaPrivateKey *ns,
                         const char *nid,
                          const char *nuid,
                          enum GNUNET_FS_PublishOptions options);
@@ -2054,7 +2087,7 @@ struct GNUNET_FS_PublishSksContext;
  */
 struct GNUNET_FS_PublishSksContext *
 GNUNET_FS_publish_sks (struct GNUNET_FS_Handle *h,
-                       const struct GNUNET_CRYPTO_EccPrivateKey *ns,
+                       const struct GNUNET_CRYPTO_EcdsaPrivateKey *ns,
                        const char *identifier,
                       const char *update,
                        const struct GNUNET_CONTAINER_MetaData *meta,
@@ -2176,7 +2209,7 @@ typedef void (*GNUNET_FS_IdentifierProcessor) (void *cls,
  */
 void
 GNUNET_FS_namespace_list_updateable (struct GNUNET_FS_Handle *h,
-                                    const struct GNUNET_CRYPTO_EccPrivateKey *ns,
+                                    const struct GNUNET_CRYPTO_EcdsaPrivateKey *ns,
                                      const char *next_id,
                                      GNUNET_FS_IdentifierProcessor ip,
                                      void *ip_cls);