//
//  EXPModelObject.h
//  Expression
//
//  Created by ashley on 15/11/2008.
//  Copyright 2008 __MyCompanyName__. All rights reserved.
//

#import <Cocoa/Cocoa.h>

@class PLTMatrix;

@interface EXPModelObject : NSObject {
	NSMutableArray *_objects;
	NSMutableSet *_selection;
	
	NSMutableArray *_tables;
	
	NSMutableDictionary *_defaults;
	PLTMatrix *_matrix;
	
	NSString *_name;
	NSString *_integrator;
	BOOL _fixedStep;

	NSMutableDictionary *_options;
	
	id _doc;
	
/*	int _nextNewStock;
	int _nextNewFlow;
	int _nextNewAuxiliary;
	int _nextNewParameter;*/
	NSMutableDictionary *_nextComponentNumbers;

	BOOL _drawGrid;
}

// - (id) initWithData:(NSData *)data;

- (BOOL) loadData:(NSData *)data;
- (id) XMLRepresentation;

- (void) setName:(id)name;
- (id) name;
- (void) setIntegrator:(id)integrator;
- (id) integrator;
- (void) setFixedStep:(BOOL)fixedStep;
- (BOOL) fixedStep;
- (void) setObjects:(id)objects;
- (id) objects;
- (void) setSelection:(id)selection;
- (id) selection;
- (void) setTables:(id)tables;
- (id) tables;

- (id) defaults;
- (id) textAttributes;

- (void) deleteComponents:(id)components;

- (void) setNameForNewComponent:(id)component;

- (int) lineStyleForLine:(int)line;
- (float) lineThicknessForLine:(int)line;
- (int) markerStyleForLine:(int)line;
- (NSColor *) lineColourForLine:(int)line;
- (NSColor *) markerColourForLine:(int)line;
- (float) markerSizeForLine:(int)line;

- (void) setDocument:(id)document;
- (id) document;
- (id) option:(NSString *)name;
- (void) setOption:(id)value forName:(NSString *)name;

- (void) setOutputMatrix:(id)matrix;
- (id) matrix;

- (void) dump;

- (void) setDoesDrawGrid:(BOOL)drawGrid;
- (BOOL) doesDrawGrid;

- (NSRect) drawingBounds;

- (void) drawInView:(id)view;

@end