_id stringlengths 2 7 | title stringlengths 3 151 | partition stringclasses 3
values | text stringlengths 33 8k | language stringclasses 1
value | meta_information dict |
|---|---|---|---|---|---|
q22300 | Html.addBoleto | train | public function addBoleto(BoletoContract $boleto)
{
$dados = $boleto->toArray();
$dados['codigo_barras'] = | php | {
"resource": ""
} |
q22301 | AbstractRetorno.toArray | train | public function toArray()
{
$array = [
'header' => $this->header->toArray(),
'trailer' => $this->trailer->toArray(),
'detalhes' => new Collection()
];
foreach ($this->detalhe as | php | {
"resource": ""
} |
q22302 | Bradesco.getCodigoCliente | train | public function getCodigoCliente()
{
if (empty($this->codigoCliente)) {
$this->codigoCliente = Util::formatCnab('9', $this->getCarteiraNumero(), 4) .
Util::formatCnab('9', $this->getAgencia(), 5) .
Util::formatCnab('9', $this->getConta(), 7) .
| php | {
"resource": ""
} |
q22303 | Pdf.addBoletos | train | public function addBoletos(array $boletos, $withGroup = true)
{
if ($withGroup) {
$this->StartPageGroup();
}
| php | {
"resource": ""
} |
q22304 | AbstractBoleto.setJurosApos | train | public function setJurosApos($jurosApos)
{
$jurosApos = (int)$jurosApos;
$this->jurosApos | php | {
"resource": ""
} |
q22305 | AbstractBoleto.getCodigoBarras | train | public function getCodigoBarras()
{
if (!empty($this->campoCodigoBarras)) {
return $this->campoCodigoBarras;
}
if (!$this->isValid($messages)) {
throw new \Exception('Campos requeridos pelo banco, aparentam estar ausentes ' . $messages);
}
$codigo = ... | php | {
"resource": ""
} |
q22306 | AbstractRemessa.getDataRemessa | train | public function getDataRemessa($format){
if(is_null($this->dataRemessa)){
return Carbon::now()->format($format);
| php | {
"resource": ""
} |
q22307 | AbstractRemessa.download | train | public function download($filename = null)
{
if ($filename === null) {
$filename = 'remessa.txt';
}
header('Content-type: | php | {
"resource": ""
} |
q22308 | AbstractRemessa.gerar | train | public function gerar()
{
if (!$this->isValid($messages)) {
throw new \Exception('Campos requeridos pelo banco, aparentam estar ausentes ' . $messages);
}
$stringRemessa = '';
if ($this->iRegistros < 1) {
throw new \Exception('Nenhuma linha detalhe foi adicio... | php | {
"resource": ""
} |
q22309 | Bradesco.setCip | train | public function setCip($cip)
{
$this->cip = $cip;
$this->variaveis_adicionais['cip'] | php | {
"resource": ""
} |
q22310 | MangaReview.fromParser | train | public static function fromParser(MangaReviewParser $parser): MangaReview
{
$instance = new self();
$instance->malId = $parser->getId();
$instance->url = $parser->getUrl();
$instance->helpfulCount= $parser->getHelpfulCount();
| php | {
"resource": ""
} |
q22311 | Parser.removeChildNodes | train | public static function removeChildNodes(Crawler $crawler): Crawler
{
if (!$crawler->count()) {
return $crawler;
}
$crawler->children()->each(
function (Crawler $crawler) {
$node = $crawler->getNode(0);
| php | {
"resource": ""
} |
q22312 | Manga.fromParser | train | public static function fromParser(MangaParser $parser): Manga
{
$instance = new self();
$instance->title = $parser->getMangaTitle();
$instance->url = $parser->getMangaURL();
$instance->malId = $parser->getMangaId();
$instance->imageUrl = $parser->getMangaImageURL();
... | php | {
"resource": ""
} |
q22313 | RegexPatternPolicy.generateRegex | train | private function generateRegex($stepText)
{
return preg_replace(
array_keys(self::$replacePatterns),
| php | {
"resource": ""
} |
q22314 | RegexPatternPolicy.countPlaceholders | train | private function countPlaceholders($stepText, $stepRegex)
{
preg_match('/^' . $stepRegex . '$/', $stepText, $matches);
| php | {
"resource": ""
} |
q22315 | ConsoleOutputFactory.getDefaultStyles | train | private function getDefaultStyles()
{
return array(
'keyword' => new OutputFormatterStyle(null, null, array('bold')),
'stdout' => new OutputFormatterStyle(null, null, array()),
'exception' => new OutputFormatterStyle('red'),
'undefined' =>... | php | {
"resource": ""
} |
q22316 | OutlineTableListener.printExampleRowOnAfterExampleEvent | train | private function printExampleRowOnAfterExampleEvent(Formatter $formatter, Event $event, $eventName)
{
if (!$event instanceof AfterScenarioTested || ExampleTested::AFTER !== $eventName) {
return;
}
$example = $event->getScenario();
$this->exampleSetupPrinter->printSetup(... | php | {
"resource": ""
} |
q22317 | OutlineTableListener.printFooterOnAfterEvent | train | private function printFooterOnAfterEvent(Formatter $formatter, Event $event)
{
if (!$event instanceof AfterOutlineTested) | php | {
"resource": ""
} |
q22318 | StepTextPainter.paintText | train | public function paintText($text, Definition $definition, TestResult $result)
{
$regex = $this->patternTransformer->transformPatternToRegex($definition->getPattern());
$style = $this->resultConverter->convertResultToString($result);
$paramStyle = $style . '_param';
// If it's just a ... | php | {
"resource": ""
} |
q22319 | PrettyOutlinePrinter.printExamplesSteps | train | private function printExamplesSteps(Formatter $formatter, OutlineNode $outline, array $steps)
{
foreach ($steps as $step) {
$this->stepPrinter->printStep($formatter, $outline, $step, | php | {
"resource": ""
} |
q22320 | PrettyOutlinePrinter.printExamplesTableHeader | train | private function printExamplesTableHeader(OutputPrinter $printer, ExampleTableNode $table)
{
$printer->writeln(sprintf('%s{+keyword}%s:{-keyword}', $this->indentText, $table->getKeyword()));
| php | {
"resource": ""
} |
q22321 | PrettyOutlinePrinter.getWrapperClosure | train | private function getWrapperClosure()
{
$style = $this->resultConverter->convertResultCodeToString(TestResult::SKIPPED);
return function ($col) use ($style) {
| php | {
"resource": ""
} |
q22322 | ResultToStringConverter.convertResultCodeToString | train | public function convertResultCodeToString($resultCode)
{
switch ($resultCode) {
case TestResult::SKIPPED:
return 'skipped';
case TestResult::PENDING:
return 'pending';
| php | {
"resource": ""
} |
q22323 | WidthCalculator.calculateScenarioWidth | train | public function calculateScenarioWidth(Scenario $scenario, $indentation, $subIndentation)
{
$length = $this->calculateScenarioHeaderWidth($scenario, $indentation);
foreach ($scenario->getSteps() as $step) {
| php | {
"resource": ""
} |
q22324 | WidthCalculator.calculateExampleWidth | train | public function calculateExampleWidth(ExampleNode $example, $indentation, $subIndentation)
{
$length = $this->calculateScenarioHeaderWidth($example, $indentation);
foreach ($example->getSteps() as $step) {
| php | {
"resource": ""
} |
q22325 | WidthCalculator.calculateScenarioHeaderWidth | train | public function calculateScenarioHeaderWidth(Scenario $scenario, $indentation)
{
$indentText = str_repeat(' ', intval($indentation));
if ($scenario instanceof ExampleNode) {
$header = sprintf('%s%s', $indentText, $scenario->getTitle());
} else {
$title = $scenario->g... | php | {
"resource": ""
} |
q22326 | WidthCalculator.calculateStepWidth | train | public function calculateStepWidth(StepNode $step, $indentation)
{
$indentText = str_repeat(' ', intval($indentation)); | php | {
"resource": ""
} |
q22327 | TransformationExtension.loadDefinitionArgumentsTransformer | train | protected function loadDefinitionArgumentsTransformer(ContainerBuilder $container)
{
$definition = new Definition('Behat\Behat\Transformation\Call\Filter\DefinitionArgumentsTransformer');
$definition->addTag(CallExtension::CALL_FILTER_TAG, | php | {
"resource": ""
} |
q22328 | TransformationExtension.loadDefaultTransformers | train | protected function loadDefaultTransformers(ContainerBuilder $container)
{
$definition = new Definition('Behat\Behat\Transformation\Transformer\RepositoryArgumentTransformer', array(
new Reference(self::REPOSITORY_ID),
new Reference(CallExtension::CALL_CENTER_ID),
new Refe... | php | {
"resource": ""
} |
q22329 | TransformationExtension.loadRepository | train | protected function loadRepository(ContainerBuilder $container)
{
$definition = new Definition('Behat\Behat\Transformation\TransformationRepository', array(
| php | {
"resource": ""
} |
q22330 | TransformationExtension.processArgumentsTransformers | train | protected function processArgumentsTransformers(ContainerBuilder $container)
{
$references = $this->processor->findAndSortTaggedServices($container, self::ARGUMENT_TRANSFORMER_TAG);
$definition = $container->getDefinition($this->getDefinitionArgumentTransformerId());
| php | {
"resource": ""
} |
q22331 | FeatureContext.iRunBehatInteractively | train | public function iRunBehatInteractively($answerString, $argumentsString)
{
$env = $this->process->getEnv();
$env['SHELL_INTERACTIVE'] = true;
$this->process->setEnv($env);
| php | {
"resource": ""
} |
q22332 | FeatureContext.itShouldPassWith | train | public function itShouldPassWith($success, PyStringNode $text)
| php | {
"resource": ""
} |
q22333 | FeatureContext.fileXmlShouldBeLike | train | public function fileXmlShouldBeLike($path, PyStringNode $text)
{
$path = $this->workingDir . '/' . $path;
Assert::assertFileExists($path);
$fileContent = trim(file_get_contents($path));
| php | {
"resource": ""
} |
q22334 | FeatureContext.xmlShouldBeValid | train | public function xmlShouldBeValid($xmlFile, $schemaPath)
{
$dom = new DomDocument();
$dom->load($this->workingDir . '/' . $xmlFile);
| php | {
"resource": ""
} |
q22335 | HookExtension.loadAnnotationReader | train | private function loadAnnotationReader(ContainerBuilder $container)
{
$definition = new Definition('Behat\Behat\Hook\Context\Annotation\HookAnnotationReader');
$definition->addTag(ContextExtension::ANNOTATION_READER_TAG, | php | {
"resource": ""
} |
q22336 | PrettyFormatterFactory.loadRootNodeListener | train | protected function loadRootNodeListener(ContainerBuilder $container)
{
$definition = new Definition('Behat\Testwork\Output\Node\EventListener\ChainEventListener', array(
array(
new Definition('Behat\Behat\Output\Node\EventListener\AST\SuiteListener', array(
ne... | php | {
"resource": ""
} |
q22337 | PrettyFormatterFactory.loadTableOutlinePrinter | train | protected function loadTableOutlinePrinter(ContainerBuilder $container)
{
$definition = new Definition('Behat\Behat\Output\Node\Printer\Pretty\PrettyOutlineTablePrinter', array(
new Reference('output.node.printer.pretty.scenario'),
new Reference('output.node.printer.pretty.skipped_st... | php | {
"resource": ""
} |
q22338 | PrettyFormatterFactory.loadHookPrinters | train | protected function loadHookPrinters(ContainerBuilder $container)
{
$definition = new Definition('Behat\Behat\Output\Node\Printer\Pretty\PrettySetupPrinter', array(
new Reference(self::RESULT_TO_STRING_CONVERTER_ID),
new Reference(ExceptionExtension::PRESENTER_ID),
0,
... | php | {
"resource": ""
} |
q22339 | PrettyFormatterFactory.processListenerWrappers | train | protected function processListenerWrappers(ContainerBuilder $container)
{
| php | {
"resource": ""
} |
q22340 | TotalStatistics.registerScenarioStat | train | public function registerScenarioStat(ScenarioStat $stat)
{
if (TestResults::NO_TESTS === $stat->getResultCode()) {
return;
}
$this->scenarioCounters[$stat->getResultCode()]++;
if (TestResult::FAILED === $stat->getResultCode()) {
| php | {
"resource": ""
} |
q22341 | TotalStatistics.registerStepStat | train | public function registerStepStat(StepStat $stat)
{
$this->stepCounters[$stat->getResultCode()]++;
if (TestResult::FAILED === $stat->getResultCode()) {
$this->failedStepStats[] = $stat;
}
| php | {
"resource": ""
} |
q22342 | HelperContainerExtension.isDefinitionShared | train | private function isDefinitionShared(Definition $definition)
{
if (method_exists($definition, 'isShared')) {
return $definition->isShared();
} else if (method_exists($definition, 'getScope')) {
| php | {
"resource": ""
} |
q22343 | ConsoleDefinitionInformationPrinter.extractHeader | train | private function extractHeader(Suite $suite, Definition $definition)
{
$pattern = $definition->getPattern();
$lines = array();
$lines[] = strtr(
'{suite} <def_dimmed>|</def_dimmed> <info>{type}</info> <def_regex>{regex}</def_regex>', array(
'{suite}' => $suite->ge... | php | {
"resource": ""
} |
q22344 | ConsoleDefinitionInformationPrinter.extractDescription | train | private function extractDescription(Suite $suite, Definition $definition)
{
$definition = $this->translateDefinition($suite, $definition);
$lines = array();
if ($description = $definition->getDescription()) {
foreach (explode("\n", $description) as $descriptionLine) {
... | php | {
"resource": ""
} |
q22345 | ConsoleDefinitionInformationPrinter.extractFooter | train | private function extractFooter(Suite $suite, Definition $definition)
{
$lines = array();
$lines[] = strtr(
'{space}<def_dimmed>|</def_dimmed> at `{path}`', array(
'{space}' => str_pad('', mb_strlen($suite->getName(), 'utf8') + 1),
'{path}' => $definition-... | php | {
"resource": ""
} |
q22346 | CounterPrinter.printCounters | train | public function printCounters(OutputPrinter $printer, $intro, array $stats)
{
$stats = array_filter($stats, function ($count) { return 0 !== $count; });
if (0 === count($stats)) {
$totalCount = 0;
} else {
$totalCount = array_sum($stats);
}
$detailed... | php | {
"resource": ""
} |
q22347 | ConsoleDefinitionPrinter.translateDefinition | train | final protected function translateDefinition(Suite $suite, Definition $definition) | php | {
"resource": ""
} |
q22348 | PrettyPathPrinter.printScenarioPath | train | public function printScenarioPath(Formatter $formatter, FeatureNode $feature, Scenario $scenario, $indentation)
{
$printer = $formatter->getOutputPrinter();
if (!$formatter->getParameter('paths')) {
$printer->writeln();
return;
}
$fileAndLine = sprintf('%s:... | php | {
"resource": ""
} |
q22349 | PrettyPathPrinter.printStepPath | train | public function printStepPath(
Formatter $formatter,
Scenario $scenario,
StepNode $step,
StepResult $result,
$indentation
) {
$printer = $formatter->getOutputPrinter();
if (!$result instanceof DefinedStepResult || !$result->getStepDefinition() || !$formatter-... | php | {
"resource": ""
} |
q22350 | PrettyPathPrinter.printDefinedStepPath | train | private function printDefinedStepPath(OutputPrinter $printer, DefinedStepResult $result, $scenarioWidth, $stepWidth)
{
$path = $result->getStepDefinition()->getPath(); | php | {
"resource": ""
} |
q22351 | PrettyPathPrinter.relativizePaths | train | private function relativizePaths($path)
{
if (!$this->basePath) {
| php | {
"resource": ""
} |
q22352 | ReturnTypeTransformation.getReturnClass | train | static private function getReturnClass(ReflectionFunctionAbstract $reflection)
{
$type = $reflection->getReturnType();
| php | {
"resource": ""
} |
q22353 | ReturnTypeTransformation.hasIndex | train | private function hasIndex($index)
{
return is_string($index) ? | php | {
"resource": ""
} |
q22354 | DefinitionTranslator.translateDefinition | train | public function translateDefinition(Suite $suite, Definition $definition, $language = null)
{
$assetsId = $suite->getName();
$pattern = $definition->getPattern();
$translatedPattern = $this->translator->trans($pattern, array(), $assetsId, $language);
| php | {
"resource": ""
} |
q22355 | PrettySkippedStepPrinter.getArgumentString | train | private function getArgumentString(ArgumentInterface $argument, $collapse = false)
{
if ($collapse) {
return '...';
}
if ($argument instanceof PyStringNode) {
$text | php | {
"resource": ""
} |
q22356 | ContextFactory.createContext | train | public function createContext($class, array $arguments = array(), array $singleUseResolvers = array())
{
$reflection = new ReflectionClass($class);
$resolvers = array_merge($singleUseResolvers, $this->argumentResolvers);
$resolvedArguments = $this->resolveArguments($reflection, $arguments, $... | php | {
"resource": ""
} |
q22357 | ContextFactory.resolveArguments | train | private function resolveArguments(ReflectionClass $reflection, array $arguments, array $resolvers)
{
$newArguments = $arguments;
foreach ($resolvers as $resolver) {
$newArguments = $resolver->resolveArguments($reflection, $newArguments);
| php | {
"resource": ""
} |
q22358 | ContextFactory.createInstance | train | private function createInstance(ReflectionClass $reflection, array $arguments)
{
if (count($arguments)) | php | {
"resource": ""
} |
q22359 | ContextFactory.initializeInstance | train | private function initializeInstance(Context $context)
{
foreach ($this->contextInitializers as | php | {
"resource": ""
} |
q22360 | TurnipPatternPolicy.replaceTokensWithRegexCaptureGroups | train | private function replaceTokensWithRegexCaptureGroups($regex)
{
$tokenRegex = self::TOKEN_REGEX;
return preg_replace_callback(
self::PLACEHOLDER_REGEXP, | php | {
"resource": ""
} |
q22361 | TurnipPatternPolicy.replaceTurnipAlternativeWordsWithRegex | train | private function replaceTurnipAlternativeWordsWithRegex($regex)
{
$regex = preg_replace(self::ALTERNATIVE_WORD_REGEXP, '(?:\1|\2)', $regex);
| php | {
"resource": ""
} |
q22362 | PrettyExamplePrinter.printTitle | train | private function printTitle(OutputPrinter $printer, ExampleNode $example)
{
| php | {
"resource": ""
} |
q22363 | DefinitionWriter.printSuiteDefinitions | train | public function printSuiteDefinitions(DefinitionPrinter $printer, $suite)
{
$environment = $this->environmentManager->buildEnvironment($suite);
$definitions | php | {
"resource": ""
} |
q22364 | OnlyFirstBackgroundFiresListener.flushStatesIfBeginningOfTheFeature | train | private function flushStatesIfBeginningOfTheFeature($eventName)
{
if (FeatureTested::BEFORE !== $eventName) | php | {
"resource": ""
} |
q22365 | OnlyFirstBackgroundFiresListener.markBeginningOrEndOfTheBackground | train | private function markBeginningOrEndOfTheBackground($eventName)
{
if (BackgroundTested::BEFORE === $eventName) {
| php | {
"resource": ""
} |
q22366 | OnlyFirstBackgroundFiresListener.isSkippableEvent | train | private function isSkippableEvent(Event $event)
{
if (!$this->firstBackgroundEnded) {
| php | {
"resource": ""
} |
q22367 | OnlyFirstBackgroundFiresListener.isBeforeStepEventWithOutput | train | private function isBeforeStepEventWithOutput(Event $event)
{
if ($event instanceof AfterStepSetup && | php | {
"resource": ""
} |
q22368 | OnlyFirstBackgroundFiresListener.isAfterStepWithOutput | train | private function isAfterStepWithOutput(Event $event)
{
if ($event instanceof AfterStepTested && ($this->stepSetupHadOutput || | php | {
"resource": ""
} |
q22369 | AnnotatedContextReader.readMethodCallees | train | private function readMethodCallees($class, ReflectionMethod $method)
{
$callees = array();
// read parent annotations
try {
$prototype = $method->getPrototype();
// error occurs on every second PHP stable release - getPrototype() returns itself
if ($proto... | php | {
"resource": ""
} |
q22370 | AnnotatedContextReader.readDocBlockCallees | train | private function readDocBlockCallees($class, ReflectionMethod $method, $docBlock)
{
$callees = array();
$description = $this->readDescription($docBlock);
$docBlock = $this->mergeMultilines($docBlock);
foreach (explode("\n", $docBlock) as $docLine) {
$docLine = preg_repla... | php | {
"resource": ""
} |
q22371 | AnnotatedContextReader.readDescription | train | private function readDescription($docBlock)
{
// Remove indentation
$description = preg_replace('/^[\s\t]*/m', '', $docBlock);
// Remove block comment syntax
$description = preg_replace('/^\/\*\*\s*|^\s*\*\s|^\s*\*\/$/m', '', $description);
// Remove annotations
$de... | php | {
"resource": ""
} |
q22372 | AnnotatedContextReader.readDocLineCallee | train | private function readDocLineCallee($class, ReflectionMethod $method, $docLine, $description = null)
{
if ($this->isIgnoredAnnotation($docLine)) {
return null;
}
foreach ($this->readers as $reader) {
| php | {
"resource": ""
} |
q22373 | AnnotatedContextReader.isIgnoredAnnotation | train | private function isIgnoredAnnotation($docLine)
{
$lowDocLine = strtolower($docLine);
foreach (self::$ignoreAnnotations as $ignoredAnnotation) {
if ($ignoredAnnotation == | php | {
"resource": ""
} |
q22374 | ContextExtension.loadFactory | train | private function loadFactory(ContainerBuilder $container)
{
$definition = new Definition('Behat\Behat\Context\ContextFactory', array(
| php | {
"resource": ""
} |
q22375 | ContextExtension.loadArgumentResolverFactory | train | private function loadArgumentResolverFactory(ContainerBuilder $container)
{
$definition = new Definition('Behat\Behat\Context\Argument\CompositeArgumentResolverFactory'); | php | {
"resource": ""
} |
q22376 | ContextExtension.loadEnvironmentHandler | train | private function loadEnvironmentHandler(ContainerBuilder $container)
{
$definition = new Definition('Behat\Behat\Context\Environment\Handler\ContextEnvironmentHandler', array(
new Reference(self::FACTORY_ID),
new Reference(self::AGGREGATE_RESOLVER_FACTORY_ID)
));
| php | {
"resource": ""
} |
q22377 | ContextExtension.loadEnvironmentReader | train | private function loadEnvironmentReader(ContainerBuilder $container)
{
$definition = new Definition('Behat\Behat\Context\Environment\Reader\ContextEnvironmentReader');
$definition->addTag(EnvironmentExtension::READER_TAG, | php | {
"resource": ""
} |
q22378 | ContextExtension.loadSuiteSetup | train | private function loadSuiteSetup(ContainerBuilder $container)
{
$definition = new Definition('Behat\Behat\Context\Suite\Setup\SuiteWithContextsSetup', array(
new Reference(AutoloaderExtension::CLASS_LOADER_ID),
| php | {
"resource": ""
} |
q22379 | ContextExtension.loadSnippetAppender | train | private function loadSnippetAppender(ContainerBuilder $container)
{
$definition = new Definition('Behat\Behat\Context\Snippet\Appender\ContextSnippetAppender', array(
| php | {
"resource": ""
} |
q22380 | ContextExtension.loadSnippetGenerators | train | private function loadSnippetGenerators(ContainerBuilder $container)
{
$definition = new Definition('Behat\Behat\Context\Snippet\Generator\ContextSnippetGenerator', array(
| php | {
"resource": ""
} |
q22381 | ContextExtension.loadDefaultClassGenerators | train | private function loadDefaultClassGenerators(ContainerBuilder $container)
{
$definition = new Definition('Behat\Behat\Context\ContextClass\SimpleClassGenerator');
$definition->addTag(self::CLASS_GENERATOR_TAG, | php | {
"resource": ""
} |
q22382 | ContextExtension.loadDefaultContextReaders | train | private function loadDefaultContextReaders(ContainerBuilder $container)
{
$definition = new Definition('Behat\Behat\Context\Reader\AnnotatedContextReader');
$container->setDefinition(self::getAnnotatedContextReaderId(), $definition);
$definition = new Definition('Behat\Behat\Context\Reader\... | php | {
"resource": ""
} |
q22383 | ContextExtension.processClassResolvers | train | private function processClassResolvers(ContainerBuilder $container)
{
$references = $this->processor->findAndSortTaggedServices($container, self::CLASS_RESOLVER_TAG);
$definition = $container->getDefinition(self::getEnvironmentHandlerId());
| php | {
"resource": ""
} |
q22384 | ContextExtension.processArgumentResolverFactories | train | private function processArgumentResolverFactories($container)
{
$references = $this->processor->findAndSortTaggedServices($container, self::SUITE_SCOPED_RESOLVER_FACTORY_TAG);
$definition = $container->getDefinition(self::AGGREGATE_RESOLVER_FACTORY_ID);
| php | {
"resource": ""
} |
q22385 | ContextExtension.processArgumentResolvers | train | private function processArgumentResolvers(ContainerBuilder $container)
{
$references = $this->processor->findAndSortTaggedServices($container, self::ARGUMENT_RESOLVER_TAG);
$definition = $container->getDefinition(self::FACTORY_ID);
| php | {
"resource": ""
} |
q22386 | ContextExtension.processContextInitializers | train | private function processContextInitializers(ContainerBuilder $container)
{
$references = $this->processor->findAndSortTaggedServices($container, self::INITIALIZER_TAG);
$definition = $container->getDefinition(self::FACTORY_ID);
| php | {
"resource": ""
} |
q22387 | ContextExtension.processContextReaders | train | private function processContextReaders(ContainerBuilder $container)
{
$references = $this->processor->findAndSortTaggedServices($container, self::READER_TAG);
$definition = $container->getDefinition(self::getEnvironmentReaderId());
| php | {
"resource": ""
} |
q22388 | ContextExtension.processClassGenerators | train | private function processClassGenerators(ContainerBuilder $container)
{
$references = $this->processor->findAndSortTaggedServices($container, self::CLASS_GENERATOR_TAG);
$definition = $container->getDefinition(self::getSuiteSetupId());
| php | {
"resource": ""
} |
q22389 | ContextExtension.processAnnotationReaders | train | private function processAnnotationReaders(ContainerBuilder $container)
{
$references = $this->processor->findAndSortTaggedServices($container, self::ANNOTATION_READER_TAG);
$definition = $container->getDefinition(self::getAnnotatedContextReaderId());
| php | {
"resource": ""
} |
q22390 | PatternTransformer.generatePattern | train | public function generatePattern($type, $stepText)
{
foreach ($this->policies as $policy) {
if ($policy->supportsPatternType($type)) {
return $policy->generatePattern($stepText);
}
| php | {
"resource": ""
} |
q22391 | PatternTransformer.transformPatternToRegex | train | public function transformPatternToRegex($pattern)
{
if (!isset($this->patternToRegexpCache[$pattern])) {
$this->patternToRegexpCache[$pattern] | php | {
"resource": ""
} |
q22392 | SuiteWithPathsSetup.createFeatureDirectory | train | private function createFeatureDirectory($path)
{
mkdir($path, 0777, true);
if ($this->logger) {
| php | {
"resource": ""
} |
q22393 | SuiteWithPathsSetup.locatePath | train | private function locatePath($path)
{
if ($this->isAbsolutePath($path)) {
| php | {
"resource": ""
} |
q22394 | ServicesResolver.filterCall | train | public function filterCall(Call $call)
{
if ($container = $this->getContainer($call)) {
$autowirer = new ArgumentAutowirer($container);
| php | {
"resource": ""
} |
q22395 | ServicesResolver.getContainer | train | private function getContainer(Call $call)
{
if (!$call instanceof EnvironmentCall) {
throw new UnsupportedCallException(sprintf(
'ServicesResolver can not filter `%s` call.',
get_class($call)
), $call);
}
$environment = $call->getEnvir... | php | {
"resource": ""
} |
q22396 | ServicesResolver.repackageCallIfNewArguments | train | private function repackageCallIfNewArguments(Call $call, array $arguments)
{
if ($arguments === $call->getArguments()) {
return $call;
| php | {
"resource": ""
} |
q22397 | ServicesResolver.repackageCallWithNewArguments | train | private function repackageCallWithNewArguments(Call $call, array $newArguments)
{
if ($call instanceof DefinitionCall) {
return $this->repackageDefinitionCall($call, $newArguments);
}
if ($call instanceof TransformationCall) {
return $this->repackageTransformationCal... | php | {
"resource": ""
} |
q22398 | ServicesResolver.repackageDefinitionCall | train | private function repackageDefinitionCall(DefinitionCall $call, array $newArguments)
{
$definition = $call->getCallee();
if (!$definition instanceof Definition) {
throw new UnsupportedCallException(
sprintf(
'Something is wrong in callee associated wit... | php | {
"resource": ""
} |
q22399 | ServicesResolver.repackageTransformationCall | train | private function repackageTransformationCall(TransformationCall $call, array $newArguments)
{
$transformation = $call->getCallee();
if (!$transformation instanceof Transformation) {
throw new UnsupportedCallException(
sprintf(
'Something is wrong in c... | php | {
"resource": ""
} |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.