Tabnine Logo
OpenSshConfigFile$State
Code IndexAdd Tabnine to your IDE (free)

How to use
OpenSshConfigFile$State
in
org.eclipse.jgit.internal.transport.ssh

Best Java code snippets using org.eclipse.jgit.internal.transport.ssh.OpenSshConfigFile$State (Showing top 4 results out of 315)

origin: org.eclipse.jgit/org.eclipse.jgit

private synchronized State refresh() {
  final long mtime = configFile.lastModified();
  if (mtime != lastModified) {
    State newState = new State();
    try (BufferedReader br = Files
        .newBufferedReader(configFile.toPath(), UTF_8)) {
      newState.entries = parse(br);
    } catch (IOException | RuntimeException none) {
      // Ignore -- we'll set and return an empty state
    }
    lastModified = mtime;
    state = newState;
  }
  return state;
}
origin: berlam/github-bucket

/**
 * Creates a new {@link OpenSshConfigFile} that will read the config from
 * file {@code config} use the given file {@code home} as "home" directory.
 *
 * @param home
 *            user's home directory for the purpose of ~ replacement
 * @param config
 *            file to load.
 * @param localUserName
 *            user name of the current user on the local host OS
 */
public OpenSshConfigFile(@NonNull File home, @NonNull File config,
    @NonNull String localUserName) {
  this.home = home;
  this.configFile = config;
  this.localUserName = localUserName;
  state = new State();
}
origin: berlam/github-bucket

private synchronized State refresh() {
  final long mtime = configFile.lastModified();
  if (mtime != lastModified) {
    State newState = new State();
    try (BufferedReader br = Files
        .newBufferedReader(configFile.toPath(), UTF_8)) {
      newState.entries = parse(br);
    } catch (IOException | RuntimeException none) {
      // Ignore -- we'll set and return an empty state
    }
    lastModified = mtime;
    state = newState;
  }
  return state;
}
origin: org.eclipse.jgit/org.eclipse.jgit

/**
 * Creates a new {@link OpenSshConfigFile} that will read the config from
 * file {@code config} use the given file {@code home} as "home" directory.
 *
 * @param home
 *            user's home directory for the purpose of ~ replacement
 * @param config
 *            file to load.
 * @param localUserName
 *            user name of the current user on the local host OS
 */
public OpenSshConfigFile(@NonNull File home, @NonNull File config,
    @NonNull String localUserName) {
  this.home = home;
  this.configFile = config;
  this.localUserName = localUserName;
  state = new State();
}
org.eclipse.jgit.internal.transport.sshOpenSshConfigFile$State

Javadoc

Encapsulates entries read out of the configuration file, and a cache of fully resolved entries created from that.

Most used methods

  • <init>

Popular in Java

  • Finding current android device location
  • scheduleAtFixedRate (ScheduledExecutorService)
  • scheduleAtFixedRate (Timer)
  • notifyDataSetChanged (ArrayAdapter)
  • Runnable (java.lang)
    Represents a command that can be executed. Often used to run code in a different Thread.
  • Collection (java.util)
    Collection is the root of the collection hierarchy. It defines operations on data collections and t
  • Dictionary (java.util)
    Note: Do not use this class since it is obsolete. Please use the Map interface for new implementatio
  • Enumeration (java.util)
    A legacy iteration interface.New code should use Iterator instead. Iterator replaces the enumeration
  • Handler (java.util.logging)
    A Handler object accepts a logging request and exports the desired messages to a target, for example
  • Runner (org.openjdk.jmh.runner)
  • Top plugins for WebStorm
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now