语言

ISecureDirectoryStream.GetFileAttributeView 方法

定义

重载

名称 说明
GetFileAttributeView(Class)

返回用于访问此目录的文件属性的新文件属性视图。

GetFileAttributeView(Object, Class, LinkOption[])

返回用于访问此目录的文件属性的新文件属性视图。

GetFileAttributeView(Class)

返回用于访问此目录的文件属性的新文件属性视图。

[Android.Runtime.Register("getFileAttributeView", "(Ljava/lang/Class;)Ljava/nio/file/attribute/FileAttributeView;", "GetGetFileAttributeView_Ljava_lang_Class_Handler:Java.Nio.FileNio.ISecureDirectoryStreamInvoker, Mono.Android, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null", ApiSince=26)]
[Java.Interop.JavaTypeParameters(new System.String[] { "V extends java.nio.file.attribute.FileAttributeView" })]
public Java.Lang.Object? GetFileAttributeView(Java.Lang.Class? type);
[<Android.Runtime.Register("getFileAttributeView", "(Ljava/lang/Class;)Ljava/nio/file/attribute/FileAttributeView;", "GetGetFileAttributeView_Ljava_lang_Class_Handler:Java.Nio.FileNio.ISecureDirectoryStreamInvoker, Mono.Android, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null", ApiSince=26)>]
[<Java.Interop.JavaTypeParameters(new System.String[] { "V extends java.nio.file.attribute.FileAttributeView" })>]
abstract member GetFileAttributeView : Java.Lang.Class -> Java.Lang.Object

参数

type
Class

Class对应于文件属性视图的对象

返回

绑定到此目录流的指定类型的新文件属性视图,或者 null 属性视图类型不可用

属性

注解

返回用于访问此目录的文件属性的新文件属性视图。

生成的文件属性视图可用于读取或更新此 (打开) 目录的属性。 该 type 参数指定属性视图的类型,并且该方法返回该类型的实例(如果受支持)。 调用此方法以获取 BasicFileAttributeView 始终返回绑定到此打开目录的该类的实例。

生成的文件属性视图的状态与此目录流紧密相连。 目录流完成后 #close closed,读取或更新属性的所有方法都将引发 ClosedDirectoryStreamException ClosedDirectoryStreamException。

Java文档java.nio.file.SecureDirectoryStream.getFileAttributeView(java.lang.Class<V>)。

本页的某些部分是根据 创建和共享的工作进行的修改,并根据 许可证中所述的条款使用。

适用于

GetFileAttributeView(Object, Class, LinkOption[])

返回用于访问此目录的文件属性的新文件属性视图。

[Android.Runtime.Register("getFileAttributeView", "(Ljava/lang/Object;Ljava/lang/Class;[Ljava/nio/file/LinkOption;)Ljava/nio/file/attribute/FileAttributeView;", "GetGetFileAttributeView_Ljava_lang_Object_Ljava_lang_Class_arrayLjava_nio_file_LinkOption_Handler:Java.Nio.FileNio.ISecureDirectoryStreamInvoker, Mono.Android, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null", ApiSince=26)]
[Java.Interop.JavaTypeParameters(new System.String[] { "V extends java.nio.file.attribute.FileAttributeView" })]
public Java.Lang.Object? GetFileAttributeView(Java.Lang.Object? path, Java.Lang.Class? type, params Java.Nio.FileNio.LinkOption[]? options);
[<Android.Runtime.Register("getFileAttributeView", "(Ljava/lang/Object;Ljava/lang/Class;[Ljava/nio/file/LinkOption;)Ljava/nio/file/attribute/FileAttributeView;", "GetGetFileAttributeView_Ljava_lang_Object_Ljava_lang_Class_arrayLjava_nio_file_LinkOption_Handler:Java.Nio.FileNio.ISecureDirectoryStreamInvoker, Mono.Android, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null", ApiSince=26)>]
[<Java.Interop.JavaTypeParameters(new System.String[] { "V extends java.nio.file.attribute.FileAttributeView" })>]
abstract member GetFileAttributeView : Java.Lang.Object * Java.Lang.Class * Java.Nio.FileNio.LinkOption[] -> Java.Lang.Object

参数

path
Object

文件的路径

type
Class

Class对应于文件属性视图的对象

options
LinkOption[]

指示如何处理符号链接的选项

返回

绑定到此目录流的指定类型的新文件属性视图,或者 null 属性视图类型不可用

属性

注解

Java文档java.nio.file.SecureDirectoryStream.getFileAttributeView(java.lang.Class)。

Java参考java.nio.file.SecureDirectoryStream.getFileAttributeView。

本页的某些部分是根据 创建和共享的工作进行的修改,并根据 许可证中所述的条款使用。

适用于