Commit b69b39c5 authored by Mart Lubbers's avatar Mart Lubbers

Change iworld timestamp to timespec

For this I had to change all functions depending on the iworld timestamp
directly. Tasks using the share will still work.
parent 15f94f70
......@@ -9,6 +9,7 @@ from StdList import ++, iterate, take
from Data.Maybe import :: Maybe
from System.FilePath import :: FilePath
from Internet.HTTP import :: HTTPRequest
from System.Time import :: Timespec
import iTasks.WF.Definition
......@@ -18,8 +19,8 @@ import iTasks.WF.Definition
, appVersion :: String
, serverPort :: Int
, serverUrl :: String
, keepaliveTime :: Int
, sessionTime :: Int
, keepaliveTime :: Timespec
, sessionTime :: Timespec
, persistTasks :: Bool
, autoLayout :: Bool
, webDirPath :: FilePath // Location of public files that are served by the iTask webserver
......
......@@ -47,8 +47,8 @@ defaultEngineOptions world
, appVersion = appVersion
, serverPort = IF_POSIX_OR_WINDOWS 8080 80
, serverUrl = "http://localhost/"
, keepaliveTime = 300 // 5 minutes
, sessionTime = 60 // 1 minute, (the client pings every 10 seconds by default)
, keepaliveTime = {tv_sec=300,tv_nsec=0} // 5 minutes
, sessionTime = {tv_sec=60,tv_nsec=0} // 1 minute, (the client pings every 10 seconds by default)
, persistTasks = False
, autoLayout = True
, webDirPath = appDir </> appName +++ "-www"
......
......@@ -9,6 +9,7 @@ import iTasks.UI.Layout.Default
from iTasks.WF.Definition import :: InstanceProgress(..)
from iTasks.WF.Combinators.Core import :: TaskListItem(..)
import iTasks.Extensions.DateTime
import System.Time
gText{|User|} _ val = [maybe "" toString val]
......@@ -237,8 +238,8 @@ where
toView (_,[{TaskListItem|progress=Just p,attributes}:_]) =
{ assignedTo = mkAssignedTo attributes
, firstWorkedOn = fmap timestampToGmDateTime p.InstanceProgress.firstEvent
, lastWorkedOn = fmap timestampToGmDateTime p.InstanceProgress.lastEvent
, firstWorkedOn = fmap (timestampToGmDateTime o timespecToStamp) p.InstanceProgress.firstEvent
, lastWorkedOn = fmap (timestampToGmDateTime o timespecToStamp) p.InstanceProgress.lastEvent
, taskStatus = case p.InstanceProgress.value of
Unstable -> "In progres..."
Stable -> "Task done"
......
......@@ -35,10 +35,10 @@ where
html (URL url) = ATag [HrefAttr url] [Text url]
KEEPALIVE_TIME :== 5
KEEPALIVE_TIME :== {tv_sec=5, tv_nsec=0}
:: HttpConnState
= Idle String Timestamp
= Idle String Timespec
| ReadingRequest HttpReqState
| AwaitingResponse String Int Bool
......@@ -60,7 +60,7 @@ serveWebService port handler
@! ()
where
manageConnections io
= tcplisten port False (currentTimestamp |+< io)
= tcplisten port False (currentTimespec |+< io)
{ConnectionHandlers|onConnect=onConnect,onData=onData,onShareChange=onShareChange,onDisconnect=onDisconnect}
onConnect client_name (now,io)
......@@ -85,7 +85,7 @@ where
# reply = encodeResponse True response
= (Ok (Idle client_name now), Just io, [reply], keepalive)
onShareChange l=:(Idle client_name (Timestamp last)) (Timestamp now,_) //Close idle connections if the keepalive time passed
onShareChange l=:(Idle client_name last) (now,_) //Close idle connections if the keepalive time passed
= (Ok l, Nothing, [], now - last > KEEPALIVE_TIME)
onShareChange l (now,io)
......
......@@ -119,7 +119,7 @@ where
createClientIWorld :: !String !InstanceNo -> *IWorld
createClientIWorld serverURL currentInstance
# world = newWorld
# (timestamp=:(Timestamp seed),world) = time world
# (timestamp=:{tv_sec=seed},world) = nsTime world
= {IWorld
|options = { appName = "application"
, appPath = locundef "appDirectory"
......
......@@ -26,10 +26,10 @@ timeout iworld = case read taskEvents iworld of //Check if there are events in t
updateClock :: !*IWorld -> *(!MaybeError TaskException (), !*IWorld)
updateClock iworld=:{IWorld|clock,world}
//Determine current date and time
# (timestamp,world) = time world
# (timespec,world) = nsTime world
# iworld = {iworld & world = world}
//Write SDS if necessary
# (mbe,iworld) = if (timestamp == clock) (Ok (),iworld) (write timestamp iworldTimestamp iworld)
# (mbe,iworld) = write timespec iworldTimespec iworld
| mbe =:(Error _) = (mbe,iworld)
= (Ok (),iworld)
......@@ -46,17 +46,16 @@ where
(Ok (),iworld) = checkAll f xs iworld
(Error e,iworld) = (Error e,iworld)
removeIfOutdated (instanceNo,_,_,_) iworld=:{options={appVersion},clock}
removeIfOutdated (instanceNo,_,_,_) iworld=:{options={appVersion},clock=tNow}
# (remove,iworld) = case read (sdsFocus instanceNo taskInstanceIO) iworld of
//If there is I/O information, we check that age first
(Ok (Just (client,Timestamp tInstance)),iworld) //No IO for too long, clean up
(Ok (Just (client,tInstance)),iworld) //No IO for too long, clean up
= (Ok ((tNow - tInstance) > options.EngineOptions.sessionTime),iworld)
//If there is no I/O information, get meta-data and check builtId and creation date
(Ok Nothing,iworld)
= case read (sdsFocus instanceNo taskInstanceConstants) iworld of
(Ok {InstanceConstants|build,issuedAt},iworld)
(Ok {InstanceConstants|build,issuedAt=tInstance},iworld)
| build <> appVersion = (Ok True,iworld)
# (Timestamp tInstance) = issuedAt
| (tNow - tInstance) > options.EngineOptions.sessionTime = (Ok True,iworld)
= (Ok False,iworld)
(Error e,iworld)
......@@ -74,8 +73,6 @@ where
= (Ok (), iworld)
(Error e)
= (Error e,iworld)
where
(Timestamp tNow) = clock
//When the event queue is empty, write deferred SDS's
flushWritesWhenIdle:: !*IWorld -> (!MaybeError TaskException (), !*IWorld)
......
......@@ -11,7 +11,7 @@ generic gDefault a :: a
derive gDefault UNIT, PAIR, EITHER, CONS, OBJECT, RECORD, FIELD
derive gDefault Int, Real, Char, Bool, String, [], (), (,), (,,), (,,,), (,,,,), (,,,,,), (,,,,,,), (,,,,,,,), (->), Dynamic
derive gDefault Maybe, Either, MaybeError, Map, JSONNode, HtmlTag, Timestamp
derive gDefault Maybe, Either, MaybeError, Map, JSONNode, HtmlTag, Timestamp, Timespec
from Text.JSON import :: JSONNode
from Text.HTML import :: HtmlTag
......@@ -19,7 +19,7 @@ from Data.Maybe import :: Maybe
from Data.Either import :: Either
from Data.Error import :: MaybeError
from Data.Map import :: Map
from System.Time import :: Timestamp
from System.Time import :: Timestamp, :: Timespec
// Wrapper functions for updating
defaultValue :: a | gDefault{|*|} a
......@@ -35,7 +35,7 @@ gDefault{|HtmlTag|} = Html ""
gDefault{|Map|} fa fb = newMap
//SCARY BUG: When 'Map' is derived programs segfault when used in 'update' task on a shared source
derive gDefault Either, MaybeError, /*Map,*/ JSONNode, Timestamp
derive gDefault Either, MaybeError, /*Map,*/ JSONNode, Timestamp, Timespec
defaultValue :: a | gDefault{|*|} a
defaultValue = gDefault{|*|}
......@@ -7,7 +7,7 @@ from Data.Maybe import :: Maybe
from Data.Either import :: Either
from Data.Error import :: MaybeError
from Data.Map import :: Map
from System.Time import :: Timestamp
from System.Time import :: Timestamp, :: Timespec
:: TextFormat
= AsSingleLine //A single line of text
......@@ -22,7 +22,7 @@ generic gText a :: !TextFormat (Maybe a) -> [String]
//Default available instances
derive gText UNIT, PAIR, EITHER, CONS of {gcd_name,gcd_type_def}, OBJECT, RECORD, FIELD of {gfd_name}
derive gText Int, Real, Char, Bool, String, [], (), (,), (,,), (,,,), (,,,,), (,,,,,), (,,,,,,), (,,,,,,,), (->), Dynamic
derive gText Maybe, Either, MaybeError, Map, JSONNode, HtmlTag, Timestamp
derive gText Maybe, Either, MaybeError, Map, JSONNode, HtmlTag, Timestamp, Timespec
//Wrapper functions for visualization
toSingleLineText :: !a -> String | gText{|*|} a
......
......@@ -102,7 +102,7 @@ gText{|(,,,,,,,)|} fa fb fc fd fe ff fg fh AsRow (Just (a,b,c,d,e,f,g,h))
gText{|(,,,,,,,)|} fa fb fc fd fe ff fg fh AsSingleLine (Just (a,b,c,d,e,f,g,h)) = [concat (fa AsSingleLine (Just a)),", ",concat (fb AsSingleLine (Just b)),", ",concat (fc AsSingleLine (Just c)),", ",concat (fd AsSingleLine (Just d)),", ",concat (fe AsSingleLine (Just e)),", ",concat (ff AsSingleLine (Just f)),", ",concat (fg AsSingleLine (Just g)),", ",concat (fh AsSingleLine (Just h))]
gText{|(,,,,,,,)|} fa fb fc fd fe ff fg fh mode (Just (a,b,c,d,e,f,g,h)) = fa mode (Just a) ++ fb mode (Just b) ++ fc mode (Just c) ++ fd mode (Just d) ++ fe mode (Just e) ++ ff mode (Just f) ++ fg mode (Just g) ++ fh mode (Just h)
derive gText Either, MaybeError, Timestamp, Map
derive gText Either, MaybeError, Timestamp, Map, Timespec
//Utility function for visualizing record fields
camelCaseToWords label = {c \\ c <- [toUpper lname : addspace lnames]}
......
......@@ -7,7 +7,7 @@ from Data.Error import :: MaybeError(..), :: MaybeErrorString(..)
from Data.Set import :: Set
from Data.Queue import :: Queue
from StdFile import class FileSystem
from System.Time import :: Timestamp
from System.Time import :: Timestamp, :: Timespec
from Text.JSON import :: JSONNode
from System.Process import :: ProcessHandle, :: ProcessIO
from iTasks.Engine import :: EngineOptions
......@@ -31,7 +31,7 @@ from TCPIP import :: TCP_Listener, :: TCP_Listener_, :: TCP_RChannel_, :: TCP_SC
CLEAN_HOME_VAR :== "CLEAN_HOME"
:: *IWorld = { options :: !EngineOptions // Engine configuration
, clock :: !Timestamp // Server side clock
, clock :: !Timespec // Server side clock
, current :: !TaskEvalState // Shared state during task evaluation
, random :: [Int] // Infinite random stream
......@@ -147,6 +147,7 @@ destroyIWorld :: !*IWorld -> *World
//Internally used clock share
// (UTC time can be derived from timestamp, local time requires *World to determine time zone)
iworldTimespec :: Shared Timespec
iworldTimestamp :: Shared Timestamp
iworldLocalDateTime :: ReadOnlyShared DateTime
......
......@@ -13,6 +13,8 @@ from iTasks.Internal.TaskEval import :: TaskTime
from iTasks.Engine import :: EngineOptions(..)
from System.Process import :: ProcessHandle, :: ProcessIO
import iTasks.SDS.Combinators.Common
from StdFile import class FileSystem(..)
from StdFile import instance FileSystem World
from StdFunc import const, o, seqList, :: St
......@@ -57,10 +59,10 @@ JS_COMPILER_EXCLUDES :==
createIWorld :: !EngineOptions !*World -> *IWorld
createIWorld options world
# (timestamp=:(Timestamp seed), world) = time world
# (ts=:{tv_nsec=seed}, world) = nsTime world
= {IWorld
|options = options
,clock = timestamp
,clock = ts
,current =
{TaskEvalState
|taskTime = 0
......@@ -113,12 +115,15 @@ determineAppPath world
destroyIWorld :: !*IWorld -> *World
destroyIWorld iworld=:{IWorld|world} = world
iworldTimestamp :: Shared Timestamp
iworldTimestamp = createReadWriteSDS "IWorld" "timestamp" read write
iworldTimespec :: Shared Timespec
iworldTimespec = createReadWriteSDS "IWorld" "timespec" read write
where
read _ iworld=:{IWorld|clock} = (Ok clock,iworld)
write _ timestamp iworld = (Ok (const True), {iworld & clock = timestamp})
iworldTimestamp :: Shared Timestamp
iworldTimestamp = mapReadWrite (timespecToStamp, const o Just o timestampToSpec) iworldTimespec
iworldLocalDateTime :: ReadOnlyShared DateTime
iworldLocalDateTime = SDSParallel (createReadOnlySDS \_ -> iworldLocalDateTime`) iworldTimestamp sdsPar
where
......@@ -132,8 +137,8 @@ where
}
iworldLocalDateTime` :: !*IWorld -> (!DateTime, !*IWorld)
iworldLocalDateTime` iworld=:{clock, world}
# (tm, world) = toLocalTime clock world
iworldLocalDateTime` iworld=:{clock={tv_sec}, world}
# (tm, world) = toLocalTime (Timestamp tv_sec) world
= (tmToDateTime tm, {iworld & world = world})
iworldResource :: (*Resource -> (Bool, *Resource)) *IWorld -> (*[*Resource], *IWorld)
......
......@@ -12,7 +12,6 @@ definition module iTasks.Internal.Store
from Text.JSON import generic JSONEncode, generic JSONDecode, :: JSONNode
from Data.Maybe import :: Maybe
from Data.Error import :: MaybeError, :: MaybeErrorString
from System.Time import :: Timestamp
from System.FilePath import :: FilePath
from iTasks.SDS.Definition import :: SDS, :: Shared, :: ReadWriteShared, :: RWShared
from iTasks.Internal.IWorld import :: IWorld
......
......@@ -27,7 +27,6 @@ import iTasks.SDS.Sources.Core
import iTasks.SDS.Sources.Store
import iTasks.SDS.Combinators.Core
import iTasks.SDS.Combinators.Common
from System.Time import :: Timestamp(..), instance < Timestamp, instance toInt Timestamp
from Data.Generics.GenEq import generic gEq
instance toString StoreReadError
......
......@@ -6,7 +6,6 @@ from TCPIP import class ChannelEnv, :: IPAddress, :: Timeout
from Internet.HTTP import :: HTTPRequest, :: HTTPResponse
from System.FilePath import :: FilePath
from System.Time import :: Timestamp
from System.Process import :: ProcessPtyOptions
from Data.Error import :: MaybeError
from iTasks.WF.Definition import :: TaskId
......
......@@ -13,7 +13,7 @@ from Data.Maybe import :: Maybe
from Data.Queue import :: Queue
from Data.Error import :: MaybeError
from Data.Either import :: Either
from System.Time import :: Timestamp
from System.Time import :: Timestamp, :: Timespec
derive JSONEncode TIMeta, TIReduct, TaskTree
derive JSONDecode TIMeta, TIReduct, TaskTree
......@@ -28,7 +28,7 @@ derive JSONDecode TIMeta, TIReduct, TaskTree
, listId :: !TaskId //Reference to parent tasklist
, session :: !Bool //Is this a session
, build :: !String //Application build version when the instance was created
, issuedAt :: !Timestamp
, issuedAt :: !Timespec
//Evaluation information
, progress :: !InstanceProgress
//Identification and classification information
......
......@@ -58,8 +58,8 @@ taskInstanceAttributes :: RWShared InstanceNo TaskAttributes TaskAttributes
topLevelTaskList :: RWShared TaskListFilter (!TaskId,![TaskListItem a]) [(!TaskId,!TaskAttributes)]
taskInstanceIO :: RWShared InstanceNo (Maybe (!String,!Timestamp)) (Maybe (!String,!Timestamp))
allInstanceIO :: RWShared () (Map InstanceNo (!String,!Timestamp)) (Map InstanceNo (!String,Timestamp))
taskInstanceIO :: RWShared InstanceNo (Maybe (!String,!Timespec)) (Maybe (!String,!Timespec))
allInstanceIO :: RWShared () (Map InstanceNo (!String,!Timespec)) (Map InstanceNo (!String,Timespec))
//=== Task instance input: ===
......
......@@ -63,7 +63,7 @@ taskInstanceIndex = sdsFocus "instances" rawTaskIndex
nextInstanceNo :: RWShared () Int Int
nextInstanceNo = sdsFocus "increment" rawTaskNoCounter
taskInstanceIO :: RWShared InstanceNo (Maybe (!String,!Timestamp)) (Maybe (!String,!Timestamp))
taskInstanceIO :: RWShared InstanceNo (Maybe (!String,!Timespec)) (Maybe (!String,!Timespec))
taskInstanceIO = sdsLens "taskInstanceIO" (const ()) (SDSRead read) (SDSWrite write) (SDSNotifyConst notify) allInstanceIO
where
read instanceNo m = Ok ('DM'.get instanceNo m)
......@@ -71,7 +71,7 @@ where
write instanceNo m Nothing = Ok (Just ('DM'.del instanceNo m))
notify instanceNo _ = (==) instanceNo
allInstanceIO :: RWShared () (Map InstanceNo (!String,!Timestamp)) (Map InstanceNo (!String,Timestamp))
allInstanceIO :: RWShared () (Map InstanceNo (!String,!Timespec)) (Map InstanceNo (!String,Timespec))
allInstanceIO = sdsFocus "io" rawInstanceIO
//Event queues of task instances
......
......@@ -14,7 +14,7 @@ toStubIWorld world
= {IWorld
|options = {EngineOptions|appName="STUB",appPath="./",appVersion="STUB",serverPort=80,serverUrl="/127.0.0.1:80/",keepaliveTime=0,sessionTime=0
,persistTasks=False,autoLayout=False,webDirPath="./STUB/",storeDirPath="./STUB/",tempDirPath="./STUB/",saplDirPath="./STUB"}
,clock = Timestamp 0
,clock = {tv_sec=0,tv_nsec=0}
,current ={TaskEvalState|taskTime= 0,taskInstance= 0,sessionInstance = Nothing,attachmentChain = [] ,nextTaskNo = 0}
,sdsNotifyRequests = [], memoryShares = 'DM'.newMap, readCache = 'DM'.newMap, writeCache = 'DM'.newMap, exposedShares = 'DM'.newMap
,jsCompilerState = Nothing ,shutdown = Nothing ,ioTasks = {done = [], todo = []},ioStates = 'DM'.newMap
......
......@@ -15,6 +15,7 @@ from iTasks.WF.Definition import :: InstanceNo
from Data.Queue import :: Queue
from Data.Maybe import :: Maybe
from Data.Map import :: Map
from System.Time import :: Timespec
:: ConnectionState :== (String, WebSockState,[(InstanceNo,String)])
......@@ -40,7 +41,7 @@ from Data.Map import :: Map
, onDisconnect :: !(HTTPRequest r ConnectionState *IWorld -> *(!Maybe w, !*IWorld)) // is called on disconnect
}
httpServer :: !Int !Int ![WebService r w] (RWShared () r w) -> ConnectionTask | TC r & TC w
httpServer :: !Int !Timespec ![WebService r w] (RWShared () r w) -> ConnectionTask | TC r & TC w
:: OutputQueues :== Map InstanceNo TaskOutput
......
......@@ -21,7 +21,7 @@ import Text.HTML
from iTasks.Internal.HttpUtil import http_addRequestData, http_parseArguments
:: NetTaskState
= NTIdle String Timestamp
= NTIdle String Timespec
| NTReadingRequest HttpReqState
| NTProcessingRequest HTTPRequest ConnectionState
......@@ -129,7 +129,7 @@ where
wsockTextMsg :: String -> [String]
wsockTextMsg payload = [wsockMsgFrame WS_OP_TEXT True payload]
httpServer :: !Int !Int ![WebService r w] (RWShared () r w) -> ConnectionTask | TC r & TC w
httpServer :: !Int !Timespec ![WebService r w] (RWShared () r w) -> ConnectionTask | TC r & TC w
httpServer port keepAliveTime requestProcessHandlers sds
= wrapIWorldConnectionTask {ConnectionHandlersIWorld|onConnect=onConnect, onData=onData, onShareChange=onShareChange, onTick=onTick, onDisconnect=onDisconnect} sds
where
......@@ -195,7 +195,7 @@ where
= (Ok (NTReadingRequest rstate), Nothing, [], False, iworld)
//Close idle connections if the keepalive time has passed
onTick connState=:(NTIdle ip (Timestamp t)) r iworld=:{IWorld|clock=Timestamp now}
onTick connState=:(NTIdle ip t) r iworld=:{IWorld|clock=now}
= (Ok connState, Nothing, [], now >= t + keepAliveTime, iworld)
onTick connState=:(NTProcessingRequest request localState) r env
......
......@@ -9,7 +9,7 @@ from iTasks.WF.Combinators.Core import :: TaskList, :: SharedTaskList, :: TaskLi
from iTasks.Extensions.DateTime import :: DateTime, :: Date, :: Time
from iTasks.Engine import :: EngineOptions
from System.Time import :: Timestamp
from System.Time import :: Timespec, :: Timestamp
from System.FilePath import :: FilePath
from Data.Map import :: Map
from Data.Maybe import :: Maybe
......@@ -21,11 +21,11 @@ from Data.Maybe import :: Maybe
, session :: !Bool //* Is this a session
, listId :: !TaskId //* Reference to parent tasklist
, build :: !String //* Application build version when the instance was created
, issuedAt :: !Timestamp //* When was the task created
, issuedAt :: !Timespec //* When was the task created
, attributes :: !TaskAttributes //* Arbitrary meta-data
, value :: !ValueStatus //* Status of the task value
, firstEvent :: !Maybe Timestamp //*When was the first work done on this task
, lastEvent :: !Maybe Timestamp //* When was the last event on this task
, firstEvent :: !Maybe Timespec //*When was the first work done on this task
, lastEvent :: !Maybe Timespec //* When was the last event on this task
}
// Date & time (in task server's local timezone)
......@@ -40,6 +40,7 @@ currentUTCDate :: SDS () Date ()
//Unix timestamp
currentTimestamp :: SDS () Timestamp ()
currentTimespec :: SDS () Timespec ()
// Processes
topLevelTasks :: SharedTaskList ()
......
......@@ -39,6 +39,9 @@ currentUTCDate = mapRead (toDate o timestampToGmDateTime) currentTimestamp
currentTimestamp :: SDS () Timestamp ()
currentTimestamp = toReadOnly iworldTimestamp
currentTimespec :: SDS () Timespec ()
currentTimespec = toReadOnly iworldTimespec
// Workflow processes
topLevelTasks :: SharedTaskList ()
......
......@@ -12,7 +12,7 @@ from Data.Maybe import :: Maybe
from Data.Map import :: Map(..)
from Data.Set import :: Set
from Data.Functor import class Functor
from System.Time import :: Timestamp
from System.Time import :: Timestamp, :: Timespec
from iTasks.UI.Editor import :: Editor
from iTasks.UI.Editor.Generic import generic gEditor
......@@ -83,15 +83,15 @@ instance toInstanceNo TaskId
{ listId :: !TaskId //* Reference to parent tasklist
, session :: !Bool //* True for sessions (instances that automatically get garbage collected)
, build :: !String //* Application build version when the instance was created
, issuedAt :: !Timestamp //* When was the task created
, issuedAt :: !Timespec //* When was the task created
}
:: InstanceProgress =
{ value :: !ValueStatus //* Status of the task value
, attachedTo :: ![TaskId] //* Chain of tasks through which this instance was attached
, instanceKey :: !InstanceKey //* Random token that a client gets to have (temporary) access to the task instance
, firstEvent :: !Maybe Timestamp //* When was the first work done on this task
, lastEvent :: !Maybe Timestamp //* When was the latest event on this task (excluding Refresh events)
, firstEvent :: !Maybe Timespec //* When was the first work done on this task
, lastEvent :: !Maybe Timespec //* When was the latest event on this task (excluding Refresh events)
}
:: ValueStatus
......
......@@ -3,6 +3,7 @@ implementation module iTasks.WF.Definition
from iTasks.Internal.IWorld import :: IWorld
from iTasks.Internal.TaskState import :: TaskTree
from iTasks.Internal.TaskEval import :: TaskEvalOpts, :: TaskEvalInfo
from System.Time import :: Timestamp, :: Timespec
import iTasks.UI.Definition
import iTasks.UI.Editor
import iTasks.UI.Editor.Generic
......@@ -11,7 +12,6 @@ from Text.JSON import :: JSONNode
from Data.Map import :: Map(..)
from Data.Set import :: Set
from Data.Maybe import :: Maybe
from System.Time import :: Timestamp
import Data.Functor
import Text, Text.JSON
......
......@@ -10,7 +10,7 @@ from iTasks.SDS.Sources.System import :: TaskInstance
from Data.Either import :: Either
from Data.Error import :: MaybeError
from System.Time import :: Timestamp
from System.Time import :: Timestamp, :: Timespec
from Text.HTML import :: HtmlTag, :: HtmlAttr
from Text.HTML import :: SVGElt, :: SVGAttr, :: SVGAlign, :: SVGColor, :: SVGDefer, :: SVGFillOpacity, :: SVGFuncIRI, :: SVGLengthAdjust
......@@ -39,11 +39,11 @@ derive gText {}
//Common iTasks system types
derive class iTask TaskId, TaskListFilter, AttachmentStatus
derive JSONEncode TaskValue, TaskListItem, InstanceConstants, InstanceProgress, ValueStatus, TaskInstance, Action
derive JSONDecode TaskValue, TaskListItem, InstanceConstants, InstanceProgress, ValueStatus, TaskInstance, Action
derive JSONEncode TaskValue, TaskListItem, InstanceConstants, InstanceProgress, ValueStatus, TaskInstance, Action, Timespec
derive JSONDecode TaskValue, TaskListItem, InstanceConstants, InstanceProgress, ValueStatus, TaskInstance, Action, Timespec
derive gDefault TaskValue, TaskListItem, InstanceConstants, InstanceProgress, ValueStatus, TaskInstance, Action
derive gEq TaskValue, TaskListItem, InstanceConstants, InstanceProgress, ValueStatus, TaskInstance, Action
derive gEq TaskValue, TaskListItem, InstanceConstants, InstanceProgress, ValueStatus, TaskInstance, Action, Timespec
derive gText TaskValue, TaskListItem, InstanceConstants, InstanceProgress, ValueStatus, TaskInstance, Action
derive gEditor TaskValue, TaskListItem, InstanceConstants, InstanceProgress, ValueStatus, TaskInstance, Action
derive gEditor TaskValue, TaskListItem, InstanceConstants, InstanceProgress, ValueStatus, TaskInstance, Action, Timespec
......@@ -44,11 +44,11 @@ derive gDefault HtmlAttr
derive gEditor HtmlAttr
derive gText HtmlAttr
derive JSONEncode TaskValue, InstanceConstants, InstanceProgress, ValueStatus, TaskInstance, TaskListItem, Action
derive JSONDecode TaskValue, InstanceConstants, InstanceProgress, ValueStatus, TaskInstance, TaskListItem, Action
derive JSONEncode TaskValue, InstanceConstants, InstanceProgress, ValueStatus, TaskInstance, TaskListItem, Action, Timespec
derive JSONDecode TaskValue, InstanceConstants, InstanceProgress, ValueStatus, TaskInstance, TaskListItem, Action, Timespec
derive gDefault TaskValue, InstanceConstants, InstanceProgress, ValueStatus, TaskInstance, TaskListItem, Action
derive gEq TaskValue, InstanceConstants, InstanceProgress, ValueStatus, TaskInstance, TaskListItem, Action
derive gEq TaskValue, InstanceConstants, InstanceProgress, ValueStatus, TaskInstance, TaskListItem, Action, Timespec
derive gText TaskValue, InstanceConstants, InstanceProgress, ValueStatus, TaskInstance, TaskListItem, Action
derive gEditor TaskValue, InstanceConstants, InstanceProgress, ValueStatus, TaskInstance, TaskListItem, Action
derive gEditor TaskValue, InstanceConstants, InstanceProgress, ValueStatus, TaskInstance, TaskListItem, Action, Timespec
derive class iTask TaskId, TaskListFilter, AttachmentStatus
......@@ -3,7 +3,6 @@ implementation module iTasks.WF.Tasks.Interaction
from StdFunc import id, const, o, flip
from Data.Tuple import appSnd
from Data.List import isMemberGen, findIndex, instance Functor [], getItems
from System.Time import :: Timestamp(..)
from Data.Map import qualified get, put
import StdBool, StdList, StdMisc, StdTuple, Data.Functor
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment