public function setContextIdentifier(TargetContextIdentifier $identifier) { $this->contextIdentifier = new CachedContextIdentifier($identifier); }
/** * {@inheritdoc} */ public function execute(InputInterface $input, OutputInterface $output) { $this->generator->setContextIdentifier(new AggregateContextIdentifier(array(new ContextInterfaceBasedContextIdentifier(), new FixedContextIdentifier($input->getOption('snippets-for')), new InteractiveContextIdentifier($this->translator, $input, $output)))); $this->generator->setPatternIdentifier(new AggregatePatternIdentifier(array(new ContextInterfaceBasedPatternIdentifier(), new FixedPatternIdentifier($input->getOption('snippets-type'))))); }