Providing User Details
You can init the SDK with predefined user details. By providing the initial user details you will skip the corresponding tutorial screen
Adding gender:
Parameters:
- gender: using the MYSIZE_GENDER enum can only by ether MALE or FEMALE
Usage Example:
Adding Age:
Parameters:
- age: Integer
Usage Example:
Adding Height:
Parameters:
- height: the user height in Centimeters as Integer
Usage Example:
Adding Weight:
Parameters:
- weight: the user weight in Centimeters as Integer
Usage Example:
Adding Measurement System:
Parameters:
- MEASUREMENT_SYSTEM: using the MYSIZE_MEASUREMENT_SYSTEM enum can only by ether MEASUREMENT_SYSTEM_METRIC or MEASUREMENT_SYSTEM_IMPERIAL
Usage Example:
Getting User Details
Retrieves the user data (height, weight, age, gender, measurement system).
Parameters:
- userID: a unique user id – can be any unique String.
- OnComplete: a callback that will be called if there are no errors with the correct user as MySizeIDSDKUserDataHolder.
- OnFailure: a callback that will be called if you have an error.
MySizeIDSDKUserDataHolder:
MySizeIDSDKUserDataHolder holds the following user data:
- height: the user height as CGFloat.
- weight: the user weight as CGFloat.
- age: the user age as NSIntger.
- gender: the user gender as MYSIZE_GENDER enum (MALE, FEMALE).
- measurementSystem: the user measurement system as MYSIZE_MEASUREMENT_SYSTEM ( MEASUREMENT_SYSTEM_METRIC, MEASUREMENT_SYSTEM_IMPERIAL).
Usage Example:
Comments
0 comments
Please sign in to leave a comment.