TCGBWebViewController Class Reference

Inherits from UIViewController
Conforms to TCGBWebViewDelegate
WKNavigationDelegate
WKUIDelegate
Declared in TCGBWebViewController.h

Overview

The TCGBWebViewController is a view controller class which have webview, headerview, maskview and etc.

Other Methods

  schemeCallbackDictionary

@name Properties

@property (strong, nonatomic) NSDictionary *schemeCallbackDictionary

Declared In

TCGBWebViewController.h

  maskView

Mask View.

@property (nonatomic, strong) UIView *maskView

Discussion

Only used in popup launch style.

Declared In

TCGBWebViewController.h

  configuration

WebView Configuration.

@property (nonatomic, strong) TCGBWebViewConfiguration *configuration

Discussion

You can handle the webview with this configuration property.

Declared In

TCGBWebViewController.h

  delegate

UIViewController Delegate.

@property (nonatomic, weak, nullable) id<TCGBWebViewDelegate> delegate

Discussion

It is used to delegate UIViewController’s methods such as viewDidLoad: viewWillLoad: viewDidDisappear: and etc. It is setted by configuration property.

Declared In

TCGBWebViewController.h

Initialization

– initWithConfiguration:

Initialization with TCGBWebViewConfiguration.

- (instancetype)initWithConfiguration:(TCGBWebViewConfiguration *)configuration

Parameters

configuration

With this property, TCGBWebViewController initialize its components such as webview, orientation, launch style and so on.

Declared In

TCGBWebViewController.h

Launching

– showWebViewWithURL:

Show WebView that is not for local url.

- (void)showWebViewWithURL:(NSString *)urlString

Parameters

urlString

The string value for target url

Declared In

TCGBWebViewController.h

– showWebViewWithLocalURL:bundle:

Show WebView for local html (or other resources)

- (void)showWebViewWithLocalURL:(NSString *)localFilePath bundle:(NSBundle *)bundle

Parameters

localFilePath

The string value for target local path.

bundle

Where the file is located.

Declared In

TCGBWebViewController.h

– setSchemeCallbackDictionary:

custom scheme에 대한 동작 정의 - Parameter schemeCallbackDictionary: key: custom scheme, value: block

- (void)setSchemeCallbackDictionary:(NSDictionary *)schemeCallbackDictionary

Declared In

TCGBWebViewController.h