Interface SshConfigStore.HostConfig

  • All Known Implementing Classes:
    OpenSshConfigFile.HostEntry
    Enclosing interface:
    SshConfigStore

    public static interface SshConfigStore.HostConfig
    A host entry from the ssh config. Any merging of global values and of several matching host entries, %-substitutions, and ~ replacement have all been done.
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      java.util.Map<java.lang.String,​java.util.List<java.lang.String>> getMultiValuedOptions()
      Retrieves an unmodifiable map of all multi- or list-valued options, with case-insensitive lookup by keys.
      java.util.Map<java.lang.String,​java.lang.String> getOptions()
      Retrieves an unmodifiable map of all single-valued options, with case-insensitive lookup by keys.
      java.lang.String getValue​(java.lang.String key)
      Retrieves the value of a single-valued key, or the first if the key has multiple values.
      java.util.List<java.lang.String> getValues​(java.lang.String key)
      Retrieves the values of a multi- or list-valued key.
    • Method Detail

      • getValue

        java.lang.String getValue​(java.lang.String key)
        Retrieves the value of a single-valued key, or the first if the key has multiple values. Keys are case-insensitive, so getValue("HostName") == getValue("HOSTNAME").
        Parameters:
        key - to get the value of
        Returns:
        the value, or null if none
      • getValues

        java.util.List<java.lang.String> getValues​(java.lang.String key)
        Retrieves the values of a multi- or list-valued key. Keys are case-insensitive, so getValue("HostName") == getValue("HOSTNAME").
        Parameters:
        key - to get the values of
        Returns:
        a possibly empty list of values
      • getOptions

        @NonNull
        java.util.Map<java.lang.String,​java.lang.String> getOptions()
        Retrieves an unmodifiable map of all single-valued options, with case-insensitive lookup by keys.
        Returns:
        all single-valued options
      • getMultiValuedOptions

        @NonNull
        java.util.Map<java.lang.String,​java.util.List<java.lang.String>> getMultiValuedOptions()
        Retrieves an unmodifiable map of all multi- or list-valued options, with case-insensitive lookup by keys.
        Returns:
        all multi-valued options