Re: SEARCH by last path segment, Was: SEARCH for displayname

Wallmer, Martin wrote:

> here again my proposal. Is it now clear and "wasserdicht"?

I think using the "AND" terminology is still confusing. Alternate 
proposal inline.

> 
>                   5.4  DAV:from
>                   <!ELEMENT scope            (href, depth,
>                   include-versions?,
>                   <Martin>include-lastpathsegment*,
>                   exclude-lastpathsegment* </Martin>) >
>                   <!ELEMENT include-versions EMPTY >
>                   <Martin>
>                   <!ELEMENT include-lastpathsegment(#PCDATA)>
>                   <!ELEMENT exclude-lastpathsegment(#PCDATA)>
>                   </Martin>
> 
 > ...
>                   <Martin>
>                   The content of DAV:include-lastpathsegment and
>                   DAV:exclude-lastpathsegment is a literal pattern same
>                   as defined for (@see 5.15.1) <DAV:like>

Q: forgot to ask that before -- are we confident that we don't need a 
caseless matching attribute here? note that in the real world, people 
frequently have both lower- and uppercase extensions.

>                   When neither <DAV:include-lastpathsegment> nor
>                   <DAV:exclude-lastpathsegment> are present, the scope
>                   comprises ALL resources (that are defined by
>                   <DAV:href> and <DAV:depth>)
> 
>                   When one or more <DAV:include-lastpathsegment> but no
>                   <DAV:exclude-lastpathsegment> are present, the scope
>                   comprises ALL resources AND resources matching include
>                   pattern(s)

I'd just say "comprises those resources matching the include pattern(s)."

>                   When one or more <DAV:exclude-lastpathsegment> but no
>                   <DAV:include-lastpathsegment> are present, the scope
>                   comprises ALL resources AND NOT resources matching
>                   exclude pattern(s)

"...compromises all resources except those matching the excluse pattern(s)."

>                   When one or more <DAV:include-lastpathsegment> and one
>                   ore more <DAV:exclude-lastpathsegment> are present,
>                   the scope comprises ALL resources AND resources
>                   matching include pattern(s) AND NOT resources matching
>                   exclude pattern(s)

"...compromises all resources matching the include patterns except those 
matching the exclude patterns."

>                   Example:
>                   <d:searchrequest xmlns:d="DAV:">
>                     <d:basicsearch>
>                       <d:select>
>                         <d:prop><d:getcontentlength/></d:prop>
>                       </d:select>
>                       <d:from>
>                         <d:scope>
>                           <d:href>/container1/</d:href>
>                           <d:depth>infinity</d:depth>
>                          
>                   <d:include-lastpathsegment>%.pdf</d:include-lastpathsegment>
> 
>                          
>                   <d:exclude-lastpathsegment>%-2001-%.pdf</d:exclude-lastpathsegment>
> 
>                          
>                   <d:include-lastpathsegment>chapter%.doc</d:include-lastpathsegment>
> 
>                         </d:scope>
>                       </d:from>
>                     </d:basicsearch>
>                   </d:searchrequest>
> 
>                   The scope of this query comprises all resources within
>                   or below container1,
>                   that have the postfix .pdf, all doc files starting
>                   with "chapter", but not
>                   the file (for example) report-2001-july.pdf
> 
>                   </Martin>

I think it would be good to avoid examples using matching extensions -- 
this really *should* be done using matching on DAV:getcontenttype.


Julian

-- 
<green/>bytes GmbH -- http://www.greenbytes.de -- tel:+492512807760

Received on Sunday, 23 November 2003 12:32:55 UTC