Class DraftEmbedImage
- Namespace
- idunno.Bluesky.Drafts
- Assembly
- idunno.Bluesky.dll
Encapsulates a local embedded image in a draft post.
[JsonPolymorphic(UnknownDerivedTypeHandling = JsonUnknownDerivedTypeHandling.FallBackToNearestAncestor)]
[JsonDerivedType(typeof(DraftEmbedImage), "app.bsky.draft.defs#draftEmbedImage")]
public record DraftEmbedImage : IEquatable<DraftEmbedImage>Inheritance
Implements
Inherited Members
Constructors
DraftEmbedImage(DraftEmbedLocalRef, string?)
Creates a new instance of idunno.Bluesky.Drafts.DraftEmbedImage with the specified local reference and optional alt text.
[JsonConstructor]
public DraftEmbedImage(DraftEmbedLocalRef localRef, string? altText = null)Parameters
localRefDraftEmbedLocalRef-
The device local reference to an image.
altTextstring?-
The alt text for the image, if any. Maximum idunno.Bluesky.Maximum.DraftEmbedAltTextLengthInGraphemes grapheme clusters.
Exceptions
- ArgumentNullException
-
Thrown when
localRefis null. - ArgumentOutOfRangeException
-
Thrown when
altTextlength is greater than idunno.Bluesky.Maximum.DraftEmbedAltTextLengthInGraphemes grapheme clusters.
DraftEmbedImage(DraftEmbedImage)
protected DraftEmbedImage(DraftEmbedImage original)Parameters
originalDraftEmbedImage
DraftEmbedImage(DraftEmbedLocalRef, string?)
Creates a new instance of idunno.Bluesky.Drafts.DraftEmbedImage with the specified local reference and optional alt text.
[JsonConstructor]
public DraftEmbedImage(DraftEmbedLocalRef localRef, string? altText = null)Parameters
localRefDraftEmbedLocalRef-
The device local reference to an image.
altTextstring?-
The alt text for the image, if any. Maximum idunno.Bluesky.Maximum.DraftEmbedAltTextLengthInGraphemes grapheme clusters.
Exceptions
- ArgumentNullException
-
Thrown when
localRefis null. - ArgumentOutOfRangeException
-
Thrown when
altTextlength is greater than idunno.Bluesky.Maximum.DraftEmbedAltTextLengthInGraphemes grapheme clusters.
DraftEmbedImage(DraftEmbedImage)
protected DraftEmbedImage(DraftEmbedImage original)Parameters
originalDraftEmbedImage
DraftEmbedImage(DraftEmbedLocalRef, string?)
Creates a new instance of idunno.Bluesky.Drafts.DraftEmbedImage with the specified local reference and optional alt text.
[JsonConstructor]
public DraftEmbedImage(DraftEmbedLocalRef localRef, string? altText = null)Parameters
localRefDraftEmbedLocalRef-
The device local reference to an image.
altTextstring?-
The alt text for the image, if any. Maximum idunno.Bluesky.Maximum.DraftEmbedAltTextLengthInGraphemes grapheme clusters.
Exceptions
- ArgumentNullException
-
Thrown when
localRefis null. - ArgumentOutOfRangeException
-
Thrown when
altTextlength is greater than idunno.Bluesky.Maximum.DraftEmbedAltTextLengthInGraphemes grapheme clusters.
DraftEmbedImage(DraftEmbedImage)
protected DraftEmbedImage(DraftEmbedImage original)Parameters
originalDraftEmbedImage
Properties
AltText
Gets or sets the alt text for the image, if any. Maximum idunno.Bluesky.Maximum.DraftEmbedAltTextLengthInGraphemes grapheme clusters.
[JsonPropertyName("alt")]
public string? AltText { get; set; }Property Value
Exceptions
- ArgumentOutOfRangeException
-
Thrown when setting if the value length is greater than idunno.Bluesky.Maximum.DraftEmbedAltTextLengthInGraphemes grapheme clusters.
AltText
Gets or sets the alt text for the image, if any. Maximum idunno.Bluesky.Maximum.DraftEmbedAltTextLengthInGraphemes grapheme clusters.
[JsonPropertyName("alt")]
public string? AltText { get; set; }Property Value
Exceptions
- ArgumentOutOfRangeException
-
Thrown when setting if the value length is greater than idunno.Bluesky.Maximum.DraftEmbedAltTextLengthInGraphemes grapheme clusters.
AltText
Gets or sets the alt text for the image, if any. Maximum idunno.Bluesky.Maximum.DraftEmbedAltTextLengthInGraphemes grapheme clusters.
[JsonPropertyName("alt")]
public string? AltText { get; set; }Property Value
Exceptions
- ArgumentOutOfRangeException
-
Thrown when setting if the value length is greater than idunno.Bluesky.Maximum.DraftEmbedAltTextLengthInGraphemes grapheme clusters.
EqualityContract
protected virtual Type EqualityContract { get; }Property Value
EqualityContract
protected virtual Type EqualityContract { get; }Property Value
EqualityContract
protected virtual Type EqualityContract { get; }Property Value
LocalRef
Get the device local reference to an image.
[JsonRequired]
public DraftEmbedLocalRef LocalRef { get; init; }Property Value
Exceptions
- ArgumentNullException
-
Thrown when setting to null.
LocalRef
Get the device local reference to an image.
[JsonRequired]
public DraftEmbedLocalRef LocalRef { get; init; }Property Value
Exceptions
- ArgumentNullException
-
Thrown when setting to null.
LocalRef
Get the device local reference to an image.
[JsonRequired]
public DraftEmbedLocalRef LocalRef { get; init; }Property Value
Exceptions
- ArgumentNullException
-
Thrown when setting to null.
Methods
<Clone>$()
public virtual DraftEmbedImage <Clone>$()Returns
<Clone>$()
public virtual DraftEmbedImage <Clone>$()Returns
<Clone>$()
public virtual DraftEmbedImage <Clone>$()Returns
Equals(object?)
public override bool Equals(object? obj)Parameters
objobject?
Returns
Equals(DraftEmbedImage?)
public virtual bool Equals(DraftEmbedImage? other)Parameters
otherDraftEmbedImage?
Returns
Equals(object?)
public override bool Equals(object? obj)Parameters
objobject?
Returns
Equals(DraftEmbedImage?)
public virtual bool Equals(DraftEmbedImage? other)Parameters
otherDraftEmbedImage?
Returns
Equals(object?)
public override bool Equals(object? obj)Parameters
objobject?
Returns
Equals(DraftEmbedImage?)
public virtual bool Equals(DraftEmbedImage? other)Parameters
otherDraftEmbedImage?
Returns
GetHashCode()
public override int GetHashCode()Returns
GetHashCode()
public override int GetHashCode()Returns
GetHashCode()
public override int GetHashCode()Returns
PrintMembers(StringBuilder)
protected virtual bool PrintMembers(StringBuilder builder)Parameters
builderStringBuilder
Returns
PrintMembers(StringBuilder)
protected virtual bool PrintMembers(StringBuilder builder)Parameters
builderStringBuilder
Returns
PrintMembers(StringBuilder)
protected virtual bool PrintMembers(StringBuilder builder)Parameters
builderStringBuilder
Returns
ToString()
public override string ToString()Returns
ToString()
public override string ToString()Returns
ToString()
public override string ToString()Returns
Operators
operator ==(DraftEmbedImage?, DraftEmbedImage?)
public static bool operator ==(DraftEmbedImage? left, DraftEmbedImage? right)Parameters
leftDraftEmbedImage?rightDraftEmbedImage?
Returns
operator ==(DraftEmbedImage?, DraftEmbedImage?)
public static bool operator ==(DraftEmbedImage? left, DraftEmbedImage? right)Parameters
leftDraftEmbedImage?rightDraftEmbedImage?
Returns
operator ==(DraftEmbedImage?, DraftEmbedImage?)
public static bool operator ==(DraftEmbedImage? left, DraftEmbedImage? right)Parameters
leftDraftEmbedImage?rightDraftEmbedImage?
Returns
operator !=(DraftEmbedImage?, DraftEmbedImage?)
public static bool operator !=(DraftEmbedImage? left, DraftEmbedImage? right)Parameters
leftDraftEmbedImage?rightDraftEmbedImage?
Returns
operator !=(DraftEmbedImage?, DraftEmbedImage?)
public static bool operator !=(DraftEmbedImage? left, DraftEmbedImage? right)Parameters
leftDraftEmbedImage?rightDraftEmbedImage?
Returns
operator !=(DraftEmbedImage?, DraftEmbedImage?)
public static bool operator !=(DraftEmbedImage? left, DraftEmbedImage? right)Parameters
leftDraftEmbedImage?rightDraftEmbedImage?