philippeitis
f6cced9605
Support serde for arbitrary field types
...
This introduces the `serde_with` dependency and `rust_type.py`, to allow supporting arbitrary types for serialization.
Since fields may have arbitrary types (eg. `HashMap<_, chrono::Duration>`) which need deserialization, it is necessary to
use type-based serialization to avoid implementing (de)serialization for every permutation of types that require special serialization.
However, `serde` does not let you (de)serialize one type as another (eg. `chrono::Duration` as `Wrapper`) - thus necessitating `serde_with`, which does. `rust_type.py` introduces the `RustType` class, which makes it easy to describe the (de)serialization type used by `serde_with`
2022-10-08 23:01:30 -07:00
philippeitis
8cc2707563
Fix cargo check w.r.t. FieldMask
...
The serde traits are now directly implemented for FieldMask - this helps address potential serde issues with wrapper types, and simplifies the serde process somewhat.
2022-10-08 19:59:23 -07:00
philippeitis
ddac761e06
Add #[serde(default)] for Option parsing
...
If using #[serde(with = ...)] with an Option type, serde will expect all marked fields to be present. Adding #[serde(default)] restores expected behaviour - if no Option value is present, None will be used.
2022-10-08 15:50:47 -07:00
philippeitis
d043fd67b9
Include references to definitions of types
2022-10-08 12:56:54 -07:00
philippeitis
8809ec4807
Add base64 round trip test
2022-10-08 12:56:30 -07:00
philippeitis
a2d16944cd
Make format fully supported
2022-10-08 12:36:59 -07:00
philippeitis
2f3972036c
Remove unnecessary examples for ref types
2022-10-08 03:24:47 -07:00
philippeitis
afb96bd264
Add FieldMask and serde impl
2022-10-08 03:22:08 -07:00
philippeitis
928c6027e6
Add serde test cases
2022-10-08 02:03:39 -07:00
philippeitis
76627413a3
serde cleanup
2022-10-08 00:58:37 -07:00
philippeitis
5398dc6f79
refactor serde functionality into separate module
2022-10-08 00:51:59 -07:00
philippeitis
23dd5d7c24
chrono example types
2022-10-07 21:46:03 -07:00
philippeitis
158e52399e
Use UTC DateTime
2022-10-07 21:35:05 -07:00
philippeitis
66db5c892d
Use type constructors for examples
2022-10-07 21:27:13 -07:00
philippeitis
1f10077e44
Find sources for appropriate types
2022-10-07 20:59:51 -07:00
philippeitis
44882a3c44
use chrono::Duration instead of custom client type
2022-10-07 20:44:31 -07:00
philippeitis
477be5d76c
Fix type signatures
2022-10-07 20:40:47 -07:00
philippeitis
6ced748cb1
Fix tested type
2022-10-07 20:38:41 -07:00
philippeitis
05df68de32
Use chrono::Duration directly with serde attributes
2022-10-07 20:34:40 -07:00
philippeitis
444b610ddc
Add proper error handling for parsing Duration
2022-10-07 14:06:04 -07:00
philippeitis
fc780014d4
Clean up duration parsing code
2022-10-07 13:49:22 -07:00
philippeitis
29aa8df15b
Use appropriate types for date-time, duration, bytes
2022-10-07 13:36:03 -07:00
philippeitis
66c535e4d6
Add support for duration and base64 serde
2022-10-07 02:14:26 -07:00
philippeitis
3d831bcdc6
Use type specified by format key where possible
2022-10-06 22:57:48 -07:00
Sebastian Thiel
93c8601fdc
Release google-apis-common v4.0.1
google-apis-common-v4.0.1
2022-10-02 09:18:16 +08:00
Sebastian Thiel
dc0686ea0b
prepare release of google-apis-common
2022-10-02 09:17:50 +08:00
Sebastian Thiel
f1b07182dd
Release google-walletobjects1-cli v4.0.4+20220928
google-walletobjects1-cli-v4.0.4+20220928
2022-10-01 09:50:53 +08:00
Sebastian Thiel
0d038dbd72
Release google-walletobjects1 v4.0.4+20220928
google-walletobjects1-v4.0.4+20220928
2022-10-01 09:50:11 +08:00
Sebastian Thiel
1aa4bf63d9
regenerate walletobjects
2022-10-01 09:49:58 +08:00
Sebastian Thiel
5895233ea5
add drive3 publish markers
2022-10-01 09:45:42 +08:00
Sebastian Thiel
88483ca756
Release google-drive3-cli v4.0.4+20220225
google-drive3-cli-v4.0.4+20220225
2022-10-01 09:45:21 +08:00
Sebastian Thiel
b71bbcf3b0
Release google-drive3 v4.0.4+20220225
google-drive3-v4.0.4+20220225
2022-10-01 09:45:00 +08:00
Sebastian Thiel
7e5d8998b0
regen drive3 with thread::sleep fix
2022-10-01 09:44:42 +08:00
Sebastian Thiel
9764239ff7
bump patch level for thread::sleep fix
2022-10-01 09:44:02 +08:00
Sebastian Thiel
fe1e97299f
Merge branch 'patch-2'
2022-10-01 09:43:31 +08:00
philippeitis
2b5f119242
Change dependency in api.rs
2022-10-01 01:36:23 +00:00
philippeitis
27891b8a10
Use tokio::time::sleep over std: 🧵 :sleep in api.rs as well
2022-10-01 01:34:56 +00:00
Sebastian Thiel
ba498a6e27
add publish marker
2022-10-01 09:34:35 +08:00
Sebastian Thiel
90e7b20eb9
Release google-drive3 v4.0.3+20220225
google-drive3-v4.0.3+20220225
2022-10-01 09:33:43 +08:00
Sebastian Thiel
1eafc7b628
regen google drive with latest fixes
2022-10-01 09:33:31 +08:00
Sebastian Thiel
348be95f84
bump patch level for +Send fix
2022-10-01 09:25:17 +08:00
Sebastian Thiel
6548d38483
Merge branch 'patch-1'
2022-10-01 09:22:58 +08:00
Sebastian Thiel
7ef298daed
Merge branch 'add-walletobjects-api'
2022-10-01 09:09:05 +08:00
Sebastian Thiel
f7b820edaa
Add walletobjects CLI
2022-10-01 09:04:33 +08:00
philippeitis
811ed3d016
Replace std: 🧵 :sleep with tokio: 🧵 :sleep
2022-09-30 07:42:11 +00:00
philippeitis
276324ae09
Make remove_json_null_values O(n) instead of O(n^2)
2022-09-30 07:35:55 +00:00
philippeitis
dad761d3f8
Add additional send/sync bounds
2022-09-29 21:33:57 -07:00
philippeitis
5a5d476317
Update lib.rs
2022-09-29 06:39:11 +00:00
philippeitis
b10bddab08
Add Send bound to GetToken
2022-09-29 06:34:47 +00:00
shinichi kogai
9fe9e424ef
generate api client
2022-09-29 12:40:34 +09:00