Closed GoogleCodeExporter closed 8 years ago
Done.
It's now stored in my student repository.
See
yang/ExternalResource/uimafit/src/test/java/org/uimafit/factory/AnalysisEngineFa
ctoryExternalResourceTest.java
Original comment by s.y...@ishuo.de
on 3 Jan 2012 at 2:06
Original comment by richard.eckart
on 4 Jan 2012 at 10:51
- Added createExternalResourceDescription() calls that do not require to set a
resource name for binding resources like we set parameters.
- Added test cases
- Extracted configuration parameter args list check into
ConfigurationParameterFactory.ensureParametersComeInPairs()
- Allow adding external resources to AEs like we set parameters as part of the
varargs list
- Thanks to Shuo Yang for preparing proof-of-concept implementation.
---
Committed revision 667.
Original comment by richard.eckart
on 5 Jan 2012 at 12:35
I did not transfer the changes to the
ConfigurationParameterFactory.javaUimaTypeMap as they looked incomplete to me.
I suppose this was the first try and then you gave up on this approach. I also
did the integration without adding a dependency on Commons Lang 3 - simply
nulling out the external resource parameters in the parameter list als does the
job since parameters with null values are ignored by
ConfigurationParameterFactory.createConfigurationData().
Furthermore, I just notice
AnalysisEngineFactory.createPrimitive(AnalysisEngineDescription, Object...),
AnalysisEngineFactory.setConfigurationParameters(AnalysisEngineDescription,
Object...) and also the calls in CollectionReaderFactory and
FlowControllerFactory do not understand the external resources yet, so I'll
leave the issue in "Started" for the moment.
Original comment by richard.eckart
on 5 Jan 2012 at 12:44
Well, I'm not sure about the
AnalysisEngineFactory.setConfigurationParameters(AnalysisEngineDescription,
Object...) since it explicitly says "set parameters" here. Maybe defer that
until we figure that it's really a good idea.
Original comment by richard.eckart
on 9 Jan 2012 at 9:27
I have been looking further into the issue now and think that
AnalysisEngineFactory.setConfigurationParameters() and
CollectionReaderFactory.setConfigurationParameters() should not be updated to
support external resources. Actually I think the two methods should not be used
at all. They are just convenience proxies for
ResourceCreationSpecifierFactory.setConfigurationParameters().
Original comment by richard.eckart
on 15 Jan 2012 at 4:18
- Added support for external resources to flow controllers
- Added external resource injection tests for collection readers and flow
controllers
- ConfigurationParameterFactory.createConfigurationData() ignores
ExternalResourceDescriptions. This simplifies the code because we do no longer
have to null parameter values.
- Some additional cleaning up
---
Fixed in revision 731.
Original comment by richard.eckart
on 15 Jan 2012 at 5:22
Original issue reported on code.google.com by
richard.eckart
on 26 Sep 2011 at 7:31