ドキュメント

Unity Engine

Download Unity

Unity Engine

ResolveIsValid(AssetList)

Tests if any of the assets in the list have the conflicted state and can be resolved.
読み終わるまでの所要時間 1 分最終更新 19日前

Definition

public static bool ResolveIsValid(AssetList assets)

Parameters

assets

The list of asset to be resolved.

Returns

Type

Description

boolTrue if one or more assets in the list are resolvable. Otherwise, false.

Remarks

Returns true if one or more assets in the list are resolvable.

Examples

using System.Collections.Generic;using UnityEditor;using UnityEditor.VersionControl;using UnityEngine;public class EditorScript : MonoBehaviour{ [MenuItem("Version Control/ResolveIsValid")] public static void ExampleResolveIsValid() { AssetList assets = new AssetList(); assets.Add(Provider.GetAssetByPath("Assets/ExampleAsset.cs")); bool valid = Provider.ResolveIsValid(assets); Debug.Log("Can the file be resolved?" + valid); }}