<commit_before>//
//  NetWorkService.swift
//  Shrimp500px
//
//  Created by <NAME> 16/3/2.
//  Copyright © 2016年 papa.studio. All rights reserved.
//

import Foundation
import ReachabilitySwift

class NetWorkService {
    static let sharedManager = NetWorkService()
    
    /// 网络状态检测
    var netStatus: NetStatus?
    
    private init() {
        netStatus = NetStatus()
        netStatus?.delegate = self
    }
}


// MARK: - 实现网络状态协议
extension NetWorkService: NetStatusDelegate {
    func startListen() {
        netStatus?.startListen()
    }
    
    func stopListen() {
        
    }
    
    func reachabilityChanged(status: Reachability.NetworkStatus) {
        
    }
    
    func currentReachabilityStatus(status: Reachability.NetworkStatus) {
        log.info(status.description)
    }
    
}<commit_msg>* implement delegate functions<commit_after>//
//  NetWorkService.swift
//  Shrimp500px
//
//  Created by <NAME> on 16/3/2.
//  Copyright © 2016年 papa.studio. All rights reserved.
//

import Foundation
import ReachabilitySwift

class NetWorkService {
    static let sharedManager = NetWorkService()
    
    /// 网络状态检测
    var netStatus: NetStatus?
    
    private init() {
        netStatus = NetStatus()
        netStatus?.delegate = self
    }
}


// MARK: - 实现网络状态协议
extension NetWorkService: NetStatusDelegate {
    func startListen() {
        netStatus?.startListen()
    }
    
    func stopListen() {
        netStatus?.stopListen()
    }
    
    func reachabilityChanged(status: Reachability.NetworkStatus) {
        log.info("current status change to: \(status.description)")
    }
    
    func currentReachabilityStatus(status: Reachability.NetworkStatus) {
        log.info(status.description)
    }
    
}
{'fraction_non_alphanumeric': 0.10275545350172216, 'fraction_numerical': 0.012629161882893225, 'mean_word_length': 2.410958904109589, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7652305', 'n_tokens_mistral': 564, 'n_tokens_neox': 556, 'n_words': 112}