Constructs the pattern.
@return pattern
185920
@Override
	public Pattern constructPattern()
	{
		Pattern p = new Pattern(SequenceEntityReference.class, "controller ER");
		p.add(isHuman(), "controller ER");
		p.add(linkedER(true), "controller ER", "controller generic ER");
		p.add(erToPE(), "controller generic ER", "controller simple PE");
		p.add(linkToComplex(), "controller simple PE", "controller PE");
		p.add(peToControl(), "controller PE", "Control");
		p.add(controlToInter(), "Control", "Interaction");
		p.add(new NOT(participantER()), "Interaction", "controller ER");
		p.add(participant(), "Interaction", "affected PE");
		p.add(linkToSpecific(), "affected PE", "affected simple PE");
		p.add(new Type(SequenceEntity.class), "affected simple PE");
		p.add(peToER(), "affected simple PE", "affected generic ER");
		p.add(peToER(), "affected generic ER", "affected ER");

		return p;
	}
1032917
private ProcPattern createPattern(Pattern pattern) {
        if (pattern.isEmpty()) {
            throw new IllegalStateException("Pattern elements list can't be empty.");
        }

        List<ProcPatternElement> elements = new ArrayList<ProcPatternElement>();
        for (PatternElement element : pattern.getElements()) {
            elements.add(patternElementFactory.create(element));
        }
        return new ProcPattern(elements);
    }
472294
public function getPattern() {
        return ($this->group->hasPattern() ? $this->group->getPattern() . ($this->pattern === '/' ? '' : '/') : '') . $this->pattern;
    }
44719
public function getFormatPattern()
    {
        static $kyr = self::KYR_CHARS;

        switch (true) {
            // X000XX77_OR_X000XX777
            case \preg_match("~^[{$kyr}]{1}\d{3}[{$kyr}]{2}\d{2,3}$~iu", $this->value) === 1:
                return self::FORMAT_PATTERN_1;

            // X000XX
            case \preg_match("~^[{$kyr}]{1}\d{3}[{$kyr}]{2}$~iu", $this->value) === 1:
                return self::FORMAT_PATTERN_2;

            // XX00077
            case \preg_match("~^[{$kyr}]{2}\d{3}\d{2}$~iu", $this->value) === 1:
                return self::FORMAT_PATTERN_3;

            // 0000XX77
            case \preg_match("~^\d{4}[{$kyr}]{2}\d{2}$~iu", $this->value) === 1:
                return self::FORMAT_PATTERN_4;

            // XX000077
            case \preg_match("~^[{$kyr}]{2}\d{4}\d{2}$~iu", $this->value) === 1:
                return self::FORMAT_PATTERN_5;

            // X000077
            case \preg_match("~^[{$kyr}]{1}\d{4}\d{2}$~iu", $this->value) === 1:
                return self::FORMAT_PATTERN_6;

            // 000X77
            case \preg_match("~^\d{3}[{$kyr}]{1}\d{2}$~iu", $this->value) === 1:
                return self::FORMAT_PATTERN_7;

            // 0000X77
            case \preg_match("~^\d{4}[{$kyr}]{1}\d{2}$~iu", $this->value) === 1:
                return self::FORMAT_PATTERN_8;
        }
    }
233961
public function make()
    {
        if (($params = $this->canBuild())) {
            $reflectionClass = new \ReflectionClass($this->className);
            $object = $reflectionClass->newInstanceArgs(is_array($params) ? $params : []);
            /**
             * Reset the object by removing default values used for typehinting
             * Then add our dependancies
             */
            $this->resetObject($object);
            foreach ($this->params as $key => $value) {
                $object->with($value, (is_numeric($key) ? null : $key));
            }
            $object->freeze();
            return $object;
        }
        return $this;
    }
447516
public function pattern($pattern = null)
        {
            if ($pattern === null) return $this->rulePattern;

            $this->rulePattern = $pattern;

            return $this;
        }
