<commit_before>//
//  {{{projectName}}}Helper.m
//  {{{projectName}}}
//  Version: {{{version}}}
//
//  Created by Mobivery
//  Copyright (c) 2012 Mobivery. All rights reserved.
//

#import "{{{projectName}}}Helper.h"
#import <QuartzCore/QuartzCore.h>

@implementation {{{projectName}}}Helper


// Get the shared instance and create it if necessary.
+ ({{{projectName}}}Helper *)sharedInstance {
    
    static dispatch_once_t onceQueue;
    static {{{projectName}}}Helper *instance = nil;
    
    dispatch_once(&onceQueue, ^{ instance = [[self alloc] init]; });
    return instance;
}

- (NSString *)preInjectURLParameters:(NSString *)url withObject:(NSObject *)object onService:(NSString *)serviceName onMethod:(NSString *)serviceMethod {
	return url;
}

- (NSString *)postInjectURLParameters:(NSString *)url withObject:(NSObject *)object onService:(NSString *)serviceName onMethod:(NSString *)serviceMethod {
	return url;
}

- (NSString *)escapeUrl:(NSString *)url  onService:(NSString *)serviceName onMethod:(NSString *)serviceMethod{
	return [url stringByAddingPercentEscapesUsingEncoding:NSUTF8StringEncoding];
}

- (NSMutableURLRequest *)manageRequest:(NSMutableURLRequest *)request  onService:(NSString *)serviceName onMethod:(NSString *)serviceMethod{
	return request;
}

- (NSString *)preprocessResponse:(NSString *)responseString  onService:(NSString *)serviceName onMethod:(NSString *)serviceMethod{
	return responseString;
}

- (NSDictionary *) preprocessResponseAsDictionary:(NSDictionary *)responseDict  onService:(NSString *)serviceName onMethod:(NSString *)serviceMethod{
	return responseDict;
}

- (id)preprocessCacheHitForRequest:(id)request withCachedResponse:(id)cachedResponse onService:(NSString *)serviceName onMethod:(NSString *)methodName {
    return cachedResponse;
}

