wlanutilities/wlansniffer/wlaninfo/inc/wsfwlaninfo.inl
branchRCL_3
changeset 24 63be7eb3fc78
parent 23 b852595f5cbe
child 25 f28ada11abbf
equal deleted inserted replaced
23:b852595f5cbe 24:63be7eb3fc78
     1 /*
       
     2 * Copyright (c) 2007-2007 Nokia Corporation and/or its subsidiary(-ies). 
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description:  Inline for TWsfWlanInfo
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 
       
    20 //  INLINE FUNCTIONS
       
    21 
       
    22 // -----------------------------------------------------------------------------
       
    23 // TWsfWlanInfo::Connected
       
    24 // -----------------------------------------------------------------------------
       
    25 //
       
    26 inline TBool TWsfWlanInfo::Connected() const
       
    27 	{ 
       
    28 	return ( iConnectionState == EConnected ); 
       
    29 	}
       
    30 
       
    31 
       
    32 // -----------------------------------------------------------------------------
       
    33 // TWsfWlanInfo::ConnectionStatus
       
    34 // -----------------------------------------------------------------------------
       
    35 //
       
    36 inline TWsfWlanConnectionState TWsfWlanInfo::ConnectionStatus() const
       
    37     { 
       
    38     return iConnectionState; 
       
    39     }
       
    40 
       
    41 
       
    42 // -----------------------------------------------------------------------------
       
    43 // TWsfWlanInfo::Known
       
    44 // -----------------------------------------------------------------------------
       
    45 //
       
    46 inline TBool TWsfWlanInfo::Known() const
       
    47 	{ 
       
    48 	return ( iIapId );
       
    49 	}
       
    50 
       
    51 
       
    52 // -----------------------------------------------------------------------------
       
    53 // TWsfWlanInfo::Hidden
       
    54 // -----------------------------------------------------------------------------
       
    55 //
       
    56 inline TBool TWsfWlanInfo::Hidden() const
       
    57 	{ 
       
    58 	return !iVisibility;
       
    59 	}
       
    60 
       
    61 
       
    62 // -----------------------------------------------------------------------------
       
    63 // TWsfWlanInfo::Secure
       
    64 // -----------------------------------------------------------------------------
       
    65 //
       
    66 inline TBool TWsfWlanInfo::Secure() const
       
    67 	{ 
       
    68 	return ( iSecurityMode != CMManager::EWlanSecModeOpen );
       
    69 	}
       
    70 
       
    71 
       
    72 // -----------------------------------------------------------------------------
       
    73 // TWsfWlanInfo::SetBrand
       
    74 // -----------------------------------------------------------------------------
       
    75 //
       
    76 inline void TWsfWlanInfo::SetBrand( const TInt8 aBrandId ) 
       
    77 	{
       
    78 	iBrandId = aBrandId;
       
    79 	}
       
    80 	
       
    81 
       
    82 // -----------------------------------------------------------------------------
       
    83 // TWsfWlanInfo::BrandId
       
    84 // -----------------------------------------------------------------------------
       
    85 //
       
    86 inline TInt8 TWsfWlanInfo::BrandId() const
       
    87 	{
       
    88 	return iBrandId; 
       
    89 	}		
       
    90 	
       
    91 
       
    92 // -----------------------------------------------------------------------------
       
    93 // TWsfWlanInfo::SetBlackListEntry
       
    94 // -----------------------------------------------------------------------------
       
    95 //
       
    96 inline void TWsfWlanInfo::SetBlackListEntry( const TBool aBlackListEntry )
       
    97 	{
       
    98 	iFilterFlags = aBlackListEntry ? 
       
    99                         ( EBlackListItem | iFilterFlags ): 
       
   100                         ( ~EBlackListItem & iFilterFlags );
       
   101 	}
       
   102 	
       
   103 
       
   104 // -----------------------------------------------------------------------------
       
   105 // TWsfWlanInfo::BlackListEntry
       
   106 // -----------------------------------------------------------------------------
       
   107 //
       
   108 inline TBool TWsfWlanInfo::BlackListEntry() const
       
   109 	{
       
   110 	return ( iFilterFlags & EBlackListItem );
       
   111 	}	
       
   112 
       
   113 
       
   114 // -----------------------------------------------------------------------------
       
   115 // TWsfWlanInfo::FonSsid
       
   116 // -----------------------------------------------------------------------------
       
   117 //
       
   118 inline TBool TWsfWlanInfo::FonSsid() const
       
   119 	{
       
   120 	return ( iFilterFlags & EFonSsid );
       
   121 	}
       
   122 	
       
   123 
       
   124 // -----------------------------------------------------------------------------
       
   125 // TWsfWlanInfo::SetFonSsid
       
   126 // -----------------------------------------------------------------------------
       
   127 //
       
   128 inline void TWsfWlanInfo::SetFonSsid( const TBool aFonSsid )
       
   129 	{			
       
   130 	iFilterFlags = aFonSsid ? 
       
   131 	                    ( EFonSsid | iFilterFlags ): 
       
   132 	                    ( ~EFonSsid & iFilterFlags );			
       
   133 	}
       
   134 
       
   135 
       
   136 // -----------------------------------------------------------------------------
       
   137 // TWsfWlanInfo::UsesPreSharedKey
       
   138 // -----------------------------------------------------------------------------
       
   139 //
       
   140 inline TBool TWsfWlanInfo::UsesPreSharedKey() const
       
   141 	{
       
   142 	return ( iFilterFlags & EUsesPresharedKey );
       
   143 	}
       
   144 	
       
   145 
       
   146 // -----------------------------------------------------------------------------
       
   147 // TWsfWlanInfo::SetUsesPreSharedKey
       
   148 // -----------------------------------------------------------------------------
       
   149 //
       
   150 inline void TWsfWlanInfo::SetUsesPreSharedKey( const TBool aUsePresharedKey )
       
   151 	{			
       
   152 	iFilterFlags = aUsePresharedKey? 
       
   153 	                    ( EUsesPresharedKey | iFilterFlags ): 
       
   154 	                    ( ~EUsesPresharedKey & iFilterFlags );
       
   155 	}
       
   156 
       
   157 
       
   158 // -----------------------------------------------------------------------------
       
   159 // TWsfWlanInfo::SetPriority
       
   160 // -----------------------------------------------------------------------------
       
   161 //
       
   162 inline void TWsfWlanInfo::SetPriority( const TUint8 aPriority ) 
       
   163     {
       
   164     iPriority = aPriority;
       
   165     }
       
   166     
       
   167 
       
   168 // -----------------------------------------------------------------------------
       
   169 // TWsfWlanInfo::Priority
       
   170 // -----------------------------------------------------------------------------
       
   171 //
       
   172 inline TUint8 TWsfWlanInfo::Priority() const
       
   173     {
       
   174     return iPriority; 
       
   175     }
       
   176 
       
   177 // -----------------------------------------------------------------------------
       
   178 // TWsfWlanInfo::SecurityMode
       
   179 // -----------------------------------------------------------------------------
       
   180 //
       
   181 inline CMManager::TWlanSecMode TWsfWlanInfo::SecurityMode() const
       
   182     { 
       
   183     return iSecurityMode;
       
   184     }