X-Git-Url: http://gitweb.michael.orlitzky.com/?a=blobdiff_plain;f=src%2FOptionalConfiguration.hs;h=49355f2de743dfcdbc887606df408488ba73e60a;hb=e3272460a03b4bdded1902467310a4190feb333f;hp=213f20363ae6fe822fa097f0ca3103f94cb72266;hpb=ef96e8bf0cadf5d602022f8c91914d3cabeb35a0;p=dead%2Fhtsn-import.git diff --git a/src/OptionalConfiguration.hs b/src/OptionalConfiguration.hs index 213f203..49355f2 100644 --- a/src/OptionalConfiguration.hs +++ b/src/OptionalConfiguration.hs @@ -15,6 +15,7 @@ module OptionalConfiguration ( merge_maybes ) where +-- System imports. import qualified Data.Configurator as DC ( Worth(Optional), load, @@ -33,6 +34,7 @@ import System.IO.Error ( catchIOError ) import System.Log ( Priority(..) ) import Text.Read ( readMaybe ) +-- Local imports. import Backend ( Backend(..) ) import ConnectionString ( ConnectionString ) import Network.Services.TSN.Report ( report_error ) @@ -44,10 +46,10 @@ import Network.Services.TSN.Report ( report_error ) deriving instance Data Priority deriving instance Typeable Priority --- | The same as Configuration, except everything is optional. It's easy to --- merge two of these by simply dropping the Nothings in favor of --- the Justs. The 'feed_hosts' are left un-maybed so that cmdargs --- can parse more than one of them. +-- | The same as 'Configuration', except everything is optional. It's +-- easy to merge two of these by simply dropping the 'Nothing's in +-- favor of the 'Just's. The 'xml_files' are left un-maybed so that +-- cmdargs can parse more than one of them. -- data OptionalConfiguration = OptionalConfiguration { @@ -71,8 +73,8 @@ merge_maybes Nothing (Just x) = Just x merge_maybes (Just _) (Just y) = Just y --- | The Monoid instance for these lets us "combine" two --- OptionalConfigurations. The "combine" operation that we'd like to +-- | The Monoid instance for these lets us \"combine\" two +-- OptionalConfigurations. The \"combine\" operation that we'd like to -- perform is, essentially, to mash them together. So if we have two -- OptionalConfigurations, each half full, we could combine them -- into one big one.