Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface ConfigStub

Different hooks into ConfigFile used for testing instead of doing file IO.

Hierarchy

  • ConfigStub

Index

Properties

Optional contents

contents: ConfigContents

The contents that are used when @{link ConfigFile.read} unless retrieveContents is set. This will also contain the new config when @{link ConfigFile.write} is called. This will persist through config instances, such as {@link Alias.update} and {@link Alias.fetch}.

Optional readFn

readFn: undefined | function

readFn A function that controls all aspect of ConfigFile.read. For example, it won't set the contents unless explicitly done. Only use this if you know what you are doing. Use retrieveContents instead.

Optional retrieveContents

retrieveContents: undefined | function

A function to conditionally read based on the config instance. The this value will be the config instance.

Optional updateContents

updateContents: undefined | function

A function to conditionally set based on the config instance. The this value will be the config instance.

Optional writeFn

writeFn: undefined | function

A function that controls all aspects of ConfigFile.write. For example, it won't read the contents unless explicitly done. Only use this if you know what you are doing. Use updateContents instead.