×
INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!
  • Students Click Here

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Login User and Password

Login User and Password

Login User and Password

(OP)
Hi,

I intend creating a web application in java/Jdeveloper that is an add on to ellipse. I need to use the user id and password validation modules as a front end to my application (Similar to Ellipse).

Has anyone done something similar or have any ideas.

Regards
  Kes

RE: Login User and Password

I'm not sure what exactly you are referring to in your question... Ellipse User id and password validation occurs on login to Ellipse after a connection to the Ellipse server.

The Ellipse WinView Client login screen (mlog.exe) is a Windows COM based object.  This is only used in a win32 environment.

You will have to create you own login screen and use the connect and login methods of the MimsSession class... see the EllipseConnection.java code below:

CODE

package com.mincom.ellipse.myapp.connection;

import java.io.IOException;
import java.io.InterruptedIOException;

import com.mincom.mims.tech.mware.cbr.CBRException;
import com.mincom.mims.tech.mware.common.*;


/**
 * The EllipseConnection class is used to establish a connection to Ellipse
 */
public class EllipseConnection {

    private IMimsSession mySession;
    private String buflib = "";
    
    private String hostName;
    private String portNumber;
    private String hostUsername;
    private String hostPassword;
    
    /**
     * EllipseConnection constructor
     */
    public EllipseConnection() {
        
    }
    
    /**
     * Set the location of the bfl files (for MSO access)
     * @param location
     */
    public void setBufferLibraryLocation(String location) {
        buflib = location;
    }

    /**
     * Connect to the Ellipse server
     * @param TP
     * @param hostName
     * @param portNumber
     * @param hostUsername
     * @param hostPassword
     * @throws EllipseConnectionException
     */

    public void connect(String TP, String hostName, int portNumber, String hostUsername, String hostPassword) throws EllipseConnectionException {
        
        MimsSessionFactory sessionFactory = MimsSessionFactory.getMimsSessionFactory();
        mySession = sessionFactory.getMimsSession(TP,buflib);
    
        try {
            mySession.connect(hostName, portNumber, hostUsername, hostPassword);
        } catch (InterruptedIOException e) {
            throw new EllipseConnectionException(e.toString());
        } catch (IOException e) {
            throw new EllipseConnectionException(e.toString());
        } catch (CBRException e) {
            throw new EllipseConnectionException(e.toString());
        }
    }  
    
    /**
     * This method attempts to login to the Ellipse server.
     * @param mimsUser
     * @param mimsPwd
     * @param district
     * @param position
     * @throws EllipseConnectionException
     */
    //login to mims
    public void login(String mimsUser,String mimsPwd,String district,String position) throws EllipseConnectionException {
        try {
            mySession.login(mimsUser,mimsPwd,district,position);
        } catch (CBRException e) {
            throw new EllipseConnectionException(trimQuotes(e.toString()));
        } catch (MwareException e) {
            throw new EllipseConnectionException(trimQuotes(e.toString()));
        } catch (ServerException e) {
            throw new EllipseConnectionException(trimQuotes(e.getLocalizedMessage()));
        } catch (IOException e) {
            throw new EllipseConnectionException(trimQuotes(e.toString()));
        }
    }


    /**
     * This method attempts to disconnect from the Ellipse server.
     * @throws EllipseConnectionException
     */
    //disconnect from mims server
    public void disconnect() throws EllipseConnectionException {
        try {
            mySession.disconnect();
        } catch (IOException e) {
            throw new EllipseConnectionException(e.toString());
        } catch (CBRException e) {
            throw new EllipseConnectionException(e.toString());
        }
    }
    
    /**
     * Get the current connection to Ellipse
     * @return IMimsSession: The current Ellipse session
     */
    public IMimsSession getSession() {
        return mySession;
    }
    
    /**
     * Trim the error message and remove double quotes
     * from the ends of the message.
     */
    private String trimQuotes(String errorMessage) {
        // Start with initial trim
        String trimMessage = errorMessage.trim();
        // Strip double quotes (") from error message
        if (trimMessage.startsWith("\"") && trimMessage.endsWith("\"")) {
            trimMessage = trimMessage.substring(1, trimMessage.length()-1);
        }
        // Trim again on the way out
        return trimMessage.trim();
    }
}

RE: Login User and Password

(OP)
Hi,

Thank you for the java code. This is what I will use.

Regards
  Kes
 

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members! Already a Member? Login

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close