Udostępnij za pośrednictwem


IBasicFileAttributes.Size Method

Definition

Returns the size of the file (in bytes).

[Android.Runtime.Register("size", "()J", "GetSizeHandler:Java.Nio.FileNio.Attributes.IBasicFileAttributesInvoker, Mono.Android, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null", ApiSince=26)]
public long Size ();
[<Android.Runtime.Register("size", "()J", "GetSizeHandler:Java.Nio.FileNio.Attributes.IBasicFileAttributesInvoker, Mono.Android, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null", ApiSince=26)>]
abstract member Size : unit -> int64

Returns

the file size, in bytes

Attributes

Remarks

Returns the size of the file (in bytes). The size may differ from the actual size on the file system due to compression, support for sparse files, or other reasons. The size of files that are not #isRegularFile regular files is implementation specific and therefore unspecified.

Java documentation for java.nio.file.attribute.BasicFileAttributes.size().

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to