---
title: "CFNumberGetType(_:)"
framework: corefoundation
role: symbol
role_heading: Function
path: "corefoundation/cfnumbergettype(_:)"
---

# CFNumberGetType(_:)

Returns the type used by a CFNumber object to store its value.

## Declaration

```swift
func CFNumberGetType(_ number: CFNumber!) -> CFNumberType
```

## Parameters

- `number`: The CFNumber object to examine.

## Return Value

Return Value A constant that indicates the data type of the value contained in number. See CFNumberType for a list of possible values.

## Discussion

Discussion The type specified in the call to CFNumberCreate(_:_:_:) is not necessarily preserved when a new CFNumber object is created—it uses whatever internal storage type the creation function deems appropriate.

## See Also

### Getting Information About Numbers

- [CFNumberGetByteSize(_:)](corefoundation/cfnumbergetbytesize(_:).md)
- [CFNumberGetValue(_:_:_:)](corefoundation/cfnumbergetvalue(_:_:_:).md)
- [CFNumberIsFloatType(_:)](corefoundation/cfnumberisfloattype(_:).md)
