Package system.io
Class File
- java.lang.Object
-
- org.mases.jcobridge.netreflection.NetObject
-
- system.io.File
-
- All Implemented Interfaces:
IJCOBridgeReflected
public class File extends NetObject
The base .NET class managing System.IO.File, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089..NET documentation at https://docs.microsoft.com/en-us/dotnet/api/System.IO.File
Powered by JCOBridge: more info at https://www.jcobridge.com
- Author:
- MASES s.r.l https://masesgroup.com
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.StringassemblyFullNameFully assembly qualified name: mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089static java.lang.StringassemblyShortNameAssembly name: mscorlibstatic java.lang.StringclassNameQualified class name: System.IO.Filestatic JCTypeclassTypeThe type managed from JCOBridge.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static voidAppendAllText(java.lang.String path, java.lang.String contents)static voidAppendAllText(java.lang.String path, java.lang.String contents, Encoding encoding)static StreamWriterAppendText(java.lang.String path)static Filecast(IJCOBridgeReflected from)Try to cast theIJCOBridgeReflectedinstance intoFile, a cast assert is made to check if types are compatible.static voidCopy(java.lang.String sourceFileName, java.lang.String destFileName)static voidCopy(java.lang.String sourceFileName, java.lang.String destFileName, boolean overwrite)static FileStreamCreate(java.lang.String path)static FileStreamCreate(java.lang.String path, int bufferSize)static FileStreamCreate(java.lang.String path, int bufferSize, FileOptions options)static FileStreamCreate(java.lang.String path, int bufferSize, FileOptions options, FileSecurity fileSecurity)static StreamWriterCreateText(java.lang.String path)static voidDecrypt(java.lang.String path)static voidDelete(java.lang.String path)static voidEncrypt(java.lang.String path)static booleanExists(java.lang.String path)static FileSecurityGetAccessControl(java.lang.String path)static FileSecurityGetAccessControl(java.lang.String path, AccessControlSections includeSections)static FileAttributesGetAttributes(java.lang.String path)static DateTimeGetCreationTime(java.lang.String path)static DateTimeGetCreationTimeUtc(java.lang.String path)java.lang.StringgetJCOAssemblyName()Returns the reflected Assembly namejava.lang.StringgetJCOClassName()Returns the reflected Class namejava.lang.ObjectgetJCOInstance()Returns the instantiated classjava.lang.StringgetJCOObjectName()Returns the reflected Class name used to build the objectJCTypegetJCOType()Returns the instantiated class Typestatic DateTimeGetLastAccessTime(java.lang.String path)static DateTimeGetLastAccessTimeUtc(java.lang.String path)static DateTimeGetLastWriteTime(java.lang.String path)static DateTimeGetLastWriteTimeUtc(java.lang.String path)static voidMove(java.lang.String sourceFileName, java.lang.String destFileName)static FileStreamOpen(java.lang.String path, FileMode mode)static FileStreamOpen(java.lang.String path, FileMode mode, FileAccess access)static FileStreamOpen(java.lang.String path, FileMode mode, FileAccess access, FileShare share)static FileStreamOpenRead(java.lang.String path)static StreamReaderOpenText(java.lang.String path)static FileStreamOpenWrite(java.lang.String path)static byte[]ReadAllBytes(java.lang.String path)static java.lang.String[]ReadAllLines(java.lang.String path)static java.lang.String[]ReadAllLines(java.lang.String path, Encoding encoding)static java.lang.StringReadAllText(java.lang.String path)static java.lang.StringReadAllText(java.lang.String path, Encoding encoding)static voidReplace(java.lang.String sourceFileName, java.lang.String destinationFileName, java.lang.String destinationBackupFileName)static voidReplace(java.lang.String sourceFileName, java.lang.String destinationFileName, java.lang.String destinationBackupFileName, boolean ignoreMetadataErrors)static voidSetAccessControl(java.lang.String path, FileSecurity fileSecurity)static voidSetAttributes(java.lang.String path, FileAttributes fileAttributes)static voidSetCreationTime(java.lang.String path, DateTime creationTime)static voidSetCreationTimeUtc(java.lang.String path, DateTime creationTimeUtc)voidsetJCOInstance(JCObject instance)static voidSetLastAccessTime(java.lang.String path, DateTime lastAccessTime)static voidSetLastAccessTimeUtc(java.lang.String path, DateTime lastAccessTimeUtc)static voidSetLastWriteTime(java.lang.String path, DateTime lastWriteTime)static voidSetLastWriteTimeUtc(java.lang.String path, DateTime lastWriteTimeUtc)static voidWriteAllBytes(java.lang.String path, byte[] bytes)static voidWriteAllBytes(java.lang.String dupParam0, JCORefOut dupParam1)static voidWriteAllLines(java.lang.String path, java.lang.String[] contents)static voidWriteAllLines(java.lang.String path, java.lang.String[] contents, Encoding encoding)static voidWriteAllLines(java.lang.String dupParam0, JCORefOut dupParam1)static voidWriteAllLines(java.lang.String dupParam0, JCORefOut dupParam1, Encoding dupParam2)static voidWriteAllText(java.lang.String path, java.lang.String contents)static voidWriteAllText(java.lang.String path, java.lang.String contents, Encoding encoding)
-
-
-
Field Detail
-
assemblyFullName
public static final java.lang.String assemblyFullName
Fully assembly qualified name: mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089- See Also:
- Constant Field Values
-
assemblyShortName
public static final java.lang.String assemblyShortName
Assembly name: mscorlib- See Also:
- Constant Field Values
-
className
public static final java.lang.String className
Qualified class name: System.IO.File- See Also:
- Constant Field Values
-
-
Method Detail
-
getJCOAssemblyName
public java.lang.String getJCOAssemblyName()
Description copied from interface:IJCOBridgeReflectedReturns the reflected Assembly name- Specified by:
getJCOAssemblyNamein interfaceIJCOBridgeReflected- Overrides:
getJCOAssemblyNamein classNetObject- Returns:
- A
Stringrepresenting the Fullname of reflected Assembly
-
getJCOClassName
public java.lang.String getJCOClassName()
Description copied from interface:IJCOBridgeReflectedReturns the reflected Class name- Specified by:
getJCOClassNamein interfaceIJCOBridgeReflected- Overrides:
getJCOClassNamein classNetObject- Returns:
- A
Stringrepresenting the Fullname of reflected Class
-
getJCOObjectName
public java.lang.String getJCOObjectName()
Description copied from interface:IJCOBridgeReflectedReturns the reflected Class name used to build the object- Specified by:
getJCOObjectNamein interfaceIJCOBridgeReflected- Overrides:
getJCOObjectNamein classNetObject- Returns:
- A
Stringrepresenting the name used to allocated the object in CLR context
-
getJCOInstance
public java.lang.Object getJCOInstance()
Description copied from interface:IJCOBridgeReflectedReturns the instantiated class- Specified by:
getJCOInstancein interfaceIJCOBridgeReflected- Overrides:
getJCOInstancein classNetObject- Returns:
- An
Objectrepresenting the CLR instance of the instantiated Class
-
setJCOInstance
public void setJCOInstance(JCObject instance)
- Overrides:
setJCOInstancein classNetObject
-
getJCOType
public JCType getJCOType()
Description copied from interface:IJCOBridgeReflectedReturns the instantiated class Type- Specified by:
getJCOTypein interfaceIJCOBridgeReflected- Overrides:
getJCOTypein classNetObject- Returns:
- A
JCTyperepresenting the CLR Type of the instantiated Class
-
cast
public static File cast(IJCOBridgeReflected from) throws java.lang.Throwable
Try to cast theIJCOBridgeReflectedinstance intoFile, a cast assert is made to check if types are compatible.- Parameters:
from-IJCOBridgeReflectedinstance to be casted- Returns:
Fileinstance- Throws:
java.lang.Throwable- in case of error during cast operation
-
Exists
public static boolean Exists(java.lang.String path) throws java.lang.Throwable, ArgumentNullException, ArgumentException, PathTooLongException, ArgumentOutOfRangeException, FileNotFoundException, DirectoryNotFoundException, UnauthorizedAccessException, IOException, DriveNotFoundException, OperationCanceledException, InvalidOperationException, NotSupportedException- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentExceptionPathTooLongExceptionArgumentOutOfRangeExceptionFileNotFoundExceptionDirectoryNotFoundExceptionUnauthorizedAccessExceptionIOExceptionDriveNotFoundExceptionOperationCanceledExceptionInvalidOperationExceptionNotSupportedException
-
ReadAllBytes
public static byte[] ReadAllBytes(java.lang.String path) throws java.lang.Throwable, ArgumentNullException, ArgumentException, ArgumentOutOfRangeException, FormatException, PathTooLongException, FileNotFoundException, DirectoryNotFoundException, UnauthorizedAccessException, IOException, DriveNotFoundException, OperationCanceledException, NotSupportedException, InvalidOperationException, NullReferenceException, SecurityException, EndOfStreamException- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentExceptionArgumentOutOfRangeExceptionFormatExceptionPathTooLongExceptionFileNotFoundExceptionDirectoryNotFoundExceptionUnauthorizedAccessExceptionIOExceptionDriveNotFoundExceptionOperationCanceledExceptionNotSupportedExceptionInvalidOperationExceptionNullReferenceExceptionSecurityExceptionEndOfStreamException
-
GetCreationTime
public static DateTime GetCreationTime(java.lang.String path) throws java.lang.Throwable, ArgumentNullException, ArgumentException, PathTooLongException, ArgumentOutOfRangeException, FileNotFoundException, DirectoryNotFoundException, UnauthorizedAccessException, IOException, DriveNotFoundException, OperationCanceledException, InvalidOperationException, NotSupportedException, InvalidTimeZoneException
- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentExceptionPathTooLongExceptionArgumentOutOfRangeExceptionFileNotFoundExceptionDirectoryNotFoundExceptionUnauthorizedAccessExceptionIOExceptionDriveNotFoundExceptionOperationCanceledExceptionInvalidOperationExceptionNotSupportedExceptionInvalidTimeZoneException
-
GetCreationTimeUtc
public static DateTime GetCreationTimeUtc(java.lang.String path) throws java.lang.Throwable, ArgumentNullException, ArgumentException, PathTooLongException, ArgumentOutOfRangeException, FileNotFoundException, DirectoryNotFoundException, UnauthorizedAccessException, IOException, DriveNotFoundException, OperationCanceledException, InvalidOperationException, NotSupportedException
- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentExceptionPathTooLongExceptionArgumentOutOfRangeExceptionFileNotFoundExceptionDirectoryNotFoundExceptionUnauthorizedAccessExceptionIOExceptionDriveNotFoundExceptionOperationCanceledExceptionInvalidOperationExceptionNotSupportedException
-
GetLastAccessTime
public static DateTime GetLastAccessTime(java.lang.String path) throws java.lang.Throwable, ArgumentNullException, ArgumentException, PathTooLongException, ArgumentOutOfRangeException, FileNotFoundException, DirectoryNotFoundException, UnauthorizedAccessException, IOException, DriveNotFoundException, OperationCanceledException, InvalidOperationException, NotSupportedException, InvalidTimeZoneException
- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentExceptionPathTooLongExceptionArgumentOutOfRangeExceptionFileNotFoundExceptionDirectoryNotFoundExceptionUnauthorizedAccessExceptionIOExceptionDriveNotFoundExceptionOperationCanceledExceptionInvalidOperationExceptionNotSupportedExceptionInvalidTimeZoneException
-
GetLastAccessTimeUtc
public static DateTime GetLastAccessTimeUtc(java.lang.String path) throws java.lang.Throwable, ArgumentNullException, ArgumentException, PathTooLongException, ArgumentOutOfRangeException, FileNotFoundException, DirectoryNotFoundException, UnauthorizedAccessException, IOException, DriveNotFoundException, OperationCanceledException, InvalidOperationException, NotSupportedException
- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentExceptionPathTooLongExceptionArgumentOutOfRangeExceptionFileNotFoundExceptionDirectoryNotFoundExceptionUnauthorizedAccessExceptionIOExceptionDriveNotFoundExceptionOperationCanceledExceptionInvalidOperationExceptionNotSupportedException
-
GetLastWriteTime
public static DateTime GetLastWriteTime(java.lang.String path) throws java.lang.Throwable, ArgumentNullException, ArgumentException, PathTooLongException, ArgumentOutOfRangeException, FileNotFoundException, DirectoryNotFoundException, UnauthorizedAccessException, IOException, DriveNotFoundException, OperationCanceledException, InvalidOperationException, NotSupportedException, InvalidTimeZoneException
- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentExceptionPathTooLongExceptionArgumentOutOfRangeExceptionFileNotFoundExceptionDirectoryNotFoundExceptionUnauthorizedAccessExceptionIOExceptionDriveNotFoundExceptionOperationCanceledExceptionInvalidOperationExceptionNotSupportedExceptionInvalidTimeZoneException
-
GetLastWriteTimeUtc
public static DateTime GetLastWriteTimeUtc(java.lang.String path) throws java.lang.Throwable, ArgumentNullException, ArgumentException, PathTooLongException, ArgumentOutOfRangeException, FileNotFoundException, DirectoryNotFoundException, UnauthorizedAccessException, IOException, DriveNotFoundException, OperationCanceledException, InvalidOperationException, NotSupportedException
- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentExceptionPathTooLongExceptionArgumentOutOfRangeExceptionFileNotFoundExceptionDirectoryNotFoundExceptionUnauthorizedAccessExceptionIOExceptionDriveNotFoundExceptionOperationCanceledExceptionInvalidOperationExceptionNotSupportedException
-
GetAttributes
public static FileAttributes GetAttributes(java.lang.String path) throws java.lang.Throwable, ArgumentNullException, ArgumentException, PathTooLongException, ArgumentOutOfRangeException, OutOfMemoryException, IndexOutOfRangeException, FileNotFoundException, DirectoryNotFoundException, UnauthorizedAccessException, IOException, DriveNotFoundException, OperationCanceledException, NotSupportedException, InvalidOperationException
- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentExceptionPathTooLongExceptionArgumentOutOfRangeExceptionOutOfMemoryExceptionIndexOutOfRangeExceptionFileNotFoundExceptionDirectoryNotFoundExceptionUnauthorizedAccessExceptionIOExceptionDriveNotFoundExceptionOperationCanceledExceptionNotSupportedExceptionInvalidOperationException
-
Create
public static FileStream Create(java.lang.String path) throws java.lang.Throwable, ArgumentNullException, ArgumentException, ArgumentOutOfRangeException, FormatException, PathTooLongException, IndexOutOfRangeException, NotSupportedException, InvalidOperationException, NullReferenceException, SecurityException, IOException
-
Create
public static FileStream Create(java.lang.String path, int bufferSize) throws java.lang.Throwable, ArgumentNullException, ArgumentException, ArgumentOutOfRangeException, FormatException, PathTooLongException, FileNotFoundException, DirectoryNotFoundException, UnauthorizedAccessException, IOException, DriveNotFoundException, OperationCanceledException, NotSupportedException, InvalidOperationException, NullReferenceException, SecurityException
- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentExceptionArgumentOutOfRangeExceptionFormatExceptionPathTooLongExceptionFileNotFoundExceptionDirectoryNotFoundExceptionUnauthorizedAccessExceptionIOExceptionDriveNotFoundExceptionOperationCanceledExceptionNotSupportedExceptionInvalidOperationExceptionNullReferenceExceptionSecurityException
-
Create
public static FileStream Create(java.lang.String path, int bufferSize, FileOptions options) throws java.lang.Throwable, ArgumentNullException, ArgumentException, ArgumentOutOfRangeException, FormatException, PathTooLongException, FileNotFoundException, DirectoryNotFoundException, UnauthorizedAccessException, IOException, DriveNotFoundException, OperationCanceledException, NotSupportedException, InvalidOperationException, NullReferenceException, SecurityException
- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentExceptionArgumentOutOfRangeExceptionFormatExceptionPathTooLongExceptionFileNotFoundExceptionDirectoryNotFoundExceptionUnauthorizedAccessExceptionIOExceptionDriveNotFoundExceptionOperationCanceledExceptionNotSupportedExceptionInvalidOperationExceptionNullReferenceExceptionSecurityException
-
Create
public static FileStream Create(java.lang.String path, int bufferSize, FileOptions options, FileSecurity fileSecurity) throws java.lang.Throwable, ArgumentNullException, ArgumentOutOfRangeException, ArgumentException, InvalidOperationException, MissingMethodException, TargetInvocationException, FormatException, PathTooLongException, IndexOutOfRangeException, NotSupportedException, FileNotFoundException, DirectoryNotFoundException, UnauthorizedAccessException, IOException, DriveNotFoundException, OperationCanceledException, SecurityException, KeyNotFoundException
- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentOutOfRangeExceptionArgumentExceptionInvalidOperationExceptionMissingMethodExceptionTargetInvocationExceptionFormatExceptionPathTooLongExceptionIndexOutOfRangeExceptionNotSupportedExceptionFileNotFoundExceptionDirectoryNotFoundExceptionUnauthorizedAccessExceptionIOExceptionDriveNotFoundExceptionOperationCanceledExceptionSecurityExceptionKeyNotFoundException
-
Open
public static FileStream Open(java.lang.String path, FileMode mode) throws java.lang.Throwable, ArgumentNullException, ArgumentException, ArgumentOutOfRangeException, FormatException, PathTooLongException, IndexOutOfRangeException, NotSupportedException, InvalidOperationException, NullReferenceException, SecurityException, IOException
-
Open
public static FileStream Open(java.lang.String path, FileMode mode, FileAccess access) throws java.lang.Throwable, ArgumentNullException, ArgumentException, ArgumentOutOfRangeException, FormatException, PathTooLongException, IndexOutOfRangeException, NotSupportedException, InvalidOperationException, NullReferenceException, SecurityException, IOException
-
Open
public static FileStream Open(java.lang.String path, FileMode mode, FileAccess access, FileShare share) throws java.lang.Throwable, ArgumentNullException, ArgumentException, ArgumentOutOfRangeException, FormatException, PathTooLongException, FileNotFoundException, DirectoryNotFoundException, UnauthorizedAccessException, IOException, DriveNotFoundException, OperationCanceledException, NotSupportedException, InvalidOperationException, NullReferenceException, SecurityException
- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentExceptionArgumentOutOfRangeExceptionFormatExceptionPathTooLongExceptionFileNotFoundExceptionDirectoryNotFoundExceptionUnauthorizedAccessExceptionIOExceptionDriveNotFoundExceptionOperationCanceledExceptionNotSupportedExceptionInvalidOperationExceptionNullReferenceExceptionSecurityException
-
OpenRead
public static FileStream OpenRead(java.lang.String path) throws java.lang.Throwable, ArgumentNullException, ArgumentException, ArgumentOutOfRangeException, FormatException, PathTooLongException, FileNotFoundException, DirectoryNotFoundException, UnauthorizedAccessException, IOException, DriveNotFoundException, OperationCanceledException, NotSupportedException, InvalidOperationException, NullReferenceException, SecurityException
- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentExceptionArgumentOutOfRangeExceptionFormatExceptionPathTooLongExceptionFileNotFoundExceptionDirectoryNotFoundExceptionUnauthorizedAccessExceptionIOExceptionDriveNotFoundExceptionOperationCanceledExceptionNotSupportedExceptionInvalidOperationExceptionNullReferenceExceptionSecurityException
-
OpenWrite
public static FileStream OpenWrite(java.lang.String path) throws java.lang.Throwable, ArgumentNullException, ArgumentException, ArgumentOutOfRangeException, FormatException, PathTooLongException, FileNotFoundException, DirectoryNotFoundException, UnauthorizedAccessException, IOException, DriveNotFoundException, OperationCanceledException, NotSupportedException, InvalidOperationException, NullReferenceException, SecurityException
- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentExceptionArgumentOutOfRangeExceptionFormatExceptionPathTooLongExceptionFileNotFoundExceptionDirectoryNotFoundExceptionUnauthorizedAccessExceptionIOExceptionDriveNotFoundExceptionOperationCanceledExceptionNotSupportedExceptionInvalidOperationExceptionNullReferenceExceptionSecurityException
-
OpenText
public static StreamReader OpenText(java.lang.String path) throws java.lang.Throwable, ArgumentNullException, ArgumentOutOfRangeException, ArgumentException, PathTooLongException, CultureNotFoundException, NotSupportedException, InvalidOperationException, IndexOutOfRangeException, NullReferenceException, SecurityException, IOException
-
AppendText
public static StreamWriter AppendText(java.lang.String path) throws java.lang.Throwable, ArgumentNullException, ArgumentOutOfRangeException, ArgumentException, PathTooLongException, CultureNotFoundException, NotSupportedException, InvalidOperationException, IndexOutOfRangeException, NullReferenceException, SecurityException, IOException
-
CreateText
public static StreamWriter CreateText(java.lang.String path) throws java.lang.Throwable, ArgumentNullException, ArgumentOutOfRangeException, ArgumentException, PathTooLongException, CultureNotFoundException, NotSupportedException, InvalidOperationException, IndexOutOfRangeException, NullReferenceException, SecurityException, IOException
-
GetAccessControl
public static FileSecurity GetAccessControl(java.lang.String path) throws java.lang.Throwable, ArgumentNullException, ArgumentException, OutOfMemoryException, UnauthorizedAccessException, InvalidOperationException, PrivilegeNotHeldException, SystemException, ArgumentOutOfRangeException, OverflowException, PathTooLongException, IndexOutOfRangeException, NotSupportedException
-
GetAccessControl
public static FileSecurity GetAccessControl(java.lang.String path, AccessControlSections includeSections) throws java.lang.Throwable, ArgumentNullException, ArgumentException, OutOfMemoryException, UnauthorizedAccessException, InvalidOperationException, PrivilegeNotHeldException, SystemException, ArgumentOutOfRangeException, OverflowException, PathTooLongException, FileNotFoundException, DirectoryNotFoundException, IOException, DriveNotFoundException, OperationCanceledException, NotSupportedException
- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentExceptionOutOfMemoryExceptionUnauthorizedAccessExceptionInvalidOperationExceptionPrivilegeNotHeldExceptionSystemExceptionArgumentOutOfRangeExceptionOverflowExceptionPathTooLongExceptionFileNotFoundExceptionDirectoryNotFoundExceptionIOExceptionDriveNotFoundExceptionOperationCanceledExceptionNotSupportedException
-
ReadAllText
public static java.lang.String ReadAllText(java.lang.String path) throws java.lang.Throwable, ArgumentNullException, ArgumentException, ArgumentOutOfRangeException, FormatException, PathTooLongException, IndexOutOfRangeException, NotSupportedException, InvalidOperationException, NullReferenceException, SecurityException, IOException, OutOfMemoryException
-
ReadAllText
public static java.lang.String ReadAllText(java.lang.String path, Encoding encoding) throws java.lang.Throwable, ArgumentNullException, ArgumentException, ArgumentOutOfRangeException, FormatException, PathTooLongException, IndexOutOfRangeException, NotSupportedException, InvalidOperationException, NullReferenceException, SecurityException, IOException, OutOfMemoryException
-
ReadAllLines
public static java.lang.String[] ReadAllLines(java.lang.String path) throws java.lang.Throwable, ArgumentNullException, ArgumentException, ArgumentOutOfRangeException, PathTooLongException, CultureNotFoundException, NotSupportedException, InvalidOperationException, IndexOutOfRangeException, NullReferenceException, SecurityException, IOException, OutOfMemoryException
-
ReadAllLines
public static java.lang.String[] ReadAllLines(java.lang.String path, Encoding encoding) throws java.lang.Throwable, ArgumentNullException, ArgumentException, ArgumentOutOfRangeException, PathTooLongException, CultureNotFoundException, NotSupportedException, InvalidOperationException, IndexOutOfRangeException, NullReferenceException, SecurityException, IOException, OutOfMemoryException
-
AppendAllText
public static void AppendAllText(java.lang.String path, java.lang.String contents) throws java.lang.Throwable, ArgumentNullException, ArgumentException, ArgumentOutOfRangeException, NotSupportedException, InvalidOperationException, NullReferenceException, FileNotFoundException, DirectoryNotFoundException, UnauthorizedAccessException, IOException, PathTooLongException, DriveNotFoundException, OperationCanceledException, SecurityException, FormatException- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentExceptionArgumentOutOfRangeExceptionNotSupportedExceptionInvalidOperationExceptionNullReferenceExceptionFileNotFoundExceptionDirectoryNotFoundExceptionUnauthorizedAccessExceptionIOExceptionPathTooLongExceptionDriveNotFoundExceptionOperationCanceledExceptionSecurityExceptionFormatException
-
AppendAllText
public static void AppendAllText(java.lang.String path, java.lang.String contents, Encoding encoding) throws java.lang.Throwable, ArgumentNullException, ArgumentException, ArgumentOutOfRangeException, NotSupportedException, InvalidOperationException, NullReferenceException, FileNotFoundException, DirectoryNotFoundException, UnauthorizedAccessException, IOException, PathTooLongException, DriveNotFoundException, OperationCanceledException, SecurityException, FormatException- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentExceptionArgumentOutOfRangeExceptionNotSupportedExceptionInvalidOperationExceptionNullReferenceExceptionFileNotFoundExceptionDirectoryNotFoundExceptionUnauthorizedAccessExceptionIOExceptionPathTooLongExceptionDriveNotFoundExceptionOperationCanceledExceptionSecurityExceptionFormatException
-
Copy
public static void Copy(java.lang.String sourceFileName, java.lang.String destFileName) throws java.lang.Throwable, ArgumentNullException, ArgumentException, PathTooLongException, ArgumentOutOfRangeException, FileNotFoundException, DirectoryNotFoundException, UnauthorizedAccessException, IOException, DriveNotFoundException, OperationCanceledException, InvalidOperationException, NotSupportedException- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentExceptionPathTooLongExceptionArgumentOutOfRangeExceptionFileNotFoundExceptionDirectoryNotFoundExceptionUnauthorizedAccessExceptionIOExceptionDriveNotFoundExceptionOperationCanceledExceptionInvalidOperationExceptionNotSupportedException
-
Copy
public static void Copy(java.lang.String sourceFileName, java.lang.String destFileName, boolean overwrite) throws java.lang.Throwable, ArgumentNullException, ArgumentException, PathTooLongException, ArgumentOutOfRangeException, FileNotFoundException, DirectoryNotFoundException, UnauthorizedAccessException, IOException, DriveNotFoundException, OperationCanceledException, InvalidOperationException, NotSupportedException- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentExceptionPathTooLongExceptionArgumentOutOfRangeExceptionFileNotFoundExceptionDirectoryNotFoundExceptionUnauthorizedAccessExceptionIOExceptionDriveNotFoundExceptionOperationCanceledExceptionInvalidOperationExceptionNotSupportedException
-
Decrypt
public static void Decrypt(java.lang.String path) throws java.lang.Throwable, ArgumentNullException, ArgumentException, PathTooLongException, ArgumentOutOfRangeException, OutOfMemoryException, IndexOutOfRangeException, FileNotFoundException, DirectoryNotFoundException, UnauthorizedAccessException, IOException, DriveNotFoundException, OperationCanceledException, NotSupportedException, InvalidOperationException- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentExceptionPathTooLongExceptionArgumentOutOfRangeExceptionOutOfMemoryExceptionIndexOutOfRangeExceptionFileNotFoundExceptionDirectoryNotFoundExceptionUnauthorizedAccessExceptionIOExceptionDriveNotFoundExceptionOperationCanceledExceptionNotSupportedExceptionInvalidOperationException
-
Delete
public static void Delete(java.lang.String path) throws java.lang.Throwable, ArgumentNullException, ArgumentException, PathTooLongException, ArgumentOutOfRangeException, FileNotFoundException, DirectoryNotFoundException, UnauthorizedAccessException, IOException, DriveNotFoundException, OperationCanceledException, InvalidOperationException, NotSupportedException- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentExceptionPathTooLongExceptionArgumentOutOfRangeExceptionFileNotFoundExceptionDirectoryNotFoundExceptionUnauthorizedAccessExceptionIOExceptionDriveNotFoundExceptionOperationCanceledExceptionInvalidOperationExceptionNotSupportedException
-
Encrypt
public static void Encrypt(java.lang.String path) throws java.lang.Throwable, ArgumentNullException, ArgumentException, PathTooLongException, ArgumentOutOfRangeException, OutOfMemoryException, IndexOutOfRangeException, FileNotFoundException, DirectoryNotFoundException, UnauthorizedAccessException, IOException, DriveNotFoundException, OperationCanceledException, NotSupportedException, InvalidOperationException- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentExceptionPathTooLongExceptionArgumentOutOfRangeExceptionOutOfMemoryExceptionIndexOutOfRangeExceptionFileNotFoundExceptionDirectoryNotFoundExceptionUnauthorizedAccessExceptionIOExceptionDriveNotFoundExceptionOperationCanceledExceptionNotSupportedExceptionInvalidOperationException
-
Move
public static void Move(java.lang.String sourceFileName, java.lang.String destFileName) throws java.lang.Throwable, ArgumentNullException, ArgumentException, PathTooLongException, ArgumentOutOfRangeException, FileNotFoundException, DirectoryNotFoundException, UnauthorizedAccessException, IOException, DriveNotFoundException, OperationCanceledException, InvalidOperationException, NotSupportedException- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentExceptionPathTooLongExceptionArgumentOutOfRangeExceptionFileNotFoundExceptionDirectoryNotFoundExceptionUnauthorizedAccessExceptionIOExceptionDriveNotFoundExceptionOperationCanceledExceptionInvalidOperationExceptionNotSupportedException
-
Replace
public static void Replace(java.lang.String sourceFileName, java.lang.String destinationFileName, java.lang.String destinationBackupFileName) throws java.lang.Throwable, ArgumentNullException, ArgumentException, PathTooLongException, ArgumentOutOfRangeException, FileNotFoundException, DirectoryNotFoundException, UnauthorizedAccessException, IOException, DriveNotFoundException, OperationCanceledException, NotSupportedException, InvalidOperationException- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentExceptionPathTooLongExceptionArgumentOutOfRangeExceptionFileNotFoundExceptionDirectoryNotFoundExceptionUnauthorizedAccessExceptionIOExceptionDriveNotFoundExceptionOperationCanceledExceptionNotSupportedExceptionInvalidOperationException
-
Replace
public static void Replace(java.lang.String sourceFileName, java.lang.String destinationFileName, java.lang.String destinationBackupFileName, boolean ignoreMetadataErrors) throws java.lang.Throwable, ArgumentNullException, ArgumentException, PathTooLongException, ArgumentOutOfRangeException, FileNotFoundException, DirectoryNotFoundException, UnauthorizedAccessException, IOException, DriveNotFoundException, OperationCanceledException, NotSupportedException, InvalidOperationException- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentExceptionPathTooLongExceptionArgumentOutOfRangeExceptionFileNotFoundExceptionDirectoryNotFoundExceptionUnauthorizedAccessExceptionIOExceptionDriveNotFoundExceptionOperationCanceledExceptionNotSupportedExceptionInvalidOperationException
-
SetAccessControl
public static void SetAccessControl(java.lang.String path, FileSecurity fileSecurity) throws java.lang.Throwable, ArgumentNullException, ArgumentException, PathTooLongException, ArgumentOutOfRangeException, OutOfMemoryException, IndexOutOfRangeException, FileNotFoundException, DirectoryNotFoundException, UnauthorizedAccessException, IOException, DriveNotFoundException, OperationCanceledException, NotSupportedException, InvalidOperationException, PrivilegeNotHeldException, InvalidProgramException- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentExceptionPathTooLongExceptionArgumentOutOfRangeExceptionOutOfMemoryExceptionIndexOutOfRangeExceptionFileNotFoundExceptionDirectoryNotFoundExceptionUnauthorizedAccessExceptionIOExceptionDriveNotFoundExceptionOperationCanceledExceptionNotSupportedExceptionInvalidOperationExceptionPrivilegeNotHeldExceptionInvalidProgramException
-
SetAttributes
public static void SetAttributes(java.lang.String path, FileAttributes fileAttributes) throws java.lang.Throwable, ArgumentNullException, ArgumentException, PathTooLongException, ArgumentOutOfRangeException, OutOfMemoryException, IndexOutOfRangeException, FileNotFoundException, DirectoryNotFoundException, UnauthorizedAccessException, IOException, DriveNotFoundException, OperationCanceledException, NotSupportedException- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentExceptionPathTooLongExceptionArgumentOutOfRangeExceptionOutOfMemoryExceptionIndexOutOfRangeExceptionFileNotFoundExceptionDirectoryNotFoundExceptionUnauthorizedAccessExceptionIOExceptionDriveNotFoundExceptionOperationCanceledExceptionNotSupportedException
-
SetCreationTime
public static void SetCreationTime(java.lang.String path, DateTime creationTime) throws java.lang.Throwable, ArgumentException, ArgumentNullException, ArgumentOutOfRangeException, InvalidTimeZoneException, SecurityException, IOException, InvalidOperationException, NotSupportedException, OverflowException, PathTooLongException, FileNotFoundException, DirectoryNotFoundException, UnauthorizedAccessException, DriveNotFoundException, OperationCanceledException, NullReferenceException, IndexOutOfRangeException- Throws:
java.lang.ThrowableArgumentExceptionArgumentNullExceptionArgumentOutOfRangeExceptionInvalidTimeZoneExceptionSecurityExceptionIOExceptionInvalidOperationExceptionNotSupportedExceptionOverflowExceptionPathTooLongExceptionFileNotFoundExceptionDirectoryNotFoundExceptionUnauthorizedAccessExceptionDriveNotFoundExceptionOperationCanceledExceptionNullReferenceExceptionIndexOutOfRangeException
-
SetCreationTimeUtc
public static void SetCreationTimeUtc(java.lang.String path, DateTime creationTimeUtc) throws java.lang.Throwable, ArgumentNullException, ArgumentException, ArgumentOutOfRangeException, FormatException, PathTooLongException, IndexOutOfRangeException, NotSupportedException, InvalidOperationException, NullReferenceException, SecurityException, IOException, InvalidTimeZoneException, OverflowException- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentExceptionArgumentOutOfRangeExceptionFormatExceptionPathTooLongExceptionIndexOutOfRangeExceptionNotSupportedExceptionInvalidOperationExceptionNullReferenceExceptionSecurityExceptionIOExceptionInvalidTimeZoneExceptionOverflowException
-
SetLastAccessTime
public static void SetLastAccessTime(java.lang.String path, DateTime lastAccessTime) throws java.lang.Throwable, ArgumentException, ArgumentNullException, ArgumentOutOfRangeException, InvalidTimeZoneException, SecurityException, IOException, InvalidOperationException, NotSupportedException, OverflowException, PathTooLongException, FileNotFoundException, DirectoryNotFoundException, UnauthorizedAccessException, DriveNotFoundException, OperationCanceledException, NullReferenceException, IndexOutOfRangeException- Throws:
java.lang.ThrowableArgumentExceptionArgumentNullExceptionArgumentOutOfRangeExceptionInvalidTimeZoneExceptionSecurityExceptionIOExceptionInvalidOperationExceptionNotSupportedExceptionOverflowExceptionPathTooLongExceptionFileNotFoundExceptionDirectoryNotFoundExceptionUnauthorizedAccessExceptionDriveNotFoundExceptionOperationCanceledExceptionNullReferenceExceptionIndexOutOfRangeException
-
SetLastAccessTimeUtc
public static void SetLastAccessTimeUtc(java.lang.String path, DateTime lastAccessTimeUtc) throws java.lang.Throwable, ArgumentNullException, ArgumentException, ArgumentOutOfRangeException, FormatException, PathTooLongException, IndexOutOfRangeException, NotSupportedException, InvalidOperationException, NullReferenceException, SecurityException, IOException, InvalidTimeZoneException, OverflowException- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentExceptionArgumentOutOfRangeExceptionFormatExceptionPathTooLongExceptionIndexOutOfRangeExceptionNotSupportedExceptionInvalidOperationExceptionNullReferenceExceptionSecurityExceptionIOExceptionInvalidTimeZoneExceptionOverflowException
-
SetLastWriteTime
public static void SetLastWriteTime(java.lang.String path, DateTime lastWriteTime) throws java.lang.Throwable, ArgumentException, ArgumentNullException, ArgumentOutOfRangeException, InvalidTimeZoneException, SecurityException, IOException, InvalidOperationException, NotSupportedException, OverflowException, PathTooLongException, FileNotFoundException, DirectoryNotFoundException, UnauthorizedAccessException, DriveNotFoundException, OperationCanceledException, NullReferenceException, IndexOutOfRangeException- Throws:
java.lang.ThrowableArgumentExceptionArgumentNullExceptionArgumentOutOfRangeExceptionInvalidTimeZoneExceptionSecurityExceptionIOExceptionInvalidOperationExceptionNotSupportedExceptionOverflowExceptionPathTooLongExceptionFileNotFoundExceptionDirectoryNotFoundExceptionUnauthorizedAccessExceptionDriveNotFoundExceptionOperationCanceledExceptionNullReferenceExceptionIndexOutOfRangeException
-
SetLastWriteTimeUtc
public static void SetLastWriteTimeUtc(java.lang.String path, DateTime lastWriteTimeUtc) throws java.lang.Throwable, ArgumentNullException, ArgumentException, ArgumentOutOfRangeException, FormatException, PathTooLongException, IndexOutOfRangeException, NotSupportedException, InvalidOperationException, NullReferenceException, SecurityException, IOException, InvalidTimeZoneException, OverflowException- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentExceptionArgumentOutOfRangeExceptionFormatExceptionPathTooLongExceptionIndexOutOfRangeExceptionNotSupportedExceptionInvalidOperationExceptionNullReferenceExceptionSecurityExceptionIOExceptionInvalidTimeZoneExceptionOverflowException
-
WriteAllBytes
public static void WriteAllBytes(java.lang.String path, byte[] bytes) throws java.lang.Throwable, ArgumentNullException, ArgumentException, ArgumentOutOfRangeException, FormatException, PathTooLongException, FileNotFoundException, DirectoryNotFoundException, UnauthorizedAccessException, IOException, DriveNotFoundException, OperationCanceledException, NotSupportedException, InvalidOperationException, NullReferenceException, SecurityException- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentExceptionArgumentOutOfRangeExceptionFormatExceptionPathTooLongExceptionFileNotFoundExceptionDirectoryNotFoundExceptionUnauthorizedAccessExceptionIOExceptionDriveNotFoundExceptionOperationCanceledExceptionNotSupportedExceptionInvalidOperationExceptionNullReferenceExceptionSecurityException
-
WriteAllBytes
public static void WriteAllBytes(java.lang.String dupParam0, JCORefOut dupParam1) throws java.lang.Throwable, ArgumentNullException, ArgumentException, ArgumentOutOfRangeException, FormatException, PathTooLongException, FileNotFoundException, DirectoryNotFoundException, UnauthorizedAccessException, IOException, DriveNotFoundException, OperationCanceledException, NotSupportedException, InvalidOperationException, NullReferenceException, SecurityException- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentExceptionArgumentOutOfRangeExceptionFormatExceptionPathTooLongExceptionFileNotFoundExceptionDirectoryNotFoundExceptionUnauthorizedAccessExceptionIOExceptionDriveNotFoundExceptionOperationCanceledExceptionNotSupportedExceptionInvalidOperationExceptionNullReferenceExceptionSecurityException
-
WriteAllLines
public static void WriteAllLines(java.lang.String path, java.lang.String[] contents) throws java.lang.Throwable, ArgumentNullException, ArgumentException, ArgumentOutOfRangeException, PathTooLongException, CultureNotFoundException, NotSupportedException, InvalidOperationException, IndexOutOfRangeException, NullReferenceException, SecurityException, IOException
-
WriteAllLines
public static void WriteAllLines(java.lang.String dupParam0, JCORefOut dupParam1) throws java.lang.Throwable, ArgumentNullException, ArgumentException, ArgumentOutOfRangeException, PathTooLongException, CultureNotFoundException, NotSupportedException, InvalidOperationException, IndexOutOfRangeException, NullReferenceException, SecurityException, IOException
-
WriteAllLines
public static void WriteAllLines(java.lang.String path, java.lang.String[] contents, Encoding encoding) throws java.lang.Throwable, ArgumentNullException, ArgumentException, ArgumentOutOfRangeException, PathTooLongException, CultureNotFoundException, NotSupportedException, InvalidOperationException, IndexOutOfRangeException, NullReferenceException, SecurityException, IOException
-
WriteAllLines
public static void WriteAllLines(java.lang.String dupParam0, JCORefOut dupParam1, Encoding dupParam2) throws java.lang.Throwable, ArgumentNullException, ArgumentException, ArgumentOutOfRangeException, PathTooLongException, CultureNotFoundException, NotSupportedException, InvalidOperationException, IndexOutOfRangeException, NullReferenceException, SecurityException, IOException
-
WriteAllText
public static void WriteAllText(java.lang.String path, java.lang.String contents) throws java.lang.Throwable, ArgumentNullException, ArgumentException, ArgumentOutOfRangeException, FormatException, PathTooLongException, FileNotFoundException, DirectoryNotFoundException, UnauthorizedAccessException, IOException, DriveNotFoundException, OperationCanceledException, NotSupportedException, InvalidOperationException, NullReferenceException, SecurityException, IndexOutOfRangeException- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentExceptionArgumentOutOfRangeExceptionFormatExceptionPathTooLongExceptionFileNotFoundExceptionDirectoryNotFoundExceptionUnauthorizedAccessExceptionIOExceptionDriveNotFoundExceptionOperationCanceledExceptionNotSupportedExceptionInvalidOperationExceptionNullReferenceExceptionSecurityExceptionIndexOutOfRangeException
-
WriteAllText
public static void WriteAllText(java.lang.String path, java.lang.String contents, Encoding encoding) throws java.lang.Throwable, ArgumentNullException, ArgumentException, ArgumentOutOfRangeException, FormatException, PathTooLongException, FileNotFoundException, DirectoryNotFoundException, UnauthorizedAccessException, IOException, DriveNotFoundException, OperationCanceledException, NotSupportedException, InvalidOperationException, NullReferenceException, SecurityException, IndexOutOfRangeException- Throws:
java.lang.ThrowableArgumentNullExceptionArgumentExceptionArgumentOutOfRangeExceptionFormatExceptionPathTooLongExceptionFileNotFoundExceptionDirectoryNotFoundExceptionUnauthorizedAccessExceptionIOExceptionDriveNotFoundExceptionOperationCanceledExceptionNotSupportedExceptionInvalidOperationExceptionNullReferenceExceptionSecurityExceptionIndexOutOfRangeException
-
-