Y2YCPFunction Class Reference

#include <YExpression.h>

Inheritance diagram for Y2YCPFunction:

Y2Function

List of all members.

Public Member Functions

 Y2YCPFunction (YSymbolEntryPtr entry)
 ~Y2YCPFunction ()
string qualifiedName () const
string name () const
virtual bool attachParameter (const YCPValue &arg, const int pos)
virtual constTypePtr wantedParameterType () const
virtual bool appendParameter (const YCPValue &arg)
virtual bool finishParameters ()
virtual YCPValue evaluateCall ()
virtual bool reset ()

Private Attributes

YSymbolEntryPtr m_sentry
YCPValuem_parameters


Constructor & Destructor Documentation

Y2YCPFunction::Y2YCPFunction ( YSymbolEntryPtr  entry  ) 

References m_parameters, m_sentry, and y2debug.

Y2YCPFunction::~Y2YCPFunction (  ) 

References m_parameters.


Member Function Documentation

bool Y2YCPFunction::appendParameter ( const YCPValue arg  )  [virtual]

Appends a parameter to the call.

Returns:
false if there was a type mismatch

Implements Y2Function.

References YCPElement::isNull(), m_parameters, m_sentry, qualifiedName(), y2debug, and ycp2error.

bool Y2YCPFunction::attachParameter ( const YCPValue arg,
const int  position 
) [virtual]

Attaches a parameter to a given position to the call.

Returns:
false if there was a type mismatch

Implements Y2Function.

References m_parameters, m_sentry, and y2error.

YCPValue Y2YCPFunction::evaluateCall (  )  [virtual]

bool Y2YCPFunction::finishParameters (  )  [virtual]

Signal that we're done adding parameters.

Returns:
false if there was a parameter missing

Implements Y2Function.

References m_parameters, m_sentry, qualifiedName(), and y2error.

string Y2YCPFunction::name (  )  const [virtual]

Implements Y2Function.

References m_sentry.

string Y2YCPFunction::qualifiedName (  )  const

References m_sentry.

Referenced by appendParameter(), and finishParameters().

bool Y2YCPFunction::reset (  )  [virtual]

Reset the currecn parameters, so the instance can be reused for the next call (appendParameter etc)

Implements Y2Function.

References m_parameters, and m_sentry.

constTypePtr Y2YCPFunction::wantedParameterType (  )  const [virtual]

What type is expected for the next appendParameter (val) ? (Used when calling from Perl, to be able to convert from the simple type system of Perl to the elaborate type system of YCP)

Returns:
Type::Any if number of parameters exceeded

Implements Y2Function.

References Type::Any, m_parameters, m_sentry, Type::Unspec, and YCode::ycFunction.


Member Data Documentation

YSymbolEntryPtr Y2YCPFunction::m_sentry [private]


The documentation for this class was generated from the following files:

Generated on a sunny day for yast2-core by doxygen 1.5.9