#include <pslib.h>
#include <ippdb.h>
#include <stdlib.h>

int main ()
{
    {
        psDB            *dbh;
        weatherRow      *object;

        dbh = psDBInit("localhost", "test", NULL, "test");
        if (!dbh) {
            exit(EXIT_FAILURE);
        }

        object = weatherRowAlloc(32.32, 32.32, 32.32, 32.32, 32.32, 32.32, 32.32);
        if (!object) {
            exit(EXIT_FAILURE);
        }

        if (!weatherInsertObject(dbh, object)) {
            exit(EXIT_FAILURE);
        }

        psFree(object);
        psDBCleanup(dbh);
    }

    {
        psDB            *dbh;
        skyp_transparencyRow *object;

        dbh = psDBInit("localhost", "test", NULL, "test");
        if (!dbh) {
            exit(EXIT_FAILURE);
        }

        object = skyp_transparencyRowAlloc("a string", 64.64, -32, 64.64, 64.64, 32.32, 64.64);
        if (!object) {
            exit(EXIT_FAILURE);
        }

        if (!skyp_transparencyInsertObject(dbh, object)) {
            exit(EXIT_FAILURE);
        }

        psFree(object);
        psDBCleanup(dbh);
    }

    {
        psDB            *dbh;
        skyp_absorptionRow *object;

        dbh = psDBInit("localhost", "test", NULL, "test");
        if (!dbh) {
            exit(EXIT_FAILURE);
        }

        object = skyp_absorptionRowAlloc("a string", 32.32, 32.32, 32.32, -32, 64.64, 64.64, 32.32, 64.64);
        if (!object) {
            exit(EXIT_FAILURE);
        }

        if (!skyp_absorptionInsertObject(dbh, object)) {
            exit(EXIT_FAILURE);
        }

        psFree(object);
        psDBCleanup(dbh);
    }

    {
        psDB            *dbh;
        skyp_emissionRow *object;

        dbh = psDBInit("localhost", "test", NULL, "test");
        if (!dbh) {
            exit(EXIT_FAILURE);
        }

        object = skyp_emissionRowAlloc("a string", 32.32, 32.32, 32.32, 32.32, 32.32);
        if (!object) {
            exit(EXIT_FAILURE);
        }

        if (!skyp_emissionInsertObject(dbh, object)) {
            exit(EXIT_FAILURE);
        }

        psFree(object);
        psDBCleanup(dbh);
    }

    {
        psDB            *dbh;
        dimmRow         *object;

        dbh = psDBInit("localhost", "test", NULL, "test");
        if (!dbh) {
            exit(EXIT_FAILURE);
        }

        object = dimmRowAlloc(32.32, 32.32, 32.32, 64.64, 64.64, 32.32, "a string");
        if (!object) {
            exit(EXIT_FAILURE);
        }

        if (!dimmInsertObject(dbh, object)) {
            exit(EXIT_FAILURE);
        }

        psFree(object);
        psDBCleanup(dbh);
    }

    {
        psDB            *dbh;
        skyp_irRow      *object;

        dbh = psDBInit("localhost", "test", NULL, "test");
        if (!dbh) {
            exit(EXIT_FAILURE);
        }

        object = skyp_irRowAlloc(64.64, 64.64, 64.64, 64.64, 32.32, 32.32);
        if (!object) {
            exit(EXIT_FAILURE);
        }

        if (!skyp_irInsertObject(dbh, object)) {
            exit(EXIT_FAILURE);
        }

        psFree(object);
        psDBCleanup(dbh);
    }

    {
        psDB            *dbh;
        domeRow         *object;

        dbh = psDBInit("localhost", "test", NULL, "test");
        if (!dbh) {
            exit(EXIT_FAILURE);
        }

        object = domeRowAlloc(32.32, true, true, true);
        if (!object) {
            exit(EXIT_FAILURE);
        }

        if (!domeInsertObject(dbh, object)) {
            exit(EXIT_FAILURE);
        }

        psFree(object);
        psDBCleanup(dbh);
    }

    {
        psDB            *dbh;
        telescopeRow    *object;

        dbh = psDBInit("localhost", "test", NULL, "test");
        if (!dbh) {
            exit(EXIT_FAILURE);
        }

        object = telescopeRowAlloc("a string", 32.32, 32.32, 64.64, 64.64);
        if (!object) {
            exit(EXIT_FAILURE);
        }

        if (!telescopeInsertObject(dbh, object)) {
            exit(EXIT_FAILURE);
        }

        psFree(object);
        psDBCleanup(dbh);
    }

    {
        psDB            *dbh;
        summitExpRow    *object;

        dbh = psDBInit("localhost", "test", NULL, "test");
        if (!dbh) {
            exit(EXIT_FAILURE);
        }

        object = summitExpRowAlloc("a string", "a string", "a string", "a string", "a string");
        if (!object) {
            exit(EXIT_FAILURE);
        }

        if (!summitExpInsertObject(dbh, object)) {
            exit(EXIT_FAILURE);
        }

        psFree(object);
        psDBCleanup(dbh);
    }

    {
        psDB            *dbh;
        pzPendingExpRow *object;

        dbh = psDBInit("localhost", "test", NULL, "test");
        if (!dbh) {
            exit(EXIT_FAILURE);
        }

        object = pzPendingExpRowAlloc("a string", "a string", "a string", "a string", -32);
        if (!object) {
            exit(EXIT_FAILURE);
        }

        if (!pzPendingExpInsertObject(dbh, object)) {
            exit(EXIT_FAILURE);
        }

        psFree(object);
        psDBCleanup(dbh);
    }

    {
        psDB            *dbh;
        pzPendingImfileRow *object;

        dbh = psDBInit("localhost", "test", NULL, "test");
        if (!dbh) {
            exit(EXIT_FAILURE);
        }

        object = pzPendingImfileRowAlloc("a string", -32, "a string", "a string", "a string", "a string");
        if (!object) {
            exit(EXIT_FAILURE);
        }

        if (!pzPendingImfileInsertObject(dbh, object)) {
            exit(EXIT_FAILURE);
        }

        psFree(object);
        psDBCleanup(dbh);
    }

    {
        psDB            *dbh;
        newExpRow       *object;

        dbh = psDBInit("localhost", "test", NULL, "test");
        if (!dbh) {
            exit(EXIT_FAILURE);
        }

        object = newExpRowAlloc("a string", "a string", "a string", "a string", -32);
        if (!object) {
            exit(EXIT_FAILURE);
        }

        if (!newExpInsertObject(dbh, object)) {
            exit(EXIT_FAILURE);
        }

        psFree(object);
        psDBCleanup(dbh);
    }

    {
        psDB            *dbh;
        newImfileRow    *object;

        dbh = psDBInit("localhost", "test", NULL, "test");
        if (!dbh) {
            exit(EXIT_FAILURE);
        }

        object = newImfileRowAlloc("a string", "a string", "a string", "a string");
        if (!object) {
            exit(EXIT_FAILURE);
        }

        if (!newImfileInsertObject(dbh, object)) {
            exit(EXIT_FAILURE);
        }

        psFree(object);
        psDBCleanup(dbh);
    }

    {
        psDB            *dbh;
        rawDetrendExpRow *object;

        dbh = psDBInit("localhost", "test", NULL, "test");
        if (!dbh) {
            exit(EXIT_FAILURE);
        }

        object = rawDetrendExpRowAlloc("a string", "a string", "a string", "a string", -32, "a string", "a string");
        if (!object) {
            exit(EXIT_FAILURE);
        }

        if (!rawDetrendExpInsertObject(dbh, object)) {
            exit(EXIT_FAILURE);
        }

        psFree(object);
        psDBCleanup(dbh);
    }

    {
        psDB            *dbh;
        rawScienceExpRow *object;

        dbh = psDBInit("localhost", "test", NULL, "test");
        if (!dbh) {
            exit(EXIT_FAILURE);
        }

        object = rawScienceExpRowAlloc("a string", "a string", "a string", "a string", -32, "a string", "a string");
        if (!object) {
            exit(EXIT_FAILURE);
        }

        if (!rawScienceExpInsertObject(dbh, object)) {
            exit(EXIT_FAILURE);
        }

        psFree(object);
        psDBCleanup(dbh);
    }

    {
        psDB            *dbh;
        rawImfileRow    *object;

        dbh = psDBInit("localhost", "test", NULL, "test");
        if (!dbh) {
            exit(EXIT_FAILURE);
        }

        object = rawImfileRowAlloc("a string", "a string", "a string", "a string");
        if (!object) {
            exit(EXIT_FAILURE);
        }

        if (!rawImfileInsertObject(dbh, object)) {
            exit(EXIT_FAILURE);
        }

        psFree(object);
        psDBCleanup(dbh);
    }

    {
        psDB            *dbh;
        p1PendingExpRow *object;

        dbh = psDBInit("localhost", "test", NULL, "test");
        if (!dbh) {
            exit(EXIT_FAILURE);
        }

        object = p1PendingExpRowAlloc("a string", "a string", "a string", "a string", -32, "a string", "a string", "a string", -32);
        if (!object) {
            exit(EXIT_FAILURE);
        }

        if (!p1PendingExpInsertObject(dbh, object)) {
            exit(EXIT_FAILURE);
        }

        psFree(object);
        psDBCleanup(dbh);
    }

    {
        psDB            *dbh;
        p2PendingExpRow *object;

        dbh = psDBInit("localhost", "test", NULL, "test");
        if (!dbh) {
            exit(EXIT_FAILURE);
        }

        object = p2PendingExpRowAlloc("a string", "a string", "a string", "a string", -32, "a string", "a string", "a string", -32, -32);
        if (!object) {
            exit(EXIT_FAILURE);
        }

        if (!p2PendingExpInsertObject(dbh, object)) {
            exit(EXIT_FAILURE);
        }

        psFree(object);
        psDBCleanup(dbh);
    }

    {
        psDB            *dbh;
        p2PendingImfileRow *object;

        dbh = psDBInit("localhost", "test", NULL, "test");
        if (!dbh) {
            exit(EXIT_FAILURE);
        }

        object = p2PendingImfileRowAlloc("a string", "a string", "a string", "a string", "a string", -32, -32);
        if (!object) {
            exit(EXIT_FAILURE);
        }

        if (!p2PendingImfileInsertObject(dbh, object)) {
            exit(EXIT_FAILURE);
        }

        psFree(object);
        psDBCleanup(dbh);
    }

    {
        psDB            *dbh;
        p2DoneExpRow    *object;

        dbh = psDBInit("localhost", "test", NULL, "test");
        if (!dbh) {
            exit(EXIT_FAILURE);
        }

        object = p2DoneExpRowAlloc("a string", "a string", "a string", "a string", -32, "a string", "a string", "a string", -32, -32);
        if (!object) {
            exit(EXIT_FAILURE);
        }

        if (!p2DoneExpInsertObject(dbh, object)) {
            exit(EXIT_FAILURE);
        }

        psFree(object);
        psDBCleanup(dbh);
    }

    {
        psDB            *dbh;
        p2DoneImfileRow *object;

        dbh = psDBInit("localhost", "test", NULL, "test");
        if (!dbh) {
            exit(EXIT_FAILURE);
        }

        object = p2DoneImfileRowAlloc("a string", "a string", "a string", "a string", "a string", -32, -32);
        if (!object) {
            exit(EXIT_FAILURE);
        }

        if (!p2DoneImfileInsertObject(dbh, object)) {
            exit(EXIT_FAILURE);
        }

        psFree(object);
        psDBCleanup(dbh);
    }

    {
        psDB            *dbh;
        p3PendingExpRow *object;

        dbh = psDBInit("localhost", "test", NULL, "test");
        if (!dbh) {
            exit(EXIT_FAILURE);
        }

        object = p3PendingExpRowAlloc("a string", "a string", "a string", -32, "a string", "a string", "a string", -32, -32);
        if (!object) {
            exit(EXIT_FAILURE);
        }

        if (!p3PendingExpInsertObject(dbh, object)) {
            exit(EXIT_FAILURE);
        }

        psFree(object);
        psDBCleanup(dbh);
    }

    {
        psDB            *dbh;
        detRunRow       *object;

        dbh = psDBInit("localhost", "test", NULL, "test");
        if (!dbh) {
            exit(EXIT_FAILURE);
        }

        object = detRunRowAlloc("a string");
        if (!object) {
            exit(EXIT_FAILURE);
        }

        if (!detRunInsertObject(dbh, object)) {
            exit(EXIT_FAILURE);
        }

        psFree(object);
        psDBCleanup(dbh);
    }

    {
        psDB            *dbh;
        detInputExpRow  *object;

        dbh = psDBInit("localhost", "test", NULL, "test");
        if (!dbh) {
            exit(EXIT_FAILURE);
        }

        object = detInputExpRowAlloc(-32, -32, "a string", "a string", "a string", "a string", -32, "a string", "a string");
        if (!object) {
            exit(EXIT_FAILURE);
        }

        if (!detInputExpInsertObject(dbh, object)) {
            exit(EXIT_FAILURE);
        }

        psFree(object);
        psDBCleanup(dbh);
    }

    {
        psDB            *dbh;
        detProcessedImfileRow *object;

        dbh = psDBInit("localhost", "test", NULL, "test");
        if (!dbh) {
            exit(EXIT_FAILURE);
        }

        object = detProcessedImfileRowAlloc(-32, "a string", "a string", "a string", "a string", "a string");
        if (!object) {
            exit(EXIT_FAILURE);
        }

        if (!detProcessedImfileInsertObject(dbh, object)) {
            exit(EXIT_FAILURE);
        }

        psFree(object);
        psDBCleanup(dbh);
    }

    {
        psDB            *dbh;
        detStackedImfileRow *object;

        dbh = psDBInit("localhost", "test", NULL, "test");
        if (!dbh) {
            exit(EXIT_FAILURE);
        }

        object = detStackedImfileRowAlloc(-32, -32, "a string", "a string", "a string", "a string");
        if (!object) {
            exit(EXIT_FAILURE);
        }

        if (!detStackedImfileInsertObject(dbh, object)) {
            exit(EXIT_FAILURE);
        }

        psFree(object);
        psDBCleanup(dbh);
    }

    {
        psDB            *dbh;
        detNormalizedImfileRow *object;

        dbh = psDBInit("localhost", "test", NULL, "test");
        if (!dbh) {
            exit(EXIT_FAILURE);
        }

        object = detNormalizedImfileRowAlloc(-32, -32, "a string", "a string", "a string", "a string");
        if (!object) {
            exit(EXIT_FAILURE);
        }

        if (!detNormalizedImfileInsertObject(dbh, object)) {
            exit(EXIT_FAILURE);
        }

        psFree(object);
        psDBCleanup(dbh);
    }

    {
        psDB            *dbh;
        detMasterFrameRow *object;

        dbh = psDBInit("localhost", "test", NULL, "test");
        if (!dbh) {
            exit(EXIT_FAILURE);
        }

        object = detMasterFrameRowAlloc(-32, -32, "a string");
        if (!object) {
            exit(EXIT_FAILURE);
        }

        if (!detMasterFrameInsertObject(dbh, object)) {
            exit(EXIT_FAILURE);
        }

        psFree(object);
        psDBCleanup(dbh);
    }

    {
        psDB            *dbh;
        detMasterImfileRow *object;

        dbh = psDBInit("localhost", "test", NULL, "test");
        if (!dbh) {
            exit(EXIT_FAILURE);
        }

        object = detMasterImfileRowAlloc(-32, "a string", "a string", "a string", "a string");
        if (!object) {
            exit(EXIT_FAILURE);
        }

        if (!detMasterImfileInsertObject(dbh, object)) {
            exit(EXIT_FAILURE);
        }

        psFree(object);
        psDBCleanup(dbh);
    }

    {
        psDB            *dbh;
        detResidImfileAnalysisRow *object;

        dbh = psDBInit("localhost", "test", NULL, "test");
        if (!dbh) {
            exit(EXIT_FAILURE);
        }

        object = detResidImfileAnalysisRowAlloc(-32, -32, "a string", "a string", "a string", "a string");
        if (!object) {
            exit(EXIT_FAILURE);
        }

        if (!detResidImfileAnalysisInsertObject(dbh, object)) {
            exit(EXIT_FAILURE);
        }

        psFree(object);
        psDBCleanup(dbh);
    }

    {
        psDB            *dbh;
        detResidExpAnalysisRow *object;

        dbh = psDBInit("localhost", "test", NULL, "test");
        if (!dbh) {
            exit(EXIT_FAILURE);
        }

        object = detResidExpAnalysisRowAlloc(-32, -32, "a string", "a string", "a string", true);
        if (!object) {
            exit(EXIT_FAILURE);
        }

        if (!detResidExpAnalysisInsertObject(dbh, object)) {
            exit(EXIT_FAILURE);
        }

        psFree(object);
        psDBCleanup(dbh);
    }

    exit(EXIT_SUCCESS);
}
