> -----Original Message-----
> From: Julian Foad [mailto:julianfoad_at_btopenworld.com]
> Sent: woensdag 26 maart 2014 12:57
> To: Bert Huijben
> Cc: dev_at_subversion.apache.org
> Subject: Re: svn commit: r1544182 - in /subversion/trunk/subversion:
> include/svn_client.h libsvn_client/cat.c libsvn_client/deprecated.c
> Hi Bert...
> > URL: http://svn.apache.org/r1544182
> > Log:
> > Make the 'svn_client_cat()' API a bit more generic usable for api users,
> > by allowing the suppression of keyword expansion and by optionally
> > the properties of the node.
> Shouldn't we have an EOL-style translation option as well? Usually the two
svn_client_cat2() already implemented keyword expansion, but I don't think
it changes EOL?
I just added an option to allow disabling a magic feature of
svn_client_cat2() that api developers could only work around by directly
going to either the wc or ra apis.
Translating the EOL style can be done by wrapping the passed output stream
by a translation... So I don't see that as an as-interesting case.
> > * subversion/include/svn_client.h
> > (svn_client_cat3): New function.
> > (svn_client_cat2): Deprecate function.
> > * subversion/libsvn_client/cat.c
> > (svn_client_cat2): Rename to ...
> > (svn_client_cat3): ... this. Add support for not expanding keywords
> > for returning the properties.
> > * subversion/libsvn_client/deprecated.c
> > (svn_client_cat2): New function.
> > Modified: subversion/trunk/subversion/include/svn_client.h
> > /**
> > * Output the content of a file.
> > *
> > - * @param[in] out The stream to which the content will be
> > - * @param[in] path_or_url The path or URL of the file.
> > - * @param[in] peg_revision The peg revision.
> > - * @param[in] revision The operative revision.
> > + * @param[out] props Optional output argument to obtain
> > + * @param[in] out The stream to which the content will be
> > + * @param[in] path_or_url The path or URL of the file.
> > + * @param[in] peg_revision The peg revision.
> > + * @param[in] revision The operative revision.
> > + * @param[in] expand_keywords When true, keywords (when set) are
> And what if @a expand_keywords is false -- are keywords contracted to
> repository-normal form, or left unchanged? The implementation looks like
> leaves them unchanged.
We should never have expanded keywords in the repository normal form...
And we certainly never retract them when translating from that form...
> > * @param[in] ctx The standard client context, used for possible
> > * authentication.
> > * @param[in] pool Used for any temporary allocation.
> There's no longer a 'pool', there's a result_pool and a scratch_pool.
> > *
> > * @todo Add an expansion/translation flag?
> That comment seems to be redundant now.
I removed the documentation for pool and the todo in r1581796.
> > *
> > - * @since New in 1.2.
> > - *
> You should leave that "@since 1.2" in the deprecated function's doc
Fixed in r1581796.
> > * @see #svn_client_ctx_t <br> @ref clnt_revisions for
> > * a discussion of operative and peg revisions.
> > + *
> > + * @since New in 1.9.
> > */
> > svn_error_t *
> > +svn_client_cat3(apr_hash_t **props,
> > + svn_stream_t *out,
> > + const char *path_or_url,
> > + const svn_opt_revision_t *peg_revision,
> > + const svn_opt_revision_t *revision,
> > + svn_boolean_t expand_keywords,
> > + svn_client_ctx_t *ctx,
> > + apr_pool_t *result_pool,
> > + apr_pool_t *scratch_pool);
> > +
> > +/**
> > + * Similar to svn_client_cat3() except without the option of directly
> > + * reading the properties, and with @a expand_keywords always TRUE.
> ... and only one pool.
I don't think we document those pool changes in other similar cases.
(svn_client_cat2() didn't have output arguments, so I don't think there is
anything special to document here)
Received on 2014-03-26 13:13:41 CET