View Javadoc
1 /* 2 * (C) 2002 David Carr david@carr.name 3 * 4 * This program is free software; you can redistribute it and/or modify 5 * it under the terms of the GNU General Public License as published by 6 * the Free Software Foundation; either version 2 of the License, or 7 * (at your option) any later version. 8 * 9 * This program is distributed in the hope that it will be useful, 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 * GNU General Public License for more details. 13 * 14 * You should have received a copy of the GNU General Public License 15 * along with this program; if not, write to the Free Software 16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 */ 18 19 package net.sourceforge.mflow.api; 20 21 /*** 22 * Describes a method of reaching a Contact 23 * 24 * @author <a href="mailto:david@carr.name">David Carr</a> 25 * @version $Revision: 1.3 $ 26 */ 27 public interface ContactMethod extends Iconable { 28 /*** 29 * Constant for ContactMethods that are best displayed one Msg at a time 30 */ 31 int VIEW_TYPE_SINGLE = 0; 32 /*** 33 * Constant for ContactMethods that are best displayed in a Msg dialog 34 */ 35 int VIEW_TYPE_MULTI = 1; 36 37 /*** 38 * Accessor for the protocol 39 * 40 * @return the current protocol 41 */ 42 String getProtocol(); 43 44 /*** 45 * Mutator for the identifier 46 * 47 * @param id the new identifier 48 */ 49 void setIdentifier(String id); 50 51 /*** 52 * Accessor for the identifier 53 * 54 * @return the current identifier 55 */ 56 String getIdentifier(); 57 58 /*** 59 * Accessor for the user-friendly name 60 * 61 * @return the display name for the contact method 62 */ 63 String getDisplayName(); 64 65 /*** 66 * Mutator for the associated Contact 67 * 68 * @param c the Contact to associate with this ContactMethod 69 */ 70 void setContact(Contact c); 71 72 /*** 73 * Accessor for the associated Contact 74 * 75 * @return the Contact to associate with this ContactMethod 76 */ 77 Contact getContact(); 78 79 /*** 80 * Returns a String representing this ContactMethod in a parseable form 81 * (protocol:id) 82 * 83 * @return a string representing this ContactMethod 84 * @see ContactMethodManager#parse(String) 85 */ 86 String idString(); 87 88 /*** 89 * Returns the prefered view type 90 * 91 * @return the prefered view type 92 * @see #VIEW_TYPE_SINGLE 93 * @see #VIEW_TYPE_MULTI 94 */ 95 int getPreferredViewType(); 96 }

This page was automatically generated by Maven