Author: julianfoad
Date: Mon Feb 26 09:28:54 2018
New Revision: 1825348
URL: http://svn.apache.org/viewvc?rev=1825348&view=rev
Log:
Shelving: make the revprop get/set API public.
There was no strong reason why it was private, and now I have a client
interested in calling it.
* subversion/include/svn_client.h
(svn_client_shelf_revprop_set,
svn_client_shelf_revprop_get,
svn_client_shelf_revprop_list): Rename and move to here...
* subversion/libsvn_client/client.h,
subversion/libsvn_client/shelf.c
(svn_client__shelf_revprop_set,
svn_client__shelf_revprop_get,
svn_client__shelf_revprop_list): ... from here.
Modified:
subversion/trunk/subversion/include/svn_client.h
subversion/trunk/subversion/libsvn_client/client.h
subversion/trunk/subversion/libsvn_client/shelf.c
Modified: subversion/trunk/subversion/include/svn_client.h
URL:
http://svn.apache.org/viewvc/subversion/trunk/subversion/include/svn_client.h?rev=1825348&r1=1825347&r2=1825348&view=diff
==============================================================================
--- subversion/trunk/subversion/include/svn_client.h (original)
+++ subversion/trunk/subversion/include/svn_client.h Mon Feb 26 09:28:54 2018
@@ -7024,6 +7024,57 @@ svn_client_shelf_paths_changed(apr_hash_
apr_pool_t *result_pool,
apr_pool_t *scratch_pool);
+/** Set @a shelf's revprop @a prop_name to @a prop_val.
+ *
+ * This can be used to set or change the shelf's log message
+ * (property name "svn:log" or #SVN_PROP_REVISION_LOG).
+ *
+ * If @a prop_val is NULL, delete the property (if present).
+ *
+ * @since New in 1.X.
+ * @warning EXPERIMENTAL.
+ */
+SVN_EXPERIMENTAL
+svn_error_t *
+svn_client_shelf_revprop_set(svn_client_shelf_t *shelf,
+ const char *prop_name,
+ const svn_string_t *prop_val,
+ apr_pool_t *scratch_pool);
+
+/** Get @a shelf's revprop @a prop_name into @a *prop_val.
+ *
+ * If the property is not present, set @a *prop_val to NULL.
+ *
+ * This can be used to get the shelf's log message
+ * (property name "svn:log" or #SVN_PROP_REVISION_LOG).
+ *
+ * The lifetime of the result is limited to that of @a shelf and/or
+ * of @a result_pool.
+ *
+ * @since New in 1.X.
+ * @warning EXPERIMENTAL.
+ */
+SVN_EXPERIMENTAL
+svn_error_t *
+svn_client_shelf_revprop_get(svn_string_t **prop_val,
+ svn_client_shelf_t *shelf,
+ const char *prop_name,
+ apr_pool_t *result_pool);
+
+/** Get @a shelf's revprops into @a props.
+ *
+ * The lifetime of the result is limited to that of @a shelf and/or
+ * of @a result_pool.
+ *
+ * @since New in 1.X.
+ * @warning EXPERIMENTAL.
+ */
+SVN_EXPERIMENTAL
+svn_error_t *
+svn_client_shelf_revprop_list(apr_hash_t **props,
+ svn_client_shelf_t *shelf,
+ apr_pool_t *result_pool);
+
/** Set the log message in @a shelf, using the log message callbacks in
* the client context, and set other revprops to @a revprop_table.
*
Modified: subversion/trunk/subversion/libsvn_client/client.h
URL:
http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_client/client.h?rev=1825348&r1=1825347&r2=1825348&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_client/client.h (original)
+++ subversion/trunk/subversion/libsvn_client/client.h Mon Feb 26 09:28:54 2018
@@ -1250,39 +1250,6 @@ svn_client__merge_locked(svn_client__con
apr_pool_t *result_pool,
apr_pool_t *scratch_pool);
-/** Set @a shelf's revprop @a prop_name to @a prop_val.
- *
- * If @a prop_val is NULL, delete the property (if present).
- */
-svn_error_t *
-svn_client__shelf_revprop_set(svn_client_shelf_t *shelf,
- const char *prop_name,
- const svn_string_t *prop_val,
- apr_pool_t *scratch_pool);
-
-/** Get @a shelf's revprop @a prop_name into @a *prop_val.
- *
- * If the property is not present, set @a *prop_val to NULL.
- *
- * The lifetime of the result is limited to that of @a shelf and/or
- * of @a result_pool.
- */
-svn_error_t *
-svn_client__shelf_revprop_get(svn_string_t **prop_val,
- svn_client_shelf_t *shelf,
- const char *prop_name,
- apr_pool_t *result_pool);
-
-/** Get @a shelf's revprops into @a props.
- *
- * The lifetime of the result is limited to that of @a shelf and/or
- * of @a result_pool.
- */
-svn_error_t *
-svn_client__shelf_revprop_list(apr_hash_t **props,
- svn_client_shelf_t *shelf,
- apr_pool_t *result_pool);
-
#ifdef __cplusplus
}
#endif /* __cplusplus */
Modified: subversion/trunk/subversion/libsvn_client/shelf.c
URL:
http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_client/shelf.c?rev=1825348&r1=1825347&r2=1825348&view=diff
==============================================================================
--- subversion/trunk/subversion/libsvn_client/shelf.c (original)
+++ subversion/trunk/subversion/libsvn_client/shelf.c Mon Feb 26 09:28:54 2018
@@ -237,10 +237,10 @@ shelf_write_revprops(svn_client_shelf_t
}
svn_error_t *
-svn_client__shelf_revprop_set(svn_client_shelf_t *shelf,
- const char *prop_name,
- const svn_string_t *prop_val,
- apr_pool_t *scratch_pool)
+svn_client_shelf_revprop_set(svn_client_shelf_t *shelf,
+ const char *prop_name,
+ const svn_string_t *prop_val,
+ apr_pool_t *scratch_pool)
{
svn_hash_sets(shelf->revprops, apr_pstrdup(shelf->pool, prop_name),
svn_string_dup(prop_val, shelf->pool));
@@ -249,19 +249,19 @@ svn_client__shelf_revprop_set(svn_client
}
svn_error_t *
-svn_client__shelf_revprop_get(svn_string_t **prop_val,
- svn_client_shelf_t *shelf,
- const char *prop_name,
- apr_pool_t *result_pool)
+svn_client_shelf_revprop_get(svn_string_t **prop_val,
+ svn_client_shelf_t *shelf,
+ const char *prop_name,
+ apr_pool_t *result_pool)
{
*prop_val = svn_hash_gets(shelf->revprops, prop_name);
return SVN_NO_ERROR;
}
svn_error_t *
-svn_client__shelf_revprop_list(apr_hash_t **props,
- svn_client_shelf_t *shelf,
- apr_pool_t *result_pool)
+svn_client_shelf_revprop_list(apr_hash_t **props,
+ svn_client_shelf_t *shelf,
+ apr_pool_t *result_pool)
{
*props = shelf->revprops;
return SVN_NO_ERROR;
@@ -719,8 +719,8 @@ svn_client_shelf_set_log_message(svn_cli
{
svn_string_t *propval = svn_string_create(message, shelf->pool);
- SVN_ERR(svn_client__shelf_revprop_set(shelf, "svn:log", propval,
- scratch_pool));
+ SVN_ERR(svn_client_shelf_revprop_set(shelf, "svn:log", propval,
+ scratch_pool));
}
return SVN_NO_ERROR;