X-Git-Url: https://git.martlubbers.net/?a=blobdiff_plain;f=Shares%2FmTaskShare.dcl;h=1d3866958258509aac70f383dabf4f2e3c71b51d;hb=7d9088b54956fe56c36ca8d01ec386b48f0a1c47;hp=9110254307403c02958ab64b4277785fb24c44e7;hpb=32ff545d18253da21f25c69c6d99b96f90668773;p=mTask.git diff --git a/Shares/mTaskShare.dcl b/Shares/mTaskShare.dcl index 9110254..1d38669 100644 --- a/Shares/mTaskShare.dcl +++ b/Shares/mTaskShare.dcl @@ -3,20 +3,34 @@ definition module Shares.mTaskShare import iTasks import iTasks._Framework.Serialization import mTask +import Devices.mTaskDevice -derive class iTask MTaskShareType, MTaskShare +derive class iTask MTaskShare -:: MTaskShareType = MTaskWithShare String | MTaskLens String :: MTaskShare = - {withTask :: String + {withTask :: [String] ,identifier :: Int - ,realShare :: MTaskShareType ,value :: BCValue } -manageShares :: [MTaskShare] -> Task () +//Constructor +makeShare :: String Int BCValue -> MTaskShare -///makeShare :: String Int Dynamic -> Task MTaskShare -makeShare :: String Int BCValue -> Task MTaskShare +//General viewing task +manageShares :: Task [MTaskDevice] +//manageShares :: [MTaskShare] -> Task MTaskShare -updateShare :: Int BCValue -> Task () +updateShares :: MTaskDevice ([MTaskShare] -> [MTaskShare]) -> Task [MTaskShare] + +//Clean out shares when a task has been removed +cleanSharesTask :: Int MTaskDevice -> Task [MTaskShare] +//cleanSharesTask :: Int MTaskDevice -> Task [MTaskShare] +//Clean out shares when a device has been removed + +updateShareFromPublish :: MTaskDevice Int BCValue -> Task [MTaskShare] +//updateShare :: Int BCValue -> Task [MTaskShare] + +getRealShare :: MTaskDevice MTaskShare -> Shared BCValue +//getRealShare :: MTaskDevice BCShare -> Shared BCValue + +//updateShare :: Int BCValue -> Task ()