C# 클래스 InTheHand.Storage.StorageFile

Represents a file. Provides information about the file and its content, and ways to manipulate them.
PlatformVersion supported AndroidAndroid 4.4 and later iOSiOS 9.0 and later tvOStvOS 9.0 and later TizenTizen 3.0 Windows UWPWindows 10 Windows StoreWindows 8.1 or later Windows Phone StoreWindows Phone 8.1 or later Windows Phone SilverlightWindows Phone 8.0 or later Windows (Desktop Apps)Windows Vista or later
상속: IStorageFile, IStorageItem, IStorageItem2
파일 보기 프로젝트 열기: inthehand/Charming 1 사용 예제들

공개 메소드들

메소드 설명
CopyAndReplaceAsync ( IStorageFile fileToReplace ) : System.Threading.Tasks.Task

Replaces the specified file with a copy of the current file.

CopyAsync ( IStorageFolder destinationFolder ) : Task

Creates a copy of the file in the specified folder.

CopyAsync ( IStorageFolder destinationFolder, string desiredNewName ) : Task

Creates a copy of the file in the specified folder and renames the copy.

DeleteAsync ( ) : System.Threading.Tasks.Task

Deletes the current file.

DeleteAsync ( StorageDeleteOption option ) : System.Threading.Tasks.Task

Deletes the current file, optionally deleting the item permanently.

GetBasicPropertiesAsync ( ) : Task

Gets the basic properties of the current file.

GetFileFromPathAsync ( string path ) : Task

Gets a StorageFile object to represent the file at the specified path.

GetParentAsync ( ) : Task

Gets the parent folder of the current file.

IsEqual ( IStorageItem item ) : bool

Indicates whether the current file is equal to the specified file.

IsOfType ( StorageItemTypes type ) : bool

Determines whether the current StorageFile matches the specified StorageItemTypes value.

MoveAndReplaceAsync ( IStorageFile fileToReplace ) : System.Threading.Tasks.Task

Moves the current file to the location of the specified file and replaces the specified file in that location.

MoveAsync ( IStorageFolder destinationFolder ) : System.Threading.Tasks.Task

Moves the current file to the specified folder and renames the file according to the desired name.

MoveAsync ( IStorageFolder destinationFolder, string desiredNewName ) : System.Threading.Tasks.Task

Moves the current file to the specified folder and renames the file according to the desired name.

RenameAsync ( string desiredName ) : System.Threading.Tasks.Task

Renames the current file.

RenameAsync ( string desiredName, NameCollisionOption option ) : System.Threading.Tasks.Task

Renames the current file. This method also specifies what to do if an existing item in the current file's location has the same name.

비공개 메소드들

메소드 설명
StorageFile ( Windows file ) : System
StorageFile ( string path ) : System

메소드 상세

CopyAndReplaceAsync() 공개 메소드

Replaces the specified file with a copy of the current file.
public CopyAndReplaceAsync ( IStorageFile fileToReplace ) : System.Threading.Tasks.Task
fileToReplace IStorageFile
리턴 System.Threading.Tasks.Task

CopyAsync() 공개 메소드

Creates a copy of the file in the specified folder.
public CopyAsync ( IStorageFolder destinationFolder ) : Task
destinationFolder IStorageFolder The destination folder where the copy of the file is created.
리턴 Task

CopyAsync() 공개 메소드

Creates a copy of the file in the specified folder and renames the copy.
public CopyAsync ( IStorageFolder destinationFolder, string desiredNewName ) : Task
destinationFolder IStorageFolder The destination folder where the copy of the file is created.
desiredNewName string The new name for the copy of the file created in the destinationFolder.
리턴 Task

DeleteAsync() 공개 메소드

Deletes the current file.
public DeleteAsync ( ) : System.Threading.Tasks.Task
리턴 System.Threading.Tasks.Task

DeleteAsync() 공개 메소드

Deletes the current file, optionally deleting the item permanently.
public DeleteAsync ( StorageDeleteOption option ) : System.Threading.Tasks.Task
option StorageDeleteOption
리턴 System.Threading.Tasks.Task

GetBasicPropertiesAsync() 공개 메소드

Gets the basic properties of the current file.
public GetBasicPropertiesAsync ( ) : Task
리턴 Task

GetFileFromPathAsync() 공개 정적인 메소드

Gets a StorageFile object to represent the file at the specified path.
public static GetFileFromPathAsync ( string path ) : Task
path string The path of the file to get a StorageFile to represent. /// If your path uses slashes, make sure you use backslashes(\). /// Forward slashes(/) are not accepted by this method.
리턴 Task

GetParentAsync() 공개 메소드

Gets the parent folder of the current file.
public GetParentAsync ( ) : Task
리턴 Task

IsEqual() 공개 메소드

Indicates whether the current file is equal to the specified file.
public IsEqual ( IStorageItem item ) : bool
item IStorageItem The object that represents a file to compare against.
리턴 bool

IsOfType() 공개 메소드

Determines whether the current StorageFile matches the specified StorageItemTypes value.
public IsOfType ( StorageItemTypes type ) : bool
type StorageItemTypes The value to match against.
리턴 bool

MoveAndReplaceAsync() 공개 메소드

Moves the current file to the location of the specified file and replaces the specified file in that location.
public MoveAndReplaceAsync ( IStorageFile fileToReplace ) : System.Threading.Tasks.Task
fileToReplace IStorageFile The file to replace.
리턴 System.Threading.Tasks.Task

MoveAsync() 공개 메소드

Moves the current file to the specified folder and renames the file according to the desired name.
public MoveAsync ( IStorageFolder destinationFolder ) : System.Threading.Tasks.Task
destinationFolder IStorageFolder The destination folder where the file is moved.
리턴 System.Threading.Tasks.Task

MoveAsync() 공개 메소드

Moves the current file to the specified folder and renames the file according to the desired name.
public MoveAsync ( IStorageFolder destinationFolder, string desiredNewName ) : System.Threading.Tasks.Task
destinationFolder IStorageFolder The destination folder where the file is moved.
desiredNewName string The desired name of the file after it is moved.
리턴 System.Threading.Tasks.Task

RenameAsync() 공개 메소드

Renames the current file.
public RenameAsync ( string desiredName ) : System.Threading.Tasks.Task
desiredName string The desired, new name of the current item.
리턴 System.Threading.Tasks.Task

RenameAsync() 공개 메소드

Renames the current file. This method also specifies what to do if an existing item in the current file's location has the same name.
public RenameAsync ( string desiredName, NameCollisionOption option ) : System.Threading.Tasks.Task
desiredName string The desired, new name of the current file. /// If there is an existing item in the current file's location that already has the specified desiredName, the specified determines how the system responds to the conflict.
option NameCollisionOption The enum value that determines how the system responds if the desiredName is the same as the name of an existing item in the current file's location.
리턴 System.Threading.Tasks.Task