Table of Contents

Struct MessageBrokerExternalObject

Namespace
LfrlAnvil.MessageBroker.Client
Assembly
LfrlAnvil.MessageBroker.Client.dll

Represents basic information about a server-side message broker object.

public readonly struct MessageBrokerExternalObject : IEquatable<MessageBrokerExternalObject>
Implements
Inherited Members

Constructors

MessageBrokerExternalObject(int, string?)

Creates a new MessageBrokerExternalObject instance.

public MessageBrokerExternalObject(int id, string? name = null)

Parameters

id int

Unique object id.

name string

Optional object name. Equal to null by default.

Properties

Id

Unique object id.

public int Id { get; }

Property Value

int

Name

Optional object name.

public string? Name { get; }

Property Value

string

Methods

Equals(MessageBrokerExternalObject)

Indicates whether the current object is equal to another object of the same type.

[Pure]
public bool Equals(MessageBrokerExternalObject other)

Parameters

other MessageBrokerExternalObject

An object to compare with this object.

Returns

bool

true if the current object is equal to the other parameter; otherwise, false.

Equals(object?)

Indicates whether this instance and a specified object are equal.

[Pure]
public override bool Equals(object? obj)

Parameters

obj object

The object to compare with the current instance.

Returns

bool

true if obj and this instance are the same type and represent the same value; otherwise, false.

GetHashCode()

Returns the hash code for this instance.

[Pure]
public override int GetHashCode()

Returns

int

A 32-bit signed integer that is the hash code for this instance.

ToString()

Returns a string representation of this MessageBrokerExternalObject instance.

[Pure]
public override string ToString()

Returns

string

String representation.

Operators

operator ==(MessageBrokerExternalObject, MessageBrokerExternalObject)

Checks if a is equal to b.

[Pure]
public static bool operator ==(MessageBrokerExternalObject a, MessageBrokerExternalObject b)

Parameters

a MessageBrokerExternalObject

First operand.

b MessageBrokerExternalObject

Second operand.

Returns

bool

true when operands are equal, otherwise false.

operator !=(MessageBrokerExternalObject, MessageBrokerExternalObject)

Checks if a is not equal to b.

[Pure]
public static bool operator !=(MessageBrokerExternalObject a, MessageBrokerExternalObject b)

Parameters

a MessageBrokerExternalObject

First operand.

b MessageBrokerExternalObject

Second operand.

Returns

bool

true when operands are not equal, otherwise false.