44 references to IfNull
Microsoft.Extensions.AI.Abstractions (44)
ChatCompletion\ChatClientExtensions.cs (5)
25
_ = Throw.
IfNull
(client);
42
_ = Throw.
IfNull
(client);
43
_ = Throw.
IfNull
(chatMessage);
60
_ = Throw.
IfNull
(client);
61
_ = Throw.
IfNull
(chatMessage);
ChatCompletion\ChatCompletion.cs (3)
23
_choices = Throw.
IfNull
(choices);
30
_ = Throw.
IfNull
(message);
38
set => _choices = Throw.
IfNull
(value);
ChatCompletion\ChatFinishReason.cs (1)
90
Throw.
IfNull
(writer).WriteStringValue(value.Value);
ChatCompletion\ChatMessage.cs (1)
39
_contents = Throw.
IfNull
(contents);
ChatCompletion\ChatResponseFormat.cs (1)
37
new(Throw.
IfNull
(schema),
ChatCompletion\ChatRole.cs (1)
98
Throw.
IfNull
(writer).WriteStringValue(value.Value);
ChatCompletion\DelegatingChatClient.cs (2)
27
InnerClient = Throw.
IfNull
(innerClient);
68
_ = Throw.
IfNull
(serviceType);
ChatCompletion\StreamingChatCompletionUpdateExtensions.cs (2)
36
_ = Throw.
IfNull
(updates);
64
_ = Throw.
IfNull
(updates);
Contents\DataContent.cs (1)
50
: this(Throw.
IfNull
(uri).ToString(), mediaType)
Contents\FunctionCallContent.cs (5)
28
Name = Throw.
IfNull
(name);
74
_ = Throw.
IfNull
(callId);
75
_ = Throw.
IfNull
(name);
76
_ = Throw.
IfNull
(encodedArguments);
77
_ = Throw.
IfNull
(argumentParser);
Contents\FunctionResultContent.cs (2)
31
CallId = Throw.
IfNull
(callId);
32
Name = Throw.
IfNull
(name);
Contents\UsageContent.cs (2)
30
_details = Throw.
IfNull
(details);
37
set => _details = Throw.
IfNull
(value);
Embeddings\DelegatingEmbeddingGenerator.cs (2)
30
InnerGenerator = Throw.
IfNull
(innerGenerator);
64
_ = Throw.
IfNull
(serviceType);
Embeddings\EmbeddingGeneratorExtensions.cs (5)
32
_ = Throw.
IfNull
(generator);
99
_ = Throw.
IfNull
(generator);
100
_ = Throw.
IfNull
(value);
135
_ = Throw.
IfNull
(generator);
136
_ = Throw.
IfNull
(values);
Embeddings\GeneratedEmbeddings.cs (1)
39
_embeddings = new List<TEmbedding>(Throw.
IfNull
(embeddings));
Functions\AIFunctionMetadata.cs (4)
53
Name = Throw.
IfNull
(metadata).Name;
80
init => _parameters = Throw.
IfNull
(value);
100
init => _returnParameter = Throw.
IfNull
(value);
107
init => _additionalProperties = Throw.
IfNull
(value);
Functions\AIFunctionParameterMetadata.cs (1)
30
_ = Throw.
IfNull
(metadata);
Functions\AIFunctionReturnParameterMetadata.cs (1)
25
Description = Throw.
IfNull
(metadata).Description;
Utilities\AIJsonUtilities.Schema.cs (4)
63
_ = Throw.
IfNull
(parameterMetadata);
64
_ = Throw.
IfNull
(functionMetadata);
110
_ = Throw.
IfNull
(parameterName);
187
_ = Throw.
IfNull
(options);