# Class SeekableStreamFactory

java.lang.Object
htsjdk.samtools.seekablestream.SeekableStreamFactory

public class SeekableStreamFactory extends Object
Singleton class for getting `SeekableStream`s from URL/paths Applications using this library can set their own factory

## Field Summary

Fields
Modifier and Type
Field
Description
`static final String`
`FILE_SCHEME`

## Method Summary

Modifier and Type
Method
Description
`static boolean`
`canBeHandledByLegacyUrlSupport(String path)`
`static ISeekableStreamFactory`
`getInstance()`
`static boolean`
`isBeingHandledByLegacyUrlSupport(String path)`
is this path being handled by one of the legacy SeekableStream types (http(s) / ftp)
`static boolean`
`isFilePath(String path)`
Deprecated.
this method is simplistic and no longer particularly useful since IOPath allows similar access to various non-file data sources, internal use has been replaced with `isBeingHandledByLegacyUrlSupport(String)`
`static void`
`setInstance(ISeekableStreamFactory factory)`

### Methods inherited from class Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Field Details

### FILE_SCHEME

public static final String FILE_SCHEME

See Also:
  - Constant Field Values

## Method Details

### setInstance

public static void setInstance(ISeekableStreamFactory factory)

### getInstance

public static ISeekableStreamFactory getInstance()

### isFilePath

@Deprecated public static boolean isFilePath(String path)
Deprecated.
this method is simplistic and no longer particularly useful since IOPath allows similar access to various non-file data sources, internal use has been replaced with `isBeingHandledByLegacyUrlSupport(String)`
Does this path point to a regular file on disk and not something like a URL?

Parameters:
  `path` - the path to test
Returns:
  true if the path is to a file on disk

### isBeingHandledByLegacyUrlSupport

public static boolean isBeingHandledByLegacyUrlSupport(String path)
is this path being handled by one of the legacy SeekableStream types (http(s) / ftp)

Parameters:
  `path` - a path to check
Returns:
  if the path is not being handled by a FileSystemProvider and it can be read by legacy streams

### canBeHandledByLegacyUrlSupport

public static boolean canBeHandledByLegacyUrlSupport(String path)