FirebaseAI Framework Reference
Stay organized with collections
Save and categorize content based on your preferences.
ContentModality
@available(iOS 15.0, macOS 12.0, tvOS 15.0, watchOS 8.0, *)
public struct ContentModality : DecodableProtoEnum, Hashable, Sendable
Content part modality.
-
Declaration
Swift
public static let text: ContentModality
-
Declaration
Swift
public static let image: ContentModality
-
Declaration
Swift
public static let video: ContentModality
-
Declaration
Swift
public static let audio: ContentModality
-
Declaration
Swift
public static let document: ContentModality
-
Returns the raw string representation of the ContentModality
value.
Declaration
Swift
public let rawValue: String
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-05-20 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-05-20 UTC."],[],[],null,["# FirebaseAI Framework Reference\n\nContentModality\n===============\n\n @available(iOS 15.0, macOS 12.0, tvOS 15.0, watchOS 8.0, *)\n public struct ContentModality : DecodableProtoEnum, Hashable, Sendable\n\nContent part modality.\n- `\n ``\n ``\n `\n\n ### [text](#/s:10FirebaseAI15ContentModalityV4textACvpZ)\n\n `\n ` \n Plain text. \n\n #### Declaration\n\n Swift \n\n public static let text: ContentModality\n\n- `\n ``\n ``\n `\n\n ### [image](#/s:10FirebaseAI15ContentModalityV5imageACvpZ)\n\n `\n ` \n Image. \n\n #### Declaration\n\n Swift \n\n public static let image: ContentModality\n\n- `\n ``\n ``\n `\n\n ### [video](#/s:10FirebaseAI15ContentModalityV5videoACvpZ)\n\n `\n ` \n Video. \n\n #### Declaration\n\n Swift \n\n public static let video: ContentModality\n\n- `\n ``\n ``\n `\n\n ### [audio](#/s:10FirebaseAI15ContentModalityV5audioACvpZ)\n\n `\n ` \n Audio. \n\n #### Declaration\n\n Swift \n\n public static let audio: ContentModality\n\n- `\n ``\n ``\n `\n\n ### [document](#/s:10FirebaseAI15ContentModalityV8documentACvpZ)\n\n `\n ` \n Document, e.g. PDF. \n\n #### Declaration\n\n Swift \n\n public static let document: ContentModality\n\n- `\n ``\n ``\n `\n\n ### [rawValue](#/s:10FirebaseAI15ContentModalityV8rawValueSSvp)\n\n `\n ` \n Returns the raw string representation of the `ContentModality` value. \n\n #### Declaration\n\n Swift \n\n public let rawValue: String"]]