<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body style="overflow-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;">
<div>Resuscitating this discussion thread from last year ...</div>
<div><br>
</div>
<div>To summarize my rereading of the thread, there is good agreement that Path.{ends,starts}With(String) should be deprecated and replaced with something else, perhaps Path.{ends,starts}WithString(String). There was also a parallel suggestion that Path.{ends,starts}With(Path)
be deprecated in favor of Path.{ends,starts}WithPath(Path). Thus:</div>
<div><br>
</div>
<div>* Path.{ends,starts}With(String) -> Path.{ends,starts}WithString(String)</div>
<div>* Path.{ends,starts}With(Path) -> Path.{ends,starts}WithPath(Path)</div>
<div><br>
</div>
<div>Among doubtlessly many others, one alternative is</div>
<div><br>
</div>
<div>1. Leave Path.{ends,starts}With(Path) unchanged</div>
<div>2. Deprecate Path.{ends,starts}With(String)</div>
<div>3. Add Path.pathString{ends,starts}With(String)</div>
<div><br>
</div>
<div>where "pathstring" in effect implies the value of Path.toString().</div>
<div><br>
</div>
<div>Comments?</div>
<div><br>
</div>
<div>Brian</div>
<div><br>
<blockquote type="cite">
<div>On Nov 2, 2025, at 3:35 PM, David Alayachew <davidalayachew@gmail.com> wrote:</div>
<br class="Apple-interchange-newline">
<div>
<div class="gmail_default" style="caret-color: rgb(0, 0, 0); font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; font-family: monospace;">
As for deprecations, I still think all 4 methods should be deprecated. This path variants are kind of ok, but the String variants are just too deceptively named.</div>
<div class="gmail_default" style="caret-color: rgb(0, 0, 0); font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; font-family: monospace;">
<br>
</div>
<div class="gmail_default" style="caret-color: rgb(0, 0, 0); font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; font-family: monospace;">
I think Rob Spoor hit it on the head with this quote.</div>
<div class="gmail_default" style="caret-color: rgb(0, 0, 0); font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; font-family: monospace;">
<br>
</div>
<div class="gmail_default" style="caret-color: rgb(0, 0, 0); font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; font-family: monospace;">
> Perhaps both can be added?</div>
<div class="gmail_default" style="caret-color: rgb(0, 0, 0); font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; font-family: monospace;">
> </div>
<div class="gmail_default" style="caret-color: rgb(0, 0, 0); font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; font-family: monospace;">
> Path.{start,end}sWithString would default to calling</div>
<div class="gmail_default" style="caret-color: rgb(0, 0, 0); font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; font-family: monospace;">
> toString().{start,end}sWith(arg) and</div>
<div class="gmail_default" style="caret-color: rgb(0, 0, 0); font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; font-family: monospace;">
> Path.{start,end}sWithPath would default to calling</div>
<div class="gmail_default" style="caret-color: rgb(0, 0, 0); font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; font-family: monospace;">
> {start,end}sWith(arg). The latter could default to</div>
<div class="gmail_default" style="caret-color: rgb(0, 0, 0); font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; font-family: monospace;">
> calling {start,end}sWith(getFileSystem().getPath(arg))</div>
<div class="gmail_default" style="caret-color: rgb(0, 0, 0); font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; font-family: monospace;">
> but then custom implementations that do something else</div>
<div class="gmail_default" style="caret-color: rgb(0, 0, 0); font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; font-family: monospace;">
> (in addition) may not work as expected.</div>
<div class="gmail_default" style="caret-color: rgb(0, 0, 0); font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; font-family: monospace;">
<br>
</div>
<div class="gmail_default" style="caret-color: rgb(0, 0, 0); font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; font-family: monospace;">
Doing it this way, we can have (start|end)sWithPath() have both String and Path overloads with no ambiguity.</div>
</div>
</blockquote>
</div>
<br>
</body>
</html>