---
title: "CFStringTokenizerSetString(_:_:_:)"
framework: corefoundation
role: symbol
role_heading: Function
path: "corefoundation/cfstringtokenizersetstring(_:_:_:)"
---

# CFStringTokenizerSetString(_:_:_:)

Sets the string for a tokenizer.

## Declaration

```swift
func CFStringTokenizerSetString(_ tokenizer: CFStringTokenizer!, _ string: CFString!, _ range: CFRange)
```

## Parameters

- `tokenizer`: A tokenizer.
- `string`: The string for the tokenizer to tokenize.
- `range`: The range of string to tokenize. The range of characters within the string to be tokenized. The specified range must not exceed the length of the string.
