UnionMemberTypes :
- = `|`? NamedType
- UnionMemberTypes | NamedType

@return array
@throws SyntaxErrorException
428810
protected function lexUnionMemberTypes(): array
    {
        $types = [];

        if ($this->skip(TokenKindEnum::EQUALS)) {
            // Optional leading pipe
            $this->skip(TokenKindEnum::PIPE);

            do {
                $types[] = $this->lexNamedType();
            } while ($this->skip(TokenKindEnum::PIPE));
        }

        return $types;
    }
1038763
public function getJoinString()
    {
        $statement = "";
        
        foreach ($this->join as $i => $join) {
            $statement .= " " . $join['type'] . " " . $join['table'];
            
            if ($join['alias']) {
                $statement .= " AS " . $join['alias'];
            }
            
            // Add ON criteria if specified.
            if ($join['criteria']) {
                $statement .= " ON ";
                
                foreach ($join['criteria'] as $x => $criterion) {
                    // Logically join each criterion with AND.
                    if ($x != 0) {
                        $statement .= " " . self::LOGICAL_AND . " ";
                    }
                    
                    // If the criterion does not include an equals sign, assume a
                    // column name and join against the same column from the previous
                    // table.
                    if (strpos($criterion, '=') === false) {
                        $statement .= $this->getJoinCriteriaUsingPreviousTable($i, $join['table'], $criterion);
                    } else {
                        $statement .= $criterion;
                    }
                }
            }
        }
        
        $statement = trim($statement);
        
        return $statement;
    }
388553
def parse_type(parser):
    # type: (Parser) -> Union[NamedType, NonNullType, ListType]
    """"""
    start = parser.token.start
    if skip(parser, TokenKind.BRACKET_L):
        ast_type = parse_type(parser)
        expect(parser, TokenKind.BRACKET_R)
        ast_type = ast.ListType(type=ast_type, loc=loc(parser, start))  # type: ignore

    else:
        ast_type = parse_named_type(parser)

    if skip(parser, TokenKind.BANG):
        return ast.NonNullType(type=ast_type, loc=loc(parser, start))

    return ast_type
1143579
private function optionalTypeHint() {
    static $array_callable_types = [T_ARRAY, T_CALLABLE];
    $node = NULL;
    if ($node = $this->tryMatchToken($array_callable_types)) {
      return $node;
    }
    elseif (in_array($this->currentType, self::$namespacePathTypes)) {
      return $this->name();
    }
    return NULL;
  }
192230
function UnionType(schema, opts) {
  Type.call(this);

  if (!Array.isArray(schema)) {
    throw new Error(f('non-array union schema: %j', schema));
  }
  if (!schema.length) {
    throw new Error('empty union');
  }
  this.types = Object.freeze(schema.map(function (obj) {
    return Type.forSchema(obj, opts);
  }));

  this._branchIndices = {};
  this.types.forEach(function (type, i) {
    if (Type.isType(type, 'union')) {
      throw new Error('unions cannot be directly nested');
    }
    var branch = type.branchName;
    if (this._branchIndices[branch] !== undefined) {
      throw new Error(f('duplicate union branch name: %j', branch));
    }
    this._branchIndices[branch] = i;
  }, this);
}
597781
public function getOperators()
    {
        return array(
            "<" => $this->translation->text('Less than'),
            ">" => $this->translation->text('Greater than'),
            "=" => $this->translation->text('Equal (is in list)'),
            "<=" => $this->translation->text('Less than or equal to'),
            ">=" => $this->translation->text('Greater than or equal to'),
            "!=" => $this->translation->text('Not equal (is not in list)')
        );
    }
808349
public function ConditionalTerm()
    {
        $conditionalFactors = array();
        $conditionalFactors[] = $this->ConditionalFactor();

        while ($this->lexer->isNextToken(Lexer::T_AND)) {
            $this->match(Lexer::T_AND);

            $conditionalFactors[] = $this->ConditionalFactor();
        }

        // Phase 1 AST optimization: Prevent AST\ConditionalTerm
        // if only one AST\ConditionalFactor is defined
        if (count($conditionalFactors) == 1) {
            return $conditionalFactors[0];
        }

        return new AST\ConditionalTerm($conditionalFactors);
    }