1240576
public function parse()
    {
        if (preg_match_all($this->pattern, $this->originalString, $matches, PREG_SET_ORDER)) {
            $this->parsed = [];
            foreach ($matches as $match) {
                $code = explode(';', static::$colorMaps[$match['color']]);
                $parsed = [];
                if ($match['prefix']) {
                    $parsed = array_merge($parsed, $this->parseLine($match['prefix']));
                }
                $parsed = array_merge($parsed, $this->parseLine($match['str'], $code[1]));
                if ($match['suffix']) {
                    $parsed = array_merge($parsed, $this->parseLine($match['suffix']));
                }
                /*
                $this->parsed = array_merge(
                    $this->parsed,
                    // $this->parseLine($match['prefix']),
                    $this->parseLine($match['str'], $code[1])
                    // $this->parseLine($match['suffix'])
                );
                */
               $this->parsed = array_merge($this->parsed, $parsed);
            }
        } else {
            $this->parsed = $this->parseLine($this->originalString, null);
        }

        return $this;
    }
399378
public function build()
    {
        $input = new BucketInput($this->namespace, $this->filters);
        $spec  = new Specification($input, $this->phases, $this->timeout);

        return new BucketMapReduce($spec);
    }
197389
public function getPattern($name = '')
    {
        if ('' === $name) {
            return $this->pattern;
        }

        return isset($this->pattern[$name]) ? $this->pattern[$name] : null;
    }
749538
private function build() {

        $this -> fill();

        $html = '<input type="'. $this -> type .'"';
        
        foreach($this -> attributes as $attribute => $value) {
            $html .= ' ' . $attribute . '="'. Escape :: attr($value) .'"';
        }

        $html .= '>';

        return $html;
    }
725669
private static function buildPattern($masks)
    {
        $pattern = array();
        $masks = is_array($masks) ? $masks : [$masks];
        foreach ($masks as $mask) {
            $mask = rtrim(strtr($mask, '\\', '/'), '/');
            $prefix = '';
            if ($mask === '') {
                continue;

            } elseif ($mask === '*') {
                return NULL;

            } elseif ($mask[0] === '/') { // absolute fixing
                $mask = ltrim($mask, '/');
                $prefix = '(?<=^/)';
            }
            $pattern[] = $prefix . strtr(preg_quote($mask, '#'),
                    array('\*\*' => '.*', '\*' => '[^/]*', '\?' => '[^/]', '\[\!' => '[^', '\[' => '[', '\]' => ']', '\-' => '-'));
        }

        return $pattern ? '#/(' . implode('|', $pattern) . ')\z#i' : NULL;
    }
786354
public function build()
    {
        $class = $this->getClassForType($this->type);
        $validator = new $class;
        $validator->setSpecification($this->specification);

        return $validator;
    }
549983
public static function init() {
		
		$found = false;
		$patternExtension = Config::getOption("patternExtension");
		self::loadRules();
		
		foreach (self::$rules as $rule) {
			if ($rule->test($patternExtension)) {
				self::$instance = $rule;
				$found = true;
				break;
			}
		}
		
		if (!$found) {
			Console::writeError("the supplied pattern extension didn't match a pattern loader rule. check your config...");
		}
		
	}
1247293
def build_string(self, *pattern, **kwargs):
        
        set_defaults(self._string_defaults, kwargs)
        set_defaults(self._defaults, kwargs)
        return StringPattern(*pattern, **kwargs)
53034
public function getPattern($key = null)
    {
        return isset($this->patterns[$key]) ? $this->patterns[$key] : $this->patterns;
    }
412275
public function build(): SetRequestInterceptionRequest
	{
		$instance = new SetRequestInterceptionRequest();
		if ($this->patterns === null) {
			throw new BuilderException('Property [patterns] is required.');
		}
		$instance->patterns = $this->patterns;
		return $instance;
	}
170012
public function getIdAndClassPattern()
    {
        $id = $this->getAttribute('id');
        $class = $this->getAttribute('class');

        $pattern = '';
        if (!empty($id)) {
            $pattern = '#'.$id.'|#'.$id;
        }
        if (!empty($class)) {
            if (!empty($pattern)) {
                $pattern .= '.'.$class.'|';
            }
            $pattern .= '.'.$class;
        }

        return empty($pattern) ? null : '/('.$pattern.')/';
    }