用于访问资源并针对资源执行操作的接口。
ActiveRefreshImportMode | Gets the refresh import mode currently in use by the asset database. |
DesiredWorkerCount | The desired number of processes to use when importing assets, during an asset database refresh. |
GlobalArtifactDependencyVersion | Changes during Refresh if anything has changed that can invalidate any artifact. |
GlobalArtifactProcessedVersion | Changes whenever a new artifact is added to the artifact database. |
onImportPackageItemsCompleted | Callback raised whenever a package import successfully completes that lists the items selected to be imported. |
AddObjectToAsset | 将 objectToAdd 添加到 path 下的现有资源中。 |
AllowAutoRefresh | 递减 Unity 用于确定是否允许自动 AssetDatabase 刷新行为的内部计数器。 |
AssetPathExists | Check whether an asset exists at the given path in the database. |
AssetPathToGUID | 获取 path 下资源的 GUID。 |
CanConnectToCacheServer | Checks the availability of the Cache Server. |
CanOpenAssetInEditor | Checks if Unity can open an asset in the Editor. |
CanOpenForEdit | Query whether an Asset file can be opened for editing in version control and is not exclusively locked by another user or otherwise unavailable. |
ClearImporterOverride | 清除资源的导入器覆盖。 |
ClearLabels | 删除附加到资源的所有标签。 |
CloseCacheServerConnection | Closes an active cache server connection. If no connection is active, then it does nothing. |
Contains | 对象是否为资源? |
CopyAsset | 复制 path 下的资源并将其存储在 newPath 下。 |
CopyAssets | Duplicates assets in paths and stores them in newPaths. |
CreateAsset | Creates a new native Unity asset. |
CreateFolder | Creates a new folder, in the specified parent folder.The parent folder string must start with the "Assets" folder, and all folders within the parent folder string must already exist. For example, when specifying "Assets/ParentFolder1/Parentfolder2/", the new folder will be created in "ParentFolder2" only if ParentFolder1 and ParentFolder2 already exist. |
DeleteAsset | Deletes the specified asset or folder. |
DeleteAssets | Lets you delete multiple assets or folders at once with performance benefits under version control. |
DisallowAutoRefresh | 递增 Unity 用于确定是否允许自动 AssetDatabase 刷新行为的内部计数器。 |
ExportPackage | 将由 **assetPathNames** 标识的资源导出到 **fileName** 中的 unitypackage 文件中。 |
ExtractAsset | 通过在导入资源(例如,FBX 文件)中提取外部资源,在对象(例如,材质)中创建此资源。 |
FindAssets | 使用搜索筛选器字符串搜索资源数据库。 |
ForceReserializeAssets | 强制加载给定资源并将其重新序列化,这样会将所有待定数据更改都刷新到磁盘。 |
ForceToDesiredWorkerCount | Forces the Editor to use the desired amount of worker processes. Unity will either spawn new worker processes or shut down idle worker processes to reach the desired number. |
GenerateUniqueAssetPath | 为资源创建一个新的唯一路径。 |
GetAllAssetBundleNames | 返回资源数据库中所有的 AssetBundle 名称。 |
GetAssetBundleDependencies | 给定一个 **assetBundleName**,返回其依赖的 AssetBundle 列表。 |
GetAssetDependencyHash | 返回资源所有依赖项的哈希值。 |
GetAssetOrScenePath | 返回相对于存储资源的项目文件夹的路径名称。 |
GetAssetPath | 返回相对于存储资源的项目文件夹的路径名称。 |
GetAssetPathFromTextMetaFilePath | 获取与 .meta 文本文件关联的资源文件的路径。 |
GetAssetPathsFromAssetBundle | 返回一个数组,其中包含使用指定资源包名称标记的所有资源的路径。 |
GetAssetPathsFromAssetBundleAndAssetName | 获取所有标有 assetBundleName 且有指定 assetName 的 资源的资源路径。 |
GetAvailableImporters | Gets the importer types associated with a given Asset path. |
GetCachedIcon | 在给定资源路径下检索资源的图标。 |
GetCacheServerAddress | Gets the IP address of the Cache Server in Editor Settings. |
GetCacheServerEnableDownload | Gets the Cache Server Download option from Editor Settings. |
GetCacheServerEnableUpload | Gets the Cache Server Upload option from Editor Settings. |
GetCacheServerNamespacePrefix | Gets the Cache Server Namespace prefix set in Editor Settings. |
GetCacheServerPort | Gets the Port number of the Cache Server in Editor Settings. |
GetCurrentCacheServerIp | 获取 Editor 当前使用的缓存服务器的 IP 地址。 |
GetDefaultImporter | Returns the Default Importer associated with the asset located at the supplied path. When no Importer override is set, then the default importer is used. See Also: AssetDatabase.GetImporterOverride, AssetDatabase.ClearImporterOverride. |
GetDependencies | 返回一个数组,其中包含作为指定 **pathName** 处资源的依赖关系的所有资源。**注意:**GetDependencies() 获取其他资源所引用的资源。例如,一个场景可以包含许多附加了材质的 GameObjects。在此情况下,GetDependencies() 会返回材质资源的路径,而不是 GameObjects,因为这些不是磁盘上的资源。 |
GetImplicitAssetBundleName | 返回给定资源所属的 AssetBundle 的名称。 |
GetImplicitAssetBundleVariantName | 返回给定资源所属的 AssetBundle 变体的名称。 |
GetImporterOverride | 返回覆盖导入器的类型。 |
GetImporterType | Returns the type of importer associated with an asset without loading the asset. |
GetImporterTypes | Returns the types of importers associated with the specified array of assets, without loading those assets. |
GetLabels | 返回给定资源上的所有标签。 |
GetMainAssetTypeAtPath | 返回 assetPath 下主资源对象的类型。 |
GetSubFolders | 给定 Assets 文件夹中目录相对于项目文件夹的路径,此方法将返回其所有子目录的数组。 |
GetTextMetaFilePathFromAssetPath | 获取与资源关联的 .meta 文本文件的路径。 |
GetTypeFromPathAndFileID | Gets an object's type from an Asset path and a local file identifier. |
GetUnusedAssetBundleNames | 返回资源数据库中所有未使用的 assetBundle 名称。 |
GUIDFromAssetPath | 获取 path 下资源的 GUID。 |
GUIDToAssetPath | Gets the corresponding asset path for the supplied GUID, or an empty string if the GUID can't be found. |
ImportAsset | 在路径下导入资源。 |
ImportPackage | 将 **packagePath** 下的包导入到当前项目。 |
InstanceIDsToGUIDs | Sets a NativeArray of UnityEditor.GUIDs for every valid Instance ID that is an asset. |
IsCacheServerEnabled | Checks whether the Cache Server is enabled in Project Settings. |
IsConnectedToCacheServer | Checks connection status of the Cache Server. |
IsDirectoryMonitoringEnabled | Reports whether Directory Monitoring is enabled. |
IsForeignAsset | 确定资源是否为外部资源。 |
IsMainAsset | 资源是否为 Project 窗口中的主资源? |
IsMainAssetAtPathLoaded | 如果在内存中加载 assetPath 下的主资源对象,则返回 true。 |
IsMetaFileOpenForEdit | 查询资源的元数据 (.meta) 文件是否在版本控制中打开以供编辑。 |
IsNativeAsset | 确定资源是否为原生资源。 |
IsOpenForEdit | 查询是否在版本控制中打开资源文件进行编辑。 |
IsSubAsset | 资源是否构成了其他资源的一部分? |
IsValidFolder | 给定文件夹的路径,如果存在,则返回 true;否则,返回 false。 |
LoadAllAssetRepresentationsAtPath | 返回 assetPath 下所有的子资源。 |
LoadAllAssetsAtPath | 返回一个含 assetPath 下所有资源的数组。 |
LoadAssetAtPath | 返回给定路径 **assetPath** 下 **type** 类型的第一个资源对象。 |
LoadMainAssetAtPath | 返回 assetPath 下的主资源对象。The "main" Asset is the Asset at the root of a hierarchy (such as a Maya file which may contain multiples meshes and GameObjects). |
LoadObjectAsync | Loads a specific Object and its dependencies from an Asset file asynchronously. |
MakeEditable | 在版本控制中使文件成为“打开以进行编辑”。 |
MoveAsset | 将资源文件(或文件夹)从一个文件夹移动到另一个文件夹。 |
MoveAssetsToTrash | Lets you move multiple assets or folders to trash at once with performance benefits under version control. |
MoveAssetToTrash | Moves the specified asset or folder to the OS trash. |
OpenAsset | 使用关联的应用程序打开资源。 |
Refresh | 导入所有更改的资源。 |
RefreshSettings | Apply pending Editor Settings changes to the Asset pipeline. |
RegisterCustomDependency | Allows you to register a custom dependency that Assets can be dependent on. If you register a custom dependency, and specify that an Asset is dependent on it, then the Asset will get re-imported if the custom dependency changes. |
ReleaseCachedFileHandles | 调用此函数将释放 Unity 内部缓存的文件句柄。这允许安全地修改资源或元文件,从而避免潜在的文件共享 IO 错误。 |
RemoveAssetBundleName | 从资源数据库中删除 assetBundle 名称。ForceRemove 标志用于指示您是否要将其删除,即使您正在使用它。 |
RemoveObjectFromAsset | 从其资源中删除对象(另外请参阅:AssetDatabase.AddObjectToAsset)。 |
RemoveUnusedAssetBundleNames | 删除资源数据库中所有未使用的 assetBundle 名称。 |
RenameAsset | 为资源文件重命名。 |
ResetCacheServerReconnectTimer | Resets the internal cache server connection reconnect timer values. The default delay timer value is 1 second, and the max delay value is 5 minutes. Everytime a connection attempt fails it will double the delay timer value, until a maximum time of the max value. |
SaveAssetIfDirty | Writes all unsaved changes to the specified asset to disk. |
SaveAssets | 将所有未保存的资源更改写入磁盘。 |
SetImporterOverride | 将特定导入器设置为用于资源。 |
SetLabels | 替换资源上的标签列表。 |
SetMainObject | 指定资源文件中的哪个对象在下次导入后应成为主对象。 |
StartAssetEditing | Places the Asset Database into a state that temporarily prevents automatic import, allowing you to group several asset imports together into one larger import. |
StopAssetEditing | Ends the Asset Database's temporary paused state, allowing it to resume normal automatic imports. |
TryGetAssetFolderInfo | Get AssetDatabase specific information about a folder. |
TryGetGUIDAndLocalFileIdentifier | 从对象实例 ID 中获取 GUID 和本地文件 ID。 |
UnregisterCustomDependencyPrefixFilter | Removes custom dependencies that match the prefixFilter. |
ValidateMoveAsset | 检查是否可以将资源文件从一个文件夹移动到另一文件夹。(不是真正移动文件)。 |
WriteImportSettingsIfDirty | 将导入设置写入磁盘。 |
cacheServerConnectionChanged | Unity raises this event when Cache Server connection is changed. |
importPackageCancelled | 用户取消导入包时引发的回调。 |
importPackageCompleted | 成功导入包时引发的回调。 |
importPackageFailed | 包导入失败时引发的回调。 |
importPackageStarted | 开始导入包时引发的回调。 |
ImportPackageCallback | AssetDatabase.ImportPackage 回调要调用的委托。**packageName** 是引发回调的包的名称。 |
ImportPackageFailedCallback | AssetDatabase.ImportPackage 回调要调用的委托。**packageName** 是引发回调的包的名称。**errorMessage** 是失败原因。 |