//
//  JDViewController.h
//  kneet2
//
//  Created by Created by Jason Lee on 10/1/15.
//  Copyright (c) 2015 ntels. All rights reserved.
//
#import "JDObject.h"
#import "KNTableViewCell.h"
#import "KNView.h"
#import "MoreBtnModel.h"


@class CustomTableView;

@interface JDViewController : UIViewController {

@protected
    NSMutableArray *_popooverOptionArray;
    NSMutableArray<MoreBtnModel *> *_moreBtnArray;
    __weak UIView *_mainView;
}


#pragma mark - Properties
@property (weak, nonatomic) IBOutlet UIView *mainView;

#pragma mark - Instance Methods
- (void)initTableViewAsDefaultStyle:(CustomTableView *)tableView;


- (UIButton *)generateOptionButton;

- (void)toggleOptionsWithArray:(id)sender btnArray:(NSMutableArray *)btnArray;

- (void)toggleOptions:(id)sender;
- (void)resetOptions;
- (void)dismissOptionPopOver:(void (^)(void))completion;


- (void)sendDataToSocket:(SocketRequestModel *)data;
- (void)sendDataToSocket:(SocketRequestModel *)data modelClass:(Class)modelClass;
- (void)sendDataToSocket:(SocketRequestModel *)data modelClass:(Class)modelClass isLoading:(BOOL)isLoading;
- (void)sendDataToSocketWithOutDelegate:(SocketRequestModel *)data;
- (void)closeSocket;
- (BOOL)isSocketConnected;
- (SRReadyState)getSocketStatus;

// Socket BoradCasting
-(void)addSocketDataReceive;
-(void)removeSocketDataReceive;
-(void)receiveSocketData:(NSNotification *)notification;

//table view
- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath;

- (void)showTransparencyModalView:(UIViewController *)vc;

- (void)showTransparencyModalView:(UIViewController *)vc removeSelf:(BOOL)removeSelf;



@end
