2 * Copyright (C) 2010 Felix Bechstein
4 * This file is part of AndGMXsms.
6 * This program is free software; you can redistribute it and/or modify it under
7 * the terms of the GNU General Public License as published by the Free Software
8 * Foundation; either version 3 of the License, or (at your option) any later
11 * This program is distributed in the hope that it will be useful, but WITHOUT
12 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
13 * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
16 * You should have received a copy of the GNU General Public License along with
17 * this program; If not, see <http://www.gnu.org/licenses/>.
20 package de
.ub0r
.android
.andGMXsms
;
22 import android
.content
.Context
;
23 import android
.content
.Intent
;
26 * ConnectorSpecs presents all necessary informations to use a connector.
30 public interface ConnectorSpecs
{
32 /** Prefs: enable connector. */
33 String PREFS_ENABLED
= "enable_";
36 short FEATURE_NONE
= 0;
37 /** Feature: multiple recipients. */
38 short FEATURE_MULTIRECIPIENTS
= 1;
39 /** Feature: flash sms. */
40 short FEATURE_FLASHSMS
= 2;
41 /** Feature: send later. */
42 short FEATURE_SENDLATER
= 4;
43 /** Feature: custom sender. */
44 short FEATURE_CUSTOMSENDER
= 8;
47 * Init ConnectorSpecs' context.
52 void init(final Context c
);
55 * Get a fresh Connector.
61 Connector
getConnector(final Context c
);
64 * @return true if connector is enabled
69 * Set Account's balance.
74 void setBalance(final String b
);
77 * Get Conector's account balance. This does not run any update!
84 * @return connector's author
89 * @return prefix for preferences
91 String
getPrefsPrefix();
94 * @return connector's preference intent
96 Intent
getPreferencesIntent();
99 * @return connector's preference title
101 String
getPreferencesTitle();
106 * @return conector's name
108 String
getName(final boolean shortName
);
111 * @return supported feature