1 /* 2 Project: Sudoku 3 Document.h 4 5 Copyright (C) 2007-2011 The Free Software Foundation, Inc 6 7 Author: Marko Riedel 8 9 This application is free software; you can redistribute it and/or 10 modify it under the terms of the GNU General Public 11 License as published by the Free Software Foundation; either 12 version 3 of the License, or (at your option) any later version. 13 14 This application is distributed in the hope that it will be useful, 15 but WITHOUT ANY WARRANTY; without even the implied warranty of 16 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 17 Library General Public License for more details. 18 19 You should have received a copy of the GNU General Public 20 License along with this library; if not, write to the Free 21 Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 22 */ 23 24 #import <Foundation/Foundation.h> 25 #import <AppKit/NSDocument.h> 26 #import <AppKit/NSWindowController.h> 27 28 @class Sudoku; 29 @class SudokuView; 30 31 #define DOCTYPE @"sudoku" 32 33 @interface Document : NSDocument 34 { 35 SudokuView *sdkview; 36 NSArray *lines; 37 } 38 39 - init; 40 41 - (NSData *)dataRepresentationOfType:(NSString *)aType; 42 - (BOOL)loadDataRepresentation:(NSData *)data ofType:(NSString *)aType; 43 44 - (void)makeWindowControllers; 45 - (void)windowControllerDidLoadNib:(NSWindowController *)aController; 46 47 - (Sudoku *)sudoku; 48 - (SudokuView *)sudokuView; 49 50 - resetPuzzle:(id)sender; 51 - solvePuzzle:(id)sender; 52 53 54 @end 55