⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 java.telephony.provider.html

📁 JTAPI_html 用于JTAPI的HTML文档.
💻 HTML
📖 第 1 页 / 共 3 页
字号:
<!--NewPage--><html><head><!-- Generated by javadoc on Fri Feb 07 16:42:30 PST 1997 --><a name="_top_"></a><title>  Interface java.telephony.Provider</title></head><body><pre><a href="packages.html">All Packages</a>  <a href="tree.html">Class Hierarchy</a>  <a href="Package-java.telephony.html">This Package</a>  <a href="java.telephony.JtapiPeer.html#_top_">Previous</a>  <a href="java.telephony.ProviderObserver.html#_top_">Next</a>  <a href="AllNames.html">Index</a></pre><hr><h1>  Interface java.telephony.Provider</h1><dl>  <dt> public interface <b>Provider</b>  <dt> extends <a href="java.lang.Object.html#_top_">Object</a></dl>A Provider represents the telephony-software-entity that interfaces with a telephony subsystem. The telephony subsystem could be a PBX connected to a server machine, or a telephony/fax card in a desktop machine or a networking technology such as IP.<p>A Provider instance is created and returned by the <EM>JtapiPeer</EM> method <EM>getProvider()</EM> which is given a string to describe the desiredProvider. This method sets up any needed communcation paths between theapplication and the Provider object instance.<p>The Provider has methods for creating Call objects and obtaining Terminaland Address objects. Applications cannot create their own instances of Call,Terminal, Address, Connection, and TerminalConnection objects with the"new" operator.<p>The Provider maintains lists of Call, Terminal, and Address objects itknows about. Applications may create new Call objects using the<EM>Provider.createCall()</EM> method. The Provider maintains a referenceto this new Call object until the Call object moves into theProvider.INVALID state. Applications may obtain a list of all Callobjects known by the Provider (which are either in the Provider.IDLE or Provider.ACTIVE state) using the <EM>Provider.getCalls()</EM> method.<p>There may have been telephone calls present in the Provider's domainbefore the Provider software object has been created by the application.The Provider is still responsible, however, for reporting the existenceof these Calls when the application invokes the <EM>getCalls()</EM> method.This principle applies to other objects as well. For example, the Addressobject must report all Connections which are part of telephone calls evenif these Calls came into existence before the Provider.<p>Unlike Call objects, applications may not create Terminal or Addressobjects. The Provider begins with knowledge of certain Terminal and Addressobjects defined in the system. This list of Terminals and Addressesrepresents those Terminals and Addresses within the Provider's domain.This list is static once the Provider is created. The <EM>getTerminals()</EM> and <EM>getAddresses()</EM> method returns these lists, respectively.Other Addresses and Terminals may be created sometime during the operationof the Provider when the Provider learns of new instances of these objects.These new object, however, represent Addresses and Terminals outside theProvider's domain. For example, if the Provider's domain is a PBX, theProvider will know about all Addresses and Terminals in this PBX when theProvider first starts. Any Addresses and Terminals it subsequently learnsabout are outside this PBX. These Address and Terminal objects outside thisPBX are not reported via the <EM>getTerminals()</EM> and<EM>getAddresses()</EM> methods.<p>The Provider may either be in the Provider.IN_SERVICE state, theProvider.OUT_OF_SERVICE state, or the Provider.SHUTDOWN state. The Providerstate represents whether any action on that Provider or the objectsassociated with the Provider are valid. The pre-condition that the Providerstate must be Provider.IN_SERVICE exists on most Java Telephony API objectmethods and is noted in all instances. The Provider.OUT_OF_SERVICE stateindicates that the Provider is not available because of a temporarycondition not controlled by the application. The Provider.SHUTDOWN stateindicates that the Provider is permanently unavailable. The application mayuse the <EM>Provider.shutdown()</EM> method to move the Provider into theProvider.SHUTDOWN state itself or an external condition may cuase theProvider to move into this state as well.<p>Each time a state changes occurs on a Provider object, the application isnotified via an <EM>event</EM>.  This event is reported via theProviderObserver interface. Applications instantiate objects which implementthe ProviderObject interface and use the <EM>Provider.addObserver()</EM>method to begin the delivery of events. All Provider events reported viathis interface extend the ProviderEvent interface. Applications may thenquery the event object returned for the specific state change. In the coreProvider API, the following generates events to the ProviderObserver:when the Provider state changes to either Provider.IN_SERVICE,Provider.OUT_OF_SERVICE, or Provider.SHUTDOWN.<p>It is not guaranteed or expected that objects (Call, Terminal, etc.) instantiated through one Provider will be usable with anotherProvider. Thus an application that uses two providers must keep all theobjects relating to these providers separate.<p><dl>    <dt> <b>See Also:</b>    <dd> <a href="java.telephony.JtapiPeer.html#_top_">JtapiPeer</a>, <a href="java.telephony.ProviderObserver.html#_top_">ProviderObserver</a></dl><hr><a name="index"></a><h2>  <img src="images/variable-index.gif" width=207 height=38 alt="Variable Index"></h2><dl>  <dt> <img src="images/blue-ball-small.gif" width=6 height=6 alt=" o ">	<a href="#IN_SERVICE"><b>IN_SERVICE</b></a>  <dd> The Provider.IN_SERVICE state indicates that a Provider is currentlavailable for use.  <dt> <img src="images/blue-ball-small.gif" width=6 height=6 alt=" o ">	<a href="#OUT_OF_SERVICE"><b>OUT_OF_SERVICE</b></a>  <dd> The Provider.OUT_OF_SERVICE state indicates that a Provider is temporarilynot available for use.  <dt> <img src="images/blue-ball-small.gif" width=6 height=6 alt=" o ">	<a href="#SHUTDOWN"><b>SHUTDOWN</b></a>  <dd> The SHUTDOWN state indicates that a Provider is permanently no longeravailable for use.</dl><h2>  <img src="images/method-index.gif" width=207 height=38 alt="Method Index"></h2><dl>  <dt> <img src="images/red-ball-small.gif" width=6 height=6 alt=" o ">	<a href="#addObserver(java.telephony.ProviderObserver)"><b>addObserver</b></a>(ProviderObserver)  <dd> Adds an observer to the Provider.  <dt> <img src="images/red-ball-small.gif" width=6 height=6 alt=" o ">	<a href="#createCall()"><b>createCall</b></a>()  <dd> Creates and returns a new instance of the Call object.  <dt> <img src="images/red-ball-small.gif" width=6 height=6 alt=" o ">	<a href="#getAddress(java.lang.String)"><b>getAddress</b></a>(String)  <dd> Returns an Address object which corresponds to the telephone numberstring provided.  <dt> <img src="images/red-ball-small.gif" width=6 height=6 alt=" o ">	<a href="#getAddressCapabilities(java.telephony.Terminal)"><b>getAddressCapabilities</b></a>(Terminal)  <dd> Gets the AddressCapabilities object with respect to a Terminal.  <dt> <img src="images/red-ball-small.gif" width=6 height=6 alt=" o ">	<a href="#getAddresses()"><b>getAddresses</b></a>()  <dd> Returns a list of Addresses associated with the Provider and within theProvider's domain.  <dt> <img src="images/red-ball-small.gif" width=6 height=6 alt=" o ">	<a href="#getCallCapabilities(java.telephony.Terminal, java.telephony.Address)"><b>getCallCapabilities</b></a>(Terminal, Address)  <dd> Gets the CallCapabilities object with respect to a Terminal.  <dt> <img src="images/red-ball-small.gif" width=6 height=6 alt=" o ">	<a href="#getCalls()"><b>getCalls</b></a>()  <dd> Returns an array of Call objects currently associated with the Provider.  <dt> <img src="images/red-ball-small.gif" width=6 height=6 alt=" o ">	<a href="#getConnectionCapabilities(java.telephony.Terminal, java.telephony.Address)"><b>getConnectionCapabilities</b></a>(Terminal, Address)  <dd> Gets the ConnectionCapabilities object with respect to a Terminal.  <dt> <img src="images/red-ball-small.gif" width=6 height=6 alt=" o ">	<a href="#getName()"><b>getName</b></a>()  <dd> Returns the unique string name of the Provider.  <dt> <img src="images/red-ball-small.gif" width=6 height=6 alt=" o ">	<a href="#getObservers()"><b>getObservers</b></a>()  <dd> Returns a list of all ProviderObservers associated with this call object.  <dt> <img src="images/red-ball-small.gif" width=6 height=6 alt=" o ">	<a href="#getProviderCapabilities(java.telephony.Terminal)"><b>getProviderCapabilities</b></a>(Terminal)  <dd> Returns the ProviderCapabilities object with respect to a Terminal.  <dt> <img src="images/red-ball-small.gif" width=6 height=6 alt=" o ">	<a href="#getState()"><b>getState</b></a>()  <dd> Returns the current state of the Provider, either Provider.IN_SERVICE,Provider.OUT_OF_SERVICE, or Provider.SHUTDOWN.  <dt> <img src="images/red-ball-small.gif" width=6 height=6 alt=" o ">	<a href="#getTerminal(java.lang.String)"><b>getTerminal</b></a>(String)  <dd> Returns an instance of the Terminal class which corresponds to thegiven name.  <dt> <img src="images/red-ball-small.gif" width=6 height=6 alt=" o ">	<a href="#getTerminalCapabilities(java.telephony.Terminal)"><b>getTerminalCapabilities</b></a>(Terminal)  <dd> Gets the TerminalCapabilities object with respect to a Terminal.  <dt> <img src="images/red-ball-small.gif" width=6 height=6 alt=" o ">	<a href="#getTerminalConnectionCapabilities(java.telephony.Terminal)"><b>getTerminalConnectionCapabilities</b></a>(Terminal)  <dd> Gets the TerminalConnectionCapabilities of a Terminal.  <dt> <img src="images/red-ball-small.gif" width=6 height=6 alt=" o ">	<a href="#getTerminals()"><b>getTerminals</b></a>()  <dd> Returns a list of Terminals associated with the Provider and within theProvider's domain.  <dt> <img src="images/red-ball-small.gif" width=6 height=6 alt=" o ">	<a href="#removeObserver(java.telephony.ProviderObserver)"><b>removeObserver</b></a>(ProviderObserver)  <dd> Removes the given observer from the Provider.  <dt> <img src="images/red-ball-small.gif" width=6 height=6 alt=" o ">	<a href="#shutdown()"><b>shutdown</b></a>()  <dd> Instructs the Provider to shut itself down and perform all neccessarycleanup.</dl><a name="variables"></a><h2>  <img src="images/variables.gif" width=153 height=38 alt="Variables"></h2><a name="IN_SERVICE"><img src="images/blue-ball.gif" width=12 height=12 alt=" o "></a><b>IN_SERVICE</b><pre>  public final static int IN_SERVICE</pre><dl>  <dd> The Provider.IN_SERVICE state indicates that a Provider is currentlavailable for use.</dl><a name="OUT_OF_SERVICE"><img src="images/blue-ball.gif" width=12 height=12 alt=" o "></a><b>OUT_OF_SERVICE</b><pre>  public final static int OUT_OF_SERVICE</pre><dl>  <dd> The Provider.OUT_OF_SERVICE state indicates that a Provider is temporarilynot available for use. Most methods in the Java Telephony API are invalidwhen the Provider is in this state. Providers may come back IN_SERVICEat any time, however, the application can take no direct action to causethis change.</dl><a name="SHUTDOWN"><img src="images/blue-ball.gif" width=12 height=12 alt=" o "></a><b>SHUTDOWN</b><pre>  public final static int SHUTDOWN</pre><dl>  <dd> The SHUTDOWN state indicates that a Provider is permanently no longeravailable for use. Most methods in the Java TelephonyAPI are invalid whenthe Provider is in this state.</dl><a name="methods"></a><h2>  <img src="images/methods.gif" width=151 height=38 alt="Methods"></h2><a name="getState()"><img src="images/red-ball.gif" width=12 height=12 alt=" o "></a><a name="getState"><b>getState</b></a><pre>  public abstract int getState() throws <a href="java.telephony.PlatformException.html#_top_">PlatformException</a></pre><dl>  <dd> Returns the current state of the Provider, either Provider.IN_SERVICE,Provider.OUT_OF_SERVICE, or Provider.SHUTDOWN.<p>  <dl>    <dt> <b>Returns:</b>    <dd> The current state of the provider.    <dt> <b>Throws:</b> <a href="java.telephony.PlatformException.html#_top_">PlatformException</a>    <dd> A platform-specific exception occurred.  </dl></dl><a name="getName()"><img src="images/red-ball.gif" width=12 height=12 alt=" o "></a><a name="getName"><b>getName</b></a><pre>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -