1 | void setUserName(String username) {↵ | | 1 | void setServerType(String serverType) {↵
|
2 | setProperty(USERNAME, username);↵ | | 2 | setProperty(SERVER_TYPE, serverType);↵
|
3 | }↵ | | 3 | }↵
|
|
4 | /**↵ | | 4 | /**↵
|
5 | * @return The username of the mail account.↵ | | 5 | * Returns the type of the protocol set to use when talking with the remote↵
|
| | | 6 | * server. Either MailReaderSampler.TYPE_IMAP[S] or↵
|
| | | 7 | * MailReaderSampler.TYPE_POP3[S].↵
|
| | | 8 | * ↵
|
| | | 9 | * @return Server Type↵
|
6 | */↵ | | 10 | */↵
|
7 | public String getUserName() {↵ | | 11 | public String getServerType() {↵
|
8 | return getProperty(USERNAME).toString();↵ | | 12 | return getProperty(SERVER_TYPE).toString();↵
|
9 | }↵ | | 13 | }↵
|
|
10 | /**↵ | | 14 | /**↵
|
11 | * @param password↵ | | 15 | * @param server -↵
|
| | | 16 | * The name or address of the remote server.↵
|
12 | */↵ | | 17 | */↵
|
13 | public void setPassword(String password) {↵ | | 18 | public void setServer(String server) {↵
|
14 | setProperty(PASSWORD, password);↵ | | 19 | setProperty(SERVER, server);↵
|
15 | }↵ | | 20 | }↵
|
|
16 | /**↵ | | 21 | /**↵
|
17 | * @return password↵ | | 22 | * @return The name or address of the remote server.↵
|
18 | */↵ | | 23 | */↵
|
19 | public String getPassword() {↵ | | 24 | public String getServer() {↵
|
20 | return getProperty(PASSWORD).toString();↵ | | 25 | return getProperty(SERVER).toString();↵
|
21 | }↵ | | 26 | }↵
|
|
22 | /**↵ | | 27 | /**↵
|
23 | * @param folder -↵ | | 28 | * @param username -↵
|
24 | * Name of the folder to read emails from. "INBOX" is the only↵ | | 29 | * ↵
|
25 | * acceptable value if the server type is POP3.↵ | | 30 | The username of the mail account.↵
|
26 | */↵ | | 31 | */↵
|
27 | public void setFolder(String folder) {↵ | | 32 | public void setUserName(String username) {↵
|
28 | setProperty(FOLDER, folder);↵ | | 33 | setProperty(USERNAME, username);↵
|
29 | }↵ | | 34 | }↵
|
|
30 | /**↵ | | 35 | /**↵
|
31 | * @return folder↵ | | 36 | * @return The username of the mail account.↵
|
32 | */↵ | | 37 | */↵
|
33 | public String getFolder() {↵ | | 38 | public String getUserName() {↵
|
34 | return getProperty(FOLDER).toString();↵ | | 39 | return getProperty(USERNAME).toString();↵
|
35 | } | | 40 | }
|