activitystreams-aeson 0.2.0.0 → 0.2.0.1
raw patch · 3 files changed
+12/−12 lines, 3 filesdep +timedep −datetime
Dependencies added: time
Dependencies removed: datetime
Files
- Codec/ActivityStream/Representation.hs +6/−6
- Codec/ActivityStream/Schema.hs +4/−4
- activitystreams-aeson.cabal +2/−2
Codec/ActivityStream/Representation.hs view
@@ -84,7 +84,7 @@ , fromJSON ) import qualified Data.Aeson as A-import Data.DateTime (DateTime)+import Data.Time.Clock (UTCTime) import qualified Data.HashMap.Strict as HM import Data.Text (Text) @@ -233,7 +233,7 @@ -- | The date and time at which the object was published. An object MAY -- contain a @published@ property.-oPublished :: Lens' Object (Maybe DateTime)+oPublished :: Lens' Object (Maybe UTCTime) oPublished = makeAesonLensMb "published" oRest -- | Natural-language summarization of the object encoded as a single@@ -244,7 +244,7 @@ -- | The date and time at which a previously published object has been -- modified. An Object MAY contain an @updated@ property.-oUpdated :: Lens' Object (Maybe DateTime)+oUpdated :: Lens' Object (Maybe UTCTime) oUpdated = makeAesonLensMb "updated" oRest -- | A JSON Array of one or more absolute IRI's@@ -333,7 +333,7 @@ -- | The date and time at which the activity was published. An activity -- MUST contain a @published@ property.-acPublished :: Lens' Activity DateTime+acPublished :: Lens' Activity UTCTime acPublished = makeAesonLens "published" acRest -- | Describes the application that published the activity. Note that this@@ -362,7 +362,7 @@ -- | The date and time at which a previously published activity has -- been modified. An Activity MAY contain an @updated@ property.-acUpdated :: Lens' Activity (Maybe DateTime)+acUpdated :: Lens' Activity (Maybe UTCTime) acUpdated = makeAesonLensMb "updated" acRest -- | An IRI <http://www.ietf.org/rfc/rfc3987.txt RFC3987>@@ -384,7 +384,7 @@ -- | Create an @Activity@ with an @actor@, @published@, and -- @provider@ property.-makeActivity :: Object -> DateTime -> Activity+makeActivity :: Object -> UTCTime -> Activity makeActivity actor published = Activity $ HM.insert "actor" (toJSON actor) $ HM.insert "published" (toJSON published)
Codec/ActivityStream/Schema.hs view
@@ -88,7 +88,7 @@ import qualified Data.Aeson as Aeson import Data.Aeson.TH (deriveJSON)-import Data.DateTime (DateTime)+import Data.Time.Clock (UTCTime) import Data.Aeson ( FromJSON(..), ToJSON(..) ) import qualified Data.HashMap.Strict as HM import Data.Text (Text)@@ -698,7 +698,7 @@ -- | The date and time that the event ends represented as a String -- conforming to the "date-time" production in [RFC3339].-evEndTime :: Lens' Object (Maybe DateTime)+evEndTime :: Lens' Object (Maybe UTCTime) evEndTime = makeAesonLensMb "endTime" oRest -- | A collection object as defined in Section 3.5 of the JSON@@ -727,7 +727,7 @@ -- | The date and time that the event begins represented as a String -- confirming to the "date-time" production in RFC 3339.-evStartTime :: Lens' Object (Maybe DateTime)+evStartTime :: Lens' Object (Maybe UTCTime) evStartTime = makeAesonLensMb "startTime" oRest -- issue@@ -811,7 +811,7 @@ -- | A RFC 3339 date-time specifying the date and time by which the -- task is to be completed.-tsBy :: Lens' Object (Maybe DateTime)+tsBy :: Lens' Object (Maybe UTCTime) tsBy = makeAesonLensMb "by" oRest -- | An Activity Streams object describing the object of the task.
activitystreams-aeson.cabal view
@@ -1,5 +1,5 @@ name: activitystreams-aeson-version: 0.2.0.0+version: 0.2.0.1 synopsis: An interface to the ActivityStreams specification description: An interface to the <http://activitystrea.ms/ Activity Streams>@@ -32,6 +32,6 @@ build-depends: base >=4.7 && <4.8, aeson ==0.8.*, text >=1.1,- datetime ==0.2.*,+ time >=1.4, unordered-containers >=0.2.5 default-language: Haskell2010