Table of Contents

Class HashTag

Namespace
idunno.Bluesky.RichText
Assembly
idunno.Bluesky.dll

Provides an object representation of a hash tag in a Bluesky post.

public record HashTag : PostBuilderFacetFeature, IEquatable<PostBuilderFacetFeature>, IEquatable<HashTag>

Inheritance

Implements

Inherited Members

Constructors

HashTag(string)

Creates a new instance of idunno.Bluesky.RichText.HashTag.

public HashTag(string tag)

Parameters

tag string

The hash tag to add to a post. Do not include the '#' prefix except in the case of 'double hash tags'.

Remarks

The lexicon limits apply to tag itself, not to the text it renders as, so a tag of the maximum allowed length is still valid once its '#' prefix is added.

Exceptions

ArgumentException

if tag is null or white space.

ArgumentOutOfRangeException

If tag is longer than the allowed maximum.

HashTag(string, string)

Creates a new instance of idunno.Bluesky.RichText.HashTag.

public HashTag(string tag, string text)

Parameters

tag string

The hash tag to add to a post. Do not include the '#' prefix except in the case of 'double hash tags'.

text string

The text to wrap the hashtag around, if any. The text usually includes a '#' prefix.

Remarks

If text is not specified the tag will be used as the facet feature text.

The lexicon limits apply to tag only. text is the text the tag renders as, and so counts towards the length of the post rather than the length of the tag.

Exceptions

ArgumentException

if tag is null or white space.

ArgumentOutOfRangeException

If tag is longer than the allowed maximum.

HashTag(HashTag)

protected HashTag(HashTag original)

Parameters

original HashTag

HashTag(string)

Creates a new instance of idunno.Bluesky.RichText.HashTag.

public HashTag(string tag)

Parameters

tag string

The hash tag to add to a post. Do not include the '#' prefix except in the case of 'double hash tags'.

Remarks

The lexicon limits apply to tag itself, not to the text it renders as, so a tag of the maximum allowed length is still valid once its '#' prefix is added.

Exceptions

ArgumentException

if tag is null or white space.

ArgumentOutOfRangeException

If tag is longer than the allowed maximum.

HashTag(string, string)

Creates a new instance of idunno.Bluesky.RichText.HashTag.

public HashTag(string tag, string text)

Parameters

tag string

The hash tag to add to a post. Do not include the '#' prefix except in the case of 'double hash tags'.

text string

The text to wrap the hashtag around, if any. The text usually includes a '#' prefix.

Remarks

If text is not specified the tag will be used as the facet feature text.

The lexicon limits apply to tag only. text is the text the tag renders as, and so counts towards the length of the post rather than the length of the tag.

Exceptions

ArgumentException

if tag is null or white space.

ArgumentOutOfRangeException

If tag is longer than the allowed maximum.

HashTag(HashTag)

protected HashTag(HashTag original)

Parameters

original HashTag

HashTag(string)

Creates a new instance of idunno.Bluesky.RichText.HashTag.

public HashTag(string tag)

Parameters

tag string

The hash tag to add to a post. Do not include the '#' prefix except in the case of 'double hash tags'.

Remarks

The lexicon limits apply to tag itself, not to the text it renders as, so a tag of the maximum allowed length is still valid once its '#' prefix is added.

Exceptions

ArgumentException

if tag is null or white space.

ArgumentOutOfRangeException

If tag is longer than the allowed maximum.

HashTag(string, string)

Creates a new instance of idunno.Bluesky.RichText.HashTag.

public HashTag(string tag, string text)

Parameters

tag string

The hash tag to add to a post. Do not include the '#' prefix except in the case of 'double hash tags'.

text string

The text to wrap the hashtag around, if any. The text usually includes a '#' prefix.

Remarks

If text is not specified the tag will be used as the facet feature text.

The lexicon limits apply to tag only. text is the text the tag renders as, and so counts towards the length of the post rather than the length of the tag.

Exceptions

ArgumentException

if tag is null or white space.

ArgumentOutOfRangeException

If tag is longer than the allowed maximum.

HashTag(HashTag)

protected HashTag(HashTag original)

