Add a custom alias

@param string $alias
@param string $type
@return static
165150
public function alias(string $alias, string $type): TypeCastInterface
    {
        $copy = clone $this;
        $copy->aliases[$alias] = $type;

        return $copy;
    }
71633
public function removeAlias($alias)
    {
        if (array_key_exists($alias, $this->aliases)) {
            unset($this->aliases[$alias]);
        }

        return $this;
    }
1208418
public function optional(string $alias, string $type): EntityDefinitionOptions {
    return $this->optional[$alias] = new EntityDefinitionOptions($alias, $type);
  }
533751
public function addTrait(string $traitName, string $alias = null)
    {
        $this->traits[] = $this->addUse($traitName, $alias);

        return $this;
    }
928226
public function add($original, $alias)
    {
        $alias = Input::checkAlias($alias);
        $this->aliases[$alias] = $original;
    }
410336
public function createAlias($alias)
    {
        class_alias('Pixie\\AliasFacade', $alias);
        $builder = $this->container->build('\\Pixie\\QueryBuilder\\QueryBuilderHandler', array($this));
        AliasFacade::setQueryBuilderInstance($builder);
    }
1198907
public function addAlias(string $key, string $alias): AliasResolver
    {
        $this->aliases[$key] = $alias;

        return $this;
    }
157231
public function registerAlias($alias, $file, $extension = null)
    {
        if ($extension === null) {
            $extension = File::extension($file);
        }

        $extension = strtolower($extension);

        if (!isset($this->aliases[$extension])) {
            $this->aliases[$extension] = [];
        }

        $this->aliases[$extension][$alias] = $file;

        return $this;
    }
780059
public function add($alias, $concrete = null)
    {
        $container = Container::getInstance();
        $container->add($alias, $concrete);
    }
728568
public function addGroupAlias($groupName, $alias)
    {
       if(is_array($alias))
           foreach($alias as $item)
               $this->groupAliasIndices[$item] = $groupName;
       else
           $this->groupAliasIndices[$alias] = $groupName;

        return $this;
    }
38247
public function addType($type)
    {
        if (is_string($type)) {
            $type = array($type);
        }

        foreach($type as $typ) {
            if (defined('self::' . strtoupper($typ)) && !in_array($typ, $this->_type)) {
                $this->_type[] = $typ;
            }

            if (($typ == self::ALL)) {
                $this->_type = array_keys($this->_cardLength);
            }
        }

        return $this;
    }
1071307
protected function addFilters($type, $filters)
	{
		if (isset($this->action[$type]))
		{
			$this->action[$type] .= '|'.$filters;
		}
		else
		{
			$this->action[$type] = $filters;
		}

		return $this;
	}
1314391
public function setAlias($alias) {
        if ($alias !== null && ! $this->argumentsParser->isOptionAlias($alias)) {
            throw new InvalidOptionAliasException(s(
                'A option alias must have this format: "-f", got: "%s"', $alias
            ));
        }

        $this->alias = $alias;

        return $this;
    }
460092
public function addAlias($alias, $tagName)
    {
        if($this->getComponentFactory($tagName)) {
            $this->alias[(string) $alias] = (string) $tagName;
        }
        return $this;
    }
776065
public function alias($alias)
    {
        $alias = (string)$alias;
        if (in_array($alias, $this->with)) {
            throw new \InvalidArgumentException("Cannot use alias '{$alias}' because a relation already uses it");
        }

        $this->alias = $alias;

        return $this;
    }
213089
public function addFileType($type): self
    {
        $type = '.' . trim($type, '. ');

        if (!isset($this->watchedTypes[$type])) {
            $this->watchedTypes[$type] = true;
        }

        return $this;
    }
602249
public function addAlias(string $alias, string $original): self
    {
        $this->aliases[$alias] = $original;
        return $this;
    }