Skip to content

Releases: marlonrcfranco/jcon

Stable release 1.0

11 Sep 13:40
0418f37
Compare
Choose a tag to compare

Contains:

Supported protocols:

  • FileSystem (local);
  • SMB 1 (remote);
  • SMB 2/3 (remote); and
  • NFS (remote);

Available methods:

read

public String read(String IP, String filePath, String user, String pass) throws IOException;

Returns the content of a file as a String;


readBytes

public byte[] readBytes(String IP, String filePath, String user, String pass) throws IOException;

Returns the content of a file as byte[];


write

public String write(String IP, String filePath, String user, String pass, String content) throws IOException;

Writes a String to a file (overwrites or creates the file, also creating all the directories missing in the path);


writeBytes

public byte[] writeBytes(String IP, String filePath, String user, String pass, byte[] content) throws IOException;

Writes a byte[] to a file (overwrites or creates the file, also creating all the directories missing in the path);


delete

public String delete(String IP, String filePath, String user, String pass) throws IOException;

Deletes files or directories;


listFiles

public String listFiles(String IP, String filePath, String user, String pass) throws IOException;

Returns a String with all the files and directories in a given path.


listFilesAsList

public ArrayList listFilesAsList(String IP, String filePath, String user, String pass) throws Exception;

Returns an ArrayList of objects according to the protocol. E.g. for filesystem protocol, it will return ArrayList<java.io.File>; for smb1 protocol, it will return ArrayList<jcifs.smb.SmbFile>, and so on.


Read and Write for Local FileSystem, SMB1, SMB2 and SMB3.

04 Sep 17:14
5fdb7d0
Compare
Choose a tag to compare
Merge pull request #3 from marlonrcfranco/develop

release 0.1.2