Try a singleton, try
our $pipeline; sub pipeline { $pipeline ||= new Lingua::StanfordCoreNLP::Pipeline(1, 1); $pipeline; } sub process_text { my ($self,$text) = @_; $self->pipeline->process( $text ); }
If things go wrong try Dumper-ing $MyModule::pipeline
In reply to Re: Exporter Problem
by Anonymous Monk
in thread Exporter Problem
by osler
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |