This is MiscExporterPrivate.h in view mode; [Download] [Up]
#ifndef __MiscExporterPrivate_h #define __MiscExporterPrivate_h //============================================================================= // // Copyright (C) 1996 by Paul S. McCarthy and Eric Sunshine. // Written by Paul S. McCarthy and Eric Sunshine. // All Rights Reserved. // // This notice may not be removed from this source code. // // This object is included in the MiscKit by permission from the authors // and its use is governed by the MiscKit license, found in the file // "License.rtf" in the MiscKit distribution. Please refer to that file // for a list of all applicable permissions and restrictions. // //============================================================================= //----------------------------------------------------------------------------- // MiscExporterPrivate.h // // Private, internal communication and utility routines for the // MiscExporter class. // //----------------------------------------------------------------------------- //----------------------------------------------------------------------------- // $Id: MiscExporterPrivate.h,v 1.1 96/09/25 11:54:58 zarnuk Exp $ // $Log: MiscExporterPrivate.h,v $ // Revision 1.1 96/09/25 11:54:58 zarnuk // Internal communication methods for the MiscExporter class. // //----------------------------------------------------------------------------- #import <misckit/MiscExporter.h> #import <misckit/MiscTableScroll.h> extern "Objective-C" { #import <appkit/Cell.h> } extern "C" { #import <stdio.h> #import <string.h> } @interface MiscExporter(Private) - (int*) makeColMap:(int)ncols; - (int) rowTitleCharWidth:(int) nrows; @end @interface MiscExporter(ASCII) - (void) exportFixed:(FILE*)fp; - (void) exportTab:(FILE*)fp; - (void) exportDelimited:(FILE*)fp; @end @interface MiscExporter(DBF) - (void) exportDBF:(FILE*)fp; @end //----------------------------------------------------------------------------- // safe_strlen //----------------------------------------------------------------------------- inline static int safe_strlen( char const* s ) { return (s != 0 ? (int) strlen(s) : 0); } //----------------------------------------------------------------------------- // repchar //----------------------------------------------------------------------------- inline static void repchar( int rep, char c, FILE* fp ) { for (int i = 0; i < rep; i++) fputc( c, fp ); } //----------------------------------------------------------------------------- // pad //----------------------------------------------------------------------------- inline static void pad( int len, FILE* fp ) { repchar( len, ' ', fp ); } inline static int row_at( int visual_pos, id obj ) { return [obj rowAtPosition:visual_pos]; } inline static int col_at( int visual_pos, id obj ) { return [obj colAtPosition:visual_pos]; } inline static id cell_at( int r, int c, id obj ) { return [obj cellAt:r:c]; } inline static char const* str_at( int r, int c, id obj ) { return [obj stringValueAt:r:c]; } inline static char const* col_title( int c, id obj ) { return [obj colTitle:c]; } inline static char const* row_title( int r, id obj ) { return [obj rowTitle:r]; } #endif // __MiscExporterPrivate_h
These are the contents of the former NiCE NeXT User Group NeXTSTEP/OpenStep software archive, currently hosted by Netfuture.ch.