When session is obtained, connection is made b/w javax.mail.Store & host, authenticator, port, username/password. Store objects which are involved in implementation of specified protocol might be formed by protocol information passage to the getStore() method.
After connecting to store you need to get a folder that holds
// create object of store class.
Store store = session.getStore("pop3");
store.connect(host, username, password);