[jcifs] sample app

Michael B Allen mba2000 at ioplex.com
Thu Feb 22 17:00:56 GMT 2007


See the examples directory. Yeah, some of them may be wrong as the API
has changed over the years but ...

On Thu, 22 Feb 2007 11:23:25 +0000 (UTC)
jpl <ouiouinonnon at yahoo.fr> wrote:

> Hello,
> 
> Just download jCIFS and tried the snippet found in the documentation.
> It is not very helpful: it is even not accurate since the signature of
> SMBFileInputStream is wrong.
> The documentation could benefit from a simple "sample app that tell you how it
> works for the easiest case". It could even be displayed on the homepage.
> Does this exist somewhere in the doc/faq/list?
> What I would find useful is something like:
> 
> import jcifs.*
> 
> public class foo {
>     final String DOMAIN = "domain";
>     final String USERNAME = "username";
>     final String PASSWORD = "password";
>     final String HOST = "host";
>     ...
> 
>     public static void main(String[] args) throws Exception {
>         // authenticates to DOMAIN
>         ...
>         // connects to HOST
>         ...
>         // list content of root directory of some share drive
>         ...
>         // read some file of some share drive
>         ...
>         // check that credentials allow to read this resource
>         ...
>         // close everything and quit nicely
>         ...
>     }
> }
> 
> Thanks for your help.
> jpl
> 


-- 
Michael B Allen
PHP Active Directory SSO
http://www.ioplex.com/


More information about the jcifs mailing list