api/symfony/Component/AssetMapper/ImportMap/ImportMapEntry.yaml

35 lines
1.9 KiB
YAML
Raw Normal View History

2024-09-26 09:03:21 +00:00
name: ImportMapEntry
class_comment: null
dependencies: []
properties: []
methods:
- name: isRemotePackage
visibility: public
parameters: []
comment: "# * Represents an item that should be in the importmap.\n# *\n# * @author\
\ Ryan Weaver <ryan@symfonycasts.com>\n# */\n# final class ImportMapEntry\n# {\n\
# private function __construct(\n# public readonly string $importName,\n# public\
\ readonly ImportMapType $type,\n# /**\n# * A logical path, relative path or absolute\
\ path to the file.\n# */\n# public readonly string $path,\n# public readonly\
\ bool $isEntrypoint,\n# /**\n# * The version of the package (remote only).\n\
# */\n# public readonly ?string $version,\n# /**\n# * The full \"package-name/path\"\
\ (remote only).\n# */\n# public readonly ?string $packageModuleSpecifier,\n#\
\ ) {\n# }\n# \n# public static function createLocal(string $importName, ImportMapType\
\ $importMapType, string $path, bool $isEntrypoint): self\n# {\n# return new self($importName,\
\ $importMapType, $path, $isEntrypoint, null, null);\n# }\n# \n# public static\
\ function createRemote(string $importName, ImportMapType $importMapType, string\
\ $path, string $version, string $packageModuleSpecifier, bool $isEntrypoint):\
\ self\n# {\n# return new self($importName, $importMapType, $path, $isEntrypoint,\
\ $version, $packageModuleSpecifier);\n# }\n# \n# public function getPackageName():\
\ string\n# {\n# return self::splitPackageNameAndFilePath($this->packageModuleSpecifier)[0];\n\
# }\n# \n# public function getPackagePathString(): string\n# {\n# return self::splitPackageNameAndFilePath($this->packageModuleSpecifier)[1];\n\
# }\n# \n# /**\n# * @psalm-assert-if-true !null $this->version\n# * @psalm-assert-if-true\
\ !null $this->packageModuleSpecifier"
- name: splitPackageNameAndFilePath
visibility: public
parameters:
- name: packageModuleSpecifier
comment: null
traits: []
interfaces: []