epoc32/include/es_sock.inl
author William Roberts <williamr@symbian.org>
Wed, 31 Mar 2010 12:27:01 +0100 (2010-03-31)
branchSymbian2
changeset 3 e1b950c65cb4
parent 0 061f57f2323e
permissions -rw-r--r--
Attempt to represent the S^2->S^3 header reorganisation as a series of "hg rename" operations
williamr@2
     1
// Copyright (c) 1997-2009 Nokia Corporation and/or its subsidiary(-ies).
williamr@2
     2
// All rights reserved.
williamr@2
     3
// This component and the accompanying materials are made available
williamr@2
     4
// under the terms of the License "Symbian Foundation License v1.0" to Symbian Foundation members and "Symbian Foundation End User License Agreement v1.0" to non-members
williamr@2
     5
// which accompanies this distribution, and is available
williamr@2
     6
// at the URL "http://www.symbianfoundation.org/legal/licencesv10.html".
williamr@2
     7
//
williamr@2
     8
// Initial Contributors:
williamr@2
     9
// Nokia Corporation - initial contribution.
williamr@2
    10
//
williamr@2
    11
// Contributors:
williamr@2
    12
//
williamr@2
    13
// Description:
williamr@2
    14
//
williamr@2
    15
williamr@2
    16
inline TSockIOBufC::TSockIOBufC()	: TPckgC<TSockIO>(iArgs)
williamr@2
    17
williamr@2
    18
	{}
williamr@2
    19
williamr@2
    20
inline TSockOpenBufC::TSockOpenBufC()	: TPckgC<TSockOpen>(iArgs)
williamr@2
    21
williamr@2
    22
	{}
williamr@2
    23
williamr@2
    24
inline SSockAddr *TSockAddr::BasePtr() const
williamr@2
    25
/**
williamr@2
    26
This function returns the end point to a connection.
williamr@2
    27
williamr@2
    28
@return socket address
williamr@2
    29
*/
williamr@2
    30
	{ return (SSockAddr*)iBuf; }
williamr@2
    31
williamr@2
    32
williamr@2
    33
inline TUint8 *TSockAddr::UserPtr() const
williamr@2
    34
/** Gets an offset to place data after the base class data. This function is mainly 
williamr@2
    35
intended for use in derived classes.
williamr@2
    36
@return Pointer to derived class intended data area */
williamr@2
    37
	{ return (TUint8*)(BasePtr()+1); }
williamr@2
    38
williamr@2
    39
inline TUint16 ByteOrder::Swap16(TUint aVal)
williamr@2
    40
/** 
williamr@2
    41
Reverses the order of the bytes in a 16-bit value.
williamr@2
    42
	
williamr@2
    43
@param aVal The value to reverse. 
williamr@2
    44
@return The reversed value. 
williamr@2
    45
*/
williamr@2
    46
	{ return ByteOrder::Swap16((TUint16)aVal); }
williamr@2
    47
williamr@2
    48
inline TNameRecord::TNameRecord()
williamr@2
    49
	:iName(),iAddr(),iFlags(0)	
williamr@2
    50
/** 
williamr@2
    51
Trivial C++ constructor. This sets the fields in the 
williamr@2
    52
class to suitable default values. 
williamr@2
    53
*/
williamr@2
    54
	{}
williamr@2
    55
williamr@2
    56
inline TNifProgress::TNifProgress()	:iStage(0), iError(KErrNone) 
williamr@2
    57
/**
williamr@2
    58
It sets the iStage data member to 0 and the iError data member to KErrNone.
williamr@2
    59
*/
williamr@2
    60
	{}
williamr@2
    61
williamr@2
    62
inline RSubConnection::TEventFilter::TEventFilter(TInt32 aEventGroupId, TUint32 aEventMask)
williamr@2
    63
	: iEventGroupUid(aEventGroupId), iEventMask(aEventMask)
williamr@2
    64
	{
williamr@2
    65
	}
williamr@2
    66
williamr@2
    67
inline TUint32 CSubConParameterFamily::Id()
williamr@2
    68
/**
williamr@2
    69
Fetch the identity of the sub-connection parameter family
williamr@2
    70
*/
williamr@2
    71
	{
williamr@2
    72
	return iFamilyId;
williamr@2
    73
	}
williamr@2
    74
williamr@2
    75
inline TAccessPointInfo::TAccessPointInfo(TUint aApId)
williamr@2
    76
/** Initialises the object using the specified 32-bit long integer ID of the access point.
williamr@2
    77
williamr@2
    78
@param aApId The 32-bit long integer ID of the access point to initialise the object with. */
williamr@2
    79
	{
williamr@2
    80
	iAccessPointId = aApId;
williamr@2
    81
	}
williamr@2
    82
williamr@2
    83
inline TUint TAccessPointInfo::AccessPoint() const
williamr@2
    84
/** Returns the 32-bit long integer ID of the access point.
williamr@2
    85
williamr@2
    86
@return The 32-bit long integer ID of the access point. */
williamr@2
    87
	{
williamr@2
    88
	return iAccessPointId;
williamr@2
    89
	}
williamr@2
    90
williamr@2
    91
inline void TAccessPointInfo::SetAccessPoint(TUint aAccessPoint)
williamr@2
    92
/** Sets the 32-bit long integer ID of the access point.
williamr@2
    93
williamr@2
    94
@param aAccessPoint The 32-bit long integer ID of the access point. */
williamr@2
    95
	{
williamr@2
    96
	iAccessPointId = aAccessPoint;
williamr@2
    97
	}
williamr@2
    98
	
williamr@2
    99
inline TBool TAccessPointInfo::operator== (const TAccessPointInfo& aRhs) const
williamr@2
   100
/** Compares the 32-bit long integer ID of the specified object with our own.
williamr@2
   101
williamr@2
   102
@param aRhs The TAccessPointInfo to compare.
williamr@2
   103
@return A boolean value of ETrue if the TAccessPointInfo object has the same ID or false otherwise. */
williamr@2
   104
	{
williamr@2
   105
	return iAccessPointId == aRhs.iAccessPointId;
williamr@2
   106
	}