//
//  NSControl+CCHFieldEditor.h
//  Chikoo
//
//  Created by Shlok Datye on 17.04.2013.
//  Copyright (c) 2013 Coding Turtle. All rights reserved.
//

#import <Foundation/Foundation.h>


@interface NSControl (CCHFieldEditor)

//Obtains the control’s (self’s) object value, without performing
//any validation if there currently is a field editor on the control.
//Note: The returned *object could very well be nil if the formatter brings that about.
- (BOOL)objectValue:(id *)object takingIntoAccountFieldEditorWithError:(NSError **)error;

//Does nothing if there is no field editor.
//Does nothing if self’s formatter cannot convert the object to string (or if there is no formatter).
- (void)applyObjectValueToFieldEditor:(id)object;

@end
