//
//  MFMdnTextField.h
//  myverizon
//
//  Created by ShaunH on 2/23/15.
//  Copyright (c) 2015 Verizon Wireless. All rights reserved.
//

#import <UIKit/UIKit.h>
#import <AddressBookUI/AddressBookUI.h>
#import <ContactsUI/ContactsUI.h>
#import <MVMCoreUI/MFTextField.h>

@interface MFMdnTextField : MFTextField <UITextFieldDelegate, ABPeoplePickerNavigationControllerDelegate, CNContactPickerDelegate>

@property (nullable, nonatomic, weak) IBOutlet id<UITextFieldDelegate> customDelegate;
@property (nonatomic) BOOL isNationalMdn;
@property (nonatomic) BOOL shouldValidateMDN;

- (void)setupTextfield;

// valid if 0 or correct national or international mdn size+character
- (BOOL)hasValidMdn;

// return hasValidMdn and color text accordingly
- (BOOL)validateAndColor;

// return customiz error message
- (nullable NSString *)getErrorMessage;

// return unformated mdn
- (nullable NSString *)getMdn;

// format mdn and set to self.text
- (void)setMdn:(nullable NSString *)mdn;

@end
