Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[smila-dev] ParentId needed for DeltaIndexing of Compound records

Hi all,

to be able to implement
https://bugs.eclipse.org/bugs/show_bug.cgi?id=278360

We need some functionality to get the parent Id from a given Id/record
object. For top level ids the parentId should be null of course. For
this use case the hash string of the parent Id would suffice (it could
be easily modelled as a Metadata attribute value), but I guess it is
more generic to return the complete parent Id object.

Could we just add a method getParentId() to interface Id and provide an
appropriate implementation in IdImpl ?
Is it even possible to implement this logic to compute a parentId from a
given Id? How to handle elements and fragments ?

Another option would be to include an optional parentId in the record.
So we would have to either convert the id to xml and handle it as a
String literal or an attachment. But this involves unneccessary
conversion and parsing.
So if this is the way to go I would prefer a special record member
variabel parentId, that may be optionally set.

Of course we could also add a parentId member to the Id object, so we
don't have to recompute it.

What do you think ?

Bye,
Daniel


Back to the top