\M2M_Utility

Utility contains usefull functionnalities

Summary

Methods
Properties
Constants
getBeautifiedOutput()
getBeautifiedException()
calculateLuhnChecksum()
serialNumberToICCID()
ICCIDToserialNumber()
swapICCID()
No public properties found
No constants found
No protected methods found
No protected properties found
N/A
No private methods found
No private properties found
N/A

Methods

getBeautifiedOutput()

getBeautifiedOutput(mixed $oOutput, mixed $sMethodName, mixed $sAnchorName)

getBeautifiedOutput

Parameters

mixed $oOutput
mixed $sMethodName
mixed $sAnchorName

getBeautifiedException()

getBeautifiedException(\Exception $oException)

getBeautifiedException

Parameters

\Exception $oException

calculateLuhnChecksum()

calculateLuhnChecksum( $sNumber) : 

Used in the ICCD to SSN conversion

Parameters

$sNumber

Returns

serialNumberToICCID()

serialNumberToICCID( $ssn,  $iccidPrefix) : \:

This function transforms a SIM Serial Number into a ICCID (Integrated Circuit Card Identifier)

Parameters

$ssn
$iccidPrefix

Returns

\: —

ICCID corresponding to the SSN number

ICCIDToserialNumber()

ICCIDToserialNumber( $iccid) : \:

This function transforms a ICCID (Integrated Circuit Card Identifier) into a SIM Serial Number

Parameters

$iccid

Returns

\: —

SSN number corresponding to the ICCID

swapICCID()

swapICCID( $iccid) : 

For 3G sim cards for instance, you might need the ICCID for which digits are swapped 2 by 2 example : calculated iccid=89330116680073700130 if you run swappICCID("89330116680073700130"), you will get : SWAPPED iccid=98331061860037071003

Parameters

$iccid

Returns