# Class SpartanUtil

java.lang.Object
org.jmol.adapter.readers.spartan.SpartanUtil

public class SpartanUtil extends Object
A class to isolate Spartan file reading methods from the rest of Jmol. Two public methods: getFileList and getData

## Field Summary

Fields
Modifier and Type
Field
Description
`FileManager`
`fm`

## Constructor Summary

Constructors
Constructor
Description
`SpartanUtil()`

## Method Summary

Modifier and Type
Method
Description
`SB`
`getData(InputStream is, String[] zipDirectory)`
called by SmarterJmolAdapter via JmolUtil to open a Spartan directory and get all the needed data as a string.
`Object`
`getFileList(String name, boolean isTypeCheckOnly)`
get a complete critical file list for a spartan file Mac directory based on file extension ".spardir.zip" or ".spardir"
`SpartanUtil`
`set(FileManager fm)`

### Methods inherited from class Object

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

## Field Details

### fm

public FileManager fm

## Constructor Details

### SpartanUtil

public SpartanUtil()

## Method Details

### set

public SpartanUtil set(FileManager fm)

### getFileList

public Object getFileList(String name, boolean isTypeCheckOnly)
get a complete critical file list for a spartan file Mac directory based on file extension ".spardir.zip" or ".spardir"

Parameters:
  `name` -
  `isTypeCheckOnly` -
Returns:
  critical files list if just checking type or a buffered reader for a String containing all data

### getData

public SB getData(InputStream is, String[] zipDirectory)
called by SmarterJmolAdapter via JmolUtil to open a Spartan directory and get all the needed data as a string.

Parameters:
  `is` -
  `zipDirectory` -
Returns:
  String data for processing