samedi 19 septembre 2020

Design pattern suggestions for reading and parsing related methods for emails using java Mail API?

I am currently working with selenium and I am using JavaMail API (v. 1.6.2) to retreive mails and parse them for the following uses, e.g:

  1. Extract the account confimation link.
  2. Extract the account confirmation code.
  3. Extract the link for account deletion.
  4. etc...

As you can already infer, I am doing it to automatize certain online account procedures such as account creation and deletion and so on.

First I thought of creating keywords for each and every methods and use them but since there are going to be email session objects, this wouldn't be a nice way to create a new email session object on every single method call.

So if anyone has ever done somethign similar to this, do you have any suggestions for using specific design patterns?

Aucun commentaire:

Enregistrer un commentaire