All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.github.bloodshura.sparkium.mail.component.Recipients Maven / Gradle / Ivy

Go to download

An API which aims to facilitate the usage of javax.mail, also including other mailing services.

The newest version!
package com.github.bloodshura.sparkium.mail.component;

import com.github.bloodshura.ignitium.collection.list.XList;
import com.github.bloodshura.ignitium.collection.list.impl.XArrayList;
import com.github.bloodshura.ignitium.object.Base;
import com.github.bloodshura.ignitium.object.Mutable;

import javax.annotation.Nonnull;

@Mutable
public class Recipients extends Base {
	private final XList ccRecipients;
	private final XList recipients;

	public Recipients() {
		this(new XArrayList<>(), new XArrayList<>());
	}

	public Recipients(@Nonnull Email recipient) {
		this(new XArrayList<>(recipient), new XArrayList<>());
	}

	public Recipients(@Nonnull Email recipient, @Nonnull Email ccRecipient) {
		this(new XArrayList<>(recipient), new XArrayList<>(ccRecipient));
	}

	public Recipients(@Nonnull XList recipients, @Nonnull XList ccRecipients) {
		this.ccRecipients = ccRecipients;
		this.recipients = recipients;
	}

	@Nonnull
	public XList getCcRecipients() {
		return ccRecipients;
	}

	@Nonnull
	public XList getRecipients() {
		return recipients;
	}

	@Nonnull
	@Override
	protected Object[] stringValues() {
		return new Object[] { getRecipients(), getCcRecipients() };
	}
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy