/*
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
* Common Development and Distribution License, Version 1.0 only
* (the "License"). You may not use this file except in compliance
* with the License.
*
* You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
* See the License for the specific language governing permissions
* and limitations under the License.
*
* When distributing Covered Code, include this CDDL HEADER in each
* file and include the License file at usr/src/OPENSOLARIS.LICENSE.
* If applicable, add the following below this CDDL HEADER, with the
* fields enclosed by brackets "[]" replaced with your own identifying
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
*/
/*
*
* Copyright (c) 1988-1992 Sun Microsystems Inc
* All Rights Reserved.
*/
#pragma ident "%Z%%M% %I% %E% SMI"
#include <stdio.h>
#include "db_headers.h"
#include "db_log_entry.h"
#include "db_table.h"
/*
* Constructor: Create a log entry using the given parameters. Note that
* pointers to db_query and entry_object are simply assigned, not copied.
*/
{
action = a;
query = q;
}
{
/* we might not have allocated these ourselves, so we cannot delete them */
// if (query) delete query;
// if (object) free_entry(object);
}
/* prints a line from the journal */
void
{
switch (action) {
case DB_ADD:
printf("add: ");
break;
case DB_REMOVE:
printf("remove: ");
break;
default:
break;
}
putchar(' ');
else
printf("no query!\n");
print_entry(0, object);
} else {
printf("no object\n");
}
putchar('\n');
}