cancel
Showing results for 
Search instead for 
Did you mean: 

use many types in nuxeo-scan-importer

ITShine_
Star Contributor
Star Contributor

I'm using nuxeo-scan-importer to import documents using XML files, i've tried it with one type, now i want to be able map many type of document but i don't know how to indicates that those XML files correspond to this type of document. Any suggestions ? I’ve attached my scan-importer-config.xml file.

1 ACCEPTED ANSWER

Manon_Lumeau
Star Contributor
Star Contributor

Hello ITShine !

In your configuration file, you have those lines:

<targetLeafType>plan</targetLeafType>
<!--
  Or a dynamic one by defining a class that implements the DocumentTypeMapper interface
        <targetLeafTypeMapper>org.nuxeo.platform.scanimporter.tests.SampleMapper</targetLeafTypeMapper>
        
-->

You chose to use a static value for the document/leaf type (plan) with the targetLeafType attribute. But you could have chosen a dynamic value with the targetLeafTypeMapper attribute: in this case, as indicated in the above comment, you have to specify a class that implements the DocumentTypeMapper interface => that's what you need to do to "use many types" with the Scan importer.

Regards,

View answer in original post

2 REPLIES 2

Manon_Lumeau
Star Contributor
Star Contributor

Hello ITShine !

In your configuration file, you have those lines:

<targetLeafType>plan</targetLeafType>
<!--
  Or a dynamic one by defining a class that implements the DocumentTypeMapper interface
        <targetLeafTypeMapper>org.nuxeo.platform.scanimporter.tests.SampleMapper</targetLeafTypeMapper>
        
-->

You chose to use a static value for the document/leaf type (plan) with the targetLeafType attribute. But you could have chosen a dynamic value with the targetLeafTypeMapper attribute: in this case, as indicated in the above comment, you have to specify a class that implements the DocumentTypeMapper interface => that's what you need to do to "use many types" with the Scan importer.

Regards,

It's working now, thank you

Getting started

Find what you came for

We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.