/* -*- linux-c -*- * * (C) Copyright IBM Corp. 2005 * * 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. This * file and program are licensed under a BSD style license. See * the Copying file included with the OpenHPI distribution for * full licensing terms. * * Author(s): * W. David Ashley */ #include #include #include extern "C" { #include } #include "oSaHpiAlarm.hpp" int main(int argc, char *argv[]) { oSaHpiAlarm *ptr1; // create the first Alarm ptr1 = new oSaHpiAlarm; if (ptr1 == NULL) { printf("Error: Unable to create a oSaHpiAlarm.\n"); return -1; } // print the contents of the first Alarm fprintf(stdout, "\nSaHpiAlarm\n"); if (ptr1->fprint(stdout, 3)) { printf("Error: Unable to print the buffer.\n"); return -1; } fprintf(stdout, "\n"); printf("Success!\n"); return 0; }