Enumerates the types.

@return array Returns the types enumeration.
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,
        ];
    }
111811
protected function getSubTypes()
    {
        $subTypes = [];

        foreach ($this->types as $type) {
            if (substr($type,-2) === '[]') {
                $subTypes[] = substr($type, 0, -2);
            }
        }

        return $subTypes;
    }
1225536
public function getTypes()
    {
        $types = $this->config()->get('types');

        if ($this->allowed_types) {
            // Prioritise local field over global settings
            $allowed_types = $this->allowed_types;
        }
        if ($allowed_types = $this->config()->get('allowed_types')) {
           foreach ($allowed_types as $type) {
                if (!array_key_exists($type, $types)) {
                    user_error("{$type} is not a valid link type");
                }
            }

            foreach (array_diff_key($types, array_flip($allowed_types)) as $key => $value) {
                unset($types[$key]);
            }
        }
        $this->extend('updateTypes', $types);
        return $types;
    }
147837
protected function getTypesSorted()
    {
        $types = $this->getTypes();
        usort($types, function ($first, $second) {
            /* @var Type $first */
            /* @var Type $second */
            return $first->name == 'mixed' ? 1 : 0;
        });

        return $types;
    }
874943
protected function getTypeItems()
	{
		$typeManager = \Aimeos\MShop::create( $this->getContext(), 'service/type' );

		$search = $typeManager->createSearch( true )->setSlice( 0, 10000 );
		$search->setSortations( [$search->sort( '+', 'service.type.position' )] );

		return $this->map( $typeManager->searchItems( $search ) );
	}
1327660
public function getBlockTypes()
    {
        $types = array();
        foreach ($this->alBlocks as $block) {
            $type = $block->getType();
            if ( !in_array($type, $types)) {
                $types[] = $type;
            }
        }

        return $types;
    }
649421
public function getMessageTypes()
    {
        if ($this->messageTypes === null) {
            $this->messageTypes = array();
            $messageTypes = Mage::getConfig()->getNode(self::XML_PATH_MESSAGE_TYPES);
            if ($messageTypes) {
                foreach ($messageTypes->children() as $typeCode => $classAlias) {
                    $this->messageTypes[$typeCode] = (string)$classAlias;
                }
            }
        }

        return $this->messageTypes;
    }
950484
public function getNames()
    {
        $enums = [];

        foreach (static::toArray() as $name => $value) {
            if ($this->has($value)) {
                $enums[] = $name;
            }
        }

        return $enums;
    }
324173
protected function getTypesCollection()
    {
        if (null === $this->types) {
            $this->types = new Collection(
                array($this->type),
                $this->docblock ? $this->docblock->getContext() : null
            );
        }
        return $this->types;
    }
276546
public function getItemTypes()
	{
		$usedTypes = array_reduce( $this->elements, function( $carry, $element ) {
			foreach ( $element as $key => $entry )
			{
				$type = $entry['taxonomy_element']['type'];
				if ( empty( $type ) ) continue;

				if ( ! isset( $carry[ $type ] ) )
				{
					$carry[ $type ] = 1;
				}
			}

			return $carry;
		}, array() );

		return array_keys( $usedTypes );
	}
755154
public static function get_deleted_types() {
        $defaults = self::get_default_types();
        $deleted = array();
        foreach (self::get_custom_types() as $customentry) {
            if (!empty($customentry->deleted)) {
                $deleted[$customentry->extension] = $defaults[$customentry->extension];
            }
        }
        return $deleted;
    }
360842
public function getResourceTypes()
    {
        $types = [];
        foreach ($this as $entity) {
            $types[] = $entity->getType();
        }
        return array_unique($types);
    }
381655
public function getUsedTypeIds()
    {
        $types = array();

        $db   = $this->getDb();
        $rows = $db->fetchAll("SELECT DISTINCT `type` as typeid FROM " . $this->table);

        foreach ($rows as $row) {
            $types[] = $row['typeid'];
        }

        return $types;
    }
869187
public static function getTypes(): array
    {
        return [
            self::TYPE_DELIVERY => self::TYPE_DELIVERY,
            self::TYPE_SALE => self::TYPE_SALE,
            self::TYPE_REGULATION => self::TYPE_REGULATION,
            self::TYPE_RETURN => self::TYPE_RETURN,
        ];
    }
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;
  }
1354440
public function getTypes()
    {
        $schema = StaticSchema::inst();
        $tree = array_merge(
            [$this->rootClass],
            $schema->getDescendants($this->rootClass)
        );

        return array_map(function ($class) use ($tree, $schema) {
            return $schema->typeNameForDataObject($class);
        }, $tree);
    }
1192403
public function getOptions()
    {
        $types = $this->types();

        array_walk($types, function (&$classname) {
            $classname = $classname::getLabel();
        });

        return $types;
    }