Class AddressCommune
public record AddressCommune : IAddressCommune, IAddressState, IEquatable<AddressCommune>
- Inheritance
-
AddressCommune
- Implements
- Inherited Members
- Extension Methods
Constructors
AddressCommune()
public AddressCommune()
AddressCommune(AddressCommune)
[SetsRequiredMembers]
protected AddressCommune(AddressCommune original)
Parameters
originalAddressCommune
Properties
AddressPackageId
public int AddressPackageId { get; set; }
Property Value
CommuneId
public long CommuneId { get; set; }
Property Value
CommuneName
The name of the commune.
public required string CommuneName { get; set; }
Property Value
Country
The country to which this state belongs. The Country class encapsulates details like the country's name, its ISO codes, and other pertinent information.
public Country Country { get; set; }
Property Value
EqualityContract
protected virtual Type EqualityContract { get; }
Property Value
StateId
public int StateId { get; set; }
Property Value
StateName
The name of the state.
public required string StateName { get; set; }
Property Value
Methods
Equals(object?)
public override bool Equals(object? obj)
Parameters
objobject
Returns
Equals(AddressCommune?)
public virtual bool Equals(AddressCommune? other)
Parameters
otherAddressCommune
Returns
GetHashCode()
public override int GetHashCode()
Returns
PrintMembers(StringBuilder)
protected virtual bool PrintMembers(StringBuilder builder)
Parameters
builderStringBuilder
Returns
ToString()
public override string ToString()
Returns
ToString(string, string?)
Returns a string that represents the current address based on the specified format.
public string ToString(string format, string? houseNumber = null)
Parameters
formatstringUse "s" for short, the "l" format (long) includes additional address components. "td" is also available for "top-down".
houseNumberstringPlace the house number inside the address, if applicable.
Returns
- string
A string containing the address components based on the specified format.
Operators
operator ==(AddressCommune?, AddressCommune?)
public static bool operator ==(AddressCommune? left, AddressCommune? right)
Parameters
leftAddressCommunerightAddressCommune
Returns
operator !=(AddressCommune?, AddressCommune?)
public static bool operator !=(AddressCommune? left, AddressCommune? right)
Parameters
leftAddressCommunerightAddressCommune