# Path: ship/utils/utilfunctions.py
# def formatFloat(value, no_of_dps, ignore_empty_str=True):
# def checkFileType(file_path, ext):
# def isNumeric(s):
# def encodeStr(value):
# def isString(value):
# def isList(value):
# def arrayToString(self, str_array):
# def findSubstringInList(substr, the_list):
# def findMax(val1, val2):
# def fileExtensionWithoutPeriod(filepath, name_only=False):
# def findWholeWord(w):
# def convertRunOptionsToSEDict(options):
# def getSEResolvedFilename(filename, se_vals):
# def enum(*sequential, **named):
#     def __init__(self):
#     def isEmpty(self):
#     def enqueue(self, item):
#     def dequeue(self):
#     def size(self):
#     def __init__(self, max_size=-1):
#     def isEmpty(self):
#     def add(self, item):
#     def pop(self):
#     def peek(self):
#     def size(self):
# class FileQueue(object):
# class LoadStack(object):
# 
# Path: ship/utils/filetools.py
# def getFile(file_path):
# def writeFile(contents, file_path, add_newline=True):
# def finalFolder(path):
# def setFinalFolder(path, folder_name):
# def getFileName(in_path, with_extension=False):
# def directory(in_path):
#     def __init__(self, path, root=None):
#     def _setupVars(self, path):
#     def finalFolder(self):
#     def setFinalFolder(self, folder_name):
#     def absolutePath(self, filename=None, relative_roots=[], normalize=True):
#     def directory(self):
#     def relativePath(self, with_extension=True, filename=None):
#     def filenameAndExtension(self):
#     def setAbsolutePath(self, absolute_path, keep_relative_root=False):
#     def setFilename(self, filename, has_extension=False, keep_extension=False):
#     def pathExists(self, ext=None):
# class PathHolder(object):
#     ABSOLUTE, RELATIVE, DIRECTORY, NAME, EXTENSION, NAME_AND_EXTENSION = range(6)


import os
import logging
from ship.utils import utilfunctions as uf
from ship.utils import filetools as ft
            dictionary. To fix this a list of all valid keys should be created
            and checked here before setting the value. These are the keys used
            in the ief file.
        """
        headlist = ['Title', 'Path', 'Datafile', 'Results']
        if key in headlist:
            self.event_header[key] = value
        else:
            self.event_details[key] = value

    def addIedFile(self, ied_path, name=''):
        """Add a new ied file.

        Args:
            ied_path(str): path to an ied file.
            name=''(str): name for the ied file.
        """
        if self.ied_data is None:
            self.ied_data = []
        self.ied_data.append({'name': name, 'file': ied_path})

    def addSnapshot(self, snapshot_path, time):
        """Add a new snapshot.

        Args:
            snapshot_path(str): the path for the snapshot.
            time(float): the time to assign to the snapshot.
        """
        if self.snapshots is None:
            self.snapshots = []

# Path: ship/utils/utilfunctions.py
# def formatFloat(value, no_of_dps, ignore_empty_str=True):
# def checkFileType(file_path, ext):
# def isNumeric(s):
# def encodeStr(value):
# def isString(value):
# def isList(value):
# def arrayToString(self, str_array):
# def findSubstringInList(substr, the_list):
# def findMax(val1, val2):
# def fileExtensionWithoutPeriod(filepath, name_only=False):
# def findWholeWord(w):
# def convertRunOptionsToSEDict(options):
# def getSEResolvedFilename(filename, se_vals):
# def enum(*sequential, **named):
#     def __init__(self):
#     def isEmpty(self):
#     def enqueue(self, item):
#     def dequeue(self):
#     def size(self):
#     def __init__(self, max_size=-1):
#     def isEmpty(self):
#     def add(self, item):
#     def pop(self):
#     def peek(self):
#     def size(self):
# class FileQueue(object):
# class LoadStack(object):
# 
# Path: ship/utils/filetools.py
# def getFile(file_path):
# def writeFile(contents, file_path, add_newline=True):
# def finalFolder(path):
# def setFinalFolder(path, folder_name):
# def getFileName(in_path, with_extension=False):
# def directory(in_path):
#     def __init__(self, path, root=None):
#     def _setupVars(self, path):
#     def finalFolder(self):
#     def setFinalFolder(self, folder_name):
#     def absolutePath(self, filename=None, relative_roots=[], normalize=True):
#     def directory(self):
#     def relativePath(self, with_extension=True, filename=None):
#     def filenameAndExtension(self):
#     def setAbsolutePath(self, absolute_path, keep_relative_root=False):
#     def setFilename(self, filename, has_extension=False, keep_extension=False):
#     def pathExists(self, ext=None):
# class PathHolder(object):
#     ABSOLUTE, RELATIVE, DIRECTORY, NAME, EXTENSION, NAME_AND_EXTENSION = range(6)


# Path: ship/fmp/ief.py
import os
import logging
from ship.utils import utilfunctions as uf
from ship.utils import filetools as ft

            dictionary. To fix this a list of all valid keys should be created
            and checked here before setting the value. These are the keys used
            in the ief file.
        """
        headlist = ['Title', 'Path', 'Datafile', 'Results']
        if key in headlist:
            self.event_header[key] = value
        else:
            self.event_details[key] = value

    def addIedFile(self, ied_path, name=''):
        """Add a new ied file.

        Args:
            ied_path(str): path to an ied file.
            name=''(str): name for the ied file.
        """
        if self.ied_data is None:
            self.ied_data = []
        self.ied_data.append({'name': name, 'file': ied_path})

    def addSnapshot(self, snapshot_path, time):
        """Add a new snapshot.

        Args:
            snapshot_path(str): the path for the snapshot.
            time(float): the time to assign to the snapshot.
        """
        if self.snapshots is None:
            self.snapshots = []

        if not uf.isNumeric(time):