Inherits from NSObject
Declared in RCTConvert.h

Overview

This class provides a collection of conversion functions for mapping JSON objects to native types and classes. These are useful when writing custom RCTViewManager setter methods.

Copyright © 2015-present, Facebook, Inc. All rights reserved.

This source code is licensed under the BSD-style license found in the LICENSE file in the root directory of this source tree. An additional grant of patent rights can be found in the PATENTS file in the same directory.

Copyright © 2015-present, Facebook, Inc. All rights reserved.

This source code is licensed under the BSD-style license found in the LICENSE file in the root directory of this source tree. An additional grant of patent rights can be found in the PATENTS file in the same directory.

Copyright © 2015-present, Facebook, Inc. All rights reserved.

This source code is licensed under the BSD-style license found in the LICENSE file in the root directory of this source tree. An additional grant of patent rights can be found in the PATENTS file in the same directory.

Copyright © 2015-present, Facebook, Inc. All rights reserved.

This source code is licensed under the BSD-style license found in the LICENSE file in the root directory of this source tree. An additional grant of patent rights can be found in the PATENTS file in the same directory.

Copyright © 2015-present, Facebook, Inc. All rights reserved.

This source code is licensed under the BSD-style license found in the LICENSE file in the root directory of this source tree. An additional grant of patent rights can be found in the PATENTS file in the same directory.

Copyright © 2015-present, Facebook, Inc. All rights reserved.

This source code is licensed under the BSD-style license found in the LICENSE file in the root directory of this source tree. An additional grant of patent rights can be found in the PATENTS file in the same directory.

Copyright © 2015-present, Facebook, Inc. All rights reserved.

This source code is licensed under the BSD-style license found in the LICENSE file in the root directory of this source tree. An additional grant of patent rights can be found in the PATENTS file in the same directory.

Tasks

Other Methods

ART Methods

UIStatusBar Methods

CoreLocation Methods

UIActivityIndicatorView Methods

UIDatePicker Methods

UIScrollView Methods

MapKit Methods

Class Methods

ARTBrush:

+ (ARTBrush *)ARTBrush:(id)json

ARTCGFloatArray:

+ (ARTCGFloatArray)ARTCGFloatArray:(id)json

ARTTextFrame:

+ (ARTTextFrame)ARTTextFrame:(id)json

BOOL:

+ (BOOL)BOOL:(id)json

CATransform3D:

+ (CATransform3D)CATransform3D:(id)json

CGAffineTransform:

+ (CGAffineTransform)CGAffineTransform:(id)json

CGColor:

+ (CGColorRef)CGColor:(id)json

CGColor:offset:

+ (CGColorRef)CGColor:(id)json offset:(NSUInteger)offset

CGColorArray:

+ (CGColorArray *)CGColorArray:(id)json

CGFloat:

+ (CGFloat)CGFloat:(id)json

CGGradient:offset:

+ (CGGradientRef)CGGradient:(id)json offset:(NSUInteger)offset

CGImage:

+ (CGImageRef)CGImage:(id)json

CGLineCap:

+ (CGLineCap)CGLineCap:(id)json

CGLineJoin:

+ (CGLineJoin)CGLineJoin:(id)json

CGPath:

+ (CGPathRef)CGPath:(id)json

CGPoint:

+ (CGPoint)CGPoint:(id)json

CGPoint:offset:

+ (CGPoint)CGPoint:(id)json offset:(NSUInteger)offset

CGRect:

+ (CGRect)CGRect:(id)json

CGRect:offset:

+ (CGRect)CGRect:(id)json offset:(NSUInteger)offset

CGSize:

+ (CGSize)CGSize:(id)json

CLLocationCoordinate2D:

+ (CLLocationCoordinate2D)CLLocationCoordinate2D:(id)json

CLLocationDegrees:

+ (CLLocationDegrees)CLLocationDegrees:(id)json

CLLocationDistance:

+ (CLLocationDistance)CLLocationDistance:(id)json

CTTextAlignment:

+ (CTTextAlignment)CTTextAlignment:(id)json

MKCoordinateRegion:

+ (MKCoordinateRegion)MKCoordinateRegion:(id)json

MKCoordinateSpan:

+ (MKCoordinateSpan)MKCoordinateSpan:(id)json

MKMapType:

+ (MKMapType)MKMapType:(id)json

MKShape:

+ (MKShape *)MKShape:(id)json

MKShapeArray:

+ (MKShapeArray *)MKShapeArray:(id)json

NSArray:

+ (NSArray *)NSArray:(id)json

NSData:

+ (NSData *)NSData:(id)json

NSDate:

+ (NSDate *)NSDate:(id)json

NSDictionary:

+ (NSDictionary *)NSDictionary:(id)json

NSDictionaryArray:

+ (NSDictionaryArray *)NSDictionaryArray:(id)json

NSIndexSet:

+ (NSIndexSet *)NSIndexSet:(id)json

NSInteger:

+ (NSInteger)NSInteger:(id)json

