1 #pragma once 2 3 /* 4 * $Header: /home/tv/src/debugger/src/datadisp/tv_data_display.h,v 1.3 2010-04-21 15:32:50 tringali Exp $ 5 * $Locker: $ 6 7 Copyright (c) 2010, Rogue Wave Software, Inc. 8 9 Permission is hereby granted, free of charge, to any person obtaining a copy 10 of this software and associated documentation files (the "Software"), to deal 11 in the Software without restriction, including without limitation the rights 12 to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 13 copies of the Software, and to permit persons to whom the Software is 14 furnished to do so, subject to the following conditions: 15 16 The above copyright notice and this permission notice shall be included in 17 all copies or substantial portions of the Software. 18 19 THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 20 IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 21 FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 22 AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 23 LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 24 OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 25 THE SOFTWARE. 26 27 * Update log 28 * 29 * Sep 25 2009 SJT: Add idempotence header. 30 * Jul 1 2009 SJT: Created. 31 * 32 */ 33 34 #include <petscsys.h> 35 36 #if defined(__cplusplus) 37 extern "C" { 38 #endif 39 40 enum TV_format_result { 41 TV_format_OK, /* Type is known, and successfully converted */ 42 TV_format_failed, /* Type is known, but could not convert it */ 43 TV_format_raw, /* Just display it as a regular type for now */ 44 TV_format_never /* Don't know about this type, and please don't ask again */ 45 }; 46 47 #define TV_ascii_string_type "$string" 48 #define TV_int_type "$int" 49 50 PETSC_EXTERN int TV_add_row(const char *, const char *, const void *); 51 52 /* 53 0: Success 54 EPERM: Called with no active callback to TV_display_type 55 EINVAL: field_name or type_name has illegal characters 56 ENOMEM: No more room left for display data 57 */ 58 59 #if defined(__cplusplus) 60 } 61 #endif 62