Show / Hide Table of Contents

    Struct KeyValuePair<K, V>

    An entry in a dictionary from K to V.

    Implements
    IEquatable<KeyValuePair<K, V>>
    IShowable
    IFormattable
    Namespace: Lucene.Net.Support.C5
    Assembly: Lucene.Net.dll
    Syntax
    public struct KeyValuePair<K, V> : IEquatable<KeyValuePair<K, V>>, IShowable, IFormattable
    Type Parameters
    Name Description
    K
    V

    Constructors

    | Improve this Doc View Source

    KeyValuePair(K)

    Create an entry with a specified key. The value will be the default value of type

    V
    .

    Declaration
    public KeyValuePair(K key)
    Parameters
    Type Name Description
    K key

    The key

    | Improve this Doc View Source

    KeyValuePair(K, V)

    Create an entry with specified key and value

    Declaration
    public KeyValuePair(K key, V value)
    Parameters
    Type Name Description
    K key

    The key

    V value

    The value

    Fields

    | Improve this Doc View Source

    Key

    The key field of the entry

    Declaration
    public K Key
    Field Value
    Type Description
    K
    | Improve this Doc View Source

    Value

    The value field of the entry

    Declaration
    public V Value
    Field Value
    Type Description
    V

    Methods

    | Improve this Doc View Source

    Equals(KeyValuePair<K, V>)

    Declaration
    public bool Equals(KeyValuePair<K, V> other)
    Parameters
    Type Name Description
    KeyValuePair<K, V> other
    Returns
    Type Description
    System.Boolean
    | Improve this Doc View Source

    Equals(Object)

    Check equality of entries.

    Declaration
    public override bool Equals(object obj)
    Parameters
    Type Name Description
    System.Object obj

    The other object

    Returns
    Type Description
    System.Boolean

    True if obj is an entry of the same type and has the same key and value

    | Improve this Doc View Source

    GetHashCode()

    Get the hash code of the pair.

    Declaration
    public override int GetHashCode()
    Returns
    Type Description
    System.Int32

    The hash code

    | Improve this Doc View Source

    Show(System.Text.StringBuilder, ref Int32, IFormatProvider)

    Declaration
    public bool Show(System.Text.StringBuilder stringbuilder, ref int rest, IFormatProvider formatProvider)
    Parameters
    Type Name Description
    System.Text.StringBuilder stringbuilder
    System.Int32 rest
    IFormatProvider formatProvider
    Returns
    Type Description
    System.Boolean
    | Improve this Doc View Source

    ToString()

    Pretty print an entry

    Declaration
    public override string ToString()
    Returns
    Type Description
    System.String

    (key, value)

    | Improve this Doc View Source

    ToString(String, IFormatProvider)

    Declaration
    public string ToString(string format, IFormatProvider formatProvider)
    Parameters
    Type Name Description
    System.String format
    IFormatProvider formatProvider
    Returns
    Type Description
    System.String

    Operators

    | Improve this Doc View Source

    Equality(KeyValuePair<K, V>, KeyValuePair<K, V>)

    Declaration
    public static bool operator ==(KeyValuePair<K, V> pair1, KeyValuePair<K, V> pair2)
    Parameters
    Type Name Description
    KeyValuePair<K, V> pair1
    KeyValuePair<K, V> pair2
    Returns
    Type Description
    System.Boolean
    | Improve this Doc View Source

    Inequality(KeyValuePair<K, V>, KeyValuePair<K, V>)

    Declaration
    public static bool operator !=(KeyValuePair<K, V> pair1, KeyValuePair<K, V> pair2)
    Parameters
    Type Name Description
    KeyValuePair<K, V> pair1
    KeyValuePair<K, V> pair2
    Returns
    Type Description
    System.Boolean

    Implements

    IEquatable<>
    IShowable
    IFormattable
    • Improve this Doc
    • View Source
    Back to top Copyright © 2020 Licensed to the Apache Software Foundation (ASF)