18117
final public static function getMembers(): array
    {
        if (!isset(self::$constants[static::class])) {
            $reflection = new ReflectionClass(static::class);
            $constants = self::sortConstants($reflection);
            self::guardConstants($constants);
            self::$constants[static::class] = $constants;
        }

        return self::$constants[static::class];
    }
961568
public static function enumTypes() {
        return [
            ButtonInterface::BUTTON_TYPE_DANGER,
            ButtonInterface::BUTTON_TYPE_DEFAULT,
            ButtonInterface::BUTTON_TYPE_INFO,
            ButtonInterface::BUTTON_TYPE_LINK,
            ButtonInterface::BUTTON_TYPE_PRIMARY,
            ButtonInterface::BUTTON_TYPE_SUCCESS,
            ButtonInterface::BUTTON_TYPE_WARNING,
        ];
    }
720385
private function initActionTypes()
    {
        $this->actionTypes = [];

        foreach ($this->loadActionTypes() as $type) {
            if (!$type instanceof ActionTypeInterface) {
                throw new UnexpectedTypeException($type, ActionTypeInterface::class);
            }

            $this->actionTypes[get_class($type)] = $type;
        }
    }
421013
def _get_union_type_name(type_names_to_union):
    """"""
    if not type_names_to_union:
        raise AssertionError(u'Expected a non-empty list of type names to union, received: '
                             u'{}'.format(type_names_to_union))
    return u'Union__' + u'__'.join(sorted(type_names_to_union))
549449
public function getMembershipTypes() {
    $types = [];

    foreach ($this->getMembershipPriceMatrix() as $membership_type) {
      $types[$membership_type['id']] = [
        'title' => $membership_type['title'],
        'description' => $membership_type['description'],
      ];
    }

    return $types;
  }
831555
private function parseOperand (){

		$negate = false;
		$offset = $this->pos+1;
		if( $offset >= $this->input_len ){
			return;
		}
		$char = $this->input[$offset];
		if( $char === '@' || $char === '(' ){
			$negate = $this->MatchChar('-');
		}

		$o = $this->MatchFuncs(array('parseSub','parseEntitiesDimension','parseEntitiesColor','parseEntitiesVariable','parseEntitiesCall'));

		if( $negate ){
			$o->parensInOp = true;
			$o = $this->NewObj1('Less_Tree_Negative',$o);
		}

		return $o;
	}
124234
private function multiLineString()
    {
        $values = array();
        $count  = $this->readCount();

        for ($i = 0; $i < $count; $i++) {
            $this->readByteOrder();

            $type = $this->readType();

            if ($this->getDimensionedPrimitive(self::WKB_TYPE_LINESTRING) !== $type) {
                throw new UnexpectedValueException($this->getBadTypeInTypeMessage($type, self::WKB_TYPE_MULTILINESTRING, array(self::WKB_TYPE_LINESTRING)));
            }

            $values[] = $this->readPoints($this->readCount());
        }

        return $values;
    }
724413
final public static function members()
    {
        $class = get_called_class();

        if (!array_key_exists($class, self::$members)) {
            self::$members[$class] = array();
            static::initializeMembers();
        }

        return self::$members[$class];
    }
303393
private function entriesType(): array
    {
        // This is an object list, so handle the 'entries' key.
        if (!isset($this->class)) {
            throw new \UnexpectedValueException('setClass() must be called before using this extractor.');
        }

        $collectionKeyType = new Type(Type::BUILTIN_TYPE_INT);
        $collectionValueType = new Type('object', false, $this->class);

        return [new Type(Type::BUILTIN_TYPE_ARRAY, false, null, true, $collectionKeyType, $collectionValueType)];
    }
1374704
def union(self):
        
        usegs = reduce(operator.or_, self.values())
        usegs.name = ' | '.join(self.keys())
        return usegs