/* --*-c++-*-- */
/* osgEarth - Dynamic map generation toolkit for OpenSceneGraph
 * Copyright 2008-2010 Pelican Mapping
 * http://osgearth.org
 *
 * osgEarth is free software; you can redistribute it and/or modify
 * it under the terms of the GNU Lesser General Public License as published by
 * the Free Software Foundation; either version 2 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public License
 * along with this program.  If not, see <http://www.gnu.org/licenses/>
 */

#ifndef OSGEARTHSYMBOLOGY_CONTENT_H
#define OSGEARTHSYMBOLOGY_CONTENT_H 1

#include <osgEarth/Revisioning>
#include <osgEarthSymbology/Common>
#include <osgEarthSymbology/Geometry>


namespace osgEarth { namespace Symbology
{
    /**
     * Base template for all Symbolizer content types.
     */
    template<typename CONTENT_TYPE>
    class Content : public osgEarth::Revisioned<CONTENT_TYPE> // header only (no export)
    {
        //empty
    };

    /**
     * Empty content object.
     */
    class NullContent : public Content<osg::Referenced>
    {
        //empty
    };
    
    /** 
     * Content object containing a simple text string.
     */
    class TextContent : public Content<osg::Referenced> // header only (no export)
    {
    public:
        TextContent() { }
        TextContent( const std::string& text ) : _text( text ) { }

        const std::string& getText() const { return _text; }

        void setText( const std::string& text ) { _text = text; }

    private:
        std::string _text;
    };

    /**
     * Basic content type for a geometry list.
     */
    class GeometryContent : public Content<osg::Referenced> // header-only (no export)
    {
    public:
        const GeometryList& getGeometryList() const { return _geometryList; }
        GeometryList& getGeometryList() { return _geometryList; }

    protected:
        GeometryList _geometryList;
    };

} } // namespace osgEarth::Symbology

#endif // OSGEARTHSYMBOLOGY_CONTENT_H
