Differences
This shows you the differences between the selected revisions of the page.
library_remotefileinfo 2014-12-01 | library_remotefileinfo 2020-12-24 (current) | ||
Line 1: | Line 1: | ||
====== RemoteFileInfo Class ====== | ====== RemoteFileInfo Class ====== | ||
- | Represents data about remote file. | + | Represents data about a remote file. |
~~AD~~ | ~~AD~~ | ||
Line 17: | Line 17: | ||
===== Properties ===== | ===== Properties ===== | ||
^ Name ^ Description ^ | ^ Name ^ Description ^ | ||
- | | bool IsDirectory | Is file a directory? (i.e. ''FileType'' is ''D''). Read-only. | | + | | [[library_filepermissions|FilePermissions]] ==FilePermissions== | File permissions. Read-only. | |
- | | DateTime LastWriteTime | Timestamp of the last file modification. Read-only. | | + | | char ==FileType== | File type. ''-'' for regular file, ''D'' for directory, ''L'' for symbolic link, etc. Read-only. See also ''IsDirectory''. | |
- | | long Length | Size of the file in bytes. Read-only. | | + | | string ==FullName== | File path. See also ''Name''. Read-only. | |
- | | int Length32 | An alternative to ''Length''. Particularly useful for COM hosts that do not support 64-bit integers, such as Visual Basic. Throws ''OverflowException'', when the file size cannot be expressed using 32-bit integer. &beta_feature | | + | | string ==Group== | File group. Read-only. | |
- | | string Name | File name (with ''[[library_session_listdirectory|Session.ListDirectory]]'') or file path (with ''[[library_session_getfileinfo|Session.GetFileInfo]]''). Read-only. | | + | | bool ==IsDirectory== | Is file a directory? (i.e. ''FileType'' is ''D''). Read-only. | |
- | | [[library_filepermissions|FilePermissions]] FilePermissions | File permissions. Read-only. | | + | | bool ==IsParentDirectory== | Is it a reference to a parent directory (''..'')? Read-only. | |
- | | char FileType | File type. ''-'' for regular file, ''D'' for directory, ''L'' for symlink, etc. Read-only. See also ''IsDirectory''. | | + | | bool ==IsThisDirectory== | Is it a reference to this directory (''.'')? Read-only. | |
+ | | DateTime ==LastWriteTime== | Timestamp of the last file modification. Read-only. | | ||
+ | | long ==Length== | Size of the file in bytes. Read-only. | | ||
+ | | int ==Length32== | An alternative to ''Length''. Particularly useful for COM hosts, that do not support 64-bit integers, such as Visual Basic. Throws ''OverflowException'', when the file size cannot be expressed using 32-bit integer. Read-only. | | ||
+ | | string ==Name== | File name. See also ''FullName''. Read-only. | | ||
+ | | string ==Owner== | File owner. Read-only. | | ||
===== Methods ===== | ===== Methods ===== | ||
Line 30: | Line 35: | ||
===== Remarks ===== | ===== Remarks ===== | ||
- | Instance of the class can be created by the WinSCP assembly only. You can only get an instance of the class by calling ''[[library_session_listdirectory|Session.ListDirectory]]'' or ''[[library_session_getfileinfo|Session.GetFileInfo]]''. | + | This class can only be instantiated by the WinSCP assembly. To get an instance of the class, call ''[[library_session_listdirectory|Session.ListDirectory]]'' or ''[[library_session_getfileinfo|Session.GetFileInfo]]''. |
===== Examples ===== | ===== Examples ===== | ||
- | See example for ''[[library_session_listdirectory#example|Session.ListDirectory]]'' or ''[[library_session_getfiles#example|Session.GetFiles]]''. | + | See example for ''[[library_session_listdirectory#example|Session.ListDirectory]]''. |
==== Real-Life Examples ==== | ==== Real-Life Examples ==== | ||
- | * [[library_example_listing_files_matching_wildcard|Listing files matching wildcard]]; | + | * [[library_example_check_existence_timestamp|*]]; |
- | * [[library_example_recursive_search_text|Search recursively for text in remote directory / Grep files over SFTP/FTP protocol]]. | + | * [[library_example_listing_files_matching_wildcard|*]]; |
+ | * [[library_example_recursive_search_text|*]]; | ||
+ | * [[library_example_recursive_download_custom_error_handling|*]]; | ||
+ | * [[library_example_find_duplicate_files|*]]; | ||
+ | * [[script_custom_listing_format_csv|*]]. | ||