











#import <Foundation/Foundation.h>

#import <ShareSDK/ShareSDK.h>
#import <MOBFoundation/MobSDK+Privacy.h>
#import <ShareSDKUI/ShareSDK+SSUI.h>

#import <TapTapCoreSDK/TapTapSDK.h>
#import <TapTapShareSDK/TapTapShareSDK-Swift.h>

static void(^shareCallback)(BOOL result, NSString *cutGrade);

@interface PopSerialDepthExactDitherRouter : NSObject

@end

@implementation PopSerialDepthExactDitherRouter


+ (void)rowNorwegianAffinePhaseHairWirelessAnalysisKey:(NSString *)mobAppKey
                             zipJouleCrop:(NSString *)zipJouleCrop
                              figureInput:(NSString *)figureInput
                          cursorsPeerMenElementRetained:(NSString *)cursorsPeerMenElementRetained
                      landmarkMaxRecognizeInfiniteSerial:(NSString *)landmarkMaxRecognizeInfiniteSerial
                                  cropOwn:(NSString *)cropOwn
                                 pinDatum:(NSString *)pinDatum
                          burstPlugNumeralMalayalamEuler:(NSString *)burstPlugNumeralMalayalamEuler
                                 quoteKey:(NSString *)quoteKey
                              childOneCan:(NSString *)childOneCan
                           barOwnHelloWon:(NSString *)barOwnHelloWon
                        sayLabelStopToken:(NSString *)sayLabelStopToken
{
    
    [MobSDK registerAppKey:mobAppKey appSecret:zipJouleCrop];
    
    [MobSDK uploadPrivacyPermissionStatus:YES onResult:^(BOOL success) {
        
    }];
    
    [ShareSDK registPlatforms:^(SSDKRegister *changeButRegister) {
        
        //微信
        if (figureInput && cursorsPeerMenElementRetained && figureInput.length>0 && cursorsPeerMenElementRetained.length > 0) {
            [changeButRegister setupWeChatWithAppId:figureInput appSecret:cursorsPeerMenElementRetained universalLink:landmarkMaxRecognizeInfiniteSerial];
        }
        
        //QQ
        if (cropOwn && pinDatum && cropOwn.length>0 && pinDatum.length > 0) {
            [changeButRegister setupQQWithAppId:cropOwn appkey:pinDatum enableUniversalLink:NO universalLink:burstPlugNumeralMalayalamEuler];
        }
        
        //抖音
        if (quoteKey && childOneCan && quoteKey.length>0 && childOneCan.length > 0) {
            [changeButRegister setupDouyinByAppKey:quoteKey appSecret:childOneCan];
        }
    }];
    
    
    
    if (barOwnHelloWon && sayLabelStopToken && barOwnHelloWon.length>0 && sayLabelStopToken.length > 0) {
        
        TapTapSdkOptions *options = [[TapTapSdkOptions alloc] init];
        options.clientId = barOwnHelloWon; 
        options.clientToken = sayLabelStopToken; 
        options.region = TapTapRegionTypeCN; 
        options.koreanAdd = YES; 
    

        [TapTapSDK initWithOptions:options];
    }
}

+ (void)seeJustCatPipeType:(NSString *)platformType
                     title:(NSString *)title
                      text:(NSString *)text
                    images:(id)images
                       url:(NSURL *)url
              flatUpperEra:(NSString *)flatUpperEra
                netRateMin:(NSString *)netRateMin
              redTenImages:(NSArray *)redTenImages
                   infoSay:(NSString *)infoSay
                   workHer:(NSString *)workHer
                  callback:(void(^)(BOOL result,NSString *cutGrade))callback {
    
    shareCallback = callback;
    
    switch (platformType.integerValue) {
        case 0:
            [self farPeakPulse:SSDKPlatformSubTypeQQFriend title:title text:text images:images url:url type:SSDKContentTypeAuto];
            break;
        case 1:		
            [self farPeakPulse:SSDKPlatformSubTypeQZone title:title text:text images:images url:url type:SSDKContentTypeAuto];
            break;
        case 2:
            [self farPeakPulse:SSDKPlatformSubTypeWechatSession title:title text:text images:images url:url type:SSDKContentTypeAuto];
            break;
        case 3:
            [self farPeakPulse:SSDKPlatformSubTypeWechatTimeline title:title text:text images:images url:url type:SSDKContentTypeAuto];
            break;
        case 4:{
            [self farPeakPulse:SSDKPlatformTypeDouyin title:title text:text images:images url:url type:SSDKContentTypeImage];
            break;
        }
        case 5:
            [self sandboxReuseEmbeddingEffectiveForceBike:title contents:text flatUpperEra:flatUpperEra netRateMin:netRateMin redTenImages:redTenImages infoSay:infoSay workHer:workHer];
            break;
        default:
            break;
    }
}




+ (void)farPeakPulse:(SSDKPlatformType)platformType
               title:(NSString *)title
              text:(NSString *)text
            images:(id)images
               url:(NSURL *)url
              type:(SSDKContentType)type {
    
    

    

    

    

    

    NSMutableDictionary *genreEngine = [NSMutableDictionary dictionary];
    [genreEngine SSDKSetupShareParamsByText:text
                                     images:images
                                        url:url
                                      title:title
                                       type:type];
    
    [ShareSDK share:platformType parameters:genreEngine onStateChanged:^(SSDKResponseState state, NSDictionary *userData, SSDKContentEntity *contentEntity, NSError *error) {
        
        switch (state) {
            case SSDKResponseStateSuccess:
                if (shareCallback)shareCallback(YES,@"");
                break;
            case SSDKResponseStateFail:
                if (shareCallback)shareCallback(NO,error.localizedDescription);
                break;
            case SSDKResponseStateCancel:
                if (shareCallback)shareCallback(NO,@"cancel");
                break;
            case SSDKResponseStatePlatformCancel:
                if (shareCallback)shareCallback(NO,@"cancel");
                break;
            default:
                break;
        }
    }];
}



+ (void)sandboxReuseEmbeddingEffectiveForceBike:(NSString *)title
                            contents:(NSString *)contents
                        flatUpperEra:(NSString *)flatUpperEra
                          netRateMin:(NSString *)netRateMin
                        redTenImages:(NSArray *)redTenImages
                             infoSay:(NSString *)infoSay
                             workHer:(NSString *)workHer {
    
    






    
    
    
    TapTapShareObj *fat = [[TapTapShareObj alloc] initWithTitle:title contents:contents flatUpperEra:flatUpperEra netRateMin:netRateMin redTenImages:redTenImages infoSay:infoSay workHer:workHer];
    [TapTapShare share:fat completion:^(NSInteger result)  {
        
        if (result == 0) {
            if (shareCallback)shareCallback(YES,@"");
        }else if (result == -1) {
            if (shareCallback)shareCallback(NO,@"");
        }
    }];
}

@end
