|
JSR-043: JTAPI-1.4 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
A MobileProvider
represents the telephony software-entity that interfaces
with a wireless subsystem. It is an extension of the core provider
with various additions needed for wireless communication.
Provider
interface.
The states defined by this interface are related to the states defined in
the core package in certain, specific ways, as defined below. Applications
may obtain the MobileProvider
state via the
Provider.getState()
method defined on the core. This
method returns one of the integer state constants defined in this interface.
Below is a description of each MobileProvider
state in
real-world terms. These real-world descriptions only serve to provide a
more intuitive understanding of what is going on. Several methods in this
specification state pre-conditions based upon the
MobileProvider
state. Most of the states are identical
to those defined in the core package.
MobileProvider.RESTRICTED_SERVICE |
This state indicates that the subscription is invalid (invalid subscription, forbidden network...): from the network point of view, only emergency calls are allowed. Local operations (such as Personal Information Management) are available. |
MobileProvider
states and the Provider
states. If an implementation supports the mobile package, it must
ensure this relationship is properly maintained.
Since the states defined in the MobileProvider
interface
provide more detail to the states defined in the Provider
interface, each state in the Provider
interface corresponds
to a state defined in the MobileProvider
interface.
Conversely, each MobileProvider
state corresponds to
exactly one Provider
state. This arrangement permits
applications to view either the core state or the mobile state and
still see a consistent view.
The following table outlines the relationship between the core package Provider states and the mobile package Provider states.
If the mobile package state is... | then the core package state must be... |
MobileProvider.RESTRICTED_SERVICE |
Provider.IN_SERVICE |
MobileProviderListener
interface. Applications instantiate objects
which implement this interface and use the
Provider.addProviderListener(MobileProviderListener)
method to begin
the delivery of events.
MobileProviderEvent
,
MobileProviderListener
Field Summary | |
static int |
RESTRICTED_SERVICE
The MobileProvider.RESTRICTED_SERVICE state indicates a
MobileProvider services are restricted because of missing user
subscription or invalid/missing password such as four-digit PIN-code. |
Fields inherited from interface javax.telephony.Provider |
IN_SERVICE, OUT_OF_SERVICE, SHUTDOWN |
Method Summary | |
void |
cancelAvailableNetworkRequest()
Cancels an outstanding getAvailableNetworks-request, if possible. |
MobileNetwork[] |
getAvailableNetworks(boolean fullsearch)
Scans for available networks in the area or returns the previous search results, if available. |
MobileNetwork |
getCurrentNetwork()
Returns the current network object. |
MobileNetwork |
getHomeNetwork()
Get the home network object. |
int |
getMobileState()
Returns the current state of the MobileProvider. |
java.util.Date |
getNetworkTime()
Get the network time. |
java.util.TimeZone |
getNetworkTimeZone()
Get the network time zone. |
java.lang.String |
getType()
Returns the type of network/wireless service. |
boolean |
isRoaming()
Return the current roaming status. |
void |
setNetwork(MobileNetwork network)
Selects a network as the current servicing network. |
Field Detail |
public static final int RESTRICTED_SERVICE
MobileProvider.RESTRICTED_SERVICE
state indicates a
MobileProvider services are restricted because of missing user
subscription or invalid/missing password such as four-digit PIN-code.
In this state, only emergency calls are allowed.Method Detail |
public int getMobileState()
public MobileNetwork[] getAvailableNetworks(boolean fullsearch) throws MethodNotSupportedException, InvalidStateException, ResourceUnavailableException
fullsearch
- True, if full search is initiated. This may take
several tens of seconds to complete. False, if previous results
without a full scan are asked for.MethodNotSupportedException
- Indicates that the scanning
for available networks is not supported.InvalidStateException
- Indicates the implementation is
in a such state which network search is not possible (call ongoing,
for example.)ResourceUnavailableException
- indicates that a resource
inside the system is not available to complete an operation. This
may often be the case when the application wants the
previous results.MobileNetwork
public void cancelAvailableNetworkRequest() throws MethodNotSupportedException, InvalidStateException
MethodNotSupportedException
- Indicates the cancelling of
the radio scan capability is not supported.InvalidStateException
- Indicates the implementation is
in a such state in which the cancelling of an operation is not
possible.public MobileNetwork getCurrentNetwork()
public MobileNetwork getHomeNetwork() throws MethodNotSupportedException, ResourceUnavailableException
MethodNotSupportedException
- Indicates the home network
information capability is not supported.ResourceUnavailableException
- Indicates that
a resource inside the system is not available to
complete an operation.public void setNetwork(MobileNetwork network) throws MethodNotSupportedException, InvalidStateException, ResourceUnavailableException
network
- Network to be selected.MethodNotSupportedException
- Indicates network
selection is not supported.InvalidStateException
- Indicates the implementation
is in a state in which setting the network is not possible
(call ongoing, for example.)ResourceUnavailableException
- Indicates that a
resource inside the system is not available to complete the operation.public boolean isRoaming() throws MethodNotSupportedException, InvalidStateException
MethodNotSupportedException
- Indicates this method is
not supported by the implementation.InvalidStateException
- Indicates the MobileProvider
or MobileRadio
is in a state in which the roaming
state is not available.public java.lang.String getType()
public java.util.Date getNetworkTime() throws MethodNotSupportedException
MethodNotSupportedException
- Indicates the home network
information capability is not supported.public java.util.TimeZone getNetworkTimeZone() throws MethodNotSupportedException
MethodNotSupportedException
- Indicates the home network
information capability is not supported.
|
JSR-043: JTAPI-1.4 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |