Instance Method インスタンスメソッド

fileManager:shouldLinkItemAtPath:toPath:

Asks the delegate if a hard link should be created between the items at the two paths. 2つのパスでの項目間にハードリンクが作成されるべきか、委任先に尋ねます。

Declaration 宣言

- (BOOL)fileManager:(NSFileManager *)fileManager 
shouldLinkItemAtPath:(NSString *)srcPath 
             toPath:(NSString *)dstPath;

Parameters パラメータ

fileManager

The file manager object that is attempting to create the link. リンクの作成を試みているファイルマネージャオブジェクト。

srcPath

The path or a file or directory that fileManager is about to attempt to link. fileManagerがまさにリンクを試みようとするパスまたはファイルまたはディレクトリ。

dstPath

The path or a file or directory to which fileManager is about to attempt to link. それに対してfileManagerがまさにリンクを試みようとするパスまたはファイルまたはディレクトリ。

Return Value 戻り値

YES if the operation should proceed, otherwise NO. 操作を続行すべきならばYES、そうでないならばNO

Discussion 議論

If the item specified by destURL is a directory, returning NO prevents links from being created to both the directory and its children. destURLによって指定された項目がディレクトリならば、NOを返すことは、ディレクトリとそれの子の両方が作成されることを防ぎます。

This method performs the same task as the fileManager:shouldLinkItemAtURL:toURL: method, which is preferred over this method in macOS 10.6 and later. このメソッドは、macOS 10.6以降ではこのメソッドより好まれるfileManager:shouldLinkItemAtURL:toURL:メソッドと同じ業務を実行します。

See Also 参照

Linking an Item 項目をリンクする

Related Documentation 関連文書