- (UIView *) loadingViewForTasks {

	// Una vista de carga por defecto
	CGRect screenRect = [[UIScreen mainScreen] bounds];
	CGFloat screenWidth = screenRect.size.width;
	CGFloat screenHeight = screenRect.size.height;
    
    UIView *loadingView = [[UIView alloc] initWithFrame:CGRectMake(0, 0, screenWidth, screenHeight)];
    [loadingView setBackgroundColor:[UIColor clearColor]];
    
    CGSize centerViewSize = CGSizeMake(100, 100);
    
    UIView *centerView = [[UIView alloc] initWithFrame:
                          CGRectMake(screenWidth/2 - centerViewSize.width/2, 
                                     screenHeight/2 - centerViewSize.height/2, 
                                     centerViewSize.width, 
                                     centerViewSize.height)];
    
    [centerView setBackgroundColor:[UIColor colorWithRed:0 green:0 blue:0 alpha:0.5]];
    [centerView.layer setCornerRadius:5];
    [centerView.layer setMasksToBounds:YES];
    
    UIActivityIndicatorView *activityIndicator = [[UIActivityIndicatorView alloc] initWithActivityIndicatorStyle:UIActivityIndicatorViewStyleWhiteLarge];
    [activityIndicator setFrame:CGRectMake(screenWidth/2 - activityIndicator.frame.size.width/2,       // X
                                           screenHeight/2 - activityIndicator.frame.size.height/2,     // Y
                                           activityIndicator.frame.size.width, activityIndicator.frame.size.height)];
    [loadingView addSubview:centerView];
    [loadingView addSubview:activityIndicator];    
    [activityIndicator startAnimating];<commit_msg>More spanish stuff removed - though all these things werent mine to begin with -_-<commit_after>//
//  {{{projectName}}}Helper.m
//  {{{projectName}}}
//  Version: {{{version}}}
//
//  Created by Mobivery
//  Copyright (c) 2012 Mobivery. All rights reserved.
//

#import "{{{projectName}}}Helper.h"
#import <QuartzCore/QuartzCore.h>

@implementation {{{projectName}}}Helper


// Get the shared instance and create it if necessary.
+ ({{{projectName}}}Helper *)sharedInstance {
    
    static dispatch_once_t onceQueue;
    static {{{projectName}}}Helper *instance = nil;
    
    dispatch_once(&onceQueue, ^{ instance = [[self alloc] init]; });
    return instance;
}

- (NSString *)preInjectURLParameters:(NSString *)url withObject:(NSObject *)object onService:(NSString *)serviceName onMethod:(NSString *)serviceMethod {
	return url;
}

- (NSString *)postInjectURLParameters:(NSString *)url withObject:(NSObject *)object onService:(NSString *)serviceName onMethod:(NSString *)serviceMethod {
	return url;
}

- (NSString *)escapeUrl:(NSString *)url  onService:(NSString *)serviceName onMethod:(NSString *)serviceMethod{
	return [url stringByAddingPercentEscapesUsingEncoding:NSUTF8StringEncoding];
}

- (NSMutableURLRequest *)manageRequest:(NSMutableURLRequest *)request  onService:(NSString *)serviceName onMethod:(NSString *)serviceMethod{
	return request;
}

- (NSString *)preprocessResponse:(NSString *)responseString  onService:(NSString *)serviceName onMethod:(NSString *)serviceMethod{
	return responseString;
}

- (NSDictionary *) preprocessResponseAsDictionary:(NSDictionary *)responseDict  onService:(NSString *)serviceName onMethod:(NSString *)serviceMethod{
	return responseDict;
}

- (id)preprocessCacheHitForRequest:(id)request withCachedResponse:(id)cachedResponse onService:(NSString *)serviceName onMethod:(NSString *)methodName {
    return cachedResponse;
}

- (UIView *) loadingViewForTasks {
	CGRect screenRect = [[UIScreen mainScreen] bounds];
	CGFloat screenWidth = screenRect.size.width;
	CGFloat screenHeight = screenRect.size.height;
    
    UIView *loadingView = [[UIView alloc] initWithFrame:CGRectMake(0, 0, screenWidth, screenHeight)];
    [loadingView setBackgroundColor:[UIColor clearColor]];
    
    CGSize centerViewSize = CGSizeMake(100, 100);
    
    UIView *centerView = [[UIView alloc] initWithFrame:
                          CGRectMake(screenWidth/2 - centerViewSize.width/2, 
                                     screenHeight/2 - centerViewSize.height/2, 
                                     centerViewSize.width, 
                                     centerViewSize.height)];
    
    [centerView setBackgroundColor:[UIColor colorWithRed:0 green:0 blue:0 alpha:0.5]];
    [centerView.layer setCornerRadius:5];
    [centerView.layer setMasksToBounds:YES];
    
    UIActivityIndicatorView *activityIndicator = [[UIActivityIndicatorView alloc] initWithActivityIndicatorStyle:UIActivityIndicatorViewStyleWhiteLarge];
    [activityIndicator setFrame:CGRectMake(screenWidth/2 - activityIndicator.frame.size.width/2,       // X
                                           screenHeight/2 - activityIndicator.frame.size.height/2,     // Y
                                           activityIndicator.frame.size.width, activityIndicator.frame.size.height)];
    [loadingView addSubview:centerView];
    [loadingView addSubview:activityIndicator];    
    [activityIndicator startAnimating];
{'fraction_non_alphanumeric': 0.11417265132639601, 'fraction_numerical': 0.007914407152279056, 'mean_word_length': 3.9485134155184918, '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': 14, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2270189', 'n_tokens_mistral': 1956, 'n_tokens_neox': 1829, 'n_words': 382}