finding the parent of a filereference

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

finding the parent of a filereference

Tudor Girba-2
Hi,

I would like to find the parent of a FileReference. For example:

/a/b/c ==> /a/b

I could not find any straightforward way. The one I found was to go via the path and do:

aFileReference path withParents reverse second asFileReference

Is there no other way?

Cheers,
Doru

--

"Every thing has its own flow"
Reply | Threaded
Open this post in threaded view
|

Re: finding the parent of a filereference

Goubier Thierry
Try

aFileReference parent

Thierry

De : Pharo-users [[hidden email]] de la part de Tudor Girba [[hidden email]]
Date d'envoi : vendredi 31 janvier 2014 21:48
À : Any question about pharo is welcome
Objet : [Pharo-users] finding the parent of a filereference

Hi,

I would like to find the parent of a FileReference. For example:

/a/b/c ==> /a/b

I could not find any straightforward way. The one I found was to go via the path and do:

aFileReference path withParents reverse second asFileReference

Is there no other way?

Cheers,
Doru

--

"Every thing has its own flow"
Reply | Threaded
Open this post in threaded view
|

Re: finding the parent of a filereference

Sean P. DeNigris
Administrator
In reply to this post by Tudor Girba-2
Tudor Girba-2 wrote
I would like to find the parent of a FileReference. For example:
You're going to like the answer… #parent ;-)
Cheers,
Sean
Reply | Threaded
Open this post in threaded view
|

Re: finding the parent of a filereference

Tudor Girba-2
Ok, this is funny.

Thanks.

I go to sleep now :)

Doru


On Fri, Jan 31, 2014 at 10:21 PM, Sean P. DeNigris <[hidden email]> wrote:
Tudor Girba-2 wrote
> I would like to find the parent of a FileReference. For example:

You're going to like the answer… #parent ;-)



-----
Cheers,
Sean
--
View this message in context: http://forum.world.st/finding-the-parent-of-a-filereference-tp4740763p4740770.html
Sent from the Pharo Smalltalk Users mailing list archive at Nabble.com.




--

"Every thing has its own flow"