package org.thoughtcrime.securesms.database; import android.support.annotation.NonNull; import android.support.annotation.Nullable; import java.util.LinkedList; import java.util.List; public class MmsAddresses { private final @Nullable String from; private final @NonNull List to; private final @NonNull List cc; private final @NonNull List bcc; public MmsAddresses(@Nullable String from, @NonNull List to, @NonNull List cc, @NonNull List bcc) { this.from = from; this.to = to; this.cc = cc; this.bcc = bcc; } @NonNull public List getTo() { return to; } @NonNull public List getCc() { return cc; } @NonNull public List getBcc() { return bcc; } @Nullable public String getFrom() { return from; } public static MmsAddresses forTo(@NonNull List to) { return new MmsAddresses(null, to, new LinkedList(), new LinkedList()); } public static MmsAddresses forBcc(@NonNull List bcc) { return new MmsAddresses(null, new LinkedList(), new LinkedList(), bcc); } public static MmsAddresses forFrom(@NonNull String from) { return new MmsAddresses(from, new LinkedList(), new LinkedList(), new LinkedList()); } }