1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1.2 +++ b/epoc32/include/authserver/authexpression.inl Wed Mar 31 12:33:34 2010 +0100
1.3 @@ -0,0 +1,85 @@
1.4 +/*
1.5 +* Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies).
1.6 +* All rights reserved.
1.7 +* This component and the accompanying materials are made available
1.8 +* under the terms of the License "Eclipse Public License v1.0"
1.9 +* which accompanies this distribution, and is available
1.10 +* at the URL "http://www.eclipse.org/legal/epl-v10.html".
1.11 +*
1.12 +* Initial Contributors:
1.13 +* Nokia Corporation - initial contribution.
1.14 +*
1.15 +* Contributors:
1.16 +*
1.17 +* Description:
1.18 +* @publishedAll
1.19 +* @released
1.20 +*
1.21 +*/
1.22 +
1.23 +
1.24 +#ifndef AUTHEXPRESSION_INL
1.25 +#define AUTHEXPRESSION_INL
1.26 +
1.27 +#include "authserver/authexpression.h"
1.28 +
1.29 +namespace AuthServer
1.30 +{
1.31 +
1.32 +
1.33 +// -------- TAuthExpressionWrapper --------
1.34 +
1.35 +
1.36 +inline TAuthExpressionWrapper::operator CAuthExpression*()
1.37 +/**
1.38 + Conversion operator recasts this object as a
1.39 + pointer to the contained authorisation expression.
1.40 + */
1.41 + {
1.42 + return iPtr;
1.43 + }
1.44 +
1.45 +
1.46 +#ifdef AUTH_EXPR_BINARY_OPS
1.47 +
1.48 +
1.49 +inline TAuthExpressionWrapper operator&(TAuthExpressionWrapper aLeft, TAuthExpressionWrapper aRight)
1.50 +/**
1.51 + This overloaded operator is a wrapper around a call to AuthAnd.
1.52 + See AuthAnd for a full description.
1.53 +
1.54 + @param aLeft Left subexpression.
1.55 + @param aRight Right subexpression.
1.56 + @return Wrapper around new complex AND expression,
1.57 + which is NULL if could not allocate.
1.58 + @see AuthAnd
1.59 + */
1.60 + {
1.61 + return AuthAnd(aLeft, aRight);
1.62 + }
1.63 +
1.64 +
1.65 +inline TAuthExpressionWrapper operator|(TAuthExpressionWrapper aLeft, TAuthExpressionWrapper aRight)
1.66 +/**
1.67 + This overloaded operator is a wrapper around a call to AuthOr
1.68 + See AuthOr for a full description.
1.69 +
1.70 + @param aLeft Left subexpression.
1.71 + @param aRight Right subexpression.
1.72 + @return Wrapper around new complex OR expression,
1.73 + which is NULL if could not allocate.
1.74 + @see AuthOr
1.75 + */
1.76 + {
1.77 + return AuthOr(aLeft, aRight);
1.78 + }
1.79 +
1.80 +
1.81 +#endif // #ifdef AUTH_EXPR_BINARY_OPS
1.82 +
1.83 +
1.84 +} // namespace AuthServer
1.85 +
1.86 +
1.87 +#endif // AUTHEXPRESSION_INL
1.88 +