Loading login details...

DeltaXML Support Forums

 new topic  post reply 
moderators: chrisc nigelw tristanm
setting features with core 4.4
Joined: 25-October-2007
Posts: 2
Posted: 15-January-2008 12:34
Hello,

I was trying to use some special features of the 4.4 API, but there I got some problems. When I try to set the isCombineForward feature I always get the same exception

The PipelinedComparator comparator feature: http://deltaxml.com/api/feature/isCombineForward is not recognized

What does this mean?
With the isFullDelta, enhancedMatch1 and enhancedMatch2 features its working fine. For all for I use the method setComparatorFeature(featureName, featureValue)

So can anyone tell me what I'm doing wrong?

reguards
Robert
compator vs combiner features
Joined: 27-March-2007
Posts: 54
Location: Malvern, United Kingdom
Posted: 15-January-2008 14:46
Hello Robert,

The PipelinedComparator comparator feature: http://deltaxml.com/api/feature/isCombineForward is not recognized


This is because isCombineForward is a combiner feature, not a comparator feature.

The combiner is a component which takes a raw, changes-only or minimal delta produced by the comparator and one of the other comparator inputs and a regenerate or 'recombine' to produce what was the other comparator input.

What does this mean?
With the isFullDelta, enhancedMatch1 and enhancedMatch2 features its working fine. For all for I use the method setComparatorFeature(featureName, featureValue)

So can anyone tell me what I'm doing wrong?


The software is working as we expect, I think you may have seen the list of features and did not appreciate the distinction between comparator and combiner?  I'll see if there is anything in the documentation we can improve for a future release.

Some backround to the API design:  There is both an XMLComparator and an XMLCombiner in the lower level JAXP style API (in the com.deltaxml.api package).  But there is only a PipelinedComparator in the higher level com.deltaxml.core API.   The reason that we don't have a PipelinedCombiner is because when the comparator/combiner are used to 'round-trip' XML, the combiner needs raw un-processed delta files from the comparator.  We have many use-cases for a Pipelined Comparator, but we could not find any for a 'Pipelined Combiner',  hence the differences in these APIs.

Regards,

Nigel
compator vs combiner features
Joined: 25-October-2007
Posts: 2
Posted: 16-January-2008 12:33
hello nigel

thanks for your fast reply.

do i get you right?

the combiner is used to reproduce a source document?
so when i compare A and B and get the result C, then i can take B and C to get A again?

regards
robert
Re: compator vs combiner features
Joined: 27-March-2007
Posts: 54
Location: Malvern, United Kingdom
Posted: 16-January-2008 16:43
Hello Robert,

do i get you right?

the combiner is used to reproduce a source document?
so when i compare A and B and get the result C, then i can take B and C to get A again?


Yes, exactly.

A compare B -> C  ; A combine-forward C -> B
                     B combine-reverse C -> A

Note that comparison is not commutative, so that:
  A compare B != B compare A

Similarly this all works the other way round, so that:

  B compare A -> D  ; B combine-forward D -> A
                      A combine-reverse D -> B

So the compareForward feature allows you to reverse the normal 'direction' of the delta when used with recombination.

We don't believe we have many users of the combiner - though it does have some specialized use-cases, but it is an important way to prove the correctness of the delta; we use it heavily in our test processes.
 new topic  post reply  To find out about new replies to this post as they occur
please subscribe to one of these feeds:
AtomRSS moderate