BarrierOption Class Reference
[Financial instruments]

#include <ql/instruments/barrieroption.hpp>

Inheritance diagram for BarrierOption:

List of all members.


Detailed Description

Barrier option on a single asset.

The analytic pricing engine will be used if none if passed.

Examples:

Replication.cpp.


Public Member Functions

 BarrierOption (Barrier::Type barrierType, Real barrier, Real rebate, const boost::shared_ptr< StrikedTypePayoff > &payoff, const boost::shared_ptr< Exercise > &exercise)
void setupArguments (PricingEngine::arguments *) const
Volatility impliedVolatility (Real price, const boost::shared_ptr< GeneralizedBlackScholesProcess > &process, Real accuracy=1.0e-4, Size maxEvaluations=100, Volatility minVol=1.0e-7, Volatility maxVol=4.0) const

Protected Attributes

Barrier::Type barrierType_
Real barrier_
Real rebate_

Classes

class  arguments
 Arguments for barrier option calculation More...
class  engine
 Barrier-option engine base class More...

Member Function Documentation

void setupArguments ( PricingEngine::arguments *   )  const [virtual]

When a derived argument structure is defined for an instrument, this method should be overridden to fill it. This is mandatory in case a pricing engine is used.

Reimplemented from Option.

Volatility impliedVolatility ( Real  price,
const boost::shared_ptr< GeneralizedBlackScholesProcess > &  process,
Real  accuracy = 1.0e-4,
Size  maxEvaluations = 100,
Volatility  minVol = 1.0e-7,
Volatility  maxVol = 4.0 
) const

Warning:
see VanillaOption for notes on implied-volatility calculation.