Skip to content

ben-j69/ios-tools-by-benj

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 

Repository files navigation

Tools for iOS by Ben-J

Tools helper class for ios (iPhone, iPod, iPad)

This class will help you to:

Display alert pop up

  • (void) displayAlertWithMessage:(NSString )message andTitle:(NSString)title;

Check if the network is available

  • (BOOL) isNetworkAvailable;

Use a google tracker

  • (void) trackPage:(NSString*)page;

Encode in MD5

  • (NSString*) md5encode:(NSString*) str;

Encode in base64

  • (NSString*)base64forInt:(int)theInt;
  • (NSString*)base64forString:(NSString*)theString;
  • (NSString*)base64forData:(NSData*)theData;

Get preference dictionnary

  • (NSMutableDictionary *)getPrefDictionary;

Encode in SHA 256

  • (NSString*)getHashForInt:(int)intToHash;
  • (NSString*)getHash:(NSString*)stringToHash;

Encode string for url

  • (NSURL*)encodeStringForUrl:(NSString*)callString;

Check system version

  • (BOOL)versionIsEqualOrSupAs:(int)version;

Get device token

  • (NSString*)stringWithDeviceToken:(NSData*)deviceToken;

Get data from url

  • (NSData*)getDataFromUrl:(NSURL*)url withAlert:(BOOL)alert;

Get data from string

  • (NSData*)getDataFromStringUrl:(NSString*)link withAlert:(BOOL)alert;

Check if the device is an iPhone 5

  • (BOOL)isIphone5;

Check if a mail is valid

  • (BOOL) isValidEmail:(NSString *)checkString;

Get color from hex string

  • (UIColor*)colorWithHexString:(NSString*)hex;

Replace euro html entity in string

  • (NSString*)replaceEuroInString:(NSString*)str;

Get UIColor from hex string

  • (UIColor*)colorWithHexString:(NSString*)hex

Check if the device is able to make a call

  • (BOOL)isAbleToCall

Call an url easily

  • (BOOL)makeSimpleRequest:(NSString*)url

Test if the device is an IPad +(BOOL)isIpad

About

Tools helper class for ios

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published