Package com.sun.enterprise.universal.process

Examples of com.sun.enterprise.universal.process.WindowsException


                new HashMap<String, String>((Map) (System.getProperties())));

        node = theNode;

        if (node == null)
            throw new WindowsException(
                    Strings.get("internal.error", "Node is null"));

        if (!isDcomNode(node))
            throw new WindowsException(Strings.get("not.dcom.node",
                    getNode().getName(), getNode().getType()));

        SshConnector conn = node.getSshConnector();
        if (conn == null)
            throw new WindowsException(Strings.get("no.password"));

        SshAuth auth = conn.getSshAuth();
        if (auth == null)
            throw new WindowsException(Strings.get("no.password"));

        String notFinal = auth.getPassword();
        if (!ok(notFinal))
            throw new WindowsException(Strings.get("no.password"));

        password = DcomUtils.resolvePassword(notFinal);

        notFinal = node.getNodeHost();
        if (!ok(notFinal))
            notFinal = conn.getSshHost();
        if (!ok(notFinal))
            throw new WindowsException(Strings.get("no.host"));
        host = resolver.resolve(notFinal);

        notFinal = auth.getUserName();
        if (!ok(notFinal))
            notFinal = System.getProperty("user.name");
        if (!ok(notFinal))
            throw new WindowsException(Strings.get("no.username"));
        user = resolver.resolve(notFinal);

        notFinal = node.getWindowsDomain();
        if (!ok(notFinal))
            notFinal = host;
        windowsDomain = resolver.resolve(notFinal);

        notFinal = node.getInstallDirUnixStyle();
        if (!ok(notFinal))
            throw new WindowsException(Strings.get("no.lib.dir"));

        if (!notFinal.endsWith("/"))
            notFinal += "/";

        notFinal += SystemPropertyConstants.getComponentName();
View Full Code Here


            wrfs = parent.wrfs;
            smbPath = parent.smbPath + removeLeadingAndTrailingSlashes(path) + "/";
            smbFile = new SmbFile(smbPath, wrfs.getAuthorization());
        }
        catch (Exception e) {
            throw new WindowsException(e);
        }
    }
View Full Code Here

            //SmbFile remoteRoot = new SmbFile("smb://" + name + "/" + path.replace('\\', '/').replace(':', '$')+"/",createSmbAuth());

            smbFile = new SmbFile(smbPath, wrfs.getAuthorization());
        }
        catch (Exception e) {
            throw new WindowsException(e);
        }
    }
View Full Code Here

    public final boolean exists() throws WindowsException {
        try {
            return smbFile.exists();
        }
        catch (Exception se) {
            throw new WindowsException(se);
        }
    }
View Full Code Here

    public final String[] list() throws WindowsException {
        try {
            return smbFile.list();
        }
        catch (Exception se) {
            throw new WindowsException(se);
        }
    }
View Full Code Here

    public final void createNewFile() throws WindowsException {
        try {
            smbFile.createNewFile();
        }
        catch (Exception se) {
            throw new WindowsException(se);
        }
    }
View Full Code Here

    public final void copyTo(WindowsRemoteFile wf) throws WindowsException {
        try {
            smbFile.copyTo(wf.smbFile);
        }
        catch (Exception se) {
            throw new WindowsException(se);
        }
    }
View Full Code Here

    public final void delete() throws WindowsException {
        try {
            smbFile.delete();
        }
        catch (Exception se) {
            throw new WindowsException(se);
        }
    }
View Full Code Here

        try {
            if (exists()) {
                if (force)
                    delete();
                else
                    throw new WindowsException(Strings.get("dir.already.exists", getPath()));
            }
            smbFile.mkdirs();
        }
        catch (WindowsException we) {
            throw we;
        }
        catch (Exception se) {
            throw new WindowsException(se);
        }
    }
View Full Code Here

                if (progress != null)
                    progress.callback(totalBytesCopied, filelength);
            }
        }
        catch (Exception e) {
            throw new WindowsException(e);
        }
        finally {
            try {
                sin.close();
            }
View Full Code Here

TOP

Related Classes of com.sun.enterprise.universal.process.WindowsException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.