// Attached: Lab_9
// ===========================================================
// File: Lab9_Combined.cpp
// ===========================================================
// Programmer: Elaine Torrez
// Class: CMPR 121
// ===========================================================

#include <iostream>
#include <string>
using namespace std;

// ===========================================================
// Abstract Base Class: Art
// ===========================================================
class Art
{
protected:
    string id;
    string title;
    string artist;
    string genre;
    int year;
    double price;

public:
    Art(string i, string t, string a, string g, int y, double p)
    {
        id = i;
        title = t;
        artist = a;
        genre = g;
        year = y;
        price = p;
    }

    virtual ~Art()
    {
    }

    virtual void showArt() = 0;
};

// ===========================================================
// Derived Class: Painting
// ===========================================================
class Painting : public Art
{
private:
    string paintMedium;

public:
    Painting(string i, string t, string a, string g, int y, double p, string pm)
        : Art(i, t, a, g, y, p)
    {
        paintMedium = pm;
    }

    ~Painting()
    {
    }

    void showArt()
    {
        cout << "ID: " << id << endl;
        cout << "Title: " << title << endl;
        cout << "Artist: " << artist << endl;
        cout << "Paint Medium: " << paintMedium << endl;
        cout << "Genre: " << genre << endl;
        cout << "Year: " << year << endl;
        cout << "Price: $" << price << endl;
    }
};

// ===========================================================
// Derived Class: Sculpture
// ===========================================================
class Sculpture : public Art
{
private:
    string material;

public:
    Sculpture(string i, string t, string a, string g, int y, double p, string m)
        : Art(i, t, a, g, y, p)
    {
        material = m;
    }

    ~Sculpture()
    {
    }

    void showArt()
    {
        cout << "ID: " << id << endl;
        cout << "Title: " << title << endl;
        cout << "Artist: " << artist << endl;
        cout << "Material: " << material << endl;
        cout << "Genre: " << genre << endl;
        cout << "Year: " << year << endl;
        cout << "Price: $" << price << endl;
    }
};

// ===========================================================
// Function Prototype
// ===========================================================
void displayArt(Art &art);

// ===========================================================
// displayArt Function
// ===========================================================
void displayArt(Art &art)
{
    art.showArt();
}

// ===========================================================
// main
// ===========================================================
int main()
{
    Painting a1("12345", "The Kiss", "Gustav Klimt", "Symbolist", 1908, 2500, "Oil");
    Sculpture a2("54321", "The Thinker", "Rodin", "Impressionism", 1880, 2000, "Bronze");

    cout << "==========================" << endl;
    displayArt(a1);
    displayArt(a2);
    cout << "=====================================" << endl;

    return 0;
}