Java Reference
In-Depth Information
/** Set from */
public
public
void
void
setFrom
(
String fm
) {
from
=
fm
;
}
/** Get subject */
public
public
String
getSubject
() {
return
return
subject
;
}
/** Set subject */
public
public
void
void
setSubject
(
String subj
) {
subject
=
subj
;
}
// SETTERS/GETTERS FOR TO: LIST
/** Get tolist, as an array of Strings */
public
public
List
<
String
>
getToList
() {
return
return
toList
;
}
/** Set to list to an ArrayList of Strings */
public
public
void
void
setToList
(
ArrayList
<
String
>
to
) {
toList
=
to
;
}
/** Set to as a string like "tom, mary, robin@host". Loses any
* previously set values. */
public
public
void
void
setToList
(
String s
) {
toList
=
Arrays
.
asList
(
s
.
split
(
",\\s+"
));
}
/** Add one "to" recipient */
public
public
void
void
addTo
(
String to
) {
toList
.
add
(
to
);
}
// SETTERS/GETTERS FOR CC: LIST
/** Get cclist, as an array of Strings */
public
public
List
<
String
>
getCcList
() {
return
return
ccList
;
}
/** Set cc list to an ArrayList of Strings */