/*
 *  ITnMapAnnotationProxy.h
 *  OpenGL Map Engine
 */

#ifndef ITN_MAP_ANNOTATION_PROXY_H
#define ITN_MAP_ANNOTATION_PROXY_H

#include "foundation/SharedPtr.h"

#include "TnMapAnnotationData.h"



/*! Client implements this. This is how they are informed about
 *  requests for map annotation data from the engine. */


class ITnMapAnnotationProxy
{
protected:

    virtual ~ITnMapAnnotationProxy() = 0;

public:
    
    typedef Tn::Foundation::shared_ptr<ITnMapAnnotationProxy> ptr;

    /*! Engine calls this to request tile annotation data. The client should
     *  store the weak pointer and return immediately. When the annotation
     *  data is available, the client should cast the
     *  TnMapAnnotationDataWeakPtr to TnMapAnnotationDataPtr, check for validity,
     *  and pass in the annotation data.
     */

    virtual void RequestTile(TnMapAnnotationData::ptr const & data) = 0;

    virtual void CancelRequest(TnMapAnnotationData::ptr const & data) = 0;
};

#endif
