Skip to content

Commit af3994f

Browse files
committed
Merge pull request #23 from cryogenian/aggregation
aggregation
2 parents 7ab9057 + 2e90b0c commit af3994f

20 files changed

+131
-2071
lines changed

bower.json

Lines changed: 5 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -7,27 +7,13 @@
77
],
88
"license": "MIT",
99
"dependencies": {
10-
"purescript-either": "^0.2.0",
11-
"purescript-tuples": "^0.4.0",
12-
"purescript-maps": "^0.4.0",
13-
"purescript-sets": "^0.4.0",
14-
"purescript-foldable-traversable": "^0.4.0",
15-
"purescript-strings": "^0.5.2",
16-
"purescript-arrays": "^0.4.0",
17-
"purescript-lists": "^0.7.0",
18-
"purescript-prelude": "^0.1.0",
19-
"purescript-globals": "^0.2.0",
20-
"purescript-control": "^0.3.0",
21-
"purescript-lens": "^0.8.0",
22-
"purescript-integers": "^0.2.0",
23-
"purescript-functions": "^0.1.0",
24-
"purescript-optics": "https://github.com/paf31/purescript-optic.git#0.7",
25-
"purescript-index": "https://github.com/paf31/purescript-index.git#0.7",
26-
"purescript-strongcheck": "^0.10.0",
27-
"purescript-unfoldable": "^0.4.0"
10+
"purescript-argonaut-traversals": "^0.1.0",
11+
"purescript-argonaut-core": "^0.1.0",
12+
"purescript-argonaut-codecs": "^0.1.0"
2813
},
2914
"devDependencies": {
30-
"purescript-console": "^0.1.0"
15+
"purescript-console": "^0.1.0",
16+
"purescript-strongcheck": "^0.10.0"
3117
},
3218
"resolutions": {
3319
"purescript-lens": "^0.8.0"

docs/Data/Argonaut/Core.md

Lines changed: 8 additions & 92 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ data JNull :: *
4646
``` purescript
4747
instance eqJNull :: Eq JNull
4848
instance ordJNull :: Ord JNull
49-
instance showJsonNull :: Show JNull
49+
instance showJNull :: Show JNull
5050
```
5151

5252
#### `Json`
@@ -57,9 +57,9 @@ data Json :: *
5757

5858
##### Instances
5959
``` purescript
60-
instance showJson :: Show Json
6160
instance eqJson :: Eq Json
6261
instance ordJson :: Ord Json
62+
instance showJson :: Show Json
6363
```
6464

6565
#### `foldJson`
@@ -104,12 +104,6 @@ foldJsonArray :: forall a. a -> (JArray -> a) -> Json -> a
104104
foldJsonObject :: forall a. a -> (JObject -> a) -> Json -> a
105105
```
106106

107-
#### `isJsonType`
108-
109-
``` purescript
110-
isJsonType :: forall a. (Boolean -> (a -> Boolean) -> Json -> Boolean) -> Json -> Boolean
111-
```
112-
113107
#### `isNull`
114108

115109
``` purescript
@@ -218,6 +212,12 @@ fromArray :: JArray -> Json
218212
fromObject :: JObject -> Json
219213
```
220214

215+
#### `jsonNull`
216+
217+
``` purescript
218+
jsonNull :: Json
219+
```
220+
221221
#### `jsonTrue`
222222

223223
``` purescript
@@ -236,18 +236,6 @@ jsonFalse :: Json
236236
jsonZero :: Json
237237
```
238238

239-
#### `jsonNull`
240-
241-
``` purescript
242-
jsonNull :: Json
243-
```
244-
245-
#### `jsonEmptyString`
246-
247-
``` purescript
248-
jsonEmptyString :: Json
249-
```
250-
251239
#### `jsonEmptyArray`
252240

253241
``` purescript
@@ -272,76 +260,4 @@ jsonSingletonArray :: Json -> Json
272260
jsonSingletonObject :: String -> Json -> Json
273261
```
274262

275-
#### `nullL`
276-
277-
``` purescript
278-
nullL :: PrismP Json JNull
279-
```
280-
281-
#### `booleanL`
282-
283-
``` purescript
284-
booleanL :: PrismP Json JBoolean
285-
```
286-
287-
#### `numberL`
288-
289-
``` purescript
290-
numberL :: PrismP Json JNumber
291-
```
292-
293-
#### `stringL`
294-
295-
``` purescript
296-
stringL :: PrismP Json JString
297-
```
298-
299-
#### `arrayL`
300-
301-
``` purescript
302-
arrayL :: PrismP Json JArray
303-
```
304-
305-
#### `objectL`
306-
307-
``` purescript
308-
objectL :: PrismP Json JObject
309-
```
310-
311-
#### `jsonNullL`
312-
313-
``` purescript
314-
jsonNullL :: TraversalP Json Json
315-
```
316-
317-
#### `jsonBooleanL`
318-
319-
``` purescript
320-
jsonBooleanL :: TraversalP Json Json
321-
```
322-
323-
#### `jsonNumberL`
324-
325-
``` purescript
326-
jsonNumberL :: TraversalP Json Json
327-
```
328-
329-
#### `jsonStringL`
330-
331-
``` purescript
332-
jsonStringL :: TraversalP Json Json
333-
```
334-
335-
#### `jsonArrayL`
336-
337-
``` purescript
338-
jsonArrayL :: TraversalP Json Json
339-
```
340-
341-
#### `jsonObjectL`
342-
343-
``` purescript
344-
jsonObjectL :: TraversalP Json Json
345-
```
346-
347263

docs/Data/Argonaut/Decode.md

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -31,22 +31,4 @@ instance decodeMap :: (Ord a, DecodeJson a, DecodeJson b) => DecodeJson (Map a b
3131
decodeMaybe :: forall a. (DecodeJson a) => Json -> Maybe a
3232
```
3333

34-
#### `decodeL`
35-
36-
``` purescript
37-
decodeL :: forall a. (DecodeJson a, EncodeJson a) => PrismP Json a
38-
```
39-
40-
#### `arrayIndexL`
41-
42-
``` purescript
43-
arrayIndexL :: forall a. (DecodeJson a, EncodeJson a) => Int -> TraversalP Json a
44-
```
45-
46-
#### `objectFieldL`
47-
48-
``` purescript
49-
objectFieldL :: forall a. (DecodeJson a, EncodeJson a) => JString -> TraversalP Json a
50-
```
51-
5234

docs/Data/Argonaut/JCursor.md

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,12 @@ instance showJsonPrim :: Show JsonPrim
3838
runJsonPrim :: JsonPrim -> (forall a. (JNull -> a) -> (JBoolean -> a) -> (JNumber -> a) -> (JString -> a) -> a)
3939
```
4040

41+
#### `exactNull`
42+
43+
``` purescript
44+
exactNull :: JNull
45+
```
46+
4147
#### `primNull`
4248

4349
``` purescript
@@ -92,6 +98,12 @@ downIndex :: Int -> JCursor -> JCursor
9298
cursorGet :: JCursor -> Json -> Maybe Json
9399
```
94100

101+
#### `inferEmpty`
102+
103+
``` purescript
104+
inferEmpty :: JCursor -> Json
105+
```
106+
95107
#### `cursorSet`
96108

97109
``` purescript
@@ -110,4 +122,10 @@ toPrims :: Json -> List (Tuple JCursor JsonPrim)
110122
fromPrims :: List (Tuple JCursor JsonPrim) -> Maybe Json
111123
```
112124

125+
#### `fail`
126+
127+
``` purescript
128+
fail :: forall a b. (Show a) => a -> Either String b
129+
```
130+
113131

docs/Data/Argonaut/Prisms.md

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
## Module Data.Argonaut.Prisms
2+
3+
#### `_Null`
4+
5+
``` purescript
6+
_Null :: PrismP Json JNull
7+
```
8+
9+
#### `_Boolean`
10+
11+
``` purescript
12+
_Boolean :: PrismP Json JBoolean
13+
```
14+
15+
#### `_Number`
16+
17+
``` purescript
18+
_Number :: PrismP Json JNumber
19+
```
20+
21+
#### `_String`
22+
23+
``` purescript
24+
_String :: PrismP Json JString
25+
```
26+
27+
#### `_Array`
28+
29+
``` purescript
30+
_Array :: PrismP Json JArray
31+
```
32+
33+
#### `_Object`
34+
35+
``` purescript
36+
_Object :: PrismP Json JObject
37+
```
38+
39+

docs/Data/Argonaut/Traversals.md

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
## Module Data.Argonaut.Traversals
2+
3+
#### `_JsonNull`
4+
5+
``` purescript
6+
_JsonNull :: TraversalP Json Json
7+
```
8+
9+
#### `_JsonBoolean`
10+
11+
``` purescript
12+
_JsonBoolean :: TraversalP Json Json
13+
```
14+
15+
#### `_JsonNumber`
16+
17+
``` purescript
18+
_JsonNumber :: TraversalP Json Json
19+
```
20+
21+
#### `_JsonString`
22+
23+
``` purescript
24+
_JsonString :: TraversalP Json Json
25+
```
26+
27+
#### `_JsonArray`
28+
29+
``` purescript
30+
_JsonArray :: TraversalP Json Json
31+
```
32+
33+
#### `_JsonObject`
34+
35+
``` purescript
36+
_JsonObject :: TraversalP Json Json
37+
```
38+
39+

gulpfile.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,9 @@ gulp.task('docs', function() {
4242
"Data.Argonaut.Encode": "docs/Data/Argonaut/Encode.md",
4343
"Data.Argonaut.JCursor": "docs/Data/Argonaut/JCursor.md",
4444
"Data.Argonaut.Parser": "docs/Data/Argonaut/Parser.md",
45-
"Data.Argonaut.Printer": "docs/Data/Argonaut/Printer.md"
45+
"Data.Argonaut.Printer": "docs/Data/Argonaut/Printer.md",
46+
"Data.Argonaut.Prisms": "docs/Data/Argonaut/Prisms.md",
47+
"Data.Argonaut.Traversals": "docs/Data/Argonaut/Traversals.md"
4648
}
4749
});
4850
});

0 commit comments

Comments
 (0)