connectivity/com.nokia.tcf/src/com/nokia/tcf/api/ITCConnection.java
author cawthron
Fri, 15 Jan 2010 11:19:08 -0600
branchRCL_2_4
changeset 768 774b5f74e4ed
parent 60 9d2210c8eed2
permissions -rw-r--r--
add release notes about WINSCW compiler 3.2.5 build 487
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
2
cawthron
parents:
diff changeset
     1
/*
cawthron
parents:
diff changeset
     2
* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
cawthron
parents:
diff changeset
     3
* All rights reserved.
cawthron
parents:
diff changeset
     4
* This component and the accompanying materials are made available
cawthron
parents:
diff changeset
     5
* under the terms of the License "Eclipse Public License v1.0"
cawthron
parents:
diff changeset
     6
* which accompanies this distribution, and is available
cawthron
parents:
diff changeset
     7
* at the URL "http://www.eclipse.org/legal/epl-v10.html".
cawthron
parents:
diff changeset
     8
*
cawthron
parents:
diff changeset
     9
* Initial Contributors:
cawthron
parents:
diff changeset
    10
* Nokia Corporation - initial contribution.
cawthron
parents:
diff changeset
    11
*
cawthron
parents:
diff changeset
    12
* Contributors:
cawthron
parents:
diff changeset
    13
*
cawthron
parents:
diff changeset
    14
* Description: 
cawthron
parents:
diff changeset
    15
*
cawthron
parents:
diff changeset
    16
*/
cawthron
parents:
diff changeset
    17
/**
cawthron
parents:
diff changeset
    18
 * 
cawthron
parents:
diff changeset
    19
 */
cawthron
parents:
diff changeset
    20
package com.nokia.tcf.api;
cawthron
parents:
diff changeset
    21
cawthron
parents:
diff changeset
    22
import org.eclipse.core.runtime.IStatus;
cawthron
parents:
diff changeset
    23
cawthron
parents:
diff changeset
    24
/**
cawthron
parents:
diff changeset
    25
 * This interface the basis of all connection type classes. Instantiate one of these classes using
cawthron
parents:
diff changeset
    26
 * the TCFClassFactory for the connection type required.
cawthron
parents:
diff changeset
    27
 * 
cawthron
parents:
diff changeset
    28
 */
cawthron
parents:
diff changeset
    29
public interface ITCConnection {
cawthron
parents:
diff changeset
    30
	
cawthron
parents:
diff changeset
    31
	/**
cawthron
parents:
diff changeset
    32
	 * Default retry interval and retry timeout (in seconds)
cawthron
parents:
diff changeset
    33
	 */
cawthron
parents:
diff changeset
    34
	public final long DEFAULT_COMM_ERROR_RETRY_INTERVAL = 1; // 1 second
cawthron
parents:
diff changeset
    35
	public final long DEFAULT_COMM_ERROR_RETRY_TIMEOUT = 5*60; // 5 minutes
cawthron
parents:
diff changeset
    36
cawthron
parents:
diff changeset
    37
	/**
cawthron
parents:
diff changeset
    38
	 * Return a string detailing this connection
cawthron
parents:
diff changeset
    39
	 * @return
cawthron
parents:
diff changeset
    40
	 */
cawthron
parents:
diff changeset
    41
	public String getConnectionDescription();
cawthron
parents:
diff changeset
    42
	/**
cawthron
parents:
diff changeset
    43
	 * Return connection type
cawthron
parents:
diff changeset
    44
	 * @return
cawthron
parents:
diff changeset
    45
	 */
60
9d2210c8eed2 Commit changes for 2.1.0
chpeckha
parents: 2
diff changeset
    46
	public String getConnectionType();
2
cawthron
parents:
diff changeset
    47
	/**
cawthron
parents:
diff changeset
    48
	 * Get the current retry interval in seconds
cawthron
parents:
diff changeset
    49
	 * @return
cawthron
parents:
diff changeset
    50
	 */
cawthron
parents:
diff changeset
    51
	public long getRetryInterval();
cawthron
parents:
diff changeset
    52
	/**
cawthron
parents:
diff changeset
    53
	 * Get the current retry timeout in seconds
cawthron
parents:
diff changeset
    54
	 * @return
cawthron
parents:
diff changeset
    55
	 */
cawthron
parents:
diff changeset
    56
	public long getRetryTimeout();
cawthron
parents:
diff changeset
    57
	/**
cawthron
parents:
diff changeset
    58
	 * Set the connection type
cawthron
parents:
diff changeset
    59
	 * @param inConnectionType
cawthron
parents:
diff changeset
    60
	 * @return IStatus
cawthron
parents:
diff changeset
    61
	 */
60
9d2210c8eed2 Commit changes for 2.1.0
chpeckha
parents: 2
diff changeset
    62
	public IStatus setConnectionType(String inConnectionType);
2
cawthron
parents:
diff changeset
    63
	
cawthron
parents:
diff changeset
    64
	/**
cawthron
parents:
diff changeset
    65
	 * Set the retry interval after a comm error in seconds. The default is 1 second. 
cawthron
parents:
diff changeset
    66
	 * Must be >= 1 second and less then retry timeout.
cawthron
parents:
diff changeset
    67
	 * 
cawthron
parents:
diff changeset
    68
	 * @param inRetryInterval in seconds
cawthron
parents:
diff changeset
    69
	 * @return IStatus
cawthron
parents:
diff changeset
    70
	 */
cawthron
parents:
diff changeset
    71
	public IStatus setRetryInterval(long inRetryInterval);
cawthron
parents:
diff changeset
    72
	/**
cawthron
parents:
diff changeset
    73
	 * Set the retry timeout after a comm error in seconds. The default is 5 minutes.
cawthron
parents:
diff changeset
    74
	 * Must be > then the retry interval.
cawthron
parents:
diff changeset
    75
	 * 
cawthron
parents:
diff changeset
    76
	 * @param inRetryTimeout in seconds
cawthron
parents:
diff changeset
    77
	 * @return IStatus
cawthron
parents:
diff changeset
    78
	 */
cawthron
parents:
diff changeset
    79
	public IStatus setRetryTimeout(long inRetryTimeout);
cawthron
parents:
diff changeset
    80
cawthron
parents:
diff changeset
    81
	/**
cawthron
parents:
diff changeset
    82
	 * Specify which message format to decode on incoming messages
cawthron
parents:
diff changeset
    83
	 * A string to indicate the formatting types
cawthron
parents:
diff changeset
    84
	 * e.g. "platsim", "ost", etc.
cawthron
parents:
diff changeset
    85
	 * 
cawthron
parents:
diff changeset
    86
	 * @param inDecodeFormat
cawthron
parents:
diff changeset
    87
	 */
cawthron
parents:
diff changeset
    88
	public IStatus setDecodeFormat(String inDecodeFormat);
cawthron
parents:
diff changeset
    89
cawthron
parents:
diff changeset
    90
	/**
cawthron
parents:
diff changeset
    91
	 * Returns the current decode format for this connection
cawthron
parents:
diff changeset
    92
	 * 
cawthron
parents:
diff changeset
    93
	 * @return
cawthron
parents:
diff changeset
    94
	 */
cawthron
parents:
diff changeset
    95
	public String getDecodeFormat();
cawthron
parents:
diff changeset
    96
}