Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.skype.tutorial.step5
Class Tutorial_5

    java.lang.Object
      com.skype.tutorial.step5.Tutorial_5

    public class Tutorial_5

extends java.lang.Object

Getting Started With SkypeKit: Tutorial Application, Step 5. Answering calls. Getting a list of audio devices involves two separate commands:

- Skype.GetAvailableOutputDevices
- Skype.GetAvailableRecordingDevices

Each returns three String arrays:

1. device handles that can be used as arguments to other audio-related commands, such as Skype.SelectSoundDevices
2. descriptive device names
3. product IDs that can safely be ignored in most cases

Once the lists have been obtained, set the current sound devices to the first entry in the lists. If your speakers or microphone fail to work, you might need to change these values.

Since:
  1.0
Author:
  Andrea Drane (ported/refactored from existing C++ tutorial code)

Field Summary
`static int` | `ACCOUNT_NAME_IDX` Index of the account name in the command line argument list.
`static int` | `ACCOUNT_PWORD_IDX` Index of the account password in the command line argument list.
`static int` | `APPTOKEN_FILE_IDX` Index of the optional AppToken text file pathname in the command line argument list, which is always last.
`(package private) com.skype.api.Participant[]` | `callerList` List of callers.
`static java.lang.String` | `MY_CLASS_TAG` Info/Debug console output message prefix/identifier tag.
`private static AppToken` | `myAppToken`
`private static MySession` | `mySession`
`private static Tutorial_5` | `myTutorial` "Extraneous" instance of this tutorial so we can invoke our business logic method from `main(String[])` without having to declare it as being "static".
`static int` | `OPT_ARG_CNT` Number of optional arguments in the command line argument list.
`static int` | `REQ_ARG_CNT` Number of required arguments in the command line argument list.

Constructor Summary
`Tutorial_5()`

Method Summary
`(package private) void` | `doAcceptCalls(MySession mySession)` Find available input/output devices, then wait for incoming calls..
`static void` | `main(java.lang.String[] args)` Main loop

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### callerList

    com.skype.api.Participant[] callerList

  List of callers. Maintain this list here so it won't get garbage collected during a conversation!

  Since:
    1.0

### MY_CLASS_TAG

    public static final java.lang.String MY_CLASS_TAG

  Info/Debug console output message prefix/identifier tag. Corresponds to class name.

  Since:
    1.0
  See Also:
    Constant Field Values

### ACCOUNT_NAME_IDX

    public static final int ACCOUNT_NAME_IDX

  Index of the account name in the command line argument list.

  Since:
    1.0
  See Also:
    Constant Field Values

### ACCOUNT_PWORD_IDX

    public static final int ACCOUNT_PWORD_IDX

  Index of the account password in the command line argument list.

  Since:
    1.0
  See Also:
    Constant Field Values

### REQ_ARG_CNT

    public static final int REQ_ARG_CNT

  Number of required arguments in the command line argument list.

  Since:
    1.0
  See Also:
    Constant Field Values

### OPT_ARG_CNT

    public static final int OPT_ARG_CNT

  Number of optional arguments in the command line argument list.

  Since:
    1.0
  See Also:
    Constant Field Values

### APPTOKEN_FILE_IDX

    public static final int APPTOKEN_FILE_IDX

  Index of the optional AppToken text file pathname in the command line argument list, which is always last.

  Since:
    1.0
  See Also:
    Constant Field Values

### myAppToken

    private static AppToken myAppToken

### mySession

    private static MySession mySession

### myTutorial

    private static Tutorial_5 myTutorial

  "Extraneous" instance of this tutorial so we can invoke our business logic method from `main(String[])` without having to declare it as being "static".

  Since:
    1.0

Constructor Detail

### Tutorial_5

    public Tutorial_5()

Method Detail

### main

    public static void main(java.lang.String[] args)

  Main loop

  Parameters:
    `args` -
    1. Name of the target Skype account.
    2. Password for the target Skype account.
    3. Optional pathname of a text file containing an AppToken string.
  Since:
    1.0#

### doAcceptCalls

    void doAcceptCalls(MySession mySession)

  Find available input/output devices, then wait for incoming calls..
  1. List the available playback and recording devices.
  2. Set the current devices (input, output, notification) to the first device in their respective list.
  3. Initialize the speaker volume level.
  4. Wait for in-coming calls.

  Parameters:
    `mySession` - Populated session object
  Since:
    1.0

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD