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.String
assemblyFullName
Fully assembly qualified name: mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089static java.lang.String
assemblyShortName
Assembly name: mscorlibstatic java.lang.String
className
Qualified class name: System.IO.Filestatic JCType
classType
The type managed from JCOBridge.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static void
AppendAllText(java.lang.String path, java.lang.String contents)
static void
AppendAllText(java.lang.String path, java.lang.String contents, Encoding encoding)
static StreamWriter
AppendText(java.lang.String path)
static File
cast(IJCOBridgeReflected from)
Try to cast theIJCOBridgeReflected
instance intoFile
, a cast assert is made to check if types are compatible.static void
Copy(java.lang.String sourceFileName, java.lang.String destFileName)
static void
Copy(java.lang.String sourceFileName, java.lang.String destFileName, boolean overwrite)
static FileStream
Create(java.lang.String path)
static FileStream
Create(java.lang.String path, int bufferSize)
static FileStream
Create(java.lang.String path, int bufferSize, FileOptions options)
static FileStream
Create(java.lang.String path, int bufferSize, FileOptions options, FileSecurity fileSecurity)
static StreamWriter
CreateText(java.lang.String path)
static void
Decrypt(java.lang.String path)
static void
Delete(java.lang.String path)
static void
Encrypt(java.lang.String path)
static boolean
Exists(java.lang.String path)
static FileSecurity
GetAccessControl(java.lang.String path)
static FileSecurity
GetAccessControl(java.lang.String path, AccessControlSections includeSections)
static FileAttributes
GetAttributes(java.lang.String path)
static DateTime
GetCreationTime(java.lang.String path)
static DateTime
GetCreationTimeUtc(java.lang.String path)
java.lang.String
getJCOAssemblyName()
Returns the reflected Assembly namejava.lang.String
getJCOClassName()
Returns the reflected Class namejava.lang.Object
getJCOInstance()
Returns the instantiated classjava.lang.String
getJCOObjectName()
Returns the reflected Class name used to build the objectJCType
getJCOType()
Returns the instantiated class Typestatic DateTime
GetLastAccessTime(java.lang.String path)
static DateTime
GetLastAccessTimeUtc(java.lang.String path)
static DateTime
GetLastWriteTime(java.lang.String path)
static DateTime
GetLastWriteTimeUtc(java.lang.String path)
static void
Move(java.lang.String sourceFileName, java.lang.String destFileName)
static FileStream
Open(java.lang.String path, FileMode mode)
static FileStream
Open(java.lang.String path, FileMode mode, FileAccess access)
static FileStream
Open(java.lang.String path, FileMode mode, FileAccess access, FileShare share)
static FileStream
OpenRead(java.lang.String path)
static StreamReader
OpenText(java.lang.String path)
static FileStream
OpenWrite(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.String
ReadAllText(java.lang.String path)
static java.lang.String
ReadAllText(java.lang.String path, Encoding encoding)
static void
Replace(java.lang.String sourceFileName, java.lang.String destinationFileName, java.lang.String destinationBackupFileName)
static void
Replace(java.lang.String sourceFileName, java.lang.String destinationFileName, java.lang.String destinationBackupFileName, boolean ignoreMetadataErrors)
static void
SetAccessControl(java.lang.String path, FileSecurity fileSecurity)
static void
SetAttributes(java.lang.String path, FileAttributes fileAttributes)
static void
SetCreationTime(java.lang.String path, DateTime creationTime)
static void
SetCreationTimeUtc(java.lang.String path, DateTime creationTimeUtc)
void
setJCOInstance(JCObject instance)
static void
SetLastAccessTime(java.lang.String path, DateTime lastAccessTime)
static void
SetLastAccessTimeUtc(java.lang.String path, DateTime lastAccessTimeUtc)
static void
SetLastWriteTime(java.lang.String path, DateTime lastWriteTime)
static void
SetLastWriteTimeUtc(java.lang.String path, DateTime lastWriteTimeUtc)
static void
WriteAllBytes(java.lang.String path, byte[] bytes)
static void
WriteAllBytes(java.lang.String dupParam0, JCORefOut dupParam1)
static void
WriteAllLines(java.lang.String path, java.lang.String[] contents)
static void
WriteAllLines(java.lang.String path, java.lang.String[] contents, Encoding encoding)
static void
WriteAllLines(java.lang.String dupParam0, JCORefOut dupParam1)
static void
WriteAllLines(java.lang.String dupParam0, JCORefOut dupParam1, Encoding dupParam2)
static void
WriteAllText(java.lang.String path, java.lang.String contents)
static void
WriteAllText(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:IJCOBridgeReflected
Returns the reflected Assembly name- Specified by:
getJCOAssemblyName
in interfaceIJCOBridgeReflected
- Overrides:
getJCOAssemblyName
in classNetObject
- Returns:
- A
String
representing the Fullname of reflected Assembly
-
getJCOClassName
public java.lang.String getJCOClassName()
Description copied from interface:IJCOBridgeReflected
Returns the reflected Class name- Specified by:
getJCOClassName
in interfaceIJCOBridgeReflected
- Overrides:
getJCOClassName
in classNetObject
- Returns:
- A
String
representing the Fullname of reflected Class
-
getJCOObjectName
public java.lang.String getJCOObjectName()
Description copied from interface:IJCOBridgeReflected
Returns the reflected Class name used to build the object- Specified by:
getJCOObjectName
in interfaceIJCOBridgeReflected
- Overrides:
getJCOObjectName
in classNetObject
- Returns:
- A
String
representing the name used to allocated the object in CLR context
-
getJCOInstance
public java.lang.Object getJCOInstance()
Description copied from interface:IJCOBridgeReflected
Returns the instantiated class- Specified by:
getJCOInstance
in interfaceIJCOBridgeReflected
- Overrides:
getJCOInstance
in classNetObject
- Returns:
- An
Object
representing the CLR instance of the instantiated Class
-
setJCOInstance
public void setJCOInstance(JCObject instance)
- Overrides:
setJCOInstance
in classNetObject
-
getJCOType
public JCType getJCOType()
Description copied from interface:IJCOBridgeReflected
Returns the instantiated class Type- Specified by:
getJCOType
in interfaceIJCOBridgeReflected
- Overrides:
getJCOType
in classNetObject
- Returns:
- A
JCType
representing the CLR Type of the instantiated Class
-
cast
public static File cast(IJCOBridgeReflected from) throws java.lang.Throwable
Try to cast theIJCOBridgeReflected
instance intoFile
, a cast assert is made to check if types are compatible.- Parameters:
from
-IJCOBridgeReflected
instance to be casted- Returns:
File
instance- 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.Throwable
ArgumentNullException
ArgumentException
PathTooLongException
ArgumentOutOfRangeException
FileNotFoundException
DirectoryNotFoundException
UnauthorizedAccessException
IOException
DriveNotFoundException
OperationCanceledException
InvalidOperationException
NotSupportedException
-
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.Throwable
ArgumentNullException
ArgumentException
ArgumentOutOfRangeException
FormatException
PathTooLongException
FileNotFoundException
DirectoryNotFoundException
UnauthorizedAccessException
IOException
DriveNotFoundException
OperationCanceledException
NotSupportedException
InvalidOperationException
NullReferenceException
SecurityException
EndOfStreamException
-
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.Throwable
ArgumentNullException
ArgumentException
PathTooLongException
ArgumentOutOfRangeException
FileNotFoundException
DirectoryNotFoundException
UnauthorizedAccessException
IOException
DriveNotFoundException
OperationCanceledException
InvalidOperationException
NotSupportedException
InvalidTimeZoneException
-
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.Throwable
ArgumentNullException
ArgumentException
PathTooLongException
ArgumentOutOfRangeException
FileNotFoundException
DirectoryNotFoundException
UnauthorizedAccessException
IOException
DriveNotFoundException
OperationCanceledException
InvalidOperationException
NotSupportedException
-
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.Throwable
ArgumentNullException
ArgumentException
PathTooLongException
ArgumentOutOfRangeException
FileNotFoundException
DirectoryNotFoundException
UnauthorizedAccessException
IOException
DriveNotFoundException
OperationCanceledException
InvalidOperationException
NotSupportedException
InvalidTimeZoneException
-
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.Throwable
ArgumentNullException
ArgumentException
PathTooLongException
ArgumentOutOfRangeException
FileNotFoundException
DirectoryNotFoundException
UnauthorizedAccessException
IOException
DriveNotFoundException
OperationCanceledException
InvalidOperationException
NotSupportedException
-
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.Throwable
ArgumentNullException
ArgumentException
PathTooLongException
ArgumentOutOfRangeException
FileNotFoundException
DirectoryNotFoundException
UnauthorizedAccessException
IOException
DriveNotFoundException
OperationCanceledException
InvalidOperationException
NotSupportedException
InvalidTimeZoneException
-
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.Throwable
ArgumentNullException
ArgumentException
PathTooLongException
ArgumentOutOfRangeException
FileNotFoundException
DirectoryNotFoundException
UnauthorizedAccessException
IOException
DriveNotFoundException
OperationCanceledException
InvalidOperationException
NotSupportedException
-
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.Throwable
ArgumentNullException
ArgumentException
PathTooLongException
ArgumentOutOfRangeException
OutOfMemoryException
IndexOutOfRangeException
FileNotFoundException
DirectoryNotFoundException
UnauthorizedAccessException
IOException
DriveNotFoundException
OperationCanceledException
NotSupportedException
InvalidOperationException
-
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.Throwable
ArgumentNullException
ArgumentException
ArgumentOutOfRangeException
FormatException
PathTooLongException
FileNotFoundException
DirectoryNotFoundException
UnauthorizedAccessException
IOException
DriveNotFoundException
OperationCanceledException
NotSupportedException
InvalidOperationException
NullReferenceException
SecurityException
-
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.Throwable
ArgumentNullException
ArgumentException
ArgumentOutOfRangeException
FormatException
PathTooLongException
FileNotFoundException
DirectoryNotFoundException
UnauthorizedAccessException
IOException
DriveNotFoundException
OperationCanceledException
NotSupportedException
InvalidOperationException
NullReferenceException
SecurityException
-
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.Throwable
ArgumentNullException
ArgumentOutOfRangeException
ArgumentException
InvalidOperationException
MissingMethodException
TargetInvocationException
FormatException
PathTooLongException
IndexOutOfRangeException
NotSupportedException
FileNotFoundException
DirectoryNotFoundException
UnauthorizedAccessException
IOException
DriveNotFoundException
OperationCanceledException
SecurityException
KeyNotFoundException
-
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.Throwable
ArgumentNullException
ArgumentException
ArgumentOutOfRangeException
FormatException
PathTooLongException
FileNotFoundException
DirectoryNotFoundException
UnauthorizedAccessException
IOException
DriveNotFoundException
OperationCanceledException
NotSupportedException
InvalidOperationException
NullReferenceException
SecurityException
-
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.Throwable
ArgumentNullException
ArgumentException
ArgumentOutOfRangeException
FormatException
PathTooLongException
FileNotFoundException
DirectoryNotFoundException
UnauthorizedAccessException
IOException
DriveNotFoundException
OperationCanceledException
NotSupportedException
InvalidOperationException
NullReferenceException
SecurityException
-
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.Throwable
ArgumentNullException
ArgumentException
ArgumentOutOfRangeException
FormatException
PathTooLongException
FileNotFoundException
DirectoryNotFoundException
UnauthorizedAccessException
IOException
DriveNotFoundException
OperationCanceledException
NotSupportedException
InvalidOperationException
NullReferenceException
SecurityException
-
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.Throwable
ArgumentNullException
ArgumentException
OutOfMemoryException
UnauthorizedAccessException
InvalidOperationException
PrivilegeNotHeldException
SystemException
ArgumentOutOfRangeException
OverflowException
PathTooLongException
FileNotFoundException
DirectoryNotFoundException
IOException
DriveNotFoundException
OperationCanceledException
NotSupportedException
-
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.Throwable
ArgumentNullException
ArgumentException
ArgumentOutOfRangeException
NotSupportedException
InvalidOperationException
NullReferenceException
FileNotFoundException
DirectoryNotFoundException
UnauthorizedAccessException
IOException
PathTooLongException
DriveNotFoundException
OperationCanceledException
SecurityException
FormatException
-
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.Throwable
ArgumentNullException
ArgumentException
ArgumentOutOfRangeException
NotSupportedException
InvalidOperationException
NullReferenceException
FileNotFoundException
DirectoryNotFoundException
UnauthorizedAccessException
IOException
PathTooLongException
DriveNotFoundException
OperationCanceledException
SecurityException
FormatException
-
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.Throwable
ArgumentNullException
ArgumentException
PathTooLongException
ArgumentOutOfRangeException
FileNotFoundException
DirectoryNotFoundException
UnauthorizedAccessException
IOException
DriveNotFoundException
OperationCanceledException
InvalidOperationException
NotSupportedException
-
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.Throwable
ArgumentNullException
ArgumentException
PathTooLongException
ArgumentOutOfRangeException
FileNotFoundException
DirectoryNotFoundException
UnauthorizedAccessException
IOException
DriveNotFoundException
OperationCanceledException
InvalidOperationException
NotSupportedException
-
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.Throwable
ArgumentNullException
ArgumentException
PathTooLongException
ArgumentOutOfRangeException
OutOfMemoryException
IndexOutOfRangeException
FileNotFoundException
DirectoryNotFoundException
UnauthorizedAccessException
IOException
DriveNotFoundException
OperationCanceledException
NotSupportedException
InvalidOperationException
-
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.Throwable
ArgumentNullException
ArgumentException
PathTooLongException
ArgumentOutOfRangeException
FileNotFoundException
DirectoryNotFoundException
UnauthorizedAccessException
IOException
DriveNotFoundException
OperationCanceledException
InvalidOperationException
NotSupportedException
-
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.Throwable
ArgumentNullException
ArgumentException
PathTooLongException
ArgumentOutOfRangeException
OutOfMemoryException
IndexOutOfRangeException
FileNotFoundException
DirectoryNotFoundException
UnauthorizedAccessException
IOException
DriveNotFoundException
OperationCanceledException
NotSupportedException
InvalidOperationException
-
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.Throwable
ArgumentNullException
ArgumentException
PathTooLongException
ArgumentOutOfRangeException
FileNotFoundException
DirectoryNotFoundException
UnauthorizedAccessException
IOException
DriveNotFoundException
OperationCanceledException
InvalidOperationException
NotSupportedException
-
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.Throwable
ArgumentNullException
ArgumentException
PathTooLongException
ArgumentOutOfRangeException
FileNotFoundException
DirectoryNotFoundException
UnauthorizedAccessException
IOException
DriveNotFoundException
OperationCanceledException
NotSupportedException
InvalidOperationException
-
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.Throwable
ArgumentNullException
ArgumentException
PathTooLongException
ArgumentOutOfRangeException
FileNotFoundException
DirectoryNotFoundException
UnauthorizedAccessException
IOException
DriveNotFoundException
OperationCanceledException
NotSupportedException
InvalidOperationException
-
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.Throwable
ArgumentNullException
ArgumentException
PathTooLongException
ArgumentOutOfRangeException
OutOfMemoryException
IndexOutOfRangeException
FileNotFoundException
DirectoryNotFoundException
UnauthorizedAccessException
IOException
DriveNotFoundException
OperationCanceledException
NotSupportedException
InvalidOperationException
PrivilegeNotHeldException
InvalidProgramException
-
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.Throwable
ArgumentNullException
ArgumentException
PathTooLongException
ArgumentOutOfRangeException
OutOfMemoryException
IndexOutOfRangeException
FileNotFoundException
DirectoryNotFoundException
UnauthorizedAccessException
IOException
DriveNotFoundException
OperationCanceledException
NotSupportedException
-
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.Throwable
ArgumentException
ArgumentNullException
ArgumentOutOfRangeException
InvalidTimeZoneException
SecurityException
IOException
InvalidOperationException
NotSupportedException
OverflowException
PathTooLongException
FileNotFoundException
DirectoryNotFoundException
UnauthorizedAccessException
DriveNotFoundException
OperationCanceledException
NullReferenceException
IndexOutOfRangeException
-
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.Throwable
ArgumentNullException
ArgumentException
ArgumentOutOfRangeException
FormatException
PathTooLongException
IndexOutOfRangeException
NotSupportedException
InvalidOperationException
NullReferenceException
SecurityException
IOException
InvalidTimeZoneException
OverflowException
-
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.Throwable
ArgumentException
ArgumentNullException
ArgumentOutOfRangeException
InvalidTimeZoneException
SecurityException
IOException
InvalidOperationException
NotSupportedException
OverflowException
PathTooLongException
FileNotFoundException
DirectoryNotFoundException
UnauthorizedAccessException
DriveNotFoundException
OperationCanceledException
NullReferenceException
IndexOutOfRangeException
-
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.Throwable
ArgumentNullException
ArgumentException
ArgumentOutOfRangeException
FormatException
PathTooLongException
IndexOutOfRangeException
NotSupportedException
InvalidOperationException
NullReferenceException
SecurityException
IOException
InvalidTimeZoneException
OverflowException
-
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.Throwable
ArgumentException
ArgumentNullException
ArgumentOutOfRangeException
InvalidTimeZoneException
SecurityException
IOException
InvalidOperationException
NotSupportedException
OverflowException
PathTooLongException
FileNotFoundException
DirectoryNotFoundException
UnauthorizedAccessException
DriveNotFoundException
OperationCanceledException
NullReferenceException
IndexOutOfRangeException
-
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.Throwable
ArgumentNullException
ArgumentException
ArgumentOutOfRangeException
FormatException
PathTooLongException
IndexOutOfRangeException
NotSupportedException
InvalidOperationException
NullReferenceException
SecurityException
IOException
InvalidTimeZoneException
OverflowException
-
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.Throwable
ArgumentNullException
ArgumentException
ArgumentOutOfRangeException
FormatException
PathTooLongException
FileNotFoundException
DirectoryNotFoundException
UnauthorizedAccessException
IOException
DriveNotFoundException
OperationCanceledException
NotSupportedException
InvalidOperationException
NullReferenceException
SecurityException
-
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.Throwable
ArgumentNullException
ArgumentException
ArgumentOutOfRangeException
FormatException
PathTooLongException
FileNotFoundException
DirectoryNotFoundException
UnauthorizedAccessException
IOException
DriveNotFoundException
OperationCanceledException
NotSupportedException
InvalidOperationException
NullReferenceException
SecurityException
-
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.Throwable
ArgumentNullException
ArgumentException
ArgumentOutOfRangeException
FormatException
PathTooLongException
FileNotFoundException
DirectoryNotFoundException
UnauthorizedAccessException
IOException
DriveNotFoundException
OperationCanceledException
NotSupportedException
InvalidOperationException
NullReferenceException
SecurityException
IndexOutOfRangeException
-
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.Throwable
ArgumentNullException
ArgumentException
ArgumentOutOfRangeException
FormatException
PathTooLongException
FileNotFoundException
DirectoryNotFoundException
UnauthorizedAccessException
IOException
DriveNotFoundException
OperationCanceledException
NotSupportedException
InvalidOperationException
NullReferenceException
SecurityException
IndexOutOfRangeException
-
-