NSNumber:

+ (NSNumber *)NSNumber:(id)json

NSNumberArray:

+ (NSNumberArray *)NSNumberArray:(id)json

NSPropertyList:

+ (NSPropertyList)NSPropertyList:(id)json
Discussion

Convert a JSON object to a Plist-safe equivalent by stripping null values.

Declared In

RCTConvert.h

NSSet:

+ (NSSet *)NSSet:(id)json

NSString:

+ (NSString *)NSString:(id)json

NSStringArray:

+ (NSStringArray *)NSStringArray:(id)json

NSTextAlignment:

+ (NSTextAlignment)NSTextAlignment:(id)json

NSTimeInterval:

+ (NSTimeInterval)NSTimeInterval:(id)json

NSTimeZone:

+ (NSTimeZone *)NSTimeZone:(id)json

NSUInteger:

+ (NSUInteger)NSUInteger:(id)json

NSURL:

+ (NSURL *)NSURL:(id)json

NSURLArray:

+ (NSURLArray *)NSURLArray:(id)json

NSURLRequest:

+ (NSURLRequest *)NSURLRequest:(id)json

NSUnderlineStyle:

+ (NSUnderlineStyle)NSUnderlineStyle:(id)json

NSWritingDirection:

+ (NSWritingDirection)NSWritingDirection:(id)json

RCTAnimationType:

+ (RCTAnimationType)RCTAnimationType:(id)json

RCTFileURL:

+ (RCTFileURL *)RCTFileURL:(id)json

RCTFileURLArray:

+ (RCTFileURLArray *)RCTFileURLArray:(id)json

RCTPointAnnotation:

+ (RCTPointAnnotation *)RCTPointAnnotation:(id)json

RCTPointAnnotationArray:

+ (RCTPointAnnotationArray *)RCTPointAnnotationArray:(id)json

RCTPointerEvents:

+ (RCTPointerEvents)RCTPointerEvents:(id)json

RCTTextDecorationLineType:

+ (RCTTextDecorationLineType)RCTTextDecorationLineType:(id)json

UIActivityIndicatorViewStyle:

+ (UIActivityIndicatorViewStyle)UIActivityIndicatorViewStyle:(id)json

UIBarStyle:

+ (UIBarStyle)UIBarStyle:(id)json

UIColor:

+ (UIColor *)UIColor:(id)json

UIColorArray:

+ (UIColorArray *)UIColorArray:(id)json

UIDatePickerMode:

+ (UIDatePickerMode)UIDatePickerMode:(id)json

UIEdgeInsets:

+ (UIEdgeInsets)UIEdgeInsets:(id)json

UIFont:

+ (UIFont *)UIFont:(id)json

UIFont:withFamily:

+ (UIFont *)UIFont:(UIFont *)font withFamily:(id)json

UIFont:withFamily:size:weight:style:

+ (UIFont *)UIFont:(UIFont *)font withFamily:(id)family size:(id)size weight:(id)weight style:(id)style

UIFont:withSize:

+ (UIFont *)UIFont:(UIFont *)font withSize:(id)json

UIFont:withStyle:

+ (UIFont *)UIFont:(UIFont *)font withStyle:(id)json

UIFont:withWeight:

+ (UIFont *)UIFont:(UIFont *)font withWeight:(id)json

UIImage:

+ (UIImage *)UIImage:(id)json

UIKeyboardType:

+ (UIKeyboardType)UIKeyboardType:(id)json

UIReturnKeyType:

+ (UIReturnKeyType)UIReturnKeyType:(id)json

UIScrollViewKeyboardDismissMode:

+ (UIScrollViewKeyboardDismissMode)UIScrollViewKeyboardDismissMode:(id)json

UIStatusBarAnimation:

+ (UIStatusBarAnimation)UIStatusBarAnimation:(id)json

UIStatusBarStyle:

+ (UIStatusBarStyle)UIStatusBarStyle:(id)json

UITextAutocapitalizationType:

+ (UITextAutocapitalizationType)UITextAutocapitalizationType:(id)json

UITextFieldViewMode:

+ (UITextFieldViewMode)UITextFieldViewMode:(id)json

UIViewContentMode:

+ (UIViewContentMode)UIViewContentMode:(id)json

css_align_t:

+ (css_align_t)css_align_t:(id)json

css_clip_t:

+ (css_clip_t)css_clip_t:(id)json

css_flex_direction_t:

+ (css_flex_direction_t)css_flex_direction_t:(id)json

css_justify_t:

+ (css_justify_t)css_justify_t:(id)json

css_position_type_t:

+ (css_position_type_t)css_position_type_t:(id)json

css_wrap_type_t:

+ (css_wrap_type_t)css_wrap_type_t:(id)json

double:

+ (double)double:(id)json

float:

+ (float)float:(id)json

id:

+ (id)id:(id)json

int64_t:

+ (int64_t)int64_t:(id)json

int:

+ (int)int:(id)json

uint64_t:

+ (uint64_t)uint64_t:(id)json