[opencms-dev] Identifying CmsResource as sibling

a.westermann at alkacon.com a.westermann at alkacon.com
Fri Apr 24 17:30:40 CEST 2009


Hi Ludwig,

there is no original and a sibling. On the database layer all siblings 
are different database entries (structure entries) that point to the 
same content (resource entry, content entry). So once you create a 
sibling you even may delete the first file and still have a valid file 
in the explorer.  Siblings must not be compared with symlinks.

If you insist on the idea of having the first file as the original file 
you could try to write some code based on the creation date.

Kind Regards,
Achim.
 
-------------------
Achim Westermann
 
Alkacon Software GmbH  - The OpenCms Experts                    
http://www.alkacon.com - http://www.opencms.org                 
                                                                
Visit OpenCms Days 2009 Conference and Expo                     
June 15 to June 16 2009 in Cologne, Germany                         
http://www.opencms-days.org  





Ludwig Hunecke wrote:
> Hi all,
>
> I have got a question regarding siblings.
>
> Imaging the following situation: there is a resource r and a sibling  
> to r called link_r. I need a method to programmatically identify  
> link_r as the sibling and r as the "original" resource.
>
> If you read r as resource via readFile for instance, I didn't find any  
> attribute identifying r as the original file.
>
> Has somebody got a solution for this?
>
>
> Thanks & regards,
> Ludwig
>
> --
> Ludwig Hunecke
> Kramerst. 18
> D-38122 Braunschweig
> Tel.: +49 (151) 14818950
> GnuPG Key-ID: 8CEAB267
>
>
>
>
> _______________________________________________
> This mail is sent to you from the opencms-dev mailing list
> To change your list options, or to unsubscribe from the list, please visit
> http://lists.opencms.org/mailman/listinfo/opencms-dev
>   



More information about the opencms-dev mailing list