-- CS module extracted from ITU-T Z.165 (03/2011)
namespace Etsi.Ttcn3.Tri
{
public interface ITriBoolean
{
bool BooleanValue { get; set; }
}
public interface IQualifiedName
{
string ModuleName { get; }
string BaseName { get; }
bool Equals(IQualifiedName name);
}
public interface ITriPortId
{
string PortName { get; }
ITriComponentId Component { get; }
bool IsArray { get; }
int PortIndex { get; }
IQualifiedName PortTypeName { get; }
}
public interface ITriPortIdList
: System.Collections.IEnumerable
{
int Size { get; }
bool IsEmpty { get; }
ITriPortId this[int index] { get; }
}
public interface ITriComponentId
{
string ComponentId { get; }
string ComponentName { get; }
IQualifiedName ComponentTypeName { get; }
bool Equals(ITriComponentId comp);
}
public interface ITriComponentIdList : System.Collections.IEnumerable
{
int Size { get; }
bool IsEmpty { get; }
ITriComponentId this[int index] { get; }
void Clear();
void Add(ITriComponentId comp);
}
public interface ITriMessage
{
byte[] EncodedMessage { get; set; }
int NumberOfBits { get; }
void SetEncodedMessage(byte[] data, int numberOfBits);
bool Equals(ITriMessage msg);
}
public interface ITriAddress
{
byte[] EncodedAddress { get; set; }
bool Equals(ITriAddress addr);
}
public interface ITriAddressList : System.Collections.IEnumerable
{
int Size { get; }
bool IsEmpty { get; }
ITriAddress this[int index] { get; }
void Clear();
void Add(ITriAddress addr);
}
public interface ITriSignatureId : IQualifiedName { }
public interface ITriParameter
{
string ParameterName { get; set; }
TriParameterPassingMode ParameterPassingMode { get; set; }
byte[] EncodedParameter { get; set; }
}
public interface ITriParameterList : System.Collections.IEnumerable
{
int Size { get; }
bool IsEmpty { get; }
ITriParameterId this[int index] { get; }
void Clear();
void Add(ITriParameter comp);
}
public interface ITriException
{
byte[] EncodedException { get; set; }
bool Equals(ITriException exception);
}
public interface ITriTimerId
{
string TimerName { get; }
bool Equals(ITriTimerId timer);
}
public interface ITriTimerDuration
{
double Duration { get; set; }
bool Equals(ITriTimerDuration duration);
}
public interface ITriFunctionId : IQualifiedName { }
public interface ITriTestCaseId : IQualifiedName { }
public enum TriStatus
{
TriOk = 0,
TriError = -1
}
public interface ITriCommunicationSA
{
// Reset operation
// Ref: TRI-Definition 5.5.1
TriStatus TriSAReset();
// Connection handling operations
// Ref: TRI-Definition 5.5.2.1
TriStatus TriExecuteTestCase(ITriTestCaseId testCaseId,
ITriPortIdList portIdList);
// Ref: TRI-Definition 5.5.2.2
TriStatus TriMap(ITriPortId compPortId, ITriPortId tsiPortId);
// Ref: TRI-Definition 5.5.2.3
TriStatus TriUnmap(ITriPortId compPortId, ITriPortId tsiPortId);
// Ref: TRI-Definition 5.5.2.4
TriStatus TriEndTestCase();
// Message based communication operations
// Ref: TRI-Definition 5.5.3.1
TriStatus TriSend(ITriComponentId componentId, ITriPortId tsiPortId,
ITriAddress address, ITriMessage sentMessage);
// Ref: TRI-Definition 5.5.3.2
TriStatus TriSendBC(ITriComponentId componentId, ITriPortId tsiPortId,
ITriMessage sentMessage);
// Ref: TRI-Definition 5.5.3.3
TriStatus TriSendMC(ITriComponentId componentId, ITriPortId tsiPortId,
ITriAddressList addresses, ITriMessage sentMessage);
// Procedure based communication operations
// Ref: TRI-Definition 5.5.4.1
TriStatus TriCall(ITriComponentId componentId, ITriPortId tsiPortId,
ITriAddress sutAddress, ITriSignatureId signatureId,
ITriParameterList parameterList);
// Ref: TRI-Definition 5.5.4.2
TriStatus TriCallBC(ITriComponentId componentId, ITriPortId tsiPortId,
ITriSignatureId signatureId, ITriParameterList parameterList);
// Ref: TRI-Definition 5.5.4.3
TriStatus TriCallMC(ITriComponentId componentId, ITriPortId tsiPortId,
ITriAddressList sutAddresses, ITriSignatureId signatureId,
ITriParameterList parameterList);
// Ref: TRI-Definition 5.5.4.4
TriStatus TriReply(ITriComponentId componentId, ITriPortId tsiPortId,
ITriAddress sutAddress, ITriSignatureId signatureId,
ITriParameterList parameterList, ITriParameter returnValue);
// Ref: TRI-Definition 5.5.4.5
TriStatus TriReplyBC(ITriComponentId componentId, ITriPortId tsiPortId,
ITriSignatureId signatureId, ITriParameterList parameterList,
ITriParameter returnValue);
// Ref: TRI-Definition 5.5.4.6
TriStatus TriReplyMC(ITriComponentId componentId, ITriPortId tsiPortId,
ITriAddressList sutAddresses, ITriSignatureId signatureId,
ITriParameterList parameterList, ITriParameter returnValue);
// Ref: TRI-Definition 5.5.4.7
TriStatus TriRaise(ITriComponentId componentId, ITriPortId tsiPortId,
ITriAddress sutAddress, ITriSignatureId signatureId,
ITriException exc);
// Ref: TRI-Definition 5.5.4.8
TriStatus TriRaiseBC(ITriComponentId componentId, ITriPortId tsiPortId,
ITriSignatureId signatureId, ITriException exc);
// Ref: TRI-Definition 5.5.4.9
TriStatus TriRaiseMC(ITriComponentId componentId, ITriPortId tsiPortId,
ITriAddressList sutAddresses, ITriSignatureId signatureId,
ITriException exc);
// Miscellaneous operations
// Ref: TRI-Definition 5.5.5.1
TriStatus TriSutActionInformal(string description);
}
public interface ITriCommunicationTE
{
// Message based communication operations
// Ref: TRI-Definition 5.5.3.4
void EnqueueMessage(ITriPortId tsiPortId, ITriAddress sutAddress,
ITriComponentId componentId, ITriMessage msg);
// Procedure based communication operations
// Ref: TRI-Definition 5.5.4.10
void EnqueueCall(ITriPortId tsiPortId, ITriAddress sutAddress,
ITriComponentId componentId, ITriSignatureId signatureId,
ITriParameterList parameterList);
// Ref: TRI-Definition 5.5.4.10
void EnqueueReply(ITriPortId tsiPortId, ITriAddress sutAddress,
ITriComponentId componentId, ITriSignatureId signatureId,
ITriParameterList parameterList, ITriParameter returnValue);
// Ref: TRI-Definition 5.5.4.11
void EnqueueException(ITriPortId tsiPortId, ITriAddress sutAddress,
ITriComponentId componentId, ITriSignatureId signatureId,
ITriException exc);
}
public interface ITriPlatformPA
{
// Ref: TRI-Definition 5.6.1
TriStatus TriPAReset();
// Timer handling operations
// Ref: TRI-Definition 5.6.2.1
TriStatus TriStartTimer(ITriTimerId timerId, ITriTimerDuration duration);
// Ref: TRI-Definition 5.6.2.2
TriStatus TriStopTimer(ITriTimerId timerId);
// Ref: TRI-Definition 5.6.2.3
TriStatus TriReadTimer(ITriTimerId timerId,
ITriTimerDuration elapsedTime);
// Ref: TRI-Definition 5.6.2.4
TriStatus TriTimerRunning(ITriTimerId timerId, ITriBoolean running);
// Miscellaneous operations
// Ref: TRI-Definition 5.6.3.1
TriStatus TriExternalFunction(ITriFunctionId functionId,
ITriParameterList parameterList, ITriParameter returnValue);
}
public interface ITriPlatformTE
{
// Ref: TRI-Definition 5.6.2.5
void TriTimeout(ITriTimerId timerId);
}
}