# GCKHLSSegment Class

[Class Methods](https://developers.google.com/cast/docs/reference/ios/interface_g_c_k_h_l_s_segment#pub-static-methods) GCKHLSSegment Class Reference

## Overview

Class that provides helpers to convert between `GCKHLSSegmentFormat` and `NSString`.

Inherits NSObject.

|---|---|
| ## Class Method Summary ||
| (nullable NSString \*) | + [mapHLSSegmentFormatToString:](https://developers.google.com/cast/docs/reference/ios/interface_g_c_k_h_l_s_segment#a95e3c01240dbdb2335a29ae81d91da10) |
|   | Helper method to convert from `GCKHLSSegmentFormat` to `NSString`. [More...](https://developers.google.com/cast/docs/reference/ios/interface_g_c_k_h_l_s_segment#a95e3c01240dbdb2335a29ae81d91da10) |
|   ||
| ([GCKHLSSegmentFormat](https://developers.google.com/cast/docs/reference/ios/g_c_k_h_l_s_segment_format_8h#a2e7a0fabbe01b583c51dab04d512642b)) | + [mapHLSSegmentFormatStringToEnum:](https://developers.google.com/cast/docs/reference/ios/interface_g_c_k_h_l_s_segment#ad04ae4b1459b9ace26d05767e3e2a618) |
|   | Helper method to convert from `NSString` to `GCKHLSSegmentFormat`. [More...](https://developers.google.com/cast/docs/reference/ios/interface_g_c_k_h_l_s_segment#ad04ae4b1459b9ace26d05767e3e2a618) |
|   ||

## Method Detail

|---|---|---|---|---|
| + (nullable NSString \*) mapHLSSegmentFormatToString: |   | ([GCKHLSSegmentFormat](https://developers.google.com/cast/docs/reference/ios/g_c_k_h_l_s_segment_format_8h#a2e7a0fabbe01b583c51dab04d512642b)) | *hlsSegmentFormat* |   |

Helper method to convert from `GCKHLSSegmentFormat` to `NSString`.

Returns
:   NSString The string value corresponding to `GCKHLSSegmentFormat`. `nil` for `GCKHLSSegmentFormatUndefined` and invalid enum values.

Since
:   4.6.0

|---|---|---|---|---|
| + ([GCKHLSSegmentFormat](https://developers.google.com/cast/docs/reference/ios/g_c_k_h_l_s_segment_format_8h#a2e7a0fabbe01b583c51dab04d512642b)) mapHLSSegmentFormatStringToEnum: |   | (NSString \*) | *hlsSegmentFormatString* |   |

Helper method to convert from `NSString` to `GCKHLSSegmentFormat`.

The comparison is case insensitive.

Returns
:   GCKHLSSegmentFormat The corresponding `GCKHLSSegmentFormat` enum value. `GCKHLSSegmentFormatUndefined` for invalid string.

Since
:   4.6.0