Parameters

original HashTag

Properties

EqualityContract

protected override Type EqualityContract { get; }

Property Value

Type

EqualityContract

protected override Type EqualityContract { get; }

Property Value

Type

EqualityContract

protected override Type EqualityContract { get; }

Property Value

Type

Tag

Gets the hash tag for this facet feature.

public string Tag { get; init; }

Property Value

string

Tag

Gets the hash tag for this facet feature.

public string Tag { get; init; }

Property Value

string

Tag

Gets the hash tag for this facet feature.

public string Tag { get; init; }

Property Value

string

Methods

<Clone>$()

public override HashTag <Clone>$()

Returns

HashTag

<Clone>$()

public override HashTag <Clone>$()

Returns

HashTag

<Clone>$()

public override HashTag <Clone>$()

Returns

HashTag

Equals(object?)

public override bool Equals(object? obj)

Parameters

obj object?

Returns

bool

Equals(PostBuilderFacetFeature?)

public override sealed bool Equals(PostBuilderFacetFeature? other)

Parameters

other PostBuilderFacetFeature?

Returns

bool

Equals(HashTag?)

public virtual bool Equals(HashTag? other)

Parameters

other HashTag?

Returns

bool

Equals(object?)

public override bool Equals(object? obj)

Parameters

obj object?

Returns

bool

Equals(PostBuilderFacetFeature?)

public override sealed bool Equals(PostBuilderFacetFeature? other)

Parameters

other PostBuilderFacetFeature?

Returns

bool

Equals(HashTag?)

public virtual bool Equals(HashTag? other)

Parameters

other HashTag?

Returns

bool

Equals(object?)

public override bool Equals(object? obj)

Parameters

obj object?

Returns

bool

Equals(PostBuilderFacetFeature?)

public override sealed bool Equals(PostBuilderFacetFeature? other)

Parameters

other PostBuilderFacetFeature?

Returns

bool

Equals(HashTag?)

public virtual bool Equals(HashTag? other)

Parameters

other HashTag?

Returns

bool

GetHashCode()

public override int GetHashCode()

Returns

int

GetHashCode()

public override int GetHashCode()

Returns

int

GetHashCode()

public override int GetHashCode()

Returns

int

PrintMembers(StringBuilder)

protected override bool PrintMembers(StringBuilder builder)

Parameters

builder StringBuilder

Returns

bool

PrintMembers(StringBuilder)

protected override bool PrintMembers(StringBuilder builder)

Parameters

builder StringBuilder

Returns

bool

PrintMembers(StringBuilder)

protected override bool PrintMembers(StringBuilder builder)

Parameters

builder StringBuilder

Returns

bool

ToString()

Returns a string that represents the current object.

public override string ToString()

Returns

string

The text of the facet, or an empty string if the facet has no text.

ToString()

Returns a string that represents the current object.

public override string ToString()

Returns

string

The text of the facet, or an empty string if the facet has no text.

ToString()

Returns a string that represents the current object.

public override string ToString()

Returns

string

The text of the facet, or an empty string if the facet has no text.

Operators

operator ==(HashTag?, HashTag?)

public static bool operator ==(HashTag? left, HashTag? right)

Parameters

left HashTag?
right HashTag?

Returns

bool

operator ==(HashTag?, HashTag?)

public static bool operator ==(HashTag? left, HashTag? right)

Parameters

left HashTag?
right HashTag?

Returns

bool

operator ==(HashTag?, HashTag?)

public static bool operator ==(HashTag? left, HashTag? right)

Parameters

left HashTag?
right HashTag?

Returns

bool

operator !=(HashTag?, HashTag?)

public static bool operator !=(HashTag? left, HashTag? right)

Parameters

left HashTag?
right HashTag?

Returns

bool

operator !=(HashTag?, HashTag?)

public static bool operator !=(HashTag? left, HashTag? right)

Parameters

left HashTag?
right HashTag?

Returns

bool

operator !=(HashTag?, HashTag?)

public static bool operator !=(HashTag? left, HashTag? right)

Parameters

left HashTag?
right HashTag?

Returns

bool